/* Shoot for the Stars
   Gloock carries the display lines; Switzer carries everything else.
   White page, one photograph, one black blueprint. */

@font-face { font-family: "Gloock"; src: url("fonts/gloock-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Switzer"; src: url("fonts/switzer-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Switzer"; src: url("fonts/switzer-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --white: #ffffff;
  --black: #000000;
  --grey: #737373;
  --grey-on-black: #8c8c8c;
  --court: #243c2f;        /* the court green from the photograph, deepened */
  --on-court: #a7bcae;     /* secondary text on court green */
  --rule-on-court: rgba(255,255,255,.22);
  --serif: "Gloock", "Times New Roman", serif;
  --sans: "Switzer", "Helvetica Neue", Arial, sans-serif;
  --pad: clamp(1.25rem, 3.6vw, 3.5rem);
  /* one micro-label style for every small piece of chrome */
  --micro-size: 11.5px;
  --micro-track: .2em;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--white);
  color: var(--black);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  font-kerning: normal;
}

a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .25em; }
a:focus-visible, button:focus-visible { outline: 1px solid currentColor; outline-offset: 5px; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: var(--pad); top: 1rem; z-index: 10; background: #fff; color: #000; padding: .5rem .75rem; }

/* ——— Cover ——— */
.cover {
  position: relative;
  height: 100svh;
  min-height: 600px;
  overflow: hidden;
  color: var(--white);
  background: #111;
}
.cover img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 50% 58%;
}
.cover::after {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 60% 40% at 50% 50%, rgba(0,0,0,.30), rgba(0,0,0,0) 100%),
    linear-gradient(to bottom, rgba(0,0,0,.35), rgba(0,0,0,0) 25%),
    rgba(0,0,0,.42);
  pointer-events: none;
}
.bar {
  position: absolute; z-index: 3;
  top: 0; left: 0; right: 0;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  margin: 0 var(--pad);
  padding: 1.35rem 0;
  border-bottom: 1px solid rgba(255,255,255,.28);
}
.bar nav { display: flex; gap: 2.75rem; }
.bar-cta { justify-self: end; padding: .7rem 1.15rem .68rem; border: 1px solid rgba(255,255,255,.7); transition: background .2s ease, color .2s ease; }
.bar-cta:hover { background: #fff; color: #000; text-decoration: none; }
.bar nav a:hover { text-decoration: none; opacity: .7; }
.cover-type {
  position: absolute; z-index: 2;
  inset: 0;
  pointer-events: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: 0 var(--pad);
}
.cover-type h1 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(3.2rem, 8.2vw, 8.75rem);
  line-height: 1;
  letter-spacing: -.015em;
  text-shadow: 0 2px 40px rgba(0,0,0,.3);
}
.cover-type p {
  margin: clamp(1.6rem, 2.6vw, 2.4rem) 0 0;
  font-size: 12.5px;
  letter-spacing: .34em;
  padding-left: .34em; /* balance the trailing tracking so the line centres optically */
  opacity: .95;
}

/* Micro labels: small, spaced capitals. Used for every piece of chrome so the page reads as one system. */
.bar, .cover-type p, .kicker, .total span, .figures dt, .beliefs h2,
.label-no, .label-data dt, .schedule caption, .schedule thead th, .end {
  font-family: var(--sans);
  font-size: var(--micro-size);
  font-weight: 500;
  letter-spacing: var(--micro-track);
  text-transform: uppercase;
  line-height: 1.4;
}

/* ——— Record ——— */
.record { padding: clamp(9rem, 24vh, 16rem) var(--pad) clamp(8rem, 22vh, 14rem); background: var(--court); color: var(--white); }
.first {
  margin: 0 auto;
  text-align: center;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.1rem, 4.4vw, 4.5rem);
  line-height: 1.06;
  letter-spacing: -.02em;
}

/* Three figures: equal columns, label above, figure below, both centred, one rule above and below. */
.figures {
  margin: clamp(7rem, 18vh, 11rem) auto 0;
  max-width: 1080px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid rgba(255,255,255,.7);
  border-bottom: 1px solid rgba(255,255,255,.7);
}
.figures div {
  display: flex; flex-direction: column; align-items: center;
  padding: clamp(2.5rem, 5.5vh, 3.5rem) 1rem;
  text-align: center;
}
.figures dt { color: var(--on-court); }
.figures dd {
  margin: 1.1rem 0 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.5rem, 4vw, 4rem);
  line-height: 1;
  letter-spacing: -.02em;
  font-variant-numeric: lining-nums;
}
.beliefs {
  margin: clamp(7rem, 18vh, 11rem) auto 0;
  max-width: 1080px;
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  column-gap: 2rem;
}
.beliefs h2 { margin: 0; padding-top: 2.1rem; color: var(--on-court); }
.beliefs ol { container-type: inline-size; list-style: none; margin: 0; padding: 0; border-top: 1px solid rgba(255,255,255,.7); }
.beliefs li {
  padding: 1.5rem 0 1.6rem;
  border-bottom: 1px solid var(--rule-on-court);
  font-family: var(--serif);
  font-weight: 400;
  /* One line each: the longest belief is about 15.7 em wide, so size to the column. */
  font-size: min(2.75rem, 6.2cqi);
  line-height: 1.1;
  letter-spacing: -.018em;
  white-space: nowrap;
}

/* ——— Court ——— */
.court {
  background: var(--black);
  color: var(--white);
  padding: clamp(6rem, 16vh, 10rem) var(--pad) clamp(6rem, 14vh, 9rem);
}
.court-head {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #2a2a2a;
  margin-bottom: clamp(3rem, 8vh, 5rem);
}
.kicker { margin: 0 0 1.1rem; color: var(--grey-on-black); }
.court-head h2 {
  margin: 0;
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(2rem, 3.6vw, 3.4rem); line-height: 1; letter-spacing: -.02em;
}
.total { margin: 0; text-align: right; font-family: var(--serif); font-weight: 400; font-size: clamp(1.6rem, 2.4vw, 2.2rem); line-height: 1; }
.total span { display: block; margin-bottom: .75rem; color: var(--grey-on-black); }

.court-grid {
  display: grid;
  grid-template-columns: minmax(15rem, 3fr) minmax(0, 9fr);
  column-gap: clamp(2rem, 4vw, 4.5rem);
  align-items: center;
}
.label-no { margin: 0 0 1.25rem; color: var(--grey-on-black); font-variant-numeric: tabular-nums; }
.label h3 {
  margin: 0;
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.9rem, 2.6vw, 2.6rem); line-height: 1.04; letter-spacing: -.015em;
  min-height: 2.08em;
}
.label-desc { margin: 1rem 0 0; color: #bdbdbd; min-height: 4.5em; max-width: 22em; }
.label-data { margin: 1.5rem 0 0; border-top: 1px solid #3a3a3a; }
.label-data div { display: grid; grid-template-columns: 5rem 1fr; align-items: baseline; padding: .75rem 0; border-bottom: 1px solid #242424; }
.label-data dt { color: var(--grey-on-black); }
.label-data dd { margin: 0; font-variant-numeric: tabular-nums; }
.label [data-f] { transition: opacity .16s ease; }
.label.is-swapping [data-f] { opacity: 0; }

.stage { position: relative; }
.drawing { display: block; width: 100%; height: auto; }

.drawing .ln { fill: none; stroke: #fff; stroke-width: 1.2; vector-effect: non-scaling-stroke; stroke-linecap: square; }
.drawing .ln-outer { stroke-width: 2; }
.drawing .ln-thin { stroke-width: .7; }
.drawing .ln-dash { stroke-dasharray: 6 6; }
.drawing .ln-axis { stroke-width: .6; stroke-dasharray: 18 7 2 7; stroke: #5e5e5e; fill: none; vector-effect: non-scaling-stroke; }
.drawing .dim-text { font-family: var(--sans); font-size: 36px; fill: #fff; letter-spacing: .02em; }

.drawing .paving { fill: url(#paving); opacity: .07; }
.drawing .border-fill { fill: url(#hatch); opacity: .22; }
.drawing .tiles { fill: url(#tile); opacity: .09; }
.drawing .key-fill { fill: url(#hatch); opacity: .3; }
.drawing .basket-fill { fill: #000; }
.drawing .paving, .drawing .border-fill, .drawing .tiles, .drawing .key-fill { transition: opacity .25s ease, fill .25s ease; }

/* Lines sit in a difference blend: white on the black field, black over a solid white fill. */
.drawing .lines { mix-blend-mode: difference; }

.drawing .lyr, .drawing .callout { transition: opacity .25s ease; }
.drawing[data-active] .lyr:not(.is-on), .drawing[data-active] .callout:not(.is-on) { opacity: .2; }
.drawing[data-active="install"] .paving { opacity: .45; }
.drawing[data-active="border"] .border-fill { fill: #fff; opacity: 1; }
.drawing[data-active="surface"] .tiles { opacity: .45; }
.drawing[data-active="keys"] .key-fill { fill: #fff; opacity: 1; }
.drawing[data-active="baskets"] .basket-fill { fill: #fff; }
.drawing .lyr.is-on .ln { stroke-width: 2.6; }
.drawing .lyr.is-on .ln-thin { stroke-width: 1.6; }

.callout .tag { fill: #000; stroke: #fff; stroke-width: 1; vector-effect: non-scaling-stroke; }
.callout .dot { fill: #fff; }
.callout .tag-text { font-family: var(--sans); font-size: 36px; fill: #fff; font-variant-numeric: tabular-nums; }
.callout.is-on .tag { fill: #fff; }
.callout.is-on .tag-text { fill: #000; }

.hit { fill: transparent; cursor: crosshair; }
.hit-line { fill: none; stroke: transparent; stroke-width: 14; vector-effect: non-scaling-stroke; pointer-events: stroke; cursor: crosshair; }
.hit-line * { fill: none !important; }

.stage::after {
  content: ""; position: absolute; inset: -2px;
  background: var(--black);
  transform-origin: right center;
  pointer-events: none;
}
.stage.is-drawn::after { transform: scaleX(0); transition: transform 1.5s cubic-bezier(.7,0,.2,1); }
@media (prefers-reduced-motion: reduce) { .stage::after { display: none; } }

/* Cost bar: each segment's width is its share of ₹10,00,000. */
.costbar { display: flex; gap: 3px; height: 12px; margin-top: clamp(3.5rem, 8vh, 5rem); }
.seg { appearance: none; border: 0; padding: 0; background: none; cursor: pointer; flex-basis: 0; min-width: 6px; display: flex; }
.seg span { flex: 1; background: #3d3d3d; transition: background .2s ease; }
.seg:hover span, .seg.is-on span { background: #fff; }

.schedule { width: 100%; margin-top: 2rem; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.schedule caption { text-align: left; padding-bottom: 1.1rem; color: var(--grey-on-black); }
.schedule th, .schedule td { text-align: left; font-weight: 400; padding: .8rem 1rem .8rem 0; border-bottom: 1px solid #222; vertical-align: baseline; }
.schedule thead th { color: var(--grey-on-black); border-bottom-color: #3a3a3a; }
.schedule tbody tr { color: #a3a3a3; cursor: default; transition: color .15s ease; }
.schedule tbody tr:hover, .schedule tbody tr.is-on, .schedule tbody tr:focus { color: #fff; outline: none; }
.schedule tbody th { color: inherit; }
.schedule .no { width: 3.5rem; color: var(--grey-on-black); }
.schedule .num { text-align: right; padding-right: 0; }
.schedule .share { width: 5rem; }
.schedule tfoot th, .schedule tfoot td { border-bottom: 0; border-top: 1px solid #3a3a3a; color: #fff; padding-top: 1rem; }

/* ——— End ——— */
.end {
  display: flex; justify-content: space-between; gap: 1rem 2rem; flex-wrap: wrap;
  padding: 2rem var(--pad) 2.25rem;
  background: var(--black);
  color: var(--grey-on-black);
  border-top: 1px solid #1f1f1f;
}
.end span:first-child, .end a { color: var(--white); }

@media (max-width: 900px) {
  .court-grid { grid-template-columns: minmax(0, 1fr); row-gap: 3rem; }
  .label h3, .label-desc { min-height: 0; }
  .beliefs { grid-template-columns: minmax(0, 1fr); row-gap: 1.25rem; }
  .schedule .share, .schedule td:nth-child(3), .schedule th:nth-child(3) { display: none; }
}
@media (max-width: 720px) {
  .bar { grid-template-columns: 1fr auto; }
  .bar nav { display: none; }
  .figures { grid-template-columns: minmax(0, 1fr); }
  .first br { display: none; }
  .total { text-align: left; }
  .drawing .dim-text, .drawing .dims, .drawing .callouts { display: none; }
  .stage { container-type: inline-size; aspect-ratio: 2320 / 3640; }
  .drawing {
    position: absolute; top: 50%; left: 50%;
    width: 156.9cqw; height: auto;
    transform: translate(-50%, -50%) rotate(90deg);
  }
}

/* Gloock has no plus sign; set it in Switzer so it matches the weight. */
.figures dd { position: relative; }
.figures .plus { position: absolute; left: 100%; top: .02em; margin-left: .06em; font-family: var(--sans); font-weight: 400; font-size: .5em; line-height: 1; letter-spacing: 0; }
