/* ------------------------------------------------------------------------
   ROUGE / 37 — public-safe projection of the native Unreal 5.8.2 speelvloer
   route: alternatieve native route
   The page is built as one receding sightline: a fixed 37-fret rail on the
   left, and content plates that step inward as the corridor deepens.
   ------------------------------------------------------------------------ */

:root {
  --ink:        #0B0708;
  --ink-2:      #120C0E;
  --ink-3:      #180F12;
  --oxblood:    #4A0C16;
  --oxblood-lo: #2A070E;
  --brass:      #D9AE6A;
  --brass-dim:  #8A6B3E;
  --paper:      #F4EDE8;
  --muted:      #C4B3AC;
  --rail-w:     104px;

  --display: Georgia, "Iowan Old Style", "Times New Roman", serif;
  --sans: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: "IBM Plex Mono", "Cascadia Mono", Consolas, ui-monospace, monospace;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.62;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }

a { color: var(--brass); text-decoration-thickness: 1px; text-underline-offset: 4px; }

:focus-visible {
  outline: 3px solid var(--brass);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 40;
  background: var(--brass);
  color: #1A0D08;
  padding: 14px 22px;
  font-weight: 650;
}
.skip:focus { left: 0; }

/* ---------------------------------------------------------------- frame */

.frame { display: grid; grid-template-columns: var(--rail-w) minmax(0, 1fr); }

.rail {
  position: sticky;
  top: 0;
  align-self: start;
  height: 100vh;
  border-right: 1px solid #2A1A1C;
  background: linear-gradient(180deg, var(--oxblood-lo) 0%, var(--ink) 62%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 28px 0 26px;
}

.rail__mark {
  margin: 0;
  writing-mode: vertical-rl;
  font-family: var(--display);
  font-size: 20px;
  letter-spacing: 0.34em;
  color: var(--paper);
  display: flex;
  gap: 12px;
  align-items: center;
}
.rail__slash { color: var(--brass); }

.rail__frets {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 0 1 auto;
}
.rail__frets li { width: 26px; height: 3px; }
.rail__frets .ox { background: #7E1A26; }
.rail__frets .bl { background: #3B3438; }
.rail__frets .br { background: var(--brass); height: 5px; width: 34px; }

.rail__count {
  margin: 0;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.24em;
  color: var(--brass-dim);
  writing-mode: vertical-rl;
}

.stage { min-width: 0; }

/* ------------------------------------------------------------- masthead */

.masthead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 48px 22px 42px;
  border-bottom: 1px solid #201417;
}

.masthead__mark {
  margin: 0;
  font-family: var(--display);
  font-size: 21px;
  letter-spacing: 0.2em;
}

.masthead__nav { display: flex; gap: 30px; }
.masthead__nav a {
  font-size: 13px;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  padding: 10px 2px;
  border-bottom: 1px solid transparent;
  transition: color .2s ease, border-color .2s ease;
}
.masthead__nav a:hover,
.masthead__nav a:focus-visible { color: var(--paper); border-bottom-color: var(--brass); }

/* -------------------------------------------------------------- opening */

.opening { position: relative; }

.opening__view { margin: 0; position: relative; }

.opening__img {
  width: 100%;
  height: clamp(560px, 78vh, 860px);
  object-fit: cover;
  object-position: 46% 46%;
}
.opening__img--tall { display: none; }

.opening__view::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(96deg, rgba(11,7,8,.94) 0%, rgba(11,7,8,.80) 26%, rgba(11,7,8,.18) 55%, rgba(11,7,8,.05) 78%),
    linear-gradient(0deg, rgba(11,7,8,.86) 0%, rgba(11,7,8,0) 42%);
  pointer-events: none;
}

.opening__plate {
  position: absolute;
  left: 42px;
  bottom: 54px;
  z-index: 2;
  max-width: 560px;
}

.kicker {
  margin: 0 0 18px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--brass);
}

h1 {
  margin: 0 0 20px;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(40px, 4.6vw, 68px);
  line-height: 1.04;
  letter-spacing: -0.012em;
}
h1 em { font-style: italic; color: var(--brass); }

.lede {
  margin: 0 0 30px;
  font-size: 17px;
  color: #E3D6CF;
  max-width: 50ch;
}

.actions { display: flex; flex-wrap: wrap; gap: 14px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 28px;
  font-size: 15px;
  font-weight: 620;
  letter-spacing: 0.05em;
  text-decoration: none;
  border: 1px solid var(--brass);
  transition: background-color .2s ease, color .2s ease, transform .2s ease;
}
.btn--primary { background: var(--brass); color: #180C06; }
.btn--primary:hover, .btn--primary:focus-visible { background: #EDC684; }
.btn--ghost { background: transparent; color: var(--brass); }
.btn--ghost:hover, .btn--ghost:focus-visible { background: rgba(217,174,106,.14); color: #EFD6AC; }

.qualifier {
  margin: 18px 0 0;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: #E7DAD3;
  border-left: 2px solid var(--brass);
  padding-left: 12px;
}

/* ----------------------------------------------------------- sightlines */

.sightlines { padding: 96px 48px 40px 42px; }

.sightlines__intro { max-width: 660px; margin: 0 0 72px; }

h2 {
  margin: 0 0 16px;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(28px, 2.7vw, 40px);
  line-height: 1.14;
}

.sightlines__intro p { margin: 0 0 14px; color: var(--muted); }

.qualifier--inline { display: inline-block; margin-top: 8px; }

.room {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  align-items: end;
  column-gap: 28px;
  margin-bottom: 108px;
}

.room__crop {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  border: 1px solid #26171A;
  background: var(--ink-2);
}
.room__crop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.42);
}

.room__crop--roulette img { object-position: 15% 44%; transform-origin: 15% 44%; }
.room__crop--slots img    { object-position: 74% 42%; transform-origin: 74% 42%; }
.room__crop--tables img   { object-position: 47% 40%; transform-origin: 47% 40%; }

/* the plates step inward as the corridor deepens */
.room--near .room__crop  { grid-column: 1 / span 6; }
.room--near .room__plate { grid-column: 7 / span 5; }

.room--wall .room__crop  { grid-column: 6 / span 7; }
.room--wall .room__plate { grid-column: 2 / span 4; }

.room--deep .room__crop  { grid-column: 3 / span 6; }
.room--deep .room__plate { grid-column: 9 / span 4; }

.room__plate { padding-bottom: 18px; }

.room__index {
  margin: 0 0 10px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--brass-dim);
}
.room__index span {
  font-family: var(--display);
  font-size: 30px;
  letter-spacing: 0;
  color: var(--brass);
  margin-right: 12px;
  vertical-align: -3px;
}

.room h3 {
  margin: 0 0 14px;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(26px, 2.4vw, 36px);
  line-height: 1.1;
}

.room__plate p { margin: 0 0 14px; color: #DCCEC7; }

.room__note {
  margin: 0;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  color: var(--brass-dim);
  border-top: 1px solid #251619;
  padding-top: 12px;
}

/* ----------------------------------------------------------------- plan */

.plan {
  padding: 20px 48px 96px 42px;
  border-top: 1px solid #201417;
  margin-top: 24px;
}

.plan__intro { max-width: 640px; margin: 64px 0 40px; }
.plan__intro p { margin: 0; color: var(--muted); }

.plan__sheet {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 40px;
  align-items: start;
}

.plan__sheet svg {
  width: 100%;
  height: auto;
  border: 1px solid #26171A;
  background: var(--ink-2);
}

.plan__legend {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 13.5px;
  color: var(--muted);
}
.plan__legend li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid #1E1216;
}
.key { width: 16px; height: 16px; flex: none; border: 1px solid var(--brass-dim); }
.key--cam { background: #D9AE6A; border-radius: 50%; }
.key--wheel { background: #1A0E11; border-color: #D9AE6A; border-radius: 50%; }
.key--arc { background: linear-gradient(90deg, #A32232 50%, #6B6167 50%); }
.key--slots { background: #2E2226; }
.key--tables { background: #3A0E18; border-radius: 50% / 38%; }
.key--brass { background: #8A6B3E; }

/* ------------------------------------------------------------- colophon */

.colophon {
  padding: 44px 48px 64px 42px;
  border-top: 1px solid #201417;
  background: linear-gradient(180deg, var(--ink) 0%, var(--oxblood-lo) 240%);
}
.colophon__mark {
  margin: 0 0 14px;
  font-family: var(--display);
  font-size: 20px;
  letter-spacing: 0.2em;
}
.qualifier--foot { margin: 0 0 16px; }
.colophon__note { margin: 0 0 8px; color: var(--muted); font-size: 14.5px; max-width: 56ch; }
.colophon__meta { margin: 0; color: #9C8B85; font-size: 12.5px; font-family: var(--mono); }

/* ---------------------------------------------------------------------- */
/* MOBILE — recomposed for 390 × 844, not scaled down                      */
/* ---------------------------------------------------------------------- */

@media (max-width: 700px) {

  body { font-size: 16px; }

  .frame { display: block; }

  /* the vertical fret rail becomes a horizontal cadence meter */
  .rail {
    position: static;
    height: auto;
    flex-direction: column;
    gap: 12px;
    padding: 16px 18px 14px;
    border-right: 0;
    border-bottom: 1px solid #2A1A1C;
    background: linear-gradient(180deg, var(--oxblood-lo) 0%, var(--ink) 100%);
    align-items: stretch;
  }
  .rail__mark {
    writing-mode: horizontal-tb;
    font-size: 17px;
    letter-spacing: 0.28em;
    gap: 9px;
    justify-content: flex-start;
  }
  .rail__frets { flex-direction: row; gap: 0; width: 100%; align-items: flex-end; }
  .rail__frets li { width: auto; flex: 1 1 0; height: 6px; margin-right: 2px; }
  .rail__frets li:last-child { margin-right: 0; }
  .rail__frets .br { width: auto; height: 11px; }
  .rail__count { writing-mode: horizontal-tb; font-size: 10px; }

  .masthead {
    padding: 14px 18px;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
  .masthead__mark { display: none; }
  .masthead__nav { gap: 18px; }
  .masthead__nav a { font-size: 12px; letter-spacing: 0.14em; padding: 8px 0; }

  /* one decisive close view instead of the wide panorama */
  .opening__img--wide { display: none; }
  .opening__img--tall { display: block; height: 280px; min-height: 280px; object-position: 52% 42%; }
  .opening__view::after {
    background: linear-gradient(0deg, rgba(11,7,8,.98) 4%, rgba(11,7,8,.55) 34%, rgba(11,7,8,0) 66%);
  }

  .opening { display: flex; flex-direction: column; }
  .opening__plate {
    position: static;
    max-width: none;
    padding: 0 18px 28px;
    margin-top: -72px;
  }
  .kicker { margin-bottom: 8px; }
  h1 { font-size: 31px; margin-bottom: 10px; }
  .lede { font-size: 14.5px; line-height: 1.45; margin-bottom: 18px; }

  .actions { flex-direction: column; gap: 8px; }
  .btn { width: 100%; min-height: 50px; font-size: 15px; }

  .qualifier { margin-top: 12px; font-size: 10.5px; letter-spacing: 0.06em; line-height: 1.4; }

  .sightlines { padding: 44px 18px 8px; }
  .sightlines__intro { margin-bottom: 34px; }

  .room { display: block; margin-bottom: 54px; }
  .room__crop {
    aspect-ratio: 4 / 3;
    margin: 0 -18px 20px;
    border-left: 0;
    border-right: 0;
  }
  .room__crop img { transform: scale(1.28); }
  .room__plate { padding-bottom: 0; }
  .room__index span { font-size: 26px; }

  .plan { padding: 8px 18px 56px; margin-top: 8px; }
  .plan__intro { margin: 36px 0 22px; }
  .plan__sheet { grid-template-columns: 1fr; gap: 22px; }
  .plan__legend { font-size: 13px; }

  .colophon { padding: 32px 18px 48px; }
}

/* ------------------------------------------------------- reduced motion */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .btn, .masthead__nav a { transition: none !important; }
}

/* ------------------------------------------------------ forced contrast */

@media (forced-colors: active) {
  .btn { border: 2px solid ButtonText; }
  .qualifier { border-left-color: CanvasText; }
}
