/* ===================================================================
   GP Translate - Dark Aesthetic Blog Design System
   Obsidian Black (#08090A), Card Surface (#0D0E12), Primary (#0062A5)
   =================================================================== */

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

:root {
  --bg-main: #08090A;
  --bg-card: #0D0E12;
  --bg-card-hover: #121318;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(255, 255, 255, 0.16);
  --primary: #0062A5;
  --primary-light: #38bdf8;
  --primary-glow: rgba(0, 98, 165, 0.25);
  --text-primary: #ffffff;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, monospace;
}

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

html {
  color-scheme: dark;
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-main);
  color: var(--text-primary);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

::selection {
  background: var(--primary);
  color: #ffffff;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ===================================================================
   HEADER & NAVBAR (Matches App.tsx Navbar)
   =================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  width: 100%;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(8, 9, 10, 0.85);
  border-bottom: 1px solid var(--border-subtle);
}

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

.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.02em;
  color: #fff;
}

.brand-icon-box {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: linear-gradient(135deg, #0062A5 0%, #0284c7 100%);
  color: #fff;
}

.nav-menu {
  display: none;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.04);
  padding: 4px 6px;
  border-radius: 9999px;
  border: 1px solid var(--border-subtle);
}

@media (min-width: 860px) {
  .nav-menu {
    display: flex;
  }
}

.nav-link-item {
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: 9999px;
  transition: all 0.15s ease;
}

.nav-link-item:hover, .nav-link-item.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  color: #000000;
  font-size: 13px;
  font-weight: 600;
  height: 36px;
  padding: 0 16px;
  border-radius: 9999px;
  transition: all 0.15s ease;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.12);
}

.nav-cta:hover {
  background: #f4f4f5;
  transform: translateY(-1px);
}

/* ===================================================================
   HERO / BLOG HEADER
   =================================================================== */
.blog-hero {
  position: relative;
  padding: 80px 24px 48px;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
  overflow: hidden;
}

.blog-hero-glow {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 250px;
  background: radial-gradient(ellipse 60% 50% at 50% 0%, var(--primary-glow), transparent 70%);
  pointer-events-none;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.25);
  margin-bottom: 20px;
}

.hero-title {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 18px;
  background: linear-gradient(180deg, #ffffff 30%, #a1a1aa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: clamp(15px, 2vw, 17px);
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 680px;
  margin: 0 auto;
}

/* ===================================================================
   CATEGORY FILTER TABS
   =================================================================== */
.filter-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 32px 0 48px;
  padding: 0 24px;
}

.filter-btn {
  padding: 6px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.filter-btn:hover, .filter-btn.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.2);
}

/* ===================================================================
   ARTICLE GRID & CARDS
   =================================================================== */
.blog-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px 80px;
  flex-grow: 1;
}

.article-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

@media (min-width: 768px) {
  .article-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1080px) {
  .article-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.article-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.article-card:hover {
  transform: translateY(-4px);
  background: var(--bg-card-hover);
  border-color: var(--border-highlight);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.4), 0 0 24px rgba(0, 98, 165, 0.15);
}

.article-banner {
  height: 190px;
  position: relative;
  background: #111319;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border-subtle);
}

.banner-pattern {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.08) 1.5px, transparent 1.5px);
  background-size: 20px 20px;
  opacity: 0.6;
}

.banner-glow {
  position: absolute;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.25;
}

.banner-glow.blue { background: #0062A5; }
.banner-glow.emerald { background: #10b981; }
.banner-glow.purple { background: #8b5cf6; }
.banner-glow.amber { background: #f59e0b; }

.banner-badge {
  position: relative;
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  padding: 6px 14px;
  border-radius: 8px;
  background: rgba(13, 14, 18, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(8px);
  color: #fff;
}

.article-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.article-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-bottom: 12px;
}

.article-tag {
  color: #38bdf8;
  font-weight: 600;
  text-transform: uppercase;
}

.article-title {
  font-size: 19px;
  font-weight: 700;
  line-height: 1.35;
  color: #ffffff;
  margin-bottom: 12px;
  letter-spacing: -0.015em;
  transition: color 0.15s ease;
}

.article-card:hover .article-title {
  color: #38bdf8;
}

.article-snippet {
  font-size: 13.5px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 24px;
  flex-grow: 1;
}

.article-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
  font-size: 13px;
  font-weight: 500;
  color: #ffffff;
}

.read-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #38bdf8;
  transition: gap 0.15s ease;
}

.article-card:hover .read-btn {
  gap: 10px;
}

/* ===================================================================
   SINGLE POST LAYOUT (Obsidian Reader)
   =================================================================== */
.post-wrapper {
  max-width: 1280px;
  margin: 0 auto;
  padding: 48px 24px 96px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 56px;
}

@media (min-width: 1024px) {
  .post-wrapper {
    grid-template-columns: 1fr 340px;
    gap: 64px;
  }
}

.post-main {
  min-width: 0;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 24px;
  transition: color 0.15s ease;
}

.back-link:hover {
  color: #fff;
}

.post-header {
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 32px;
  margin-bottom: 40px;
}

.post-h1 {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.025em;
  color: #ffffff;
  margin: 14px 0 20px;
}

.post-byline {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 13px;
  color: var(--text-muted);
}

.author-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #ffffff;
  font-weight: 600;
}

.author-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #1f2937;
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
}

/* Post Typography & Elements */
.post-content {
  font-size: 16px;
  line-height: 1.8;
  color: #d4d4d8;
}

.post-content h2 {
  font-size: 24px;
  font-weight: 700;
  color: #ffffff;
  margin: 48px 0 16px;
  letter-spacing: -0.02em;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.post-content h3 {
  font-size: 18px;
  font-weight: 600;
  color: #f4f4f5;
  margin: 32px 0 12px;
}

.post-content p {
  margin-bottom: 20px;
}

.post-content strong {
  color: #ffffff;
  font-weight: 600;
}

.post-content ul, .post-content ol {
  margin: 0 0 24px 24px;
  padding: 0;
}

.post-content li {
  margin-bottom: 10px;
}

/* Callout Box */
.callout-box {
  background: rgba(0, 98, 165, 0.08);
  border: 1px solid rgba(0, 98, 165, 0.3);
  border-left: 4px solid #0284c7;
  border-radius: 12px;
  padding: 20px 24px;
  margin: 32px 0;
}

.callout-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  color: #38bdf8;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.callout-box p {
  font-size: 14.5px;
  line-height: 1.6;
  color: #e2e8f0;
  margin-bottom: 0;
}

/* Code Snippet Box */
.code-box {
  background: #000000;
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 20px;
  margin: 28px 0;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 13.5px;
  line-height: 1.6;
  color: #e2e8f0;
}

.code-box code {
  font-family: inherit;
}

/* Comparison Table in Blog */
.post-table-wrap {
  overflow-x: auto;
  margin: 32px 0;
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  background: var(--bg-card);
}

.post-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  text-align: left;
}

.post-table th {
  background: rgba(255, 255, 255, 0.04);
  padding: 14px 18px;
  font-weight: 600;
  color: #fff;
  border-bottom: 1px solid var(--border-subtle);
}

.post-table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-subtle);
  color: #d4d4d8;
}

.post-table tr:last-child td {
  border-bottom: none;
}

/* SIDEBAR & STICKY CTA */
.post-sidebar {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

@media (min-width: 1024px) {
  .post-sidebar {
    position: sticky;
    top: 96px;
    align-self: start;
  }
}

.sidebar-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  padding: 24px;
}

.sidebar-card-title {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.toc-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0;
  margin: 0;
}

.toc-link {
  font-size: 13.5px;
  color: var(--text-secondary);
  transition: all 0.15s ease;
  display: block;
}

.toc-link:hover {
  color: #38bdf8;
  transform: translateX(4px);
}

/* Conversion Card in Sidebar */
.cta-card {
  background: linear-gradient(180deg, rgba(0, 98, 165, 0.15) 0%, rgba(13, 14, 18, 0.9) 100%);
  border: 1px solid rgba(0, 98, 165, 0.35);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}

.cta-card h4 {
  font-size: 18px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
}

.cta-card p {
  font-size: 13.5px;
  color: var(--text-secondary);
  margin-bottom: 20px;
  line-height: 1.5;
}

.btn-sidebar-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: 42px;
  border-radius: 10px;
  background: #ffffff;
  color: #000000;
  font-size: 13.5px;
  font-weight: 700;
  transition: all 0.15s ease;
}

.btn-sidebar-cta:hover {
  background: #f4f4f5;
  transform: translateY(-1px);
}

/* ===================================================================
   FOOTER (Matches App.tsx Footer)
   =================================================================== */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  background: #060708;
  padding: 64px 24px 36px;
  margin-top: auto;
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
}

.footer-top-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

@media (min-width: 768px) {
  .footer-top-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}

.footer-col h5 {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #fff;
  margin-bottom: 18px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0;
  margin: 0;
}

.footer-links a {
  font-size: 13.5px;
  color: var(--text-secondary);
  transition: color 0.15s ease;
}

.footer-links a:hover {
  color: #fff;
}

.footer-bottom-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 28px;
  border-top: 1px solid var(--border-subtle);
  font-size: 12.5px;
  color: var(--text-muted);
}

@media (min-width: 640px) {
  .footer-bottom-row {
    flex-direction: row;
  }
}

/* ===================================================================
   UNIFIED RESPONSIVE HEADER & FOOTER SYSTEM (Matches App.tsx 1:1)
   =================================================================== */
@media (max-width: 639px) {
  .cta-install-btn {
    display: none !important;
  }
}

@media (min-width: 640px) {
  .header-container, .footer-container {
    padding-left: 24px !important;
    padding-right: 24px !important;
  }
  .footer-bottom-bar {
    flex-direction: row !important;
  }
  .footer-right-note {
    padding-right: 0 !important;
  }
}

@media (min-width: 768px) {
  .footer-grid-layout {
    grid-template-columns: repeat(12, 1fr) !important;
    gap: 32px !important;
  }
  .footer-brand-column {
    grid-column: span 4 !important;
  }
  .footer-link-col {
    grid-column: span 2 !important;
  }
  .footer-support-column {
    grid-column: span 4 !important;
  }
}

@media (min-width: 1024px) {
  .header-container, .footer-container {
    padding-left: 32px !important;
    padding-right: 32px !important;
  }
  .desktop-nav-pill {
    display: flex !important;
  }
  .footer-grid-layout {
    grid-template-columns: repeat(12, 1fr) !important;
    gap: 40px !important;
  }
  .footer-brand-column {
    grid-column: span 4 !important;
  }
  .footer-link-col {
    grid-column: span 2 !important;
  }
  .footer-support-column {
    grid-column: span 4 !important;
  }
}

.footer-support-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: #0B0C0F;
  text-decoration: none;
  transition: all 0.2s ease;
  width: 100%;
  box-sizing: border-box;
}
.footer-support-card:hover {
  border-color: rgba(255, 255, 255, 0.16) !important;
  background: rgba(255, 255, 255, 0.025) !important;
}
.footer-support-card:hover .support-chevron {
  color: #d4d4d8 !important;
  transform: translateX(2px);
}
.footer-support-card-wa:hover .support-icon-box {
  background: rgba(16, 185, 129, 0.1) !important;
  border-color: rgba(16, 185, 129, 0.25) !important;
}
.footer-support-card-mail:hover .support-icon-box {
  background: rgba(14, 165, 233, 0.1) !important;
  border-color: rgba(14, 165, 233, 0.25) !important;
}

@media (min-width: 1280px) {
  .app-store-header-link {
    display: inline-flex !important;
  }
}

.nav-pill-link:hover {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.08) !important;
}

.footer-nav-link:hover {
  color: #ffffff !important;
}

@media (min-width: 1024px) {
  .blog-header-link {
    display: inline-flex !important;
  }
}
.blog-header-link:hover {
  color: #ffffff !important;
}

/* ===================================================================
   DARK POLICY PAGES (privacy.html & terms.html)
   =================================================================== */
body.policy-page {
  background: var(--bg-main);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.policy-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 56px 24px 96px;
  width: 100%;
  box-sizing: border-box;
}

.policy-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  align-items: start;
}

@media (min-width: 960px) {
  .policy-grid {
    grid-template-columns: 280px 1fr;
    gap: 56px;
  }
}

.policy-sidebar-sticky {
  position: sticky;
  top: 96px;
  background: #0D0E12;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 24px;
}

.policy-title-box {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.policy-title-box h1 {
  font-size: 22px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.02em;
  margin: 0 0 6px;
}

.policy-title-box p {
  font-size: 12px;
  font-family: var(--font-mono);
  color: #71717a;
  margin: 0;
}

.policy-toc {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.policy-toc-link {
  font-size: 13px;
  color: #a1a1aa;
  padding: 8px 10px;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.15s ease;
  line-height: 1.4;
}

.policy-toc-link:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

.policy-content-col {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.policy-card-item {
  background: #0D0E12;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 28px 32px;
  scroll-margin-top: 96px;
}

.policy-card-caption {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.2);
  padding: 3px 10px;
  border-radius: 9999px;
  margin-bottom: 12px;
}

.policy-card-item h3 {
  font-size: 18px;
  font-weight: 600;
  color: #ffffff;
  letter-spacing: -0.015em;
  margin: 0 0 14px;
}

.policy-card-item p {
  font-size: 14.5px;
  line-height: 1.75;
  color: #a1a1aa;
  margin: 0 0 14px;
}

.policy-card-item p:last-child {
  margin-bottom: 0;
}

.policy-card-item strong {
  color: #f4f4f5;
  font-weight: 600;
}

.policy-card-item ul {
  margin: 12px 0 0;
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.policy-card-item li {
  font-size: 14.5px;
  line-height: 1.7;
  color: #a1a1aa;
}

.policy-card-item a {
  color: #38bdf8;
  text-decoration: none;
}

.policy-card-item a:hover {
  text-decoration: underline;
}

.policy-card-item code {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: #e4e4e7;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 2px 6px;
  border-radius: 5px;
}

