@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  --bg: #f0f4f9;
  --surface: #ffffff;
  --surface-alt: #e8eef6;
  --surface-glass: rgba(255, 255, 255, 0.72);
  --text: #1a2332;
  --muted: #536478;
  --line: #d0dae7;
  --primary: #1b5e8a;
  --primary-dark: #0f3d5e;
  --accent: #3a8fd4;
  --accent-light: #5ba8e6;
  --accent-glow: rgba(58, 143, 212, 0.18);
  --gradient-primary: linear-gradient(135deg, #0f3d5e 0%, #3a8fd4 100%);
  --gradient-hero: linear-gradient(135deg, #0b2a42 0%, #1b5e8a 50%, #2c7ab5 100%);
  --shadow-sm: 0 2px 8px rgba(15, 61, 94, 0.06);
  --shadow: 0 8px 32px rgba(15, 61, 94, 0.08);
  --shadow-lg: 0 16px 48px rgba(15, 61, 94, 0.12);
  --shadow-glow: 0 8px 32px rgba(58, 143, 212, 0.2);
  --radius: 18px;
  --radius-sm: 12px;
  --radius-xs: 8px;
  --container: 1120px;
  --container-narrow: 860px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--primary);
  text-decoration: none;
}

code,
pre {
  font-family: 'JetBrains Mono', Consolas, Monaco, "Courier New", monospace;
}

.container {
  width: min(var(--container), calc(100% - 40px));
  margin: 0 auto;
}

.container.narrow {
  width: min(var(--container-narrow), calc(100% - 40px));
}

/* ── Navigation ── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 24px 0;
  background: transparent;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  border-bottom: 1px solid transparent;
}

.navbar.scrolled {
  padding: 12px 0;
  background: rgba(10, 22, 40, 0.85); /* Dark background */
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(15, 23, 42, 0.15);
}

.navbar .container {
  display: flex;
  align-items: center;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 1.6rem;
  letter-spacing: -0.02em;
  color: #ffffff;
  transition: opacity 0.3s ease;
  margin-right: 8px;
}

.logo:hover {
  opacity: 0.8;
  text-decoration: none;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.logo-main {
  font-size: 1.2rem;
  font-weight: 700;
}

.logo-sub {
  font-family: 'Outfit', sans-serif;
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.7;
  margin-top: 2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
  margin-left: auto;
  margin-bottom: 0;
  padding-left: 0;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.7);
  transition: all 0.2s ease;
  position: relative;
}

.nav-links a:not(.nav-cta):hover {
  color: #ffffff;
}

.nav-links a:not(.nav-cta)::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #2563eb;
  transition: width 0.3s ease;
  border-radius: 2px;
}

.nav-links a:not(.nav-cta):hover::after {
  width: 100%;
}

.nav-cta {
  background: rgba(37, 99, 235, 0.15);
  border: 1px solid rgba(37, 99, 235, 0.3);
  color: #60a5fa !important;
  padding: 8px 18px;
  border-radius: 20px;
  font-weight: 600;
  transition: all 0.3s ease;
}

.nav-cta:hover {
  background: #2563eb;
  color: white !important;
  border-color: #2563eb;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4);
  transform: translateY(-1px);
}

.lang-toggle {
  display: flex;
  align-items: center;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 30px;
  padding: 4px;
  gap: 0;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.lang-btn {
  padding: 8px 18px;
  font-size: 0.8rem;
  font-weight: 700;
  font-family: 'Outfit', sans-serif;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.5);
  background: transparent;
  border: none;
  border-radius: 24px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.lang-btn:hover {
  color: rgba(255, 255, 255, 0.9);
}

.lang-btn.active {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(37, 99, 235, 0.3);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  z-index: 1001;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: white;
  transition: all 0.3s ease;
  transform-origin: center;
}

.nav-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

@media (max-width: 768px) {
  .navbar .container { gap: 12px; }
  .nav-toggle { display: flex; flex-shrink: 0; z-index: 1003; }
  .nav-links {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    height: 100vh;
    height: 100dvh;
    height: -webkit-fill-available;
    background: rgba(10, 22, 40, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 32px;
    z-index: 1002;
    padding: 80px 20px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  .nav-links.active { display: flex; }
  .nav-links a { font-size: 1.2rem; color: rgba(255, 255, 255, 0.9); }
  .nav-links a:not(.nav-cta)::after { display: none; }
  .nav-cta { margin-top: 16px; }
  .lang-toggle { position: relative; z-index: 1003; margin-left: auto; flex-shrink: 0; }
}

/* ── Hero ── */
.hero {
  position: relative;
  padding: 112px 0 64px;
  background: var(--gradient-hero);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -30%;
  right: -10%;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(90, 168, 230, 0.25) 0%, transparent 70%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -20%;
  left: -5%;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(58, 143, 212, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 16px;
  padding: 7px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.hero h1 {
  margin: 0;
  font-size: clamp(2.2rem, 4.5vw, 3.4rem);
  line-height: 1.15;
  color: #ffffff;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.lead {
  margin: 20px 0 0;
  max-width: 680px;
  color: rgba(255, 255, 255, 0.75);
  font-size: 1.1rem;
  line-height: 1.8;
}

.hero-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 36px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  font-family: inherit;
  transition: all var(--transition);
  border: 1px solid transparent;
  cursor: pointer;
  letter-spacing: 0.01em;
}

.button:hover {
  text-decoration: none;
  transform: translateY(-2px);
}

.button.primary {
  background: #ffffff;
  color: var(--primary-dark);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.button.primary:hover {
  background: #f0f4f9;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.button.secondary {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(4px);
}

.button.secondary:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.4);
}

.info-strip {
  margin-top: 42px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.info-card {
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  padding: 20px 22px;
  transition: all var(--transition);
}

.info-card:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.2);
}

.info-label {
  display: block;
  margin-bottom: 8px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.info-card code {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.88rem;
}

.info-card a {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
}

.info-card a:hover {
  color: #ffffff;
}

/* ── Section ── */
.section {
  padding: 80px 0;
}

.section.alt {
  background: var(--surface-alt);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section h2 {
  margin-top: 0;
  margin-bottom: 16px;
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  line-height: 1.2;
  color: var(--primary-dark);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.section-heading {
  margin-bottom: 28px;
}

.section-kicker {
  margin: 0 0 8px;
  color: var(--accent);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
}

.section-intro {
  margin-top: 0;
  margin-bottom: 32px;
  color: var(--muted);
  font-size: 1.05rem;
}

/* ── Grid & Cards ── */
.grid {
  display: grid;
  gap: 20px;
}

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

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity var(--transition);
}

.card:hover {
  box-shadow: var(--shadow);
  transform: translateY(-3px);
  border-color: rgba(58, 143, 212, 0.2);
}

.card:hover::before {
  opacity: 1;
}

.card h3 {
  margin-top: 0;
  margin-bottom: 10px;
  color: var(--primary-dark);
  font-size: 1.1rem;
  font-weight: 700;
}

.card p {
  margin: 0;
  color: var(--muted);
}

/* ── Step cards ── */
.step-card {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 22px;
  align-items: start;
  margin-bottom: 20px;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  position: relative;
}

.step-card:hover {
  box-shadow: var(--shadow);
  border-color: rgba(58, 143, 212, 0.15);
}

.step-number {
  width: 50px;
  height: 50px;
  border-radius: 14px;
  background: var(--gradient-primary);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.15rem;
  box-shadow: 0 4px 16px rgba(15, 61, 94, 0.2);
  flex-shrink: 0;
}

.step-content h3 {
  margin: 0 0 10px;
  color: var(--primary-dark);
  font-size: 1.12rem;
  font-weight: 700;
}

.step-content p {
  margin: 0 0 14px;
  color: var(--muted);
}

/* ── Code blocks (terminal style) ── */
.code-block {
  position: relative;
  margin-top: 12px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: #0c1219;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04),
              0 4px 16px rgba(0, 0, 0, 0.12);
}

.code-block::before {
  content: '';
  display: block;
  height: 36px;
  background: #151d27;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  position: relative;
}

.code-block::after {
  content: '● ● ●';
  position: absolute;
  top: 10px;
  left: 16px;
  font-size: 9px;
  letter-spacing: 5px;
  color: rgba(255, 255, 255, 0.2);
}

.code-block pre {
  margin: 0;
  padding: 16px 60px 18px 20px;
  overflow-x: auto;
}

.code-block pre code {
  color: #b8d4ee;
  font-size: 0.88rem;
  line-height: 1.7;
  white-space: pre-wrap;
  word-break: break-word;
  background: transparent;
  padding: 0;
}

.copy-button {
  position: absolute;
  top: 42px;
  right: 12px;
  appearance: none;
  border: 0;
  border-radius: var(--radius-xs);
  padding: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.copy-button:hover {
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.8);
  transform: scale(1.05);
}

.copy-button.copied {
  background: rgba(34, 197, 94, 0.2);
  color: #4ade80;
}

.note-card code,
.step-content code,
.info-card code {
  background: rgba(58, 143, 212, 0.08);
  color: var(--primary);
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 0.87em;
  font-weight: 500;
}

/* Override info-card code for hero */
.hero .info-card code {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

/* ── OS tabs ── */
.os-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 0;
  background: rgba(58, 143, 212, 0.04);
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  padding: 6px 6px 0;
  border-bottom: 2px solid var(--line);
}

.os-tab {
  appearance: none;
  border: none;
  background: transparent;
  padding: 10px 22px;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: inherit;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  border-radius: var(--radius-xs) var(--radius-xs) 0 0;
  transition: all var(--transition);
  position: relative;
}

.os-tab:hover {
  color: var(--accent);
  background: rgba(58, 143, 212, 0.06);
}

.os-tab.active {
  color: var(--primary);
  background: var(--surface);
  border-bottom-color: var(--accent);
  box-shadow: 0 -2px 8px rgba(58, 143, 212, 0.08);
}

.os-panel {
  display: none;
  padding: 22px 0 8px;
  animation: fadeSlideIn 0.3s ease;
}

.os-panel.active {
  display: block;
}

.os-panel ol {
  margin: 8px 0 16px;
  padding-left: 22px;
  color: var(--muted);
}

.os-panel ol li {
  margin-bottom: 8px;
  line-height: 1.6;
}

.install-note {
  margin-top: 8px;
  font-size: 0.88rem;
  color: var(--muted);
}

.os-note {
  margin-top: 24px;
  padding: 16px 20px;
  background: var(--surface-alt);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.os-note h4 {
  margin: 0 0 8px;
  font-size: 0.95rem;
  color: var(--primary-dark);
}

.os-note p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.6;
}

/* ── Download selector ── */
.download-selector {
  margin-top: 16px;
  padding: 24px;
  background: rgba(58, 143, 212, 0.03);
  border: 1px solid rgba(58, 143, 212, 0.08);
  border-radius: var(--radius);
}

.selector-group {
  margin-bottom: 18px;
}

.selector-label {
  display: block;
  margin-bottom: 10px;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
}

.selector-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  appearance: none;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 9px 20px;
  font-size: 0.88rem;
  font-weight: 600;
  font-family: inherit;
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  transition: all var(--transition);
}

.pill:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(58, 143, 212, 0.04);
  transform: translateY(-1px);
}

.pill.active {
  background: var(--gradient-primary);
  color: #fff;
  border-color: transparent;
  box-shadow: var(--shadow-glow);
  transform: translateY(-1px);
}

.subject-input-area {
  margin-bottom: 16px;
  animation: fadeSlideIn 0.3s ease;
}

.subject-input-area label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--muted);
}

.subject-input {
  width: 100%;
  max-width: 380px;
  padding: 12px 16px;
  font-size: 0.92rem;
  font-family: 'JetBrains Mono', Consolas, monospace;
  border: 2px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  transition: all var(--transition);
}

.subject-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-glow);
}

.subject-input::placeholder {
  color: #a8b7c7;
}

.selector-description {
  margin-bottom: 16px;
  padding: 12px 16px;
  background: rgba(58, 143, 212, 0.06);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-xs) var(--radius-xs) 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.5;
  transition: all var(--transition);
}

/* ── Note cards ── */
.note-card {
  position: relative;
  padding-left: 56px !important;
}

.note-card::after {
  position: absolute;
  left: 24px;
  top: 28px;
  font-size: 1.3rem;
  opacity: 0.7;
}

.note-card:nth-child(1)::after { content: '💾'; }
.note-card:nth-child(2)::after { content: '💰'; }
.note-card:nth-child(3)::after { content: '⏸️'; }
.note-card:nth-child(4)::after { content: '🔌'; }

/* ── Animations ── */
@keyframes fadeSlideIn {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ── Footer ── */
.site-footer {
  padding: 32px 0 48px;
  background: var(--surface);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  border-top: 1px solid var(--line);
  padding-top: 24px;
}

.site-footer p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

/* ── Responsive ── */
@media (max-width: 860px) {
  .info-strip,
  .grid.two {
    grid-template-columns: 1fr;
  }

  .step-card {
    grid-template-columns: 1fr;
  }

  .step-number {
    width: 44px;
    height: 44px;
    border-radius: 12px;
  }

  .hero {
    padding: 104px 0 48px;
  }

  .section {
    padding: 60px 0;
  }

  .footer-inner,
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .download-selector {
    padding: 18px;
  }

  .note-card {
    padding-left: 48px !important;
  }

  .note-card::after {
    left: 18px;
  }
}

@media (max-width: 560px) {
  .hero {
    padding-top: 104px;
  }

  .hero h1 {
    font-size: 1.75rem;
  }

  .button {
    width: 100%;
  }

  .nav {
    gap: 4px;
  }

  .nav a {
    padding: 6px 10px;
    font-size: 0.85rem;
  }

  .os-tabs {
    overflow-x: auto;
  }

  .selector-pills {
    gap: 6px;
  }

  .pill {
    padding: 8px 14px;
    font-size: 0.82rem;
  }
}
