/* ============================================================
   Revenant Systems — styles.css
   ============================================================ */

:root {
  --bg: #0b0f14;
  --bg-alt: #10161d;
  --surface: #151d26;
  --surface-edge: #22303d;
  --text: #e8edf2;
  --text-dim: #9baab8;
  --accent: #2ee6a8;
  --accent-soft: rgba(46, 230, 168, 0.12);
  --accent-glow: rgba(46, 230, 168, 0.25);
  --radius: 14px;
  --font: "Avenir Next", Avenir, "Segoe UI", Inter, system-ui, -apple-system, sans-serif;
  --mono: "SF Mono", "Fira Code", Menlo, Consolas, monospace;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.container {
  width: min(1100px, 92%);
  margin-inline: auto;
}

/* ---------- Typography ---------- */

h1, h2, h3 { line-height: 1.15; font-weight: 700; letter-spacing: -0.02em; }

h1 { font-size: clamp(2rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.15rem; margin-bottom: 0.5rem; }

h1 em, h2 em {
  font-style: normal;
  color: var(--accent);
}

.eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
  margin-bottom: 1rem;
}

.section-sub {
  color: var(--text-dim);
  max-width: 42rem;
  margin-top: 1rem;
  font-size: 1.05rem;
}

/* ---------- Header / Nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 15, 20, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--surface-edge);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}

.logo-mark {
  color: var(--accent);
  font-size: 1.3rem;
  line-height: 1;
}

.logo-accent { color: var(--accent); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  list-style: none;
}

.nav-links a {
  color: var(--text-dim);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s;
}

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

.nav-cta {
  color: var(--bg) !important;
  background: var(--accent);
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
  font-weight: 600 !important;
  transition: transform 0.15s, box-shadow 0.2s !important;
}

.nav-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px var(--accent-glow);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}

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

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(5rem, 12vh, 9rem) 0 clamp(4rem, 10vh, 7rem);
  text-align: center;
}

.hero-glow {
  position: absolute;
  inset: -40% -20% auto;
  height: 90%;
  background:
    radial-gradient(ellipse 50% 60% at 50% 0%, var(--accent-glow), transparent 70%),
    radial-gradient(ellipse 30% 40% at 20% 20%, rgba(46, 140, 230, 0.12), transparent 70%);
  pointer-events: none;
}

.hero-inner { position: relative; }

.hero-sub {
  color: var(--text-dim);
  font-size: clamp(1rem, 2vw, 1.2rem);
  max-width: 44rem;
  margin: 1.4rem auto 2.2rem;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: clamp(1.5rem, 5vw, 4rem);
  list-style: none;
  margin-top: 3.5rem;
  flex-wrap: wrap;
}

.hero-stats li {
  display: flex;
  flex-direction: column;
  font-size: 0.9rem;
  color: var(--text-dim);
}

.hero-stats strong {
  color: var(--text);
  font-size: 1.15rem;
}

.hero-shot {
  margin: 4rem auto 0;
  max-width: 900px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--surface-edge);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
}

.hero-shot img {
  width: 100%;
  aspect-ratio: 21 / 9;
  object-fit: cover;
  display: block;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  padding: 0.8rem 1.7rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.2s, background 0.2s, border-color 0.2s;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 30px var(--accent-glow);
}

.btn-ghost {
  color: var(--text);
  border: 1px solid var(--surface-edge);
}

.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-lg { padding: 1rem 2.4rem; font-size: 1.1rem; }

/* ---------- Sections ---------- */

.section { padding: clamp(4rem, 9vh, 7rem) 0; }

.section-alt {
  background: var(--bg-alt);
  border-block: 1px solid var(--surface-edge);
}

/* ---------- Cards ---------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.2rem;
  margin-top: 2.5rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--surface-edge);
  border-radius: var(--radius);
  padding: 1.8rem;
  transition: transform 0.2s, border-color 0.2s;
}

.card:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
}

.card-icon { font-size: 1.8rem; margin-bottom: 0.9rem; }

.card p { color: var(--text-dim); font-size: 0.95rem; }

/* ---------- Split (Why) ---------- */

.split {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.split-text > p { color: var(--text-dim); margin-top: 1rem; }

.checklist {
  list-style: none;
  margin-top: 1.8rem;
  display: grid;
  gap: 0.9rem;
}

.checklist li {
  color: var(--text-dim);
  padding-left: 1.9rem;
  position: relative;
}

.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--accent);
  font-weight: 700;
}

.checklist strong { color: var(--text); }

/* ---------- Terminal visual ---------- */

.terminal {
  background: #0d1117;
  border: 1px solid var(--surface-edge);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  font-family: var(--mono);
  font-size: 0.85rem;
}

.terminal-bar {
  display: flex;
  gap: 7px;
  padding: 0.7rem 1rem;
  background: var(--surface);
  border-bottom: 1px solid var(--surface-edge);
}

.terminal-bar span {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--surface-edge);
}

.terminal-bar span:first-child { background: #ff5f57; }
.terminal-bar span:nth-child(2) { background: #febc2e; }
.terminal-bar span:nth-child(3) { background: #28c840; }

.terminal-body { padding: 1.2rem 1.3rem 1.4rem; display: grid; gap: 0.45rem; }

.t-prompt { color: var(--accent); }
.t-dim { color: var(--text-dim); }
.t-ok { color: var(--accent); }

.t-cursor {
  animation: blink 1.1s steps(1) infinite;
  color: var(--accent);
}

@keyframes blink { 50% { opacity: 0; } }

/* ---------- About facts ---------- */

.about-facts {
  list-style: none;
  display: grid;
  gap: 1rem;
}

.about-facts li {
  background: var(--surface);
  border: 1px solid var(--surface-edge);
  border-radius: var(--radius);
  padding: 1.1rem 1.4rem;
  display: flex;
  flex-direction: column;
}

.about-facts strong { font-size: 1.05rem; }
.about-facts span { color: var(--text-dim); font-size: 0.9rem; }

/* ---------- Work / Portfolio ---------- */

.work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.2rem;
  margin-top: 2.5rem;
}

.work-shot {
  background: var(--surface);
  border: 1px solid var(--surface-edge);
  border-radius: var(--radius);
  overflow: hidden;
  margin: 0;
  transition: transform 0.2s, border-color 0.2s;
}

.work-shot:hover { transform: translateY(-4px); border-color: var(--accent); }

.work-shot img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: top;
  display: block;
  border-bottom: 1px solid var(--surface-edge);
}

.work-shot figcaption {
  padding: 1.1rem 1.3rem 1.3rem;
  font-size: 0.9rem;
  color: var(--text-dim);
}

.work-shot figcaption strong { color: var(--text); display: block; margin-bottom: 0.2rem; }

.work-shot figcaption a { color: var(--accent); text-decoration: none; }
.work-shot figcaption a:hover { text-decoration: underline; }

.work-list {
  list-style: none;
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 0.7rem 2rem;
}

.work-list li {
  color: var(--text-dim);
  font-size: 0.92rem;
  padding-left: 1.2rem;
  position: relative;
}

.work-list li::before {
  content: "⟁";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-size: 0.75rem;
  top: 0.15rem;
}

.work-list strong { color: var(--text); }

/* ---------- Steps ---------- */

.steps {
  list-style: none;
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.2rem;
  margin-top: 2.5rem;
}

.step {
  background: var(--surface);
  border: 1px solid var(--surface-edge);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
}

.step-photo {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
  border-bottom: 1px solid var(--surface-edge);
}

.step-body {
  padding: 1.5rem 1.8rem 1.8rem;
}

.step-num {
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--accent);
  display: inline-block;
  margin-bottom: 0.8rem;
  background: var(--accent-soft);
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
}

.step p { color: var(--text-dim); font-size: 0.95rem; }

/* ---------- Contact ---------- */

.contact { text-align: center; }

.contact-inner .section-sub { margin-inline: auto; margin-bottom: 2.2rem; }

.contact-note {
  margin-top: 1.6rem;
  color: var(--text-dim);
  font-size: 0.95rem;
}

.contact-note a { color: var(--accent); text-decoration: none; }
.contact-note a:hover { text-decoration: underline; }

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--surface-edge);
  padding: 2.2rem 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.site-footer p { color: var(--text-dim); font-size: 0.9rem; }

/* ---------- Blog & Articles ---------- */

.page-hero {
  padding: clamp(3rem, 8vh, 5rem) 0 clamp(2rem, 5vh, 3rem);
  text-align: center;
}

.breadcrumbs {
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-bottom: 1.2rem;
}

.breadcrumbs a { color: var(--accent); text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }

.post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.2rem;
  margin: 2.5rem 0 4rem;
}

.post-card {
  background: var(--surface);
  border: 1px solid var(--surface-edge);
  border-radius: var(--radius);
  padding: 1.6rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--text);
  transition: transform 0.2s, border-color 0.2s;
}

.post-card:hover { transform: translateY(-4px); border-color: var(--accent); }

.post-card h2, .post-card h3 { font-size: 1.15rem; line-height: 1.3; }

.post-card p { color: var(--text-dim); font-size: 0.92rem; flex: 1; }

.post-meta {
  font-size: 0.8rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.post-meta .tag { color: var(--accent); }

.article {
  max-width: 720px;
  margin-inline: auto;
  padding: clamp(2.5rem, 6vh, 4rem) 0 4rem;
}

.article h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin-bottom: 0.8rem; }

.article .post-meta { margin-bottom: 2.2rem; }

.article-body { font-size: 1.05rem; }

.article-body h2 {
  font-size: 1.45rem;
  margin: 2.4rem 0 0.8rem;
}

.article-body h3 { font-size: 1.15rem; margin: 1.8rem 0 0.6rem; }

.article-body p { margin-bottom: 1.1rem; color: #c6d0da; }

.article-body ul, .article-body ol {
  margin: 0 0 1.1rem 1.4rem;
  color: #c6d0da;
}

.article-body li { margin-bottom: 0.45rem; }

.article-body strong { color: var(--text); }

.article-body a { color: var(--accent); }

.article-body blockquote {
  border-left: 3px solid var(--accent);
  padding: 0.4rem 0 0.4rem 1.2rem;
  margin: 1.5rem 0;
  color: var(--text-dim);
  font-style: italic;
}

.article-cta {
  margin-top: 3rem;
  background: var(--surface);
  border: 1px solid var(--surface-edge);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
}

.article-cta h2 { font-size: 1.3rem; margin-bottom: 0.5rem; }
.article-cta p { color: var(--text-dim); margin-bottom: 1.2rem; }

/* ---------- FAQ ---------- */

.faq-list {
  max-width: 760px;
  margin: 2.5rem auto 0;
  display: grid;
  gap: 0.8rem;
}

.faq-list details {
  background: var(--surface);
  border: 1px solid var(--surface-edge);
  border-radius: var(--radius);
  padding: 1.1rem 1.4rem;
}

.faq-list summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.faq-list summary::after {
  content: "+";
  color: var(--accent);
  font-size: 1.3rem;
  flex-shrink: 0;
}

.faq-list details[open] summary::after { content: "–"; }

.faq-list details p { color: var(--text-dim); margin-top: 0.8rem; }

/* ---------- Footer nav ---------- */

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.4rem;
  list-style: none;
  padding: 0;
  margin: 0.8rem 0 0;
}

.footer-links a {
  color: var(--text-dim);
  font-size: 0.85rem;
  text-decoration: none;
}

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

/* ---------- Reveal animation ---------- */

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Mobile ---------- */

@media (max-width: 760px) {
  .nav-toggle { display: flex; }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--bg-alt);
    border-bottom: 1px solid var(--surface-edge);
    display: none;
    padding: 0.5rem 0 1rem;
  }

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

  .nav-links li { text-align: center; }

  .nav-links a {
    display: block;
    padding: 0.9rem 0;
    font-size: 1.05rem;
  }

  .nav-links .nav-cta {
    margin: 0.5rem 1.5rem 0;
    border-radius: var(--radius);
  }

  .split { grid-template-columns: 1fr; }

  .hero-stats { gap: 1.2rem 2rem; }
}
