/* /students: a semester page, not a copy of A day in Ordo.
   Split hero over the cloud sea with two straight phones, then scenic tiles
   where real phones rise from the bottom edge. */

/* Hero */
.student-hero {
  position: relative;
  isolation: isolate;
  margin-top: -82px;
  padding: 140px 0 clamp(36px, 4vw, 64px);
  overflow: clip;
}
.student-hero .hero-landscape { background-image: url('/assets/ambient/OrdoHeroCloudSea.jpg'); background-position: 50% 60%; }
.student-hero .hero-landscape video { object-position: 50% 60%; }
.student-hero .hero-atmosphere {
  background:
    linear-gradient(90deg, #0e1113f2 0%, #0e1113cc 36%, #0e111366 62%, #0e111314 100%),
    linear-gradient(180deg, #141414d9 0%, #14141400 22%, #14141400 74%, #171717 100%);
}
.student-hero-inner {
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
  align-items: center;
  gap: clamp(24px, 3vw, 48px);
}
.student-hero-copy { padding-bottom: clamp(24px, 4vw, 64px); }
.student-kicker { color: #e9e6e0; font-size: 13px; letter-spacing: .01em; margin-bottom: 18px; }
.student-hero h1 {
  color: #faf8f2;
  font-family: "Ordo Hero", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: clamp(40px, 4.2vw, 66px);
  font-weight: 800;
  letter-spacing: -.05em;
  line-height: .92;
  text-shadow: 0 2px 30px #0004;
}
.student-hero h1 > span { display: block; white-space: nowrap; }
.student-hero h1 > span + span { color: #faf8f2b8; }
.student-hero-lede { max-width: 470px; margin-top: 22px; color: #ece9e3; font-size: clamp(16px, 1.4vw, 19px); line-height: 1.55; }
.student-hero .opening-actions { justify-content: flex-start; margin-top: 26px; }
.student-hero-note { margin-top: 26px; color: #bdb8af; font-size: 11px; }

/* The web app on a laptop-sized screen that runs off the right edge, with the
   iPhone in front of it. Shadows are box-shadows, never filters: a filter over
   the playing scenery video draws a faint rectangle in Safari. */
.student-devices { --bleed: calc(max(40px, (100vw - 1240px) / 2) + 8vw); position: relative; padding: 12px 0 clamp(70px, 8vw, 120px); }
.student-laptop { position: relative; z-index: 1; width: calc(100% + var(--bleed)); margin: 0; }
.student-laptop-frame {
  padding: clamp(6px, .7vw, 11px);
  border: 1px solid #9c9483;
  border-radius: clamp(16px, 1.6vw, 24px);
  background: #151515;
  overflow: hidden;
  box-shadow: 0 2px 0 #080808, inset 0 0 0 2px #202020, 0 30px 70px #000000b3;
}
.student-laptop-frame img { display: block; width: 100%; height: auto; border-radius: clamp(9px, .9vw, 14px); }
.student-phone { --pw: clamp(180px, 16vw, 240px); position: absolute; z-index: 2; right: calc(var(--pw) * .1); bottom: 0; width: var(--pw); margin: 0; isolation: isolate; }
.student-phone::before { content: ""; position: absolute; z-index: -1; inset: 1.4% 3% 1.2%; border-radius: 16% / 7.5%; box-shadow: 0 30px 60px #000000b8, 0 8px 18px #00000066; pointer-events: none; }

/* The week: a swipeable deck of moments, each with its own scene and its own
   kind of visual (a phone peeking up, a close-up, Focus with locked apps, type
   alone, a floating card, a phone at the edge). */
.wk { --gut: max(40px, calc((100vw - 1240px) / 2)); padding-block: clamp(72px, 7vw, 112px) 28px; }
.wk-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: clamp(26px, 3vw, 40px); }
.wk-kicker { color: var(--soft); font-size: 13px; }
.wk-head h2 {
  margin-top: 12px;
  color: #faf8f2;
  font-family: "Ordo Hero", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: clamp(40px, 5vw, 76px);
  font-weight: 800;
  letter-spacing: -.048em;
  line-height: .95;
}
.wk-lede { max-width: 300px; color: #c9c5be; font-size: 15px; line-height: 1.55; text-align: right; }

.wk-track {
  --cw: clamp(300px, 27vw, 392px);
  --ch: calc(var(--cw) * 1.62);
  display: flex;
  gap: 16px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gut);
  padding: 4px var(--gut) 22px;
  scrollbar-width: none;
  outline: none;
}
.wk-track::-webkit-scrollbar { display: none; }
.wk-track:focus-visible { outline: 2px solid #fff; outline-offset: -2px; border-radius: 30px; }
.wk-card {
  position: relative;
  isolation: isolate;
  flex: 0 0 var(--cw);
  height: var(--ch);
  overflow: hidden;
  border-radius: 28px;
  border: 1px solid #ffffff1f;
  background: #101214 var(--scene) center / cover no-repeat;
  scroll-snap-align: start;
}
.wk-card::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, #07090bf0 0%, #07090bb8 30%, #07090b40 60%, #07090b14 100%); }
.wk-copy { position: relative; z-index: 3; padding: 26px 26px 0; }
.wk-stamp { color: #e3dfd7; font-size: 12px; letter-spacing: .03em; font-variant-numeric: tabular-nums; }
.wk-card h3 { margin-top: 10px; color: #fbfaf7; font-size: clamp(25px, 2.1vw, 31px); font-weight: 680; letter-spacing: -.03em; line-height: 1.08; text-shadow: 0 1px 18px #0008; }
.wk-copy > p:not(.wk-stamp):not(.wk-coming) { margin-top: 10px; color: #ece9e4; font-size: 15px; line-height: 1.5; text-shadow: 0 1px 12px #0009; }
.wk-phone { position: absolute; z-index: 2; margin: 0; }
.wk-phone .iphone-device { filter: drop-shadow(0 28px 40px #000c) drop-shadow(0 6px 12px #0007); }

/* 1. A phone peeking up from the bottom edge */
.wk-peek .wk-phone { width: 74%; left: 13%; bottom: calc(var(--cw) * -.9); }
/* 2. A close-up: the phone far larger than the card, held on the evening row */
.wk-zoom .wk-phone { width: 158%; left: -11%; top: calc(var(--cw) * -.33); }
.wk-zoom .wk-copy::before { content: ""; position: absolute; inset: 0 0 -96px; z-index: -1; background: linear-gradient(180deg, #0c0d0f calc(100% - 56px), #0c0d0f00 100%); }
.wk-zoom::after { content: ""; position: absolute; inset: auto 0 0; height: 18%; z-index: 2; background: linear-gradient(0deg, #07090bcc, #07090b00); pointer-events: none; }
/* 3. Focus with the apps it will lock */
.wk-focus-visual { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.wk-focus .wk-phone { width: 58%; right: 7%; bottom: calc(var(--cw) * -.66); }
.wk-focus .locked-apps { position: absolute; inset: auto auto 0 0; transform: none; width: 44%; height: 46%; }
.wk-focus .locked-app { --s: 46px; }
.wk-focus .locked-app--instagram { --x: 30%; --y: 4%; --s: 58px; }
.wk-focus .locked-app--tiktok { --x: 2%; --y: 22%; --s: 46px; }
.wk-focus .locked-app--youtube { --x: 40%; --y: 38%; --s: 50px; }
.wk-focus .locked-app--x { --x: 8%; --y: 55%; --s: 40px; }
.wk-focus .locked-app--snapchat { --x: 44%; --y: 68%; --s: 44px; }
.wk-focus .locked-app--reddit { --x: 12%; --y: 82%; --s: 38px; }
.wk-coming { margin-top: 12px; color: #ece9e4; font-size: 13px; line-height: 1.5; max-width: 30ch; text-shadow: 0 1px 12px #0009; }
.wk-coming span { display: block; color: #ffffffa8; font-size: 11px; margin-bottom: 2px; }
/* 4. Type alone: the reminder's own words, set large */
.wk-type::before { background: linear-gradient(180deg, #07090bd9 0%, #07090b80 45%, #07090bcc 100%); }
.wk-type-block { position: absolute; z-index: 3; left: 26px; right: 26px; bottom: 30px; }
.wk-type-from { color: #f2eee7; font-size: 14px; font-weight: 600; letter-spacing: .01em; }
.wk-type-big { margin-top: 8px; color: #fff; font-family: "Ordo Hero", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-size: clamp(56px, 5.4vw, 80px); font-weight: 800; letter-spacing: -.05em; line-height: .9; text-shadow: 0 2px 30px #0006; }
.wk-type-note { margin-top: 16px; color: #ece9e4; font-size: 15px; line-height: 1.5; max-width: 26ch; }
/* 5. A single card, floating */
.wk-card-shot { position: absolute; z-index: 2; left: 9%; right: 9%; bottom: 8%; margin: 0; }
.wk-card-shot img { display: block; width: 100%; height: auto; border-radius: 6.5% / 7%; box-shadow: 0 0 0 1px #ffffff26, 0 34px 70px #000000c4, 0 8px 18px #0007; }
/* 6. A phone at the edge, cut by the card */
.wk-side .wk-phone { width: 82%; right: -22%; bottom: calc(var(--cw) * -.78); }

.wk-scene-dawn { --scene: url('/assets/ambient/scene-alpinedawn.jpg'); }
.wk-scene-forest { --scene: url('/assets/ambient/OrdoHeroForestDusk.jpg'); background-position: 60% 60%; }
.wk-scene-sunset { --scene: url('/assets/ambient/scene-mountainsunset.jpg'); background-position: 40% 50%; }
.wk-scene-night { --scene: url('/assets/ambient/scene-milkyway.jpg'); background-position: 50% 20%; }
.wk-scene-lake { --scene: url('/assets/ambient/scene-mountainlake.jpg'); background-position: 30% 50%; }

.wk-controls { display: flex; align-items: center; gap: 12px; }
.wk-progress { flex: 1; height: 2px; border-radius: 2px; background: #ffffff1f; overflow: hidden; }
.wk-progress i { display: block; height: 100%; width: calc(var(--wk-p, .2) * 100%); background: #f4f2ee; border-radius: 2px; transition: width .2s; }
.wk-prev, .wk-next { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 999px; border: 1px solid #ffffff38; background: #ffffff0d; color: #f4f2ee; cursor: pointer; transition: background .2s, opacity .2s; }
.wk-prev:hover, .wk-next:hover { background: #ffffff1f; }
.wk-prev:disabled, .wk-next:disabled { opacity: .35; cursor: default; }
.wk-prev:focus-visible, .wk-next:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.wk-prev svg, .wk-next svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

@media (prefers-reduced-motion: no-preference) { .wk-track { scroll-behavior: smooth; } }
@media (max-width: 1000px) {
  .student-hero-inner { grid-template-columns: 1fr; }
  .student-hero-copy { padding-bottom: 0; }
  .student-devices { --bleed: 12vw; margin-top: 18px; }
  .student-phone { --pw: clamp(150px, 30vw, 230px); right: 4%; }
}
@media (max-width: 1000px) {
  .wk { --gut: 24px; }
}
@media (max-width: 700px) {
  .wk { --gut: 18px; }
  .wk-head { display: block; }
  .wk-lede { margin-top: 14px; text-align: left; }
  .wk-track { --cw: 82vw; --ch: min(calc(82vw * 1.62), 640px); gap: 12px; }
  .wk-controls .wk-prev, .wk-controls .wk-next { display: none; }
  .student-hero { padding-top: 112px; }
  .student-hero h1 { font-size: clamp(32px, 9vw, 56px); }
  .student-devices { --bleed: 18vw; }
  .student-phone { --pw: 40vw; right: 2%; }
}
@media (max-width: 380px) {
  .student-hero h1 > span { white-space: normal; }
}
