
:root {
  --bg: #f5f5f7;
  --surface: rgba(255,255,255,0.72);
  --surface-solid: #ffffff;
  --text: #111827;
  --muted: #6b7280;
  --border: rgba(17, 24, 39, 0.08);
  --primary: #111111;
  --accent: #2563eb;

  --radius: 24px;
  --radius-lg: 38px;

  --shadow-sm: 0 8px 30px rgba(0,0,0,0.06);
  --shadow-lg: 0 30px 80px rgba(0,0,0,0.12);

  --transition: all .35s cubic-bezier(.4,0,.2,1);
}

[data-theme="dark"] {
  --bg: #09090b;
  --surface: rgba(18,18,20,0.75);
  --surface-solid: #111214;
  --text: #f5f5f7;
  --muted: rgba(255,255,255,.62);
  --border: rgba(255,255,255,.08);
  --primary: #ffffff;
  --accent: #60a5fa;

  --shadow-sm: 0 10px 40px rgba(0,0,0,.4);
  --shadow-lg: 0 40px 100px rgba(0,0,0,.7);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: min(1280px, calc(100% - 48px));
  margin-inline: auto;
}

/* BACKGROUND */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at top left, rgba(59,130,246,.12), transparent 30%),
    radial-gradient(circle at bottom right, rgba(168,85,247,.12), transparent 35%);
  pointer-events: none;
  z-index: -1;
}

/* NAVBAR */
.header {
  position: sticky;
  top: 0;
  z-index: 999;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.nav {
  height: 84px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo a {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -.04em;
}

.nav-links {
  display: flex;
  gap: 36px;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  position: relative;
  transition: var(--transition);
}

.nav-links a:hover {
  color: var(--text);
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -8px;
  width: 0;
  height: 2px;
  border-radius: 10px;
  background: var(--text);
  transition: var(--transition);
}

.nav-links a:hover::after {
  width: 100%;
}

.theme-toggle,
#menuBtn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.06);
  color: var(--text);
  cursor: pointer;
  transition: var(--transition);
}

.theme-toggle:hover,
#menuBtn:hover {
  transform: translateY(-2px);
}

#menuBtn {
  display: none;
}

/* MOBILE MENU */
.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 18px;
  padding: 24px;
  margin-top: 12px;
  border-radius: 24px;
  background: var(--surface);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border);
}

.mobile-menu.show {
  display: flex;
}

.mobile-menu a {
  color: var(--text);
  text-decoration: none;
  font-size: 1.05rem;
}

/* HERO */
.hero {
  min-height: calc(100vh - 84px);
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 70px;
  align-items: center;
  padding: 80px 0;
}

.hero-content span {
  display: inline-flex;
  align-items: center;
  padding: 10px 18px;
  border-radius: 999px;
  background: rgba(255,255,255,.5);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: .82rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.hero-content h1 {
  font-size: clamp(3rem, 7vw, 6rem);
  line-height: .95;
  letter-spacing: -.06em;
  margin: 24px 0;
  max-width: 760px;
}

.hero-content h1 a {
  color: var(--text);
  text-decoration: none;
}

.hero-content p {
  font-size: 1.15rem;
  color: var(--muted);
  line-height: 1.9;
  max-width: 620px;
}

.hero-btn {
  margin-top: 34px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  width: fit-content;
  padding: 16px 26px;
  border-radius: 999px;
  background: var(--primary);
  color: white !important;
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition);
}

.hero-btn:hover {
  transform: translateY(-4px);
}

/* DARK MODE FIX */

[data-theme="dark"] .hero-btn {
  background: #ffffff;
  color: #000 !important;
}

[data-theme="dark"] .hero-btn:hover {
  color: #000 !important;
}

.hero-image {
  position: relative;
}

.hero-image::before {
  content: "";
  position: absolute;
  inset: -30px;
  background: linear-gradient(135deg, rgba(59,130,246,.2), rgba(168,85,247,.18));
  filter: blur(80px);
  z-index: -1;
}

.hero-image img {
  width: 100%;
  height: 720px;
  object-fit: cover;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  transition: transform .8s ease;
}

.hero-image:hover img {
  transform: scale(1.03);
}

/* SECTION */
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 80px 0 40px;
}

.section-heading h2 {
  font-size: clamp(2rem, 4vw, 3.4rem);
  letter-spacing: -.05em;
}

.section-heading p {
  color: var(--muted);
}

/* POSTS */
.posts {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 28px;
  margin-bottom: 120px;
}

.card {
  grid-column: span 4;
  position: relative;
  overflow: hidden;
  border-radius: 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(20px);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-lg);
}

.card img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  transition: transform .8s ease;
}

.card:hover img {
  transform: scale(1.08);
}

.card-content {
  padding: 28px;
}

.card-content span {
  display: inline-flex;
  margin-bottom: 18px;
  color: var(--accent);
  font-size: .85rem;
  font-weight: 600;
}

.card-content h3 {
  font-size: 1.6rem;
  line-height: 1.25;
  margin-bottom: 16px;
}

.card-content h3 a {
  text-decoration: none;
  color: var(--text);
}

.card-content p {
  color: var(--muted);
  line-height: 1.8;
  margin-bottom: 22px;
}

.read-more {
  color: var(--text);
  font-weight: 600;
  text-decoration: none;
}

/* FOOTER */
.footer {
  padding: 80px 0;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--muted);
  backdrop-filter: blur(20px);
}

/* PAGE ANIMATION */
body.page-enter {
  opacity: 0;
  transform: translateY(12px);
}

body.page-exit {
  opacity: 0;
  transform: translateY(20px);
}

body {
  transition: opacity .35s ease, transform .35s ease;
}

/* SCROLL ANIMATION */
.reveal {
  opacity: 0;
  transform: translateY(60px);
  transition: 1s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* ARTICLE PAGE */
.article-page {
  width: min(900px, calc(100% - 40px));
  margin: 80px auto;
}

.article-hero img {
  width: 100%;
  height: 580px;
  object-fit: cover;
  border-radius: 38px;
  margin-bottom: 40px;
  box-shadow: var(--shadow-lg);
}

.article-content h1 {
  font-size: clamp(3rem, 5vw, 5rem);
  line-height: 1;
  margin-bottom: 26px;
  letter-spacing: -.06em;
}

.article-content p {
  font-size: 1.15rem;
  line-height: 2;
  color: var(--muted);
  margin-bottom: 28px;
}

body.page-exit {
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
}

body.page-enter {
  opacity: 0;
  transform: translateY(10px);
}

body {
  opacity: 1;
}

/* RESPONSIVE */
@media (max-width: 1100px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .card {
    grid-column: span 6;
  }
}

@media (max-width: 768px) {

  .container {
    width: min(100% - 28px, 100%);
  }

  .nav-links {
    display: none;
  }

  #menuBtn {
    display: block;
  }

  .hero {
    min-height: auto;
    padding: 50px 0 20px;
    gap: 40px;
  }

  .hero-image img {
    height: 420px;
  }

  .hero-content p {
    font-size: 1rem;
  }

  .posts {
    grid-template-columns: 1fr;
  }

  .card {
    grid-column: span 1;
  }

  .card-content {
    padding: 22px;
  }

  .article-hero img {
    height: 320px;
  }
}


