/* Notfinity — bilingual dark/light, HTML + CSS only */

:root {
  --bg: #05070a;
  --bg-end: #090d13;
  --panel: #0d1118;
  --panel-2: #111720;
  --text: #f4f7fb;
  --muted: #9aa4b3;
  --line: rgba(255, 255, 255, 0.11);
  --soft: rgba(255, 255, 255, 0.035);
  --accent: #1478ff;
  --accent-2: #51a0ff;
  --shadow: 0 24px 70px rgba(0,0,0,.35);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
.state-toggle { position: fixed; opacity: 0; pointer-events: none; }
.es, .print-logo, .light-logo { display: none; }
.dark-logo { display: block; }

.page-shell {
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at 72% 24%, rgba(20,120,255,.18), transparent 24rem),
    linear-gradient(180deg, var(--bg) 0%, var(--bg) 45%, var(--bg-end) 100%);
  transition: background .25s ease, color .25s ease;
}

/* Light theme */
#theme-toggle:checked ~ .page-shell {
  --bg: #f6f8fb;
  --bg-end: #eaf0f8;
  --panel: #ffffff;
  --panel-2: #f8fbff;
  --text: #0c1420;
  --muted: #5e6b7c;
  --line: rgba(12, 20, 32, 0.12);
  --soft: rgba(12, 20, 32, 0.035);
  --shadow: 0 24px 70px rgba(56, 75, 101, .14);
  background:
    radial-gradient(circle at 72% 24%, rgba(20,120,255,.12), transparent 24rem),
    linear-gradient(180deg, #fbfcfe 0%, var(--bg) 50%, var(--bg-end) 100%);
}

#theme-toggle:checked ~ .page-shell .dark-logo { display: none; }
#theme-toggle:checked ~ .page-shell .light-logo { display: block; }

.theme-logo {
  object-fit: contain;
  object-position: center;
}

/* Language state */
#language-toggle:checked ~ .page-shell .en { display: none; }
#language-toggle:checked ~ .page-shell .es { display: initial; }
#language-toggle:checked ~ .page-shell .hero-copy > .es,
#language-toggle:checked ~ .page-shell .intro > .es,
#language-toggle:checked ~ .page-shell .feature-card > .es,
#language-toggle:checked ~ .page-shell .contact-card > .es,
#language-toggle:checked ~ .page-shell .site-footer p.es { display: block; }

.site-header, .site-footer, main {
  width: min(1320px, calc(100% - 48px));
  margin-inline: auto;
}

.site-header {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  border-bottom: 1px solid var(--line);
}

.brand { display: inline-flex; align-items: center; gap: 14px; }
.brand-logo { width: 70px; height: 38px; object-fit: contain; object-position: left center; }
.brand-word { letter-spacing: .34em; font-size: .95rem; font-weight: 700; }

.header-actions { display: flex; align-items: center; gap: 24px; }
.nav { display: flex; gap: 24px; color: var(--muted); font-size: .91rem; }
.nav a { position: relative; padding: 31px 0; }
.nav a:hover, .nav a.active { color: var(--text); }
.nav a.active::after, .nav a:hover::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 20px; height: 2px; background: var(--accent);
}

.controls { display: flex; gap: 10px; align-items: center; }
.segmented {
  display: flex; align-items: center; gap: 7px; padding: 5px 7px;
  border: 1px solid var(--line); border-radius: 10px; background: var(--soft);
}
.control-label, .theme-icon { min-width: 23px; text-align: center; font-size: .72rem; font-weight: 800; color: var(--muted); }
.active-en { color: var(--text); }
#language-toggle:checked ~ .page-shell .active-en { color: var(--muted); }
#language-toggle:checked ~ .page-shell .active-es { color: var(--text); }

.segmented label { cursor: pointer; }
.mini-track {
  position: relative; display: block; width: 36px; height: 21px;
  border-radius: 999px; background: color-mix(in srgb, var(--text) 12%, transparent);
}
.mini-dot {
  position: absolute; width: 15px; height: 15px; top: 3px; left: 3px;
  border-radius: 50%; background: var(--accent); transition: transform .18s ease;
}
#language-toggle:checked ~ .page-shell .language-control .mini-dot,
#theme-toggle:checked ~ .page-shell .theme-control .mini-dot { transform: translateX(15px); }

.hero {
  min-height: 650px;
  display: grid;
  grid-template-columns: 1.06fr .94fr;
  align-items: center;
  gap: 70px;
  padding: 72px 0 90px;
}

.hero-copy { max-width: 700px; }
.eyebrow {
  margin: 0 0 14px; color: var(--accent-2); font-size: .78rem;
  font-weight: 800; letter-spacing: .13em; text-transform: uppercase;
}
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 24px; font-size: clamp(3.7rem, 6.5vw, 6.8rem); line-height: .98; letter-spacing: -.06em; }
h1 span { color: var(--accent); }
h2 { margin-bottom: 18px; font-size: clamp(2rem, 3.8vw, 4rem); line-height: 1.06; letter-spacing: -.045em; }
h3 { margin-bottom: 8px; font-size: 1.45rem; letter-spacing: -.03em; }
.hero-text, .section-copy, .feature-card p, .contact-copy p { color: var(--muted); }
.hero-text { max-width: 620px; margin-bottom: 32px; font-size: 1.1rem; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.button {
  min-height: 50px; display: inline-flex; align-items: center; justify-content: center;
  gap: 18px; padding: 0 20px; border: 1px solid transparent; border-radius: 9px; font-weight: 750;
  transition: transform .17s ease, border-color .17s ease, background .17s ease;
}
.button:hover { transform: translateY(-2px); }
.button-primary { background: linear-gradient(135deg, #0873ff, #1765dd); color: #fff; box-shadow: 0 10px 30px rgba(20,120,255,.22); }
.button-secondary { border-color: var(--line); background: var(--soft); }

.hero-brand {
  position: relative; min-height: 430px; display: grid; place-items: center;
  align-content: center; text-align: center;
}
.brand-glow {
  position: absolute; width: 420px; height: 420px; border-radius: 50%;
  background: radial-gradient(circle, rgba(20,120,255,.24), transparent 66%); filter: blur(18px);
}
.hero-logo { position: relative; z-index: 2; width: min(520px, 90%); max-height: 230px; object-fit: contain; }
.hero-brand-name { position: relative; z-index: 2; margin: 12px 0 4px; font-size: clamp(1.7rem, 3vw, 3rem); font-weight: 500; letter-spacing: .42em; }
.hero-tagline { position: relative; z-index: 2; margin: 0; color: var(--muted); font-size: clamp(1rem, 1.8vw, 1.35rem); }
.hero-tagline span { color: var(--accent-2); }

.intro { padding: 84px 0 44px; text-align: center; border-top: 1px solid var(--line); }
.intro > div { max-width: 850px; margin-inline: auto; }
.intro h2 { font-size: clamp(2.3rem, 4vw, 4.6rem); }
.section-copy { max-width: 760px; margin: 0 auto; font-size: 1.05rem; }

.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; padding: 26px 0 72px; }
.feature-card {
  min-height: 280px; display: grid; grid-template-columns: auto 1fr; gap: 20px; padding: 28px;
  border: 1px solid var(--line); border-radius: 22px;
  background: linear-gradient(180deg, var(--soft), transparent), var(--panel);
  box-shadow: inset 0 1px 0 var(--soft);
  transition: transform .18s ease, border-color .18s ease, background .25s ease;
}
.feature-card:hover { transform: translateY(-4px); border-color: rgba(20,120,255,.5); }
.icon-badge {
  width: 62px; height: 62px; display: grid; place-items: center; border-radius: 50%;
  color: #fff; background: linear-gradient(145deg, #0c73ff, #0e469b); border: 1px solid rgba(255,255,255,.12); font-weight: 800;
}
.feature-kicker { margin-bottom: 12px; color: var(--accent-2) !important; font-size: .8rem; font-weight: 800; letter-spacing: .12em; }
.feature-card a { color: var(--accent-2); font-weight: 700; }

.contact-card {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 26px;
  margin: 0 0 34px; padding: 28px 30px; border: 1px solid rgba(20,120,255,.55); border-radius: 22px;
  background: radial-gradient(circle at 80% 50%, rgba(20,120,255,.11), transparent 28rem), var(--panel-2);
  box-shadow: var(--shadow);
}
.contact-icon {
  width: 66px; height: 66px; display: grid; place-items: center;
  border: 1px solid var(--accent); border-radius: 50%; color: var(--accent-2); font-size: 1.5rem;
}
.contact-copy .eyebrow { margin-bottom: 6px; }
.contact-copy h2 { margin-bottom: 4px; font-size: clamp(1.55rem, 3vw, 2.3rem); }
.contact-copy p { margin-bottom: 0; }

.site-footer {
  min-height: 110px; display: flex; align-items: center; justify-content: space-between; gap: 24px;
  border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem;
}
.footer-brand { display: flex; align-items: center; gap: 12px; color: var(--text); font-size: .74rem; font-weight: 800; letter-spacing: .28em; }
.footer-logo { width: 58px; height: 32px; object-fit: contain; }
.site-footer p { margin: 0; }
.site-footer a:hover { color: var(--text); }

a:focus-visible, label:focus-visible { outline: 3px solid rgba(81,160,255,.45); outline-offset: 4px; }

@media (max-width: 1080px) {
  .nav { display: none; }
  .hero { grid-template-columns: 1fr; gap: 20px; }
  .hero-brand { min-height: 360px; }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-card { min-height: 220px; }
}

@media (max-width: 720px) {
  .site-header, .site-footer, main { width: min(100% - 26px, 1320px); }
  .brand-word { display: none; }
  .header-actions { gap: 10px; }
  .controls { gap: 7px; }
  .segmented { padding: 4px 5px; }
  .hero { min-height: auto; padding: 58px 0 72px; }
  h1 { font-size: clamp(3.2rem, 16vw, 5.3rem); }
  .hero-brand { min-height: 300px; }
  .feature-card { grid-template-columns: 1fr; }
  .contact-card { grid-template-columns: 1fr; align-items: start; }
  .contact-card .button { width: 100%; }
  .site-footer { padding: 28px 0; flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}

@media print {
  .page-shell { color: #111; background: #fff; }
  .theme-logo, .controls, .hero-actions, .contact-card .button { display: none !important; }
  .print-logo { display: block !important; }
  .site-header, .intro, .feature-card, .contact-card, .site-footer { border-color: #bbb; }
  .hero-brand, .feature-card, .contact-card { background: #fff; box-shadow: none; }
  .brand-glow { display: none; }
  h1 span, .hero-tagline span, .eyebrow, .feature-card a { color: #111; }
}
