/* Ultimate ICE — download page
   Palette follows the desktop app: deep navy glass, cyan-blue accents, soft glow. */

:root {
  --bg-0: #030a18;
  --bg-1: #061630;
  --bg-2: #0a2147;
  --panel: rgba(10, 32, 68, .62);
  --panel-solid: #0a1e3f;
  --line: rgba(110, 180, 255, .16);
  --line-strong: rgba(90, 175, 255, .45);
  --ice: #3fb4ff;
  --ice-hi: #7fd3ff;
  --ice-deep: #1a7fe0;
  --text: #e8f3ff;
  --text-dim: #9fb9d8;
  --text-faint: #6a87ab;
  --good: #5ee0c0;
  --glow: 0 0 24px rgba(63, 180, 255, .45);
  --radius: 22px;
  --gutter: clamp(16px, 4vw, 56px);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: radial-gradient(120% 90% at 70% 10%, var(--bg-2) 0%, var(--bg-1) 40%, var(--bg-0) 100%) fixed;
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
.mono { font-family: var(--mono); }
button { font: inherit; color: inherit; }

/* ---------- Background layers ---------- */
#net { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; }
.bg-glow {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(40% 35% at 50% 48%, rgba(40, 140, 255, .20), transparent 70%),
    radial-gradient(30% 30% at 85% 15%, rgba(80, 200, 255, .12), transparent 70%),
    radial-gradient(35% 30% at 10% 90%, rgba(30, 90, 220, .18), transparent 70%);
  animation: breathe 9s ease-in-out infinite alternate;
}
.bg-noise {
  position: fixed; inset: 0; z-index: 0; 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");
}
@keyframes breathe { from { opacity: .75; } to { opacity: 1; } }

/* ---------- Frame (the glass card) ---------- */
.frame {
  position: relative; z-index: 1;
  margin: clamp(10px, 2.4vh, 28px) auto;
  width: min(1480px, calc(100% - 2 * clamp(10px, 2vw, 28px)));
  height: calc(100vh - 2 * clamp(10px, 2.4vh, 28px));
  min-height: 680px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(160deg, rgba(14, 44, 92, .38), rgba(4, 14, 34, .30));
  box-shadow: 0 40px 120px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(140, 200, 255, .10);
  backdrop-filter: blur(2px);
  overflow: hidden;
}

/* editorial guide lines */
.grid { position: absolute; inset: 0; pointer-events: none; }
.gl { position: absolute; background: var(--line); transform-origin: left top; }
.gl-h { left: 0; right: 0; height: 1px; transform: scaleX(0); transition: transform 1.6s cubic-bezier(.2,.7,.1,1); }
.gl-v { top: 0; bottom: 0; width: 1px; transform: scaleY(0); transition: transform 1.8s cubic-bezier(.2,.7,.1,1); }
.gl-top { top: 96px; }
.gl-bottom { bottom: 92px; }
.gl-1 { left: var(--gutter); }
.gl-2 { left: 33.33%; }
.gl-3 { left: 66.66%; }
.gl-4 { right: var(--gutter); }
.ready .gl-h, .ready .gl-v { transform: none; }
.ready .gl-v { transition-delay: .25s; }
.dot {
  position: absolute; bottom: 87px; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%;
  background: var(--text); box-shadow: var(--glow); opacity: 0; transform: scale(0);
  transition: opacity .5s, transform .5s cubic-bezier(.3,1.6,.5,1);
}
.d-1 { left: var(--gutter); } .d-2 { left: 33.33%; } .d-3 { left: 66.66%; } .d-4 { left: calc(100% - var(--gutter)); }
.ready .dot { opacity: 1; transform: scale(1); }
.ready .d-1 { transition-delay: 1.3s; } .ready .d-2 { transition-delay: 1.4s; }
.ready .d-3 { transition-delay: 1.5s; } .ready .d-4 { transition-delay: 1.6s; }

/* giant outlined watermark */
.watermark {
  position: absolute; left: 50%; bottom: -0.2em; transform: translateX(-50%);
  font-size: clamp(180px, 34vw, 520px); font-weight: 800; letter-spacing: -.04em; line-height: 1;
  color: transparent; -webkit-text-stroke: 1px rgba(110, 190, 255, .10);
  background: linear-gradient(180deg, rgba(80, 170, 255, .10), transparent 70%);
  -webkit-background-clip: text; background-clip: text;
  pointer-events: none; user-select: none;
}

/* ---------- Reveal-on-load ---------- */
.reveal { opacity: 0; transform: translateY(14px); filter: blur(6px);
  transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.2,1), filter .9s ease;
  transition-delay: var(--d, 0s); }
.ready .reveal { opacity: 1; transform: none; filter: none; }

/* ---------- Top bar ---------- */
.topbar {
  position: absolute; top: 0; left: 0; right: 0; height: 96px;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 var(--gutter);
}
.brand { display: flex; align-items: center; gap: 12px; color: var(--text); text-decoration: none; font-size: 22px; font-weight: 600; letter-spacing: .01em; }
.brand img { filter: drop-shadow(0 0 10px rgba(63,180,255,.6)); }
.brand b { color: var(--ice); font-weight: 700; }
.top-actions { display: flex; gap: 10px; }
.pill {
  display: inline-flex; align-items: center; height: 44px; padding: 0 22px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: rgba(10, 34, 72, .55);
  color: var(--text); text-decoration: none; font-size: 14px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  cursor: pointer; transition: background .25s, box-shadow .25s, transform .25s;
}
.pill:hover { background: rgba(30, 90, 170, .55); box-shadow: var(--glow); transform: translateY(-1px); }
.pill-solid { background: var(--text); color: var(--bg-1); border-color: transparent; }
.pill-solid:hover { background: #fff; }

/* ---------- Side copy ---------- */
.meta { position: absolute; top: 140px; left: var(--gutter); font-size: 15px; color: var(--text-dim); line-height: 1.55; }
.meta p { margin: 0; }
.meta .mono { margin-bottom: 18px; color: var(--text); }
.meta b { color: var(--text); font-weight: 600; }
.pitch { position: absolute; top: 140px; right: var(--gutter); max-width: 300px; text-align: right; font-size: 16px; line-height: 1.6; color: var(--text-dim); }
.pitch p { margin: 0; }
.pitch b { color: var(--ice-hi); font-weight: 600; }

/* ---------- Hero ---------- */
.hero {
  position: absolute; left: 50%; top: 48%; transform: translate(-50%, -50%);
  width: min(880px, 92%); text-align: center;
}
.logo-orbit { position: relative; width: 132px; height: 132px; margin: 0 auto 18px; display: grid; place-items: center; }
.logo-orbit img { width: 88px; height: 88px; filter: drop-shadow(0 0 22px rgba(63,180,255,.75)); animation: float 6s ease-in-out infinite; }
.orbit { position: absolute; inset: 0; border-radius: 50%; border: 1px solid rgba(110,190,255,.28); }
.orbit::after { content: ""; position: absolute; top: -3px; left: 50%; width: 6px; height: 6px; margin-left: -3px; border-radius: 50%; background: var(--ice-hi); box-shadow: var(--glow); }
.o1 { animation: spin 14s linear infinite; }
.o2 { inset: -16px; border-style: dashed; border-color: rgba(110,190,255,.14); animation: spin 26s linear infinite reverse; }
.o2::after { background: var(--ice); width: 4px; height: 4px; margin-left: -2px; top: -2px; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes float { 50% { transform: translateY(-5px); } }

.eyebrow { margin: 0 0 10px; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--ice-hi); }
h1 {
  margin: 0; font-size: clamp(48px, 8.4vw, 116px); font-weight: 800; letter-spacing: -.035em; line-height: .98;
  text-shadow: 0 6px 40px rgba(20, 90, 200, .45);
}
h1 .ice {
  background: linear-gradient(100deg, var(--ice-hi) 0%, var(--ice) 40%, #ffffff 50%, var(--ice) 60%, var(--ice-deep) 100%);
  background-size: 250% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: sheen 6s ease-in-out 1.6s infinite;
}
@keyframes sheen { 0% { background-position: 100% 0; } 45%, 100% { background-position: 0 0; } }
.subtitle { margin: 12px 0 0; font-size: clamp(18px, 2.2vw, 26px); font-weight: 300; letter-spacing: .32em; text-transform: uppercase; color: var(--text-dim); }

.downloads { display: flex; justify-content: center; flex-wrap: wrap; gap: 14px; margin-top: 40px; }
.dl {
  position: relative; display: flex; align-items: center; gap: 12px; min-width: 200px; padding: 14px 22px;
  border-radius: 14px; border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, rgba(20, 64, 128, .65), rgba(8, 30, 66, .75));
  color: var(--text); text-decoration: none; text-align: left; overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(160, 215, 255, .18);
  transition: transform .25s cubic-bezier(.3,1.4,.5,1), box-shadow .25s, border-color .25s;
}
.dl::before { /* sweeping highlight on hover */
  content: ""; position: absolute; inset: 0; transform: translateX(-120%);
  background: linear-gradient(100deg, transparent 30%, rgba(160, 220, 255, .22) 50%, transparent 70%);
  transition: transform .7s ease;
}
.dl:hover { transform: translateY(-3px); border-color: var(--ice); box-shadow: var(--glow), inset 0 1px 0 rgba(160,215,255,.25); }
.dl:hover::before { transform: translateX(120%); }
.dl svg { width: 26px; height: 26px; fill: var(--ice-hi); flex: none; }
.dl b { display: block; font-size: 17px; font-weight: 600; }
.dl small { display: block; font-size: 12.5px; color: var(--text-dim); margin-top: 2px; }
.dl.primary { background: linear-gradient(180deg, #49b8ff, #1a7fe0); border-color: rgba(190, 230, 255, .6); box-shadow: 0 10px 36px rgba(30, 130, 240, .45), inset 0 1px 0 rgba(255,255,255,.35); }
.dl.primary svg { fill: #fff; }
.dl.primary small { color: rgba(240, 248, 255, .85); }

/* not yet available: muted, with a "Coming soon" tooltip */
.dl.soon { overflow: visible; cursor: default; }
.dl.soon::before { display: none; }
.dl.soon > svg, .dl.soon > span:not(.tip) { opacity: .6; }
.dl.soon:hover, .dl.soon:focus-visible { transform: none; border-color: var(--line-strong); box-shadow: inset 0 1px 0 rgba(160,215,255,.18); outline: none; }
.tip {
  position: absolute; left: 50%; bottom: calc(100% + 10px); z-index: 5;
  padding: 6px 12px; border-radius: 8px; white-space: nowrap;
  background: linear-gradient(180deg, #49b8ff, #1a7fe0); color: #fff;
  font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  box-shadow: 0 8px 24px rgba(20, 110, 230, .45);
  opacity: 0; transform: translate(-50%, 6px) scale(.95); pointer-events: none;
  transition: opacity .2s ease, transform .25s cubic-bezier(.3,1.5,.5,1);
}
.tip::after { content: ""; position: absolute; left: 50%; top: 100%; margin-left: -6px; border: 6px solid transparent; border-top-color: #1a7fe0; }
.dl.soon:hover .tip, .dl.soon:focus-visible .tip { opacity: 1; transform: translate(-50%, 0) scale(1); }
.fineprint { margin: 22px 0 0; font-size: 12.5px; letter-spacing: .06em; color: var(--text-faint); }

/* ---------- Hotspots ---------- */
.hotspot {
  position: absolute; z-index: 3; width: 92px; height: 92px; margin: -46px 0 0 -46px; padding: 0;
  border: 0; background: none; cursor: pointer; display: grid; place-items: center;
}
.hotspot[hidden] { display: none; }
.hs-ui { left: 79%; top: 42%; }
.hs-results { left: 15%; top: 68%; }

.hs-ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.hs-ring circle { fill: none; stroke: rgba(200, 235, 255, .7); stroke-width: 1.2; stroke-dasharray: 290; stroke-dashoffset: 290; }
.hs-core {
  position: relative; width: 56px; height: 56px; border-radius: 50%;
  display: grid; place-items: center;
  background: #fff; color: var(--bg-1); font: italic 700 26px/1 Georgia, "Times New Roman", serif;
  box-shadow: 0 0 0 0 rgba(120, 210, 255, .6), 0 10px 30px rgba(0, 40, 120, .5);
  transform: scale(0);
}
.hs-core::before, .hs-core::after { /* sonar ripples */
  content: ""; position: absolute; inset: 0; border-radius: 50%; border: 1px solid rgba(160, 225, 255, .8); opacity: 0;
}
.hs-label {
  position: absolute; left: 100%; top: 50%; margin-left: 4px; transform: translate(-8px, -50%);
  white-space: nowrap; font-size: 13px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase;
  color: var(--text); opacity: 0; transition: opacity .5s 1.3s, transform .5s 1.3s;
}
.hs-results .hs-label { left: auto; right: 100%; margin: 0 4px 0 0; transform: translate(8px, -50%); }

.hotspot.in .hs-ring circle { animation: draw 1s cubic-bezier(.6,0,.2,1) forwards; }
.hotspot.in .hs-core { animation: pop .6s cubic-bezier(.3,1.7,.5,1) .8s forwards; }
.hotspot.in .hs-core::before { animation: ripple 2.4s ease-out 1.4s infinite; }
.hotspot.in .hs-core::after { animation: ripple 2.4s ease-out 2.6s infinite; }
.hotspot.in .hs-label { opacity: .9; transform: translate(0, -50%); }
.hotspot.seen .hs-core::before, .hotspot.seen .hs-core::after { animation: none; }
.hotspot:hover .hs-core, .hotspot:focus-visible .hs-core { box-shadow: 0 0 0 6px rgba(120, 210, 255, .25), 0 10px 30px rgba(0, 40, 120, .5); }
.hotspot:focus-visible { outline: none; }

@keyframes draw { 0% { stroke-dashoffset: 290; } 70% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: 0; } }
@keyframes pop { from { transform: scale(0); } to { transform: scale(1); } }
@keyframes ripple { 0% { opacity: .9; transform: scale(1); } 100% { opacity: 0; transform: scale(2.4); } }

/* ---------- Feature strip ---------- */
.features {
  position: absolute; left: 0; right: 0; bottom: 0; height: 92px;
  display: grid; grid-template-columns: repeat(3, 1fr); align-items: center;
  padding: 0 var(--gutter);
}
.feature { text-align: center; font-size: 15px; color: var(--text-dim); }
.feature .mono { color: var(--ice); font-size: 12px; margin-right: 8px; }

/* ---------- Dialogs ---------- */
dialog.panel {
  width: min(920px, calc(100% - 32px)); max-height: calc(100vh - 48px);
  padding: 28px; border-radius: 20px; border: 1px solid var(--line-strong);
  background: linear-gradient(170deg, rgba(14, 44, 92, .92), rgba(5, 18, 42, .96));
  color: var(--text);
  box-shadow: 0 40px 120px rgba(0, 0, 0, .6), 0 0 0 1px rgba(63, 180, 255, .08), 0 0 60px rgba(40, 140, 255, .18);
  overflow: auto;
}
dialog.panel[open] { animation: dlg-in .5s cubic-bezier(.2,.9,.2,1); }
dialog.panel::backdrop { background: rgba(2, 8, 20, .62); backdrop-filter: blur(6px); animation: fade .4s ease; }
@keyframes dlg-in { from { opacity: 0; transform: translateY(18px) scale(.96); filter: blur(4px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes fade { from { opacity: 0; } }

.close {
  position: absolute; top: 16px; right: 16px; width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid var(--line-strong); background: rgba(10, 34, 72, .6); font-size: 22px; line-height: 1; cursor: pointer;
  transition: transform .25s, background .25s;
}
.close:hover { transform: rotate(90deg); background: rgba(40, 110, 200, .6); }

.panel-head { display: flex; align-items: center; gap: 16px; margin: 0 48px 20px 0; }
.panel-icon {
  flex: none; width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center;
  background: linear-gradient(180deg, #49b8ff, #1a6fd0); box-shadow: var(--glow);
}
.panel-icon svg { width: 26px; height: 26px; fill: none; stroke: #fff; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.kicker { margin: 0 0 4px; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--ice-hi); }
.panel h2 { margin: 0; font-size: clamp(22px, 3vw, 30px); font-weight: 700; letter-spacing: -.01em; }

.shot { margin: 0; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 20px 60px rgba(0,0,0,.4); }
.shot img { display: block; width: 100%; height: auto; }
dialog[open] .shot img { animation: zoom-in 1.2s cubic-bezier(.2,.8,.2,1); }
@keyframes zoom-in { from { transform: scale(1.06); opacity: .4; } }
.panel-text { margin: 20px 0 14px; font-size: 15.5px; line-height: 1.65; color: var(--text-dim); max-width: 70ch; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; }
.chips li {
  padding: 7px 14px; border-radius: 999px; font-size: 13px; color: var(--text);
  border: 1px solid var(--line-strong); background: rgba(20, 64, 128, .4);
}
dialog[open] .chips li { animation: chip .5s cubic-bezier(.3,1.5,.5,1) backwards; }
dialog[open] .chips li:nth-child(2) { animation-delay: .08s; }
dialog[open] .chips li:nth-child(3) { animation-delay: .16s; }
dialog[open] .chips li:nth-child(4) { animation-delay: .24s; }
@keyframes chip { from { opacity: 0; transform: translateY(8px) scale(.9); } }

/* results table */
.table-wrap { overflow-x: auto; border-radius: 14px; border: 1px solid var(--line); background: rgba(3, 12, 30, .45); }
.results { width: 100%; border-collapse: collapse; font-size: 15px; }
.results th {
  padding: 14px 18px; text-align: left; font-size: 11.5px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  color: var(--text-faint); border-bottom: 1px solid var(--line);
}
.results td { padding: 16px 18px; border-bottom: 1px solid rgba(110, 180, 255, .08); white-space: nowrap; }
.results tbody tr:last-child td { border-bottom: 0; }
.results .num { text-align: right; }
.results small { display: block; font-size: 12px; color: var(--text-faint); margin-top: 2px; }
.results b { color: var(--ice-hi); font-weight: 600; }
.results tr.base td { color: var(--text-dim); }
.results tr.best { background: linear-gradient(90deg, rgba(63, 180, 255, .12), transparent 80%); }
.bar-col { width: 34%; min-width: 200px; }
.barline { display: flex; align-items: center; gap: 12px; }
.bar {
  flex: 1; height: 10px; border-radius: 999px; position: relative; background: rgba(110, 180, 255, .08);
}
.bar::after {
  content: ""; position: absolute; inset: 0 auto 0 0; width: 0; border-radius: inherit;
  background: linear-gradient(90deg, var(--ice-deep), var(--ice-hi)); box-shadow: 0 0 12px rgba(63,180,255,.5);
}
.base .bar::after { background: linear-gradient(90deg, #4a5f7e, #7d93b2); box-shadow: none; }
dialog[open] .bar::after { animation: grow 1.1s cubic-bezier(.2,.8,.2,1) .25s forwards; }
dialog[open] tr:nth-child(2) .bar::after { animation-delay: .4s; }
dialog[open] tr:nth-child(3) .bar::after { animation-delay: .55s; }
dialog[open] tr:nth-child(4) .bar::after { animation-delay: .7s; }
@keyframes grow { to { width: var(--w); } }
.bar-col em { font-style: normal; font-family: var(--mono); font-size: 13px; width: 64px; text-align: right; color: var(--good); }
.base .bar-col em { color: var(--text-faint); }
dialog[open] .results tbody tr { animation: row .5s ease backwards; }
dialog[open] .results tbody tr:nth-child(2) { animation-delay: .1s; }
dialog[open] .results tbody tr:nth-child(3) { animation-delay: .2s; }
dialog[open] .results tbody tr:nth-child(4) { animation-delay: .3s; }
@keyframes row { from { opacity: 0; transform: translateX(-10px); } }
.footnote { margin: 16px 0 0; font-size: 12px; line-height: 1.6; color: var(--text-faint); }

/* ---------- Smaller screens ---------- */
@media (max-width: 980px) {
  .pitch { display: none; }
  .meta { top: 120px; font-size: 14px; }
  .gl-2, .gl-3, .d-2, .d-3 { display: none; }
}
@media (max-width: 720px), (max-height: 640px) {
  .frame { height: auto; min-height: calc(100vh - 20px); padding-bottom: 24px; }
  .topbar { position: relative; height: 76px; }
  .pill { height: 38px; padding: 0 16px; font-size: 12.5px; }
  .meta, .gl, .dot { display: none; }
  .hero { position: relative; left: auto; top: auto; transform: none; margin: 24px auto 0; }
  .logo-orbit { width: 104px; height: 104px; }
  .logo-orbit img { width: 68px; height: 68px; }
  .subtitle { letter-spacing: .2em; }
  .dl { width: 100%; min-width: 0; }
  .features { position: relative; height: auto; grid-template-columns: 1fr; gap: 10px; margin-top: 32px; }
  .hs-ui { left: auto; right: 6px; top: 96px; margin: 0; }
  .hs-results { left: 6px; top: auto; bottom: 12px; margin: 0; }
  .hs-label { display: none; }
  dialog.panel { padding: 20px 16px; }
  .panel-head { margin-right: 40px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; transition-delay: 0s !important; animation-delay: 0s !important; }
  .hotspot.in .hs-ring circle { stroke-dashoffset: 0; }
  .hotspot.in .hs-core { transform: scale(1); }
}
