/* Dyyno landing page. Standalone (served apart from the app), plain CSS, no build step.
   Colours follow the app's tokens (backend/app/static/css/tokens.css) plus the Dyyno logo teal. */

:root {
  --navy-950: #0f1a30;
  --navy-900: #14203a;
  --navy-800: #1b2a4a;
  --blue-600: #2b5ea7;
  --teal-600: #0d9488;
  --teal-500: #14b8a6;
  --teal-300: #5eead4;
  --gold-500: #c5a059;
  --slate-50: #f8fafc;
  --slate-100: #f1f5f9;
  --slate-200: #e2e8f0;
  --slate-300: #cbd5e1;
  --slate-500: #64748b;
  --slate-600: #475569;
  --slate-700: #334155;
  --slate-900: #0f172a;
  --white: #ffffff;

  --text: var(--slate-900);
  --text-muted: var(--slate-600);
  --surface: var(--white);
  --surface-tint: var(--slate-50);
  --border: var(--slate-200);
  --accent: var(--teal-600);
  --accent-strong: #0b7f75;

  --font: "Source Sans 3", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.08);
  --shadow: 0 10px 30px -12px rgba(15, 23, 42, 0.25);
  --shadow-lg: 0 30px 60px -20px rgba(15, 23, 42, 0.45);
  --max: 1160px;
  --gutter: 24px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px; /* sticky header; 120px on tablets and phones (two-row menu) */
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--accent-strong);
}

h1,
h2,
h3 {
  line-height: 1.2;
  margin: 0;
  letter-spacing: -0.01em;
}

p {
  margin: 0;
}

:focus-visible {
  outline: 3px solid var(--teal-500);
  outline-offset: 3px;
  border-radius: 4px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--white);
  color: var(--navy-900);
  font-weight: 700;
  border-radius: var(--radius-sm);
}

.skip-link:focus {
  top: 12px;
}

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.container--narrow {
  max-width: 760px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 10px 22px;
  font: inherit;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn--primary {
  background: var(--accent);
  color: var(--white);
}

.btn--primary:hover {
  background: var(--accent-strong);
}

.btn--ghost-light {
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.35);
  background: transparent;
}

.btn--ghost-light:hover {
  border-color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.btn--large {
  min-height: 54px;
  padding: 12px 30px;
  font-size: 1.0625rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(20, 32, 58, 0.92);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 68px;
}

/* horizontal logo (mark + wordmark, white version for the navy header and footer) */
.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.brand img {
  height: 40px;
  width: auto;
}

.brand--footer img {
  height: 30px;
}

.site-nav__links {
  display: flex;
  gap: 4px;
  margin: 0 0 0 auto;
  padding: 0;
  list-style: none;
}

.site-nav__links a {
  display: block;
  padding: 8px 12px;
  color: rgba(255, 255, 255, 0.82);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius-sm);
}

.site-nav__links a:hover,
.site-nav__links a[aria-current="page"] {
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.site-nav__login {
  min-height: 40px;
  padding: 6px 18px;
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  color: var(--white);
  background:
    radial-gradient(900px 500px at 85% 10%, rgba(20, 184, 166, 0.22), transparent 60%),
    radial-gradient(700px 500px at 0% 100%, rgba(43, 94, 167, 0.35), transparent 60%),
    var(--navy-900);
}

.hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  align-items: center;
  gap: 56px;
  padding-top: 88px;
  padding-bottom: 96px;
}

.eyebrow {
  margin-bottom: 14px;
  color: var(--teal-300);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.eyebrow--dark {
  color: var(--accent-strong);
}

.hero h1 {
  font-size: clamp(2.2rem, 4.6vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.hero__lead {
  margin-top: 22px;
  max-width: 36em;
  color: rgba(255, 255, 255, 0.82);
  font-size: 1.2rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.hero__visual {
  position: relative;
  padding-bottom: 40px;
}

/* Screenshot frames */
.frame {
  margin: 0;
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-lg);
}

.frame--browser {
  position: relative;
  padding-top: 30px;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: var(--slate-100);
}

.frame__dots {
  position: absolute;
  top: 10px;
  left: 14px;
  display: flex;
  gap: 6px;
}

.frame__dots i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--slate-300);
}

.frame--phone {
  width: 200px;
  border: 7px solid var(--navy-950);
  border-radius: 30px;
}

.hero .frame--phone {
  position: absolute;
  right: -10px;
  bottom: 0;
  width: 34%;
  max-width: 210px;
}

.frame--paper {
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

/* Sections */
.section {
  padding: 88px 0;
}

.section--tint {
  background: var(--surface-tint);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section--navy {
  color: var(--white);
  background: var(--navy-900);
}

.section__title {
  max-width: 22em;
  margin-bottom: 40px;
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  font-weight: 800;
}

.grid {
  display: grid;
  gap: 24px;
}

.grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.point,
.feature {
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.point h3,
.feature h3 {
  margin-bottom: 10px;
  font-size: 1.2rem;
  font-weight: 700;
}

.point p,
.feature p {
  color: var(--text-muted);
}

.feature {
  position: relative;
  padding-top: 34px;
}

.feature::before {
  content: "";
  position: absolute;
  top: 0;
  left: 28px;
  width: 44px;
  height: 4px;
  border-radius: 0 0 4px 4px;
  background: var(--accent);
}

/* Showcase */
.showcase {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  align-items: center;
  gap: 56px;
}

.showcase + .showcase {
  margin-top: 96px;
}

.showcase--reverse .showcase__copy {
  order: 2;
}

.showcase__title {
  margin-bottom: 14px;
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  font-weight: 800;
}

.showcase__copy p:not(.eyebrow) {
  color: var(--text-muted);
  font-size: 1.125rem;
}

.showcase .frame--paper {
  max-height: 560px;
}

.showcase__phones {
  display: flex;
  justify-content: center;
  gap: 24px;
}

.showcase__phones .frame--phone {
  width: 46%;
  max-width: 250px;
}

.showcase__phones .frame--phone:last-child {
  margin-top: 48px;
}

.note {
  margin-top: 48px;
  color: var(--slate-500);
  font-size: 0.9rem;
  text-align: center;
}

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: none;
}

.step {
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.step__num {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-bottom: 16px;
  color: var(--white);
  font-weight: 800;
  background: var(--navy-800);
  border-radius: 50%;
}

.step h3 {
  margin-bottom: 8px;
  font-size: 1.2rem;
}

.step p {
  color: var(--text-muted);
}

/* Security */
.security__item {
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.04);
}

.security__item h3 {
  margin-bottom: 10px;
  color: var(--white);
  font-size: 1.2rem;
}

.security__item p {
  color: rgba(255, 255, 255, 0.78);
}

.security__more {
  margin-top: 32px;
  text-align: center;
}

/* FAQ */
.faq {
  border-bottom: 1px solid var(--border);
}

.faq summary {
  position: relative;
  padding: 20px 40px 20px 0;
  font-size: 1.125rem;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--accent);
  font-size: 1.6rem;
  font-weight: 400;
  line-height: 1;
}

.faq[open] summary::after {
  content: "\2212";
}

.faq p {
  padding-bottom: 20px;
  color: var(--text-muted);
}

/* School login finder */
.login-card .section__title {
  margin-bottom: 12px;
}

.login-card > p {
  margin-bottom: 24px;
  color: var(--text-muted);
}

.finder {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
}

.finder__field {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 0 16px;
  background: var(--white);
  border: 2px solid var(--slate-300);
  border-radius: var(--radius-sm);
}

.finder__field:focus-within {
  border-color: var(--accent);
}

.finder__prefix,
.finder__suffix {
  color: var(--slate-500);
  white-space: nowrap;
}

.finder input {
  flex: 1;
  min-width: 0;
  padding: 12px 2px;
  font: inherit;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--text);
  border: 0;
  outline: none;
  background: transparent;
}

.finder .btn {
  border-radius: var(--radius-sm);
}

.finder__help,
.finder__error {
  grid-column: 1 / -1;
  font-size: 0.95rem;
}

.finder__help {
  color: var(--text-muted);
}

.finder__error {
  color: #b42318;
}

/* Call to action */
.cta {
  color: var(--white);
  text-align: center;
  background:
    radial-gradient(700px 300px at 50% 0%, rgba(20, 184, 166, 0.25), transparent 70%),
    var(--navy-950);
}

.cta__inner {
  padding-top: 88px;
  padding-bottom: 88px;
}

.cta h2 {
  font-size: clamp(1.75rem, 3vw, 2.4rem);
  font-weight: 800;
}

.cta__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.cta p {
  margin: 12px 0 28px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.15rem;
}

/* Demo video */
.video__title {
  margin-bottom: 12px;
}

.video__lead {
  max-width: 46em;
  margin-bottom: 28px;
  color: var(--text-muted);
}

.video__frame {
  overflow: hidden;
  border-radius: var(--radius-lg, 16px);
  background: var(--navy-900);
  box-shadow: 0 30px 70px -30px rgba(15, 23, 42, 0.45);
  aspect-ratio: 16 / 9;
}

.video__player {
  display: block;
  width: 100%;
  height: 100%;
}

/* Demo request form */
.request__title {
  margin-bottom: 12px;
}

.request__lead {
  margin-bottom: 28px;
  color: var(--text-muted);
}

.request {
  display: grid;
  gap: 18px;
}

.request__row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.request__field {
  display: grid;
  gap: 6px;
}

.request__label {
  font-weight: 700;
}

.request__optional {
  font-weight: 400;
  color: var(--text-muted);
}

.request input,
.request select,
.request textarea {
  width: 100%;
  padding: 12px 14px;
  font: inherit;
  color: var(--text);
  background: var(--white);
  border: 2px solid var(--slate-300);
  border-radius: var(--radius-sm);
}

.request input:focus,
.request select:focus,
.request textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.request textarea {
  resize: vertical;
}

.request__trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.request__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
}

.request__fineprint {
  flex: 1 1 260px;
  font-size: 0.95rem;
  color: var(--text-muted);
}

@media (max-width: 640px) {
  .request__row {
    grid-template-columns: 1fr;
  }

  .request__actions .btn {
    width: 100%;
  }
}

/* Footer */
.site-footer {
  color: rgba(255, 255, 255, 0.7);
  background: var(--navy-950);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 32px;
  padding-top: 32px;
  padding-bottom: 32px;
}



.site-footer__links {
  display: flex;
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer__links a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
}

.site-footer__links a:hover {
  color: var(--white);
  text-decoration: underline;
}

.site-footer__copy {
  flex-basis: 100%;
  font-size: 0.875rem;
}

/* "How Dyyno uses your Google account" */
.google-data__lead {
  margin: -16px 0 28px;
  color: var(--text-muted);
  font-size: 1.125rem;
}

.google-data .point p a {
  font-weight: 600;
}

/* Legal pages (privacy, terms) */
.legal {
  padding: 64px 0 88px;
}

.legal h1 {
  font-size: clamp(2rem, 4vw, 2.6rem);
  font-weight: 800;
  color: var(--navy-900);
}

.legal__updated {
  margin: 8px 0 32px;
  color: var(--slate-500);
}

.legal h2 {
  margin: 40px 0 12px;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--navy-900);
}

.legal h3 {
  margin: 24px 0 8px;
  font-size: 1.1rem;
  font-weight: 700;
}

.legal p + p,
.legal p + ul,
.legal ul + p {
  margin-top: 12px;
}

.legal ul {
  margin: 8px 0 0;
  padding-left: 22px;
}

.legal li + li {
  margin-top: 6px;
}

.legal code {
  font-size: 0.95em;
  padding: 1px 5px;
  background: var(--slate-100);
  border-radius: 4px;
}

/* Tablet */
@media (max-width: 960px) {
  .hero__inner,
  .showcase {
    grid-template-columns: minmax(0, 1fr);
    gap: 40px;
  }

  .hero__inner {
    padding-top: 64px;
    padding-bottom: 72px;
  }

  .showcase--reverse .showcase__copy {
    order: 0;
  }

  .grid--3,
  .steps {
    grid-template-columns: minmax(0, 1fr);
  }

  html {
    scroll-padding-top: 120px;
  }

  /* the menu moves to a second row that scrolls sideways instead of disappearing */
  .site-nav {
    flex-wrap: wrap;
    row-gap: 0;
  }

  .site-nav__links {
    order: 3;
    width: 100%;
    margin: 0 0 8px;
    gap: 0;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .site-nav__links a {
    padding: 6px 6px;
    font-size: 0.95rem;
    white-space: nowrap;
  }

  .site-nav__login {
    margin-left: auto;
  }
}

/* Phone */
@media (max-width: 640px) {
  :root {
    --gutter: 16px;
  }

  body {
    font-size: 1rem;
  }

  .section {
    padding: 64px 0;
  }

  .section__title {
    margin-bottom: 28px;
  }

  .grid--2 {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero__lead {
    font-size: 1.075rem;
  }

  .hero__actions .btn {
    flex: 1 1 100%;
  }

  .hero .frame--phone {
    right: 0;
    width: 38%;
  }

  .showcase + .showcase {
    margin-top: 64px;
  }

  .showcase__phones {
    gap: 14px;
  }

  .finder {
    grid-template-columns: minmax(0, 1fr);
  }

  .finder__prefix {
    display: none;
  }

  .finder input {
    font-size: 16px; /* no iOS zoom on focus */
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn {
    transition: none;
  }

  .btn:hover {
    transform: none;
  }
}
