:root {
  color-scheme: var(--tg-color-scheme, light);
  --app-viewport-height: 100dvh;
  --app-safe-top: var(--tg-content-safe-area-inset-top, 0px);
  --bg: var(--tg-theme-bg-color, #f4f5f7);
  --surface: var(--tg-theme-secondary-bg-color, #ffffff);
  --text: var(--tg-theme-text-color, #131517);
  --muted: var(--tg-theme-hint-color, #80858c);
  --link: var(--tg-theme-link-color, #2481cc);
  --accent: var(--tg-theme-button-color, #2481cc);
  --accent-text: var(--tg-theme-button-text-color, #ffffff);
  --destructive: var(--tg-theme-destructive-text-color, #e45151);
  --line: color-mix(in srgb, var(--text) 9%, transparent);
  --soft: color-mix(in srgb, var(--text) 5%, var(--surface));
  --accent-soft: color-mix(in srgb, var(--accent) 12%, var(--surface));
  --shadow: 0 14px 38px color-mix(in srgb, #000 10%, transparent);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, sans-serif;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { width: 100%; max-width: 100%; overflow-x: hidden; background: var(--bg); }
body { width: 100%; max-width: 100%; margin: 0; overflow-x: hidden; background: var(--bg); color: var(--text); min-height: var(--app-viewport-height); -webkit-font-smoothing: antialiased; }
html.scroll-locked, body.scroll-locked { overflow: hidden; overscroll-behavior: none; }
body.scroll-locked { position: fixed; left: 0; right: 0; width: 100%; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
h1, h2, h3, p { margin-top: 0; }
.topbar { position: relative; z-index: 40; width: 100%; max-width: 1120px; margin: auto; padding: calc(22px + var(--tg-content-safe-area-inset-top, 0px)) 24px 18px; display: grid; gap: 18px; }
.topbar-toolbar { position: relative; min-height: 32px; display: flex; justify-content: center; align-items: center; }
.topbar-actions { position: absolute; right: 0; top: 50%; display: flex; align-items: center; gap: 9px; transform: translateY(-50%); }
.group-heading { min-width: 0; }
.group-heading h1 { max-width: 760px; overflow: hidden; overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; }
.more-entry-wrap { position: relative; flex: 0 0 auto; }
.more-entry { display: flex; align-items: center; justify-content: center; gap: 8px; min-width: 90px; height: 32px; padding: 0 16px; border: 1px solid var(--line); border-radius: 13px; background: var(--soft); color: var(--text); font-size: 13px; font-weight: 720; line-height: 1; transition: color .18s, background .18s, transform .18s; }
.more-entry:active, .more-entry[aria-expanded="true"] { transform: scale(.94); color: var(--accent); background: var(--accent-soft); }
.menu-burger { display: grid; gap: 2px; width: 12px; flex: 0 0 auto; }
.menu-burger i { display: block; width: 100%; height: 1.5px; border-radius: 2px; background: currentColor; }
.more-menu { position: absolute; z-index: 30; top: calc(100% + 8px); left: 50%; width: 210px; padding: 6px; border: 1px solid var(--line); border-radius: 15px; background: color-mix(in srgb, var(--surface) 94%, transparent); box-shadow: var(--shadow); backdrop-filter: blur(18px); transform: translateX(-50%); animation: fade-in .14s ease both; }
.more-menu button { display: grid; grid-template-columns: 24px 1fr; align-items: center; gap: 8px; width: 100%; padding: 10px 11px; border: 0; border-radius: 10px; background: transparent; color: var(--text); text-align: left; font-size: 13px; }
.more-menu button:hover { background: var(--soft); }
.more-menu button:active { background: var(--accent-soft); }
.more-menu button span:first-child { color: var(--muted); text-align: center; }
h1 { font-size: 21px; line-height: 1.1; margin: 0; letter-spacing: -.025em; }
h2 { margin-bottom: 0; letter-spacing: -.035em; }
.eyebrow { display: block; color: var(--muted); text-transform: uppercase; letter-spacing: .09em; font-size: 10px; line-height: 1.3; font-weight: 780; margin-bottom: 5px; }
main { width: 100%; max-width: 1120px; margin: auto; padding: 0 24px 110px; overflow-x: clip; }
.banner-stage { position: relative; margin: 6px 0 16px; }
.banner-carousel { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; border-radius: 23px; overscroll-behavior-x: contain; }
.banner-carousel::-webkit-scrollbar { display: none; }
.intro { flex: 0 0 100%; width: 100%; min-height: 145px; margin: 0; padding: 23px 28px 32px; border-radius: 23px; background: var(--surface); display: flex; align-items: end; justify-content: space-between; gap: 28px; position: relative; overflow: hidden; scroll-snap-align: start; --banner-accent: var(--accent-soft); }
.intro::after { content: ""; position: absolute; z-index: 0; width: 280px; height: 280px; border-radius: 50%; right: -80px; top: -150px; background: var(--banner-accent); pointer-events: none; }
.intro > * { position: relative; z-index: 1; }
.intro h2 { font-size: clamp(27px, 3.8vw, 37px); line-height: 1; }
.intro p { max-width: 330px; margin: 0; color: var(--muted); line-height: 1.4; font-size: 13px; }
.banner-summary { max-width: 330px; }
.banner-slide[data-banner-listing] { cursor: pointer; transition: filter .18s; }
.banner-slide[data-banner-listing]:active { filter: brightness(.97); }
.banner-link-hint { display: inline-flex; align-items: center; gap: 7px; margin-top: 10px; padding: 7px 10px; border-radius: 10px; background: color-mix(in srgb, var(--accent) 11%, var(--surface)); color: var(--accent); font-size: 11px; font-weight: 760; }
.banner-link-hint i { font-size: 14px; font-style: normal; }
.banner--green { --banner-accent: color-mix(in srgb, #35b888 18%, var(--surface)); }
.banner--violet { --banner-accent: color-mix(in srgb, #8a6dde 20%, var(--surface)); }
.banner--amber { --banner-accent: color-mix(in srgb, #d99a45 20%, var(--surface)); }
.banner-dots { position: absolute; z-index: 2; left: 50%; bottom: 11px; transform: translateX(-50%); display: flex; gap: 5px; padding: 4px 6px; border-radius: 9px; background: color-mix(in srgb, var(--surface) 75%, transparent); backdrop-filter: blur(8px); }
.banner-dots:empty { display: none; }
.banner-dots button { width: 5px; height: 5px; padding: 0; border: 0; border-radius: 5px; background: var(--muted); opacity: .42; transition: width .2s, opacity .2s, background .2s; }
.banner-dots button.active { width: 15px; opacity: 1; background: var(--accent); }
.group-summary { max-width: 360px; }
.admin-screen { padding-bottom: 80px; }
.admin-head { display: flex; align-items: center; gap: 12px; margin: 8px 0 22px; }
.admin-head h2, .admin-panel h3 { margin: 0; }
.admin-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.admin-stat, .admin-panel { background: var(--surface); border-radius: 20px; padding: 20px; }
.admin-stat strong { display: block; font-size: 28px; margin-bottom: 5px; }
.admin-stat span { color: var(--muted); font-size: 12px; }
.admin-panel { display: grid; gap: 17px; margin-bottom: 16px; }
.setting-toggle { display: flex; flex-direction: row; align-items: center; justify-content: space-between; gap: 18px; }
.setting-toggle span { display: grid; gap: 4px; }
.setting-toggle small { color: var(--muted); font-weight: 400; }
.setting-toggle input { width: 22px; height: 22px; accent-color: var(--accent); }
.price-input-row { display: grid; grid-template-columns: minmax(0, 1fr) 82px; gap: 8px; }
.price-input-row select { padding-left: 10px; padding-right: 8px; font-weight: 750; }
.admin-users { display: grid; gap: 8px; }
.admin-user { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 13px 14px; border-radius: 14px; background: var(--soft); }
.admin-user span { display: grid; gap: 3px; min-width: 0; }
.admin-user strong { overflow: hidden; text-overflow: ellipsis; }
.admin-user small { color: var(--muted); }
.admin-user b { white-space: nowrap; }
.admin-delete { margin-top: 14px; width: 100%; }
.group-summary > span { display: block; color: var(--muted); font-size: 11px; margin-bottom: 5px; }
.group-summary > strong { display: block; font-size: 18px; margin-bottom: 10px; }
.search-panel { display: flex; gap: 12px; align-items: center; padding: 14px 0 34px; overflow: hidden; }
.search { min-width: 280px; flex: 1; min-height: 52px; background: var(--surface); border: 1px solid transparent; border-radius: 16px; padding: 0 17px; display: flex; align-items: center; gap: 12px; transition: border-color .2s, box-shadow .2s; }
.search:focus-within { border-color: color-mix(in srgb, var(--accent) 55%, transparent); box-shadow: 0 0 0 4px var(--accent-soft); }
.search-icon { width: 16px; height: 16px; border: 2px solid var(--muted); border-radius: 50%; position: relative; opacity: .8; }
.search-icon::after { content: ""; position: absolute; width: 6px; height: 2px; background: var(--muted); border-radius: 2px; right: -5px; bottom: -2px; transform: rotate(45deg); }
.search input { width: 100%; padding: 14px 0; border: 0; border-radius: 0; outline: 0; background: transparent; color: var(--text); box-shadow: none; }
.search input:focus { border: 0; outline: 0; box-shadow: none; }
.search input::placeholder, input::placeholder, textarea::placeholder { color: var(--muted); opacity: .75; }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 3px; }
.chips::-webkit-scrollbar { display: none; }
.chip { white-space: nowrap; border: 0; color: var(--muted); background: var(--surface); border-radius: 14px; padding: 13px 16px; font-size: 13px; font-weight: 650; transition: background .18s, color .18s, transform .18s; }
.chip:active { transform: scale(.96); }
.chip.active { background: var(--accent); color: var(--accent-text); box-shadow: 0 6px 16px color-mix(in srgb, var(--accent) 20%, transparent); }
.section-heading { display: flex; align-items: end; justify-content: space-between; margin: 2px 2px 17px; }
.section-heading h2 { font-size: 24px; }
.listing-filters { display: flex; align-items: center; gap: 7px; flex: 0 0 auto; }
.text-button { border: 0; border-radius: 12px; padding: 9px 13px; background: var(--accent-soft); color: var(--accent); font-size: 13px; font-weight: 750; transition: transform .18s; }
.text-button:active { transform: scale(.95); }
.text-button.active { background: var(--accent); color: var(--accent-text); }
.favorite-filter { width: 38px; height: 38px; display: grid; place-items: center; border: 0; border-radius: 12px; background: var(--accent-soft); color: var(--accent); font-size: 22px; line-height: 1; transition: transform .18s, color .18s, background .18s; }
.favorite-filter:active { transform: scale(.92); }
.favorite-filter.active { color: var(--accent-text); background: var(--accent); }
.listing-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.load-more-sentinel { min-height: 78px; display: flex; align-items: center; justify-content: center; gap: 9px; color: var(--muted); font-size: 11px; }
.load-more-sentinel i { width: 18px; height: 18px; border: 2px solid var(--line); border-top-color: var(--accent); border-radius: 50%; animation: spin .75s linear infinite; }
.card { background: var(--surface); border: 0; border-radius: 22px; overflow: hidden; text-align: left; padding: 0; color: inherit; position: relative; transition: transform .22s cubic-bezier(.2,.8,.2,1), box-shadow .22s; animation: card-in .35s both; }
.card-open { display: block; width: 100%; height: 100%; border: 0; padding: 0; background: transparent; color: inherit; text-align: left; }
.card, .card-body, .dialog-head > div, .contact-box, .details-actions { min-width: 0; max-width: 100%; }
.card:nth-child(2) { animation-delay: .04s; }
.card:nth-child(3) { animation-delay: .08s; }
.card:nth-child(4) { animation-delay: .12s; }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card:active { transform: scale(.985); }
.card.optimistic { opacity: .68; }
.card.favorite-removing { opacity: 0; transform: scale(.96); pointer-events: none; }
.media { aspect-ratio: 16/10; position: relative; overflow: hidden; background: var(--soft); }
.card-image { width: 100%; height: 100%; object-fit: cover; display: block; opacity: 0; transition: opacity .35s, transform .45s; }
.card-image.loaded { opacity: 1; }
.card:hover .card-image { transform: scale(1.02); }
.media-count { position: absolute; right: 10px; top: 10px; z-index: 2; border-radius: 9px; padding: 5px 8px; background: color-mix(in srgb, #000 58%, transparent); color: white; font-size: 10px; font-weight: 750; backdrop-filter: blur(8px); }
.favorite-button { display: grid; place-items: center; border: 1px solid color-mix(in srgb, #fff 45%, transparent); color: white; background: color-mix(in srgb, #000 48%, transparent); backdrop-filter: blur(9px); -webkit-backdrop-filter: blur(9px); font-family: inherit; line-height: 1; transition: transform .18s, color .18s, background .18s, opacity .18s; }
.favorite-button:active { transform: scale(.9); }
.favorite-button:disabled { opacity: .62; }
.favorite-button.active { color: #ff6681; background: color-mix(in srgb, #19151a 62%, transparent); }
.card-favorite { position: absolute; z-index: 4; left: 10px; top: 10px; width: 36px; height: 36px; border-radius: 12px; font-size: 22px; }
.placeholder { width: 100%; height: 100%; display: flex; flex-direction: column; justify-content: space-between; padding: 18px; color: var(--placeholder-ink, var(--muted)); background:
  radial-gradient(circle at 85% 18%, color-mix(in srgb, var(--placeholder-ink) 10%, transparent) 0 18%, transparent 18.5%),
  linear-gradient(145deg, var(--placeholder-bg, var(--soft)), color-mix(in srgb, var(--placeholder-bg, var(--soft)) 72%, var(--surface))); }
.placeholder-icon { align-self: flex-end; width: 46px; height: 46px; border-radius: 15px; display: grid; place-items: center; background: color-mix(in srgb, var(--placeholder-ink) 11%, transparent); font-size: 23px; font-weight: 500; }
.placeholder-label { font-size: 11px; font-weight: 780; text-transform: uppercase; letter-spacing: .08em; opacity: .8; }
.placeholder--transport { --placeholder-bg: color-mix(in srgb, #6895f5 17%, var(--surface)); --placeholder-ink: color-mix(in srgb, #477be7 70%, var(--text)); }
.placeholder--home { --placeholder-bg: color-mix(in srgb, #d59b59 18%, var(--surface)); --placeholder-ink: color-mix(in srgb, #b97731 72%, var(--text)); }
.placeholder--gift { --placeholder-bg: color-mix(in srgb, #d9769b 16%, var(--surface)); --placeholder-ink: color-mix(in srgb, #c34e78 70%, var(--text)); }
.placeholder--service { --placeholder-bg: color-mix(in srgb, #8e78e8 16%, var(--surface)); --placeholder-ink: color-mix(in srgb, #7057d7 72%, var(--text)); }
.placeholder--things { --placeholder-bg: color-mix(in srgb, #55b894 17%, var(--surface)); --placeholder-ink: color-mix(in srgb, #329675 72%, var(--text)); }
.card-body { padding: 17px 18px 19px; }
.meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--muted); font-size: 11px; margin-bottom: 9px; }
.meta time { flex: 0 0 auto; white-space: nowrap; }
.category { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.status { display: inline-flex; width: 7px; height: 7px; border-radius: 50%; background: var(--muted); margin-right: 6px; box-shadow: 0 0 0 3px color-mix(in srgb, currentColor 12%, transparent); }
.status--green { background: #35b888; color: #35b888; }
.status--amber { background: #d99a45; color: #d99a45; }
.status--cyan { background: #32aeca; color: #32aeca; }
.status--blue { background: #5284eb; color: #5284eb; }
.status--pink { background: #d96791; color: #d96791; }
.status--purple { background: #8a6dde; color: #8a6dde; }
.status--orange { background: #e17b42; color: #e17b42; }
.status--red { background: #d95d5d; color: #d95d5d; }
.status--violet { background: #a065d6; color: #a065d6; }
.status--gray { background: var(--muted); color: var(--muted); }
.card h3 { max-width: 100%; overflow-wrap: anywhere; font-size: 17px; line-height: 1.25; margin: 0 0 12px; min-height: 2.5em; }
.price { font-size: 18px; line-height: 1; font-weight: 800; letter-spacing: -.025em; }
.primary { border: 0; border-radius: 14px; background: var(--accent); color: var(--accent-text); font-weight: 750; padding: 14px 19px; box-shadow: 0 7px 18px color-mix(in srgb, var(--accent) 22%, transparent); transition: transform .18s, filter .18s; }
.primary:hover { filter: brightness(1.04); }
.primary:active { transform: scale(.97); }
.primary:disabled { opacity: .5; filter: none; cursor: default; box-shadow: none; }
.primary.compact { padding: 12px 16px; display: flex; align-items: center; gap: 6px; }
.wide { width: 100%; margin-top: 5px; }
.fab { display: none; position: fixed; right: 18px; bottom: calc(18px + env(safe-area-inset-bottom)); width: 58px; height: 58px; border: 0; border-radius: 19px; background: var(--accent); color: var(--accent-text); font-size: 28px; box-shadow: 0 10px 28px color-mix(in srgb, var(--accent) 36%, transparent); z-index: 5; transition: transform .18s; }
.fab:active { transform: scale(.92); }
.empty { text-align: center; padding: 74px 20px; background: var(--surface); border-radius: 24px; }
.empty-icon { width: 62px; height: 62px; margin: 0 auto 18px; border-radius: 20px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-size: 28px; }
.empty p { color: var(--muted); margin: 8px auto 22px; max-width: 360px; }
.hidden { display: none !important; }
dialog { position: fixed; inset: 0; width: min(600px, calc(100% - 32px)); max-width: calc(100% - 32px); max-height: min(calc(var(--app-viewport-height) * 0.9), 760px); margin: auto; overflow-x: hidden; overflow-y: auto; border: 0; border-radius: 26px; padding: 0; color: var(--text); background: var(--surface); box-shadow: 0 30px 90px color-mix(in srgb, #000 25%, transparent); animation: dialog-in .25s cubic-bezier(.2,.8,.2,1); }
#create-dialog { animation: create-dialog-in .2s ease-out; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
dialog::backdrop { background: color-mix(in srgb, #080a0c 55%, transparent); backdrop-filter: blur(6px); animation: fade-in .2s; }
#details-dialog::backdrop { opacity: calc(1 - var(--pull-progress, 0)); transition: opacity .1s linear; }
#details-dialog {
  --sheet-offset: clamp(180px, 38dvh, 300px);
  --pull-offset: 0px;
  height: min(calc(var(--app-viewport-height) - var(--app-safe-top) - 24px), 760px);
  transform: translate3d(0, calc(var(--sheet-offset) + var(--pull-offset)), 0);
  transition: transform .38s cubic-bezier(.22,1,.36,1);
  animation: details-dialog-in .2s ease-out;
  will-change: transform;
  contain: layout paint;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
#details-dialog.expanded { --sheet-offset: 0px; }
dialog form, #details, .about-panel { padding: 26px; }
#details { position: relative; width: 100%; min-width: 0; max-width: 100%; overflow: hidden; }
.about-panel p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.58; }
.dialog-head { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.details-favorite { flex: 0 0 auto; width: 42px; height: 42px; border-radius: 14px; border-color: var(--line); background: var(--soft); color: var(--muted); font-size: 25px; backdrop-filter: none; }
.details-favorite.active { color: #e84f6b; background: color-mix(in srgb, #e84f6b 12%, var(--soft)); }
.dialog-head h2 { font-size: 24px; line-height: 1.12; }
.icon-button { flex: 0 0 auto; width: 38px; height: 38px; border-radius: 13px; border: 0; background: var(--soft); color: var(--text); font-size: 24px; line-height: 1; }
.dialog-head h2, .details-description, .contact-box strong { max-width: 100%; overflow-wrap: anywhere; word-break: break-word; }
label { display: grid; gap: 8px; margin-bottom: 15px; color: var(--muted); font-size: 12px; font-weight: 700; }
input, textarea, select { width: 100%; border: 1px solid transparent; border-radius: 13px; padding: 13px 14px; background: var(--soft); color: var(--text); outline: none; transition: border-color .18s, box-shadow .18s; }
input:focus, textarea:focus, select:focus { border-color: color-mix(in srgb, var(--accent) 55%, transparent); box-shadow: 0 0 0 4px var(--accent-soft); }
input[aria-invalid="true"] { border-color: var(--destructive); box-shadow: 0 0 0 4px color-mix(in srgb, var(--destructive) 14%, transparent); }
.field-error { min-height: 1.25em; color: var(--destructive); font-size: 10px; font-weight: 600; }
textarea { resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-note { text-align: center; color: var(--muted); font-size: 11px; margin: 13px 0 0; }
.media-field { margin-bottom: 15px; }
.field-label { display: flex; justify-content: space-between; color: var(--muted); font-size: 12px; font-weight: 700; margin-bottom: 8px; }
.field-label small { font-weight: 500; }
.media-upload { min-height: 78px; margin: 0; padding: 14px; border: 1px dashed color-mix(in srgb, var(--accent) 38%, transparent); border-radius: 15px; background: var(--accent-soft); color: var(--text); display: flex; align-items: center; gap: 12px; cursor: pointer; }
.media-upload input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.upload-icon { flex: 0 0 auto; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 13px; background: var(--accent); color: var(--accent-text); font-size: 23px; }
.media-upload strong, .media-upload small { display: block; }
.media-upload small { color: var(--muted); margin-top: 3px; font-weight: 500; }
.media-preview { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 8px; }
.preview-item { aspect-ratio: 1; position: relative; overflow: hidden; border-radius: 12px; background: var(--soft); }
.preview-item img, .preview-item video { width: 100%; height: 100%; object-fit: cover; }
.preview-item button { position: absolute; right: 5px; top: 5px; width: 24px; height: 24px; border: 0; border-radius: 8px; background: color-mix(in srgb, #000 68%, transparent); color: white; }
.preview-upload-state { position: absolute; inset: auto 5px 5px; padding: 5px 7px; border-radius: 8px; background: color-mix(in srgb, #000 72%, transparent); color: white; font-size: 9px; font-weight: 750; backdrop-filter: blur(5px); }
.preview-upload-state.error { background: color-mix(in srgb, #b9343e 86%, transparent); border: 0; width: auto; height: auto; top: auto; }
.preview-progress { position: absolute; inset: auto 0 0; height: 3px; background: rgba(255,255,255,.22); }
.preview-progress i { display: block; height: 100%; background: var(--accent); transition: width .15s linear; }
.details-media { width: calc(100% + 52px); margin: -26px -26px 23px; aspect-ratio: 16/9; overflow: hidden; background: var(--soft); }
.details-image { width: 100%; height: 100%; object-fit: cover; }
.details-media .placeholder { padding: 24px; }
.details-media .placeholder-icon { width: 56px; height: 56px; font-size: 27px; }
.carousel { width: calc(100% + 52px); margin: -26px -26px 23px; position: relative; }
.details-gallery { width: 100%; display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; background: var(--soft); overscroll-behavior-x: contain; }
.details-gallery::-webkit-scrollbar { display: none; }
.gallery-slide { flex: 0 0 100%; width: 100%; aspect-ratio: 16/9; position: relative; overflow: hidden; scroll-snap-align: start; background: var(--soft); cursor: zoom-in; }
.gallery-slide img, .gallery-slide video { display: block; width: 100%; height: 100%; object-fit: cover; }
.carousel-button { position: absolute; top: 50%; z-index: 2; width: 34px; height: 42px; margin-top: -21px; border: 0; border-radius: 12px; background: color-mix(in srgb, #000 48%, transparent); color: white; font-size: 27px; backdrop-filter: blur(7px); }
.carousel-button.previous { left: 10px; }
.carousel-button.next { right: 10px; }
.carousel-dots { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); display: flex; gap: 5px; padding: 5px 7px; border-radius: 10px; background: color-mix(in srgb, #000 32%, transparent); backdrop-filter: blur(7px); }
.carousel-dots i { width: 5px; height: 5px; border-radius: 50%; background: rgba(255,255,255,.45); transition: width .18s, background .18s; }
.carousel-dots i.active { width: 14px; border-radius: 4px; background: white; }
.media-open-hint { position: absolute; right: 10px; bottom: 10px; z-index: 3; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 11px; background: color-mix(in srgb, #000 48%, transparent); color: white; font-size: 17px; backdrop-filter: blur(8px); }
.media-kind { position: absolute; left: 50%; top: 50%; width: 48px; height: 48px; margin: -24px; display: grid; place-items: center; border-radius: 50%; padding-left: 3px; background: color-mix(in srgb, #000 46%, transparent); color: white; font-size: 18px; backdrop-filter: blur(8px); }
.details-description { color: var(--muted); line-height: 1.55; white-space: pre-wrap; }
.details-created { margin: -6px 0 16px; color: var(--muted); font-size: 11px; }
.contact-box { position: relative; width: 100%; margin-top: 20px; padding: 15px 46px 15px 16px; border: 1px solid transparent; border-radius: 15px; background: var(--accent-soft); color: var(--text); text-align: left; transition: transform .18s, border-color .18s, filter .18s; }
.contact-box:hover { border-color: color-mix(in srgb, var(--accent) 24%, transparent); filter: brightness(1.02); }
.contact-box:active { transform: scale(.985); }
.contact-box span { display: block; color: var(--muted); font-size: 11px; margin-bottom: 4px; }
.contact-box i { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); color: var(--accent); font-size: 20px; font-style: normal; }
.details-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.secondary, .danger { flex: 1; border-radius: 13px; padding: 12px; background: var(--soft); color: var(--text); border: 0; font-weight: 700; }
.secondary:disabled { opacity: .55; cursor: default; }
.bump-action { display: inline-flex; align-items: center; width: auto; margin: 10px 0 16px; padding: 7px 10px; border: 0; border-radius: 9px; background: var(--accent-soft); color: var(--accent); font-size: 11px; line-height: 1.2; font-weight: 750; transition: transform .18s, filter .18s, opacity .18s; }
.bump-action:not(:disabled):active { transform: scale(.96); }
.bump-action:disabled { color: var(--muted); opacity: .72; cursor: default; }
.danger { color: var(--destructive); }
.toast { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translate(-50%, 120px); opacity: 0; background: var(--text); color: var(--bg); border-radius: 14px; padding: 12px 17px; box-shadow: var(--shadow); transition: transform .25s, opacity .25s; z-index: 20; font-size: 13px; white-space: nowrap; }
.toast.show { transform: translate(-50%, 0); opacity: 1; }
.app-loader { position: fixed; inset: 0; z-index: 100; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; background: var(--bg); color: var(--muted); font-size: 12px; transition: opacity .28s, visibility .28s; }
.app-loader.hidden-loader { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-mark { width: 52px; height: 52px; border-radius: 17px; display: grid; place-items: center; background: var(--accent); color: var(--accent-text); font-size: 21px; font-weight: 850; animation: loader-pulse 1.15s ease-in-out infinite; }
.loading-bar { position: fixed; z-index: 40; top: 0; left: 0; width: 100%; height: 3px; overflow: hidden; opacity: 0; pointer-events: none; transition: opacity .18s; }
.loading-bar.visible { opacity: 1; }
.loading-bar::after { content: ""; display: block; width: 38%; height: 100%; border-radius: 3px; background: var(--accent); animation: loading-slide .9s ease-in-out infinite; }
.media-viewer:not([open]) { display: none; }
.media-viewer[open] { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; padding: 0; overflow: hidden; border: 0; border-radius: 0; background: #05080b; touch-action: none; overscroll-behavior: none; }
.media-viewer::backdrop { background: #05080b; backdrop-filter: none; }
.viewer-content { width: 100%; height: 100%; display: grid; place-items: center; padding: 68px 16px 56px; overflow: hidden; cursor: grab; }
.viewer-content:active { cursor: grabbing; }
.viewer-content img, .viewer-content video { display: block; width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; user-select: none; -webkit-user-drag: none; transform-origin: center; will-change: transform; }
.viewer-fade img, .viewer-fade video { animation: viewer-fade .2s ease-out; }
.viewer-next img, .viewer-next video { animation: viewer-next .24s cubic-bezier(.2,.8,.2,1); }
.viewer-previous img, .viewer-previous video { animation: viewer-previous .24s cubic-bezier(.2,.8,.2,1); }
.viewer-close { position: absolute; z-index: 2; top: calc(14px + env(safe-area-inset-top) + var(--tg-content-safe-area-inset-top, 0px)); right: 14px; width: 44px; height: 44px; border: 1px solid rgba(255,255,255,.58); border-radius: 14px; background: rgba(0,0,0,.58); color: white; font-size: 28px; text-shadow: 0 1px 3px #000; box-shadow: 0 3px 16px rgba(0,0,0,.5), inset 0 0 0 1px rgba(0,0,0,.24); backdrop-filter: blur(10px); }
.viewer-nav { position: absolute; z-index: 2; top: 50%; width: 44px; height: 52px; margin-top: -26px; border: 0; border-radius: 14px; background: rgba(255,255,255,.12); color: white; font-size: 30px; }
.viewer-prev { left: 10px; }
.viewer-next { right: 10px; }
.viewer-counter { position: absolute; bottom: calc(14px + env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); color: white; font-size: 12px; }
@keyframes card-in { from { opacity: 0; transform: translateY(10px); } }
@keyframes dialog-in { from { opacity: 0; transform: translateY(14px) scale(.98); } }
@keyframes create-dialog-in { from { opacity: 0; } }
@keyframes details-dialog-in { from { opacity: 0; } }
@keyframes fade-in { from { opacity: 0; } }
@keyframes loader-pulse { 50% { transform: scale(.93); opacity: .78; } }
@keyframes loading-slide { from { transform: translateX(-110%); } to { transform: translateX(280%); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes viewer-fade { from { opacity: 0; transform: scale(.985); } }
@keyframes viewer-next { from { opacity: 0; transform: translateX(26px); } }
@keyframes viewer-previous { from { opacity: 0; transform: translateX(-26px); } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
@media (max-width: 760px) {
  .topbar { padding: calc(20px + var(--tg-content-safe-area-inset-top, 0px)) 14px 14px; gap: 18px; }
  .topbar-toolbar { padding-inline: 104px; }
  .group-heading { padding-inline: 2px; }
  .group-heading h1 { max-width: 100%; font-size: 22px; line-height: 1.08; }
  .more-entry-wrap { transform: translateY(-5px); }
  .more-entry { min-width: 90px; height: 30px; border-radius: 13px; font-size: 13px; }
  .topbar-actions { display: none; }
  .topbar .primary { display: none; }
  .admin-summary { grid-template-columns: 1fr 1fr; }
  .admin-stat { padding: 16px; }
  main { padding: 0 14px 92px; }
  .banner-stage { margin-top: 3px; }
  .banner-carousel { border-radius: 20px; }
  .intro { min-height: 126px; margin: 0; padding: 17px 18px 29px; border-radius: 20px; display: block; }
  .intro h2 { font-size: clamp(25px, 7.4vw, 32px); }
  .intro p { font-size: 13px; max-width: 290px; }
  .banner-summary { max-width: 290px; margin-top: 10px; }
  .group-summary { margin-top: 10px; }
  .search-panel { display: block; padding: 12px 0 28px; }
  .search { width: 100%; min-height: 50px; margin-bottom: 10px; }
  .chips { margin: 0 -14px; padding: 2px 14px 4px; }
  .section-heading { margin-inline: 2px; gap: 10px; }
  .section-heading h2 { font-size: 21px; }
  .listing-filters { gap: 5px; }
  .listing-filters .text-button { padding: 8px 9px; font-size: 11px; }
  .favorite-filter { width: 34px; height: 34px; border-radius: 11px; font-size: 18px; }
  .listing-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .card { border-radius: 18px; }
  .card-body { padding: 13px 14px 16px; }
  .card h3 { font-size: 15px; }
  .price { font-size: 16px; }
  .placeholder { padding: 13px; }
  .placeholder-icon { width: 38px; height: 38px; border-radius: 12px; font-size: 19px; }
  .placeholder-label { font-size: 9px; }
  .fab { display: grid; place-items: center; }
  .carousel-button { display: none; }
  .viewer-nav { display: none; }
}
@media (max-width: 430px) {
  .listing-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .meta { gap: 5px; font-size: 9px; }
  .form-row { grid-template-columns: 1fr; gap: 0; }
  dialog { inset: auto 10px 10px 10px; width: auto; max-width: none; max-height: calc(var(--app-viewport-height) - var(--app-safe-top) - 20px); margin: 0; border-radius: 25px; }
  #create-dialog {
    inset: calc(var(--app-safe-top) + 10px) 10px auto;
    height: calc(var(--app-viewport-height) - var(--app-safe-top) - 20px);
    max-height: none;
  }
  #details-dialog {
    --sheet-offset: 38dvh;
    height: calc(var(--app-viewport-height) - var(--app-safe-top) - 20px);
  }
  dialog::backdrop { backdrop-filter: none; }
  .media-preview { grid-template-columns: repeat(3, 1fr); }
}
