/* ═══════════════════════════════════════════════════════════════════════════
   The Avenue Ski Club — avenueski.club
   One stylesheet, no build step. See the direction contract in /index.html.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─────────────────────────────  faces  ───────────────────────────────────
   Display: Source Serif 4, one instance (opsz 20 / wght 600), subset to the
   characters this site sets. The club name and page titles only — an
   established club, not a startup. Everything functional is Inter, whose
   tabular figures carry the rates and the club's year.                     */
@font-face{
  font-family:"Source Serif 4";
  src:url(/fonts/sourceserif4-600.woff2) format("woff2");
  font-weight:600;font-style:normal;font-display:swap;
}
@font-face{
  font-family:"Inter";
  src:url(/fonts/inter-latin-var.woff2) format("woff2");
  font-weight:100 900;font-style:normal;font-display:swap;
}

/* ─────────────────────────────  tokens  ────────────────────────────────── */
:root{
  --paper:#f4f7fa;         /* page ground — cool near-white, a snow-light room */
  --surface:#ffffff;       /* tables, panels, list blocks                     */
  --ink:#122438;           /* navy ink                                        */
  --muted:#55697f;         /* 4.9:1 on paper                                  */
  --rule:#dde5ee;
  --rule-firm:#c6d4e2;
  --tint:#eaf1f8;          /* row hover / selection wash                      */
  --link:#1a4d84;
  --link-hover:#123a66;
  --action:#b5332b;        /* the one action colour — booking, nothing else   */
  --action-hover:#98281f;
  --action-ink:#ffffff;
  --shadow-a:rgba(18,36,56,.10);
  --shadow-b:rgba(181,51,43,.30);
  --photo-bg:#dfe8f1;      /* what a photo sits on while it loads             */

  --display:"Source Serif 4",Georgia,"Times New Roman",serif;
  --sans:"Inter",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;

  --col:47rem;
  --gutter:1.25rem;
  --r:.4rem;
  --ease:cubic-bezier(.16,1,.3,1);
}
@media (min-width:48rem){ :root{ --gutter:2rem } }

@media (prefers-color-scheme:dark){
  :root{
    --paper:#0d1926;
    --surface:#152538;
    --ink:#e8eff7;
    --muted:#9fb3c9;
    --rule:#26384e;
    --rule-firm:#37506c;
    --tint:#1c2f46;
    --link:#8cbde9;
    --link-hover:#aed3f4;
    --action:#c9433a;
    /* hover darkens in both schemes — a lighter dark-mode hover drops white
       below 4.5:1 on the button's own sub-line */
    --action-hover:#b0342c;
    --action-ink:#ffffff;
    --shadow-a:rgba(0,0,0,.45);
    --shadow-b:rgba(0,0,0,.5);
    --photo-bg:#1b2c40;
  }
}

/* ───────────────────  reset + the surfaces we did not draw  ─────────────── */
*,*::before,*::after{box-sizing:border-box}
html{
  -webkit-text-size-adjust:100%;
  scroll-behavior:smooth;
  scrollbar-color:var(--rule-firm) var(--paper);
  scrollbar-width:thin;
  color-scheme:light dark;
}
@media (prefers-reduced-motion:reduce){ html{scroll-behavior:auto} }
body{
  margin:0;
  background:var(--paper);
  color:var(--ink);
  font:400 1rem/1.6 var(--sans);
  font-synthesis-weight:none;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
::selection{background:var(--tint);color:var(--ink)}
:focus-visible{outline:2px solid var(--link);outline-offset:2px;border-radius:2px}
:root{caret-color:var(--link)}
a{color:var(--link);text-underline-offset:.16em;text-decoration-thickness:.06em}
a:hover{color:var(--link-hover)}
img,svg,picture{display:block;max-width:100%}
h1,h2,h3,p,ul,ol,dl,dd,figure,table,blockquote{margin:0}
ul,ol{padding:0;list-style:none}
b,strong{font-weight:600}
::-webkit-scrollbar{width:11px;height:11px}
::-webkit-scrollbar-track{background:var(--paper)}
::-webkit-scrollbar-thumb{background:var(--rule-firm);border-radius:6px;border:3px solid var(--paper)}

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

/* ──────────────────────────  the shell  ────────────────────────────────── */
.wrap{width:min(100% - (var(--gutter) * 2),var(--col));margin-inline:auto}
body.wide{--col:60rem}

/* ──────────────────────────  masthead  ─────────────────────────────────── */
.site{
  background:var(--surface);
  border-bottom:1px solid var(--rule);
}
.site-in{
  display:flex;flex-wrap:wrap;align-items:baseline;
  column-gap:1.75rem;row-gap:.4rem;
  padding-block:.8rem .75rem;
}
.mark{
  font-family:var(--display);font-weight:600;font-size:1.05rem;letter-spacing:.004em;
  color:var(--ink);text-decoration:none;white-space:nowrap;
}
.mark:hover{color:var(--link)}
.nav{display:flex;flex-wrap:wrap;gap:.25rem 1.15rem;margin-left:auto}
.nav a{
  font-size:.86rem;font-weight:500;color:var(--muted);text-decoration:none;
  padding-block:.1rem;border-bottom:1.5px solid transparent;
  transition:color .13s ease,border-color .13s ease;
}
.nav a:hover{color:var(--ink);border-bottom-color:var(--rule-firm)}
.nav a[aria-current="page"]{color:var(--ink);border-bottom-color:var(--ink)}
@media (max-width:36rem){
  .site-in{flex-direction:column;align-items:flex-start;padding-block:.7rem .6rem}
  .nav{margin-left:0;gap:.2rem .9rem}
  .nav a{font-size:.83rem}
}

/* ──────────────────────────  the hero band  ────────────────────────────── */
/* One photograph, ungraded at runtime: the grade is baked into the file so a
   member sees the lodge as it is on a bright snow day. No scrim, no text over
   the picture — the club's name sits on the clean surface underneath.       */
.hero{
  background:var(--photo-bg);
  height:clamp(250px,36vh,320px);
  overflow:clip;
}
.hero img{width:100%;height:100%;object-fit:cover;object-position:50% 42%}
@media (min-width:48rem){
  .hero{height:clamp(340px,31vw,450px)}
  .hero img{object-position:50% 52%}
}
@media (prefers-color-scheme:dark){
  .hero img{filter:brightness(.86) saturate(.92)}
}

/* ──────────────────────────  page titles  ──────────────────────────────── */
.title{padding-block:1.9rem .25rem}
.title.plain{padding-block:2.6rem .25rem}
h1{
  font-family:var(--display);font-weight:600;
  font-size:clamp(2rem,6.6vw,3rem);line-height:1.05;letter-spacing:-.014em;
  text-wrap:balance;
}
.locale{margin-top:.55rem;color:var(--muted);font-size:1.02rem;line-height:1.45;
  max-width:54ch;text-wrap:pretty}

/* ──────────────────────────  generic sections  ─────────────────────────── */
main{padding-bottom:4rem}
.section{margin-top:2.9rem}
.section > * + *{margin-top:.85rem}
h2{
  font-family:var(--display);font-weight:600;font-size:1.4rem;line-height:1.2;
  letter-spacing:-.006em;
}
h3{font-size:.95rem;font-weight:600;letter-spacing:.01em}
.prose{max-width:68ch;text-wrap:pretty}
.prose p + p{margin-top:.85rem}
.lead{font-size:1.08rem;line-height:1.62;max-width:60ch;text-wrap:pretty}
.note{color:var(--muted);font-size:.9rem;line-height:1.55;max-width:66ch;text-wrap:pretty}
/* the quiet form a not-yet-known fact takes on this site */
.tbc{color:var(--muted);font-size:.9rem;font-style:italic}

/* ─────────────────────  the dated state strip  ─────────────────────────── */
.state{
  margin-top:1.5rem;
  background:var(--surface);
  border:1px solid var(--rule);
  border-radius:var(--r);
  padding:.85rem 1.05rem .95rem;
}
.state-head{
  display:flex;flex-wrap:wrap;gap:.2rem .9rem;align-items:baseline;
  justify-content:space-between;
  padding-bottom:.65rem;border-bottom:1px solid var(--rule);
}
.state-season{font-family:var(--display);font-weight:600;font-size:1.02rem}
.state-stamp{font-size:.8rem;color:var(--muted);font-variant-numeric:tabular-nums}
.state-lead{margin-top:.75rem;font-size:1.05rem;line-height:1.45;text-wrap:pretty}
.state-rows{
  margin-top:.6rem;display:grid;grid-template-columns:auto minmax(0,1fr);
  gap:.25rem .9rem;font-size:.93rem;align-items:baseline;
}
.state-rows dt{color:var(--muted);font-size:.83rem;white-space:nowrap}
.state-rows dd{margin:0}
@media (min-width:40rem){
  .state{padding:1rem 1.25rem 1.1rem}
}

/* ────────────────────────  the one action  ─────────────────────────────── */
.book{
  display:flex;align-items:center;gap:.9rem;
  margin-top:1.15rem;
  padding:.95rem 1.15rem;
  background:var(--action);color:var(--action-ink);text-decoration:none;
  border-radius:var(--r);
  box-shadow:0 1px 2px var(--shadow-a),0 10px 22px -10px var(--shadow-b);
  transition:background .14s ease,transform .14s var(--ease),box-shadow .14s ease;
}
.book:hover{
  background:var(--action-hover);color:var(--action-ink);
  transform:translateY(-1px);
  box-shadow:0 2px 3px var(--shadow-a),0 14px 26px -10px var(--shadow-b);
}
.book:active{transform:translateY(0);box-shadow:0 1px 2px var(--shadow-a)}
.book:focus-visible{outline-color:var(--action)}
.book-t{display:block;font-family:var(--display);font-weight:600;
  font-size:1.22rem;line-height:1.2}
.book-d{display:block;font-size:.86rem;line-height:1.35;margin-top:.1rem;opacity:.94}
/* dark mode's --action is lighter, so the sub-line goes to full white:
   .94 white on #c9433a computes 4.48:1 — under AA; full white is 4.86:1 */
@media (prefers-color-scheme:dark){ .book-d{opacity:1} }
.book .go{margin-left:auto;flex:none;transition:translate .14s var(--ease)}
.book:hover .go{translate:3px 0}
@media (min-width:40rem){ .book{max-width:26rem} }

/* ───────  the home lede: the dated state beside the one action  ────────
   Two calm task blocks across the width once there is width to hold them;
   below 62rem they stack in the reading order they already had.          */
@media (min-width:62rem){
  .lede{
    display:grid;grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);
    column-gap:1.5rem;align-items:stretch;
  }
  .lede > .state{margin-top:1.6rem}
  .lede > .book{margin-top:1.6rem;max-width:none}
}

/* ──────────────────────────  compact steps  ────────────────────────────── */
.steps{counter-reset:step;display:grid;gap:.55rem;max-width:62ch}
.steps li{
  counter-increment:step;position:relative;padding-left:1.85rem;
  font-size:.96rem;line-height:1.5;
}
.steps li::before{
  content:counter(step);position:absolute;left:0;top:0;
  font-family:var(--display);font-weight:600;font-size:1rem;color:var(--muted);
  font-variant-numeric:tabular-nums;
}

/* ────────────────────────────  tables  ─────────────────────────────────── */
.tablewrap{overflow-x:auto;background:var(--surface);border:1px solid var(--rule);
  border-radius:var(--r)}
table{
  width:100%;border-collapse:collapse;font-size:.94rem;
  font-variant-numeric:tabular-nums;font-feature-settings:"tnum" 1;
}
caption{
  caption-side:top;text-align:left;
  font-family:var(--display);font-weight:600;font-size:1.05rem;color:var(--ink);
  padding:.85rem 1.05rem .55rem;
}
table.rates caption{border-bottom:1px solid var(--rule)}
thead th{
  text-align:left;font-size:.75rem;font-weight:600;letter-spacing:.07em;
  text-transform:uppercase;color:var(--muted);
  padding:.7rem 1.05rem .5rem;
}
th,td{text-align:left;vertical-align:top;padding:.68rem 1.05rem;
  border-top:1px solid var(--rule)}
thead th{border-top:0}
tbody tr:first-child th,tbody tr:first-child td{border-top:1px solid var(--rule)}
tbody th{font-weight:500;white-space:nowrap;width:1%;padding-right:1rem;color:var(--ink)}
tbody tr:hover th,tbody tr:hover td{background:var(--tint)}
table td b{font-weight:600}
tr.tbc-row th,tr.tbc-row td{color:var(--muted)}
tr.tbc-row th{font-weight:400}
table + .note,.tablewrap + .note{margin-top:.7rem}
.tablewrap + .tablewrap{margin-top:1.1rem}
/* the year table: the date column earns its own rhythm */
table.year tbody th{font-variant-numeric:tabular-nums;font-weight:500}
@media (max-width:30rem){
  table{font-size:.9rem}
  th,td{padding:.62rem .8rem}
  caption,thead th{padding-inline:.8rem}
}

/* ────────────────────────  link lists (routes)  ────────────────────────── */
.routes{background:var(--surface);border:1px solid var(--rule);border-radius:var(--r);
  overflow:hidden}
.routes li + li,.routes .route + .route{border-top:1px solid var(--rule)}
.route{
  display:flex;align-items:center;gap:1rem;
  padding:.85rem 1.05rem;color:inherit;text-decoration:none;
  transition:background .12s ease;
}
.route:hover{background:var(--tint);color:inherit}
.route:focus-visible{outline-offset:-3px}
.route-t{display:block;font-weight:600;font-size:1rem;line-height:1.3}
.route-d{display:block;font-size:.855rem;color:var(--muted);line-height:1.35;margin-top:.08rem}
.route .go{margin-left:auto;color:var(--muted);flex:none;transition:translate .12s var(--ease)}
.route:hover .go{translate:3px 0;color:var(--link)}
/* a row that is not yet a link */
.route.stub{color:var(--muted)}
.route.stub .route-t{font-weight:500;color:var(--muted)}
.route.stub:hover{background:none}
/* at width an even-numbered routes list reads as a two-column index rather
   than a long single file. Opt-in — the committee hub's shorter lists keep
   their single column. */
@media (min-width:62rem){
  .routes.two-up{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
  .routes.two-up li{display:flex}
  .routes.two-up li + li{border-top:0}
  .routes.two-up li:nth-child(n+3){border-top:1px solid var(--rule)}
  .routes.two-up li:nth-child(even){border-left:1px solid var(--rule)}
  .routes.two-up .route{flex:1}
}

/* ─────────────────────────  definition blocks  ─────────────────────────── */
.facts{display:grid;gap:.9rem;max-width:68ch}
.facts > div > dt{font-weight:600;font-size:.95rem}
.facts > div > dd{margin:.1rem 0 0;color:var(--muted);font-size:.95rem;line-height:1.55;
  text-wrap:pretty}
.facts a{color:var(--link)}

/* ─────────────────────────────  gallery  ───────────────────────────────── */
/* align-items:start keeps each figure sized to picture + caption; stretching
   the row would push the caption out of its figure's box */
.gallery{display:grid;gap:1.15rem .5rem;grid-template-columns:repeat(2,minmax(0,1fr));
  align-items:start}
@media (min-width:34rem){ .gallery{gap:1.2rem .6rem;grid-template-columns:repeat(3,minmax(0,1fr))} }
@media (min-width:64rem){ .gallery{grid-template-columns:repeat(4,minmax(0,1fr))} }
.gallery figure{margin:0}
.gallery img{
  width:100%;height:auto;aspect-ratio:4/3;object-fit:cover;
  background:var(--photo-bg);border-radius:.25rem;
}
@media (prefers-color-scheme:dark){ .gallery img{filter:brightness(.88) saturate(.93)} }
.gallery figcaption{margin-top:.35rem;font-size:.8rem;color:var(--muted);line-height:1.4}
.lead-photo{margin:0}
.lead-photo img{width:100%;height:auto;border-radius:var(--r);background:var(--photo-bg)}
@media (min-width:40rem){
  .lead-photo img{aspect-ratio:16/10;height:auto;object-fit:cover;object-position:50% 46%}
}
@media (prefers-color-scheme:dark){ .lead-photo img{filter:brightness(.88) saturate(.93)} }
.lead-photo figcaption{margin-top:.5rem;font-size:.82rem;color:var(--muted)}

/* ══════════════════════════  the rooms page  ═══════════════════════════ */
.level{margin-top:2.9rem;display:grid;row-gap:0}
.level > h2{margin-bottom:.7rem}

/* floor plan — inline SVG, currentColor, zero JS */
.plan{
  background:var(--surface);border:1px solid var(--rule);border-radius:var(--r);
  padding:.7rem;margin-bottom:1rem;
  color:color-mix(in srgb,var(--ink) 55%,var(--surface));
}
.plan svg{width:100%;height:auto}
.plan text{fill:var(--muted);font-family:var(--sans)}
.plan .room-no{fill:var(--ink);font-size:48px;font-weight:600;letter-spacing:.5px}
.plan .room-sub{font-size:20px;letter-spacing:1.2px;font-variant:small-caps}
.plan .label{font-size:21px;letter-spacing:1.2px;font-variant:small-caps}
.plan .label-sm{font-size:19px;letter-spacing:1.2px;font-variant:small-caps}
.plan .label-xs{font-size:16px;letter-spacing:.8px;font-variant:small-caps}
.plan .room-area{fill:var(--link);fill-opacity:0;pointer-events:all;
  transition:fill-opacity .14s ease}
.plan a.room{cursor:pointer}
.plan a.room:hover .room-area{fill-opacity:.11}
.plan a.room:focus-visible{outline:none}
.plan a.room:focus-visible .room-area{fill-opacity:.14;stroke:var(--link);
  stroke-width:4;stroke-opacity:.85}
.plan-note{margin-top:.4rem;font-size:.79rem;color:var(--muted);text-align:center;
  padding-bottom:.1rem}

/* tap a room on the plan → that row lights up, and stays lit on the plan */
body:has(#room-1:target)  #pl-room-1  .room-area,
body:has(#room-2:target)  #pl-room-2  .room-area,
body:has(#room-3:target)  #pl-room-3  .room-area,
body:has(#room-4:target)  #pl-room-4  .room-area,
body:has(#room-5:target)  #pl-room-5  .room-area,
body:has(#room-6:target)  #pl-room-6  .room-area,
body:has(#room-7:target)  #pl-room-7  .room-area,
body:has(#room-8:target)  #pl-room-8  .room-area,
body:has(#room-9:target)  #pl-room-9  .room-area,
body:has(#room-10:target) #pl-room-10 .room-area,
body:has(#room-11:target) #pl-room-11 .room-area,
body:has(#room-12:target) #pl-room-12 .room-area,
body:has(#room-13:target) #pl-room-13 .room-area{fill-opacity:.19}

.rooms{background:var(--surface);border:1px solid var(--rule);border-radius:var(--r);
  overflow:hidden}
.rrow{
  display:grid;grid-template-columns:2.1rem 6.2rem minmax(0,1fr);
  gap:.85rem;align-items:center;padding:.75rem .95rem;
  scroll-margin-top:1.2rem;transition:background .18s ease;
}
.rrow + .rrow{border-top:1px solid var(--rule)}
.rrow:target{background:var(--tint)}
.rno{font-family:var(--display);font-weight:600;font-size:1.5rem;line-height:1;
  color:var(--muted);font-variant-numeric:tabular-nums;text-align:center;
  transition:color .18s ease}
.rrow:target .rno{color:var(--link)}
.rpic{margin:0}
.rpic-wrap{display:block;aspect-ratio:4/3;border-radius:.25rem;overflow:hidden;
  background:var(--photo-bg)}
.rpic-wrap img{width:100%;height:100%;object-fit:cover}
@media (prefers-color-scheme:dark){ .rpic-wrap img{filter:brightness(.9) saturate(.94)} }
.rpic-none{
  display:grid;place-items:center;text-align:center;width:100%;aspect-ratio:4/3;
  padding:.45rem;
  border-radius:.25rem;border:1px dashed var(--rule-firm);background:var(--paper);
}
.rpic-none span{font-size:.8rem;letter-spacing:.01em;color:var(--muted);
  line-height:1.3;text-wrap:balance}
.rbody{min-width:0}
.rname{font-family:var(--display);font-weight:600;font-size:.95rem;margin-bottom:.05rem}
.rbeds{font-weight:600;font-size:.98rem;line-height:1.3}
.rfacts{font-size:.84rem;color:var(--muted);line-height:1.35;margin-top:.08rem}
.also{margin-top:.85rem;font-size:.88rem;color:var(--muted);line-height:1.5;
  max-width:60ch;text-wrap:pretty}

@media (min-width:30rem){
  .rrow{grid-template-columns:2.5rem 9rem minmax(0,1fr);gap:1rem;padding:.85rem 1.05rem}
  .rno{font-size:1.65rem}
}
/* the plan stays beside the rows while you scan them */
@media (min-width:62rem){
  .level{grid-template-columns:23rem minmax(0,1fr);column-gap:2rem}
  .level > h2{grid-column:1 / -1}
  .level > .plan{grid-column:1;grid-row:2 / span 2;position:sticky;top:1.2rem;
    margin-bottom:0;align-self:start}
  .level > .rooms,.level > .also{grid-column:2}
  .level > .also{margin-top:.85rem}
  .rrow{grid-template-columns:2.7rem 10.5rem minmax(0,1fr);gap:1.2rem;padding:.95rem 1.15rem}
}

/* ──────────────────────────────  footer  ───────────────────────────────── */
.site-foot{
  margin-top:3rem;border-top:1px solid var(--rule);
  background:var(--surface);
  padding-block:1.5rem 2rem;
}
.site-foot p{font-size:.85rem;line-height:1.6;color:var(--muted)}
.site-foot p + p{margin-top:.4rem}
.site-foot a{color:var(--muted);text-decoration-color:var(--rule-firm)}
.site-foot a:hover{color:var(--link)}
.site-foot .legal{font-variant-numeric:tabular-nums}

/* ─────────────  one authored moment: the photograph arrives  ───────────── */
@media (prefers-reduced-motion:no-preference){
  .hero img{animation:settle 1.1s var(--ease) both}
}
@keyframes settle{
  from{transform:scale(1.04);filter:blur(8px)}
  to{transform:scale(1);filter:blur(0)}
}
@media (prefers-color-scheme:dark){
  @keyframes settle{
    from{transform:scale(1.04);filter:blur(8px) brightness(.86) saturate(.92)}
    to{transform:scale(1);filter:blur(0) brightness(.86) saturate(.92)}
  }
}

/* capture mode — review screenshots only, never a user-facing state */
html.no-motion .hero img{animation:none!important}
html.no-motion *,html.no-motion *::before,html.no-motion *::after{
  transition:none!important;animation:none!important}
