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

:root {
  --bg-primary: #ffffff;
  --bg-deep: #f7f7f7;
  --bg-surface: #f7f2f1;
  --accent: #F37300;
  --accent-hover: #e06800;
  --accent-subtle: rgba(243,115,0,0.1);
  --accent-border: rgba(243,115,0,0.3);
  --accent-glow: rgba(243,115,0,0.06);
  --accent-faint: rgba(243,115,0,0.15);
  --text-primary: #1a1a1a;
  --text-heading: #111111;
  --text-accent-heading: #c45e00;
  --text-secondary: rgba(0,0,0,0.55);
  --text-tertiary: rgba(0,0,0,0.35);
  --text-on-accent: #ffffff;
  --separator: rgba(69,61,51,0.14);
  --green: #00AC53;
  --nav-bg: rgba(255,255,255,0.85);
  --radius-card: 16px;
  --radius-btn: 4px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg-primary: #262626;
    --bg-deep: #1a1a1a;
    --bg-surface: #353535;
    --accent: #FF861A;
    --accent-hover: #F37300;
    --accent-subtle: rgba(255,134,26,0.12);
    --accent-border: rgba(255,134,26,0.3);
    --accent-glow: rgba(255,134,26,0.08);
    --accent-faint: rgba(255,134,26,0.2);
    --text-primary: #ffffff;
    --text-heading: #ffffff;
    --text-accent-heading: #FF861A;
    --text-secondary: rgba(255,255,255,0.6);
    --text-tertiary: rgba(255,255,255,0.4);
    --text-on-accent: #ffffff;
    --separator: rgba(199,191,184,0.12);
    --green: #00C165;
    --nav-bg: rgba(26,26,26,0.85);
  }
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Fira Sans', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* --- Nav --- */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 16px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--nav-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--separator);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-primary);
}

.nav-brand img { width: 32px; height: 32px; border-radius: 8px; }

.nav-brand span {
  font-family: 'Fira Mono', monospace;
  font-weight: 500;
  font-size: 18px;
  letter-spacing: 0.5px;
}

.nav-links {
  display: flex;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  font-family: 'Fira Mono', monospace;
  font-size: 13px;
  color: var(--text-secondary);
  text-decoration: none;
  letter-spacing: 0.5px;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--accent); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  width: 32px;
  height: 32px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 1px;
  transition: transform 0.25s, opacity 0.25s;
}

.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* --- Footer --- */
footer {
  padding: 32px 24px;
  border-top: 1px solid var(--separator);
  background: var(--bg-deep);
}

.footer-inner {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-inner p {
  font-family: 'Fira Mono', monospace;
  font-size: 12px;
  color: var(--text-tertiary);
}

.footer-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.footer-links a {
  font-family: 'Fira Mono', monospace;
  font-size: 12px;
  color: var(--text-tertiary);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--accent); }

/* --- Responsive (shared nav + footer) --- */
@media (max-width: 768px) {
  nav { padding: 12px 20px; flex-wrap: wrap; }

  .nav-toggle { display: flex; }

  .nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    gap: 0;
    padding: 8px 0 4px;
  }

  .nav-links.open { display: flex; }

  .nav-links li { width: 100%; }

  .nav-links a {
    display: block;
    padding: 12px 0;
    font-size: 15px;
    border-bottom: 1px solid var(--separator);
  }

  .nav-links li:last-child a { border-bottom: none; }

  .footer-inner {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}
