/* ---- Tokens ------------------------------------------------------------ */
:root {
  /* Palette */
  --slate-900: #0f172a;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-500: #64748b;
  --slate-300: #cbd5e1;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --blue-600: #2563eb;
  --green-700: #15803d;
  --green-200: #bbf7d0;
  --green-50: #f0fdf4;
  --red-700: #b91c1c;
  --red-200: #fecaca;
  --red-50: #fef2f2;
  --white: #ffffff;

  /* Roles */
  --bg: var(--slate-50);
  --surface: var(--white);
  --text: var(--slate-900);
  --text-muted: var(--slate-600);
  --border: var(--slate-300);          /* decorative card/section rules */
  --border-subtle: var(--slate-200);
  --border-control: #64748b;           /* 4.76:1 on white: passes WCAG 1.4.11 (3:1 for control edges) */
  --accent: #1e293b;
  --accent-hover: var(--slate-900);
  --on-accent: var(--white);
  --focus: var(--blue-600);
  /* Brand accent (deep emerald). Only on: Send offer / Buy buttons, fixed price tags, input focus rings. */
  --brand: #0f766e;        /* white text on it: 5.47:1 */
  --brand-hover: #115e59;  /* 7.2:1 */
  --badge-bg: #fef3c7;     /* "Open to offers" / "Offers from" badge */
  --badge-text: #78350f;   /* 8.9:1 on the badge */
  --card-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);

  /* Type */
  --font-sans: "Source Sans 3", "Segoe UI", sans-serif;
  --font-serif: "Source Serif 4", Georgia, serif;
  --fs-xs: 0.8125rem;
  --fs-sm: 0.9375rem;
  --fs-md: 1.0625rem;
  --fs-lg: 1.25rem;
  --fs-xl: 1.625rem;

  /* Space (4/8 scale) and radius */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --radius-sm: 6px;
  --radius: 10px;
}

/* ---- Base -------------------------------------------------------------- */
* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font-sans);
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

button, input, select, textarea { font: inherit; }

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

input:focus-visible,
select:focus-visible,
textarea:focus-visible { outline-color: var(--brand); }

::placeholder { color: var(--slate-600); opacity: 1; }

.container { max-width: 1060px; margin: 0 auto; padding-inline: var(--space-5); }

/* ---- Header ------------------------------------------------------------ */
header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding-block: var(--space-4);
}

.header-inner { display: flex; justify-content: space-between; align-items: center; gap: var(--space-4); }

.brand {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: var(--fs-lg);
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}

.header-cta {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 6px var(--space-4);
  border: 1px solid var(--slate-900);
  border-radius: 999px;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.15s ease;
}
.header-cta:hover { background: var(--slate-100); }

/* ---- Layout ------------------------------------------------------------ */
/* main.container beats .container's shorthand so vertical padding survives. */
main.container { padding-block: var(--space-7) 72px; }

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  grid-template-rows: auto 1fr;   /* intro hugs its content; no dead gap above the process box */
  grid-template-areas:
    "intro form"
    "details form";
  column-gap: var(--space-7);
  row-gap: var(--space-6);
  align-items: start;
}

.hero-intro { grid-area: intro; }
.hero-form { grid-area: form; }
.hero-details { grid-area: details; }
.hub-names { grid-area: names; }

/* Hub: the names sit right under the intro, before the form and the transfer steps. */
.hero-grid--hub {
  grid-template-columns: 1.15fr 0.85fr;  /* a little wider for the names so price badges fit beside them */
  grid-template-rows: auto auto 1fr;
  grid-template-areas:
    "intro form"
    "names form"
    "details form";
}
.hub-names .section-heading { margin: 0 0 var(--space-4); }

@media (max-width: 860px) {
  main.container { padding-block: var(--space-6) 56px; }
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: none;
    grid-template-areas:
      "intro"
      "form"
      "details";
    row-gap: var(--space-5);
  }
  .hero-grid--hub {
    grid-template-areas:
      "intro"
      "names"
      "form"
      "details";
  }
}

@media (max-width: 480px) {
  .container { padding-inline: var(--space-4); }
}

/* ---- Hero -------------------------------------------------------------- */
.status-pill {
  display: inline-block;
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: var(--space-1) var(--space-3);
  border-radius: 999px;
  background: var(--slate-200);
  color: var(--slate-700);
  margin-bottom: var(--space-3);
}

.domain-heading {
  font-family: var(--font-serif);
  font-size: clamp(2.125rem, 4.5vw, 3.25rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.12;
  overflow-wrap: anywhere;
  margin: 0 0 var(--space-3);
}

.lead-copy {
  font-size: var(--fs-md);
  color: var(--text-muted);
  max-width: 560px;
  margin: 0;
}

.domain-pitch {
  font-size: var(--fs-sm);
  color: var(--slate-700);
  max-width: 560px;
  margin: var(--space-3) 0 0;
}

.see-all {
  display: inline-block;
  margin-top: var(--space-3);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--text);
  text-underline-offset: 3px;
}
.see-all::before { content: "\2190  " / ""; }

.lead-copy strong { color: var(--text); }

/* ---- Cards ------------------------------------------------------------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-5);
  box-shadow: var(--card-shadow);
}

.hero-form { box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06); transition: box-shadow 0.3s ease; scroll-margin-top: var(--space-4); }
.hero-form.is-highlighted { box-shadow: 0 0 0 4px #fde68a, 0 4px 12px rgba(15, 23, 42, 0.06); }

@media (min-width: 861px) {
  .hero-form { padding: var(--space-5); }
}

.offer-heading {
  font-size: var(--fs-lg);
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 var(--space-2);
  overflow-wrap: anywhere;
}

.price-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: var(--space-3);
  row-gap: var(--space-1);
  padding-bottom: var(--space-4);
  margin-bottom: var(--space-5);
  border-bottom: 1px solid var(--border-subtle);
}

.price-label { font-size: var(--fs-xs); font-weight: 600; color: var(--text-muted); }

.price-cta {
  font-size: var(--fs-md);
  font-weight: 700;
  color: var(--text);
  text-underline-offset: 3px;
}

.price-cta::after { content: " \2193" / ""; }
.price-cta--fixed { color: var(--brand); }
.price-cta--min {
  padding: 2px var(--space-3);
  border-radius: 999px;
  background: var(--badge-bg);
  color: var(--badge-text);
  font-size: var(--fs-sm);
  text-decoration: none;
}
.price-cta--min::after { content: none; }


.fee-note {
  margin: 0 0 var(--space-4);
  font-size: var(--fs-xs);
  line-height: 1.45;
  color: var(--text-muted);
  overflow-wrap: anywhere;
}

.fee-note a,
.process-list a {
  color: inherit;
  text-underline-offset: 2px;
}

/* ---- Form -------------------------------------------------------------- */
.form-group { margin: 0 0 var(--space-3); }

/* Name + Email side by side on wide screens. */
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
@media (max-width: 420px) { .form-row { grid-template-columns: minmax(0, 1fr); } }
.form-row .form-group { min-width: 0; }

/* Payment choices side by side when they fit. */
.choices { display: flex; flex-wrap: wrap; column-gap: var(--space-5); row-gap: 0; }
.form-group:empty { display: none; }

label,
legend {
  display: block;
  font-size: var(--fs-xs);
  font-weight: 600;
  color: var(--slate-700);
  margin-bottom: var(--space-1);
}

input[type="text"],
input[type="email"],
select,
textarea {
  width: 100%;
  padding: 8px var(--space-3);
  font-size: 1rem;
  border: 1px solid var(--border-control);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
}

input[aria-invalid="true"],
select[aria-invalid="true"],
textarea[aria-invalid="true"] { border-color: var(--red-700); border-width: 2px; }

.intent { border: 0; padding: 0; min-width: 0; }
.intent legend { padding: 0; }

.choice {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--fs-sm);
  font-weight: 400;
  color: var(--text);
  margin: 0;
  min-height: 28px;
  cursor: pointer;
}

.choice input { width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }

.field-hint,
.field-error { margin: var(--space-1) 0 0; font-size: var(--fs-xs); line-height: 1.45; }
.field-hint { color: var(--text-muted); }
.field-error { color: var(--red-700); font-weight: 600; }

.btn-submit,
.btn-secondary {
  width: 100%;
  min-height: 44px;
  padding: var(--space-3) var(--space-4);
  font-size: var(--fs-sm);
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-submit { background: var(--brand); color: var(--on-accent); border: none; }
.btn-submit:hover { background: var(--brand-hover); }
.btn-submit:disabled { background: var(--slate-600); opacity: 1; cursor: not-allowed; }  /* 7.58:1 */

.btn-secondary { background: var(--surface); color: var(--text); border: 1px solid var(--border-control); }
.btn-secondary:hover { background: var(--slate-100); }

.form-status {
  display: none;
  margin-top: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius-sm);
  font-size: var(--fs-sm);
}

.form-status:focus { outline: none; }
.form-status:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

.form-status.success { display: block; background: var(--green-50); color: var(--green-700); border: 1px solid var(--green-200); }
.form-status.error { display: block; background: var(--red-50); color: var(--red-700); border: 1px solid var(--red-200); }

.form-sent {
  padding: var(--space-5);
  border-radius: var(--radius-sm);
  background: var(--green-50);
  border: 1px solid var(--green-200);
}

.form-sent[hidden] { display: none; }
.form-sent:focus { outline: 3px solid var(--focus); outline-offset: 2px; }
.form-sent-title { margin: 0 0 var(--space-2); font-size: var(--fs-lg); color: var(--green-700); }
.form-sent-text { margin: 0 0 var(--space-4); color: var(--text); overflow-wrap: anywhere; }

.fine-print { margin: var(--space-3) 0 0; font-size: var(--fs-xs); color: var(--text-muted); line-height: 1.5; }
.fine-print a { color: inherit; }

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

/* ---- Process + specs --------------------------------------------------- */
.process-box h2,
.section-heading { font-size: var(--fs-lg); font-weight: 700; margin: 0 0 var(--space-3); }

.process-list {
  margin: 0;
  padding-left: 1.4em;
  font-size: var(--fs-sm);
  color: var(--text-muted);
}

.process-list li { padding: var(--space-2) 0; border-bottom: 1px solid var(--slate-100); }
.process-list li:last-child { border-bottom: none; padding-bottom: 0; }
.process-list li::marker { font-weight: 700; color: var(--text); }
.process-list strong { color: var(--text); }

.domain-specs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-5);
  margin: var(--space-4) 0 0;
  padding-top: var(--space-4);
  border-top: 1px solid var(--border-subtle);
  font-size: var(--fs-xs);
  color: var(--text-muted);
}

.domain-specs div { display: flex; gap: var(--space-1); }
.domain-specs dt::after { content: ":"; }
.domain-specs dd { margin: 0; color: var(--slate-700); font-weight: 600; }

/* ---- Portfolio grid ---------------------------------------------------- */
.vault-section {
  margin-top: var(--space-8);
  padding-top: var(--space-7);
  border-top: 1px solid var(--border);
}

.vault-section .section-heading { margin-bottom: var(--space-5); }

.vault-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(240px, 100%), 1fr));
  gap: var(--space-4);
}

.vault-item {
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  height: 100%;
  gap: var(--space-1);
  min-height: 44px;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: var(--fs-sm);
  color: var(--text);
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: border-color 0.15s ease;
}

.vault-item:hover { border-color: var(--slate-500); }
/* Restrained cards: small category kicker, then the name dominates, then its price label. */
.vault-kicker { font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--slate-600); }
.vault-name { font-size: 1.3125rem; font-weight: 800; line-height: 1.2; letter-spacing: -0.01em; margin-top: 2px; }
.vault-price { align-self: flex-start; display: inline-block; padding: 1px 7px; border-radius: 999px; font-size: var(--fs-xs); font-weight: 700; border: 1px solid transparent; }
.vault-price--fixed { background: #ecfdf5; border-color: #a7f3d0; color: #065f46; }
.vault-price--min,
.vault-price--open { background: var(--badge-bg); color: var(--badge-text); }
.vault-meta { font-size: var(--fs-xs); font-weight: 600; color: var(--slate-600); }
.vault-pitch { font-size: var(--fs-xs); font-weight: 400; color: var(--slate-600); line-height: 1.45; }
.vault-actions { display: flex; flex-direction: column; align-items: stretch; gap: var(--space-2); margin-top: auto; padding-top: var(--space-3); }
.vault-secondary { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-3); }
.card-buy,
.card-offer {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 6px var(--space-3);
  border-radius: var(--radius-sm);
  font: inherit;
  font-size: var(--fs-xs);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}
.card-buy { border: 1px solid var(--brand); background: var(--brand); color: var(--white); width: 100%; }
.card-buy:hover { background: var(--brand-hover); border-color: var(--brand-hover); }
.card-offer { border: 1px solid var(--border-control); background: var(--white); color: var(--text); }
.card-offer:hover { background: var(--slate-100); }
.card-details { font-size: var(--fs-xs); font-weight: 600; color: var(--text); text-decoration: none; text-underline-offset: 2px; }
.card-details:hover,
.card-details:focus-visible { text-decoration: underline; }
.hub-more { margin-top: var(--space-3); font-size: var(--fs-sm); color: var(--slate-600); }
.buy-for { margin: 0 0 var(--space-2); font-size: var(--fs-sm); font-weight: 700; color: var(--text); }
.vault-item[aria-current="page"] { background: var(--slate-100); border-color: var(--slate-900); }

/* ---- Footer ------------------------------------------------------------ */
footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding-block: var(--space-6);
  font-size: var(--fs-xs);
  color: var(--text-muted);
}

footer p { margin: 0; line-height: 1.5; }
footer strong { color: var(--slate-700); }

.footer-copy {
  margin-top: var(--space-3);
  padding-top: var(--space-3);
  border-top: 1px solid var(--slate-100);
}

/* ---- Captcha (Cloudflare Turnstile) ----------------------------------- */
.captcha-slot[hidden] { display: none; }
/* interaction-only: the widget stays invisible (no "Checking…/Success!" text) unless a visitor must click. */
.captcha-slot { margin-bottom: 0; }
.captcha-widget { max-width: 100%; }
.captcha-widget iframe { display: block; margin: 0 0 var(--space-3); }
/* Flexible Turnstile needs a 300px column; at 375px that means 16px card padding. Narrower columns get "compact". */
@media (max-width: 480px) {
  .hero-form { padding: var(--space-4); }
}

.form-noscript { margin: 0 0 12px; padding: 10px 12px; border: 1px solid #b45309; border-radius: 6px; background: #fffbeb; color: #78350f; font-size: 0.9rem; }


/* Buy with Escrow.com (priced names only) */
.escrow-buy { margin: 0 0 1.25rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--border-control); }
.escrow-buy .btn-submit { margin-top: 0.75rem; }
.escrow-or { margin: 0.5rem 0 0; font-size: var(--fs-xs); color: var(--text-muted); }

/* ---- Fee line and hub subhead ------------------------------------------ */
.fee-line { margin: 0 0 var(--space-3); font-size: var(--fs-xs); color: var(--slate-600); }
.escrow-buy .fee-line { margin: var(--space-2) 0 0; }

.hub-credentials {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) 0;
  margin: var(--space-3) 0 0;
  padding: 0;
  list-style: none;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--slate-600);
}
.hub-credentials li + li::before { content: "\2022" / ""; margin: 0 var(--space-2); color: var(--slate-500); }
@media (max-width: 640px) {
  .hub-credentials { flex-direction: column; }
  .hub-credentials li { padding-left: var(--space-4); position: relative; }
  .hub-credentials li::before,
  .hub-credentials li + li::before { content: "\2022" / ""; position: absolute; left: 0; margin: 0; color: var(--slate-500); }
}

/* Full-width "More names for sale" grid: wide enough cards that the badge stays beside the name. */
#vault-grid { grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); }

/* Buy / offer panel switch and status states (no restyle: small text-link toggles, neutral badge). */
.panel-switch { margin-top: var(--space-3); font-size: var(--fs-sm); }
.link-toggle { padding: 0; border: 0; background: none; font: inherit; font-weight: 600; color: var(--text); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.link-toggle:hover { color: var(--brand-hover); }
.panel-note { margin: 0 0 var(--space-3); font-size: var(--fs-sm); color: var(--slate-600); }
.vault-price--status { background: var(--slate-100); color: var(--slate-700); border-color: var(--border); }
