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

/* ===== RESET & BASE ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg-primary: #0b100e;
  --bg-secondary: #111a15;
  --bg-card: #162119;
  --bg-card-hover: #1d2b22;
  --text-primary: #e4e8e5;
  --text-secondary: #97a89c;
  --text-muted: #5e6f63;
  --accent: #2d6a4f;
  --accent-hover: #40916c;
  --accent-glow: rgba(45, 106, 79, 0.18);
  --border: #243029;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  --max-width: 1100px;
  --transition: 0.25s ease;
}

html { scroll-behavior: smooth; }

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

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

img { max-width: 100%; display: block; }

/* ===== NAVIGATION ===== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 16, 14, 0.88);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 0 2rem;
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-logo {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

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

.nav-links { display: flex; gap: 2rem; list-style: none; }

.nav-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: color var(--transition);
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition);
}

.nav-links a:hover,
.nav-links a.active { color: var(--text-primary); }
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }

/* Mobile hamburger */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 4px; }
.nav-toggle span {
  display: block; width: 22px; height: 2px;
  background: var(--text-primary); margin: 5px 0;
  transition: var(--transition);
}

/* ===== HERO ===== */
.hero {
  padding: 6rem 2rem 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  pointer-events: none;
}

.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 1rem;
}

.hero h1 .accent { color: var(--accent); }

.hero .subtitle {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto 2rem;
  line-height: 1.6;
}

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

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.6rem;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all var(--transition);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: var(--accent-hover);
  color: #fff;
  box-shadow: 0 4px 20px var(--accent-glow);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ===== SECTIONS ===== */
.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 4rem 2rem;
}

.section-header {
  margin-bottom: 2.5rem;
}

.section-header h2 {
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1rem;
}

.section-divider {
  width: 40px;
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
  margin-top: 0.75rem;
}

/* ===== CARDS (for blog posts, projects, books) ===== */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.75rem;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

.card-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-bottom: 0.75rem;
}

.card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  line-height: 1.3;
}

.card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.6;
}

.card-tag {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  background: var(--accent-glow);
  color: var(--accent);
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-top: 1rem;
}

/* ===== BLOG POST PAGE ===== */
.post-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 3rem 2rem 4rem;
}

.post-content .post-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-bottom: 0.5rem;
}

.post-content h1 {
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin-bottom: 2rem;
}

.post-content h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin: 2rem 0 1rem;
}

.post-content p {
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  font-size: 1.05rem;
}

.post-content blockquote {
  border-left: 3px solid var(--accent);
  padding: 0.75rem 1.25rem;
  margin: 1.5rem 0;
  background: var(--bg-card);
  border-radius: 0 8px 8px 0;
  color: var(--text-secondary);
  font-style: italic;
}

/* ===== PHOTOGRAPHY GRID ===== */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.photo-grid .photo-item {
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 4/3;
  background: var(--bg-card);
  border: 1px solid var(--border);
  position: relative;
  cursor: pointer;
  transition: all var(--transition);
}

.photo-grid .photo-item:hover {
  transform: scale(1.02);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.photo-grid .photo-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ===== ABOUT PAGE ===== */
.about-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 3rem;
  align-items: start;
}

.about-photo {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  overflow: hidden;
}

.about-text h1 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
}

.about-text p {
  color: var(--text-secondary);
  margin-bottom: 1rem;
  font-size: 1.05rem;
}

/* ===== BOOK LIST ===== */
.book-item {
  display: flex;
  gap: 1.5rem;
  padding: 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-bottom: 1rem;
  transition: all var(--transition);
}

.book-item:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent);
}

.book-cover {
  width: 80px;
  height: 120px;
  border-radius: 6px;
  background: var(--bg-secondary);
  flex-shrink: 0;
}

.book-info h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.book-info .author {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}

.book-info p {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* ===== FOOTER ===== */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
  padding: 2rem;
  text-align: center;
  background: var(--bg-secondary);
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.footer-inner p {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.disclosure-toggle {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.8rem;
  cursor: pointer;
  margin-top: 0.75rem;
  transition: color var(--transition);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.disclosure-toggle:hover { color: var(--text-secondary); }

.disclosure-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
  text-align: left;
  margin-top: 1rem;
}

.disclosure-content.open { max-height: 1000px; }

.disclosure-content p {
  color: var(--text-muted);
  font-size: 0.75rem;
  line-height: 1.6;
  max-width: 720px;
  margin: 0 auto;
  padding: 1rem;
  background: var(--bg-primary);
  border-radius: 8px;
  border: 1px solid var(--border);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border);
    padding: 1rem 2rem;
    gap: 1rem;
  }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; }

  .hero { padding: 4rem 1.5rem 3rem; }
  .section { padding: 3rem 1.5rem; }

  .about-layout {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .about-photo { max-width: 200px; margin: 0 auto; }

  .card-grid { grid-template-columns: 1fr; }
  .photo-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
}

