:root {
  color-scheme: light dark;

  --page-bg: #ffffff;
  --text-main: #161616;
  --text-muted: rgb(0 0 0 / 0.55);
  --text-soft: rgb(0 0 0 / 0.4);

  --card-bg: rgb(0 0 0 / 0.035);
  --card-border: rgb(0 0 0 / 0.08);

  --glass-bg: rgb(200 200 200 / 0.35);
  --glass-bg-hover: rgb(0 0 0 / 1);

  --sheet-bg: rgb(255 255 255 / 0.1);
  --levitated-button-bg: rgb(241 241 241 / 0.6);

  --icon-filter: brightness(0) opacity(0.4);
  --icon-filter-hover: brightness(0) opacity(1);

  --back-link-icon-filter: brightness(0) opacity(0.55);
  --back-link-icon-filter-hover: brightness(0) invert(1) opacity(0.8);

  --accent: #FF857A;
}

@media (prefers-color-scheme: dark) {
  :root {
    --page-bg: #0d0d0d;
    --text-main: #f5f5f5;
    --text-muted: rgb(255 255 255 / 0.6);
    --text-soft: rgb(255 255 255 / 0.4);

    --card-bg: rgb(255 255 255 / 0.045);
    --card-border: rgb(255 255 255 / 0.09);

    --glass-bg: rgb(120 120 120 / 0.28);
    --glass-bg-hover: rgb(255 255 255 / 1);

    --sheet-bg: rgb(45 45 45 / 0.18);
    --levitated-button-bg: rgb(42 42 42 / 0.6);

    --icon-filter: brightness(0) invert(1) opacity(0.4);
    --icon-filter-hover: brightness(0) invert(1) opacity(1);

    --back-link-icon-filter: brightness(0) invert(1) opacity(0.65);
    --back-link-icon-filter-hover: brightness(0) opacity(0.85);

    --accent: #F0A2B7;
  }
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  background: var(--page-bg);
  color: var(--text-main);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", Inter, "Segoe UI", sans-serif;
}

a {
  color: inherit;
}

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

main {
  max-width: 980px;
  margin: 0 auto;
  padding: clamp(112px, 16vw, 160px) clamp(20px, 5vw, 40px) clamp(80px, 10vw, 128px);
}

.sticky-bar {
  position: fixed;
  top: 20px;
  left: 0;
  right: 0;
  margin-inline: auto;
  z-index: 100;

  width: calc(100% - clamp(20px, 5vw, 40px) * 2);
  max-width: 1100px;
  height: 64px;

  border: 1px solid rgb(127 127 127 / 0.10);
  border-radius: 999px;
  background: var(--levitated-button-bg);
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);

  box-shadow:
    0 12px 40px rgb(0 0 0 / 0.10),
    0 4px 12px rgb(0 0 0 / 0.06);

  opacity: 0;
  pointer-events: none;
  filter: blur(20px);
  translate: 0 -120px;
  scale: 0;

  transition:
    opacity 520ms cubic-bezier(0.22, 1, 0.36, 1),
    translate 780ms cubic-bezier(0.22, 1, 0.36, 1),
    scale 850ms cubic-bezier(0.34, 1.15, 0.64, 1) 220ms,
    filter 900ms cubic-bezier(0.16, 1, 0.3, 1);
}

.sticky-bar.is-visible {
  opacity: 1;
  pointer-events: auto;
  filter: blur(0);
  translate: 0 0;
  scale: 1;
}

.sticky-bar-inner {
  height: 100%;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;

  padding: 0 14px 0 clamp(20px, 4vw, 32px);
}

.sticky-bar-name {
  font-size: 17px;
  font-weight: 600;
}

.sticky-bar-download {
  display: inline-flex;
  align-items: center;

  height: 36px;
  padding: 0 18px;

  border-radius: 999px;
  background: var(--accent);
  color: var(--page-bg);

  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;

  transition: opacity 200ms ease;
}

.sticky-bar-download:hover {
  opacity: 0.8;
}

.hero {
  text-align: center;
  margin-bottom: clamp(56px, 9vw, 96px);
}

.hero .eyebrow {
  width: 100%;
  max-width: none;
  font-size: clamp(22px, 2.4vw, 30px);
  font-weight: 600;
  color: var(--text-main);
  text-align: center;
  margin: 0 0 16px;
}

.hero h1 {
  font-size: clamp(40px, 7vw, 80px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 20px;
}

.hero p {
  font-size: clamp(18px, 2.2vw, 21px);
  font-weight: 500;
  line-height: 1.35;
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto;
}

.app-store-badge {
  display: inline-block;
  margin-top: clamp(24px, 4vw, 36px);
}

.app-store-badge img {
  height: 48px;
  width: auto;
  margin: 0 auto;
}

.hero-image {
  max-width: 600px;
  margin: 0 auto clamp(40px, 6vw, 64px);
  overflow: hidden;
}

.hero-image img {
  width: 100%;
  height: auto;
}

.app-icon {
  width: 60px;
  height: 60px;
  margin: 0 auto 20px;
  overflow: hidden;
}

.app-icon img {
  width: 100%;
  height: 100%;
}

.carousel-section {
  --carousel-inset: clamp(20px, 5vw, 40px);
  --carousel-max: 980px;
  --carousel-content-w: calc(min(var(--carousel-max), 100vw) - var(--carousel-inset) * 2);
  --carousel-side-pad: calc((100vw - min(var(--carousel-max), 100vw)) / 2 + var(--carousel-inset));
  --carousel-controls-h: 56px;
  --carousel-controls-gap: 56px;
  --carousel-bottom-gap: clamp(64px, 8vw, 80px);
  --carousel-card-h: 400px;

  width: 100vw;
  position: relative;
  left: 50%;
  margin-left: -50vw;

  margin-top: clamp(80px, 10vw, 128px);
  padding: clamp(64px, 9vw, 96px) 0 var(--carousel-bottom-gap);

  background: var(--card-bg);
  overflow: clip;
}

@media (min-width: 601px) {
  .carousel-section {
    --carousel-card-h: 460px;
  }
}

@media (min-width: 901px) {
  .carousel-section {
    --carousel-card-h: 520px;
  }
}

@media (min-width: 1201px) {
  .carousel-section {
    --carousel-card-h: 580px;
  }
}

.carousel-section h2 {
  max-width: var(--carousel-max);
  margin: 0 auto clamp(32px, 5vw, 48px);
  padding: 0 var(--carousel-inset);

  font-size: clamp(32px, 4vw, 48px);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.1;
}

.carousel-track {
  position: relative;
  display: flex;
  gap: 20px;

  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scroll-padding-inline: var(--carousel-side-pad);
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;

  padding: 4px var(--carousel-side-pad) 4px;
}

.carousel-track::-webkit-scrollbar {
  display: none;
}

.carousel-card {
  --card-pad: clamp(28px, 4vw, 44px);

  flex: 0 0 auto;
  width: var(--carousel-content-w);
  height: var(--carousel-card-h);
  scroll-snap-align: start;

  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  gap: 16px;
  overflow: hidden;

  padding: 0;
  border-radius: 28px;
  color: #ffffff;
}

.carousel-card-device {
  flex: 1 1 auto;
  min-height: 0;
  width: 80%;
  display: block;
  pointer-events: none;
}

.carousel-card-device img {
  width: 100%;
  height: auto;
  display: block;
}

.carousel-card-copy {
  flex: 0 0 auto;
  padding: var(--card-pad) var(--card-pad) 0;
  text-align: center;
}

.carousel-card-copy p {
  display: inline-block;
  text-align: center;
}

.carousel-card--schedules {
  background: linear-gradient(135deg, #2a2a2e, #000000);
}

.carousel-card--assignments {
  background: linear-gradient(135deg, #33202a, #000000);
}

.carousel-card--wellbeing {
  background: linear-gradient(135deg, #17281f, #000000);
}

.carousel-card--platform {
  justify-content: space-between;

  background: linear-gradient(135deg, #172233, #000000);
}

.carousel-card--platform .carousel-card-device {
  flex: 0 0 auto;
  width: 90%;
  margin-bottom: calc(var(--card-pad) + 12px);
}

.carousel-card--intelligence {
  background: linear-gradient(135deg, #2a1c33, #000000);
}

.carousel-card h3 {
  font-size: clamp(22px, 2.6vw, 30px);
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 10px;
}

.carousel-card p {
  font-size: clamp(14px, 1.4vw, 16px);
  line-height: 1.5;
  color: rgb(255 255 255 / 0.7);
  max-width: 420px;
  margin: 0;
}

.carousel-controls {
  position: sticky;
  bottom: var(--carousel-controls-gap);
  margin-top: var(--carousel-controls-gap);
  z-index: 70;

  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;

  width: 100%;
  pointer-events: none;
}

.carousel-toggle,
.carousel-dots {
  pointer-events: auto;

  opacity: 0;
  filter: blur(20px);
  transform: translateY(120px) scale(0);

  transition:
    opacity 520ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 900ms cubic-bezier(0.34, 1.56, 0.64, 1),
    filter 900ms cubic-bezier(0.16, 1, 0.3, 1),
    background 240ms ease;
}

.carousel-controls.is-visible .carousel-toggle,
.carousel-controls.is-visible .carousel-dots {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0) scale(1);
}

.carousel-controls:not(.is-visible) .carousel-toggle,
.carousel-controls:not(.is-visible) .carousel-dots {
  pointer-events: none;
}

.carousel-toggle {
  width: 56px;
  height: 56px;

  display: grid;
  place-items: center;

  border: 1px solid rgb(127 127 127 / 0.10);
  border-radius: 999px;
  background: var(--levitated-button-bg);
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);

  box-shadow:
    0 12px 30px rgb(0 0 0 / 0.10),
    0 4px 10px rgb(0 0 0 / 0.06);

  cursor: pointer;
}

.carousel-toggle .icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
  pointer-events: none;
  filter: var(--back-link-icon-filter);
  transition: filter 200ms ease;
}

.carousel-toggle:hover {
  background: var(--accent);
}

.carousel-toggle:hover .icon {
  filter: var(--back-link-icon-filter-hover);
}

.carousel-controls.is-visible .carousel-toggle.is-pressed,
.carousel-controls.is-visible .carousel-toggle:hover.is-pressed {
  transform: scale(0.85);

  transition:
    transform 420ms cubic-bezier(0.22, 1, 0.36, 1),
    background 240ms ease;
}

.carousel-toggle .icon-play {
  display: none;
}

.carousel-toggle.is-paused .icon-pause {
  display: none;
}

.carousel-toggle.is-paused .icon-play {
  display: block;
}

.carousel-dots {
  display: flex;
  align-items: center;
  gap: 16px;

  height: 56px;
  padding: 0 22px;

  border: 1px solid rgb(127 127 127 / 0.10);
  border-radius: 999px;
  background: var(--levitated-button-bg);
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);

  box-shadow:
    0 12px 30px rgb(0 0 0 / 0.10),
    0 4px 10px rgb(0 0 0 / 0.06);
}

.carousel-dot {
  position: relative;
  overflow: hidden;

  width: 8px;
  height: 8px;
  padding: 0;

  border: none;
  border-radius: 999px;
  background: var(--text-soft);
  cursor: pointer;

  transition: width 280ms cubic-bezier(0.22, 1, 0.36, 1), background 200ms ease;
}

.carousel-dot.is-active {
  width: 44px;
}

.carousel-dot-fill {
  position: absolute;
  inset: 0;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left center;
}

/* Duration must match AUTOPLAY_DELAY in the carousel script */
.carousel-dot.is-active .carousel-dot-fill {
  animation: carousel-dot-progress 4500ms linear forwards;
}

.carousel-controls.is-paused .carousel-dot.is-active .carousel-dot-fill {
  animation-play-state: paused;
}

@keyframes carousel-dot-progress {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

.design-section {
  --design-inset: clamp(20px, 5vw, 40px);
  --design-max: 980px;
  --design-side-pad: calc((100vw - min(var(--design-max), 100vw)) / 2 + var(--design-inset));
  --design-nav-gap: 56px;

  width: 100vw;
  position: relative;
  left: 50%;
  margin-left: -50vw;

  padding: clamp(64px, 9vw, 96px) 0 clamp(32px, 5vw, 48px);

  background: var(--page-bg);
  color: var(--text-main);
  overflow: clip;
}

.design-header {
  max-width: var(--design-max);
  margin: 0 auto;
  padding: 0 var(--design-inset);
}

.design-eyebrow {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 14px;
}

.design-title {
  font-size: clamp(32px, 4.5vw, 52px);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.1;
  max-width: 700px;
  margin: 0 0 20px;
}

.design-description {
  font-size: clamp(16px, 1.6vw, 19px);
  font-weight: 500;
  line-height: 1.5;
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 0 clamp(40px, 6vw, 64px);
}

.design-track {
  display: flex;
  gap: 16px;

  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scroll-padding-inline: var(--design-side-pad);
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;

  padding: 0 var(--design-side-pad);
}

.design-track::-webkit-scrollbar {
  display: none;
}

.design-item {
  flex: 0 0 auto;
  width: clamp(220px, 27vw, 300px);
  scroll-snap-align: start;
}

.design-card {
  width: 100%;
  aspect-ratio: 4 / 5;
  border-radius: 26px;
  background: var(--card-bg);
  margin-bottom: 16px;
  overflow: hidden;
}

.design-card-media {
  display: block;
  width: 100%;
  height: 100%;
}

.design-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.design-card--centered {
  display: flex;
  align-items: center;
  justify-content: center;
}

.design-card--centered .design-card-media {
  height: 85%;
  width: auto;
}

.design-card--centered .design-card-media img {
  width: auto;
  height: 100%;
  object-fit: initial;
}

.design-card--shift-down .design-card-media img {
  object-position: 50% calc(50% + 5px);
}

.design-caption {
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0 10px;
}

.design-caption strong {
  color: var(--text-main);
  font-weight: 600;
}

.design-nav {
  position: sticky;
  bottom: var(--design-nav-gap);
  margin-top: var(--design-nav-gap);
  z-index: 70;

  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;

  width: 100%;
  pointer-events: none;
}

.design-nav-btn {
  pointer-events: auto;

  width: 56px;
  height: 56px;

  display: grid;
  place-items: center;

  border: 1px solid rgb(127 127 127 / 0.10);
  border-radius: 999px;
  background: var(--levitated-button-bg);
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);

  box-shadow:
    0 12px 30px rgb(0 0 0 / 0.10),
    0 4px 10px rgb(0 0 0 / 0.06);

  cursor: pointer;

  opacity: 0;
  filter: blur(20px);
  transform: translateY(120px) scale(0);

  transition:
    opacity 520ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 900ms cubic-bezier(0.34, 1.56, 0.64, 1),
    filter 900ms cubic-bezier(0.16, 1, 0.3, 1),
    background 240ms ease;
}

.design-nav.is-visible .design-nav-btn {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0) scale(1);
}

.design-nav:not(.is-visible) .design-nav-btn {
  pointer-events: none;
}

.design-nav-btn:hover {
  background: var(--accent);
}

.design-nav-btn:hover img {
  filter: var(--back-link-icon-filter-hover);
}

.design-nav.is-visible .design-nav-btn.is-pressed,
.design-nav.is-visible .design-nav-btn:hover.is-pressed {
  transform: scale(0.85);

  transition:
    transform 420ms cubic-bezier(0.22, 1, 0.36, 1),
    background 240ms ease;
}

.design-nav-btn img {
  width: 16px;
  height: 26px;
  object-fit: contain;
  pointer-events: none;
  filter: var(--back-link-icon-filter);
  transition: filter 200ms ease;
}

.design-nav-btn:disabled {
  cursor: default;
  pointer-events: none;
}

.design-nav-btn:disabled img {
  opacity: 0.35;
}

.section {
  margin-top: clamp(40px, 5vw, 64px);
  padding: clamp(40px, 6vw, 64px) clamp(24px, 5vw, 48px);
  background: var(--card-bg);
  border-radius: 26px;
}

/* Text and waterfall sit side by side in the same layer (no overlap).
   Narrow: text on top (2/5 of the card height), cards below (3/5) —
   the waterfall's height is set in JS to keep that ratio and its
   overflow is cropped. Wide: even left/right 50/50 split, each sized
   by its own natural content. */
.student-review {
  display: flex;
  flex-direction: column;
  border-radius: 32px;
}

.student-review-text {
  text-align: center;
}

/* Reuses .design-eyebrow/.design-title/.design-description for matching
   typography, minus the max-width/spacing tuned for sitting above a
   full-bleed design-track carousel. */
.student-review-text .design-title,
.student-review-text .design-description {
  max-width: none;
}

.student-review-text .design-description {
  margin-bottom: 0;
}

.student-review-waterfall {
  display: flex;
  align-items: flex-start;
  gap: clamp(12px, 2vw, 20px);
  margin-top: 0;
  /* Bleed past .section's own bottom padding so the waterfall touches
     the card's bottom edge directly, no gap. Left/right pull in past
     .section's (wider) side padding too, so the waterfall's distance
     from the card's edges matches the gap between the cards inside it. */
  margin-bottom: clamp(-64px, -6vw, -40px);
  margin-left: calc(clamp(12px, 2vw, 20px) - clamp(24px, 5vw, 48px));
  margin-right: calc(clamp(12px, 2vw, 20px) - clamp(24px, 5vw, 48px));
  overflow: hidden;

  /* Softens the edge where the waterfall meets the text — top (nearest
     the text above) in the vertical layout. */
  --wf-fade: linear-gradient(to bottom, transparent 0%, black 25%);
  mask-image: var(--wf-fade);
  -webkit-mask-image: var(--wf-fade);
}

.student-review-column {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(12px, 2vw, 20px);
  will-change: transform;
}

.student-review-card {
  flex: none;
  border-radius: 20px;
  background: var(--card-bg);
  padding: clamp(14px, 2.2vw, 18px);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.student-review-card > * {
  opacity: 0.7;
}

.review-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.review-card-title {
  margin: 0 0 4px;
  font-size: 16px;
  font-weight: 700;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.review-card-stars {
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--text-main);
}

.review-card-meta {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  font-size: 12px;
  color: var(--text-soft);
  white-space: nowrap;
  text-align: right;
}

.review-card-context {
  margin: -6px 0 0;
  font-size: 12px;
  color: var(--text-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.review-card-body {
  margin: 0;
  font-size: 14px;
  line-height: 1.3;
  color: var(--text-main);
}

@media (min-width: 901px) {
  .student-review {
    flex-direction: row;
    align-items: flex-start;
    gap: 0;
  }

  .student-review-text {
    text-align: left;
    flex: 1 1 0;
    min-width: 0;
  }

  .student-review-waterfall {
    flex: 1 1 0;
    min-width: 0;
    /* Bleed past .section's own vertical padding so the waterfall
       touches the card's top/bottom edges directly, no gap. Left stays
       at 0 (that side touches the text, not the card edge — pulling it
       in here would overlap them); right still pulls in to match the
       gap between the cards inside the waterfall. */
    margin-top: clamp(-64px, -6vw, -40px);
    margin-bottom: clamp(-64px, -6vw, -40px);
    margin-left: 0;
    margin-right: calc(clamp(12px, 2vw, 20px) - clamp(24px, 5vw, 48px));

    --wf-fade: linear-gradient(to right, transparent 0%, black 33%);
  }
}

.section:not(.student-review) h2 {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.1;
  margin: 0 0 16px;
  text-align: center;
}

.section:not(.student-review) > p {
  font-size: clamp(16px, 1.6vw, 19px);
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
  text-align: center;
}

footer {
  width: 100vw;
  position: relative;
  left: 50%;
  margin-left: -50vw;

  background: var(--card-bg);
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 66px clamp(20px, 5vw, 40px);

  font-size: 13px;
  color: var(--text-soft);
}

.footer-icon {
  width: 50px;
  height: 50px;
  overflow: hidden;
}

.footer-icon img {
  width: 100%;
  height: 100%;
}

.footer-columns {
  display: flex;
  align-items: flex-start;
  gap: var(--footer-gap, 64px);

  width: 100%;
}

.footer-icon-col {
  flex: 0 0 auto;
}

.footer-links-grid {
  flex: 1 1 auto;
  min-width: 0;

  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: var(--footer-gap, 64px);
}

.footer-column {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;

  min-width: 120px;
}

.footer-column-title {
  font-size: 16px;
  font-weight: 500;
  color: var(--text-main);
  margin: 0;
}

footer a {
  font-size: 16px;
  font-weight: 300;
  color: var(--text-soft);
  text-decoration: none;
  transition: color 200ms ease;
}

footer a:hover {
  color: var(--text-main);
}

.footer-socials {
  display: flex;
  align-items: center;
  gap: 16px;
}

.footer-socials img {
  width: 18px;
  height: 18px;
  object-fit: contain;
  pointer-events: none;
  filter: var(--icon-filter);
  transition: filter 200ms ease;
}

.footer-socials a:hover img {
  filter: var(--icon-filter-hover);
}
