.public { padding-bottom: env(safe-area-inset-bottom); background: #0b0908; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.pub-header {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  max-width: 960px; margin: 0 auto; padding: 14px 18px 8px;
}
.pub-header-right { display: flex; align-items: center; gap: 14px; }
.pub-account { border-color: var(--frame); }

/* Личный кабинет */
.auth-card { max-width: 460px; margin: 20px auto; }
.auth-card h1 { margin-bottom: 6px; }
.auth-card .form input[name="code"] { font-size: 28px; letter-spacing: .5em; text-align: center; }
.me-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 12px; }
.me-head h1 { margin: 0; }
.me-head p { margin: 4px 0 0; }
.pub-card h2 { display: flex; align-items: center; gap: 8px; font-size: 17px; font-weight: 800; text-transform: uppercase; letter-spacing: .03em; color: var(--gold); }
.bonus-row { display: flex; align-items: center; gap: 18px; margin: 10px 0; }
.bonus-count { display: flex; flex-direction: column; align-items: center; min-width: 90px; }
.bonus-count b { font-size: 44px; line-height: 1; background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.bonus-count small { font-size: 11px; color: var(--muted); text-align: center; }
.bonus-progress { flex: 1; }
.bonus-progress .progress span { background: linear-gradient(90deg, #e0222a, #ff9a1f, #ffd36b); }
.my-booking {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 12px 0 12px 12px; border-top: 1px solid var(--line); border-left: 3px solid var(--room);
}
.my-booking + .my-booking { margin-top: 2px; }
.my-booking-past { opacity: .85; }
.my-booking .tag { display: inline-block; margin-top: 4px; }
.me-footer { display: flex; justify-content: space-between; align-items: center; padding: 6px 4px 20px; }
.legal { line-height: 1.6; }
.legal h2 { margin-top: 22px; }
.legal ul { padding-left: 20px; }

.pub-city { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-weight: 600; font-size: 14px; }
.pub-main { max-width: 960px; margin: 0 auto; padding: 8px 18px 32px; }
.pub-footer {
  max-width: 960px; margin: 0 auto; padding: 24px 18px 40px;
  display: flex; flex-direction: column; align-items: center; gap: 14px;
  border-top: 1px solid var(--frame); color: var(--muted); text-align: center;
}

/* Обложка — как лицевая сторона визитки */
.hero-card {
  position: relative; overflow: hidden; min-height: 420px; margin-top: 6px;
  border: 1px solid var(--frame); border-radius: 22px; background: #070605;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .55);
}
.hero-photo {
  position: absolute; inset: 0 0 0 38%; background-size: cover; background-position: center;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 35%);
  mask-image: linear-gradient(90deg, transparent 0, #000 35%);
}
.hero-inner { position: relative; max-width: 560px; padding: 44px 36px 36px; display: flex; flex-direction: column; gap: 14px; }
.hero-tagline { font-size: 26px; }
.hero-card .brand-divider { width: 78%; }
.hero-card .slogan { font-size: 14px; }
.hero-text { margin: 0; color: #d9cfc6; max-width: 420px; }
.hero-cta { align-self: flex-start; margin-top: 4px; }

/* Пять направлений — как иконки на визитке */
.features { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin: 18px 0; }
.feature {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px;
  padding: 16px 10px; border-radius: 16px; border: 1px solid var(--frame);
  background: linear-gradient(180deg, rgba(255, 140, 30, .06), rgba(0, 0, 0, 0));
  color: var(--text); transition: border-color .15s, transform .15s;
}
.feature:hover { text-decoration: none; border-color: var(--gold); transform: translateY(-2px); }
.feature b { font-size: 13px; font-weight: 700; line-height: 1.25; }
.feature small { font-size: 11px; color: var(--muted); line-height: 1.3; }

.contacts { display: flex; flex-wrap: wrap; gap: 10px 22px; justify-content: center; }
.contact { display: inline-flex; align-items: center; gap: 8px; color: var(--text); font-weight: 600; font-size: 14px; }
.contact:hover { color: var(--accent-2); text-decoration: none; }
.pub-contacts-strip {
  padding: 14px; border-radius: 16px; border: 1px solid var(--frame); background: rgba(255, 255, 255, .02);
}
.section-title {
  margin: 30px 0 4px; font-size: 22px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em;
  background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; color: transparent;
  scroll-margin-top: 12px;
}

@media (max-width: 760px) {
  .pub-city { display: none; }
  .hero-card { min-height: 0; }
  .hero-photo { inset: 0; opacity: .38; -webkit-mask-image: none; mask-image: none; }
  .hero-inner { padding: 34px 22px 26px; align-items: center; text-align: center; }
  .hero-cta { align-self: stretch; }
  .hero-card .brand-divider { width: 100%; }
  .wordmark-xl { font-size: 64px; }
  .hero-tagline { font-size: 17px; }
  .features { grid-template-columns: repeat(2, 1fr); }
  .features .feature:last-child { grid-column: 1 / -1; }
}

.filters {
  position: sticky; top: 0; z-index: 5;
  margin: 14px -18px 18px; padding: 12px 18px 14px;
  background: rgba(13, 11, 10, .92); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.filter-block { margin-bottom: 10px; }
.filter-title { font-size: 12px; color: var(--muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .5px; }
.filter-row { display: flex; gap: 12px; align-items: flex-end; }
.filter-row .filter-block { margin-bottom: 0; }
.filter-row .filter-block:first-child { flex: 1; min-width: 0; }
.filter-guests select {
  padding: 10px 12px; border-radius: 12px; background: var(--card); color: var(--text);
  border: 1px solid var(--line); font: inherit; font-weight: 600; color-scheme: dark;
}

.chips-scroll { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.chips-scroll::-webkit-scrollbar { display: none; }
.day-chip input, .seg input { display: none; }
.day-chip span {
  display: flex; flex-direction: column; align-items: center; min-width: 62px;
  padding: 8px 6px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); cursor: pointer;
}
.day-chip small { font-size: 11px; color: var(--muted); }
.day-chip b { font-size: 20px; }
.day-chip input:checked + span { background: linear-gradient(135deg, var(--accent), var(--accent-dark)); border-color: rgba(242, 182, 50, .5); }
.day-chip input:checked + span small { color: rgba(255, 255, 255, .85); }

.seg { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg span {
  display: block; white-space: nowrap; padding: 9px 12px; border-radius: 12px;
  background: var(--card); border: 1px solid var(--line); cursor: pointer; font-weight: 600; font-size: 14px;
}
.seg input:checked + span { background: var(--card-2); border-color: var(--accent); color: var(--accent-2); }

.offers-wrap { display: flex; flex-direction: column; gap: 16px; transition: opacity .2s; }
.offers-wrap.htmx-request { opacity: .5; }
.offer {
  position: relative; overflow: hidden; padding: 18px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--room) 12%, var(--card)), var(--card) 60%);
  border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow);
}
.offer::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--room); box-shadow: 0 0 24px var(--room); }
.offer-gallery {
  display: flex; gap: 8px; margin: -18px -18px 14px; overflow-x: auto; scroll-snap-type: x mandatory;
  scrollbar-width: none;
}
.offer-gallery::-webkit-scrollbar { display: none; }
.offer-gallery img {
  flex: 0 0 100%; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; scroll-snap-align: start; background: var(--bg-2);
}
.offer-gallery img:only-child { flex-basis: 100%; }
@media (min-width: 700px) { .offer-gallery img { flex-basis: 70%; } .offer-gallery img:only-child { flex-basis: 100%; } }
.packages { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.package { overflow: hidden; border-radius: 20px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); }
.package-selected { border-color: var(--gold); box-shadow: 0 0 0 2px rgba(242, 182, 50, .35), var(--shadow); }
.package-photo { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.package-body { padding: 16px 18px; }
.package-body h3 { margin: 0 0 8px; font-size: 19px; }
.package-body ul { margin: 0 0 12px; padding-left: 18px; color: var(--muted); font-size: 14px; }
.package-body li { margin: 3px 0; }
.package-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.package-foot b { color: var(--accent-2); font-size: 18px; }
.package-chosen {
  margin: 0 0 12px; padding: 10px 14px; border-radius: 14px; font-size: 14px;
  background: rgba(242, 182, 50, .1); border: 1px solid rgba(242, 182, 50, .35);
}
.slots-next { margin: 14px 0 0; font-size: 14px; color: var(--muted); }
.slots-next b { color: var(--accent-2); font-size: 16px; }
.slots-taken-note { margin: 10px 0 0; font-size: 12px; color: var(--muted); }
.offer-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.offer-head h2 { margin: 0 0 2px; font-size: 22px; }
.offer-price { text-align: right; display: flex; flex-direction: column; }
.offer-price b { font-size: 20px; }
.offer-desc { color: var(--muted); margin: 10px 0 0; font-size: 14px; }
.offer-empty { color: var(--muted); margin: 14px 0 0; font-size: 14px; }
.offer-rates { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.offer-rates span { font-size: 12px; color: var(--muted); background: var(--bg-2); border-radius: 999px; padding: 5px 10px; }
.offer-rates b { color: var(--text); }
.offer-extra { margin: 12px 0 0; font-size: 13px; color: var(--accent-2); }
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 8px; margin-top: 14px; }
.slot {
  display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0; border-radius: 12px;
  background: var(--bg-2); border: 1px solid var(--line); color: var(--text);
  font-weight: 700; font-variant-numeric: tabular-nums;
}
.slot small { font-size: 11px; font-weight: 500; color: var(--muted); }
.slot:hover { text-decoration: none; border-color: var(--room); background: color-mix(in srgb, var(--room) 25%, var(--bg-2)); }
.slot.slot-taken, .slot.slot-taken:hover {
  cursor: not-allowed; color: var(--muted); opacity: .45;
  background: repeating-linear-gradient(135deg, var(--bg-2) 0 6px, transparent 6px 12px);
  border-style: dashed; border-color: var(--line);
}
.slot.slot-taken span { text-decoration: line-through; }
.slots-legend { display: flex; align-items: center; gap: 6px; margin: 12px 0 0; font-size: 12px; color: var(--muted); }
.slots-legend span { width: 14px; height: 14px; border-radius: 4px; display: inline-block; }
.legend-free { background: var(--bg-2); border: 1px solid var(--room); }
.legend-taken { margin-left: 10px; border: 1px dashed var(--line); opacity: .6;
  background: repeating-linear-gradient(135deg, var(--bg-2) 0 3px, transparent 3px 6px); }

.price-block {
  margin-top: 28px; padding: 20px; border-radius: 20px;
  background: var(--card); border: 1px solid var(--frame); box-shadow: var(--shadow);
}
.price-block h2 {
  display: flex; align-items: center; gap: 10px;
  color: var(--gold); text-transform: uppercase; letter-spacing: .04em; font-size: 18px; font-weight: 800; margin-bottom: 4px;
}
.price-block h3 { font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; margin: 16px 0 6px; }
.price-list { display: flex; flex-direction: column; }
.price-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.price-row:first-child { border-top: 0; }
.price-val { text-align: right; font-weight: 700; color: var(--gold); white-space: nowrap; }
.price-val.free { color: var(--ok); }

.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; margin-top: 16px; }
.gallery-item { margin: 0; border-radius: 14px; overflow: hidden; background: var(--bg-2); border: 1px solid var(--line); }
.gallery-item img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; }
.gallery-item figcaption { padding: 8px 10px; display: flex; flex-direction: column; gap: 2px; font-size: 13px; font-weight: 600; }
.gallery-item small { font-size: 10px; font-weight: 400; }
.gallery-item small a { color: var(--muted); }

.back { display: inline-block; margin: 6px 0 14px; color: var(--muted); }
.pub-card {
  position: relative; overflow: hidden; padding: 20px; margin-bottom: 16px;
  background: var(--card); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow);
}
.summary-card::before, .done::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--room); }
.summary-card h1 { margin-bottom: 14px; }
.summary-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 12px 0; }
.summary-grid div { background: var(--bg-2); border-radius: 12px; padding: 10px 12px; }
.summary-grid small { display: block; font-size: 11px; color: var(--muted); }
.summary-grid b { font-size: 16px; }
.btn-lg { padding: 15px 18px; font-size: 16px; border-radius: 14px; }
.center { text-align: center; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.done { text-align: center; display: flex; flex-direction: column; gap: 10px; }
.done .summary-grid { text-align: left; }
.done-mark {
  width: 64px; height: 64px; margin: 6px auto 4px; border-radius: 50%;
  display: grid; place-items: center; font-size: 32px; font-weight: 700;
  background: rgba(34, 195, 166, .15); color: var(--ok);
}

@media (max-width: 700px) {
  .filters { position: static; backdrop-filter: none; }
}

@media (max-width: 520px) {
  .filter-row { flex-direction: column; align-items: stretch; }
  .filter-guests select { width: 100%; }
}
