/* ============================================================
   Components
   ============================================================ */

/* ── Eyebrow label ────────────────────────────────────────── */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--s3);
  font-family: var(--font-head);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: var(--ls-eyebrow);
  text-transform: uppercase;
  color: var(--gold-700);
  margin-bottom: var(--s4);
}

.eyebrow::before {
  content: '';
  width: 2rem;
  height: 2px;
  background: var(--gold-rule);
  flex-shrink: 0;
}

.section--dark .eyebrow { color: var(--gold-400); }

.eyebrow--center { justify-content: center; }
.eyebrow--center::after {
  content: '';
  width: 2rem;
  height: 2px;
  background: linear-gradient(270deg, var(--gold-500) 0%, var(--gold-300) 50%, rgba(201,151,43,0) 100%);
}

/* ── Section header ───────────────────────────────────────── */

.section-head { margin-bottom: var(--s7); max-width: 46rem; }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head p { margin-top: var(--s4); }
.section-head--center p { margin-inline: auto; }

/* ── Buttons ──────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s2);
  min-height: 48px;
  padding: var(--s3) var(--s5);
  font-family: var(--font-head);
  font-size: var(--fs-base);
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  border: 1.5px solid transparent;
  border-radius: var(--r-md);
  cursor: pointer;
  transition: background var(--dur) var(--ease),
              border-color var(--dur) var(--ease),
              color var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease),
              transform var(--dur-fast) var(--ease);
  touch-action: manipulation;
}

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

.btn svg { width: 1.125em; height: 1.125em; flex-shrink: 0; }

/* Primary: gold fill, charcoal text — 11:1 contrast */
.btn--primary {
  background: var(--gold-500);
  border-color: var(--gold-500);
  color: var(--ink-900);
}
.btn--primary:hover {
  background: var(--gold-400);
  border-color: var(--gold-400);
  color: var(--ink-900);
  box-shadow: var(--shadow-gold);
}

/* Secondary: charcoal fill */
.btn--secondary {
  background: var(--ink-900);
  border-color: var(--ink-900);
  color: var(--text-invert);
}
.btn--secondary:hover {
  background: var(--ink-700);
  border-color: var(--ink-700);
  color: var(--text-invert);
}

/* Outline on light backgrounds */
.btn--outline {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--text);
}
.btn--outline:hover {
  border-color: var(--gold-500);
  color: var(--gold-700);
  background: var(--gold-050);
}

/* Outline on dark backgrounds */
.btn--ghost {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.28);
  color: var(--text-invert);
}
.btn--ghost:hover {
  border-color: var(--gold-400);
  color: var(--gold-300);
  background: rgba(201, 151, 43, 0.08);
}

.btn--sm { min-height: 40px; padding: var(--s2) var(--s4); font-size: var(--fs-sm); }
.btn--lg { min-height: 56px; padding: var(--s4) var(--s6); font-size: var(--fs-lg); }
.btn--block { width: 100%; }

.btn[disabled], .btn[aria-disabled='true'] {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}

.btn.is-loading { pointer-events: none; position: relative; color: transparent; }
.btn.is-loading::after {
  content: '';
  position: absolute;
  inset: 0;
  margin: auto;
  width: 1.1rem; height: 1.1rem;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: var(--r-full);
  color: var(--ink-900);
  animation: spin 640ms linear infinite;
}
.btn--secondary.is-loading::after, .btn--ghost.is-loading::after { color: #fff; }

@keyframes spin { to { transform: rotate(360deg); } }

/* Text link with arrow */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: var(--s2);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: var(--fs-sm);
  letter-spacing: var(--ls-wide);
  text-decoration: none;
  color: var(--gold-700);
}
.link-arrow svg {
  width: 1rem; height: 1rem;
  transition: transform var(--dur) var(--ease);
}
.link-arrow:hover svg { transform: translateX(4px); }
.section--dark .link-arrow { color: var(--gold-300); }

/* ── Cards ────────────────────────────────────────────────── */

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: var(--s6);
  transition: border-color var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease),
              transform var(--dur) var(--ease);
  overflow: hidden;
}

/* Gold rule that draws in on hover */
.card::before {
  content: '';
  position: absolute;
  inset-inline: 0;
  top: 0;
  height: 3px;
  background: var(--gold-grad);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--dur-slow) var(--ease-out);
}

.card:hover, .card:focus-within {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.card:hover::before, .card:focus-within::before { transform: scaleX(1); }

.card__icon {
  display: grid;
  place-items: center;
  width: 3rem; height: 3rem;
  border-radius: var(--r-md);
  background: var(--gold-050);
  border: 1px solid var(--gold-200);
  color: var(--gold-700);
  margin-bottom: var(--s5);
  flex-shrink: 0;
}
.card__icon svg { width: 1.5rem; height: 1.5rem; }

.card__title { font-size: var(--fs-xl); margin-bottom: var(--s3); }

.card__title a {
  color: inherit;
  text-decoration: none;
}
/* Whole card clickable while keeping a real focusable link */
.card__title a::after { content: ''; position: absolute; inset: 0; }
.card__title a:hover { color: var(--gold-700); }

.card__body { color: var(--text-muted); font-size: var(--fs-base); flex-grow: 1; }
.card__body p { max-width: none; }
.card__foot { margin-top: var(--s5); padding-top: var(--s4); border-top: 1px solid var(--line); }

.card--flush { padding: 0; }
.card--flush .card__inner { padding: var(--s6); }

.card__media {
  aspect-ratio: 16 / 10;
  background: var(--surface-sunken);
  overflow: hidden;
}
.card__media img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform var(--dur-slow) var(--ease-out);
}
.card:hover .card__media img { transform: scale(1.04); }

.card--dark {
  background: var(--ink-800);
  border-color: var(--line-dark);
  color: var(--text-on-dark);
}
.card--dark .card__title { color: var(--text-invert); }
.card--dark .card__body { color: var(--text-on-dark-muted); }
.card--dark .card__icon {
  background: rgba(201, 151, 43, 0.12);
  border-color: rgba(201, 151, 43, 0.3);
  color: var(--gold-300);
}
.card--dark .card__foot { border-top-color: var(--line-dark); }

/* ── Key facts block (the GEO extraction target) ──────────── */

.key-facts {
  background: var(--gold-050);
  border: 1px solid var(--gold-200);
  border-left: 4px solid var(--gold-500);
  border-radius: var(--r-md);
  padding: var(--s5) var(--s6);
}

.key-facts__title {
  font-family: var(--font-head);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: var(--ls-eyebrow);
  text-transform: uppercase;
  color: var(--gold-700);
  margin-bottom: var(--s4);
}

.key-facts ul {
  list-style: none;
  padding-left: 0;
  display: grid;
  gap: var(--s3);
}

.key-facts li {
  position: relative;
  padding-left: var(--s5);
  margin-top: 0;
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
  color: var(--ink-700);
}

.key-facts li::before {
  content: '';
  position: absolute;
  left: 0; top: 0.62em;
  width: 6px; height: 6px;
  border-radius: var(--r-full);
  background: var(--gold-500);
}

/* ── Spec table ───────────────────────────────────────────── */

.spec-table-wrap {
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--surface);
}

.spec-table { font-size: var(--fs-base); }
.spec-table caption {
  caption-side: top;
  text-align: left;
  padding: var(--s4) var(--s5);
  background: var(--surface-alt);
  border-bottom: 1px solid var(--line);
  font-family: var(--font-head);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--text-muted);
}
.spec-table th, .spec-table td { padding: var(--s3) var(--s5); }
.spec-table tbody tr:last-child th,
.spec-table tbody tr:last-child td { border-bottom: 0; }
.spec-table tbody tr:nth-child(even) { background: var(--surface-alt); }
.spec-table th {
  font-family: var(--font-body);
  font-size: var(--fs-base);
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
  color: var(--text);
  width: 42%;
}
.spec-table td.spec-value {
  font-family: var(--font-mono);
  font-size: var(--fs-sm);
  font-variant-numeric: tabular-nums;
}
.spec-table td.spec-value.is-pending {
  font-family: var(--font-body);
  color: var(--text-subtle);
  font-style: italic;
}
.spec-table .spec-method {
  display: block;
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-style: normal;
  color: var(--text-subtle);
  margin-top: 2px;
}

/* ── Accordion (FAQ) ──────────────────────────────────────── */

/* The block fills its container. Below 62rem it is a single column; above
   that the intro splits off to the left and stays with the reader while the
   list scrolls, which keeps the question measure readable on a wide screen. */
.faq-block {
  display: grid;
  gap: var(--s6);
}

@media (min-width: 62rem) {
  .faq-block {
    grid-template-columns: minmax(0, 21rem) minmax(0, 1fr);
    gap: var(--s8);
    align-items: start;
  }

  .faq-block__intro {
    position: sticky;
    top: calc(var(--header-h) + var(--s5));
  }
}

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

.faq-block__intro h2 { margin-top: var(--s2); }

.faq-block__lead {
  margin-top: var(--s4);
  color: var(--text-muted);
  max-width: 34ch;
}

.faq-block__intro .link-arrow { margin-top: var(--s5); }

.accordion { border-top: 1px solid var(--line); }

.accordion__item { border-bottom: 1px solid var(--line); }

.accordion__trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s4);
  width: 100%;
  min-height: 56px;
  padding: var(--s4) 0;
  background: none;
  border: 0;
  text-align: left;
  font-family: var(--font-head);
  font-size: var(--fs-lg);
  font-weight: 600;
  line-height: var(--lh-snug);
  color: var(--text);
  cursor: pointer;
  transition: color var(--dur-fast) var(--ease);
}

.accordion__trigger:hover { color: var(--gold-700); }

.accordion__trigger > span:first-child { max-width: 58ch; }

.accordion__icon {
  flex-shrink: 0;
  width: 1.5rem; height: 1.5rem;
  display: grid;
  place-items: center;
  border-radius: var(--r-full);
  border: 1.5px solid var(--line-strong);
  color: var(--gold-700);
  transition: transform var(--dur) var(--ease), border-color var(--dur) var(--ease);
}

.accordion__trigger[aria-expanded='true'] .accordion__icon {
  transform: rotate(45deg);
  border-color: var(--gold-500);
}

.accordion__panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows var(--dur-slow) var(--ease-out);
}

.accordion__panel[data-open='true'] { grid-template-rows: 1fr; }

.accordion__panel > div { overflow: hidden; }

.accordion__content {
  padding-bottom: var(--s5);
  color: var(--text-muted);
  max-width: var(--measure);
}

/* ── Forms ────────────────────────────────────────────────── */

.form { display: grid; gap: var(--s5); }

.form-row {
  display: grid;
  gap: var(--s5);
}

@media (min-width: 40rem) {
  .form-row--2 { grid-template-columns: 1fr 1fr; }
  .form-row--3 { grid-template-columns: repeat(3, 1fr); }
}

.field { display: grid; gap: var(--s2); }

.field__label {
  font-family: var(--font-head);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--text);
}

.field__required { color: var(--danger); margin-left: 2px; }

.field__hint {
  font-size: var(--fs-sm);
  color: var(--text-subtle);
  line-height: var(--lh-snug);
}

.field__control {
  width: 100%;
  min-height: 48px;
  padding: var(--s3) var(--s4);
  font-size: var(--fs-base);
  color: var(--text);
  background: var(--surface);
  border: 1.5px solid var(--line-strong);
  border-radius: var(--r-md);
  transition: border-color var(--dur-fast) var(--ease),
              box-shadow var(--dur-fast) var(--ease);
  appearance: none;
}

textarea.field__control { min-height: 8rem; resize: vertical; line-height: var(--lh-normal); }

select.field__control {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235A6472' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right var(--s4) center;
  padding-right: var(--s7);
}

.field__control::placeholder { color: var(--text-subtle); }

.field__control:hover { border-color: var(--text-subtle); }

.field__control:focus {
  outline: none;
  border-color: var(--gold-500);
  box-shadow: 0 0 0 3px rgba(201, 151, 43, 0.18);
}

.field__control:focus-visible { outline: none; }

.field.has-error .field__control { border-color: var(--danger); }
.field.has-error .field__control:focus { box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.16); }

.field__error {
  display: flex;
  align-items: flex-start;
  gap: var(--s2);
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--danger);
  line-height: var(--lh-snug);
}
.field__error svg { width: 1rem; height: 1rem; flex-shrink: 0; margin-top: 2px; }

.field--checkbox {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--s3);
  align-items: start;
}

.field--checkbox input {
  width: 1.25rem; height: 1.25rem;
  margin-top: 0.2em;
  accent-color: var(--gold-600);
  cursor: pointer;
}

.field--checkbox label { font-size: var(--fs-sm); color: var(--text-muted); cursor: pointer; }

/* Honeypot — hidden from people, visible to naive bots */
.field--trap {
  position: absolute !important;
  left: -9999px !important;
  opacity: 0;
  pointer-events: none;
}

.form-dark .field__label { color: var(--text-invert); }
.form-dark .field__hint { color: var(--text-on-dark-muted); }
.form-dark .field__control {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.18);
  color: var(--text-invert);
}
.form-dark .field__control::placeholder { color: rgba(255, 255, 255, 0.4); }
.form-dark .field__control:focus {
  border-color: var(--gold-400);
  background: rgba(255, 255, 255, 0.08);
}
.form-dark .field--checkbox label { color: var(--text-on-dark-muted); }

/* ── Alerts ───────────────────────────────────────────────── */

.alert {
  display: flex;
  align-items: flex-start;
  gap: var(--s3);
  padding: var(--s4) var(--s5);
  border-radius: var(--r-md);
  border: 1px solid;
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
}

.alert svg { width: 1.25rem; height: 1.25rem; flex-shrink: 0; margin-top: 2px; }
.alert p { max-width: none; }

.alert--success { background: var(--success-soft); border-color: #A7E3BE; color: #14532D; }
.alert--error { background: var(--danger-soft); border-color: #FBC5C5; color: #7F1D1D; }
.alert--warning { background: var(--warning-soft); border-color: #F5D9A6; color: #78350F; }
.alert--info { background: var(--tech-soft); border-color: #A9DCE8; color: #134E4A; }

/* ── Badges & pills ───────────────────────────────────────── */

.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--s2);
  padding: 0.25rem var(--s3);
  font-family: var(--font-head);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: var(--ls-wide);
  border-radius: var(--r-full);
  background: var(--surface-sunken);
  color: var(--text-muted);
  white-space: nowrap;
}

.badge--gold { background: var(--gold-050); color: var(--gold-700); border: 1px solid var(--gold-200); }
.badge--tech { background: var(--tech-soft); color: #0F5C6E; }
.badge--success { background: var(--success-soft); color: #14532D; }
.badge--muted { background: var(--surface-sunken); color: var(--text-subtle); }

.pill-list { display: flex; flex-wrap: wrap; gap: var(--s2); list-style: none; padding: 0; }
.pill-list li { margin-top: 0; }

.pill {
  display: inline-block;
  padding: var(--s2) var(--s4);
  font-size: var(--fs-sm);
  border: 1px solid var(--line);
  border-radius: var(--r-full);
  background: var(--surface);
  color: var(--text-muted);
  text-decoration: none;
  transition: all var(--dur-fast) var(--ease);
}

.pill:hover, .pill.is-active {
  border-color: var(--gold-500);
  background: var(--gold-050);
  color: var(--gold-700);
}

/* ── Breadcrumbs ──────────────────────────────────────────── */

.breadcrumbs {
  padding-block: var(--s4);
  font-size: var(--fs-sm);
  border-bottom: 1px solid var(--line);
  background: var(--surface-alt);
}

.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s2);
  list-style: none;
  padding: 0;
}

.breadcrumbs li { display: flex; align-items: center; gap: var(--s2); margin-top: 0; }

.breadcrumbs li + li::before {
  content: '';
  width: 5px; height: 5px;
  border-top: 1.5px solid var(--text-subtle);
  border-right: 1.5px solid var(--text-subtle);
  transform: rotate(45deg);
  flex-shrink: 0;
}

.breadcrumbs a { color: var(--text-muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--gold-700); text-decoration: underline; }
.breadcrumbs [aria-current='page'] { color: var(--text); font-weight: 600; }

/* ── Pagination ───────────────────────────────────────────── */

.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: var(--s2);
  list-style: none;
  padding: 0;
  margin-top: var(--s8);
}

.pagination li { margin-top: 0; }

.pagination a, .pagination span {
  display: grid;
  place-items: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 var(--s3);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  font-family: var(--font-head);
  font-size: var(--fs-sm);
  font-weight: 600;
  text-decoration: none;
  color: var(--text-muted);
  transition: all var(--dur-fast) var(--ease);
}

.pagination a:hover { border-color: var(--gold-500); color: var(--gold-700); background: var(--gold-050); }
.pagination [aria-current='page'] { background: var(--ink-900); border-color: var(--ink-900); color: var(--text-invert); }
.pagination .is-gap { border: 0; color: var(--text-subtle); min-width: auto; }

/* ── Stats ────────────────────────────────────────────────── */

.stat { text-align: center; }

.stat__value {
  display: block;
  font-family: var(--font-head);
  font-size: var(--fs-4xl);
  font-weight: 700;
  line-height: 1;
  letter-spacing: var(--ls-tight);
  background: var(--gold-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-variant-numeric: tabular-nums;
}

.stat__label {
  display: block;
  margin-top: var(--s3);
  font-size: var(--fs-sm);
  line-height: var(--lh-snug);
  color: var(--text-muted);
  max-width: 14rem;
  margin-inline: auto;
}

.section--dark .stat__label { color: var(--text-on-dark-muted); }

/* ── Scroll reveal ────────────────────────────────────────── */

[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 600ms var(--ease-out), transform 600ms var(--ease-out);
  will-change: opacity, transform;
}

[data-reveal].is-visible { opacity: 1; transform: none; }

/* ── Icon sizing ──────────────────────────────────────────── */

.icon { width: 1.25rem; height: 1.25rem; flex-shrink: 0; }
.icon--sm { width: 1rem; height: 1rem; }
.icon--lg { width: 1.5rem; height: 1.5rem; }
