:root {
  /* База: тёмный фон, белый текст, золото + розовый для редких акцентов */
  --bg: #121212;
  --bg-elevated: #161616;
  --surface: #1a1d24;
  --surface-hover: #22262f;
  --border: rgba(255, 255, 255, 0.08);
  --text: #ffffff;
  --text-muted: #9aa0ae;
  --text-dim: #6d7380;
  /* Палитра: тёмный фон + белый текст + золото; розовый — только акценты в духе hero («собирает») */
  --accent-pink: #d85b8e;
  --accent-gold: #c9b067;
  --gold: var(--accent-gold);
  --neon-pink: var(--accent-pink);
  --radius: 16px;
  --radius-lg: 20px;
  --font-sans: "Montserrat", system-ui, sans-serif;
  --text-body-size: 1rem;
  --text-lead-size: 1rem;
  --text-hero: clamp(1.75rem, 4.2vw, 2.75rem);
  --text-section: clamp(1.55rem, 3.4vw, 2.25rem);
  --text-card-title: clamp(1rem, 2.2vw, 1.125rem);
  --text-eyebrow: 0.6875rem;
  --content-max: min(92vw, 1360px);
  --layout-gutter: clamp(16px, 2.2vw, 28px);
  --section-space-y: clamp(34px, 6vw, 62px);
  --space-2xs: 6px;
  --space-xs: 10px;
  --space-sm: 14px;
  --space-md: 20px;
  --space-lg: 28px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

a,
button {
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  font-size: var(--text-body-size);
  line-height: 1.55;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background:
    radial-gradient(ellipse at 20% 40%, rgba(201, 176, 103, 0.05) 0%, transparent 45%),
    radial-gradient(ellipse at 85% 15%, rgba(216, 91, 142, 0.04) 0%, transparent 42%),
    radial-gradient(ellipse at 50% 90%, rgba(201, 176, 103, 0.04) 0%, transparent 48%);
  pointer-events: none;
  z-index: 0;
}

.main,
.hero {
  position: relative;
  z-index: 1;
}

/* Первая секция под hero — меньший верхний отступ, чтобы блоки визуально ближе */
.main > .section:first-of-type {
  padding-top: clamp(22px, 4.8vw, 46px);
}

.section.is-temporarily-hidden[hidden],
.is-temporarily-hidden[hidden] {
  display: none !important;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

code {
  font-size: 0.88em;
  background: rgba(0, 0, 0, 0.35);
  padding: 3px 8px;
  border-radius: 8px;
  border: 1px solid var(--border);
  color: var(--accent-gold);
}

strong {
  color: var(--text);
  font-weight: 600;
}

/* ——— Hero ——— */
.hero {
  padding-top: max(16px, env(safe-area-inset-top, 0px));
  padding-right: max(var(--layout-gutter), env(safe-area-inset-right, 0px));
  padding-bottom: clamp(44px, 6vw, 64px);
  padding-left: max(var(--layout-gutter), env(safe-area-inset-left, 0px));
  background: linear-gradient(180deg, var(--bg-elevated) 0%, var(--bg) 55%);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  max-width: var(--content-max);
  margin: 0 auto 28px;
  flex-wrap: wrap;
}

.logo {
  font-family: var(--font-sans);
  font-weight: 800;
  color: var(--text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  max-width: 100%;
}

.brand-mark {
  display: inline-flex;
  align-items: baseline;
  flex-wrap: wrap;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.text-brand-light {
  color: #eceef4;
  font-weight: 800;
}

.brand-mark--footer {
  font-size: clamp(1.15rem, 3vw, 1.35rem);
  display: inline-block;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 10px;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 2px 2px;
}

.nav-links a:hover {
  color: var(--accent-gold);
}

.hero-inner {
  max-width: var(--content-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(240px, 320px);
  gap: clamp(18px, 2.2vw, 34px);
  align-items: start;
}

/* Логотип CoffeeFriends в шапке = тот же кегль/интерлиньяж, что и H1 hero */
.type-hero,
.hero-copy h1,
.nav .logo .brand-mark--site {
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: var(--text-hero);
  line-height: 1.14;
  letter-spacing: -0.02em;
}

.type-hero,
.hero-copy h1 {
  margin: 0 0 18px;
  max-width: 30ch;
  color: var(--text);
}

/* Единый «героический» стиль заголовков: как строка про кофе на 2 и 11 этажах */
.type-display,
.section-head h2,
.feedback-copy h2 {
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: var(--text-section);
  line-height: 1.14;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
  color: var(--text);
}

.type-display-sub {
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: var(--text-card-title);
  line-height: 1.18;
  letter-spacing: -0.02em;
  color: var(--text);
}

.text-accent-pink,
.text-neon-pink {
  color: var(--accent-pink);
  font-weight: 800;
}

.text-accent-gold,
.text-gold {
  color: var(--accent-gold);
  font-weight: 800;
}

.hero-value {
  margin: 0 0 var(--space-sm);
  max-width: min(62ch, 100%);
  color: var(--text);
  font-size: clamp(0.9375rem, 1.55vw, 1.08rem);
  font-weight: 600;
  line-height: 1.48;
}

.hero-copy .hero-value {
  margin-bottom: 10px;
}

.subtitle {
  margin: 0 0 var(--space-md);
  max-width: min(62rem, 100%);
  color: var(--text-muted);
  font-size: clamp(0.9375rem, 1.35vw, 1.0625rem);
  font-weight: 500;
}

.hero-cta {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 260px));
  gap: 8px 12px;
  max-width: none;
  width: 100%;
  margin-bottom: 0;
}

.hero-cta .btn {
  width: 100%;
  min-width: 0;
  padding-left: 16px;
  padding-right: 16px;
}

@media (max-width: 440px) {
  .hero-cta {
    grid-template-columns: 1fr;
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 14px 22px;
  min-height: 48px;
  border-radius: 12px;
  border: 1px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  color: #0a0c14;
  background: linear-gradient(135deg, var(--gold), #f0d878);
  box-shadow: 0 0 24px rgba(201, 176, 103, 0.28);
}

.btn-primary:hover {
  box-shadow: 0 0 32px rgba(201, 176, 103, 0.42);
}

.btn-ghost {
  color: var(--text);
  background: transparent;
  border-color: var(--border);
}

.btn-ghost:hover {
  border-color: rgba(201, 176, 103, 0.45);
  color: var(--accent-gold);
}

.hero-visual {
  display: flex;
  justify-content: flex-end;
  padding-top: 4px;
}

.neon-frame {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: 0 14px 44px rgba(0, 0, 0, 0.38);
}

.hero-card {
  background: var(--surface);
  padding: 18px 16px 16px;
  max-width: 300px;
  width: 100%;
}

.hero-card-label {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
}

.hero-mood-intro {
  margin: 10px 0 6px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
}

.hero-mood-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hero-mood-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--text-muted);
}

.hero-mood-ic {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(201, 176, 103, 0.88);
}

.hero-mood-ic svg {
  display: block;
}

.type-pullquote {
  margin: 10px 0 0;
  font-family: var(--font-sans);
  font-style: normal;
  font-weight: 500;
  font-size: 0.9375rem;
  line-height: 1.45;
  color: var(--text-muted);
  letter-spacing: 0.01em;
}

/* ——— Sections ——— */
.section {
  max-width: var(--content-max);
  margin: 0 auto;
  padding-top: var(--section-space-y);
  padding-bottom: clamp(32px, 5vw, 44px);
  padding-left: max(var(--layout-gutter), env(safe-area-inset-left, 0px));
  padding-right: max(var(--layout-gutter), env(safe-area-inset-right, 0px));
}

.section--tail {
  padding-bottom: max(48px, calc(32px + env(safe-area-inset-bottom, 0px)));
}

.section-head {
  margin-bottom: 22px;
}

.section-head--tight {
  margin-bottom: 16px;
}

.eyebrow {
  margin: 0 0 8px;
  font-size: var(--text-eyebrow);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(201, 176, 103, 0.72);
}

.hours-strip {
  padding: 0;
  width: 100%;
  max-width: none;
  overflow: hidden;
}

.hours-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.hours-table caption {
  padding: 0;
}

.hours-table tbody tr {
  border-bottom: 1px solid var(--border);
}

.hours-table tbody tr:last-child {
  border-bottom: none;
}

.hours-table th {
  text-align: left;
  font-weight: 600;
  color: var(--text-muted);
  padding: 14px 18px;
  width: 38%;
  vertical-align: middle;
}

.hours-table td {
  text-align: right;
  font-weight: 700;
  color: var(--accent-gold);
  padding: 14px 18px;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  vertical-align: middle;
}

.hours-table__closed {
  color: var(--text-dim);
  font-weight: 600;
  letter-spacing: 0;
}

.lead {
  margin: 0;
  font-size: var(--text-lead-size);
  color: var(--text-muted);
  font-weight: 500;
  max-width: 52rem;
}

.lead--muted {
  font-size: 0.9375rem;
  color: var(--text-dim);
  font-weight: 400;
}

.section-feedback .lead {
  color: var(--text-muted);
}

.surface-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

/* Route */
.section-route {
  padding-bottom: clamp(14px, 2.4vw, 24px);
}

.section.section-drinks {
  padding-top: clamp(14px, 2.6vw, 32px);
}

.route-layout {
  display: block;
}

.route-banner {
  margin: 0 0 12px;
  padding: 0;
  overflow: hidden;
  background: #05060a;
}

.route-banner img {
  width: 100%;
  height: auto;
  display: block;
}

/* Route: один блок, шаги разделены линией */
.route-panel {
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
}

.route-step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 6px 12px;
  align-items: start;
  padding: 10px 14px;
}

.route-step + .route-step {
  border-top: 1px solid var(--border);
}

.route-step__body {
  min-width: 0;
}

.route-step h3 {
  margin: 0 0 3px;
  font-size: clamp(0.9375rem, 2.1vw, 1.0625rem);
  line-height: 1.2;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(201, 176, 103, 0.14);
  border: 1px solid rgba(201, 176, 103, 0.38);
  color: var(--accent-gold);
  font-weight: 800;
  font-size: 0.75rem;
  margin: 0;
}

.route-step p {
  margin: 0;
  font-size: 0.8125rem;
  line-height: 1.4;
  color: var(--text-muted);
}

/* Drinks table */
.chart-wrap {
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  background: var(--surface);
  border-radius: var(--radius-lg);
}

.chart-wrap .drinks-table {
  min-width: 640px;
}

.drinks-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.drinks-table thead {
  background: linear-gradient(90deg, rgba(24, 24, 26, 0.98), rgba(28, 28, 32, 0.99));
  border-bottom: 1px solid var(--border);
}

.drinks-table th {
  text-align: left;
  font-weight: 800;
  font-size: 0.6875rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 16px 18px;
}

.drinks-table__th-icon {
  width: 56px;
  min-width: 56px;
  max-width: 64px;
  text-align: center;
  padding-left: 12px;
  padding-right: 12px;
}

.drinks-table th:nth-child(4) {
  text-align: right;
  width: 22%;
  min-width: 100px;
}

.drinks-table tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background 0.12s ease;
}

.drinks-table tbody tr:hover {
  background: var(--surface-hover);
}

.drinks-table tbody tr:last-child {
  border-bottom: none;
}

.drinks-table td {
  padding: 14px 18px;
  vertical-align: middle;
}

.drinks-table__cell-icon {
  width: 56px;
  min-width: 56px;
  max-width: 64px;
  text-align: center;
  padding: 12px 10px;
  vertical-align: middle;
}

.drinks-table__icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
}

.drinks-table td:nth-child(2) {
  font-weight: 600;
  color: var(--text);
}

.drinks-table td:nth-child(3) {
  color: var(--text-muted);
  font-size: 0.875rem;
}

.drinks-table td:nth-child(4) {
  text-align: right;
  font-weight: 700;
  color: var(--accent-gold);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.icon-ht--table {
  display: block;
  flex-shrink: 0;
  color: var(--accent-gold);
  opacity: 0.95;
  transition: color 0.18s ease, opacity 0.18s ease;
}

.drinks-table tbody tr:hover .icon-ht--table {
  color: var(--accent-pink);
  opacity: 1;
}

.icon-ht__hud {
  opacity: 0.85;
}

/* Узкий экран: без горизонтального скролла — колонка «кратко» скрыта, таблица на всю ширину */
@media (max-width: 720px) {
  .chart-wrap {
    overflow-x: visible;
  }

  .chart-wrap .drinks-table {
    min-width: 0;
    table-layout: fixed;
  }

  .drinks-table__col-detail {
    display: none !important;
  }

  .drinks-table th,
  .drinks-table td {
    padding: 11px 8px;
  }

  .drinks-table thead th {
    font-size: 0.625rem;
    letter-spacing: 0.1em;
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .drinks-table__th-icon,
  .drinks-table__cell-icon {
    width: 38px;
    min-width: 38px;
    max-width: 42px;
    padding-left: 6px;
    padding-right: 6px;
  }

  .drinks-table th:nth-child(4),
  .drinks-table td:nth-child(4) {
    width: 32%;
    min-width: 0;
    max-width: none;
    padding-right: 10px;
  }

  .drinks-table td:nth-child(4) {
    font-size: 0.8125rem;
  }

  .drinks-table td:nth-child(2) {
    font-size: 0.8125rem;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
  }

  .drinks-table .icon-ht--table {
    width: 26px;
    height: 26px;
  }

  .drinks-table__icon-wrap img.icon-ht--table {
    width: 26px;
    height: 26px;
    max-width: 26px;
    object-fit: contain;
  }
}

/* Gallery by floor */
.gallery-floors {
  margin-top: 8px;
}

.gallery-floor-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(12px, 1.8vw, 22px);
  align-items: start;
}

.gallery-floor-col {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
}

.gallery-floor-head {
  display: flex;
  justify-content: center;
  margin-bottom: 14px;
}

.floor-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 0;
  margin: 0;
  border: none;
  background: none;
  border-radius: 0;
}

.floor-badge.floor-2,
.floor-badge.floor-11 {
  color: var(--accent-gold);
}

.gallery-masonry {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(clamp(150px, 15vw, 220px), 1fr));
  gap: 10px;
}

.gallery-masonry--compact {
  grid-template-columns: repeat(auto-fit, minmax(clamp(130px, 13vw, 190px), 1fr));
}

.gallery-tile {
  margin: 0;
  border-radius: 12px;
  overflow: hidden;
  border: none;
  background: transparent;
  aspect-ratio: 4 / 3;
}

.gallery-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-empty {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-dim);
  line-height: 1.5;
}

.gallery-other {
  margin-top: 18px;
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
}

.gallery-other-title {
  margin: 0 0 6px;
  font-weight: 600;
  color: var(--gold);
  font-size: 0.9375rem;
}

.gallery-other-hint {
  margin: 0 0 14px;
  font-size: 0.8125rem;
  color: var(--text-dim);
}

/* Jokes */
.jokes-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  margin: -4px 0 var(--space-sm);
}

.jokes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(10px, 1.4vw, 18px);
  align-items: stretch;
}

.jokes-grid.jokes-grid--expanded {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
}

.jokes-controls {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  max-width: min(340px, 100%);
}

.jokes-page-indicator {
  flex: 1;
  min-width: 0;
  text-align: center;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--text-dim);
}

.jokes-show-all {
  font-size: 0.8125rem;
  padding: 10px var(--space-md);
  flex-shrink: 0;
}

.jokes-next {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid rgba(201, 176, 103, 0.35);
  background: rgba(26, 29, 36, 0.92);
  color: var(--accent-gold);
  font: inherit;
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.jokes-next:hover {
  border-color: rgba(201, 176, 103, 0.65);
  color: #e2ce8d;
}

.joke-card.is-hidden {
  display: none;
}

.joke-card {
  padding: 18px 20px;
  min-height: 100%;
  display: flex;
  align-items: center;
}

.joke-card p {
  margin: 0;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.52;
  color: var(--text-muted);
}

.joke-card__label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(201, 176, 103, 0.75);
}

.joke-card--so {
  position: relative;
  padding-left: 22px;
}

.joke-card--so::before {
  content: "";
  position: absolute;
  left: 0;
  top: 14px;
  bottom: 14px;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: var(--accent-gold);
  opacity: 0.55;
}

/* Coffee calendar (мес. сетки) */
.calendar-legend {
  margin: -6px 0 18px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  gap: 8px;
}

.calendar-legend__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-gold);
  box-shadow: 0 0 8px rgba(201, 176, 103, 0.45);
}

.calendar-status:not(.visually-hidden) {
  margin: 12px 0 0;
  padding: 12px 16px;
  border-radius: var(--radius);
  border: 1px solid rgba(201, 176, 103, 0.28);
  background: rgba(201, 176, 103, 0.06);
  color: var(--text-muted);
  font-size: 0.875rem;
}

#coffee-calendar {
  position: relative;
}

.coffee-calendar-root {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(292px, 1fr));
  gap: 16px;
  align-items: start;
}

.cal-month {
  padding: 14px 14px 16px;
  min-width: 0;
}

.cal-month__head {
  margin: 0 0 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.cal-month__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.cal-grid__weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
  margin-bottom: 6px;
}

.cal-grid__wd {
  text-align: center;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 2px 0;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.cal-cell--pad {
  min-height: 38px;
}

.cal-day {
  position: relative;
  min-height: 40px;
  border-radius: 10px;
  border: 1px solid transparent;
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: 6px;
  color: var(--text-muted);
  background: rgba(0, 0, 0, 0.12);
}

.cal-day--empty {
  pointer-events: none;
}

.cal-day--weekend.cal-day--empty {
  opacity: 0.38;
}

.cal-day--fact {
  cursor: help;
  color: #f2ead8;
  background: linear-gradient(165deg, rgba(201, 176, 103, 0.18), rgba(26, 29, 36, 0.65));
  border-color: rgba(201, 176, 103, 0.35);
  box-shadow: 0 0 0 1px rgba(201, 176, 103, 0.06);
  -webkit-tap-highlight-color: transparent;
}

.cal-day--fact.cal-day--weekend {
  opacity: 0.94;
}

.cal-day--fact:hover,
.cal-day--fact:focus-visible {
  outline: none;
  border-color: rgba(201, 176, 103, 0.55);
  box-shadow: 0 0 0 2px rgba(201, 176, 103, 0.12);
  color: #fff;
}

.cal-day__num {
  line-height: 1.2;
}

.cal-day__dot {
  position: absolute;
  bottom: 5px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent-gold);
  box-shadow: 0 0 6px rgba(201, 176, 103, 0.5);
}

.cal-tooltip {
  position: fixed;
  z-index: 5000;
  max-width: min(380px, calc(100vw - 24px));
  padding: 14px 16px 16px;
  border-radius: var(--radius);
  background: linear-gradient(165deg, rgba(28, 28, 32, 0.98), rgba(14, 14, 18, 0.99));
  border: 1px solid rgba(201, 176, 103, 0.35);
  box-shadow:
    0 16px 40px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(255, 255, 255, 0.04);
  pointer-events: none;
}

.cal-tooltip.cal-tooltip--interactive {
  pointer-events: auto;
}

.cal-tooltip__title {
  display: block;
  margin: 0 0 8px;
  font-size: 0.9375rem;
  font-weight: 800;
  color: var(--accent-gold);
  letter-spacing: 0.02em;
}

.cal-tooltip__text {
  margin: 0;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--text-muted);
}

.cal-tooltip[hidden] {
  display: none !important;
}

.cal-tooltip.cal-tooltip--dock {
  position: absolute;
  left: 12px !important;
  right: 12px !important;
  top: auto !important;
  bottom: max(12px, env(safe-area-inset-bottom, 0px)) !important;
  width: auto;
  max-width: none;
  pointer-events: auto;
}

.cal-tooltip__close {
  display: none;
  margin-top: 12px;
  width: 100%;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  font: inherit;
  font-weight: 700;
  font-size: 0.8125rem;
  cursor: pointer;
}

.cal-tooltip.cal-tooltip--dock .cal-tooltip__close {
  display: block;
}

@media (max-width: 640px) {
  .coffee-calendar-root {
    grid-template-columns: 1fr;
  }
}

.stories-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.story-card {
  padding: 22px;
}

.story-card h3,
.feedback-aside h3 {
  margin: 0 0 10px;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.52;
  color: var(--accent-gold);
}

.story-card p {
  margin: 0;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.52;
  color: var(--text-muted);
}

/* Feedback */
/* Feedback: без лишнего «воздуха» перед следующей секцией */
.section-feedback {
  padding-bottom: clamp(24px, 4vw, 36px);
}

.section-stories {
  padding-top: clamp(22px, 4vw, 36px);
}

.section-stories .lead--muted {
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.52;
  color: var(--text-muted);
}

.feedback-layout {
  display: grid;
  grid-template-columns: 1fr minmax(220px, 300px);
  gap: 28px 36px;
  padding: 0;
  background: transparent;
}

.feedback-copy .lead {
  margin-bottom: 18px;
}

.feedback-note {
  margin: 14px 0 0;
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.52;
  color: var(--text-muted);
}

.feedback-aside {
  padding: 22px;
}

.feedback-aside ul {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--text-muted);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.52;
}

.feedback-aside li {
  margin-bottom: 8px;
}

/* Footer */
.footer {
  margin-top: 0;
  padding: 34px max(20px, env(safe-area-inset-right, 0px)) max(34px, env(safe-area-inset-bottom, 0px)) max(20px, env(safe-area-inset-left, 0px));
  background: #05060a;
  border-top: 1px solid var(--border);
  color: var(--text);
}

.footer-inner {
  max-width: var(--content-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.footer-brand .brand-mark--footer {
  margin: 0;
  display: inline-block;
}

.footer-address {
  margin: 10px 0 0;
  font-size: var(--text-eyebrow);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.footer-links p {
  margin: 0 0 6px;
  font-size: 0.9375rem;
}

.footer-links a {
  color: var(--gold);
  font-weight: 600;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--accent-gold);
}

.footer-top {
  grid-column: 1 / -1;
  margin-top: 2px;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding-top: 4px;
}

.footer-top:hover {
  color: var(--accent-gold);
}

@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    justify-content: flex-start;
  }

  .hero-card {
    max-width: min(22rem, 100%);
  }

  .stories-list,
  .jokes-grid {
    grid-template-columns: 1fr 1fr;
  }

  .gallery-floor-grid {
    grid-template-columns: 1fr;
  }

  .feedback-layout {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 901px) {
  .hero-visual {
    display: none;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .type-hero,
  .hero-copy h1 {
    max-width: min(32ch, 100%);
  }

  .subtitle {
    max-width: min(70rem, 100%);
  }

  .hero-value {
    max-width: min(54ch, 100%);
  }

  .route-banner {
    margin-bottom: 0;
  }

  .route-panel {
    display: none;
  }
}

@media (max-width: 640px) {
  .type-hero,
  .hero-copy h1 {
    max-width: none;
  }

  /* Явно один clamp для hero и логотипа — визуально совпадают на телефоне */
  .type-hero,
  .hero-copy h1,
  .nav .logo .brand-mark--site {
    font-size: clamp(1.65rem, 6.8vw, 2.45rem);
    line-height: 1.12;
  }

  .nav {
    flex-direction: column;
    align-items: flex-start;
    row-gap: 6px;
  }

  .nav-links {
    row-gap: 0;
    column-gap: 10px;
  }

  .stories-list,
  .jokes-grid {
    grid-template-columns: 1fr;
  }

  .jokes-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .jokes-controls {
    max-width: none;
  }

  .jokes-show-all {
    width: 100%;
    justify-content: center;
  }

  .feedback-layout {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 0;
  }

  .feedback-aside {
    padding: 22px 18px;
  }

  .feedback-mail-btn {
    width: 100%;
    min-height: 48px;
    padding: 14px 16px;
    text-align: center;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
  }
  .footer {
    padding-top: 22px;
    padding-bottom: max(20px, env(safe-area-inset-bottom, 0px));
  }

  .footer-inner {
    gap: 10px;
  }

  .footer-top {
    margin-top: -2px;
    min-height: 32px;
    padding-top: 0;
  }
}
