:root {
  --ink: #0f1115;
  --ink-soft: #2b2f36;
  --paper: #fcfcfa;
  --panel: #ffffff;
  --line: #e7e6e0;
  --muted: #6b7077;
  --accent: #0e7c5a;
  --accent-press: #0a634780;
  --accent-tint: #e8f4ee;
  --shadow: 0 1px 2px rgba(15, 17, 21, 0.04), 0 12px 32px rgba(15, 17, 21, 0.06);
  --radius: 16px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: "Sora", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(1200px 480px at 50% -10%, var(--accent-tint), transparent 60%),
    var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ── Top bar / wordmark ─────────────────────────────────────────────────── */
.topbar {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: clamp(1.5rem, 5vw, 3rem) 1rem 0.4rem;
}
.logo {
  appearance: none;
  border: 0;
  background: none;
  padding: 0.1rem 0.3rem;
  font-family: inherit; /* replaced per predicted font by advert.js */
  font-weight: 800;
  font-size: clamp(2.2rem, 8vw, 4rem);
  line-height: 1.04;
  letter-spacing: -0.025em;
  color: var(--ink);
  cursor: pointer;
  border-radius: 12px;
  text-align: center;
}
.logo:hover { color: var(--accent); }
.logo:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.logo-pop {
  position: absolute;
  top: calc(100% - 0.1rem);
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  width: min(20rem, calc(100vw - 2rem));
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 1rem 1.1rem;
}
.logo-pop p { margin: 0 0 0.8rem; font-size: 0.95rem; }
.logo-pop-actions { display: flex; gap: 0.5rem; align-items: center; }

/* ── Hero ───────────────────────────────────────────────────────────────── */
.hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(1rem, 4vw, 2.5rem) 1.25rem 2rem;
}
.hero-inner { max-width: 44rem; }

.badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-tint);
  border: 1px solid #cfe7dc;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
}
.domain-name {
  margin: 1.1rem 0 0.4rem;
  font-family: ui-monospace, "SFMono-Regular", "JetBrains Mono", Menlo, monospace;
  font-weight: 600;
  letter-spacing: -0.01em;
  font-size: clamp(1.9rem, 7vw, 3.6rem);
  line-height: 1.05;
  word-break: break-word;
}
.headline {
  margin: 0.6rem 0 0;
  font-weight: 800;
  letter-spacing: -0.025em;
  font-size: clamp(1.6rem, 5vw, 2.6rem);
  line-height: 1.1;
}
.subhead {
  margin: 1rem auto 0;
  max-width: 32rem;
  color: var(--ink-soft);
  font-size: clamp(1rem, 2.4vw, 1.15rem);
  line-height: 1.5;
}
.cta-row { margin-top: 1.8rem; }

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn-accent {
  appearance: none;
  display: inline-block;
  text-decoration: none;
  font: inherit;
  font-weight: 600;
  color: #fff;
  background: var(--accent);
  border: 1px solid var(--accent);
  padding: 0.7rem 1.3rem;
  border-radius: 11px;
  cursor: pointer;
  transition: transform 0.06s ease, box-shadow 0.16s ease, background 0.16s ease;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04), 0 8px 20px var(--accent-press);
}
.btn-accent:hover { background: #0c6e50; }
.btn-accent:active { transform: translateY(1px); }
.btn-accent:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.btn-accent:disabled { opacity: 0.55; cursor: default; box-shadow: none; }
.btn-lg { padding: 0.85rem 1.7rem; font-size: 1.05rem; }
.btn-ghost {
  appearance: none;
  font: inherit;
  background: none;
  border: 1px solid var(--line);
  color: var(--ink-soft);
  padding: 0.55rem 0.9rem;
  border-radius: 10px;
  cursor: pointer;
}
.btn-ghost:hover { border-color: #cfcfca; color: var(--ink); }

/* ── Cards: offer form + thank-you ──────────────────────────────────────── */
.card {
  width: min(36rem, 100%);
  margin: 2rem auto 0;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.5rem 1.5rem 1.6rem;
  text-align: left;
}
.card h3 { margin: 0 0 1rem; font-size: 1.2rem; letter-spacing: -0.01em; }

#offer-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem 1rem;
}
.field { display: flex; flex-direction: column; gap: 0.35rem; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 0.82rem; color: var(--muted); font-weight: 600; }
.field input,
.field textarea {
  font: inherit;
  padding: 0.6rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
}
.field textarea { resize: vertical; min-height: 5.5rem; }
.field input:focus,
.field textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.form-actions { grid-column: 1 / -1; margin-top: 0.4rem; }
.form-error { grid-column: 1 / -1; margin: 0.2rem 0 0; color: #b00020; font-size: 0.9rem; }

.thanks { text-align: center; }
.thanks .check {
  width: 3rem; height: 3rem; margin: 0 auto 0.7rem;
  display: grid; place-items: center;
  border-radius: 999px; background: var(--accent-tint); color: var(--accent);
  font-size: 1.5rem; font-weight: 800;
}
.thanks p { color: var(--ink-soft); margin: 0.3rem 0 0; }

/* ── Ad slot ────────────────────────────────────────────────────────────── */
.ad-slot {
  width: min(48rem, calc(100% - 2.5rem));
  margin: 2.5rem auto 0;
  min-height: 90px;
  border: 1px dashed var(--line);
  border-radius: 12px;
  overflow: hidden;
}

/* ── Other domains ──────────────────────────────────────────────────────── */
.other {
  width: min(60rem, calc(100% - 2.5rem));
  margin: 3rem auto 1rem;
}
.other-title {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  margin: 0 0 1.1rem;
}
.other-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: 0.8rem;
}
.other-link {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--ink);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  transition: transform 0.08s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}
.other-link:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: #d9e7e0;
}
.other-name {
  font-family: ui-monospace, "SFMono-Regular", Menlo, monospace;
  font-weight: 600;
  font-size: 1rem;
  word-break: break-all;
}
.other-tag { color: var(--accent); font-weight: 700; font-size: 0.82rem; }
.muted { color: var(--muted); text-align: center; }

/* ── Footer ─────────────────────────────────────────────────────────────── */
.footer {
  margin-top: auto;
  padding: 2rem 1.25rem 2.4rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.82rem;
}

@media (max-width: 560px) {
  #offer-form { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .btn-accent, .other-link { transition: none; }
}
