:root {
  --bg: #0e0e0e;
  --surface: #161616;
  --border: #2a2a2a;
  --text: #e8e4dc;
  --muted: #6b6760;
  --accent: #c8a96e;
  --accent-dim: #7a6340;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'IBM Plex Sans', sans-serif;
  font-weight: 300;
  line-height: 1.7;
  min-height: 100vh;
}

/* GRAIN OVERLAY */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 1000;
  opacity: 0.4;
}

/* LAYOUT */
.container {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* HEADER */
header {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border);
  animation: fadeUp 0.6s ease both;
}

.wordmark {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
}

.wordmark span {
  color: var(--muted);
}

.tagline {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  color: var(--accent);
  margin-top: 0.5rem;
  opacity: 0.85;
}

/* HERO */
.hero {
  padding: 4rem 0 3rem;
  border-bottom: 1px solid var(--border);
  animation: fadeUp 0.6s ease 0.1s both;
}

.hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
  color: var(--text);
}

.hero h1 em {
  font-style: italic;
  color: var(--accent);
}

.hero .bio {
  font-size: 1.05rem;
  color: var(--muted);
  max-width: 560px;
  line-height: 1.75;
}

.hero .bio strong {
  color: var(--text);
  font-weight: 500;
}

/* JOURNAL SECTION */
.section-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-dim);
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.journal {
  padding: 3.5rem 0;
  border-bottom: 1px solid var(--border);
  animation: fadeUp 0.6s ease 0.2s both;
}

.post-meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  margin-bottom: 1.5rem;
}

.post-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 2rem;
  color: var(--text);
}

.post-body {
  font-size: 0.98rem;
  color: #c8c4bc;
  line-height: 1.85;
}

.post-body p {
  margin-bottom: 1.2rem;
}

.post-body p:last-child {
  margin-bottom: 0;
}

.post-body .lesson {
  border-left: 2px solid var(--accent-dim);
  padding-left: 1.25rem;
  margin: 1.5rem 0;
  color: var(--text);
}

.post-body .lesson strong {
  font-family: 'IBM Plex Sans', sans-serif;
  font-weight: 500;
  color: var(--accent);
  display: block;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}

.tags {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.68rem;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 0.25rem 0.6rem;
  border-radius: 2px;
  letter-spacing: 0.05em;
}

/* COMING SOON */
.coming-soon {
  padding: 3.5rem 0;
  border-bottom: 1px solid var(--border);
  animation: fadeUp 0.6s ease 0.3s both;
}

.coming-soon p {
  font-size: 1rem;
  color: var(--muted);
  max-width: 520px;
  line-height: 1.75;
}

.coming-soon p strong {
  color: var(--text);
  font-weight: 500;
}

/* EMAIL CAPTURE */
.subscribe {
  padding: 3.5rem 0;
  animation: fadeUp 0.6s ease 0.4s both;
}

.subscribe p {
  font-size: 0.95rem;
  color: var(--muted);
  margin-bottom: 1.5rem;
  max-width: 480px;
}

.email-form {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.email-form input {
  flex: 1;
  min-width: 220px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 0.9rem;
  padding: 0.75rem 1rem;
  outline: none;
  border-radius: 2px;
  transition: border-color 0.2s;
}

.email-form input::placeholder { color: var(--muted); }
.email-form input:focus { border-color: var(--accent-dim); }

.email-form button {
  background: var(--accent);
  color: #0e0e0e;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 2px;
  cursor: pointer;
  transition: opacity 0.2s;
  white-space: nowrap;
}

.email-form button:hover { opacity: 0.85; }

.subscribe-note {
  margin-top: 0.75rem;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.05em;
}

.success-msg, .error-msg {
  display: none;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  margin-top: 1rem;
}

.success-msg {
  color: var(--accent);
}

.error-msg {
  color: #d87c7c;
}

/* FOOTER */
footer {
  padding: 2rem 0;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  animation: fadeUp 0.6s ease 0.5s both;
}

footer p {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.08em;
}

footer .copyright {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
}

footer .copyright span {
  color: var(--muted);
}

footer a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}

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

/* ANIMATIONS */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* RESPONSIVE */
@media (max-width: 480px) {
  .container { padding: 0 1.25rem; }
  .hero { padding: 2.5rem 0 2rem; }
  .email-form { flex-direction: column; }
  .email-form input, .email-form button { width: 100%; }
}
