/**
 * Brand: EtherSight (ethersight.app) — Flare Amber accent.
 * Amber fails WCAG as white-on-amber button fill, so interactive
 * elements use amber-600/700 with dark ink text where needed;
 * links use the darker end of the ramp in light mode.
 */

/* NOTE — selectors: brand overrides use `html:root` (and
 * `html:root[data-theme="dark"]`) rather than bare `:root` so they beat
 * the master token defaults in base/type/common.css regardless of CSS
 * bundle order (Vite emits this file BEFORE the master tokens, which are
 * imported by the shared BaseLayout). */

html:root {
  --brand-50:  var(--color-ethersight-50);
  --brand-100: var(--color-ethersight-100);
  --brand-300: var(--color-ethersight-300);
  --brand-400: var(--color-ethersight-400);
  --brand-500: var(--color-ethersight-500);
  --brand-600: var(--color-ethersight-600);
  --brand-700: var(--color-ethersight-700);
  --brand-900: var(--color-ethersight-900);

  --brand-gradient: linear-gradient(135deg, var(--color-ethersight-500), var(--color-primary-500));

  --text-link:       var(--color-ethersight-700);
  --text-link-hover: var(--color-ethersight-800);
  --border-focus:    var(--color-ethersight-500);

  --interactive-primary:       var(--color-ethersight-600);
  --interactive-primary-hover: var(--color-ethersight-700);
  --interactive-ghost:         var(--color-ethersight-700);
  --interactive-ghost-hover:   var(--color-ethersight-50);
}

html:root[data-theme="dark"] {
  --text-link:       var(--color-ethersight-400);
  --text-link-hover: var(--color-ethersight-300);
  --border-focus:    var(--color-ethersight-400);

  --interactive-primary:       var(--color-ethersight-600);
  --interactive-primary-hover: var(--color-ethersight-500);
  --interactive-ghost:         var(--color-ethersight-400);
  --interactive-ghost-hover:   var(--color-neutral-800);

  --brand-gradient: linear-gradient(135deg, var(--color-ethersight-400), var(--color-primary-400));
}

/* ------------------------------------------------------------------
   Personality — matches the live ethersight.app "Sovereign Software"
   build: dark instrument panel with a faint cyan grid backdrop, left
   split hero, cyan→violet gradient on emphasised spans, amber CTAs
   with a glow ring, mono eyebrows. Default colour-scheme is dark.
   ------------------------------------------------------------------ */

html:root {
  --hero-align: left;
  --hero-content-margin: 0;
  --hero-cta-justify: flex-start;
  --hero-pad-top: var(--space-20);
  --hero-pad-bottom: var(--space-24);
  --hero-heading-size: clamp(2.5rem, 5.5vw, 4rem);
  --hero-heading-max: 18ch;
  --display-weight: var(--font-weight-bold);
  --display-leading: 1.05;
  --display-tracking: -0.03em;

  --section-rhythm: var(--space-20);

  --eyebrow-font: var(--font-mono);
  --eyebrow-color: var(--color-secondary-400);

  /* Live hero emphasis: cyan→violet gradient text */
  --emphasis-gradient: linear-gradient(135deg, var(--color-secondary-300), var(--color-primary-400));
}

/* Amber CTA glow ring (live .btn--amber) — dark scheme only, where the
   glow reads; consumed by the shared Button via --btn-shadow. */
html:root[data-theme="dark"] {
  --btn-shadow: 0 0 0 1px var(--color-ethersight-500), 0 8px 24px -8px rgba(245, 158, 11, 0.55);
  --btn-shadow-hover: 0 0 0 1px var(--color-ethersight-400), 0 8px 28px -6px rgba(245, 158, 11, 0.65);

  /* Live dark CTAs are Flare Amber with dark ink, not white-on-amber */
  --interactive-primary:       var(--color-ethersight-500);
  --interactive-primary-hover: var(--color-ethersight-400);
  --interactive-primary-text:  #1A1206;
}

/* Faint cyan instrument grid across the whole page (live body::before),
   fading out from the top. Dark scheme only. */
[data-theme="dark"] body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(rgba(34, 211, 238, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(34, 211, 238, 0.025) 1px, transparent 1px);
  background-size: 32px 32px;
  -webkit-mask-image: radial-gradient(ellipse at top, rgba(0, 0, 0, 0.6) 0%, transparent 70%);
  mask-image: radial-gradient(ellipse at top, rgba(0, 0, 0, 0.6) 0%, transparent 70%);
}

[data-theme="dark"] body > main,
[data-theme="dark"] body > header,
[data-theme="dark"] body > footer {
  position: relative;
  z-index: 1;
}
