/* Общий стиль сайтов udnikov.ru, snow.udnikov.ru, alp.udnikov.ru и сайта Миши Часовского (вариант А «Светлый»)
   Палитра (13.10.2026): фон и графит общие, у каждого раздела свой приглушённый акцент.
   Не больше трёх цветов на разделе: графит + акцент; на главной графит + синий + зелёный. */
:root {
  --bg: #f6f3ee;
  --card: #ffffff;
  --ink: #1f2624;
  --muted: #5c6662;
  --line: #e4ddd2;
  --snow: #2e6a8e;
  --alp: #b8541a;
  --tour: #3d6b45;
  --accent: var(--ink);       /* главная: графит */
  --accent-soft: #edeae5;
  --accent-ink: #ffffff;
  --radius: 18px;
}
body[data-section="snow"] { --accent: var(--snow); --accent-soft: #e5eef4; }
body[data-section="alp"]  { --accent: var(--alp);  --accent-soft: #f7ebe3; }
body[data-section="tour"] { --accent: var(--tour); --accent-soft: #e7efe8; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 72px; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
a { color: inherit; }
img { display: block; max-width: 100%; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }

/* шапка */
.site-header { position: sticky; top: 0; z-index: 10; background: rgba(246,243,238,.94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
/* Наверху страницы шапка выше и знак крупный (полный, как на логотипе для печати); при прокрутке
   (.compact, ставит скрипт в footer.html) шапка плавно сжимается, полный знак сменяется маленьким */
.bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 84px; transition: height .3s ease; }
.logo { display: flex; align-items: center; gap: 12px; font-weight: 800; text-decoration: none; letter-spacing: -.01em; white-space: nowrap;
        font-size: 19px; transition: font-size .3s ease, gap .3s ease; }
.logo .marks { position: relative; width: 60px; height: 60px; flex: none; transition: width .3s ease, height .3s ease; }
.logo .marks svg { position: absolute; inset: 0; width: 100%; height: 100%; transition: opacity .3s ease; }
.logo .mark-small { opacity: 0; }
.site-header.compact .bar { height: 60px; }
.site-header.compact .logo { font-size: 17px; gap: 10px; }
.site-header.compact .logo .marks { width: 40px; height: 40px; }
.site-header.compact .mark-full:not(.mark-keep) { opacity: 0; }
.site-header.compact .mark-small { opacity: 1; }
@media (max-width: 859px) {
  .bar { height: 72px; }
  .logo .marks { width: 52px; height: 52px; }
}
@media (prefers-reduced-motion: reduce) {
  .bar, .logo, .logo .marks, .logo .marks svg { transition: none; }
}
.nav-desktop { display: none; gap: 22px; font-size: 15px; }
.nav-desktop a, .nav-mobile nav a { text-decoration: none; color: var(--muted); }
.nav-desktop a:hover { color: var(--ink); }
body[data-section="snow"] a[data-s="snow"], body[data-section="alp"] a[data-s="alp"],
body[data-section="tour"] a[data-s="tour"] { color: var(--accent); font-weight: 700; }
.tg-small { display: none; font-size: 14px; font-weight: 700; text-decoration: none; color: var(--accent); white-space: nowrap; }
.nav-mobile { position: relative; }
.nav-mobile summary { list-style: none; cursor: pointer; border: 1px solid var(--line); background: var(--card); border-radius: 999px; padding: 6px 14px; font-size: 15px; font-weight: 600; }
.nav-mobile summary::-webkit-details-marker { display: none; }
.nav-mobile[open] summary { background: var(--ink); color: #fff; border-color: var(--ink); }
.nav-mobile nav { position: absolute; right: 0; top: calc(100% + 10px); width: min(280px, calc(100vw - 32px)); background: var(--card);
                  border-radius: 14px; box-shadow: 0 10px 30px rgba(0,0,0,.12); padding: 8px; display: grid; }
.nav-mobile nav a { padding: 12px 14px; border-radius: 10px; font-size: 17px; color: var(--ink); }
.nav-mobile nav a:active, .nav-mobile nav a:hover { background: var(--bg); }
.nav-mobile nav a.accent { color: var(--accent); font-weight: 700; }

/* кнопки */
.btn { display: inline-flex; align-items: center; gap: 10px; background: var(--accent); color: var(--accent-ink);
       font-weight: 700; text-decoration: none; padding: 14px 22px; border-radius: 999px; }
.btn svg { width: 20px; height: 20px; flex: none; }

/* первый экран */
.hero { display: grid; gap: 24px; padding: 28px 0 40px; }
.hero h1 { font-size: clamp(36px, 9vw, 64px); line-height: 1.04; letter-spacing: -.03em; margin: 0 0 14px; }
.hero .lead { font-size: 19px; color: var(--muted); margin: 0 0 24px; max-width: 34ch; }
.hero-photo { border-radius: var(--radius); overflow: hidden; aspect-ratio: 4/5; background: #ddd; position: relative; }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 10px; }

/* разделы */
section { padding: 36px 0; }
h2 { font-size: clamp(26px, 5vw, 36px); letter-spacing: -.02em; line-height: 1.15; margin: 0 0 18px; }
h3 { line-height: 1.25; }
.prose { max-width: 68ch; }
.prose p { margin: 0 0 14px; font-size: 18px; }

/* карточки направлений */
.cards { display: grid; gap: 16px; }
.card { background: var(--card); border-radius: var(--radius); overflow: hidden; text-decoration: none; display: flex; flex-direction: column;
        box-shadow: 0 1px 0 var(--line); transition: transform .15s; }
.card:hover { transform: translateY(-3px); }
.card .pic { aspect-ratio: 16/10; background: #ccc; position: relative; }
.card .pic img { width: 100%; height: 100%; object-fit: cover; }
.card .body { padding: 18px 20px 22px; }
.card h3 { margin: 0 0 6px; font-size: 21px; }
.card p { margin: 0 0 12px; color: var(--muted); font-size: 16px; }
.card .more { font-weight: 700; color: var(--accent); font-size: 15px; }
.card.c-snow .more { color: var(--snow); }
.card.c-tour .more { color: var(--tour); }
.season { position: absolute; left: 12px; top: 12px; z-index: 1; background: rgba(255,255,255,.92); font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; }
.snow { background: linear-gradient(180deg, #cfe3f2 0%, #eef5fa 60%, #ffffff 100%); }
.snow svg { position: absolute; inset: auto 0 0 0; width: 100%; height: 70%; }

/* обо мне, цифры */
.about { display: grid; gap: 24px; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.fact { background: var(--card); border-radius: 14px; padding: 16px; }
.fact b { display: block; font-size: 26px; letter-spacing: -.02em; }
.fact span { color: var(--muted); font-size: 14px; }

/* списки-карточки */
.grid2 { display: grid; gap: 16px; }
.box { background: var(--card); border-radius: var(--radius); padding: 22px 22px 8px; }
.box h3 { margin: 0 0 10px; font-size: 20px; }
/* лицо рядом с именем — инструкторы на сайте клуба */
.who { display: flex; align-items: center; gap: 14px; margin: 0 0 12px; }
.who img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; flex: none; background: #ddd; }
.who h3 { margin: 0; }
.ticks { list-style: none; margin: 0 0 14px; padding: 0; }
.ticks li { position: relative; padding: 0 0 10px 30px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 7px; width: 16px; height: 9px; border-left: 3px solid var(--accent); border-bottom: 3px solid var(--accent); transform: rotate(-45deg); }
.steps { counter-reset: step; list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.steps li { counter-increment: step; background: var(--card); border-radius: 14px; padding: 16px 18px 16px 62px; position: relative; }
.steps li::before { content: counter(step); position: absolute; left: 16px; top: 14px; width: 32px; height: 32px; border-radius: 50%;
                    background: var(--accent); color: #fff; font-weight: 800; display: grid; place-items: center; }
.objects { display: grid; gap: 12px; }
.object { background: var(--card); border-radius: 14px; padding: 18px 20px; }
.object b { display: block; font-size: 18px; margin-bottom: 4px; }
.object span { color: var(--muted); font-size: 16px; }
.faq details { background: var(--card); border-radius: 14px; padding: 16px 18px; margin-bottom: 10px; }
.faq summary { font-weight: 700; cursor: pointer; }
.faq details p { margin: 10px 0 0; }
.photo-row { display: grid; gap: 16px; }
.photo-row img { border-radius: var(--radius); width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4/3; }
.note { background: var(--accent-soft); border-left: 4px solid var(--accent); border-radius: 10px; padding: 14px 16px; }

/* проекты */
.project { background: var(--ink); color: #fff; border-radius: var(--radius); padding: 24px; display: grid; gap: 12px; }
.project h3 { margin: 0 0 6px; }
.project p { margin: 0; color: #c7d0cc; }
.project a { color: #fff; font-weight: 700; }

/* подвал с контактами */
.site-footer { border-top: 1px solid var(--line); padding: 40px 0 48px; margin-top: 24px; }
.contacts { display: grid; gap: 10px; margin-bottom: 24px; }
.contacts a { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--card); border-radius: 14px;
              padding: 16px 18px; text-decoration: none; font-weight: 600; }
.contacts a.primary { background: var(--accent); color: #fff; }
.contacts a span { color: var(--muted); font-weight: 400; font-size: 15px; overflow-wrap: anywhere; text-align: right; }
.contacts a.primary span { color: rgba(255,255,255,.82); }
.copy { color: var(--muted); font-size: 14px; }

@media (min-width: 860px) {
  .nav-desktop, .tg-small { display: flex; }
  .nav-mobile { display: none; }
  .hero { grid-template-columns: 1.1fr .9fr; align-items: center; padding: 56px 0 64px; }
  .cards { grid-template-columns: repeat(3, 1fr); }
  .cards.cards-2 { grid-template-columns: repeat(2, 1fr); }
  .about { grid-template-columns: 1.2fr 1fr; align-items: start; }
  .grid2 { grid-template-columns: 1fr 1fr; }
  .photo-row { grid-template-columns: 1fr 1fr; }
  .project { grid-template-columns: 1fr auto; align-items: center; }
  .contacts { grid-template-columns: repeat(3, 1fr); }
}

/* галерея фото */
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.gallery figure { margin: 0; }
.gallery img { width: 100%; aspect-ratio: 3/4; object-fit: cover; border-radius: 14px; background: #ddd; }
.gallery figcaption { font-size: 14px; color: var(--muted); margin-top: 6px; }
@media (min-width: 860px) { .gallery { grid-template-columns: repeat(3, 1fr); } }
.gallery img { cursor: zoom-in; }
.gallery img:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

/* просмотр фото на весь экран (assets/lightbox.js) */
html.lb-open { overflow: hidden; }
.lightbox { position: fixed; inset: 0; z-index: 45; background: rgba(20, 24, 23, .94); display: grid;
            grid-template-columns: auto 1fr auto; align-items: center; touch-action: pan-y; }
.lightbox[hidden] { display: none; }
.lb-stage { margin: 0; display: grid; justify-items: center; gap: 10px; min-width: 0; padding: 56px 0 calc(16px + env(safe-area-inset-bottom)); }
.lb-stage img { max-width: 100%; max-height: calc(100vh - 140px); max-height: calc(100dvh - 140px); object-fit: contain; border-radius: 8px; user-select: none; -webkit-user-drag: none; }
.lb-stage figcaption { color: #e9ecea; font-size: 15px; display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; text-align: center; padding: 0 12px; }
.lb-count { color: #a9b2ae; }
.lightbox button { border: 0; background: rgba(255,255,255,.12); color: #fff; cursor: pointer; border-radius: 50%; display: grid; place-items: center; }
.lightbox button:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.lb-prev, .lb-next { width: 48px; height: 48px; font-size: 30px; line-height: 1; margin: 0 8px; }
.lb-close { position: absolute; top: calc(10px + env(safe-area-inset-top)); right: 10px; width: 44px; height: 44px; font-size: 28px; line-height: 1; }
@media (max-width: 600px) {
  .lb-prev, .lb-next { position: absolute; bottom: calc(14px + env(safe-area-inset-bottom)); margin: 0; }
  .lb-prev { left: 16px; } .lb-next { right: 16px; }
  .lightbox { grid-template-columns: 1fr; }
  .lb-stage { padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
}

/* смена портретов на главной */
.carousel img { position: absolute; inset: 0; opacity: 0; transition: opacity .8s ease; }
.carousel img.on { opacity: 1; }
.carousel .dots { position: absolute; left: 0; right: 0; bottom: 12px; display: flex; justify-content: center; gap: 8px; z-index: 2; }
.carousel .dots button { width: 10px; height: 10px; padding: 0; border-radius: 50%; border: 0; background: rgba(255,255,255,.55); cursor: pointer; }
.carousel .dots button.on { background: #fff; }

/* черновик: что ещё не заполнено (сайт Миши — пока нет ответов из анкеты) */
.todo { background: #fff3c4; color: #5c4700; border: 1px dashed #c9a227; border-radius: 6px; padding: 1px 6px;
        font-size: .92em; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.note.draft { margin: 20px 0 0; font-size: 15px; }
.card .pic-empty { display: grid; place-items: center; padding: 16px; text-align: center; background: var(--accent-soft); }

/* таблица цен (snow) */
.prices-wrap { overflow-x: auto; margin: 0 0 12px; }
.prices { width: 100%; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.prices th, .prices td { text-align: left; padding: 8px 10px 8px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.prices th { font-size: 13px; color: var(--muted); font-weight: 600; }
.grid2 > * { min-width: 0; }   /* иначе широкая таблица растягивает колонку и страницу на телефоне */
/* сайт клуба: таблица цен из CRM выше соседнего блока — соседа не растягиваем пустым (src/snowclub/assets/prices.js) */
.grid2:has(> .filled) { align-items: start; }
@media (max-width: 480px) { .prices { font-size: 14px; } .prices th, .prices td { padding-right: 8px; } }

/* snow: плашка Снежного клуба под первым экраном — цвет раздела во всю ширину карточки */
.club { display: grid; gap: 0; background: var(--accent); color: #fff; border-radius: var(--radius); overflow: hidden; margin: 8px 0 12px; padding: 0; }
.club-text { padding: 26px 24px 28px; display: grid; gap: 14px; align-content: center; }
.club-eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; opacity: .85; }
.club h2 { margin: 0; color: #fff; }
.club-facts { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.club-facts li { background: rgba(255,255,255,.16); border-radius: 999px; padding: 6px 12px; font-size: 15px; }
.btn-light { background: #fff; color: var(--accent); justify-self: start; }
.club-photo img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4/3; }
@media (min-width: 860px) { .club { grid-template-columns: 1.15fr .85fr; } .club-text { padding: 36px 36px; } .club-photo img { aspect-ratio: auto; } }

/* snow: «Где и когда» — плитки вместо абзацев */
.where { display: grid; gap: 16px; }
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tile { background: var(--card); border-radius: 14px; padding: 14px 16px; display: grid; gap: 4px; align-content: start; min-width: 0; }
.tile span { font-size: 13px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--accent); }
.tile b { font-size: 17px; line-height: 1.3; }
.tile em { font-style: normal; font-size: 14px; color: var(--muted); }
@media (max-width: 420px) { .tiles { grid-template-columns: 1fr; } }
@media (min-width: 860px) { .tiles { grid-template-columns: repeat(3, 1fr); } }

/* snow: цены — клубная строка первой и заметной, примечания — короткими пунктами */
.prices-club td { font-weight: 700; }
.prices-club a { color: var(--accent); }
.price-notes { list-style: none; margin: 4px 0 12px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.price-notes li { background: var(--accent-soft); border-radius: 999px; padding: 6px 12px; font-size: 14px; }
.mini-toggle { border: 0; background: none; padding: 0; font: inherit; color: var(--accent); font-weight: 600; text-align: left; cursor: pointer;
               text-decoration: underline; text-decoration-style: dotted; text-underline-offset: 3px; }
.mini-toggle::after { content: " ▾"; display: inline-block; transition: transform .2s; }
.mini-toggle[aria-expanded="true"]::after { transform: rotate(180deg); }
.mini-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.mini-rows td { background: var(--accent-soft); font-size: 14px; }
.mini-rows td:first-child { padding-left: 14px; }
