/* ── LoneByte · Revered Creative ── */
:root {
  --bg: #f6f5f2;
  --surface: #ffffff;
  --ink: #1c1b18;
  --ink-soft: #5c5850;
  --ink-muted: #8a857a;
  --rule: #e0ddd6;
  --accent: #c44536;     /* terracotta — warm, grounded, Ethiopian earth */
  --accent-hover: #a83528;
  --accent-glow: rgba(196, 69, 54, 0.08);
  --code-bg: #f0eee9;
  --radius: 6px;
  --max-w: 80rem;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-mono: "SF Mono", "Cascadia Code", "JetBrains Mono", ui-monospace, Menlo, monospace;
  --font-display: var(--font-sans);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141312;
    --surface: #1c1b18;
    --ink: #e6e2da;
    --ink-soft: #9c968c;
    --ink-muted: #6b655c;
    --rule: #2e2b26;
    --accent: #e05a48;
    --accent-hover: #d04a38;
    --accent-glow: rgba(224, 90, 72, 0.08);
    --code-bg: #22201c;
  }
}
html.dark {
  --bg: #141312;
  --surface: #1c1b18;
  --ink: #e6e2da;
  --ink-soft: #9c968c;
  --ink-muted: #6b655c;
  --rule: #2e2b26;
  --accent: #e05a48;
  --accent-hover: #d04a38;
  --accent-glow: rgba(224, 90, 72, 0.08);
  --code-bg: #22201c;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

/* ── Layout ── */
.page-wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
}

/* ── Nav ── */
nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--rule);
  flex-wrap: wrap;
  gap: 0.75rem;
}
.logo {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  text-decoration: none;
  color: var(--ink);
}
.logo span { color: var(--accent); }
.nav-links {
  display: flex;
  gap: 1.75rem;
  align-items: center;
}
.nav-links a {
  text-decoration: none;
  color: var(--ink-soft);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { color: var(--accent); }

/* ── Hero ── */
.hero {
  padding: 5rem 0 4rem;
  max-width: 64ch;
}
.hero-tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1rem;
}
.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.025em;
  margin: 0 0 1.25rem;
}
.hero h1 span { color: var(--accent); }
.hero p {
  font-size: 1.125rem;
  color: var(--ink-soft);
  line-height: 1.6;
  margin: 0 0 2rem;
  max-width: 54ch;
}
.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.65rem 1.5rem;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.15s;
  cursor: pointer;
  border: none;
  font-family: inherit;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: var(--accent-hover);
}
.btn-outline {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--rule);
}
.btn-outline:hover {
  border-color: var(--ink);
  background: var(--accent-glow);
}

/* ── Sections ── */
section { padding: 4rem 0; }
.section-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin: 0 0 0.5rem;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.5rem;
}
.section-sub {
  color: var(--ink-soft);
  max-width: 48ch;
  margin: 0 0 2.5rem;
  font-size: 1rem;
}

/* ── Product Grid ── */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}
.product-card {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 1.75rem 1.5rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.product-card:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 20px var(--accent-glow);
}
.product-card .icon {
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
  display: block;
}
.product-card h3 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0 0 0.4rem;
  letter-spacing: -0.01em;
}
.product-card .tagline {
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin: 0 0 0.75rem;
  line-height: 1.5;
}
.product-card .tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.tech-tag {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  padding: 0.2rem 0.5rem;
  background: var(--code-bg);
  border-radius: 3px;
  color: var(--ink-soft);
  letter-spacing: 0.01em;
}

/* ── Ethos / Approach ── */
.ethos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 2rem;
}
.ethos-item {
  border-left: 2px solid var(--rule);
  padding-left: 1.25rem;
}
.ethos-item h3 {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin: 0 0 0.5rem;
  color: var(--accent);
}
.ethos-item p {
  font-size: 0.925rem;
  color: var(--ink-soft);
  margin: 0;
  line-height: 1.6;
}

/* ── Contact ── */
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}
.contact-info p {
  margin: 0 0 0.5rem;
  color: var(--ink-soft);
  font-size: 0.925rem;
}
.contact-info a {
  color: var(--accent);
  text-decoration: none;
}
.contact-info a:hover { text-decoration: underline; }
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.contact-form label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
}
.contact-form input,
.contact-form textarea {
  font-family: inherit;
  font-size: 0.925rem;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  transition: border-color 0.15s;
  width: 100%;
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
.contact-form textarea { min-height: 120px; resize: vertical; }
.form-status {
  font-size: 0.85rem;
  margin: 0;
}
.form-status.success { color: var(--accent); }
.form-status.error { color: #c44536; }

/* ── Footer ── */
footer {
  border-top: 1px solid var(--rule);
  padding: 2.5rem 0 3rem;
  margin-top: 2rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2rem;
}
.footer-brand p {
  font-size: 0.85rem;
  color: var(--ink-muted);
  margin: 0.5rem 0 0;
  max-width: 32ch;
}
.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin: 0 0 0.75rem;
}
.footer-col a {
  display: block;
  font-size: 0.85rem;
  color: var(--ink-soft);
  text-decoration: none;
  margin-bottom: 0.4rem;
}
.footer-col a:hover { color: var(--ink); }
.footer-bottom {
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--ink-muted);
}
.footer-bottom .attribution { font-size: 0.7rem; opacity: 0.6; }
.footer-bottom .attribution a { color: var(--ink-muted); text-decoration: none; }
.footer-bottom .attribution a:hover { color: var(--ink); }

/* ── Theme Toggle ── */
.theme-toggle {
  background: none;
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 0.35rem 0.5rem;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--ink-soft);
  transition: all 0.15s;
  line-height: 1;
}
.theme-toggle:hover {
  border-color: var(--ink);
  color: var(--ink);
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .page-wrap { padding: 0 1.25rem; }
  .hero { padding: 3rem 0 2.5rem; }
  section { padding: 2.5rem 0; }
  .contact-wrap { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .footer-bottom { flex-direction: column; text-align: center; }
  nav { flex-direction: column; align-items: flex-start; }
  .nav-links { width: 100%; justify-content: flex-start; gap: 1rem; }
}

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