/* IvyUp brand theme: near-black green, emerald glow, mint-to-white gradient (from the banner) */
@font-face { font-family: "Poppins"; font-weight: 500; font-display: swap; src: url(/fonts/poppins-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 600; font-display: swap; src: url(/fonts/poppins-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 700; font-display: swap; src: url(/fonts/poppins-latin-700-normal.woff2) format("woff2"); }

:root {
  color-scheme: dark;
  --bg: #020b08;
  --bg-2: #04140e;
  --card: #061a13;
  --line: rgba(125, 232, 186, .17);
  --line-strong: rgba(125, 232, 186, .34);
  --ink: #eaf5f0;
  --muted: #93b0a2;
  --mint: #9de7c3;
  --green: #34d399;
  --green-deep: #0e7a55;
  --glow: rgba(52, 211, 153, .38);
  --on-accent: #032017;
  --err: #ff8f85;
  --accent-grad: linear-gradient(135deg, #f3fff9 0%, #9de7c3 55%, #5fdca9 100%);
  --heading: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
body {
  margin: 0; font: 15px/1.55 var(--body); color: var(--ink); min-height: 100vh;
  background-color: var(--bg);
  background-image:
    radial-gradient(900px 520px at 100% -4%, rgba(52, 211, 153, .20), transparent 62%),
    radial-gradient(800px 620px at -10% 55%, rgba(16, 185, 129, .13), transparent 60%);
  background-repeat: no-repeat;
}
.page { max-width: 980px; margin: 0 auto; padding: 24px 24px 80px; }
a { color: var(--green); }
a:hover { color: var(--mint); }
.brand { display: inline-block; margin-bottom: 18px; }
.brand img { height: 46px; width: auto; display: block; }

h1, h2, h3, button.primary, .cta, .tab, .chip, .btn { font-family: var(--heading); }
h1 {
  margin: 0 0 6px; font-size: 30px; font-weight: 700; line-height: 1.2;
  background: linear-gradient(90deg, #ffffff 0%, var(--mint) 100%); -webkit-background-clip: text; background-clip: text; color: transparent;
}
h2 { margin: 38px 0 12px; font-size: 18px; font-weight: 600; padding-bottom: 8px; border-bottom: 1px solid var(--line-strong); color: var(--ink); }
.lede { color: var(--muted); margin: 0 0 8px; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 20px 24px;
  box-shadow: 0 12px 34px rgba(0, 0, 0, .35);
}
.row { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 20px; }
.field { display: flex; flex-direction: column; gap: 4px; margin-bottom: 14px; }
.field > label, .field > .label { font-weight: 600; }
.field .hint, .hint { font-size: 13px; color: var(--muted); font-weight: 400; }
input[type=text], input[type=email], input[type=tel], input[type=number], input[type=search], select, textarea {
  font: inherit; padding: 9px 11px; color: var(--ink); background: var(--bg-2);
  border: 1px solid var(--line-strong); border-radius: 8px; width: 100%;
}
::placeholder { color: #6f8a7d; opacity: 1; }
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus, button:focus-visible, a:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
input[type=radio] { accent-color: var(--green); }
input[type=checkbox] {
  -webkit-appearance: none; appearance: none; flex: none; width: 18px; height: 18px; margin: 0;
  border: 1.5px solid #6fa890; border-radius: 5px; background: transparent; display: inline-grid; place-content: center; cursor: pointer;
}
input[type=checkbox]:hover { border-color: var(--mint); }
input[type=checkbox]:checked { background: var(--accent-grad); border-color: transparent; }
input[type=checkbox]:checked::after {
  content: ""; width: 9px; height: 5px; border-left: 2px solid var(--on-accent); border-bottom: 2px solid var(--on-accent);
  transform: translateY(-1px) rotate(-45deg);
}
.ap-check input { width: 16px; height: 16px; }
.checks { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.checks label, .ack { display: flex; align-items: center; gap: 6px; font-weight: 400; }
.ack { align-items: flex-start; }
.ack input { margin-top: 2px; }
.err, .avail-error { color: var(--err); font-size: 13px; }
.err:empty { display: none; }
.subject-group { margin-bottom: 14px; }
.subject-group h3 { margin: 0 0 6px; font-size: 12px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { font-size: 14px; font-weight: 500; padding: 6px 15px; border: 1px solid var(--line-strong); border-radius: 999px; background: transparent; color: var(--ink); cursor: pointer; }
.chip:hover { border-color: var(--green); box-shadow: 0 0 12px rgba(52, 211, 153, .25); }
.chip[aria-pressed="true"] { background: var(--accent-grad); border-color: transparent; color: var(--on-accent); }
.chip[aria-pressed="true"]::before { content: "\2713  "; }
.chosen { margin-top: 18px; padding: 14px 16px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; }
.chosen-title { font-weight: 600; margin-bottom: 8px; }
.chosen-title .hint { display: block; }
.chosen-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 6px 0; border-top: 1px solid var(--line); }
.chosen-row:first-child { border-top: 0; }
.ap-checks { margin-left: auto; margin-right: 16px; display: flex; flex-direction: column; gap: 2px; }
.ap-check { font-size: 13px; display: flex; align-items: center; gap: 4px; }
.seg { display: inline-flex; border: 1px solid var(--green); border-radius: 8px; overflow: hidden; }
.seg button { font: inherit; font-size: 13px; padding: 3px 12px; border: 0; background: transparent; color: var(--mint); cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--accent-grad); color: var(--on-accent); font-weight: 600; }
.ack-item { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 10px; margin-bottom: 10px; }
.linkish { font: inherit; font-size: 13px; background: none; border: 0; padding: 0; color: var(--green); text-decoration: underline; cursor: pointer; }
.ack-details { flex-basis: 100%; margin: 6px 0 0 22px; padding: 10px 14px; background: rgba(255, 255, 255, .03); border-left: 3px solid var(--green); border-radius: 4px; font-size: 14px; color: var(--muted); }
.ack-details ul { margin: 0; padding-left: 18px; }
.ack-details li + li { margin-top: 4px; }
#languages { margin: 12px 0 18px; }
#lang-list .chosen-row > span { flex: 1; }
#lang-list .ap-checks { margin-left: 0; }
.lang-other { margin: 10px 0 6px; max-width: 320px; }
.cefr { width: 190px; padding: 4px 6px; }
#lang-list .chosen-row { gap: 12px; }
button.primary {
  font-size: 15px; font-weight: 600; background: var(--accent-grad); color: var(--on-accent); border: 0;
  padding: 12px 30px; border-radius: 10px; cursor: pointer; box-shadow: 0 0 22px rgba(52, 211, 153, .28);
}
button.primary:hover:not(:disabled) { box-shadow: 0 0 30px rgba(52, 211, 153, .5); }
button.primary:disabled { opacity: .6; cursor: default; }
#request #submit { margin-top: 16px; }
.honey { position: absolute; left: -9999px; }
#done { text-align: center; padding: 48px 24px; }
#done h2 { border: 0; }
#general-error { margin: 12px 0; }
.turnstile { margin: 16px 0 4px; }

/* landing, privacy, footers */
.hero-band {
  position: relative; text-align: center; padding: 48px 20px 40px; border-bottom: 1px solid var(--line);
  background: #020b08 url(/img/curves.svg) center / cover no-repeat;
}
.hero-logo { display: block; margin: 0 auto 14px; width: min(520px, 86vw); height: auto; filter: drop-shadow(0 0 30px var(--glow)); }
.hero-band h1 { margin: 0; line-height: 0; background: none; -webkit-background-clip: border-box; background-clip: border-box; color: inherit; }
.hero-line { font: 600 22px/1.35 var(--heading); margin: 6px auto 12px; max-width: 660px; }
.hero-band .lede { max-width: 640px; margin: 0 auto; font-size: 16px; }
.ctas { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin: 28px 0; }
.cta-card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 22px 26px; display: flex; flex-direction: column; box-shadow: 0 12px 34px rgba(0, 0, 0, .35); }
.cta-card h2 { margin: 0 0 6px; border: 0; padding: 0; }
.cta-card p { color: var(--muted); margin: 0 0 16px; }
.cta { display: inline-block; align-self: flex-start; margin-top: auto; font-weight: 600; text-decoration: none; background: var(--accent-grad); color: var(--on-accent); border: 2px solid transparent; padding: 9px 24px; border-radius: 10px; box-shadow: 0 0 22px rgba(52, 211, 153, .28); }
.cta:hover { color: var(--on-accent); box-shadow: 0 0 32px rgba(52, 211, 153, .5); }
.cta.alt { background: transparent; color: var(--mint); border-color: var(--green); box-shadow: none; }
.cta.alt:hover { color: var(--mint); box-shadow: 0 0 22px rgba(52, 211, 153, .3); }
.steps { padding-left: 22px; max-width: 640px; }
.steps li { margin-bottom: 8px; }
.steps li::marker { color: var(--green); font-weight: 700; }
.site-foot { margin-top: 56px; padding-top: 16px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.prose { max-width: 720px; }
.prose p { margin: 0 0 12px; }

/* availability map */
.avail { display: grid; grid-template-columns: 300px 1fr; gap: 24px; align-items: start; }
.avail-text { font-family: ui-monospace, Menlo, monospace; font-size: 14px; }
.avail-errors { margin-top: 6px; }
.avail-total { margin-top: 6px; font-weight: 600; color: var(--green); }
.avail-help { margin-top: 8px; font-size: 13px; color: var(--muted); }
.avail-help code { background: rgba(157, 231, 195, .12); color: var(--mint); padding: 0 4px; border-radius: 3px; }
.avail-map { border: 1px solid var(--line-strong); border-radius: 10px; background: var(--bg-2); padding-bottom: 8px; }
.avail-head, .avail-body { display: grid; grid-template-columns: 44px repeat(7, 1fr); }
.avail-dayname { text-align: center; font-weight: 600; padding: 6px 0; border-bottom: 1px solid var(--line); }
.avail-labels { position: relative; }
.avail-label { position: absolute; right: 6px; font-size: 11px; color: var(--muted); }
.avail-col { position: relative; border-left: 1px solid var(--line);
  background-image: repeating-linear-gradient(to bottom, transparent 0, transparent 35px, var(--line) 35px, var(--line) 36px); }
.avail-block { position: absolute; left: 2px; right: 2px; background: linear-gradient(180deg, #5fdca9, #34d399); border-radius: 4px; cursor: pointer; box-shadow: 0 0 10px rgba(52, 211, 153, .45); }
.avail-block:hover { background: linear-gradient(180deg, #b6f2d6, #6ee7b7); }
.avail-tip { position: fixed; z-index: 10; background: var(--ink); color: #04140e; padding: 6px 10px; border-radius: 6px; font-size: 13px; white-space: nowrap; box-shadow: 0 4px 16px rgba(0, 0, 0, .5); }
.avail-del { font: inherit; font-size: 12px; margin-left: 6px; background: #b3261e; color: #fff; border: 0; border-radius: 4px; padding: 2px 8px; cursor: pointer; }

/* v1 is desktop only */
.mobile-notice { display: none; text-align: center; padding: 64px 24px; }
@media (max-width: 899px) {
  .desktop-only { display: none; }
  .mobile-notice { display: block; }
}

/* Phone layout (the parent form at /start is mostly opened from a QR code on a phone) */
@media (max-width: 700px) {
  .page { padding: 16px 16px 56px; }
  h1 { font-size: 24px; }
  .card { padding: 14px 16px; }
  .row { grid-template-columns: 1fr; }
  input[type=text], input[type=email], input[type=tel], input[type=number], input[type=search], select, textarea { font-size: 16px; }
  .avail { grid-template-columns: 1fr; gap: 14px; }
  .avail-dayname { font-size: 12px; }
  .chosen-row { flex-wrap: wrap; }
  .ap-checks { margin-left: 0; margin-right: 0; }
  .lang-other { max-width: none; }
  .ctas { grid-template-columns: 1fr; }
  .hero-band { padding: 32px 16px 28px; }
  .hero-line { font-size: 19px; }
  button.primary { width: 100%; }
}
