/* Desktop layout — wide screens only. Phones and tablets keep styles.css as-is.
   Loaded after styles.css / styles.ar.css / styles.he.css on every page. */
@media (min-width: 1100px) {
  body { font-size: 15px; }
  .topbar { padding: 0 4vw; font-size: 12px; }

  /* ---------- intro: story on one side, the controls panel on the other ---------- */
  .intro-screen {
    max-width: 1480px; padding: 64px 4vw 80px;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr);
    grid-template-rows: auto auto auto auto 1fr auto auto;
    column-gap: 5vw; row-gap: 0; align-items: start; position: relative; isolation: isolate;
  }
  /* children of .intro-copy and the aside become items of the two-column grid;
     the 1fr row 5 soaks up the height of the tall scenario list so the left column stays tight */
  .intro-copy { display: contents; }
  .intro-copy > .eyebrow      { grid-column: 1; grid-row: 1; margin-top: 36px; }
  .intro-copy > h1            { grid-column: 1; grid-row: 2; font-size: clamp(64px, 6.2vw, 112px); }
  .intro-copy > .intro-lede   { grid-column: 1; grid-row: 3; font-size: 16px; max-width: 540px; }
  .intro-copy > .content-note { grid-column: 1; grid-row: 4; margin-top: 0; max-width: 560px; }
  .intro-copy > .built-by     { grid-column: 1; grid-row: 5; align-self: start; margin: 18px 0 0; max-width: 560px; }
  .intro-aside {
    grid-column: 1; grid-row: 5 / 8; align-self: end; padding-bottom: 8px;
    display: grid; grid-template-columns: auto 1fr; column-gap: 34px; align-items: center; max-width: 560px;
  }
  .intro-aside .clock-face { margin-bottom: 0; grid-row: span 2; }
  .intro-aside .aside-line { margin-bottom: 14px; align-self: end; }
  .intro-aside p { margin: 0; align-self: start; }

  /* the controls panel behind column 2 */
  .intro-screen::before {
    content: ""; grid-column: 2; grid-row: 1 / -1; align-self: stretch; z-index: -1;
    border: 1px solid rgba(244,240,232,.16); background: rgba(244,240,232,.035);
    box-shadow: 18px 18px 0 rgba(11,18,15,.18);
  }
  .intro-copy > .case-picker  { grid-column: 2; grid-row: 1 / 6; max-width: none; margin: 0; padding: 40px 44px 26px; }
  .intro-copy > .settings-row { grid-column: 2; grid-row: 6; max-width: none; margin: 0 44px; padding: 24px 0 0; align-self: start; border-top: 1px solid rgba(244,240,232,.12); }
  .intro-copy > .start-button { grid-column: 2; grid-row: 7; justify-self: start; margin: 26px 44px 44px; padding: 20px 24px; font-size: 12px; gap: 60px; }

  .case-label { font-size: 11px; margin-bottom: 16px; }
  .case-options { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .case-option { min-height: 92px; padding: 18px 20px; column-gap: 14px; }
  .case-option strong { font-size: 13px; }
  .case-option span { font-size: 13px; color: var(--paper); }
  .case-option small { font-size: 12px; margin-top: 8px; }
  .segmented button { padding: 12px 18px; font-size: 11px; }
  .fullday-toggle { font-size: 11px; flex-basis: 100%; }

  /* ---------- the simulation: wider scene card, roomier rail ---------- */
  .experience {
    max-width: 1440px; padding: 56px 4vw 72px;
    grid-template-columns: 300px minmax(0, 880px); justify-content: center;
    gap: clamp(56px, 6vw, 110px); align-items: start;
  }
  .status-rail { position: sticky; top: 32px; min-height: 0; padding-top: 18px; }
  .rail-heading { font-size: 11px; }
  .rail-heading strong { font-size: 20px; }
  .capacity-bar { height: 7px; }
  .rail-note, .timeline li, .sensory-log #signalLog { font-size: 12px; }
  .sensory-log { margin-top: 30px; }
  .ambient-line { font-size: 11px; }
  #ambientFeed { max-height: 240px; }

  .scene-panel { min-height: 640px; }
  .scene-header, .scene-footer { padding: 22px 34px; font-size: 11px; }
  .scene-body { padding: 64px 80px 56px; }
  .scene-body h2 { font-size: clamp(46px, 3.8vw, 64px); max-width: 680px; }
  .scene-text { font-size: 16px; max-width: 640px; }
  .choice-list { gap: 12px; }
  .choice { padding: 19px 22px; font-size: 15px; }
  .choice span:last-child { font-size: 12px; }
  .thought-text { font-size: 15px; }
  .microcopy { font-size: 11px; }
  .event-card { max-width: 640px; }
  .event-card h3 { font-size: clamp(30px, 2.6vw, 40px); }
  .event-actions button { padding: 16px 18px; font-size: 15px; }

  /* ---------- results ---------- */
  .end-screen { max-width: 1200px; padding: 10vh 4vw 90px; }
  .end-screen > p:not(.eyebrow) { font-size: 16px; max-width: 600px; }
}

@media (min-width: 1100px) {
  /* RTL pages: the grid mirrors on its own; just flip the panel's offset shadow */
  [dir="rtl"] .intro-screen::before { box-shadow: -18px 18px 0 rgba(11,18,15,.18); }
  [dir="rtl"] .case-option { text-align: right; }
  /* Arabic/Hebrew glyphs need more leading than the Latin .91 at this size */
  [dir="rtl"] .intro-copy > h1 { line-height: 1.18; font-size: clamp(56px, 5.4vw, 96px); }
}
