/*
Theme Name: Custom Auto Theme
Author: System
Version: 1.0
*/

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

:root {
  --bg: #07080d;
  --surface: #0e1018;
  --card: #151722;
  --card-hover: #1a1d2e;
  --border: #22253a;
  --accent: #00e0a1;
  --accent-dim: rgba(0,224,161,0.12);
  --accent2: #6c5ce7;
  --accent2-dim: rgba(108,92,231,0.12);
  --text: #e2e4f0;
  --text-muted: #7a7d96;
  --text-dim: #4a4d66;
  --white: #ffffff;
  --font-display: 'Space Mono', monospace;
  --font-body: 'Outfit', sans-serif;
  --max-w: 1200px;
  --radius: 8px;
  --radius-lg: 16px;
  --transition: 0.3s cubic-bezier(0.4,0,0.2,1);
}

html { scroll-behavior: smooth; }
html, body { overflow-x: hidden; }
a { display: inline-block; text-align: center; }

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

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

/* ── GEOMETRIC BG ── */
body::before {
  content: '';
  position: fixed;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background:
    radial-gradient(ellipse 600px 600px at 20% 20%, rgba(0,224,161,0.04) 0%, transparent 70%),
    radial-gradient(ellipse 500px 500px at 80% 80%, rgba(108,92,231,0.04) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.site-wrap { position: relative; z-index: 1; }

/* ── HEADER ── */
.site-header {
  padding: 1.2rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
  background: rgba(7,8,13,0.85);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 100;
}
.site-logo {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: -0.5px;
}
.site-logo span { color: var(--text-muted); font-weight: 400; }
.site-nav { display: flex; gap: 0.3rem; align-items: center; }
.site-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.85rem;
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius);
  transition: var(--transition);
  font-weight: 500;
}
.site-nav a:hover { color: var(--accent); background: var(--accent-dim); }
.nav-toggle { display: none; background: none; border: none; color: var(--text); cursor: pointer; font-size: 1.4rem; }

@media(max-width:768px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: fixed; top: 0; right: -100%; width: 70vw; height: 100vh;
    flex-direction: column; background: var(--surface); padding: 5rem 2rem 2rem;
    transition: right 0.4s ease; gap: 0.5rem; z-index: 200;
    border-left: 1px solid var(--border);
  }
  .site-nav.open { right: 0; }
  .site-nav a { font-size: 1.1rem; text-align: left; padding: 0.8rem 1rem; width: 100%; }
  .nav-close { position: absolute; top: 1.2rem; right: 1.5rem; background: none; border: none; color: var(--text-muted); font-size: 1.6rem; cursor: pointer; display: block !important; }
  .site-header { padding: 1rem 1.2rem; }
}

/* ── BREADCRUMBS ── */
.breadcrumbs {
  padding: 1rem 0;
  font-size: 0.82rem;
  color: var(--text-dim);
  display: flex;
  gap: 0.4rem;
  align-items: center;
  flex-wrap: wrap;
}
.breadcrumbs a { color: var(--text-muted); text-decoration: none; transition: var(--transition); }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs .sep { color: var(--text-dim); }

/* ── CONTAINER ── */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 2rem; }
@media(max-width:768px) { .container { padding: 0 1.2rem; } }

/* ── HERO ── */
.hero {
  padding: 5rem 0 3rem;
  text-align: center;
  position: relative;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}
.hero-tag {
  font-family: var(--font-display);
  font-size: 0.75rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 3px;
  margin-bottom: 1.2rem;
  display: inline-block;
  background: var(--accent-dim);
  padding: 0.35rem 1rem;
  border-radius: 100px;
}
.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  line-height: 1.25;
  color: var(--white);
  max-width: 800px;
  margin: 0 auto 1.2rem;
}
.hero-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

/* ── ARTICLE LAYOUT ── */
.article-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 3rem;
  padding: 3rem 0;
  align-items: start;
}
@media(max-width:960px) {
  .article-grid { grid-template-columns: 1fr; gap: 2rem; }
}

.article-content h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--white);
  margin: 2.5rem 0 1rem;
  padding-left: 1rem;
  border-left: 3px solid var(--accent);
}
.article-content h3 {
  font-size: 1.1rem;
  color: var(--text);
  margin: 2rem 0 0.8rem;
  font-weight: 600;
}
.article-content p {
  margin-bottom: 1.2rem;
  color: var(--text);
}
.article-content img {
  width: 100%;
  border-radius: var(--radius-lg);
  margin: 1.5rem 0;
  border: 1px solid var(--border);
}

/* ── CALLOUT / QUOTE ── */
.callout {
  background: var(--accent-dim);
  border-left: 3px solid var(--accent);
  padding: 1.2rem 1.5rem;
  border-radius: 0 var(--radius) var(--radius) 0;
  margin: 2rem 0;
  font-style: italic;
  color: var(--text);
}
.callout-purple {
  background: var(--accent2-dim);
  border-left-color: var(--accent2);
}
blockquote {
  border-left: 3px solid var(--accent2);
  margin: 2rem 0;
  padding: 1rem 1.5rem;
  background: var(--accent2-dim);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-style: italic;
}

/* ── SIDEBAR ── */
.sidebar { display: flex; flex-direction: column; gap: 1.5rem; }
.sidebar-box {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: var(--transition);
}
.sidebar-box:hover { border-color: var(--accent); transform: translateY(-2px); }
.sidebar-box h3 {
  font-family: var(--font-display);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--accent);
  margin-bottom: 1rem;
}
.sidebar-box p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }
.sidebar-box ul { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; }
.sidebar-box li { font-size: 0.9rem; color: var(--text-muted); padding-left: 1rem; position: relative; }
.sidebar-box li::before { content: '→'; position: absolute; left: 0; color: var(--accent); }

/* ── DIARY SECTION ── */
.diary-section {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin: 2.5rem 0;
}
.diary-section h2 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--accent);
  margin-bottom: 1.2rem;
  border: none;
  padding-left: 0;
}
.diary-section ol {
  list-style: none;
  counter-reset: diary;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}
.diary-section li {
  counter-increment: diary;
  font-size: 0.95rem;
  color: var(--text);
  padding-left: 2.2rem;
  position: relative;
}
.diary-section li::before {
  content: counter(diary, decimal-leading-zero);
  position: absolute;
  left: 0;
  font-family: var(--font-display);
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 700;
}

/* ── READ ALSO ── */
.read-also {
  margin: 2.5rem 0;
}
.read-also h2 {
  font-family: var(--font-display);
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  margin-bottom: 1.2rem;
  border: none;
  padding-left: 0;
}
.read-also-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}
.read-also-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.3rem;
  text-decoration: none;
  transition: var(--transition);
}
.read-also-card:hover {
  border-color: var(--accent);
  background: var(--card-hover);
  transform: translateY(-3px);
}
.read-also-card .card-tag {
  font-family: var(--font-display);
  font-size: 0.7rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 1px;
}
.read-also-card .card-title {
  font-size: 0.95rem;
  color: var(--white);
  margin-top: 0.5rem;
  font-weight: 600;
  line-height: 1.4;
}
.read-also-card .card-meta {
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-top: 0.6rem;
}

/* ── SUBSCRIBE ── */
.subscribe-section {
  background: linear-gradient(135deg, var(--card) 0%, rgba(108,92,231,0.08) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  margin: 3rem 0;
  text-align: center;
}
.subscribe-section h2 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--white);
  margin-bottom: 0.6rem;
  border: none;
  padding-left: 0;
}
.subscribe-section p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}
.subscribe-form {
  display: flex;
  gap: 0.8rem;
  max-width: 480px;
  margin: 0 auto;
}
.subscribe-form input[type="email"] {
  flex: 1;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.9rem;
  transition: var(--transition);
}
.subscribe-form input[type="email"]:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}
.subscribe-form button {
  background: var(--accent);
  color: var(--bg);
  border: none;
  border-radius: var(--radius);
  padding: 0.75rem 1.5rem;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}
.subscribe-form button:hover { background: #00f5b8; transform: translateY(-1px); }
@media(max-width:500px) { .subscribe-form { flex-direction: column; } }

/* ── FOOTER ── */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 3rem 0;
  margin-top: 3rem;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 2rem;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
}
@media(max-width:768px) { .footer-inner { grid-template-columns: 1fr; gap: 1.5rem; padding: 0 1.2rem; } }
.footer-brand .site-logo { font-size: 1.1rem; margin-bottom: 0.8rem; }
.footer-brand p { font-size: 0.82rem; color: var(--text-dim); line-height: 1.6; }
.footer-col h4 {
  font-family: var(--font-display);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  margin-bottom: 0.8rem;
}
.footer-col a {
  display: block;
  color: var(--text-dim);
  text-decoration: none;
  font-size: 0.85rem;
  padding: 0.3rem 0;
  text-align: left;
  transition: var(--transition);
}
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  max-width: var(--max-w);
  margin: 2rem auto 0;
  padding: 1.5rem 2rem 0;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}
.footer-bottom p { font-size: 0.78rem; color: var(--text-dim); }
.footer-disclaimer {
  font-size: 0.75rem;
  color: var(--text-dim);
  max-width: 600px;
  line-height: 1.5;
  margin-top: 1rem;
  text-align: left;
}

/* ── COOKIE MODAL ── */
.cookie-modal {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  max-width: 380px;
  z-index: 500;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  animation: slideUp 0.5s ease;
}
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.cookie-modal h3 {
  font-family: var(--font-display);
  font-size: 0.9rem;
  color: var(--white);
  margin-bottom: 0.6rem;
}
.cookie-modal p { font-size: 0.82rem; color: var(--text-muted); margin-bottom: 1rem; line-height: 1.5; }
.cookie-btns { display: flex; gap: 0.6rem; }
.cookie-btns button {
  flex: 1;
  padding: 0.55rem 1rem;
  border-radius: var(--radius);
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}
.cookie-accept { background: var(--accent); color: var(--bg); }
.cookie-accept:hover { background: #00f5b8; }
.cookie-decline { background: var(--card); color: var(--text-muted); border: 1px solid var(--border) !important; }
.cookie-decline:hover { border-color: var(--text-muted) !important; color: var(--text); }
@media(max-width:500px) { .cookie-modal { left: 1rem; right: 1rem; max-width: none; } }

/* ── POLICY PAGES ── */
.policy-page { padding: 3rem 0; }
.policy-page h1 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  color: var(--white);
  margin-bottom: 2rem;
}
.policy-page h2 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--accent);
  margin: 2rem 0 0.8rem;
}
.policy-page p, .policy-page li {
  color: var(--text-muted);
  font-size: 0.92rem;
  margin-bottom: 0.8rem;
  line-height: 1.7;
}
.policy-page ul { list-style: none; padding-left: 1.2rem; }
.policy-page ul li::before { content: '—'; color: var(--accent); margin-right: 0.5rem; }

/* ── SUCCESS PAGE ── */
.success-page {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 2rem;
}
.success-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--accent-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2rem;
  font-size: 2rem;
}
.success-page h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  color: var(--white);
  margin-bottom: 1rem;
}
.success-page p { color: var(--text-muted); font-size: 1rem; margin-bottom: 2rem; }
.btn-home {
  background: var(--accent);
  color: var(--bg);
  text-decoration: none;
  padding: 0.8rem 2rem;
  border-radius: var(--radius);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  transition: var(--transition);
}
.btn-home:hover { background: #00f5b8; transform: translateY(-2px); }

/* ── 404 ── */
.page-404 {
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 2rem;
}
.glitch-404 {
  font-family: var(--font-display);
  font-size: clamp(5rem, 15vw, 10rem);
  font-weight: 700;
  color: var(--accent);
  position: relative;
  line-height: 1;
  margin-bottom: 1rem;
}
.page-404 p { color: var(--text-muted); font-size: 1.1rem; margin-bottom: 2rem; }

/* ── ANIMATIONS ── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-in { animation: fadeInUp 0.6s ease both; }
.fade-in-d1 { animation-delay: 0.1s; }
.fade-in-d2 { animation-delay: 0.2s; }
.fade-in-d3 { animation-delay: 0.3s; }

/* ── STAT GRID ── */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}
.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem;
  text-align: center;
  transition: var(--transition);
}
.stat-card:hover { border-color: var(--accent); }
.stat-card .num {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--accent);
}
.stat-card .label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

/* ── TIP BOX ── */
.tip-box {
  display: flex;
  gap: 1rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.3rem;
  margin: 1.5rem 0;
  align-items: flex-start;
}
.tip-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}
.tip-box p { font-size: 0.9rem; color: var(--text); margin: 0; }
