:root {
  --bg: #f0f0f2;
  --bg-deep: #d7d7db;
  --panel: rgba(255, 255, 255, 0.8);
  --panel-strong: rgba(255, 255, 255, 0.92);
  --panel-border: rgba(255, 255, 255, 0.92);
  --text: #111111;
  --muted: #595961;
  --soft: #8a8a91;
  --accent: #ef2b2d;
  --accent-dark: #b20f13;
  --shadow: 0 24px 80px rgba(55, 55, 65, 0.14);
  --radius-xl: 42px;
  --radius-lg: 30px;
  --radius-md: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.85), transparent 28%),
    radial-gradient(circle at bottom right, rgba(255, 255, 255, 0.75), transparent 24%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-deep) 100%);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  transition: background 0.25s ease, color 0.25s ease;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 255, 255, 0.5), transparent 15%),
    radial-gradient(circle at 82% 28%, rgba(255, 255, 255, 0.5), transparent 18%),
    radial-gradient(circle at 70% 72%, rgba(255, 255, 255, 0.4), transparent 16%);
  filter: blur(8px);
  opacity: 0.95;
  transition: opacity 0.25s ease;
}

body.dark-mode {
  --bg: #18181a;
  --bg-deep: #0f1012;
  --panel: rgba(31, 31, 35, 0.72);
  --panel-strong: rgba(39, 39, 44, 0.88);
  --panel-border: rgba(255, 255, 255, 0.07);
  --text: #f3f3f5;
  --muted: #bebec6;
  --soft: #91919b;
  --shadow: 0 28px 90px rgba(0, 0, 0, 0.38);
}

body.dark-mode::before {
  opacity: 0.35;
}

.ambient {
  position: fixed;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.46);
  filter: blur(22px);
  pointer-events: none;
  transition: background 0.25s ease;
}

body.dark-mode .ambient {
  background: rgba(255, 255, 255, 0.08);
}

.ambient-left {
  top: -140px;
  left: -120px;
}

.ambient-right {
  right: -140px;
  bottom: 120px;
}

.page-shell {
  width: min(1280px, calc(100% - 36px));
  margin: 0 auto;
  padding: 28px 0 64px;
  position: relative;
  z-index: 1;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 20px 24px;
  border-radius: 999px;
  margin-bottom: 28px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 34%, #111 0 8px, transparent 9px),
    linear-gradient(135deg, #0e0e10, #444);
  box-shadow: inset 0 0 0 10px rgba(255, 255, 255, 0.94);
  transition: background 0.25s ease, box-shadow 0.25s ease;
}

body.dark-mode .brand-mark {
  background:
    radial-gradient(circle at 34% 34%, #f2f2f2 0 8px, transparent 9px),
    linear-gradient(135deg, #f0f0f0, #7d7d88);
  box-shadow: inset 0 0 0 10px rgba(22, 22, 24, 0.92);
}

.brand-name,
.brand-sub,
.eyebrow,
.service-code,
.service-chip,
.step-number,
.widget-label,
.circle-label,
.matrix-head,
.nav a,
.nav-cta,
.dock-item,
.mode-button {
  font-family: "Space Mono", monospace;
}

.brand-name {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.brand-sub {
  display: block;
  margin-top: 2px;
  color: var(--soft);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.topbar-controls {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  justify-content: flex-end;
  flex: 1;
}

.mode-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(0, 0, 0, 0.06);
  user-select: none;
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

body.dark-mode .mode-switch,
body.dark-mode .nav-cta,
body.dark-mode .dock-item,
body.dark-mode .service-chip,
body.dark-mode .time-sub,
body.dark-mode .button-secondary {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.08);
}

.mode-button {
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  min-width: 72px;
  transition: background 0.25s ease, color 0.25s ease, box-shadow 0.25s ease;
}

#langToggle {
  min-width: 84px;
}

.mode-button.active {
  background: rgba(255, 255, 255, 0.95);
  color: var(--text);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

body.dark-mode .mode-button.active,
body.dark-mode .meter-center {
  background: rgba(255, 255, 255, 0.94);
  color: #121214;
}

.mode-button:hover,
.nav a:hover {
  color: var(--text);
}

.nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: flex-end;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.83rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.nav-cta {
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(0, 0, 0, 0.05);
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.hero-panel {
  border-radius: 58px;
  padding: 30px;
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 26px;
  margin-bottom: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0.44)),
    radial-gradient(circle at 20% 25%, rgba(255, 255, 255, 0.96), transparent 18%),
    radial-gradient(circle at 78% 26%, rgba(255, 255, 255, 0.75), transparent 16%),
    linear-gradient(135deg, #d8d9dd 0%, #bfc2c9 46%, #d7d8dc 100%);
  transition: background 0.25s ease;
}

body.dark-mode .hero-panel {
  background:
    linear-gradient(180deg, rgba(39, 39, 44, 0.78), rgba(22, 22, 24, 0.82)),
    radial-gradient(circle at 20% 25%, rgba(255, 255, 255, 0.05), transparent 18%),
    radial-gradient(circle at 78% 26%, rgba(255, 255, 255, 0.04), transparent 16%),
    linear-gradient(135deg, #1a1a1d 0%, #111214 46%, #191a1d 100%);
}

.hero-main {
  min-height: 520px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hero-kicker,
.hero-text,
.section-grid p,
.support-box p,
.faq-card p,
.section-copy p {
  color: var(--muted);
  line-height: 1.7;
  transition: color 0.25s ease;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  color: var(--accent);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
}

.time-block {
  margin: 18px 0 30px;
}

.time-big {
  display: block;
  font-size: clamp(4rem, 11vw, 7rem);
  line-height: 0.92;
  font-weight: 800;
  letter-spacing: -0.08em;
}

.time-sub {
  display: inline-block;
  margin-top: 10px;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  color: var(--muted);
  font-size: 0.88rem;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

h1,
h2,
h3,
p {
  margin-top: 0;
  transition: color 0.25s ease;
}

h1 {
  max-width: 12ch;
  margin-bottom: 16px;
  font-size: clamp(2.5rem, 5vw, 4.4rem);
  line-height: 0.98;
  letter-spacing: -0.05em;
}

.hero-text {
  max-width: 58ch;
  margin-bottom: 0;
}

.hero-widgets {
  display: grid;
  align-content: start;
  gap: 18px;
}

.widget {
  background: var(--panel-strong);
  border: 1px solid var(--panel-border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

body.dark-mode .widget {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.widget-pill {
  min-height: 92px;
  padding: 18px 22px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.widget-dot {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: inline-block;
}

.widget-dot.red {
  background: var(--accent);
  box-shadow: inset 0 0 0 10px rgba(255, 255, 255, 0.18);
  transition: box-shadow 0.25s ease;
}

body.dark-mode .widget-dot.red {
  box-shadow: inset 0 0 0 10px rgba(255, 255, 255, 0.08);
}

.widget-label {
  font-size: 0.88rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.widget-circle {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 16px;
}

.circle-number {
  display: block;
  font-size: clamp(3rem, 8vw, 4.8rem);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.08em;
}

.circle-label {
  display: block;
  margin-top: 12px;
  color: var(--accent-dark);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  transition: color 0.25s ease;
}

body.dark-mode .circle-label {
  color: #ff7a7d;
}

.widget-matrix {
  padding: 20px;
  border-radius: 28px;
}

.matrix-head {
  display: flex;
  justify-content: space-between;
  margin-bottom: 16px;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.dot-grid {
  display: grid;
  grid-template-columns: repeat(5, 16px);
  gap: 10px;
}

.dot-grid span {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: block;
}

.dot-grid .on {
  background: var(--accent);
}

.dot-grid .off {
  background: #d5d5db;
  transition: background 0.25s ease;
}

body.dark-mode .dot-grid .off {
  background: #4b4b52;
}

.widget-meter {
  border-radius: 999px;
  min-height: 110px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 16px 18px;
  gap: 12px;
}

.meter-arc {
  height: 54px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), rgba(239, 43, 45, 0.18));
  transition: background 0.25s ease;
}

body.dark-mode .meter-arc {
  background: linear-gradient(90deg, var(--accent), rgba(239, 43, 45, 0.12));
}

.meter-arc.right {
  transform: scaleX(-1);
}

.meter-center {
  width: 82px;
  height: 82px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.96);
  font-family: "Space Mono", monospace;
  font-size: 0.95rem;
  font-weight: 700;
  transition: background 0.25s ease, color 0.25s ease;
}

.dock {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.dock-item {
  min-width: 58px;
  padding: 14px 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.9);
  color: var(--text);
  text-decoration: none;
  text-align: center;
  font-size: 0.84rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.dock-item.wide {
  min-width: 116px;
}

.section-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 18px;
}

.services-section {
  margin-bottom: 22px;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.section-copy {
  max-width: 760px;
  margin-bottom: 24px;
}

.section-copy-services {
  padding: 6px 4px 8px;
}

.statement-card,
.faq-card,
.support-box {
  border-radius: var(--radius-lg);
  padding: 28px;
}

.large-card {
  grid-column: span 2;
  min-height: 240px;
}

.section-copy h2,
.large-card h2,
.info-card h2,
.support-box h2,
.statement-card h2 {
  margin-bottom: 12px;
}

.section-copy h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.05em;
}

.section-copy .eyebrow {
  margin-bottom: 10px;
}

.service-card,
.info-card {
  padding: 24px;
  border-radius: var(--radius-md);
}

.service-card {
  min-height: 220px;
}

.service-card.tall {
  min-height: 240px;
}

.service-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 48px;
}

.service-code,
.service-chip,
.step-number {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.service-chip {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  color: var(--muted);
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.service-card h3,
.info-card h3,
.faq-card summary,
.support-box h2,
.statement-card h2,
.large-card h2,
.info-card h2 {
  margin-bottom: 12px;
}

.system-grid .info-card:first-child {
  grid-column: span 2;
}

.accent-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(255, 245, 245, 0.88));
  transition: background 0.25s ease;
}

body.dark-mode .accent-card {
  background: linear-gradient(180deg, rgba(43, 30, 30, 0.8), rgba(28, 19, 19, 0.92));
}

.faq-card details {
  padding: 16px 0;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  transition: border-color 0.25s ease;
}

body.dark-mode .faq-card details {
  border-top-color: rgba(255, 255, 255, 0.08);
}

.faq-card details:first-of-type {
  border-top: 0;
  padding-top: 6px;
}

.faq-card summary {
  cursor: pointer;
  list-style: none;
}

.faq-card summary::-webkit-details-marker {
  display: none;
}

.faq-card details[open] summary {
  margin-bottom: 10px;
}

.support-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-top: 10px;
  background: rgba(255, 255, 255, 0.68);
}

body.dark-mode .support-box {
  background: rgba(255, 255, 255, 0.05);
}

.support-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 14px 30px rgba(239, 43, 45, 0.18);
}

body.dark-mode .button-primary {
  box-shadow: 0 14px 30px rgba(239, 43, 45, 0.22);
}

.button-secondary {
  background: rgba(255, 255, 255, 0.78);
  color: var(--text);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

@media (max-width: 1080px) {
  .hero-panel {
    grid-template-columns: 1fr;
  }

  .hero-main {
    min-height: auto;
  }

  .hero-widgets,
  .section-grid,
  .system-grid,
  .services-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .large-card,
  .system-grid .info-card:first-child {
    grid-column: span 2;
  }
}

@media (max-width: 760px) {
  .page-shell {
    width: min(100% - 20px, 100%);
    padding-top: 18px;
  }

  .topbar,
  .support-box {
    border-radius: 30px;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .topbar-controls {
    width: 100%;
    justify-content: flex-start;
  }

  .mode-switch {
    margin-left: 0;
  }

  .nav,
  .hero-widgets,
  .section-grid,
  .system-grid,
  .services-grid,
  .support-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .hero-panel {
    padding: 22px;
    border-radius: 34px;
  }

  .large-card,
  .system-grid .info-card:first-child {
    grid-column: span 1;
  }

  .dock {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dock-item,
  .dock-item.wide {
    width: 100%;
    min-width: 0;
  }

  h1 {
    max-width: none;
    font-size: clamp(2.2rem, 12vw, 3.4rem);
  }

  .time-big {
    font-size: clamp(3rem, 18vw, 5.4rem);
  }

  .support-box {
    flex-direction: column;
    align-items: flex-start;
  }
}
