/* =========================================================
   AROMĀTAI — VISUAL TOKENS & FONT REGISTRATION
   ========================================================= */
@font-face {
  font-family: "Aeonik";
  src: url("./media/AeonikTRIAL-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Aeonik";
  src: url("./media/AeonikTRIAL-Bold.otf") format("opentype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg-parchment: #d8caaf;
  --ink-parchment: #525252;
  --glass-bg: rgba(82, 82, 82, 0.6);
  --glass-border: rgba(255, 255, 255, 0.16);
  --glass-ink: #ffffff;
  --glass-ink-muted: rgba(255, 255, 255, 0.75);
  --accent-valid: #71eb87;
  --accent-error: #ff0000;
  --accent-error-soft: #c96a67;
  --radius-glass: 18px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-family: "Aeonik", sans-serif;
  font-weight: 400;
  background-color: var(--bg-parchment);
  color: var(--ink-parchment);
  scroll-snap-type: y proximity;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-parchment);
  color: var(--ink-parchment);
  overflow-x: clip;
}

main {
  position: relative;
  z-index: 1;
}

.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;
}

/* =========================================================
   LIQUID GLASS SURFACE
   ========================================================= */
.liquid-glass {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-glass);
  color: var(--glass-ink);
  transform: translateZ(0);
  backface-visibility: hidden;
}

.glass-heading {
  margin: 0 0 16px;
  font-family: "Aeonik", sans-serif;
  font-weight: 700;
  font-size: clamp(1.75rem, 2.6vw, 2.35rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
  color: var(--glass-ink);
}

.glass-body {
  margin: 0;
  font-family: "Aeonik", sans-serif;
  font-weight: 400;
  font-size: clamp(1rem, 1.25vw, 1.15rem);
  line-height: 1.55;
  color: var(--glass-ink-muted);
  max-width: 46ch;
}

.marketing-slot:empty {
  display: none;
}

/* =========================================================
   CONTOURS BACKDROP (SINGLE 90°-ROTATED LAYER) & SNAP ANCHORS
   ========================================================= */
.contours-backdrop {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  background-color: var(--bg-parchment);
  opacity: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
  will-change: opacity;
}

.contours-svg {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 135vmax;
  height: 135vmax;
  max-width: none;
  transform: translate(-50%, -50%) rotate(90deg);
  object-fit: cover;
  display: block;
  pointer-events: none;
}

.snap-anchor {
  position: absolute;
  left: 0;
  width: 100%;
  height: 100vh;
  pointer-events: none;
}

.snap-start {
  top: 0;
  scroll-snap-align: start;
}

.snap-end {
  bottom: 0;
  scroll-snap-align: end;
}

/* =========================================================
   PERSISTENT TOP-RIGHT PILL
   ========================================================= */
.beta-pill {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 100;
  padding: 11px 20px;
  border-radius: 999px;
  font-family: "Aeonik", sans-serif;
  font-weight: 400;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  color: var(--glass-ink);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.45s cubic-bezier(0.22, 1, 0.36, 1),
    background-color 0.25s ease, transform 0.25s ease;
}

.beta-pill.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.beta-pill:hover,
.beta-pill:focus-visible {
  background: rgba(82, 82, 82, 0.78);
  outline: none;
}

/* =========================================================
   SECTION 1: ESTABLISHING THE INTERFACE (320vh Track)
   ========================================================= */
.section-intro {
  position: relative;
  height: 320vh;
  background-color: transparent;
}

.intro-sticky {
  position: sticky;
  top: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  display: grid;
  place-items: center;
}

.intro-marquee-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.intro-marquee-text {
  position: absolute;
  top: 50%;
  left: 0;
  font-family: "Aeonik", sans-serif;
  font-weight: 700;
  font-size: clamp(14rem, 42vw, 46rem);
  line-height: 0.9;
  letter-spacing: 0.14em;
  color: var(--ink-parchment);
  white-space: nowrap;
  transform: translate3d(100vw, -50%, 0);
  will-change: transform, opacity;
}

.intro-beat-b,
.intro-beat-c {
  position: relative;
  grid-area: 1 / 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0 24px;
  opacity: 0;
  will-change: opacity, transform;
}

.intro-bracket-heading {
  margin: 0 0 18px;
  font-family: "Aeonik", sans-serif;
  font-weight: 700;
  font-size: clamp(3rem, 7vw, 6.25rem);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--ink-parchment);
}

.intro-pitch {
  margin: 0;
  font-family: "Aeonik", sans-serif;
  font-weight: 400;
  font-size: clamp(1.25rem, 2.2vw, 1.85rem);
  line-height: 1.4;
  color: var(--ink-parchment);
  max-width: 54ch;
}

.intro-nope {
  margin: 0 0 22px;
  font-family: "Aeonik", sans-serif;
  font-weight: 400;
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  line-height: 1.3;
  color: var(--ink-parchment);
}

.intro-brand-lockup {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: min(82vw, 620px);
}

.intro-logo-svg {
  display: block;
  width: 100%;
  height: auto;
}

.intro-subcopy-slot {
  margin-top: 28px;
  max-width: 54ch;
  min-height: 24px;
}

.intro-subcopy {
  margin: 0;
  font-size: clamp(1.05rem, 1.4vw, 1.25rem);
  line-height: 1.5;
  color: var(--ink-parchment);
}

/* =========================================================
   SECTION 2: LAUNCHPAD OVERVIEW (100vh Fullscreen Snap)
   ========================================================= */
.section-launchpad {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  background-color: transparent;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

.showcase-viewport {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100vh;
  padding: clamp(24px, 4vh, 48px) clamp(24px, 4vw, 56px);
  display: flex;
  align-items: center;
  justify-content: center;
}

.demo-window-shell {
  position: relative;
  z-index: 1;
  width: min(100%, 1280px, 131.2vh);
  height: auto;
  max-height: 82vh;
  aspect-ratio: 16 / 10;
  border-radius: 12px;
  overflow: hidden;
  background: transparent;
}

.demo-scaled-stage {
  position: absolute;
  top: 0;
  left: 0;
  width: 1280px;
  height: 800px;
  transform: scale(var(--demo-scale, 1));
  transform-origin: top left;
}

.macos-traffic-lights {
  position: absolute;
  top: 10px;
  left: 16px;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: none;
}

.macos-traffic-lights span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 0.5px rgba(0, 0, 0, 0.16);
}

.tl-close {
  background: #FF5F57;
}

.tl-min {
  background: #FEBC2E;
}

.tl-max {
  background: #28C840;
}

.launchpad-stage {
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 12px;
  overflow: hidden;
  transform: scale(0.97) translateZ(0);
  transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.section-launchpad.is-in-view .launchpad-stage {
  transform: scale(1) translateZ(0);
}

.launchpad-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

.launchpad-caption {
  position: absolute;
  left: clamp(24px, 4vw, 56px);
  bottom: clamp(24px, 4vh, 48px);
  z-index: 4;
  max-width: min(440px, calc(100% - 48px));
  padding: 36px;
}

/* =========================================================
   SCOPED 1:1 DESKTOP APP REPLICA TOKENS (.aromatai-app-replica)
   ========================================================= */
.aromatai-app-replica {
  --u: 0.0625rem;
  --spacing-1: calc(50 * var(--u));
  --spacing-2: calc(20 * var(--u));
  --spacing-3: calc(14 * var(--u));
  --spacing-4: calc(10 * var(--u));
  --padx-1: var(--spacing-1);
  --padx-2: var(--spacing-2);
  --padx-3: var(--spacing-3);
  --padx-4: var(--spacing-4);
  --pady-1: var(--spacing-1);
  --pady-2: var(--spacing-2);
  --pady-3: var(--spacing-3);
  --pady-4: var(--spacing-4);
  --gap-1: var(--spacing-1);
  --gap-2: var(--spacing-2);
  --gap-3: var(--spacing-3);
  --gap-4: var(--spacing-4);
  --radius-1: calc(25 * var(--u));
  --radius-2: calc(18 * var(--u));
  --radius-3: calc(14 * var(--u));
  --radius-4: calc(12 * var(--u));
  --radius-pill: 999em;
  --ink-surface: rgba(58, 58, 57, 0.58);
  --ink-surface-elevated: rgba(118, 118, 115, 0.58);
  --ink-surface-deep: rgba(34, 34, 34, 0.84);
  --glass-blur: blur(20px);
  --glass-border: 1px solid rgba(255, 255, 255, 0.14);
  --brand-sand: #d8caaf;
  --brand-sand-ink: #1a1a19;
  --accent-assessment: #71eb87;
  --accent-today: #ff0000;
  --timetable-day-rail-w: 148px;
  font-family: "Aeonik", sans-serif;
  color: #ffffff;
}

/* =========================================================
   SECTION 3: TIMETABLE FUNCTIONALITY (100vh Centered Window + Overlay)
   ========================================================= */
.section-timetable {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  background-color: transparent;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

.demo-iframe {
  width: 100%;
  height: 100%;
  border: none;
  background: transparent;
  display: block;
}

.timetable-replica-shell {
  position: relative;
  width: 100%;
  height: 100%;
  background: var(--ink-surface);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-radius: var(--radius-2);
  display: flex;
  overflow: hidden;
  transform: translateZ(0);
  backface-visibility: hidden;
  user-select: none;
}

.tt-scroll-container {
  flex: 1 1 auto;
  min-width: 0;
  height: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  display: flex;
  position: relative;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.tt-scroll-container::-webkit-scrollbar {
  display: none;
}

/* Sticky Left Monday-Sunday Liquid Glass Rail */
.tt-day-rail {
  position: sticky;
  left: 0;
  z-index: 20;
  width: var(--timetable-day-rail-w);
  flex-shrink: 0;
  height: 100%;
  background: rgba(44, 44, 44, 0.68);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-right: var(--glass-border);
  display: flex;
  flex-direction: column;
  transform: translateZ(0);
  backface-visibility: hidden;
}

.tt-day-rail-header {
  height: 46px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
}

.tt-configure-pill {
  font-family: "Aeonik", sans-serif;
  font-weight: 400;
  font-size: 0.78rem;
  line-height: 1;
  padding: 7px 13px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.86);
  cursor: pointer;
}

.tt-day-labels {
  flex: 1 1 auto;
  display: grid;
  grid-template-rows: repeat(7, minmax(0, 1fr));
}

.tt-day-label {
  display: flex;
  align-items: center;
  padding: 0 16px;
  font-size: 0.86rem;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.72);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.tt-day-label:last-child {
  border-bottom: none;
}

.tt-day-label.is-today {
  color: var(--accent-today);
  font-weight: 700;
  opacity: 1;
}

/* Horizontal Time Track */
.tt-timeline-track {
  position: relative;
  flex-shrink: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.tt-time-ruler {
  position: relative;
  height: 46px;
  flex-shrink: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.tt-hour-marker {
  position: absolute;
  top: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  pointer-events: none;
}

.tt-hour-num {
  padding-top: 8px;
  padding-left: 4px;
  font-size: 0.82rem;
  font-weight: 400;
  color: #ffffff;
  line-height: 1;
}

.tt-hour-ticks {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  width: 100%;
  height: 10px;
}

.tt-tick {
  width: 1px;
  height: 5px;
  background: rgba(255, 255, 255, 0.45);
}

.tt-tick.is-major {
  height: 9px;
  background: rgba(255, 255, 255, 0.85);
}

.tt-rows-layer {
  position: relative;
  flex: 1 1 auto;
  display: grid;
  grid-template-rows: repeat(7, minmax(0, 1fr));
}

.tt-day-row {
  position: relative;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.tt-day-row:last-child {
  border-bottom: none;
}

/* Class & Study Blocks */
.tt-block {
  position: absolute;
  top: 6px;
  bottom: 6px;
  border-radius: var(--radius-3);
  padding: 7px 10px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  transform: translateZ(0);
}

.tt-block-class {
  background: rgba(34, 34, 34, 0.72);
  cursor: default;
}

.tt-block-study {
  background: rgba(118, 118, 115, 0.56);
  border-color: rgba(216, 202, 175, 0.38);
  cursor: grab;
  padding-left: 14px;
  padding-right: 14px;
}

.tt-block-study:active,
.tt-block-study.is-dragging {
  cursor: grabbing;
  background: rgba(118, 118, 115, 0.76);
  border-color: #d8caaf;
  z-index: 15;
}

.tt-block-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  min-width: 0;
}

.tt-block-title {
  font-size: 0.78rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tt-block-period {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.65);
  flex-shrink: 0;
}

.tt-block-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  min-width: 0;
}

.tt-block-room {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.68);
  white-space: nowrap;
}

.tt-block-tag {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--accent-assessment);
  background: rgba(113, 235, 135, 0.14);
  border: 1px solid rgba(113, 235, 135, 0.45);
  border-radius: 999px;
  padding: 2px 7px;
  white-space: nowrap;
}

/* Crisp White Vertical End-Handles on Study Blocks */
.tt-study-handle {
  position: absolute;
  top: 6px;
  bottom: 6px;
  width: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: ew-resize;
  z-index: 4;
}

.tt-study-handle::after {
  content: "";
  width: 2.5px;
  height: 55%;
  border-radius: 999px;
  background: #ffffff;
  opacity: 0.9;
}

.tt-study-handle-left {
  left: 1px;
}

.tt-study-handle-right {
  right: 1px;
}

/* Collapsible Right Liquid Glass AI Rail */
.tt-ai-rail {
  width: 270px;
  flex-shrink: 0;
  height: 100%;
  background: rgba(44, 44, 44, 0.68);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-left: var(--glass-border);
  display: flex;
  flex-direction: column;
  padding: 14px;
  gap: 12px;
  transition: width 0.28s cubic-bezier(0.22, 1, 0.36, 1), padding 0.28s ease;
  overflow: hidden;
  transform: translateZ(0);
  backface-visibility: hidden;
}

.tt-ai-rail.is-collapsed {
  width: 52px;
  padding: 14px 9px;
}

.tt-ai-header {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.tt-ai-toggle {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  cursor: pointer;
  transition: transform 0.25s ease, background-color 0.2s ease;
}

.tt-ai-toggle svg {
  width: 14px;
  height: 14px;
}

.tt-ai-rail.is-collapsed .tt-ai-toggle svg {
  transform: rotate(180deg);
}

.tt-ai-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tt-ai-rail.is-collapsed .tt-ai-title,
.tt-ai-rail.is-collapsed .tt-ai-body,
.tt-ai-rail.is-collapsed .tt-ai-input-wrap {
  opacity: 0;
  pointer-events: none;
}

.tt-ai-body {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
}

.tt-ai-message {
  background: rgba(82, 82, 82, 0.52);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 12px;
  font-size: 0.8rem;
  line-height: 1.48;
  color: rgba(255, 255, 255, 0.9);
}

.tt-ai-hint {
  font-size: 0.76rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.65);
  padding: 0 4px;
}

.tt-ai-input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  font-family: "Aeonik", sans-serif;
  font-size: 0.78rem;
  outline: none;
}

.tt-drag-tooltip {
  position: fixed;
  z-index: 200;
  padding: 6px 11px;
  border-radius: 999px;
  background: rgba(34, 34, 34, 0.92);
  border: 1px solid rgba(216, 202, 175, 0.55);
  color: #d8caaf;
  font-family: "Aeonik", sans-serif;
  font-size: 0.76rem;
  font-weight: 700;
  pointer-events: none;
  white-space: nowrap;
}

.editorial-panel {
  max-width: min(440px, calc(100% - 48px));
  padding: 36px;
}

.timetable-info {
  position: absolute;
  right: clamp(24px, 4vw, 56px);
  bottom: clamp(24px, 4vh, 48px);
  z-index: 4;
  max-width: min(440px, calc(100% - 48px));
  padding: 36px;
  opacity: 1;
  pointer-events: auto;
}

.timetable-expanded-slot {
  margin-top: 18px;
}

/* =========================================================
   SECTION 4: SUBJECT MENUS (100vh Interactive Subject Dashboard)
   ========================================================= */
.section-subjects {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  background-color: transparent;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

.subjects-viewport {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Specular gradient-masked rim without hard top borders */
.glass-rim {
  position: relative;
}

.glass-rim::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.28) 0%,
    rgba(255, 255, 255, 0.06) 45%,
    rgba(255, 255, 255, 0.16) 100%
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
  pointer-events: none;
}

/* Outer Smoked-Graphite Liquid Glass App Window */
.subject-app-window {
  width: min(92vw, 1360px);
  height: 84vh;
  background: rgba(44, 44, 44, 0.62);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 25px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  color: #ffffff;
  transform: translateZ(0);
  backface-visibility: hidden;
  overflow: hidden;
}

/* Top App Pill Bar */
.subject-topbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  min-width: 0;
}

.subject-back-btn {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: none;
  background: rgba(255, 255, 255, 0.08);
  color: #d8caaf;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.subject-back-btn:hover {
  background: rgba(216, 202, 175, 0.2);
}

.subject-back-btn svg {
  width: 14px;
  height: 14px;
}

.subject-standards-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1 1 auto;
  min-width: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.subject-standards-nav::-webkit-scrollbar {
  display: none;
}

.subject-pill {
  font-family: "Aeonik", sans-serif;
  font-weight: 400;
  font-size: 0.85rem;
  line-height: 1;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  white-space: nowrap;
  flex-shrink: 0;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.subject-pill:hover {
  background: rgba(216, 202, 175, 0.22);
}

.subject-pill-subject {
  background: #d8caaf;
  color: #1a1a19;
  font-weight: 700;
  border-color: transparent;
  cursor: default;
}

.subject-pill-subject:hover {
  background: #d8caaf;
}

.subject-pill-standard.is-active {
  background: #d8caaf;
  color: #1a1a19;
  font-weight: 700;
  border-color: transparent;
}

.subject-pill-configure {
  margin-left: auto;
  color: rgba(255, 255, 255, 0.78);
}

/* Mobile Summary Strip (hidden on desktop) */
.subject-mobile-strip {
  display: none;
}

/* Multi-Column Interior */
.subject-workspace {
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(280px, 34%) minmax(0, 1fr);
  gap: 16px;
}

/* Left Column: Spec & Folder Trays */
.subject-sidebar {
  background: rgba(82, 82, 82, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 18px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
  min-height: 0;
  transform: translateZ(0);
  backface-visibility: hidden;
}

.std-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.8rem;
}

.std-badge-type {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(113, 235, 135, 0.14);
  border: 1px solid rgba(113, 235, 135, 0.45);
  color: #71eb87;
  font-weight: 700;
  font-size: 0.78rem;
}

.std-code-muted {
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.8rem;
}

.std-sidebar-title {
  margin: 0;
  font-family: "Aeonik", sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  line-height: 1.3;
  color: #ffffff;
}

.std-stats-block {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.84rem;
}

.std-stat-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.std-stat-label {
  color: rgba(255, 255, 255, 0.68);
}

.std-stat-value {
  color: #ffffff;
  font-weight: 700;
}

.std-folders-block {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.std-folder-tray {
  background: rgba(34, 34, 34, 0.52);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.std-folder-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  font-weight: 700;
  color: #ffffff;
}

.std-folder-count {
  color: rgba(255, 255, 255, 0.68);
  font-weight: 400;
}

.std-folder-files {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.std-folder-file {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.68);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Middle Self-Scrollable Assessment Pane */
.subject-assessment-pane {
  background: rgba(82, 82, 82, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 18px;
  padding: 28px 32px;
  overflow-y: auto;
  overscroll-behavior: contain;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 22px;
  transform: translateZ(0);
  backface-visibility: hidden;
}

.subject-assessment-pane:focus {
  outline: none;
}

.assessment-header {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.assessment-kicker-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.assessment-title {
  margin: 0;
  font-family: "Aeonik", sans-serif;
  font-weight: 700;
  font-size: clamp(1.25rem, 1.8vw, 1.65rem);
  line-height: 1.25;
  color: #ffffff;
}

.assessment-brief {
  margin: 0;
  font-size: 0.96rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.85);
}

.assessment-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.assessment-section-title {
  margin: 0;
  font-family: "Aeonik", sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: #ffffff;
}

.rubric-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.rubric-card {
  background: rgba(34, 34, 34, 0.56);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.rubric-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.rubric-grade {
  font-weight: 700;
  font-size: 0.88rem;
  color: #d8caaf;
}

.rubric-solo {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.68);
}

.rubric-list {
  margin: 0;
  padding-left: 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.88rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.82);
}

.checkpoint-tile {
  background: rgba(34, 34, 34, 0.48);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.checkpoint-title {
  font-weight: 700;
  font-size: 0.9rem;
  color: #ffffff;
}

.checkpoint-desc {
  font-size: 0.85rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.68);
}

/* Desktop Editorial Card: Bottom-Left Corner */
.subjects-info {
  position: absolute;
  left: clamp(24px, 4vw, 56px);
  bottom: clamp(24px, 4vh, 48px);
  z-index: 4;
  max-width: min(440px, calc(100% - 48px));
  padding: 36px;
}

.subjects-expanded-slot {
  margin-top: 18px;
}

/* =========================================================
   SECTION 5: DOWNLOAD THE BETA (100vh License Gate)
   ========================================================= */
.section-beta {
  position: relative;
  width: 100vw;
  min-height: 100vh;
  background-color: transparent;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 24px 96px;
}

.beta-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  padding: 44px;
}

.beta-intro {
  margin-bottom: 28px;
}

.beta-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.beta-input {
  width: 100%;
  padding: 15px 18px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.24);
  font-family: "Aeonik", sans-serif;
  font-weight: 400;
  font-size: 1rem;
  color: var(--glass-ink);
  outline: none;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.beta-input::placeholder {
  color: rgba(255, 255, 255, 0.48);
}

.beta-input:focus {
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.16);
}

.beta-submit {
  width: 100%;
  padding: 15px 22px;
  border: none;
  border-radius: 12px;
  background: var(--bg-parchment);
  color: var(--ink-parchment);
  font-family: "Aeonik", sans-serif;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.15s ease;
}

.beta-submit:hover:not(:disabled) {
  opacity: 0.92;
}

.beta-submit:active:not(:disabled) {
  transform: scale(0.99);
}

.beta-submit:disabled {
  opacity: 0.6;
  cursor: wait;
}

.beta-error {
  margin: 4px 0 0;
  font-size: 0.92rem;
  color: var(--accent-error-soft);
}

.beta-unlocked {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.beta-verified-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(113, 235, 135, 0.14);
  border: 1px solid rgba(113, 235, 135, 0.45);
  color: var(--accent-valid);
  font-size: 0.875rem;
  font-weight: 700;
  margin-bottom: 18px;
}

.verified-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-valid);
}

.beta-downloads {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.download-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  border-radius: 12px;
  background: var(--bg-parchment);
  color: var(--ink-parchment);
  font-family: "Aeonik", sans-serif;
  font-weight: 700;
  font-size: 0.98rem;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.download-btn:hover {
  opacity: 0.9;
}

.gatekeeper-note {
  margin: 16px 0 0;
  font-size: 0.88rem;
  color: var(--glass-ink-muted);
}

.site-footer {
  position: absolute;
  bottom: 24px;
  left: 0;
  right: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  font-size: 0.88rem;
  color: var(--ink-parchment);
}

.footer-link {
  color: var(--ink-parchment);
  text-decoration: none;
  font-weight: 700;
}

.footer-link:hover {
  text-decoration: underline;
}

/* =========================================================
   RESPONSIVE ADJUSTMENTS
   ========================================================= */
@media (max-width: 900px) {
  .editorial-panel {
    padding: 28px;
    max-width: calc(100vw - 32px);
  }

  .beta-card {
    padding: 28px;
  }
}

@media (max-width: 767px) {
  .showcase-viewport {
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 64px 12px 24px;
    gap: 0;
  }

  .demo-window-shell {
    width: 94vw;
    height: auto;
    max-height: none;
    aspect-ratio: 16 / 10;
    border-radius: 12px;
    flex-shrink: 0;
  }

  .launchpad-caption,
  .timetable-info,
  .subjects-info {
    position: relative;
    left: auto;
    right: auto;
    bottom: auto;
    margin-top: -24px;
    width: min(88vw, 440px);
    max-width: 88vw;
    padding: 22px 24px;
    z-index: 4;
    flex-shrink: 0;
    opacity: 1 !important;
    transform: none !important;
    pointer-events: auto;
  }

  .launchpad-caption .glass-heading,
  .timetable-info .glass-heading,
  .subjects-info .glass-heading {
    font-size: 1.35rem;
    margin-bottom: 8px;
  }

  .launchpad-caption .glass-body,
  .timetable-info .glass-body,
  .subjects-info .glass-body {
    font-size: 0.92rem;
    line-height: 1.45;
  }
}
