/* ============================================================
   DeepSeek Price Clock — 3D visual language
   ============================================================ */

:root {
  /* surfaces */
  --bg: #06070c;
  --bg-2: #0a0c14;
  --glass: rgba(20, 24, 38, 0.58);
  --glass-2: rgba(30, 35, 54, 0.42);
  --line: rgba(255, 255, 255, 0.07);
  --line-strong: rgba(255, 255, 255, 0.13);

  /* type */
  --fg: #e8ebf5;
  --fg-soft: #b3bad0;
  --muted: #767f96;
  --muted-2: #525a70;

  /* accents */
  --accent: #818cf8;
  --accent-2: #6366f1;
  --violet: #a78bfa;
  --cyan: #22d3ee;
  --peak: #fbbf24;
  --peak-2: #fb923c;
  --off: #34d399;
  --off-2: #22d3ee;

  --red: #f87171;
  --yellow: #fbbf24;
  --orange: #fb923c;
  --green: #34d399;
  --blue: #60a5fa;
  --gray: #6b7280;

  --radius: 20px;
  --radius-lg: 26px;
  --radius-sm: 12px;

  /* layered elevation */
  --elev-1:
    0 1px 1px rgba(0, 0, 0, .3),
    0 3px 6px -1px rgba(0, 0, 0, .32),
    0 10px 20px -6px rgba(0, 0, 0, .38);
  --elev-2:
    0 1px 1px rgba(0, 0, 0, .3),
    0 4px 8px -2px rgba(0, 0, 0, .34),
    0 14px 28px -8px rgba(0, 0, 0, .42),
    0 36px 64px -24px rgba(0, 0, 0, .55);
  --elev-3:
    0 2px 2px rgba(0, 0, 0, .3),
    0 8px 16px -4px rgba(0, 0, 0, .38),
    0 24px 48px -12px rgba(0, 0, 0, .5),
    0 56px 96px -32px rgba(0, 0, 0, .6);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, 'Noto Sans Bengali', sans-serif;
  font-size: 15px;
  line-height: 1.55;
  color: var(--fg);
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 55%, #070910 100%);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.mono {
  font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}

/* ============================================================
   3D scene backdrop
   ============================================================ */

.scene {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

/* perspective floor grid */
.scene-grid {
  position: absolute;
  left: -60vw; right: -60vw;
  bottom: -14vh;
  height: 72vh;
  background-image:
    linear-gradient(rgba(129, 140, 248, .20) 1px, transparent 1px),
    linear-gradient(90deg, rgba(129, 140, 248, .20) 1px, transparent 1px);
  background-size: 62px 62px;
  transform:
    translate3d(calc(var(--px, 0px) * 0.22), calc(var(--py, 0px) * 0.22), 0)
    perspective(520px) rotateX(76deg);
  transform-origin: bottom center;
  -webkit-mask-image: radial-gradient(58% 68% at 50% 100%, #000 0%, transparent 76%);
  mask-image: radial-gradient(58% 68% at 50% 100%, #000 0%, transparent 76%);
  opacity: .55;
  animation: gridDrift 14s linear infinite;
}
@keyframes gridDrift {
  from { background-position: 0 0, 0 0; }
  to   { background-position: 0 62px, 0 0; }
}

/* floating light orbs, each at its own depth */
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  will-change: transform, opacity;
}
.orb-a {
  width: 46vw; height: 46vw; max-width: 620px; max-height: 620px;
  top: -14%; left: -6%;
  background: radial-gradient(circle, rgba(99, 102, 241, .50), transparent 68%);
  animation: floatA 24s ease-in-out infinite alternate;
}
.orb-b {
  width: 38vw; height: 38vw; max-width: 520px; max-height: 520px;
  top: 2%; right: -10%;
  background: radial-gradient(circle, rgba(34, 211, 238, .30), transparent 68%);
  animation: floatB 30s ease-in-out infinite alternate;
}
.orb-c {
  width: 42vw; height: 42vw; max-width: 560px; max-height: 560px;
  bottom: -18%; left: 34%;
  background: radial-gradient(circle, rgba(167, 139, 250, .34), transparent 68%);
  animation: floatC 27s ease-in-out infinite alternate;
}
/* each orb drifts on its own, and rides the pointer at its own depth */
@keyframes floatA {
  from { transform: translate3d(calc(var(--px, 0px) * 1.00), calc(var(--py, 0px) * 1.00), 0) scale(1); opacity: .55; }
  to   { transform: translate3d(calc(var(--px, 0px) * 1.00 + 7%), calc(var(--py, 0px) * 1.00 + 5%), 0) scale(1.14); opacity: .8; }
}
@keyframes floatB {
  from { transform: translate3d(calc(var(--px, 0px) * 0.62), calc(var(--py, 0px) * 0.62), 0) scale(1.06); opacity: .7; }
  to   { transform: translate3d(calc(var(--px, 0px) * 0.62 - 6%), calc(var(--py, 0px) * 0.62 + 8%), 0) scale(.94); opacity: .45; }
}
@keyframes floatC {
  from { transform: translate3d(calc(var(--px, 0px) * 0.38), calc(var(--py, 0px) * 0.38), 0) scale(.96); opacity: .5; }
  to   { transform: translate3d(calc(var(--px, 0px) * 0.38 + 5%), calc(var(--py, 0px) * 0.38 - 6%), 0) scale(1.1); opacity: .75; }
}

.scene-vignette {
  position: absolute; inset: 0;
  background:
    radial-gradient(120% 85% at 50% -10%, transparent 42%, rgba(0, 0, 0, .5) 100%),
    linear-gradient(180deg, rgba(0,0,0,.3) 0%, transparent 22%);
}

/* film grain for texture */
.scene::after {
  content: '';
  position: absolute; inset: 0;
  opacity: .028;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* ============================================================
   Header
   ============================================================ */

.top {
  position: sticky; top: 0; z-index: 40;
  padding: 10px clamp(10px, 2.4vw, 20px) 14px;
  background: linear-gradient(180deg,
    rgba(6, 7, 12, .94) 0%,
    rgba(6, 7, 12, .72) 62%,
    rgba(6, 7, 12, 0) 100%);
}

/* a floating island rather than a full-bleed bar */
.top-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: flex; align-items: center; gap: 14px;
  padding: 9px 11px 9px 13px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .062), rgba(255, 255, 255, .018)), var(--glass);
  border: 1px solid var(--line-strong);
  backdrop-filter: saturate(165%) blur(18px);
  -webkit-backdrop-filter: saturate(165%) blur(18px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .09),
    0 10px 26px -16px rgba(0, 0, 0, .9),
    0 34px 64px -34px rgba(0, 0, 0, .95);
}
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }

/* live period chip — mirrors the hero so it stays readable when scrolled */
.live-chip {
  display: inline-flex; align-items: center; gap: 9px;
  margin-left: auto; flex: none;
  padding: 6px 13px 7px;
  border-radius: 999px;
  text-decoration: none;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .03);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05);
  transition: border-color .2s ease, background .2s ease, transform .2s ease;
}
.live-chip:hover { border-color: var(--line-strong); background: rgba(255, 255, 255, .06); transform: translateY(-1px); }
.live-chip:active { transform: translateY(0); }

.live-dot {
  width: 8px; height: 8px; border-radius: 50%; flex: none;
  background: var(--gray);
  transition: background .4s ease;
}
.live-chip.is-peak .live-dot { background: var(--peak); color: rgba(251, 191, 36, .45); animation: pulse 1.8s ease-out infinite; }
.live-chip.is-off  .live-dot { background: var(--off);  color: rgba(52, 211, 153, .45); animation: pulse 2.4s ease-out infinite; }

.live-meta { display: flex; flex-direction: column; line-height: 1.15; }
.live-period {
  font-size: 10px; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--muted);
  transition: color .4s ease;
}
.live-chip.is-peak .live-period { color: #fcd34d; }
.live-chip.is-off  .live-period { color: #6ee7b7; }
.live-sub { font-size: 12.5px; color: var(--fg); }

.top-actions { display: flex; align-items: center; gap: 10px; flex: none; }

.logo {
  width: 40px; height: 40px; flex: none;
  display: grid; place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(150deg, #6366f1 0%, #8b5cf6 55%, #a78bfa 100%);
  transform-style: preserve-3d;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .3),
    inset 0 -2px 6px rgba(0, 0, 0, .3),
    0 6px 16px -4px rgba(99, 102, 241, .6),
    0 14px 30px -10px rgba(99, 102, 241, .45);
  transition: transform .5s cubic-bezier(.22,1,.36,1);
}
.logo:hover { transform: rotateY(-18deg) rotateX(8deg); }
.logo-face { display: grid; place-items: center; transform: translateZ(8px); }

.brand-text { min-width: 0; }
h1 {
  margin: 0;
  font-size: clamp(15px, 2.4vw, 17px);
  font-weight: 700;
  letter-spacing: -0.015em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.sub {
  margin: 1px 0 0;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}



.auto {
  display: flex; align-items: center; gap: 7px;
  color: var(--fg-soft);
  font-size: 12.5px; cursor: pointer; user-select: none;
  padding: 7px 11px; border-radius: 10px;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
  transition: border-color .2s ease, background .2s ease;
}
.auto:hover { border-color: var(--line-strong); }
.auto input { accent-color: var(--accent-2); width: 14px; height: 14px; }

.btn {
  display: inline-flex; align-items: center; gap: 7px;
  color: #fff; border: 0; border-radius: 11px;
  padding: 9px 15px;
  font: inherit; font-size: 13px; font-weight: 600; letter-spacing: .01em;
  cursor: pointer; min-height: 38px;
  background: linear-gradient(180deg, #6d70f5 0%, #4f46e5 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .25),
    inset 0 -2px 4px rgba(0, 0, 0, .25),
    0 6px 16px -5px rgba(99, 102, 241, .7),
    0 12px 28px -12px rgba(99, 102, 241, .6);
  transition: transform .16s cubic-bezier(.22,1,.36,1), box-shadow .2s ease, filter .2s ease;
}
.btn:hover {
  filter: brightness(1.09);
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .3),
    inset 0 -2px 4px rgba(0, 0, 0, .25),
    0 10px 22px -6px rgba(99, 102, 241, .8),
    0 20px 40px -16px rgba(99, 102, 241, .65);
}
.btn:active { transform: translateY(1px) scale(.99); }
.btn svg { transition: transform .5s cubic-bezier(.22,1,.36,1); }
.btn:hover svg { transform: rotate(-70deg); }

/* ============================================================
   Layout
   ============================================================ */

main {
  position: relative; z-index: 2;
  width: 100%; max-width: 1180px; margin: 0 auto;
  padding: clamp(20px, 3vw, 34px) clamp(14px, 2.6vw, 22px) 72px;
  display: grid; gap: clamp(16px, 2.2vw, 24px);
  perspective: 1800px;
}

/* ---------- shared 3D tilt behaviour ---------- */

[data-tilt] {
  transform:
    perspective(1400px)
    rotateX(var(--rx, 0deg))
    rotateY(var(--ry, 0deg));
  transform-style: preserve-3d;
  will-change: transform;
}

/* ---------- glass card ---------- */

.card {
  position: relative;
  border-radius: var(--radius);
  padding: clamp(17px, 2.3vw, 24px);
  min-width: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .012)), var(--glass);
  backdrop-filter: saturate(150%) blur(16px);
  -webkit-backdrop-filter: saturate(150%) blur(16px);
  box-shadow: var(--elev-2), inset 0 1px 0 rgba(255,255,255,.06);
  transition: box-shadow .35s ease, transform .35s cubic-bezier(.22,1,.36,1);
}
/* beveled edge — light catching the top.
   Gated: without mask-composite support this would wash the whole card. */
@supports ((-webkit-mask-composite: xor) or (mask-composite: exclude)) {
  .card::before,
  .hero-clip::after {
    content: '';
    position: absolute; inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(180deg,
      rgba(255, 255, 255, .20) 0%,
      rgba(255, 255, 255, .05) 34%,
      rgba(255, 255, 255, 0) 68%);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask-composite: exclude;
    pointer-events: none;
    z-index: 3;
  }
}
.card:hover { box-shadow: var(--elev-3), inset 0 1px 0 rgba(255,255,255,.08); }

/* sheen that follows the cursor on card surfaces */
.card-sheen {
  position: absolute; inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: var(--spec, 0);
  transition: opacity .4s ease;
  background: radial-gradient(520px circle at var(--mx, 50%) var(--my, 50%),
    rgba(255, 255, 255, .07), transparent 42%);
  z-index: 1;
}

.card-head {
  position: relative; z-index: 2;
  display: flex; align-items: flex-start; justify-content: space-between; gap: 14px;
  margin-bottom: 16px; flex-wrap: wrap;
}
.card-head h3 {
  margin: 0;
  font-size: 12px; font-weight: 600;
  letter-spacing: .09em; text-transform: uppercase;
  color: var(--fg-soft);
}
.card-head p { margin: 4px 0 0; }

.src {
  font-size: 11.5px; color: var(--muted); text-decoration: none;
  padding: 5px 10px; border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.02);
  transition: color .2s ease, border-color .2s ease, background .2s ease;
  white-space: nowrap;
}
.src:hover { color: var(--accent); border-color: var(--line-strong); background: rgba(99,102,241,.08); }

.grid { display: grid; grid-template-columns: 1fr 1fr; gap: inherit; }
.grid > .span-2 { grid-column: 1 / -1; }

/* ============================================================
   Hero — the 3D centrepiece
   ============================================================ */

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(0, 1fr);
  gap: clamp(20px, 3vw, 34px);
  align-items: stretch;
  border-radius: var(--radius-lg);
  padding: clamp(22px, 3.2vw, 36px);
  isolation: isolate;
}

/* the clipping layer carries the glass so .hero stays 3D-capable */
.hero-clip {
  position: absolute; inset: 0;
  border-radius: inherit;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .012)), var(--glass);
  backdrop-filter: saturate(150%) blur(18px);
  -webkit-backdrop-filter: saturate(150%) blur(18px);
  box-shadow: var(--elev-3), inset 0 1px 0 rgba(255,255,255,.07);
  pointer-events: none;
  transition: box-shadow .5s ease;
}

/* animated colour field behind the glass */
.hero-glow {
  position: absolute; inset: -45%;
  filter: blur(70px);
  opacity: .7;
  background:
    radial-gradient(closest-side at 22% 28%, rgba(52, 211, 153, .30) 0%, transparent 70%),
    radial-gradient(closest-side at 78% 72%, rgba(99, 102, 241, .28) 0%, transparent 70%);
  transition: background .9s ease, opacity .7s ease;
  animation: heroFloat 20s ease-in-out infinite alternate;
}
.hero.is-peak .hero-glow {
  background:
    radial-gradient(closest-side at 22% 28%, rgba(251, 191, 36, .32) 0%, transparent 70%),
    radial-gradient(closest-side at 78% 72%, rgba(251, 113, 36, .26) 0%, transparent 70%);
  opacity: .68;
}
.hero.is-off .hero-glow {
  background:
    radial-gradient(closest-side at 22% 28%, rgba(52, 211, 153, .34) 0%, transparent 70%),
    radial-gradient(closest-side at 78% 72%, rgba(34, 211, 238, .26) 0%, transparent 70%);
  opacity: .8;
}
@keyframes heroFloat {
  from { transform: translate3d(-3%, -2%, 0) scale(1); }
  to   { transform: translate3d(3%, 2%, 0) scale(1.08); }
}

/* specular highlight tracking the cursor */
.hero-spec {
  position: absolute; inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: var(--spec, 0);
  transition: opacity .45s ease;
  background: radial-gradient(620px circle at var(--mx, 50%) var(--my, 50%),
    rgba(255, 255, 255, .09), transparent 44%);
  mix-blend-mode: screen;
  z-index: 2;
}

.hero.is-peak .hero-clip { box-shadow: var(--elev-3), inset 0 1px 0 rgba(251,191,36,.14); }
.hero.is-off  .hero-clip { box-shadow: var(--elev-3), inset 0 1px 0 rgba(52,211,153,.14); }

.hero-main {
  position: relative; z-index: 3;
  display: flex; flex-direction: column; min-width: 0;
  transform: translateZ(34px);
}
.hero-now {
  position: relative; z-index: 4;
  transform: translateZ(56px);
}

.hero-status { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

.pulse {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--gray); flex: none;
  box-shadow: 0 0 0 0 currentColor;
}
.hero.is-peak .pulse { background: var(--peak); color: rgba(251, 191, 36, .5); animation: pulse 1.8s ease-out infinite; }
.hero.is-off  .pulse { background: var(--off);  color: rgba(52, 211, 153, .5); animation: pulse 2.4s ease-out infinite; }
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 currentColor; }
  70%  { box-shadow: 0 0 0 13px rgba(0,0,0,0); }
  100% { box-shadow: 0 0 0 0 rgba(0,0,0,0); }
}

.hero-label {
  font-size: clamp(26px, 5.4vw, 40px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  background: linear-gradient(92deg, #ffe4a8 0%, #fbbf24 46%, #fb923c 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 3px 10px rgba(251, 191, 36, .28));
  transition: filter .6s ease;
}
.hero.is-off .hero-label {
  background: linear-gradient(92deg, #a7f3d0 0%, #34d399 44%, #22d3ee 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 3px 10px rgba(52, 211, 153, .28));
}

.hero-line {
  margin: 11px 0 0;
  color: var(--fg-soft);
  font-size: clamp(13.5px, 1.8vw, 15px);
  max-width: 54ch;
}

.badge {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line-strong);
  background: rgba(255,255,255,.04);
  color: var(--fg-soft);
  border-radius: 999px;
  padding: 4px 11px;
  font-size: 11px; font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.07);
}
.badge.peak    { color: #fcd34d; border-color: rgba(251,191,36,.4); background: rgba(251,191,36,.11); box-shadow: inset 0 1px 0 rgba(251,191,36,.18), 0 0 22px -6px rgba(251,191,36,.5); }
.badge.offpeak { color: #6ee7b7; border-color: rgba(52,211,153,.4); background: rgba(52,211,153,.11); box-shadow: inset 0 1px 0 rgba(52,211,153,.18), 0 0 22px -6px rgba(52,211,153,.5); }

/* countdown */
.clock {
  display: flex; align-items: baseline; gap: 12px;
  margin-top: 20px; flex-wrap: wrap;
  padding: 20px 0 4px;
  border-top: 1px solid var(--line);
}
.clock-num {
  font-size: clamp(36px, 8vw, 56px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.035em;
  color: #fff;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, .18),
    0 2px 1px rgba(0, 0, 0, .45),
    0 10px 26px rgba(0, 0, 0, .6);
}
.clock-cap { color: var(--muted); font-size: 13px; }

.savings {
  display: inline-flex; align-items: baseline; flex-wrap: wrap; gap: 8px;
  margin-top: 16px;
  padding: 11px 15px;
  border-radius: 13px;
  background: linear-gradient(135deg, rgba(52, 211, 153, .13), rgba(99, 102, 241, .09));
  border: 1px solid rgba(52, 211, 153, .28);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .08),
    0 8px 22px -12px rgba(52, 211, 153, .8);
}
.savings-label { color: #6ee7b7; font-size: 11.5px; text-transform: uppercase; letter-spacing: .09em; font-weight: 700; }
.savings-value { color: #d1fae5; font-size: 16px; font-weight: 600; }
.savings-cap { color: var(--muted); font-size: 12px; }

.hero-facts {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px; margin: auto 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.hero-facts div { min-width: 0; }
.hero-facts dt {
  color: var(--muted);
  font-size: 10.5px; text-transform: uppercase; letter-spacing: .09em;
  margin-bottom: 5px; font-weight: 600;
}
.hero-facts dd { margin: 0; font-size: 13px; color: var(--fg-soft); overflow-wrap: anywhere; }

/* price-now panel */
.hero-now {
  display: flex; flex-direction: column;
  border-radius: 16px;
  padding: 17px;
  min-width: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .012)), var(--glass-2);
  border: 1px solid var(--line);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .08),
    0 14px 34px -18px rgba(0, 0, 0, .9);
}
.now-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  margin-bottom: 13px; flex-wrap: wrap;
}
.now-eyebrow { color: var(--fg-soft); font-size: 12.5px; font-weight: 600; }
.now-period {
  color: var(--accent);
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: .09em;
}
.now-list { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.now-row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 11px 13px;
  border-radius: 11px;
  background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.015));
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
  min-width: 0;
  transition: border-color .2s ease, transform .2s ease;
}
.now-row:hover { border-color: var(--line-strong); }
.now-row .k { color: var(--fg-soft); font-size: 12.5px; min-width: 0; }
.now-row .v { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.15; flex: none; }
.now-row .v .bdt {
  color: #6ee7b7; font-weight: 700; font-size: 14px;
  text-shadow: 0 1px 0 rgba(0,0,0,.5), 0 0 18px rgba(52,211,153,.25);
}
.now-row .v .usd { color: var(--muted); font-size: 11.5px; }
.now-row.skeleton { height: 46px; }

.now-foot { margin-top: 11px; padding-top: 11px; border-top: 1px solid var(--line); }

/* ============================================================
   Day dial — today's price windows as a 24-hour clock face
   ============================================================ */

/* ---------- summary tiles ---------- */

.dial-detail { min-width: 0; }

.tl-stats {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.tl-stat {
  min-width: 0;
  border-radius: 13px;
  padding: 12px 14px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, .012));
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06);
  transition: border-color .45s ease, background .45s ease;
}
.tl-stat-k {
  display: block; margin-bottom: 5px;
  font-size: 10px; font-weight: 700;
  letter-spacing: .09em; text-transform: uppercase;
  color: var(--muted);
}
.tl-stat-v {
  display: block;
  font-size: clamp(17px, 2.6vw, 20px); font-weight: 700;
  letter-spacing: -.02em; line-height: 1.15;
  color: var(--fg);
  transition: color .45s ease;
}
.tl-stat-s { display: block; margin-top: 3px; font-size: 11.5px; color: var(--muted); }

/* the "right now" tile takes the live period colour (dial palette: yellow / green) */
.tl-stat.is-peak {
  border-color: rgba(250, 204, 21, .35);
  background: linear-gradient(180deg, rgba(250, 204, 21, .10), rgba(250, 204, 21, .015));
}
.tl-stat.is-peak .tl-stat-v { color: #fde047; }
.tl-stat.is-off {
  border-color: rgba(34, 197, 94, .35);
  background: linear-gradient(180deg, rgba(34, 197, 94, .10), rgba(34, 197, 94, .015));
}
.tl-stat.is-off .tl-stat-v { color: #86efac; }

/* ---------- the dial ---------- */

/* a coloured halo behind the whole card, reactive to the live period
   dial palette: off → green, peak → yellow */
.dial-halo {
  position: absolute; inset: -30%;
  z-index: 0;
  pointer-events: none;
  filter: blur(70px);
  opacity: .55;
  background: radial-gradient(closest-side at 50% 45%, rgba(34, 197, 94, .34) 0%, transparent 68%);
  transition: background .8s ease, opacity .6s ease;
}
.dial-card { position: relative; overflow: hidden; }
.dial-card.is-peak .dial-halo {
  background: radial-gradient(closest-side at 50% 45%, rgba(250, 204, 21, .34) 0%, transparent 68%);
}
.dial-card > *:not(.dial-halo) { position: relative; z-index: 2; }

.dial-body {
  display: grid;
  grid-template-columns: minmax(210px, 264px) minmax(0, 1fr);
  gap: clamp(18px, 3vw, 34px);
  align-items: center;
}

.dial-col { display: flex; justify-content: center; }

.dial {
  position: relative;
  width: 100%;
  max-width: 264px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
}

.dial-svg { width: 100%; height: 100%; overflow: visible; }

.dial-track {
  fill: none;
  stroke: url(#gTrack);
  stroke-width: 17;
}

/* arcs */
.arc { transition: opacity .5s ease; }
.arc-off { opacity: .48; }
.arc-weekend { opacity: .8; }

/* ticks */
.tick { stroke: rgba(255, 255, 255, .16); stroke-width: 1; }
.tick-major { stroke: rgba(255, 255, 255, .34); stroke-width: 1.4; }
.tick-label {
  fill: var(--muted-2);
  font-size: 8.5px;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-weight: 500;
}

/* the "now" hand */
.dial-hand {
  transform-box: view-box;
  transform-origin: 120px 120px;
  transition: transform 1.2s cubic-bezier(.22,1,.36,1);
}
.hand-line {
  stroke: #fff;
  stroke-width: 2;
  stroke-linecap: round;
  filter: drop-shadow(0 0 5px rgba(255, 255, 255, .85));
}
.hand-hub {
  fill: #fff;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, .7));
}
.hand-tip {
  fill: #fff;
  stroke: rgba(255, 255, 255, .35);
  stroke-width: 5;
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, .9));
}

/* centre readout */
.dial-center {
  position: absolute;
  inset: 26%;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 3px;
  text-align: center;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(10, 13, 22, .82), rgba(10, 13, 22, .28) 78%, transparent);
  pointer-events: none;
}
.dial-period {
  font-size: 11px; font-weight: 800;
  letter-spacing: .13em; text-transform: uppercase;
  color: var(--muted);
  transition: color .45s ease;
}
.dial-clock {
  font-size: clamp(21px, 3.4vw, 27px);
  font-weight: 600;
  letter-spacing: -.03em;
  line-height: 1.05;
  color: #fff;
  text-shadow: 0 1px 0 rgba(255, 255, 255, .16), 0 8px 22px rgba(0, 0, 0, .7);
}
.dial-cap { font-size: 10.5px; color: var(--muted); max-width: 128px; line-height: 1.35; }

.dial-card.is-peak .dial-period { color: #fde047; }
.dial-card.is-off  .dial-period { color: #86efac; }

/* ---------- peak window list ---------- */

.tl-windows-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  margin: 18px 0 10px;
  font-size: 10.5px; font-weight: 700;
  letter-spacing: .09em; text-transform: uppercase;
  color: var(--muted);
}

.tl-windows {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}
.tl-window {
  display: flex; align-items: center; gap: 12px;
  min-width: 0;
  padding: 11px 14px;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, .01));
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05);
  transition: border-color .3s ease, background .3s ease, opacity .3s ease;
}
.w-dot {
  width: 8px; height: 8px; border-radius: 50%; flex: none;
  background: var(--peak);
  transition: background .3s ease, box-shadow .3s ease;
}
.w-range {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 13.5px; font-weight: 600;
  color: var(--fg);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.w-dur { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.w-state {
  margin-left: auto; flex: none;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 10px; font-weight: 700;
  letter-spacing: .07em; text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}

/* passed windows recede */
.tl-window.is-passed { opacity: .5; }
.tl-window.is-passed .w-dot { background: var(--muted-2); }
.tl-window.is-passed .w-state { color: var(--muted-2); }

/* the window you are inside right now (dial palette: yellow) */
.tl-window.is-active {
  border-color: rgba(250, 204, 21, .42);
  background: linear-gradient(180deg, rgba(250, 204, 21, .10), rgba(250, 204, 21, .015));
}
.tl-window.is-active .w-dot { background: #facc15; box-shadow: 0 0 10px rgba(250, 204, 21, .95); }
.tl-window.is-active .w-state {
  color: #fde047;
  border-color: rgba(250, 204, 21, .45);
  background: rgba(250, 204, 21, .12);
}

/* still to come */
.tl-window.is-upcoming .w-state { color: var(--fg-soft); }

/* weekend / no peak windows */
.tl-window.is-none {
  grid-column: 1 / -1;
  border-color: rgba(56, 189, 248, .35);
  background: linear-gradient(180deg, rgba(56, 189, 248, .09), rgba(56, 189, 248, .015));
}
.tl-window.is-none .w-dot { background: #38bdf8; box-shadow: 0 0 10px rgba(56, 189, 248, .9); }
.tl-window.is-none .w-state { color: #7dd3fc; border-color: rgba(56, 189, 248, .42); background: rgba(56, 189, 248, .12); }

.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 11.5px; }
.sw { width: 12px; height: 12px; border-radius: 4px; display: inline-block; box-shadow: inset 0 1px 0 rgba(255,255,255,.25); }
.sw-peak { background: linear-gradient(135deg, rgba(250,204,21,.95), rgba(253,224,71,.85)); }
.sw-off  { background: linear-gradient(135deg, rgba(34,197,94,.95), rgba(134,239,172,.85)); }
.sw-weekend { background: repeating-linear-gradient(135deg, rgba(56,189,248,.75) 0 3px, rgba(56,189,248,.3) 3px 6px); }

/* ============================================================
   Model cards — floating 3D panels
   ============================================================ */

.models {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 14px;
}
.model {
  position: relative;
  border-radius: 16px;
  padding: 17px;
  min-width: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .01)), var(--glass-2);
  border: 1px solid var(--line);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .07),
    0 10px 26px -16px rgba(0, 0, 0, .9);
  transition: box-shadow .35s ease, border-color .25s ease;
}
.model:hover {
  border-color: var(--line-strong);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .1),
    0 24px 56px -22px rgba(0, 0, 0, 1),
    0 0 40px -18px rgba(99, 102, 241, .5);
}
.model-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 8px;
  flex-wrap: wrap; margin-bottom: 9px;
  transform: translateZ(18px);
}
.model-name { font-size: 16px; font-weight: 700; letter-spacing: -0.015em; color: #fff; }
.model-ver { color: var(--muted); font-size: 11px; font-family: 'JetBrains Mono', monospace; }
.model-tags { display: flex; flex-wrap: wrap; gap: 5px; margin: 0 0 15px; transform: translateZ(12px); }
.tag-chip {
  font-size: 10.5px; color: var(--fg-soft);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .025);
  border-radius: 999px;
  padding: 3px 9px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
}
.model-table { width: 100%; border-collapse: collapse; transform: translateZ(22px); }
.model-table th, .model-table td {
  padding: 9px 6px;
  border-bottom: 1px solid var(--line);
  text-align: right; font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.model-table th:first-child, .model-table td:first-child { text-align: left; }
.model-table thead th {
  color: var(--muted);
  font-size: 10px; text-transform: uppercase; letter-spacing: .09em; font-weight: 600;
}
.model-table tbody tr:last-child td { border-bottom: 0; }
.model-table .cell-group { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; }
.model-table .cell-usd { color: var(--fg-soft); font-size: 12.5px; }
.model-table .cell-bdt { color: #6ee7b7; font-weight: 700; font-size: 13px; }
.model-table .label-with-sub { display: flex; flex-direction: column; gap: 1px; }
.model-table .label-with-sub .label-sub { color: var(--muted-2); font-size: 10.5px; }

.model-skel { height: 190px; border-radius: 16px; }

.note { position: relative; z-index: 2; margin: 17px 0 0; line-height: 1.7; }

/* ============================================================
   Status / incidents
   ============================================================ */

.status-top { position: relative; z-index: 2; display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.status-top strong { font-size: 15.5px; font-weight: 700; letter-spacing: -0.015em; }

.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.dot-lg { width: 12px; height: 12px; box-shadow: 0 0 0 3px rgba(255,255,255,.05), 0 0 14px -2px currentColor; }
.dot.operational    { background: var(--green); color: var(--green); }
.dot.degraded       { background: var(--yellow); color: var(--yellow); }
.dot.partial_outage { background: var(--orange); color: var(--orange); }
.dot.full_outage    { background: var(--red); color: var(--red); }
.dot.maintenance    { background: var(--blue); color: var(--blue); }
.dot.unknown        { background: var(--gray); color: var(--gray); }

.components { position: relative; z-index: 2; list-style: none; margin: 13px 0 0; padding: 0; }
.components li {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 4px;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
}
.components li:last-child { border-bottom: 0; }
.components .name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.components .state { color: var(--muted); font-size: 11.5px; white-space: nowrap; }

.incidents { position: relative; z-index: 2; list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.incidents li {
  border-radius: 12px; padding: 13px 15px;
  background: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.01));
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
  transition: border-color .2s ease, box-shadow .25s ease;
}
.incidents li:hover {
  border-color: var(--line-strong);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08), 0 12px 28px -18px rgba(0,0,0,.9);
}
.incidents a { color: var(--fg); text-decoration: none; font-weight: 600; font-size: 13.5px; }
.incidents a:hover { color: var(--accent); }
.incidents .meta { color: var(--muted); font-size: 11.5px; margin-top: 4px; }
.incidents .body { color: var(--fg-soft); font-size: 12.5px; margin-top: 6px; overflow-wrap: anywhere; }
.tag { font-size: 10.5px; padding: 2px 9px; border-radius: 999px; border: 1px solid var(--line); margin-left: 8px; white-space: nowrap; text-transform: capitalize; }
.tag.resolved { color: #6ee7b7; border-color: rgba(52,211,153,.32); background: rgba(52,211,153,.09); }
.tag.investigating, .tag.identified { color: #fcd34d; border-color: rgba(251,191,36,.32); background: rgba(251,191,36,.09); }
.tag.monitoring { color: #93c5fd; border-color: rgba(96,165,250,.32); background: rgba(96,165,250,.09); }

/* ============================================================
   Misc
   ============================================================ */

.muted { color: var(--muted); }
.small { font-size: 12px; }
.foot { position: relative; z-index: 2; padding: 4px 2px 0; line-height: 1.7; }

.skeleton {
  background: linear-gradient(90deg,
    rgba(255,255,255,.03) 0%,
    rgba(255,255,255,.08) 50%,
    rgba(255,255,255,.03) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 10px;
}
@keyframes shimmer { to { background-position: -200% 0; } }

/* ============================================================
   Responsive
   ============================================================ */

@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; }
  .grid { grid-template-columns: 1fr; }
  .grid > .span-2 { grid-column: auto; }
  .hero-main { transform: translateZ(20px); }
  .hero-now  { transform: translateZ(30px); }
  .model-head, .model-tags, .model-table { transform: none; }

  /* dial stacks: the clock face moves to the top, the details below */
  .dial-body { grid-template-columns: 1fr; gap: 22px; align-items: stretch; }
  .dial-col { order: -1; }
  .dial { max-width: 240px; margin: 0 auto; }
}

@media (max-width: 640px) {
  .sub { display: none; }
  .auto-label { display: none; }
  .btn span { display: none; }
  .btn { padding: 9px 11px; }
  .hero-facts { grid-template-columns: 1fr 1fr; }
  .card-head h3 { font-size: 11.5px; }
  .model-table th, .model-table td { padding: 7px 4px; font-size: 12.5px; }
  .model-table thead th { font-size: 9.5px; }

  /* dial: shrink and re-centre; centre copy adapts via clamp() */
  .dial { max-width: 220px; }
  .dial-clock { font-size: 21px; }
  .dial-cap { font-size: 10px; max-width: 110px; }

  /* 3-tile row folds to two; "Right now" keeps the full width on its own row */
  .tl-stats { grid-template-columns: 1fr 1fr; gap: 8px; }
  .tl-stat { padding: 10px 12px; }
  .tl-stat:first-child { grid-column: 1 / -1; }
  .tl-windows { grid-template-columns: 1fr; }
  .tl-window { padding: 10px 12px; gap: 10px; }
  .w-dur { display: none; }      /* hide duration on small screens to free the row */

  /* legend wraps to a second line if needed */
  .legend { gap: 6px 12px; font-size: 11px; }

  /* header stays useful but compact */
  .live-sub { display: none; }
  .live-chip { padding: 6px 11px; gap: 7px; }
  .live-period { font-size: 9.5px; }

  .card { box-shadow: var(--elev-1), inset 0 1px 0 rgba(255,255,255,.06); }
  .hero-clip { box-shadow: var(--elev-2), inset 0 1px 0 rgba(255,255,255,.07); }
}

@media (max-width: 420px) {
  .hero-facts { grid-template-columns: 1fr; }
  .brand .logo { width: 34px; height: 34px; }
  .top { padding: 8px 10px 12px; }
  .top-inner { padding: 8px 9px 8px 10px; gap: 9px; border-radius: 15px; }
  .brand { gap: 9px; }
  .live-chip { padding: 5px 9px; }
  .now-row { padding: 9px 11px; }
  .clock-num { font-size: 32px; }

  /* dial: tiniest viewports get the smallest clock face */
  .dial { max-width: 200px; }
  .dial-clock { font-size: 19px; }
  .dial-cap { max-width: 96px; }

  /* window list rows: state pill goes to a second line so the range always reads */
  .tl-window { flex-wrap: wrap; }
  .w-state { margin-left: 0; }
  .tl-stats { grid-template-columns: 1fr; }
  .tl-stat:first-child { grid-column: auto; }
}

/* calm everything down when the user asks for less motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
  [data-tilt] { transform: none !important; }
  .btn:hover svg { transform: none; }
  .logo:hover { transform: none; }
}

/* Touch input is filtered in JS by pointerType, so no media-query gate here —
   a desktop that misreports `hover: none` would otherwise lose the effect. */