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

:root {
  --teal: #1B7A6E;
  --teal-dark: #155f56;
  --teal-light: #e6f5f3;
  --ocean: #2E86AB;
  --brown: #8B6914;
  --cream: #FFF8F0;
  --charcoal: #2D2D2D;
  --gray-100: #f7f7f8;
  --gray-200: #e8e8ec;
  --gray-300: #d1d1d8;
  --gray-500: #71717a;
  --gray-700: #3f3f46;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.1);
  --shadow-xl: 0 20px 60px rgba(0,0,0,0.12);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--charcoal);
  background: #fff;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ===== Utility ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.badge--teal {
  background: var(--teal-light);
  color: var(--teal);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 10px;
  font-size: 0.95rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn--primary {
  background: var(--charcoal);
  color: #fff;
}
.btn--primary:hover {
  background: #1a1a1a;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn--secondary {
  background: var(--gray-100);
  color: var(--charcoal);
  border: 1px solid var(--gray-200);
}
.btn--secondary:hover {
  background: var(--gray-200);
  transform: translateY(-1px);
}

.btn--ghost {
  background: transparent;
  color: var(--charcoal);
  padding: 14px 20px;
}
.btn--ghost:hover {
  background: var(--gray-100);
}

.section-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--teal);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--gray-500);
  max-width: 600px;
  line-height: 1.7;
}

/* ===== Nav ===== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.nav__logo img {
  width: 32px;
  height: 32px;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
}

.nav__links a {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--gray-700);
  transition: all 0.15s ease;
}
.nav__links a:hover {
  background: var(--gray-100);
  color: var(--charcoal);
}

.nav__links a.nav__link--active {
  color: var(--teal);
  background: var(--teal-light);
}

.nav__cta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav__github {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  background: var(--charcoal);
  color: #fff;
  transition: all 0.2s;
}
.nav__github:hover {
  background: #1a1a1a;
}
.nav__github svg { width: 18px; height: 18px; }

.nav__mobile-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

/* ===== Hero ===== */
.hero {
  padding: 140px 0 80px;
  text-align: center;
  overflow: hidden;
}

.hero__badge {
  margin-bottom: 24px;
}

.hero__title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.hero__title .highlight {
  background: linear-gradient(135deg, var(--teal), var(--ocean));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero__subtitle {
  font-size: 1.2rem;
  color: var(--gray-500);
  max-width: 580px;
  margin: 0 auto 36px;
  line-height: 1.7;
}

.hero__actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.hero__terminal {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--charcoal);
  color: #a1a1aa;
  padding: 12px 20px;
  border-radius: 10px;
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 0.85rem;
  margin-bottom: 60px;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid rgba(255,255,255,0.1);
}
.hero__terminal:hover {
  border-color: rgba(255,255,255,0.2);
}
.hero__terminal code { color: #e4e4e7; }
.hero__terminal .prompt { color: var(--teal); }
.hero__terminal .copy-hint {
  font-size: 0.75rem;
  color: #52525b;
  margin-left: 12px;
}

.hero__screenshot {
  max-width: 1000px;
  margin: 0 auto;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--gray-200);
}

.hero__screenshot-placeholder {
  background: linear-gradient(135deg, #f0faf9, #e8f4f8);
  aspect-ratio: 16/9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--teal);
  font-weight: 600;
}
.hero__screenshot-placeholder svg { width: 48px; height: 48px; opacity: 0.5; }
.hero__screenshot-placeholder span { opacity: 0.6; font-size: 0.9rem; }

/* ===== Features Grid ===== */
.features {
  padding: 100px 0;
  background: var(--gray-100);
}

.features__header {
  text-align: center;
  margin-bottom: 64px;
}
.features__header .section-subtitle {
  margin: 0 auto;
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 32px;
  border: 1px solid var(--gray-200);
  transition: all 0.2s ease;
}
.feature-card:hover {
  border-color: var(--gray-300);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.feature-card__icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--teal-light);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  font-size: 1.3rem;
}

.feature-card__title {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.feature-card__desc {
  font-size: 0.9rem;
  color: var(--gray-500);
  line-height: 1.6;
}

/* ===== Showcase Sections (alternating) ===== */
.showcase {
  padding: 100px 0;
}
.showcase:nth-child(even) {
  background: var(--gray-100);
}

.showcase__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.showcase__inner--reversed {
  direction: rtl;
}
.showcase__inner--reversed > * {
  direction: ltr;
}

.showcase__content {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.showcase__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.showcase__list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.95rem;
  color: var(--gray-700);
  line-height: 1.6;
}
.showcase__list li svg {
  flex-shrink: 0;
  margin-top: 4px;
  color: var(--teal);
}

.showcase__screenshot {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--gray-200);
}

.showcase__screenshot-placeholder {
  background: linear-gradient(135deg, #f0faf9, #e8f4f8);
  aspect-ratio: 4/3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--teal);
}
.showcase__screenshot-placeholder svg { width: 40px; height: 40px; opacity: 0.4; }
.showcase__screenshot-placeholder span { opacity: 0.5; font-size: 0.85rem; font-weight: 500; }

/* ===== Tech Stack ===== */
.stack {
  padding: 100px 0;
}

.stack__header {
  text-align: center;
  margin-bottom: 64px;
}
.stack__header .section-subtitle { margin: 0 auto; }

.stack__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  max-width: 800px;
  margin: 0 auto;
}

.stack__item {
  text-align: center;
  padding: 28px 20px;
  border-radius: var(--radius);
  border: 1px solid var(--gray-200);
  background: #fff;
  transition: all 0.2s;
}
.stack__item:hover {
  border-color: var(--teal);
  box-shadow: var(--shadow-sm);
}

.stack__item-icon {
  font-size: 1.8rem;
  margin-bottom: 10px;
}

.stack__item-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--charcoal);
}
.stack__item-desc {
  font-size: 0.75rem;
  color: var(--gray-500);
  margin-top: 2px;
}

/* ===== Quick Start ===== */
.quickstart {
  padding: 100px 0;
  background: var(--gray-100);
}

.quickstart__header {
  text-align: center;
  margin-bottom: 48px;
}
.quickstart__header .section-subtitle { margin: 0 auto; }

.quickstart__code {
  max-width: 700px;
  margin: 0 auto;
  background: var(--charcoal);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.quickstart__code-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.quickstart__code-header span {
  width: 12px; height: 12px;
  border-radius: 50%;
}
.quickstart__code-header span:nth-child(1) { background: #ff5f57; }
.quickstart__code-header span:nth-child(2) { background: #febc2e; }
.quickstart__code-header span:nth-child(3) { background: #28c840; }

.quickstart__code pre {
  padding: 24px;
  overflow-x: auto;
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: 0.85rem;
  line-height: 1.8;
  color: #d4d4d8;
}

.quickstart__code pre .comment { color: #6b7280; }
.quickstart__code pre .command { color: #e4e4e7; }
.quickstart__code pre .prompt { color: #34d399; }
.quickstart__code pre .flag { color: #93c5fd; }
.quickstart__code pre .url { color: #fbbf24; }

/* ===== Community ===== */
.community {
  padding: 100px 0;
}

.community__inner {
  text-align: center;
}

.community__links {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-top: 36px;
  flex-wrap: wrap;
}

.community__link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 28px;
  border-radius: var(--radius);
  border: 1px solid var(--gray-200);
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.2s;
  background: #fff;
}
.community__link:hover {
  border-color: var(--teal);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.community__link svg { width: 22px; height: 22px; }

/* ===== CTA ===== */
.cta {
  padding: 100px 0;
  background: var(--charcoal);
  color: #fff;
  text-align: center;
}

.cta .section-label { color: #34d399; }
.cta .section-title { color: #fff; }
.cta .section-subtitle {
  color: #a1a1aa;
  margin: 0 auto 36px;
}

.cta__actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.cta .btn--primary {
  background: #fff;
  color: var(--charcoal);
}
.cta .btn--primary:hover {
  background: #f4f4f5;
}

.cta .btn--ghost {
  color: #a1a1aa;
}
.cta .btn--ghost:hover {
  background: rgba(255,255,255,0.08);
  color: #fff;
}

/* ===== Footer ===== */
.footer {
  padding: 40px 0;
  border-top: 1px solid var(--gray-200);
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer__left {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--gray-500);
}
.footer__left img { width: 20px; height: 20px; }

.footer__right {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 0.85rem;
  color: var(--gray-500);
}
.footer__right a:hover { color: var(--charcoal); }

/* ===== Updates List ===== */
.updates {
  padding: 100px 0;
  min-height: calc(100vh - 64px);
}

.updates__header {
  margin-bottom: 64px;
}

.updates__header .section-subtitle {
  margin-top: 4px;
}

.updates__list {
  max-width: 760px;
}

.update-card {
  padding: 32px;
  border-radius: var(--radius);
  border: 1px solid var(--gray-200);
  background: #fff;
  margin-bottom: 20px;
  transition: all 0.2s ease;
}
.update-card:hover {
  border-color: var(--gray-300);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.update-card__date {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--teal);
  margin-bottom: 10px;
}

.update-card__title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.01em;
  line-height: 1.3;
}
.update-card__title a:hover {
  color: var(--teal);
}

.update-card__summary {
  font-size: 0.95rem;
  color: var(--gray-500);
  line-height: 1.7;
  margin-bottom: 16px;
}

.update-card__read-more {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--teal);
  transition: color 0.15s;
}
.update-card__read-more:hover {
  color: var(--teal-dark);
}

/* ===== Single Post ===== */
.post {
  padding: 100px 0;
  min-height: calc(100vh - 64px);
}

.post .container {
  max-width: 760px;
}

.post__back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--gray-500);
  margin-bottom: 48px;
  transition: color 0.15s;
}
.post__back:hover {
  color: var(--charcoal);
}

.post__header {
  margin-bottom: 48px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--gray-200);
}

.post__date {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--teal);
  margin-bottom: 12px;
}

.post__title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.post__content {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--gray-700);
}

.post__content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 48px 0 16px;
  color: var(--charcoal);
}

.post__content h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 36px 0 12px;
  color: var(--charcoal);
}

.post__content p {
  margin-bottom: 20px;
}

.post__content ul, .post__content ol {
  margin: 0 0 20px 24px;
}

.post__content li {
  margin-bottom: 8px;
}

.post__content a {
  color: var(--teal);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.post__content a:hover {
  color: var(--teal-dark);
}

.post__content code {
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 0.875em;
  background: var(--gray-100);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--charcoal);
}

.post__content pre {
  background: var(--charcoal);
  border-radius: var(--radius);
  padding: 24px;
  overflow-x: auto;
  margin-bottom: 24px;
}

.post__content pre code {
  background: none;
  padding: 0;
  color: #d4d4d8;
  font-size: 0.85rem;
  line-height: 1.8;
}

.post__content blockquote {
  border-left: 3px solid var(--teal);
  padding: 12px 24px;
  margin: 24px 0;
  background: var(--teal-light);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.post__content blockquote p {
  margin-bottom: 0;
  color: var(--gray-700);
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .features__grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .showcase__inner,
  .showcase__inner--reversed {
    grid-template-columns: 1fr;
    gap: 40px;
    direction: ltr;
  }
  .stack__grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .nav__links {
    display: none;
  }
  .nav__mobile-toggle {
    display: block;
  }
}

@media (max-width: 600px) {
  .features__grid {
    grid-template-columns: 1fr;
  }
  .hero__actions {
    flex-direction: column;
  }
  .hero__terminal {
    font-size: 0.75rem;
  }
  .footer__inner {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
}
