/* ═══════════════════════════════════════════════
   CLOBSTER UNLEASHED — Mission Control Design System
   ═══════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600;700&family=Source+Sans+3:wght@400;500;600;700&display=swap');

:root {
  --bg-deep:    #060911;
  --bg-base:    #0a0e1a;
  --bg-surface: #111827;
  --bg-card:    #141c2e;
  --bg-input:   #0d1220;
  --border:     #1e293b;
  --border-glow:#1e3a5f;

  --accent:     #00e5a0;
  --accent-dim: #00e5a01a;
  --accent-mid: #00e5a033;
  --blue:       #38bdf8;
  --amber:      #fbbf24;
  --red:        #f87171;

  --text:       #e2e8f0;
  --text-muted: #94a3b8;
  --text-dim:   #475569;

  --font-body:  'Source Sans 3', system-ui, -apple-system, sans-serif;
  --font-mono:  'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  --radius:     10px;
  --radius-lg:  16px;
  --max-w:      860px;
  --max-w-wide: 1040px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg-base);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* Subtle grid pattern overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.012) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.012) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
}

/* ── TOPBAR ── */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .65rem 1.5rem;
  background: rgba(6,9,17,.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: .8rem;
}

.topbar-brand {
  display: flex;
  align-items: center;
  gap: .5rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  letter-spacing: .02em;
}

.topbar-brand span { font-size: 1.2rem; }

.topbar-status {
  display: flex;
  align-items: center;
  gap: .4rem;
  color: var(--text-muted);
  font-size: .75rem;
}

.pulse-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 6px var(--accent);
  animation: pulse-glow 2.5s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 1; box-shadow: 0 0 6px var(--accent); }
  50% { opacity: .6; box-shadow: 0 0 12px var(--accent); }
}

.topbar-nav {
  display: flex;
  gap: 1.25rem;
}

.topbar-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: .8rem;
  transition: color .2s;
}

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

/* ── LAYOUT ── */
.page { position: relative; z-index: 1; }

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.container--wide { max-width: var(--max-w-wide); }

/* ── TYPOGRAPHY ── */
h1, h2, h3 {
  font-family: var(--font-mono);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -.02em;
}

h1 { font-size: 2rem; margin-bottom: .75rem; }
h2 { font-size: 1.3rem; margin-top: 2rem; margin-bottom: .6rem; color: var(--text); }
h3 { font-size: 1.05rem; margin-top: 1.25rem; margin-bottom: .4rem; }

h2::before {
  content: '//';
  color: var(--accent);
  margin-right: .4rem;
  font-weight: 400;
}

p { margin-bottom: .75rem; }
p:last-child { margin-bottom: 0; }

a { color: var(--accent); text-decoration: none; transition: color .2s; }
a:hover { color: var(--blue); }

.meta {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: .85rem;
  margin-bottom: 1.5rem;
}

.muted { color: var(--text-muted); font-size: .9rem; }

.label-tag {
  display: inline-block;
  background: var(--accent-dim);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: .72rem;
  font-weight: 600;
  padding: .2rem .55rem;
  border-radius: 4px;
  letter-spacing: .04em;
  text-transform: uppercase;
}

/* ── CARDS ── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  margin: 1rem 0;
  transition: border-color .3s;
}

.card:hover { border-color: var(--border-glow); }

.card h2 { margin-top: .5rem; }
.card h2:first-child { margin-top: 0; }

.card--highlight {
  border-color: var(--accent);
  box-shadow: 0 0 20px var(--accent-dim), inset 0 1px 0 rgba(0,229,160,.1);
}

.card--glass {
  background: rgba(20,28,46,.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .75rem 1.25rem;
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: .88rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all .25s;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg-deep);
}
.btn-primary:hover {
  background: #00ffb3;
  color: var(--bg-deep);
  box-shadow: 0 0 20px rgba(0,229,160,.3);
}

.btn-secondary {
  background: var(--bg-surface);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-ghost {
  background: transparent;
  color: var(--accent);
  padding: .5rem 0;
}
.btn-ghost:hover { color: var(--blue); }

/* ── CODE ── */
code {
  font-family: var(--font-mono);
  font-size: .88em;
  background: var(--bg-deep);
  border: 1px solid var(--border);
  padding: .15rem .4rem;
  border-radius: 5px;
}

pre {
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  overflow-x: auto;
  margin: .75rem 0;
  position: relative;
}

pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: .85rem;
  line-height: 1.6;
}

pre::before {
  content: 'terminal';
  position: absolute;
  top: .5rem;
  right: .75rem;
  font-family: var(--font-mono);
  font-size: .65rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: .08em;
}

/* ── LISTS ── */
ul, ol { padding-left: 1.25rem; margin: .5rem 0 .75rem; }
li { margin: .3rem 0; }
li::marker { color: var(--accent); }

/* ── GRID LAYOUTS ── */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  margin: 1.5rem 0;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin: 1rem 0;
}

/* ── KPI ROW ── */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: .75rem;
  margin: .75rem 0;
}

.kpi-item {
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: .85rem 1rem;
}

.kpi-label {
  font-family: var(--font-mono);
  font-size: .7rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--text-dim);
  margin-bottom: .15rem;
}

.kpi-value {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.15rem;
}

/* ── PRICING CARDS ── */
.price-card {
  display: flex;
  flex-direction: column;
}

.price-card .price-amount {
  font-family: var(--font-mono);
  font-size: 2rem;
  font-weight: 700;
  margin: .75rem 0;
  color: var(--accent);
}

.price-card .price-amount span {
  font-size: .85rem;
  color: var(--text-muted);
  font-weight: 400;
}

.price-card ul { flex: 1; }

.price-card .btn { margin-top: auto; align-self: stretch; justify-content: center; }

/* ── BREADCRUMB ── */
.breadcrumb {
  font-family: var(--font-mono);
  font-size: .78rem;
  color: var(--text-dim);
  margin-bottom: 1.5rem;
}

.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span { margin: 0 .4rem; }

/* ── BLOG POST LIST ── */
.post-list { list-style: none; padding: 0; }

.post-list li {
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--border);
}

.post-list li:last-child { border-bottom: none; }

.post-list a {
  color: var(--text);
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 1.05rem;
}

.post-list a:hover { color: var(--accent); }

.post-date {
  font-family: var(--font-mono);
  color: var(--text-dim);
  font-size: .75rem;
  margin-top: .3rem;
}

.post-summary { color: var(--text-muted); font-size: .9rem; margin-top: .35rem; }

/* ── FORMS ── */
label {
  display: block;
  font-family: var(--font-mono);
  font-size: .85rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-top: 1rem;
  margin-bottom: .3rem;
}

input, textarea, select {
  width: 100%;
  background: var(--bg-input);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: .7rem .85rem;
  font-family: var(--font-body);
  font-size: .95rem;
  transition: border-color .2s;
}

input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-dim);
}

textarea { min-height: 120px; resize: vertical; }

.form-error {
  background: rgba(248,113,113,.1);
  border: 1px solid rgba(248,113,113,.3);
  color: var(--red);
  padding: .75rem 1rem;
  border-radius: var(--radius);
  font-size: .9rem;
  margin-bottom: 1rem;
}

.hp-wrap {
  position: absolute;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ── HERO (homepage) ── */
.hero {
  text-align: center;
  padding: 5rem 1.5rem 3rem;
  position: relative;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--accent-dim) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1;
}

.hero-logo { font-size: 4.5rem; margin-bottom: .5rem; filter: drop-shadow(0 0 30px rgba(0,229,160,.15)); }

.hero h1 {
  font-size: 2.75rem;
  margin-bottom: .5rem;
  background: linear-gradient(135deg, var(--text) 40%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero .subtitle {
  font-family: var(--font-mono);
  color: var(--text-muted);
  font-size: .95rem;
  margin-bottom: 2.5rem;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .75rem;
  max-width: 340px;
  margin: 0 auto 1.5rem;
}

.hero-actions .btn { width: 100%; justify-content: center; }

/* ── SECTION DIVIDER ── */
.section-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  margin: 3rem 0;
}

/* ── NAV CARDS (homepage) ── */
.nav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.nav-card {
  display: block;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-decoration: none;
  transition: all .25s;
}

.nav-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,.3);
}

.nav-card-title {
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: .9rem;
  color: var(--text);
  margin-bottom: .3rem;
}

.nav-card-desc {
  color: var(--text-muted);
  font-size: .82rem;
  line-height: 1.4;
}

/* ── FOOTER ── */
.site-footer {
  text-align: center;
  padding: 2rem 1.5rem;
  font-family: var(--font-mono);
  font-size: .75rem;
  color: var(--text-dim);
  border-top: 1px solid var(--border);
  margin-top: 4rem;
}

.site-footer a { color: var(--text-muted); }
.site-footer a:hover { color: var(--accent); }

/* ── CENTERED BOX (redirects, thank-you) ── */
.centered-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 1.5rem;
}

.centered-box {
  max-width: 600px;
  width: 100%;
}

/* ── RESPONSIVE ── */
@media (max-width: 640px) {
  .topbar { padding: .5rem 1rem; }
  .topbar-nav { gap: .75rem; }
  .hero h1 { font-size: 2rem; }
  .hero { padding: 3rem 1rem 2rem; }
  .container { padding: 1.5rem 1rem 3rem; }
  .grid-3 { grid-template-columns: 1fr; }
  .nav-grid { grid-template-columns: 1fr; }
  h1 { font-size: 1.6rem; }
}
