/* TasselHQ marketing page. Same visual language as the app (web/src/theme):
   EDWIN-OS "Alexeev" theme, warm paper canvas, Inter + Instrument Serif,
   white rounded surfaces, deep green accent and a gold highlight. */

:root {
  --bg: #faf8f4;
  --surface: #ffffff;
  --surface-2: #f4f1ea;
  --border: #e6dfd3;
  --border-subtle: #efe9df;
  --text: #3d3a35;
  --text-strong: #1a1a1a;
  --muted: #6e6e73;
  --label: #8a9188;
  --brand: #1f4d34;
  --brand-ink: #163826;
  --brand-soft: #eef5f0;
  --gold: #d4ad55;

  --sans: Inter, 'Helvetica Neue', Arial, -apple-system, BlinkMacSystemFont, sans-serif;
  --serif: 'Instrument Serif', Georgia, serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --shadow-sm: 0 6px 20px rgba(26, 26, 26, 0.05);
  --shadow-lg: 0 2px 8px rgba(0, 0, 0, 0.04), 0 8px 32px rgba(0, 0, 0, 0.08);
  --glass-bg: linear-gradient(135deg, rgba(255, 255, 255, 0.75) 0%, rgba(255, 255, 255, 0.55) 50%, rgba(255, 255, 255, 0.65) 100%);
  --glass-shadow: 0 2px 8px rgba(0, 0, 0, 0.04), 0 8px 32px rgba(0, 0, 0, 0.08), inset 0 1px 1px rgba(255, 255, 255, 0.6);
  --page: 1160px;
  --gutter: clamp(16px, 4vw, 40px);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: rgba(31, 77, 52, 0.16);
  color: var(--text-strong);
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
}

/* ── Top bar ───────────────────────────────────────────────────────── */
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--glass-bg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: var(--glass-shadow);
  -webkit-backdrop-filter: blur(24px) saturate(1.2);
  backdrop-filter: blur(24px) saturate(1.2);
}

.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--page);
  height: 64px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.topbar__nav {
  display: flex;
  gap: 0.25rem;
}

.brand {
  color: var(--text-strong);
  font-family: var(--serif);
  font-size: 1.625rem;
  line-height: 1;
  letter-spacing: -0.02em;
  text-decoration: none;
  white-space: nowrap;
}

.brand--sm {
  font-size: 1.375rem;
}

.nav-pill {
  display: inline-flex;
  align-items: center;
  height: 36px;
  padding: 0 1.05rem;
  border-radius: 100px;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.3s var(--ease), background 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.nav-pill:hover {
  background: rgba(255, 255, 255, 0.9);
  color: var(--text-strong);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 1px 2px rgba(0, 0, 0, 0.06), 0 2px 8px rgba(0, 0, 0, 0.04);
}

/* ── Buttons ───────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  padding: 0 1.6rem;
  border: 1px solid transparent;
  border-radius: 100px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease), transform 0.25s var(--ease),
    box-shadow 0.25s var(--ease);
}

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

.btn--primary {
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
  box-shadow: 0 4px 12px rgba(31, 77, 52, 0.18);
}

.btn--primary:hover {
  border-color: var(--brand-ink);
  background: var(--brand-ink);
}

.btn--ghost {
  border-color: var(--border);
  background: var(--surface);
  color: var(--text-strong);
}

.btn--ghost:hover {
  border-color: #d6ccbc;
  box-shadow: var(--shadow-sm);
}

/* ── Hero ──────────────────────────────────────────────────────────── */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
  max-width: var(--page);
  min-height: calc(100svh - 64px);
  margin: 0 auto;
  padding: clamp(3rem, 8vh, 6rem) var(--gutter);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 1.5rem;
  padding: 0.35rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 100px;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 500;
}

.eyebrow__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
}

.hero__title {
  margin: 0;
  color: var(--text-strong);
  font-family: var(--serif);
  font-size: clamp(2.9rem, 6.4vw, 5.25rem);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: -0.025em;
}

.hero__title em {
  color: var(--brand);
  font-style: italic;
}

.hero__lead {
  max-width: 34rem;
  margin: 1.5rem 0 2.25rem;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* App preview card: a miniature of the Students list. */
.preview {
  padding: 1.25rem;
  border: 1px solid var(--border-subtle);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  transform: rotate(1deg);
}

.preview__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 0.25rem 0.35rem 0.9rem;
  border-bottom: 1px solid var(--border-subtle);
}

.preview__title {
  color: var(--text-strong);
  font-family: var(--serif);
  font-size: 1.6rem;
  line-height: 1;
}

.preview__meta {
  color: var(--label);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.preview__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.preview__row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.8rem 0.35rem;
  border-bottom: 1px solid var(--border-subtle);
}

.avatar {
  display: grid;
  flex-shrink: 0;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 0.72rem;
  font-weight: 700;
}

.avatar--gold {
  background: #f8efd9;
  color: #8a6a1f;
}

.preview__who {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
  font-size: 0.875rem;
  line-height: 1.3;
}

.preview__who b {
  color: var(--text-strong);
  font-weight: 560;
  letter-spacing: -0.01em;
}

.preview__who small {
  color: var(--label);
  font-size: 0.75rem;
}

.tag {
  padding: 0.18rem 0.5rem;
  border-radius: 6px;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  line-height: 1.2;
  text-transform: uppercase;
  white-space: nowrap;
}

.tag--good {
  background: #4ade80;
  color: #052e16;
}

.tag--info {
  background: #93c5fd;
  color: #1e3a5f;
}

.tag--warn {
  background: #fbbf24;
  color: #422006;
}

.preview__progress {
  padding: 1rem 0.35rem 0.25rem;
}

.preview__progress-label {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  color: var(--muted);
  font-size: 0.8125rem;
}

.preview__progress-label b {
  color: var(--text-strong);
}

.bar {
  height: 8px;
  overflow: hidden;
  border-radius: 100px;
  background: var(--surface-2);
}

.bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--brand), #357552);
}

/* ── Features ──────────────────────────────────────────────────────── */
.features {
  max-width: var(--page);
  margin: 0 auto;
  padding: clamp(3rem, 8vh, 5rem) var(--gutter) 1.5rem;
  scroll-margin-top: 40px;
}

.features__head {
  max-width: 40rem;
  margin-bottom: 2.25rem;
}

.section-label {
  margin: 0 0 1rem;
  color: var(--brand);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.features__title {
  margin: 0;
  color: var(--text-strong);
  font-family: var(--serif);
  font-size: clamp(2.25rem, 4vw, 3.25rem);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.card {
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.card__icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 1.25rem;
  border-radius: 12px;
  background: var(--brand-soft);
  color: var(--brand);
}

.card__icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.card h3 {
  margin: 0 0 0.5rem;
  color: var(--text-strong);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9375rem;
}

/* ── Demo request ──────────────────────────────────────────────────── */
.demo {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
  width: min(calc(100% - 2 * var(--gutter)), calc(var(--page) - 2 * var(--gutter)));
  margin: 0 auto clamp(3rem, 8vh, 5rem);
  padding: clamp(1.75rem, 4vw, 3rem);
  border-radius: 22px;
  background: radial-gradient(120% 140% at 0% 0%, rgba(212, 173, 85, 0.22) 0%, transparent 55%), var(--brand);
  color: #e8efe9;
  scroll-margin-top: 88px;
}

.demo__title {
  margin: 0;
  color: #fff;
  font-family: var(--serif);
  font-size: clamp(2rem, 3.4vw, 2.75rem);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.demo__lead {
  margin: 1rem 0 1.5rem;
  color: rgba(255, 255, 255, 0.75);
}

.demo__points {
  display: grid;
  gap: 0.6rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.9375rem;
}

.demo__points li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.demo__points li::before {
  content: '';
  flex-shrink: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
}

.demo__card {
  padding: clamp(1.25rem, 3vw, 2rem);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  color: var(--text);
}

.form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem 1rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.field--wide {
  grid-column: 1 / -1;
}

.field__label {
  color: var(--text-strong);
  font-size: 0.8125rem;
  font-weight: 600;
}

.field__optional {
  color: var(--label);
  font-weight: 400;
}

.field input,
.field textarea {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
  color: var(--text-strong);
  font: inherit;
  font-size: 0.9375rem;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.field textarea {
  min-height: 84px;
  resize: vertical;
}

.field input::placeholder,
.field textarea::placeholder {
  color: #a1a1a1;
}

.field input:focus,
.field textarea:focus {
  border-color: rgba(31, 77, 52, 0.35);
  box-shadow: 0 0 0 3px rgba(31, 77, 52, 0.08);
  outline: none;
}

.field [aria-invalid='true'] {
  border-color: #e5484d;
}

.field__error {
  min-height: 0;
  color: #c4262e;
  font-size: 0.75rem;
}

.field__error:empty {
  display: none;
}

/* Honeypot: off-screen, not display:none (some bots skip hidden fields). */
.field--trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form__error {
  margin: 1rem 0 0;
  padding: 0.7rem 0.9rem;
  border-radius: 12px;
  background: #fdecec;
  color: #8f1d22;
  font-size: 0.875rem;
}

.form__submit {
  width: 100%;
  margin-top: 1.25rem;
  cursor: pointer;
  font-family: inherit;
}

.form__submit:disabled {
  opacity: 0.7;
  cursor: progress;
  transform: none;
}

.form__done {
  padding: 1.5rem 0.5rem;
  text-align: center;
  outline: none;
}

.form__done-icon {
  display: inline-grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-bottom: 1rem;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand);
}

.form__done-icon svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.2;
}

.form__done h3 {
  margin: 0 0 0.5rem;
  color: var(--text-strong);
  font-family: var(--serif);
  font-size: 1.9rem;
  font-weight: 400;
  line-height: 1.1;
}

.form__done p {
  margin: 0 auto;
  max-width: 26rem;
  color: var(--muted);
}

/* ── Footer ────────────────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border);
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
  max-width: var(--page);
  margin: 0 auto;
  padding: 1.75rem var(--gutter);
  color: var(--muted);
  font-size: 0.875rem;
}

.footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}

.footer__links a {
  text-decoration: none;
}

.footer__links a:hover {
  color: var(--text-strong);
}

/* ── Responsive ────────────────────────────────────────────────────── */
@media (max-width: 1000px) {
  .features__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .hero {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
  }
  .preview {
    transform: none;
  }
  .demo {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 560px) {
  .nav-pill--hide-sm {
    display: none;
  }
  .features__grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .form__grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .hero__actions .btn {
    flex: 1 1 auto;
  }
  .footer__inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

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