/*
Theme Name: Stokimba WP Theme
Theme URI: https://stokimba.com
Author: Antigravity AI
Description: A custom Tailwind CSS WordPress theme optimized for AEO/GEO mirroring the Stokimba React SPA.
Version: 2.0.0
Text Domain: stokimba
*/

/* ===== CSS VARIABLES ===== */
:root {
  --background: 0 0% 100%;
  --foreground: 220 13% 13%;
  --card: 0 0% 96%;
  --card-foreground: 220 13% 13%;
  --popover: 0 0% 100%;
  --popover-foreground: 220 13% 13%;
  --primary: 220 90% 56%;
  --primary-foreground: 210 40% 98%;
  --secondary: 217.2 32.6% 17.5%;
  --secondary-foreground: 210 40% 98%;
  --muted: 220 13% 90%;
  --muted-foreground: 220 13% 40%;
  --accent: 220 13% 90%;
  --accent-foreground: 220 13% 13%;
  --destructive: 0 84% 60%;
  --destructive-foreground: 210 40% 98%;
  --border: 220 13% 85%;
  --input: 220 13% 85%;
  --ring: 220 90% 56%;
  --radius: 0.5rem;
}

.dark {
  --background: 222.2 84% 4.9%;
  --foreground: 210 40% 98%;
  --card: 222.2 84% 7%;
  --card-foreground: 210 40% 98%;
  --popover: 222.2 84% 4.9%;
  --popover-foreground: 210 40% 98%;
  --primary: 217.2 91.2% 59.8%;
  --primary-foreground: 222.2 47.4% 11.2%;
  --secondary: 217.2 32.6% 17.5%;
  --secondary-foreground: 210 40% 98%;
  --muted: 217.2 32.6% 17.5%;
  --muted-foreground: 215 20.2% 65.1%;
  --accent: 217.2 32.6% 17.5%;
  --accent-foreground: 210 40% 98%;
  --destructive: 0 62.8% 30.6%;
  --destructive-foreground: 210 40% 98%;
  --border: 217.2 32.6% 17.5%;
  --input: 217.2 32.6% 17.5%;
  --ring: 217.2 91.2% 59.8%;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.3s ease, color 0.3s ease;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
button { font-family: inherit; cursor: pointer; }

/* ===== LAYOUT ===== */
.stk-container {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1rem;
}
@media (min-width: 640px)  { .stk-container { padding: 0 1.5rem; } }
@media (min-width: 1024px) { .stk-container { padding: 0 2rem; } }

/* ===== HEADER ===== */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding: 1rem 0;
  transition: padding 0.3s ease, background-color 0.3s ease,
              box-shadow 0.3s ease, border-color 0.3s ease;
}

.site-header.at-top {
  background-color: transparent;
  border-bottom: 1px solid transparent;
  box-shadow: none;
}

.site-header.scrolled {
  padding: 0.5rem 0;
  background-color: hsl(var(--background) / 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid hsl(var(--border) / 0.5);
  box-shadow: 0 1px 8px rgba(0,0,0,0.08);
}

.admin-bar .site-header { top: 32px; }
@media screen and (max-width: 782px) {
  .admin-bar .site-header { top: 46px; }
}

/* ===== NAV LINKS ===== */
.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: hsl(var(--muted-foreground));
  text-decoration: none;
  transition: color 0.15s ease, background-color 0.15s ease;
  background: none;
  border: none;
  font-family: inherit;
  line-height: 1.5;
}

.nav-link:hover {
  color: hsl(var(--foreground));
  background-color: hsl(var(--accent));
}

.nav-link.active {
  color: hsl(var(--primary));
  background-color: hsl(var(--muted) / 0.5);
  font-weight: 600;
}

/* ===== DROPDOWN ===== */
.stk-dropdown { position: relative; }

.stk-dropdown-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: hsl(var(--muted-foreground));
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.stk-dropdown-btn:hover { color: hsl(var(--foreground)); background-color: hsl(var(--accent)); }

.stk-dropdown-btn .chevron {
  transition: transform 0.2s ease;
}

.stk-dropdown.open .chevron { transform: rotate(180deg); }

.stk-dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 220px;
  background-color: hsl(var(--popover));
  border: 1px solid hsl(var(--border));
  border-radius: 0.625rem;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12), 0 2px 6px rgba(0,0,0,0.06);
  padding: 0.375rem;
  z-index: 60;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.stk-dropdown.open .stk-dropdown-menu {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}

.stk-dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.5rem 0.75rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
  text-decoration: none;
  transition: background-color 0.12s ease, color 0.12s ease;
}

.stk-dropdown-item:hover {
  background-color: hsl(var(--accent));
  color: hsl(var(--foreground));
}

.stk-dropdown-item svg { flex-shrink: 0; opacity: 0.7; }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1;
  padding: 0.5rem 1rem;
  height: 2.5rem;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease,
              transform 0.15s ease, box-shadow 0.15s ease,
              border-color 0.15s ease, opacity 0.15s ease;
  white-space: nowrap;
  font-family: inherit;
}

.btn:focus-visible {
  outline: 2px solid hsl(var(--ring));
  outline-offset: 2px;
}

.btn:disabled { pointer-events: none; opacity: 0.5; }

.btn-default {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
}
.btn-default:hover { background-color: hsl(var(--primary) / 0.88); }

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

.btn-ghost {
  background: transparent;
  color: hsl(var(--foreground));
}
.btn-ghost:hover { background-color: hsl(var(--accent)); }

.btn-green {
  background-color: #16a34a;
  color: #fff;
  border-radius: 9999px;
  padding: 0.75rem 2rem;
  height: auto;
  font-weight: 700;
  font-size: 1rem;
  box-shadow: 0 4px 14px rgba(22,163,74,0.3);
}
.btn-green:hover { background-color: #15803d; transform: scale(1.02); color: #fff; }
.btn-green:active { transform: scale(0.98); }

.btn-sm { height: 2.25rem; padding: 0 0.75rem; font-size: 0.8125rem; }
.btn-lg { height: 2.75rem; padding: 0 2rem; font-size: 1rem; }
.btn-icon { width: 2.25rem; height: 2.25rem; padding: 0; border-radius: 9999px; }
.btn-block { width: 100%; justify-content: center; }

/* ===== THEME TOGGLE ===== */
.theme-toggle {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 9999px;
  border: 1px solid hsl(var(--border));
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: hsl(var(--muted-foreground));
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  flex-shrink: 0;
}
.theme-toggle:hover {
  background-color: hsl(var(--accent));
  color: hsl(var(--foreground));
}

/* Light mode: show moon icon (to switch to dark) */
.theme-toggle .icon-moon { display: flex; align-items: center; }
.theme-toggle .icon-sun  { display: none; }
/* Dark mode: show sun icon (to switch to light) */
.dark .theme-toggle .icon-moon { display: none; }
.dark .theme-toggle .icon-sun  { display: flex; align-items: center; }

/* ===== MOBILE MENU ===== */
.mobile-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(0,0,0,0.5);
  z-index: 98;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.mobile-overlay.open { opacity: 1; pointer-events: all; }

.mobile-drawer {
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: min(300px, 85vw);
  background-color: hsl(var(--background));
  border-left: 1px solid hsl(var(--border));
  z-index: 99;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.mobile-drawer.open { transform: translateX(0); }

.mobile-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid hsl(var(--border));
  flex-shrink: 0;
}

.mobile-drawer-nav {
  display: flex;
  flex-direction: column;
  padding: 0.75rem 0.75rem;
  gap: 0.125rem;
  flex: 1;
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  font-size: 0.9375rem;
  font-weight: 500;
  color: hsl(var(--muted-foreground));
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.mobile-nav-link:hover {
  background-color: hsl(var(--accent));
  color: hsl(var(--foreground));
}
.mobile-nav-link.active {
  color: hsl(var(--primary));
  background-color: hsl(var(--primary) / 0.08);
  font-weight: 600;
}

.mobile-divider {
  height: 1px;
  background-color: hsl(var(--border));
  margin: 0.75rem 0;
}

.mobile-section-label {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: hsl(var(--muted-foreground));
  padding: 0.25rem 1rem 0.5rem;
}

.mobile-drawer-footer {
  padding: 1rem 1.25rem;
  border-top: 1px solid hsl(var(--border));
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  flex-shrink: 0;
}

/* ===== LOGO ===== */
.logo-wrapper {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  text-decoration: none;
}

.logo-icon {
  padding: 0.375rem;
  border-radius: 0.625rem;
  background-color: #16a34a;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 8px rgba(22,163,74,0.3);
  transition: transform 0.2s ease;
  flex-shrink: 0;
}
.logo-wrapper:hover .logo-icon { transform: scale(1.06); }

.logo-text {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  color: hsl(var(--foreground));
}

/* ===== HEADER SPACER ===== */
.header-spacer { height: 80px; }

/* ===== MAIN CONTENT ===== */
.site-main {
  min-height: calc(100vh - 80px);
}

/* ===== POST CARDS ===== */
.post-card {
  background-color: hsl(var(--card));
  border: 1px solid hsl(var(--border));
  border-radius: 0.875rem;
  overflow: hidden;
  transition: box-shadow 0.25s ease, transform 0.25s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.post-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.1), 0 4px 8px rgba(0,0,0,0.05);
}
.dark .post-card:hover {
  box-shadow: 0 12px 30px rgba(0,0,0,0.5), 0 4px 8px rgba(0,0,0,0.2);
}

.post-card-thumbnail {
  aspect-ratio: 16/9;
  overflow: hidden;
  background-color: hsl(var(--muted));
  flex-shrink: 0;
}

.post-card-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.post-card:hover .post-card-thumbnail img { transform: scale(1.04); }

.post-card-thumbnail-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, hsl(var(--muted)), hsl(var(--muted) / 0.5));
}

.post-card-body {
  padding: 1.375rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.post-card-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.post-card-date {
  font-size: 0.8125rem;
  color: hsl(var(--muted-foreground));
}

.post-card-category {
  display: inline-flex;
  align-items: center;
  border-radius: 9999px;
  padding: 0.15rem 0.625rem;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background-color: hsl(var(--primary) / 0.1);
  color: hsl(var(--primary));
  border: 1px solid hsl(var(--primary) / 0.2);
  text-decoration: none;
  transition: background-color 0.15s ease;
}
.post-card-category:hover { background-color: hsl(var(--primary) / 0.18); }

.post-card-title {
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.35;
  color: hsl(var(--card-foreground));
  margin-bottom: 0.625rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-card-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s ease;
}
.post-card-title a:hover { color: hsl(var(--primary)); }

.post-card-excerpt {
  font-size: 0.9rem;
  color: hsl(var(--muted-foreground));
  line-height: 1.65;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
  margin-bottom: 1.25rem;
}

.post-card-read-more {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: hsl(var(--primary));
  text-decoration: none;
  transition: gap 0.2s ease, opacity 0.15s ease;
  margin-top: auto;
}
.post-card-read-more:hover { gap: 0.625rem; opacity: 0.85; }

/* ===== BLOG HEADER ===== */
.blog-header {
  text-align: center;
  margin-bottom: 3.5rem;
}

.blog-header-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 9999px;
  padding: 0.3rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 600;
  background-color: hsl(var(--primary) / 0.08);
  color: hsl(var(--primary));
  border: 1px solid hsl(var(--primary) / 0.15);
  margin-bottom: 1.25rem;
}

.blog-header-title {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: hsl(var(--foreground));
  line-height: 1.15;
  margin-bottom: 1rem;
}

.blog-header-desc {
  font-size: 1.0625rem;
  color: hsl(var(--muted-foreground));
  max-width: 42rem;
  margin: 0 auto;
  line-height: 1.7;
}

/* ===== EMPTY STATE ===== */
.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 5rem 2rem;
  color: hsl(var(--muted-foreground));
}

.empty-state svg { margin: 0 auto 1.25rem; opacity: 0.35; }
.empty-state h3 { font-size: 1.25rem; font-weight: 600; color: hsl(var(--foreground)); margin-bottom: 0.5rem; }
.empty-state p { font-size: 0.9375rem; }

/* ===== PAGINATION ===== */
.stk-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  margin-top: 3.5rem;
  flex-wrap: wrap;
}

.stk-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.25rem;
  height: 2.25rem;
  padding: 0 0.625rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid hsl(var(--border));
  color: hsl(var(--foreground));
  transition: all 0.15s ease;
  background-color: hsl(var(--background));
}

.stk-pagination .page-numbers:hover:not(.current) {
  background-color: hsl(var(--accent));
  border-color: hsl(var(--accent));
}

.stk-pagination .page-numbers.current {
  background-color: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  border-color: hsl(var(--primary));
  font-weight: 600;
}

.stk-pagination .page-numbers.dots {
  border-color: transparent;
  background: transparent;
  pointer-events: none;
}

/* ===== SINGLE ARTICLE ===== */
.article-header { text-align: center; margin-bottom: 2.5rem; }

.article-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  font-size: 0.875rem;
  color: hsl(var(--muted-foreground));
}

.article-eyebrow span { display: flex; align-items: center; gap: 0.375rem; }

.article-eyebrow .sep { opacity: 0.4; }

.article-title {
  font-size: clamp(1.875rem, 5vw, 3.25rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: hsl(var(--foreground));
  margin-bottom: 1.5rem;
}

.article-featured-image {
  border-radius: 1rem;
  overflow: hidden;
  margin-bottom: 2.5rem;
  border: 1px solid hsl(var(--border));
  box-shadow: 0 12px 40px rgba(0,0,0,0.1);
}
.dark .article-featured-image { box-shadow: 0 12px 40px rgba(0,0,0,0.5); }

.article-featured-image img {
  width: 100%;
  max-height: 460px;
  object-fit: cover;
}

/* ===== PROSE ===== */
.prose {
  color: hsl(var(--muted-foreground));
  line-height: 1.8;
  font-size: 1.0625rem;
}

.prose > * + * { margin-top: 1.5rem; }

.prose h1, .prose h2, .prose h3, .prose h4, .prose h5, .prose h6 {
  color: hsl(var(--foreground));
  font-weight: 700;
  line-height: 1.3;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.prose h1 { font-size: 2.25rem; letter-spacing: -0.03em; }
.prose h2 { font-size: 1.75rem; letter-spacing: -0.02em; }
.prose h3 { font-size: 1.375rem; }
.prose h4 { font-size: 1.125rem; }

.prose p { margin-bottom: 1.5rem; }

.prose a {
  color: hsl(var(--primary));
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: opacity 0.15s ease;
}
.prose a:hover { opacity: 0.8; }

.prose strong { color: hsl(var(--foreground)); font-weight: 600; }
.prose em { font-style: italic; }

.prose ul { list-style: disc; padding-left: 1.625rem; margin-bottom: 1.5rem; }
.prose ol { list-style: decimal; padding-left: 1.625rem; margin-bottom: 1.5rem; }
.prose li { margin-bottom: 0.5rem; padding-left: 0.25rem; }
.prose li::marker { color: hsl(var(--primary)); }

.prose blockquote {
  border-left: 4px solid hsl(var(--primary));
  padding: 0.875rem 1.25rem;
  margin: 2rem 0;
  background-color: hsl(var(--primary) / 0.05);
  border-radius: 0 0.5rem 0.5rem 0;
  color: hsl(var(--muted-foreground));
  font-style: italic;
}

.prose code {
  background-color: hsl(var(--muted));
  color: hsl(var(--foreground));
  padding: 0.15rem 0.4rem;
  border-radius: 0.3rem;
  font-size: 0.875em;
  font-family: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;
}

.prose pre {
  background-color: hsl(222 47% 11%);
  color: #e2e8f0;
  padding: 1.25rem 1.5rem;
  border-radius: 0.75rem;
  overflow-x: auto;
  margin: 2rem 0;
  border: 1px solid rgba(255,255,255,0.07);
}

.prose pre code {
  background: none;
  padding: 0;
  font-size: 0.9em;
  color: inherit;
}

.prose img {
  border-radius: 0.75rem;
  margin: 2rem auto;
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.prose hr {
  border: none;
  border-top: 1px solid hsl(var(--border));
  margin: 2.5rem 0;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  font-size: 0.9375rem;
  overflow-x: auto;
  display: block;
}

.prose thead tr {
  background-color: hsl(var(--muted));
}

.prose th {
  padding: 0.75rem 1rem;
  text-align: left;
  font-weight: 600;
  color: hsl(var(--foreground));
  border-bottom: 2px solid hsl(var(--border));
  white-space: nowrap;
}

.prose td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid hsl(var(--border));
  color: hsl(var(--muted-foreground));
}

.prose tr:last-child td { border-bottom: none; }
.prose tr:hover td { background-color: hsl(var(--muted) / 0.3); }

/* ===== ARTICLE CTA ===== */
.article-cta {
  background: linear-gradient(135deg, hsl(142 76% 36% / 0.08), hsl(220 90% 56% / 0.05));
  border: 1px solid hsl(142 76% 36% / 0.2);
  border-radius: 1rem;
  padding: 2.5rem 2rem;
  text-align: center;
  margin: 2.5rem 0;
}
.dark .article-cta {
  background: linear-gradient(135deg, hsl(142 76% 36% / 0.12), hsl(220 90% 56% / 0.08));
  border-color: hsl(142 76% 36% / 0.25);
}

.article-cta h3 {
  font-size: 1.5rem;
  font-weight: 700;
  color: hsl(var(--foreground));
  margin-bottom: 0.75rem;
}

.article-cta p {
  color: hsl(var(--muted-foreground));
  margin-bottom: 1.5rem;
  font-size: 1rem;
}

/* ===== POST NAVIGATION ===== */
.post-navigation {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid hsl(var(--border));
}

@media (max-width: 639px) { .post-navigation { grid-template-columns: 1fr; } }

.post-nav-link {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  padding: 1rem 1.25rem;
  border-radius: 0.75rem;
  border: 1px solid hsl(var(--border));
  text-decoration: none;
  transition: all 0.2s ease;
  background-color: hsl(var(--card));
}
.post-nav-link:hover {
  border-color: hsl(var(--primary) / 0.4);
  background-color: hsl(var(--primary) / 0.04);
  transform: translateY(-1px);
}

.post-nav-link.prev { align-items: flex-start; }
.post-nav-link.next { align-items: flex-end; }

.post-nav-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: hsl(var(--muted-foreground));
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.post-nav-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: hsl(var(--foreground));
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
  text-align: inherit;
}

/* ===== FOOTER ===== */
.site-footer {
  background-color: #fff;
  border-top: 1px solid #e5e7eb;
  padding: 4rem 0 2rem;
  margin-top: 5rem;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.dark .site-footer {
  background-color: hsl(222.2 84% 4.9%);
  border-top-color: hsl(217.2 32.6% 12%);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  margin-bottom: 3.5rem;
}

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

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

.footer-brand { grid-column: span 1; }
@media (min-width: 1024px) { .footer-brand { grid-column: span 1; } }

.footer-brand-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  text-decoration: none;
}

.footer-brand-logo .logo-icon { width: 2.375rem; height: 2.375rem; }

.footer-brand-name {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #111827;
}
.dark .footer-brand-name { color: #fff; }

.footer-brand-desc {
  font-size: 0.9rem;
  color: #6b7280;
  line-height: 1.7;
  max-width: 22rem;
  margin-bottom: 1.5rem;
}
.dark .footer-brand-desc { color: #94a3b8; }

.footer-social-icons {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  flex-wrap: wrap;
}

.social-btn {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-decoration: none;
  transition: transform 0.2s ease, opacity 0.2s ease;
  flex-shrink: 0;
}
.social-btn:hover { transform: scale(1.12); opacity: 0.9; }

.social-btn-telegram  { background-color: #0ea5e9; }
.social-btn-facebook  { background-color: #2563eb; }
.social-btn-youtube   { background-color: #dc2626; }
.social-btn-linkedin  { background-color: #1d4ed8; }
.social-btn-instagram { background: linear-gradient(135deg, #ec4899, #f97316); }
.social-btn-tiktok    { background-color: #0f172a; }
.dark .social-btn-tiktok { background-color: #fff; color: #0f172a; }

.footer-col-title {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 1rem;
}
.dark .footer-col-title { color: #f1f5f9; }

.footer-links { list-style: none; display: flex; flex-direction: column; gap: 0.625rem; }

.footer-links a {
  font-size: 0.9rem;
  color: #6b7280;
  text-decoration: none;
  transition: color 0.15s ease;
  display: inline-block;
}
.footer-links a:hover { color: #2563eb; }
.dark .footer-links a { color: #94a3b8; }
.dark .footer-links a:hover { color: #60a5fa; }

.footer-bottom {
  border-top: 1px solid #e5e7eb;
  padding-top: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  text-align: center;
}
.dark .footer-bottom { border-top-color: hsl(217.2 32.6% 12%); }

@media (min-width: 640px) {
  .footer-bottom { flex-direction: row; justify-content: space-between; text-align: left; }
}

.footer-copyright {
  font-size: 0.875rem;
  color: #9ca3af;
}
.dark .footer-copyright { color: #64748b; }

.footer-legal-links {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-legal-links a {
  font-size: 0.875rem;
  color: #9ca3af;
  text-decoration: none;
  transition: color 0.15s ease;
}
.footer-legal-links a:hover { color: #4b5563; }
.dark .footer-legal-links a { color: #64748b; }
.dark .footer-legal-links a:hover { color: #94a3b8; }

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.animate-fade-in-up {
  animation: fadeInUp 0.6s ease forwards;
}

[data-animate] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

[data-animate].in-view {
  opacity: 1;
  transform: translateY(0);
}

[data-animate-delay="1"] { transition-delay: 0.08s; }
[data-animate-delay="2"] { transition-delay: 0.16s; }
[data-animate-delay="3"] { transition-delay: 0.24s; }
[data-animate-delay="4"] { transition-delay: 0.32s; }
[data-animate-delay="5"] { transition-delay: 0.40s; }
[data-animate-delay="6"] { transition-delay: 0.48s; }

/* ===== UTILITIES ===== */
.text-primary  { color: hsl(var(--primary)); }
.text-muted    { color: hsl(var(--muted-foreground)); }
.text-fg       { color: hsl(var(--foreground)); }

.bg-card-custom {
  background-color: hsl(var(--card));
  border: 1px solid hsl(var(--border));
}

.separator {
  height: 1px;
  background-color: hsl(var(--border));
  margin: 0.75rem 0;
}

/* ===== READING PROGRESS BAR ===== */
.reading-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  background: linear-gradient(90deg, hsl(var(--primary)), #22c55e);
  width: 0%;
  z-index: 100;
  transition: width 0.1s linear;
  border-radius: 0 9999px 9999px 0;
}

/* ===== RESPONSIVE UTILITIES ===== */
.hidden-mobile  { display: none; }
@media (min-width: 768px) { .hidden-mobile  { display: flex; } }

.hidden-desktop { display: flex; }
@media (min-width: 768px) { .hidden-desktop { display: none; } }

/* ===== WP ALIGNMENTS ===== */
.alignleft  { float: left; margin: 0 1.5rem 1rem 0; }
.alignright { float: right; margin: 0 0 1rem 1.5rem; }
.aligncenter { text-align: center; margin: 0 auto 1.5rem; }
.wp-caption-text { font-size: 0.85rem; color: hsl(var(--muted-foreground)); text-align: center; margin-top: 0.5rem; }
