:root {
  --ink: #16161a;
  --paper: #f4f4f5;
  --night: #1f1f1f;
  --night-2: #16161a;
  --accent: #FF5074;
  --accent-2: rgba(224, 91, 117, 0.187);
  --nav-bg: transparent;
  --nav-text: #f5f5f7;
  font-size: 16px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 76px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  font-family: "Poppins", system-ui, sans-serif;
  background: var(--night);
  color: var(--ink);
  overflow-x: hidden;
}

h1, h2, .logo-word {
  font-family: "Playfair Display", Georgia, serif;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ---------------------------------------------------------------- NAV */

#nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px clamp(20px, 5vw, 64px);
  background: var(--nav-bg);
  color: var(--nav-text);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: background 0.45s ease, color 0.45s ease;
}

#nav .logo svg { width: 30px; height: auto; color: inherit; }

.nav-links {
  display: flex;
  gap: clamp(20px, 4vw, 44px);
  font-size: 0.98rem;
}

.nav-links a { opacity: 0.88; transition: opacity 0.2s ease; }
.nav-links a:hover { opacity: 1; }

#nav-toggle {
  display: none;
  position: relative;
  z-index: 2;              /* stays above the open drawer */
  background: none;
  border: none;
  width: 40px; height: 40px;
  margin-right: -8px;
  align-items: center;
  justify-content: center;
  color: inherit;          /* follows --nav-text, just like the logo */
  cursor: pointer;
  padding: 0;
  border-radius: 12px;
  transition: color 0.45s ease, background 0.2s ease;
}
#nav-toggle:hover { background: color-mix(in srgb, currentColor 10%, transparent); }
#nav-toggle svg {
  width: 26px; height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.3s ease, opacity 0.2s ease;
}
#nav-toggle .icon-close { position: absolute; opacity: 0; transform: rotate(-90deg); }
#nav-toggle[aria-expanded="true"] { color: #f5f5f7; }
#nav-toggle[aria-expanded="true"] .icon-menu { opacity: 0; transform: rotate(90deg); }
#nav-toggle[aria-expanded="true"] .icon-close { opacity: 1; transform: none; }
#nav-toggle[aria-expanded="true"] .icon-close { color: var(--accent); }

@media (max-width: 720px) {
  #nav-toggle { display: flex; }
  .nav-links {
    position: fixed;
    top: 0; right: 0;
    height: 100vh;
    width: min(72vw, 300px);
    background: var(--night-2);
    color: #f5f5f7;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 28px;
    padding: 40px;
    font-size: 1.15rem;
    transform: translateX(100%);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
  }
  .nav-links.open { transform: translateX(0); box-shadow: -20px 0 60px rgba(0, 0, 0, 0.35); }
}

/* ---------------------------------------------------------------- HERO */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle, var(--night) 0%, #000 100%);
  color: #f5f5f7;
  text-align: center;
  padding: 140px 24px 100px;
  overflow: hidden;
}

/* Wavy line pattern — the real asset, with the accent color baked
   directly into its fill. Using it as a plain, tiled background-image
   (rather than a CSS mask) avoids the cross-browser inconsistencies
   around mask-mode and intrinsic SVG sizing that made it fail to
   render before. Per-section opacity still varies its strength. */
.wave-layer {
  position: absolute;
  inset: 0;
  z-index: 0;
  left: -500px;
  bottom: -50px;
  overflow: hidden;
  pointer-events: none;
  background-image: url("../assets/images/bg_pattern2.svg");
  background-repeat: no-repeat;
  background-position: left bottom;
  background-size: auto 70%;
}


.hero .wave-layer { opacity: 0.22; }
.disciplines .wave-layer { opacity: 0.16; }
.work .wave-layer { opacity: 0.2; }
.contact .wave-layer { opacity: 0.14; }
.pricing .wave-layer { opacity: 0.12; }
.faq .wave-layer { opacity: 0.16; }

/* Soft rounded "blob" shapes peeking from section corners — the
   recurring motif in the reference design. Clipped by each section's
   overflow so they read as tucked half behind the edge. */
.hero::before,
.disciplines::before, .disciplines::after,
.work::before, .work::after {
  content: "";
  position: absolute;
  border-radius: 42px;
  z-index: 0;
  pointer-events: none;
}

.hero::before {
  top: -36px; left: -36px;
  width: 150px; height: 150px;
  transform: rotate(18deg);
  background: rgba(245, 245, 247, 0.05);
}

.disciplines::before {
  top: -28px; left: -36px;
  width: 170px; height: 170px;
  transform: rotate(15deg);
  background: rgba(22, 22, 26, 0.05);
}
.disciplines::after {
  bottom: -60px; right: -50px;
  width: 220px; height: 220px;
  border-radius: 54px;
  transform: rotate(-14deg);
  background: rgba(255, 80, 116, 0.07);
}

.work::before {
  top: -30px; left: -36px;
  width: 170px; height: 170px;
  transform: rotate(12deg);
  background: rgba(245, 245, 247, 0.035);
}
.work::after {
  bottom: -60px; right: -46px;
  width: 200px; height: 200px;
  border-radius: 48px;
  transform: rotate(-18deg);
  background: rgba(245, 245, 247, 0.035);
}

.gradient-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  z-index: 0;
  opacity: 0.35;
}
.orb1 { width: 320px; height: 320px; background: var(--accent-2); top: -80px; left: -60px; }
.orb2 { width: 260px; height: 260px; background: var(--accent); bottom: -60px; right: 6%; }
.orb3 { width: 180px; height: 180px; background: #ffffff; top: 40%; right: -60px; opacity: 0.06; }

.hero-content { position: relative; z-index: 1; max-width: 780px; }

.hero-eyebrow {
  font-size: clamp(1.6rem, 4.5vw, 2.6rem);
  font-weight: 300;
  margin: 0 0 18px;
  color: #e7e7ea;
}

.scene {
  position: relative;
  display: inline-block;
  margin-bottom: 28px;
}

.hero-wordmark {
  font-size: clamp(2.4rem, 8vw, 4.6rem);
  font-weight: 700;
  margin: 0;
  padding: 6px 14px;
  color: #fff;
  text-align: center;
}

/* ---- Hero artboard (js/hero.js): a small design app making the wordmark.
   The <h1> stays for screen readers; the artboard draws it. */
.scene.is-animated { display: block; margin: 0 auto 28px; }
.scene.is-animated .hero-wordmark {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; padding: 0;
}
.artboard {
  position: relative; width: min(680px, 92vw); height: clamp(184px, 27vw, 200px); margin: 0 auto;
  border-radius: 18px; border: 1px solid rgba(255, 255, 255, 0.07);
  background: radial-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1.2px) 0 0 / 18px 18px, rgba(255, 255, 255, 0.015);
  text-align: left;
}
.ab-tools {
  position: absolute; left: 10px; top: 50%; transform: translateY(-50%); z-index: 4;
  display: grid; gap: 4px; padding: 5px; border-radius: 12px;
  background: rgba(22, 22, 26, 0.85); border: 1px solid rgba(255, 255, 255, 0.08);
}
.ab-tools span { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 8px; color: #8d8d96; transition: background .2s, color .2s; }
.ab-tools span.on { background: var(--accent); color: #fff; }
.ab-tools svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ab-stage { position: absolute; inset: 0 0 0 46px; transition: opacity .45s; }
.ab-stage.fading { opacity: 0; }
.ab-cursor { position: absolute; left: 0; top: 0; width: 26px; height: 26px; z-index: 6; pointer-events: none;
  margin-left: 46px; transition: scale .12s; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, .5)); }
.ab-cursor.down { scale: 0.86; }
.ab-cursor svg { width: 100%; height: 100%; display: block; }

.ab-word { position: absolute; margin: 0; white-space: nowrap; line-height: 1; color: #fff;
  font-family: "Playfair Display", Georgia, serif; font-weight: 700; }
.ab-word--soft { animation: ab-in .6s ease both; }
@keyframes ab-in { from { opacity: 0; transform: translateX(-10px); } }
.ab-accent { color: var(--accent); font-style: italic; }
.ab-caret { display: inline-block; width: 2px; height: 0.9em; margin-left: 2px; vertical-align: -0.08em;
  background: var(--accent); animation: ab-blink 1s steps(1) infinite; }
@keyframes ab-blink { 50% { opacity: 0; } }

.ab-sel { position: absolute; border: 1.5px solid var(--accent); pointer-events: none; transition: opacity .25s; }
.ab-sel.gone { opacity: 0; }
.ab-sel i { position: absolute; width: 8px; height: 8px; background: #16161a; border: 1.5px solid var(--accent); border-radius: 2px;
  transform: translate(-50%, -50%); }
.ab-sel i[data-h="tl"] { top: 0; left: 0; } .ab-sel i[data-h="tc"] { top: 0; left: 50%; } .ab-sel i[data-h="tr"] { top: 0; left: 100%; }
.ab-sel i[data-h="ml"] { top: 50%; left: 0; } .ab-sel i[data-h="mr"] { top: 50%; left: 100%; }
.ab-sel i[data-h="bl"] { top: 100%; left: 0; } .ab-sel i[data-h="bc"] { top: 100%; left: 50%; } .ab-sel i[data-h="br"] { top: 100%; left: 100%; }
.ab-size { position: absolute; left: 50%; top: calc(100% + 10px); transform: translateX(-50%); padding: 2px 7px; border-radius: 5px;
  background: var(--accent); color: #fff; font: 600 10px/1.4 "Poppins", sans-serif; white-space: nowrap; }

.ab-mark { position: absolute; overflow: visible; }
.ab-stroke { fill: transparent; stroke: #fff; stroke-width: 0.9; transition: fill .6s; }
.ab-mark.filled .ab-stroke { fill: #fff; stroke: transparent; transition: fill .6s, stroke .6s; }
.ab-anchor { opacity: 0; transition: opacity .2s; }
.ab-anchor.on { opacity: 1; }
.ab-anchor.gone { opacity: 0; transition: opacity .5s; }
.ab-anchor rect { fill: #16161a; stroke: var(--accent); stroke-width: 0.5; }
.ab-anchor line { stroke: var(--accent); stroke-width: 0.35; }
.ab-anchor circle { fill: var(--accent); }

.ab-panel { position: absolute; right: 8px; top: 50%; width: 132px; padding: 9px; border-radius: 12px; z-index: 3;
  background: #1c1c22; border: 1px solid rgba(255, 255, 255, 0.09); box-shadow: 0 14px 30px rgba(0, 0, 0, .45);
  font: 500 11px/1.3 "Poppins", sans-serif; color: #d6d6dc; opacity: 0; transform: translate(8px, -50%); transition: opacity .3s, transform .3s; }
.ab-panel.show { opacity: 1; transform: translate(0, -50%); }
.ab-panel p { margin: 0 0 6px; font-size: 10px; color: #8d8d96; }
.ab-field span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ab-field { display: flex; gap: 4px; justify-content: space-between; padding: 6px 8px; border-radius: 7px; background: #26262e; }
.ab-field i { font-style: normal; color: #8d8d96; }
.ab-list { display: none; margin-top: 4px; padding: 4px; border-radius: 8px; background: #26262e; }
.ab-panel.open .ab-list { display: grid; gap: 2px; }
.ab-list span { padding: 5px 6px; border-radius: 5px; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ab-list span.hover { background: rgba(255, 80, 116, 0.25); color: #fff; }
.ab-swatches { display: flex; gap: 6px; margin-top: 8px; }
.ab-swatches span { width: 18px; height: 18px; border-radius: 50%; border: 2px solid #1c1c22; box-shadow: 0 0 0 1px rgba(255, 255, 255, .15); }
.ab-swatches span.on { box-shadow: 0 0 0 2px #fff; }

.ab-code { position: absolute; left: 4px; top: 50%; width: min(300px, 46%); border-radius: 12px; overflow: hidden;
  background: #121216; border: 1px solid rgba(255, 255, 255, 0.08); box-shadow: 0 14px 30px rgba(0, 0, 0, .45);
  opacity: 0; transform: translate(-8px, -50%); transition: opacity .3s, transform .3s; }
.ab-code.show { opacity: 1; transform: translate(0, -50%); }
.ab-tabs { padding: 6px 10px; background: #1b1b21; font: 500 10px "Poppins", sans-serif; color: #b9b9c2; }
.ab-code pre { margin: 0; padding: 9px 11px; min-height: 96px; font: 500 clamp(9.5px, 1.6vw, 12px)/1.55 ui-monospace, "Cascadia Code", Consolas, monospace;
  color: #d6d6dc; white-space: pre; }
.ab-code b { all: unset; } .ab-code .c-tg { color: #ff7a95; } .ab-code .c-pr { color: #A6A8FF; } .ab-code .c-kw { color: #7fd1c7; } .ab-code .c-vl { color: #f5c26b; }
.ab-caret--code { height: 1em; width: 1.5px; }
.ab-render { transition: color .3s; }
.ab-render em { font-style: italic; transition: color .3s; }
.ab-render.pink em { color: var(--accent); }
@media (max-width: 600px) {
  .ab-tools { left: 6px; padding: 4px; gap: 2px; }
  .ab-tools span { width: 22px; height: 22px; }
  .ab-stage { left: 36px; }
  .ab-cursor { margin-left: 36px; }
  .ab-panel { width: 116px; padding: 7px; font-size: 10px; }
  .ab-panel p { display: none; }
  .ab-list span { padding: 3px 5px; font-size: 10.5px; }
  .ab-swatches { margin-top: 6px; }
  .ab-swatches span { width: 15px; height: 15px; }
}

.hero-sub {
  font-size: 1.05rem;
  line-height: 1.7;
  color: #c9c9ce;
  max-width: 46ch;
  margin: 0 auto;
}

.scroll-cue {
  position: absolute;
  bottom: 34px; left: 50%;
  transform: translateX(-50%);
  width: 42px; height: 42px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.06);
  color: var(--accent);
  animation: bob 2.2s ease-in-out infinite;
  z-index: 1;
}
@keyframes bob { 0%,100% { transform: translate(-50%,0); } 50% { transform: translate(-50%,6px); } }

/* --------------------------------------------------------- SECTIONS */

.section {
  position: relative;
  overflow: hidden;
  padding: 110px clamp(20px, 6vw, 90px);
}

/* Keep real content above the wave-layer mask sitting behind it. */
.section > *:not(.wave-layer) {
  position: relative;
  z-index: 1;
}

.section-title { max-width: 640px; margin: 0 auto 56px; text-align: center; }
.section-title h2 { font-size: clamp(1.9rem, 4vw, 2.6rem); margin: 0 0 14px; }
.section-title p { font-size: 1.02rem; line-height: 1.7; color: inherit; opacity: 0.75; margin: 0; }

/* Disciplines — rounded card overlapping the hero's bottom edge */
.disciplines {
  background: var(--paper);
  border-radius: 48px 48px 0 0;
  margin-top: -48px;
  z-index: 2;
}
.discipline-grid {
  max-width: 940px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 40px;
  align-items: start;
}
.discipline-icon { font-size: 1.6rem; color: var(--accent); display: inline-block; margin-bottom: 14px; }
.discipline h3 { margin: 0 0 6px; font-size: 1.35rem; }
.discipline-tag { color: var(--accent); font-weight: 500; margin: 0 0 14px; }
.discipline p:last-child { line-height: 1.8; opacity: 0.8; margin: 0; }
.discipline-divider {
  align-self: center;
  font-size: 1.4rem;
  color: #b8b8bd;
}
@media (max-width: 680px) {
  .discipline-grid { grid-template-columns: 1fr; text-align: left; }
  .discipline-divider { display: none; }
}

/* Work */
.work { background: var(--night); color: #f5f5f7; }
.work .section-title p { color: #d8d8dc; }
.work-card-header { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
/* The SR app icon (same SVG as the app: sr-web/public/sr_white.svg) */
.sr-mark { width: 40px; height: 40px; flex: none; display: block; }

.work-badge {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.work-shot {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 20px;
  border: 1px solid rgba(255,255,255,0.08);
}

.ghost-btn, .solid-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 11px 22px;
  border-radius: 100px;
  font-size: 0.92rem;
  font-weight: 500;
  cursor: pointer;
  border: none;
}
.ghost-btn {
  border: 1.5px solid var(--accent);
  color: var(--accent);
  background: transparent;
}
.ghost-btn:hover { background: var(--accent); color: #fff; }

/* Contact */
.contact { background: var(--paper); }
.contact-grid {
  max-width: 940px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 56px;
  align-items: start;
}
@media (max-width: 760px) {
  .contact-grid { grid-template-columns: 1fr; }
}

.contact-form { display: flex; flex-direction: column; gap: 18px; }
.contact-form label { display: flex; flex-direction: column; gap: 6px; font-size: 0.9rem; }
.contact-form input, .contact-form textarea {
  font: inherit;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1.5px solid #d9d9dd;
  background: #fff;
  resize: vertical;
}
.contact-form input:focus, .contact-form textarea:focus {
  outline: none;
  border-color: var(--accent);
}
.solid-btn {
  background: var(--accent);
  color: #fff;
  align-self: flex-start;
}
.solid-btn:hover { background: #e6335f; }
.solid-btn:disabled { opacity: 0.6; cursor: wait; }
.form-status { font-size: 0.88rem; min-height: 1.2em; margin: 0; }
.form-status.ok { color: #1a8f4c; }
.form-status.err { color: #d33; }

.socials-container {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-content: flex-start;
}
.socials-container a {
  width: 46px; height: 46px;
  border-radius: 50%;
  background: #fff;
  border: 1.5px solid #e2e2e6;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink);
  transition: transform 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}
.socials-container a svg { width: 20px; height: 20px; fill: currentColor; }
.socials-container a:hover {
  transform: translateY(-3px);
  color: var(--accent-color, var(--accent));
  border-color: var(--accent-color, var(--accent));
}

/* Footer */
#footer {
  background: var(--night);
  color: #b8b8bd;
  text-align: center;
  padding: 40px 24px 32px;
}
#footer .logo svg { width: 26px; margin: 0 auto 14px; color: #f5f5f7; }
#footer-p { margin: 0; font-size: 0.85rem; }

/* --------------------------------------------------------- SR */

.nav-links .nav-cta {
  opacity: 1;
  padding: 6px 16px;
  border: 1.5px solid var(--accent);
  border-radius: 100px;
  color: var(--accent);
}
.nav-links .nav-cta:hover { background: var(--accent); color: #fff; }

.text-link { color: var(--accent); }
.text-link:hover { text-decoration: underline; }

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

.sr-intro {
  max-width: 1100px;
  margin: 0 auto 80px;
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}
.sr-eyebrow { color: var(--accent); font-weight: 500; }
.sr-intro h2 { font-size: clamp(1.9rem, 4vw, 2.6rem); line-height: 1.2; margin: 14px 0 16px; }
.sr-intro p { line-height: 1.8; color: #d8d8dc; margin: 0 0 28px; }
@media (max-width: 860px) {
  .sr-intro { grid-template-columns: 1fr; }
}

.feature-grid {
  max-width: 1100px;
  margin: 0 auto 56px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
@media (max-width: 1100px) { .feature-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 960px) { .feature-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .feature-grid { grid-template-columns: 1fr; } }
.feature {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px;
  padding: 26px;
}
.feature svg, .edition svg {
  width: 26px; height: 26px;
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.feature h3 { font-size: 1.05rem; margin: 14px 0 8px; display: flex; align-items: center; gap: 8px; }
.feature p { margin: 0; line-height: 1.7; font-size: 0.93rem; color: #c9c9ce; }

.editions {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.edition {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 26px;
  border-radius: 20px;
  background: rgba(255, 80, 116, 0.07);
  border: 1px solid rgba(255, 80, 116, 0.22);
}
.edition svg { flex: none; margin-top: 2px; }
.edition h3 { margin: 0 0 6px; font-size: 1.05rem; display: flex; align-items: center; gap: 8px; }
.edition p { margin: 0; line-height: 1.7; font-size: 0.93rem; color: #d8d8dc; }
.edition a { color: var(--accent); }
.pill {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 9px;
  border-radius: 100px;
  background: var(--accent);
  color: #fff;
}
@media (max-width: 760px) {
  .editions { grid-template-columns: 1fr; }
}

/* Pricing */
.pricing { background: var(--paper); }

.period-toggle {
  display: flex;
  width: fit-content;
  margin: -24px auto 36px;
  padding: 5px;
  border-radius: 100px;
  background: #fff;
  border: 1.5px solid #e2e2e6;
}
.period-toggle button {
  font: inherit;
  font-size: 0.9rem;
  border: none;
  background: none;
  padding: 8px 18px;
  border-radius: 100px;
  cursor: pointer;
  color: var(--ink);
  display: flex; align-items: center; gap: 8px;
}
.period-toggle button[aria-checked="true"] { background: var(--ink); color: #fff; }
.save {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--accent);
}
.save:empty { display: none; }

.plan-grid {
  max-width: 1040px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  align-items: stretch;
}
@media (max-width: 900px) {
  .plan-grid { grid-template-columns: 1fr; max-width: 460px; }
}
.plan {
  position: relative;
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1.5px solid #e2e2e6;
  border-radius: 24px;
  padding: 32px;
}
.plan--featured { border-color: var(--accent); box-shadow: 0 20px 50px rgba(255, 80, 116, 0.14); }
.plan-flag {
  position: absolute;
  top: -13px; left: 32px;
  background: var(--accent);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 100px;
}
.plan h3 { margin: 0 0 4px; font-size: 1.25rem; }
.plan-tag { margin: 0 0 20px; color: #6b6b73; font-size: 0.92rem; }
.plan-price { margin: 0 0 4px; }
.plan-per { margin: 0 0 22px; font-size: 0.82rem; color: #6b6b73; }
.plan-price span { font-family: "Playfair Display", Georgia, serif; font-size: 2.2rem; font-weight: 700; }
.plan-price small { color: #6b6b73; font-size: 0.9rem; }
.plan ul { list-style: none; padding: 0; margin: 0 0 28px; display: grid; gap: 10px; flex: 1; }
.plan li { display: flex; gap: 10px; font-size: 0.93rem; line-height: 1.5; }
.plan li svg {
  flex: none;
  width: 18px; height: 18px; margin-top: 2px;
  fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round;
}
.plan-btn { justify-content: center; align-self: stretch; }

.cloud-includes { max-width: 1040px; margin: 40px auto 0; text-align: center; }
.cloud-includes h3 { font-size: 1.05rem; margin: 0 0 16px; }
.cloud-includes ul {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 26px;
}
.cloud-includes li { display: flex; gap: 8px; font-size: 0.92rem; }
.cloud-includes li svg {
  flex: none; width: 18px; height: 18px; margin-top: 2px;
  fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round;
}

.plan--wide {
  max-width: 1040px;
  margin: 48px auto 0;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 24px 40px;
}
.plan--wide h3 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin-bottom: 8px; }
.plan--wide .plan-tag { margin: 0; max-width: 60ch; line-height: 1.6; }
.plan--wide .plan-btn { align-self: center; flex: none; }
.plan-price-inline { font-family: "Playfair Display", Georgia, serif; font-size: 1.5rem; }
.plan-price-inline small { font-family: "Poppins", system-ui, sans-serif; font-size: 0.85rem; color: #6b6b73; font-weight: 400; }
@media (max-width: 760px) {
  .plan--wide { flex-direction: column; align-items: stretch; }
  .plan--wide .plan-btn { align-self: stretch; }
}

.plan-note {
  max-width: 640px;
  margin: 22px auto 0;
  text-align: center;
  font-size: 0.88rem;
  color: #6b6b73;
  line-height: 1.6;
}
.plan-note + .cloud-includes { max-width: 1040px; margin: 40px auto 0; text-align: center; }
.cloud-includes h3 { font-size: 1.05rem; margin: 0 0 16px; }
.cloud-includes ul {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 26px;
}
.cloud-includes li { display: flex; gap: 8px; font-size: 0.92rem; }
.cloud-includes li svg {
  flex: none; width: 18px; height: 18px; margin-top: 2px;
  fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round;
}

.plan--wide {
  max-width: 1040px;
  margin: 48px auto 0;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 24px 40px;
}
.plan--wide h3 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin-bottom: 8px; }
.plan--wide .plan-tag { margin: 0; max-width: 60ch; line-height: 1.6; }
.plan--wide .plan-btn { align-self: center; flex: none; }
.plan-price-inline { font-family: "Playfair Display", Georgia, serif; font-size: 1.5rem; }
.plan-price-inline small { font-family: "Poppins", system-ui, sans-serif; font-size: 0.85rem; color: #6b6b73; font-weight: 400; }
@media (max-width: 760px) {
  .plan--wide { flex-direction: column; align-items: stretch; }
  .plan--wide .plan-btn { align-self: stretch; }
}

.plan-note { margin-top: 8px; }

.steps { max-width: 1000px; margin: 80px auto 0; }
.steps h3 { text-align: center; font-size: 1.3rem; margin: 0 0 28px; }
.steps ol {
  list-style: none;
  counter-reset: step;
  padding: 0; margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 26px;
}
.steps li { counter-increment: step; display: flex; flex-direction: column; gap: 6px; }
.steps li::before {
  content: counter(step);
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  font-weight: 600;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 6px;
}
.steps li span { font-size: 0.92rem; line-height: 1.65; color: #55555c; }

/* FAQ */
.faq-list { max-width: 760px; margin: 0 auto; display: grid; gap: 12px; }
.faq-list details {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 0 22px;
}
.faq-list summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 28px 18px 0;
  font-weight: 500;
  position: relative;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
  content: "+";
  position: absolute;
  right: 0; top: 50%;
  transform: translateY(-50%);
  color: var(--accent);
  font-size: 1.3rem;
  transition: transform 0.2s ease;
}
.faq-list details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq-list details p { margin: 0 0 20px; line-height: 1.75; color: #c9c9ce; font-size: 0.95rem; }

/* Footer links */
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 22px;
  margin-bottom: 16px;
  font-size: 0.88rem;
}
.footer-links a:hover { color: #f5f5f7; }

/* --------------------------------------------------- SUBPAGES */

.page {
  background: var(--paper);
  min-height: 100vh;
  padding: 130px clamp(20px, 6vw, 90px) 90px;
}
.page-narrow { max-width: 760px; margin: 0 auto; }
.page h1 { font-size: clamp(2rem, 5vw, 2.8rem); margin: 0 0 10px; }
.page .lede { color: #55555c; line-height: 1.7; margin: 0 0 40px; }

/* Legal */
.legal h2 { font-size: 1.35rem; margin: 40px 0 12px; }
.legal p, .legal li { line-height: 1.8; color: #2f2f35; }
.legal ul { padding-left: 22px; }
.legal a { color: var(--accent); }
.legal .updated { color: #6b6b73; font-size: 0.9rem; margin: 0 0 32px; }

/* Checkout */
.checkout-grid {
  max-width: 1040px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 40px;
  align-items: start;
}
@media (max-width: 860px) {
  .checkout-grid { grid-template-columns: 1fr; }
}
.checkout-form { display: flex; flex-direction: column; gap: 22px; }
.checkout-form fieldset {
  border: 1.5px solid #e2e2e6;
  background: #fff;
  border-radius: 20px;
  padding: 24px;
  margin: 0;
  display: grid;
  gap: 16px;
}
.checkout-form legend { font-weight: 600; padding: 0 8px; margin-left: -8px; }
.checkout-form label { display: flex; flex-direction: column; gap: 6px; font-size: 0.9rem; }
.checkout-form .hint { font-size: 0.8rem; color: #6b6b73; }
.checkout-form input, .checkout-form select {
  font: inherit;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1.5px solid #d9d9dd;
  background: #fff;
  color: var(--ink);
  width: 100%;
}
.checkout-form input:focus, .checkout-form select:focus { outline: none; border-color: var(--accent); }
.checkout-form input[aria-invalid="true"] { border-color: #d33; }
.checkout-form .agree { flex-direction: row; align-items: flex-start; gap: 10px; line-height: 1.6; }
.checkout-form .agree input { width: 18px; height: 18px; margin-top: 3px; flex: none; accent-color: var(--accent); }
.checkout-form .agree input[aria-invalid="true"] { outline: 2px solid #d33; outline-offset: 2px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) {
  .field-row { grid-template-columns: 1fr; }
}

.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.choice-grid--3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 560px) {
  .choice-grid { grid-template-columns: 1fr; }
}
.choice {
  position: relative;
  border: 1.5px solid #d9d9dd;
  border-radius: 14px;
  padding: 14px 16px;
  cursor: pointer;
}
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice strong { display: block; font-size: 0.95rem; }
.choice span { font-size: 0.82rem; color: #6b6b73; }
.choice:has(input:checked) { border-color: var(--accent); background: rgba(255, 80, 116, 0.05); }
.choice:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }

.summary {
  position: sticky;
  top: 100px;
  background: var(--ink);
  color: #f5f5f7;
  border-radius: 24px;
  padding: 28px;
}
.summary h2 { font-size: 1.3rem; margin: 0 0 18px; }
.summary dl { margin: 0 0 18px; display: grid; gap: 10px; }
.summary dl div { display: flex; justify-content: space-between; gap: 16px; font-size: 0.92rem; }
.summary dt { color: #b8b8bd; }
.summary dd { margin: 0; text-align: right; }
.summary .total {
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: 16px;
  margin-bottom: 22px;
  display: flex; justify-content: space-between; align-items: baseline;
}
.summary .total strong { font-family: "Playfair Display", Georgia, serif; font-size: 1.8rem; }
.summary .solid-btn { width: 100%; justify-content: center; }
.summary .fine { font-size: 0.78rem; color: #b8b8bd; line-height: 1.6; margin: 16px 0 0; }
.summary .fine a { color: #f5f5f7; text-decoration: underline; }
.pay-methods { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.pay-methods span {
  font-size: 0.72rem;
  padding: 3px 10px;
  border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.18);
  color: #d8d8dc;
}

.notice {
  border-radius: 14px;
  padding: 14px 16px;
  font-size: 0.88rem;
  line-height: 1.6;
  background: #fff6e0;
  border: 1px solid #f1d58a;
  color: #5c4500;
}
.done {
  max-width: 620px;
  margin: 0 auto;
  text-align: center;
  background: #fff;
  border: 1.5px solid #e2e2e6;
  border-radius: 24px;
  padding: 44px 32px;
}
.done h1 { font-size: 2rem; }
.done p { line-height: 1.75; color: #3a3a40; }
.done code { background: var(--paper); padding: 2px 8px; border-radius: 6px; }

/* --------------------------------------------------------- REVEAL */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.hero.reveal { opacity: 1; transform: none; } /* hero is visible on load, no scroll-in needed */

/* "Launching soon" bar (js/script.js, while SR_SITE.launched is false) */
.launch-bar {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  z-index: 120;
  width: min(760px, calc(100% - 32px));
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px 12px 18px;
  border-radius: 16px;
  background: var(--night-2);
  color: #f5f5f7;
  font-size: 0.88rem;
  line-height: 1.5;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}
.launch-bar span { flex: 1; }
.launch-bar strong { color: var(--accent); font-weight: 600; }
.launch-bar a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.launch-bar button {
  flex: none;
  width: 32px; height: 32px;
  border: 0; border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: #fff; font-size: 1.2rem; line-height: 1;
  cursor: pointer;
}
.launch-bar button:hover { background: rgba(255, 255, 255, 0.2); }
.soon-pill {
  display: inline-block;
  margin-bottom: 12px;
  padding: 4px 12px;
  border-radius: 999px;
  background: #fff6e0;
  border: 1px solid #f1d58a;
  color: #5c4500;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

/* =====================================================================
   Homepage: hero buttons, SR intro, stat strip, demo player
   ===================================================================== */

.hero-cta { justify-content: center; margin-top: 34px; }
.ghost-btn svg, .solid-btn svg { width: 16px; height: 16px; fill: currentColor; }
.ghost-btn--light { border-color: rgba(245, 245, 247, 0.4); color: #f5f5f7; }
.ghost-btn--light:hover { background: #f5f5f7; border-color: #f5f5f7; color: var(--ink); }
.ghost-btn, .solid-btn { transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease; }
.solid-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(255, 80, 116, 0.3); }

.section-title .kicker {
  color: var(--accent);
  opacity: 1;
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 10px;
}
.section-title--spaced { margin-top: 110px; }

/* SR intro: a light card that overlaps the hero's bottom edge */
.sr {
  background: var(--paper);
  border-radius: 48px 48px 0 0;
  margin-top: -48px;
  z-index: 2;
  padding-bottom: 90px;
}
.sr .wave-layer { opacity: 0.12; }
.sr .sr-intro p { color: #4a4a52; }
.sr .sr-eyebrow { font-family: "Playfair Display", Georgia, serif; font-size: 1.6rem; font-weight: 700; color: var(--ink); letter-spacing: 0.02em; }
.accent-word { color: var(--accent); font-style: italic; }

/* The SR intro sits above the device showcase, centred. */
.sr .sr-intro { grid-template-columns: 1fr; max-width: 760px; margin-bottom: 56px; text-align: center; }
.sr .sr-intro .work-card-header, .sr .sr-intro .btn-row { justify-content: center; }

/* SR on the school PC, a tablet and a phone: the designer's device frames
   (inline SVG) with real screenshots, placed in percentages so the group
   scales as one picture. The tablet stands in front of the monitor's
   corner and the phone in front of the tablet. */
.devices { position: relative; max-width: 1100px; margin: 0 auto 90px; aspect-ratio: 1.72; }
.dev { position: absolute; display: block; height: auto; overflow: visible; }
.dev-monitor { left: 0; top: 0; width: 70%; filter: drop-shadow(0 30px 40px rgba(22, 22, 26, 0.16)); }
.dev-tablet { right: 9%; bottom: 0; width: 25%; filter: drop-shadow(0 24px 36px rgba(22, 22, 26, 0.28)); }
.dev-phone { right: 0; bottom: 0; width: 11.5%; filter: drop-shadow(0 20px 28px rgba(22, 22, 26, 0.32)); }

/* SR's toasts, as notices around the devices. */
.sr-toast { position: absolute; z-index: 3; display: flex; align-items: flex-start; gap: 10px; padding: 11px 16px 11px 12px;
  border-radius: 12px; background: #fff; border: 1px solid #e0e2f6; box-shadow: 0 14px 34px rgba(22, 22, 26, 0.14);
  font-family: "Work Sans", system-ui, sans-serif; text-align: left; animation: float 6s ease-in-out infinite; }
.sr-toast .ic { width: 30px; height: 30px; flex: none; border-radius: 9px; display: grid; place-items: center; }
.sr-toast svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.sr-toast b { display: block; font-size: 0.86rem; font-weight: 600; }
.sr-toast small { display: block; font-size: 0.76rem; color: #535b66; margin-top: 2px; white-space: nowrap; }
.sr-toast--ok .ic { background: #EDF7ED; color: #1E7D32; }
.sr-toast--ok b { color: #1E7D32; }
.sr-toast--ind .ic { background: #DFDFF5; color: #1D1A5E; }
.sr-toast--ind b { color: #1D1A5E; }
.toast-1 { left: -2%; top: 46%; }
.toast-2 { right: 3%; top: 4%; animation-delay: -3s; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@media (max-width: 760px) {
  .sr-toast { display: none; }
}

.stat-strip {
  list-style: none;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.stat-strip li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2px 14px;
  align-items: center;
  padding: 20px;
  border-radius: 20px;
  background: #fff;
  border: 1.5px solid #e9e9ec;
  transition: transform 0.25s ease, border-color 0.25s ease;
}
.stat-strip li:hover { transform: translateY(-4px); border-color: var(--accent); }
.stat-strip svg {
  grid-row: span 2;
  width: 44px; height: 44px; padding: 10px;
  border-radius: 14px;
  background: rgba(255, 80, 116, 0.1);
  fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}
.stat-strip strong { font-size: 0.98rem; }
.stat-strip span { font-size: 0.83rem; color: #6b6b73; line-height: 1.45; }
@media (max-width: 960px) { .stat-strip { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .stat-strip { grid-template-columns: 1fr; } }

.feature { transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease; }
.feature:hover { transform: translateY(-4px); border-color: rgba(255, 80, 116, 0.4); background: rgba(255, 255, 255, 0.05); }

#about { padding-bottom: 40px; }
#about + .contact { padding-top: 70px; }

/* --------------------------------------------------- demo player */

.demo-tabs {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 980px;
  margin: -20px auto 26px;
}
.demo-tabs button {
  position: relative;
  overflow: hidden;
  display: flex; align-items: center; gap: 9px;
  font: inherit; font-size: 0.92rem;
  padding: 11px 20px;
  border-radius: 100px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: #c9c9ce;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.demo-tabs button:hover { color: #fff; border-color: rgba(255, 255, 255, 0.3); }
.demo-tabs button[aria-selected="true"] { background: #f5f5f7; color: var(--ink); border-color: #f5f5f7; }
.demo-tabs svg {
  width: 18px; height: 18px;
  fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}
.demo-tabs button[aria-selected="true"] svg { stroke: var(--accent); }
.tab-progress {
  position: absolute; left: 0; bottom: 0;
  height: 3px; width: 0;
  background: var(--accent);
}
@media (max-width: 600px) {
  .demo-tabs { display: grid; grid-template-columns: 1fr 1fr; }
  .demo-tabs button { justify-content: center; padding: 10px 12px; font-size: 0.85rem; }
}

.demo-stage {
  --s: 1;
  position: relative;
  max-width: 1040px;
  margin: 0 auto;
  height: 585px;
}
.demo-caption {
  max-width: 640px;
  margin: 26px auto 0;
  text-align: center;
  color: #c9c9ce;
  line-height: 1.7;
  min-height: 3.4em;
}

/* The pretend SR window, copied from screenshots of the desktop app.
   Laid out at the app's real size, 1280×720, and scaled by --s (js/demo.js).
   Colours are SR's default indigo theme (sr-desktop/ui/CustomColors). */
.app {
  --ind: #A6A8FF;          /* indigo secondary */
  --on-ind: #1D1A5E;
  --tert: #DFDFF5;
  --surface: #eef2fa;
  --border: #e0e2f6;
  --ink: #1c1c24;
  --muted: #535b66;
  --navy: #1D1A5E;
  position: absolute; top: 0; left: 0;
  width: 1280px; height: 720px;
  transform: scale(var(--s));
  transform-origin: top left;
  background: #fff;
  color: var(--ink);
  font-family: "Work Sans", system-ui, sans-serif;
  font-size: 15px;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.08);
  animation: app-in 0.45s ease both;
  user-select: none;
}
@keyframes app-in { from { opacity: 0; transform: scale(var(--s)) translateY(14px); } }
.app svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.app b, .app strong { font-weight: 600; }
.grow { flex: 1; }

/* chips (Chip.qml) */
.ch { display: inline-flex; align-items: center; padding: 3px 12px; border-radius: 100px; font-size: 13px; font-weight: 500; white-space: nowrap; }
.ch.green { background: #bbffba; color: #085f05; }
.ch.peach { background: #fde0bf; color: #5a2d12; }
.ch.blue { background: #b8cefd; color: #164b8b; }
.ch.pink { background: #ffbbdc; color: #6e123d; }
.ch.lav { background: var(--tert); color: var(--on-ind); }
.ch.plain { background: var(--surface); color: var(--ink); }
.ch.outline { background: #fff; border: 1px solid var(--border); color: var(--ink); }

/* --- window frame (Main.qml) --- */
.dk-title { height: 30px; display: flex; align-items: center; padding: 0 0 0 10px; }
.dk-s { width: 18px; height: 18px; flex: none; object-fit: contain; }    /* the SR mark */
.dk-win { margin-left: auto; display: flex; }
.dk-win i { width: 46px; text-align: center; font-style: normal; font-size: 13px; color: #444; }
.dk-top { position: relative; height: 62px; margin: 0 8px; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: center; }
.dk-term {
  position: absolute; left: 0; bottom: 2px;
  padding: 3px 14px; border-radius: 8px 8px 2px 2px;
  background: var(--ind); color: var(--on-ind); font-weight: 700; font-size: 13.5px;
}
.dk-tabs { display: flex; gap: 4px; padding: 4px; border-radius: 30px; background: var(--surface); }
.dk-tabs span { position: relative; padding: 8px 22px; border-radius: 22px; color: var(--muted); font-size: 15px; }
.dk-tabs span.on { background: #141419; color: #fff; font-weight: 700; }
.dk-tabs span.on::after { content: ""; position: absolute; left: 50%; bottom: 3px; width: 26px; height: 3px; margin-left: -13px; border-radius: 2px; background: var(--ind); }
.dk-end { position: absolute; right: 0; display: flex; align-items: center; gap: 18px; }
.dk-round { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); color: var(--muted); font-size: 18px; flex: none; }
.dk-round.outline { background: #fff; border: 1.5px solid var(--border); color: var(--ink); }
.dk-round.lg { width: 42px; height: 42px; font-size: 20px; }
.dk-out { background: #FDE8E8; color: #B00020; }
.dk-theme { width: 50px; height: 28px; border-radius: 100px; border: 1.5px solid var(--border); position: relative; }
.dk-theme i { position: absolute; top: 2px; left: 2px; width: 21px; height: 21px; border-radius: 50%; background: var(--border); display: grid; place-items: center; color: #fff; font-size: 13px; }
.dk-body { position: relative; height: calc(100% - 93px); padding: 12px 8px 8px; }
.dk-date {
  position: absolute; right: 0; top: 230px; padding: 12px 5px; border-radius: 10px 0 0 10px;
  background: var(--ind); color: var(--on-ind); font-weight: 700; font-size: 12.5px;
  writing-mode: vertical-rl; transform: rotate(180deg);
}
.dk-panel { background: var(--surface); border-radius: 12px; padding: 10px; min-width: 0; }
.dk-combo-l { display: grid; gap: 5px; color: var(--muted); font-size: 13px; }
.dk-combo, .dk-input {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  height: 34px; padding: 0 12px; border-radius: 8px; background: #fff; border: 1.5px solid var(--border);
  color: var(--on-ind); font-weight: 600; font-size: 14px; font-variant-numeric: tabular-nums;
}
.dk-input.focus { border-color: var(--ind); }
.dk-input.focus::after { content: "|"; color: var(--ind); font-weight: 400; animation: blink 0.7s steps(1) infinite; }
.dk-input.off { color: var(--ink); }
@keyframes blink { 50% { opacity: 0; } }
.pill-soft { padding: 9px 26px; border-radius: 100px; background: var(--tert); color: var(--on-ind); font-weight: 500; transition: background 0.25s, color 0.25s; }
.pill-soft.ready { background: var(--navy); color: var(--ind); }
.pill-outline { padding: 5px 14px; border-radius: 100px; border: 1.5px solid var(--border); background: #fff; font-weight: 500; font-size: 14px; }
.pressed { transform: scale(0.94) !important; filter: brightness(0.94); }

.av { width: 34px; height: 34px; border-radius: 50%; flex: none; display: grid; place-items: center; background: #eceef8; border: 2px solid #e2e4f3; color: #b9bdd6; font-size: 20px; }
.av.big { width: 78px; height: 78px; border-width: 4px; font-size: 44px; }

.app-toast {
  position: absolute; left: 50%; bottom: 22px;
  display: flex; align-items: center; gap: 10px;
  padding: 11px 18px 11px 12px; border-radius: 14px;
  background: var(--ink); color: #fff; font-weight: 500;
  transform: translate(-50%, 30px); opacity: 0;
  transition: transform 0.35s ease, opacity 0.35s ease; z-index: 20;
}
.app-toast svg { width: 22px; height: 22px; padding: 3px; border-radius: 50%; background: #22a35a; stroke-width: 3; }
.app-toast.show { transform: translate(-50%, 0); opacity: 1; }

.demo-cursor {
  position: absolute; top: 0; left: 0; width: 28px; height: 28px; margin: -3px 0 0 -4px;
  transform: translate(1150px, 600px);
  transition-property: transform; transition-timing-function: cubic-bezier(0.45, 0, 0.2, 1);
  pointer-events: none; z-index: 30;
}
.demo-cursor .ptr { width: 28px; height: 28px; fill: var(--ink); stroke: #fff; stroke-width: 1.5; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.3)); }
.demo-cursor::after {
  content: ""; position: absolute; left: 4px; top: 3px; width: 36px; height: 36px; margin: -18px 0 0 -18px;
  border-radius: 50%; background: rgba(255, 80, 116, 0.45); transform: scale(0); opacity: 0;
}
.demo-cursor.tap::after { animation: tap 0.45s ease-out; }
@keyframes tap { 0% { transform: scale(0.2); opacity: 1; } 100% { transform: scale(1.4); opacity: 0; } }
.demo-cursor--finger { margin: 0; }
.demo-cursor--finger i { position: absolute; left: -15px; top: -15px; width: 30px; height: 30px; border-radius: 50%; background: rgba(28, 28, 36, 0.35); border: 2px solid #fff; box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3); }
.demo-cursor--finger::after { left: 0; top: 0; }

/* --- Attendance (AttendancePage.qml) --- */
.at-toolbar { display: flex; align-items: flex-end; gap: 14px; padding: 0 4px 18px; }
.at-toolbar .dk-combo { width: 210px; }
.day { width: 36px; height: 58px; border-radius: 18px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; background: var(--surface); color: var(--muted); font-size: 12px; position: relative; }
.day b { font-size: 14px; color: var(--ink); }
.day.on { background: var(--ind); color: var(--on-ind); }
.day.on b { color: var(--on-ind); }
.day i { position: absolute; bottom: 6px; width: 4px; height: 4px; border-radius: 50%; background: #fff; }
.at-toolbar .dk-round, .at-toolbar .pill-soft { align-self: center; }
.at-table { margin: 0 4px; }
.at-head, .at-row { display: grid; grid-template-columns: 70px 1fr 260px 280px; align-items: center; }
.at-head { height: 40px; padding: 0 10px; background: var(--surface); border-radius: 6px 6px 0 0; font-weight: 700; font-size: 14px; }
.at-row { height: 48px; padding: 0 10px; border-bottom: 1px solid var(--border); }
.at-row.alt { background: #f6f8fd; }
.at-row .nm { display: grid; line-height: 1.25; }
.at-row .nm b { font-weight: 500; font-size: 15.5px; }
.at-row .nm small { color: var(--muted); font-size: 12px; }
.rate { display: flex; align-items: center; gap: 8px; }
.rate i { width: 150px; height: 9px; border-radius: 5px; background: #fbd8e0; overflow: hidden; }
.rate u { display: block; height: 100%; background: #ef9fb3; transition: width 0.5s ease; }
.rate em { font-style: normal; font-size: 14px; color: var(--muted); }
.status { display: flex; align-items: center; gap: 10px; justify-content: flex-start; }
.at-head .status { gap: 14px; }
.marked { padding: 3px 12px; border-radius: 100px; background: #141419; color: #fff; font-size: 11px; font-weight: 500; opacity: 0; transition: opacity 0.3s; }
.marked.show { opacity: 1; }
.tg { height: 32px; min-width: 32px; padding: 0 9px; border-radius: 100px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1.5px solid var(--border); background: #fff; color: var(--ink); font-size: 15px; transition: background 0.2s, color 0.2s, border-color 0.2s; }
.tg em { display: none; font-style: normal; font-size: 13.5px; }
.tg.p.on { background: #bbffba; border-color: #bbffba; color: #085f05; padding: 0 14px; }
.tg.a.on { background: #ffbbdc; border-color: #ffbbdc; color: #6e123d; padding: 0 14px; }
.tg.p.on em, .tg.a.on em { display: inline; }
.tg.e.on { background: var(--tert); border-color: var(--tert); color: var(--on-ind); }

/* --- Students page (StudentsPage.qml) --- */
.st-toolbar { display: flex; align-items: center; gap: 22px; padding: 0 4px 12px; }
.dk-search { display: flex; gap: 4px; padding: 4px; border-radius: 22px; background: var(--surface); width: 300px; }
.dk-search .seg { display: flex; align-items: center; gap: 22px; padding: 6px 12px; border-radius: 18px 6px 6px 18px; background: var(--tert); font-size: 14px; }
.dk-search .field { flex: 1; display: flex; align-items: center; justify-content: space-between; padding: 6px 12px; border-radius: 6px 18px 18px 6px; background: var(--tert); color: #a2a6c6; font-size: 14px; }
.dk-search .field svg { color: var(--ink); font-size: 17px; }
.st-cols { display: grid; grid-template-columns: 500px 1fr 305px; gap: 10px; height: calc(100% - 52px); }
.st-head { display: flex; align-items: center; justify-content: space-between; padding: 4px 4px 10px; }
.st-head strong { font-size: 15px; color: var(--muted); font-weight: 700; }
.st-head > span { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; }
.st-row { display: flex; align-items: center; gap: 10px; height: 39px; padding: 0 10px; background: #fff; border-bottom: 1px solid var(--border); }
.st-row:nth-child(odd) { background: #f8f9fe; }
.st-row.sel { background: var(--ind); border-radius: 8px; border-color: transparent; }
.st-id { width: 72px; color: var(--muted); font-size: 13px; }
.st-flower { color: #d7d8f4; font-size: 12px; }
.st-row.sel .st-flower { color: #fff; }
.st-name { flex: 1; font-size: 15px; }
.st-row.sel .st-name { font-weight: 700; color: var(--on-ind); }
.st-cls { font-size: 13px; color: var(--muted); padding: 3px 11px; }
.st-cls.chip { background: var(--surface); border-radius: 100px; }
.st-row.sel .st-cls { background: #e6e7ff; color: var(--on-ind); }
.pf-head { display: flex; align-items: center; gap: 14px; padding: 2px 0 12px; }
.pf-head strong { font-size: 21px; font-weight: 700; display: block; margin-bottom: 8px; }
.chips { display: flex; gap: 8px; }
.card { background: #fff; border-radius: 10px; padding: 12px 14px; margin-bottom: 10px; }
.card > strong { font-size: 16px; font-weight: 700; display: block; margin-bottom: 10px; }
.info { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.info span { display: grid; color: var(--muted); font-size: 13.5px; }
.info b { color: var(--ink); font-size: 14px; }
.gd { display: flex; align-items: center; justify-content: space-between; padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px 8px 0 0; color: var(--muted); }
.gd-phone { padding: 8px 12px; background: var(--surface); border-radius: 0 0 8px 8px; font-weight: 700; }
.pays { display: grid; gap: 10px; }
.pay { background: #fff; border-radius: 10px; padding: 10px 12px; }
.pay.fresh { animation: slide-in 0.5s ease both; box-shadow: 0 0 0 2px #22a35a; }
@keyframes slide-in { from { opacity: 0; transform: translateY(-16px); } }
.pay-title { font-size: 13px; color: var(--muted); }
.pay-box { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 10px; margin: 8px 0; padding: 10px; border-radius: 10px; background: var(--surface); }
.pay-box span { display: grid; gap: 4px; justify-items: start; font-size: 12.5px; color: var(--muted); }
.pay-box .ch { font-weight: 600; }
.pay-foot { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.pay-foot span:first-child { flex: 1; }
.print { width: 64px; height: 38px; border-radius: 100px; background: var(--navy); color: var(--ind); display: grid; place-items: center; font-size: 19px; transition: transform 0.12s; }

/* context menu (StudentContextMenu.qml) */
.ctx {
  position: absolute; z-index: 15; width: 190px; padding: 6px;
  background: #fff; border: 1px solid var(--border); border-radius: 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  opacity: 0; transform: scale(0.92); transform-origin: top left; transition: opacity 0.15s, transform 0.15s; pointer-events: none;
}
.ctx.show { opacity: 1; transform: none; }
.ctx span { display: flex; align-items: center; gap: 12px; padding: 7px 10px; border-radius: 8px; font-size: 14px; }
.ctx span svg { color: var(--ind); font-size: 17px; }
.ctx span.pressed { background: var(--tert); transform: none !important; }
.ctx i { display: block; height: 1px; margin: 4px 6px; background: var(--border); }

/* form popup (forms/PaymentForm.qml) */
.dk-modal { position: absolute; inset: 0; display: flex; align-items: flex-start; justify-content: center; padding-top: 50px; opacity: 0; pointer-events: none; transition: opacity 0.2s; z-index: 12; }
.dk-modal.show { opacity: 1; }
.form { width: 450px; background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 8px; box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2); transform: scale(0.9); transition: transform 0.15s ease-out; }
.dk-modal.show .form { transform: none; }
.form-title { display: flex; align-items: center; justify-content: space-between; padding: 8px 10px 12px; font-size: 17px; font-weight: 700; color: var(--muted); }
.form-title svg { font-size: 20px; color: var(--muted); }
.form-box { background: var(--surface); border-radius: 8px; padding: 12px; }
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 10px; }
.grid label { display: grid; gap: 6px; color: var(--muted); font-size: 14px; }
.grid label i { color: #e53935; font-style: normal; }
.form-foot { display: flex; justify-content: flex-end; padding: 12px 6px 4px; }

/* Doc Viewer (views/DocViewer.qml) */
.doc { position: absolute; inset: 40px 40px 14px; z-index: 14; background: #fff; border-radius: 14px; border: 1px solid var(--border); box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25); padding: 8px; opacity: 0; transform: scale(0.94); transition: opacity 0.25s, transform 0.25s; pointer-events: none; }
.doc.show { opacity: 1; transform: none; }
.doc-title { position: relative; text-align: center; padding: 8px 0 12px; font-size: 17px; font-weight: 700; color: var(--muted); }
.doc-title span { position: absolute; right: 14px; top: 8px; color: var(--on-ind); font-size: 20px; }
.doc-area { position: relative; height: calc(100% - 46px); background: var(--surface); border-radius: 10px; overflow: hidden; }
.sheet { width: 760px; margin: 0 auto; background: #fff; padding: 18px 28px; border-left: 2px solid #000; border-right: 2px solid #000; font-size: 13px; transition: transform 1.2s ease; }
.sheet.scrolled { transform: translateY(-40px); }
.sh-head { display: flex; align-items: center; gap: 20px; }
.crest { width: 82px; height: 82px; border-radius: 50%; border: 4px solid #1c1c24; display: grid; place-items: center; font-weight: 800; font-size: 26px; color: #1c1c24; flex: none; }
.sh-school { flex: 1; display: grid; justify-items: center; gap: 2px; font-size: 13px; }
.sh-school strong { font-size: 22px; font-weight: 700; }
.photo { position: relative; width: 82px; height: 90px; border-radius: 8px; background: #eceafe; display: grid; place-items: center; color: #8b85f5; font-size: 50px; }
.photo b { position: absolute; bottom: -8px; left: 50%; transform: translateX(-50%); padding: 2px 10px; border-radius: 100px; background: #000; color: #fff; font-size: 11px; }
.sh-band { position: relative; display: flex; justify-content: center; margin: 18px 0 14px; }
.sh-band::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 2px; background: #8b85f5; }
.sh-band span { position: relative; padding: 5px 60px; border-radius: 15px; background: #000; color: #fff; font-weight: 700; font-size: 14px; }
.sh-name { display: flex; justify-content: space-between; margin-bottom: 12px; font-size: 14px; }
.sh-name b { font-size: 16px; font-weight: 700; margin-left: 8px; }
.sh-boxes { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-bottom: 14px; }
.sh-boxes.sum { grid-template-columns: repeat(5, 1fr); margin-top: 14px; }
.sh-boxes span { display: grid; justify-items: center; padding: 6px 4px; border: 1.5px solid #8b85f5; border-radius: 8px; font-size: 12.5px; }
.sh-boxes b { font-weight: 700; font-size: 13px; }
.sheet table { width: 100%; border-collapse: collapse; font-size: 13px; }
.sheet th { padding: 6px 4px; border-top: 1px solid #000; border-bottom: 2px solid #000; font-weight: 700; font-size: 12px; }
.sheet td { padding: 7px 8px; text-align: center; border-bottom: 1px solid #e5e5e5; }
.sheet td:first-child { text-align: left; }
.sheet tr:nth-child(even) td { background: #eceafe; }
.doc-side { position: absolute; right: 34px; top: 40px; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--tert); color: var(--on-ind); font-size: 20px; }
.doc-print { position: absolute; right: 18px; bottom: 82px; width: 92px; height: 54px; border-radius: 100px; display: grid; place-items: center; background: var(--on-ind); color: #fff; font-size: 24px; transition: transform 0.12s; }
.doc-share { position: absolute; right: 34px; bottom: 22px; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: #fff; border: 1.5px solid var(--border); font-size: 20px; }

/* --- On the phone: the web app's register (AttendancePage, phone layout) --- */
.app--bare { background: radial-gradient(circle at 30% 40%, #2a2a33, #16161a 70%); }
.phone-scene { height: 100%; display: flex; align-items: center; justify-content: center; }
.phone { position: relative; width: 316px; height: 680px; border-radius: 40px; background: #121216; padding: 6px; flex: none;
  box-shadow: 0 0 0 1.5px #3b3b44, inset 0 0 0 1px #26262c, 0 30px 60px rgba(0, 0, 0, 0.5); }
.phone::before, .phone::after { content: ""; position: absolute; right: -4px; width: 3px; border-radius: 0 2px 2px 0; background: #3b3b44; }
.phone::before { top: 150px; height: 52px; }          /* power */
.phone::after { top: 222px; height: 92px; }           /* volume */
.phone-cam { position: absolute; top: 18px; left: 50%; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #2c2f3a 0 25%, #050507 60%); box-shadow: 0 0 0 2px #0b0b0e; z-index: 2; }
.ph { position: relative; height: 100%; border-radius: 34px; background: #fff; padding: 46px 12px 70px; display: flex; flex-direction: column; gap: 9px; overflow: hidden; font-size: 13px; }
.ph-top { display: flex; align-items: center; gap: 8px; }
.ph-day { width: 30px; height: 44px; border-radius: 15px; display: grid; place-items: center; align-content: center; background: var(--surface); font-size: 8px; color: var(--muted); position: relative; }
.ph-day b { font-size: 13px; color: var(--ink); }
.ph-day.on { background: var(--ind); }
.ph-day.on i { position: absolute; bottom: 4px; width: 3px; height: 3px; border-radius: 50%; background: var(--on-ind); }
.ph-dots { width: 36px; height: 36px; border-radius: 50%; border: 1.5px solid var(--border); display: grid; place-items: center; font-size: 18px; }
.ph-chips { display: flex; gap: 6px; }
.ph-chips .ch { font-size: 10px; padding: 3px 8px; }
.ph-class { padding: 6px 10px; border-radius: 6px; background: var(--surface); font-size: 11px; color: var(--muted); }
.ph-row { display: flex; align-items: center; gap: 8px; }
.ph-row .av { width: 38px; height: 38px; font-size: 22px; }
.ph-row .nm { flex: 1; display: grid; gap: 1px; min-width: 0; }
.ph-row .nm b { font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ph-row .nm small { font-size: 10px; color: var(--muted); }
.ph-row .nm i { width: 120px; height: 5px; border-radius: 3px; background: #ecedfb; overflow: hidden; }
.ph-row .nm u { display: block; height: 100%; background: var(--ind); }
.ph-tg { width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid var(--border); display: grid; place-items: center; font-size: 15px; color: var(--muted); transition: background 0.2s, color 0.2s, border-color 0.2s; }
.ph-tg.p.on { background: #bbffba; border-color: #bbffba; color: #085f05; }
.ph-tg.e.on { background: var(--tert); border-color: var(--tert); color: var(--on-ind); }
.ph-nav { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-around; padding: 9px 4px 12px; background: var(--surface); }
.ph-nav span { display: grid; justify-items: center; gap: 3px; font-size: 9.5px; color: var(--muted); }
.ph-nav span svg { width: 42px; height: 22px; padding: 2px 11px; border-radius: 11px; font-size: 18px; }
.ph-nav span.on { color: var(--ink); font-weight: 700; }
.ph-nav span.on svg { background: var(--ind); }
.sync-line { width: 160px; display: flex; justify-content: space-around; flex: none; }
.sync-line i { width: 11px; height: 11px; border-radius: 50%; background: rgba(255, 255, 255, 0.15); }
.sync-line.go i { animation: sync 0.9s ease-in-out infinite; }
.sync-line.go i:nth-child(2) { animation-delay: 0.15s; }
.sync-line.go i:nth-child(3) { animation-delay: 0.3s; }
@keyframes sync { 0%, 100% { background: rgba(255, 255, 255, 0.15); transform: scale(1); } 50% { background: var(--accent); transform: scale(1.5); } }
.mini-pc { width: 400px; border-radius: 16px; background: #fff; overflow: hidden; box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5); flex: none; }
.mini-top { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--border); font-weight: 600; }
.sync-state { margin-left: auto; display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 500; color: var(--muted); }
.sync-state.ok { color: #22a35a; }
.sync-state svg { font-size: 18px; }
.mini-body { padding: 12px; background: var(--surface); display: grid; gap: 8px; }
.mini-row { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-radius: 12px; background: #fff; font-weight: 500; transition: box-shadow 0.3s; }
.mini-row.flash { box-shadow: 0 0 0 2px #22a35a; }

