@import url('https://fonts.googleapis.com/css2?family=Spline+Sans+Mono:wght@400;500&display=swap');

/* ── H2-CORAL hero · "Hydrogen Crystal" ─────────────────────────────
   Scoped entirely under [data-h2c-hero]. The legacy React hero is hidden
   (not removed) so the bundle keeps reconciling normally. */
section.bg-gradient-to-br.from-brand-ocean.via-brand-teal { display: none !important; }

[data-h2c-hero] {
  --h2c-abyss: #0c242b;
  --h2c-navy: #103138;
  --h2c-deep: #154650;
  --h2c-glacier: #8edbd8;
  --h2c-ice: #d1efee;
  --h2c-pearl: #f3efe6;
  --h2c-silver: #b9c4d1;
  --h2c-mute: rgba(207, 232, 248, 0.62);
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 100dvh;
  color: var(--h2c-pearl);
  background:
    radial-gradient(60% 55% at 72% 46%, rgba(44, 158, 157, 0.24), transparent 70%),
    radial-gradient(40% 40% at 12% 90%, rgba(142, 219, 216, 0.10), transparent 70%),
    radial-gradient(120% 90% at 50% 0%, #123d46 0%, var(--h2c-abyss) 70%);
  font-family: 'DM Sans', ui-sans-serif, system-ui, sans-serif;
}
[data-h2c-hero]::before {
  /* faint crystal grid */
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(rgba(185, 196, 209, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(185, 196, 209, 0.05) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(70% 70% at 65% 45%, #000 20%, transparent 75%);
          mask-image: radial-gradient(70% 70% at 65% 45%, #000 20%, transparent 75%);
}
[data-h2c-hero]::after {
  /* grain */
  content: ""; position: absolute; inset: 0; z-index: 3; pointer-events: none; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.h2c-inner {
  position: relative; z-index: 2;
  max-width: 80rem; margin: 0 auto;
  min-height: 100dvh;
  padding: 104px 24px 56px;
  display: grid; gap: 28px;
  grid-template-columns: 1fr;
  align-items: center;
}
@media (min-width: 768px) { .h2c-inner { padding: 112px 48px 64px; } }
@media (min-width: 1024px) {
  .h2c-inner { grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr); gap: 32px; }
}

/* ── copy column ── */
.h2c-copy { position: relative; order: 1; max-width: 36rem; }
@media (min-width: 1024px) { .h2c-copy { order: 1; } }

.h2c-eyebrow {
  display: flex; align-items: center; gap: 14px;
  font-family: 'Spline Sans Mono', ui-monospace, monospace;
  font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--h2c-glacier);
}
.h2c-eyebrow::before { content: ""; width: 36px; height: 1px; background: linear-gradient(90deg, transparent, var(--h2c-glacier)); }

.h2c-title {
  margin: 18px 0 0;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 600; line-height: 1.08; letter-spacing: -0.02em;
  font-size: clamp(32px, 4.1vw, 54px);
  background: linear-gradient(176deg, #fbf8f1 30%, #c9d6e3 62%, #eef4f9 85%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  white-space: normal;
}
.h2c-title sub { font-size: .46em; vertical-align: -0.02em; letter-spacing: 0; }
.h2c-title sup { font-size: .22em; vertical-align: 2.6em; font-family: 'DM Sans', sans-serif; font-weight: 500; letter-spacing: 0; color: var(--h2c-silver); -webkit-text-fill-color: var(--h2c-silver); }

.h2c-tagline {
  margin: 20px 0 0;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-style: italic; font-weight: 500;
  font-size: clamp(24px, 2.6vw, 34px); line-height: 1.15;
  color: var(--h2c-ice);
}
.h2c-product {
  margin: 22px 0 0; padding-top: 18px;
  border-top: 1px solid rgba(185, 196, 209, 0.22);
  font-size: 12.5px; font-weight: 600; letter-spacing: .32em; text-transform: uppercase;
  color: var(--h2c-silver);
}
.h2c-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.h2c-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 0 26px; border-radius: 999px;
  font-size: 15px; font-weight: 600; text-decoration: none;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), background-color .35s, border-color .35s, color .35s;
}
.h2c-btn:focus-visible, .h2c-ctrl:focus-visible { outline: 2px solid var(--h2c-glacier); outline-offset: 3px; }
.h2c-btn--primary { background: var(--h2c-pearl); color: var(--h2c-navy); box-shadow: 0 14px 34px -14px rgba(142, 201, 238, .55); }
.h2c-btn--primary:hover { transform: translateY(-2px); background: #fffdf8; }
.h2c-btn--ghost { border: 1px solid rgba(207, 232, 248, .35); color: var(--h2c-pearl); background: rgba(207, 232, 248, .04); }
.h2c-btn--ghost:hover { border-color: rgba(207, 232, 248, .7); background: rgba(207, 232, 248, .09); transform: translateY(-2px); }
.h2c-btn svg { transition: transform .35s; }
.h2c-btn:hover svg { transform: translateY(2px); }
@media (max-width: 480px) { .h2c-btn { flex: 1 1 100%; } }

.h2c-fact {
  margin-top: 30px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-family: 'Spline Sans Mono', ui-monospace, monospace;
  font-size: 11px; letter-spacing: .08em; color: var(--h2c-mute);
}
.h2c-fact i { width: 5px; height: 5px; border-radius: 50%; background: var(--h2c-glacier); opacity: .8; }

/* staggered entrance */
.h2c-rise { opacity: 0; transform: translateY(18px); transition: opacity 1s cubic-bezier(.2,.7,.2,1), transform 1s cubic-bezier(.2,.7,.2,1); }
[data-h2c-hero].is-in .h2c-rise { opacity: 1; transform: none; }
[data-h2c-hero].is-in .h2c-rise:nth-child(2) { transition-delay: .08s; }
[data-h2c-hero].is-in .h2c-rise:nth-child(3) { transition-delay: .18s; }
[data-h2c-hero].is-in .h2c-rise:nth-child(4) { transition-delay: .28s; }
[data-h2c-hero].is-in .h2c-rise:nth-child(5) { transition-delay: .38s; }
[data-h2c-hero].is-in .h2c-rise:nth-child(6) { transition-delay: .48s; }

/* ── stage ── */
.h2c-stage {
  position: relative; order: 2;
  width: 100%; aspect-ratio: 1 / 1; max-width: 560px; margin: 0 auto;
  border-radius: 28px;
  opacity: 0; transform: scale(.97);
  transition: opacity 1.4s ease, transform 1.6s cubic-bezier(.2,.7,.2,1);
}
[data-h2c-hero].is-in .h2c-stage { opacity: 1; transform: none; }
@media (min-width: 1024px) {
  .h2c-stage { order: 2; max-width: none; aspect-ratio: auto; height: min(76vh, 720px); min-height: 520px; }
}
.h2c-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.h2c-frame {
  position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  border: 1px solid rgba(185, 196, 209, .12);
  background: linear-gradient(160deg, rgba(207,232,248,.05), transparent 40%);
}
.h2c-frame::before, .h2c-frame::after {
  content: ""; position: absolute; width: 14px; height: 14px; border-color: rgba(207,232,248,.5); border-style: solid;
}
.h2c-frame::before { top: 12px; left: 12px; border-width: 1px 0 0 1px; }
.h2c-frame::after { bottom: 12px; right: 12px; border-width: 0 1px 1px 0; }

.h2c-hud {
  position: absolute; left: 18px; right: 18px; top: 16px;
  display: flex; align-items: flex-start; justify-content: space-between; gap: 12px;
  font-family: 'Spline Sans Mono', ui-monospace, monospace;
}
.h2c-phase { min-height: 34px; }
.h2c-phase-num { font-size: 10px; letter-spacing: .2em; color: var(--h2c-glacier); }
.h2c-phase-name {
  display: block; margin-top: 4px; font-size: 12px; letter-spacing: .06em; color: var(--h2c-ice);
  transition: opacity .45s ease, transform .45s ease;
}
.h2c-phase-name.is-swap { opacity: 0; transform: translateY(4px); }

.h2c-ctrl {
  pointer-events: auto; flex: none;
  display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px 0 10px;
  border-radius: 999px; border: 1px solid rgba(207,232,248,.28); background: rgba(12,36,43,.55);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  color: var(--h2c-ice); font: 500 11px/1 'Spline Sans Mono', ui-monospace, monospace; letter-spacing: .08em;
  cursor: pointer; transition: border-color .3s, background-color .3s;
}
.h2c-ctrl:hover { border-color: rgba(207,232,248,.6); background: rgba(21,70,80,.65); }
.h2c-ctrl svg { width: 12px; height: 12px; }

.h2c-foot {
  position: absolute; left: 18px; right: 18px; bottom: 16px;
  display: flex; flex-direction: column; gap: 10px; pointer-events: none;
}
.h2c-ticks { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.h2c-tick { position: relative; height: 2px; border-radius: 2px; background: rgba(185,196,209,.18); overflow: hidden; }
.h2c-tick b { position: absolute; inset: 0; background: linear-gradient(90deg, var(--h2c-glacier), var(--h2c-pearl)); transform-origin: left; transform: scaleX(0); }
.h2c-note {
  font-family: 'Spline Sans Mono', ui-monospace, monospace;
  font-size: 10px; letter-spacing: .08em; color: rgba(207,232,248,.55);
}

.h2c-sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

@media (prefers-reduced-motion: reduce) {
  .h2c-rise, .h2c-stage, .h2c-btn, .h2c-phase-name { transition: none !important; }
}
