/**
 * AmazingAI Components: Buttons, Badges, Tech Pills, Header, Cards
 */

/* ====================================================
   BUTTONS
   ==================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-sm);
  line-height: 1;
  padding: 0.65rem 1.25rem;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: all var(--duration-fast) var(--ease-spring);
  position: relative;
  user-select: none;
}

.btn:active {
  transform: scale(0.97) translateY(0);
}

.btn-primary {
  background: linear-gradient(135deg, var(--brand-primary) 0%, #0284c7 100%);
  color: #07090e;
  font-weight: 700;
  border-color: rgba(0, 210, 180, 0.4);
  box-shadow: var(--shadow-sm), 0 0 20px -5px var(--brand-primary-glow);
  position: relative;
  overflow: hidden;
}
.btn-primary::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -100%;
  width: 50%;
  height: 200%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: rotate(25deg);
  transition: none;
}
.btn-primary:hover {
  background: linear-gradient(135deg, #26e6cb 0%, #0ea5e9 100%);
  color: #07090e;
  box-shadow: var(--shadow-md), 0 0 28px -2px var(--brand-primary-glow);
  transform: translateY(-2px);
}
.btn-primary:hover::after {
  left: 150%;
  transition: all 0.75s ease-in-out;
}

[data-theme="light"] .btn-primary {
  color: #ffffff;
}

.btn-secondary, .btn-glass {
  background: var(--bg-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  color: var(--text-primary);
  border-color: var(--border-medium);
}
.btn-secondary:hover, .btn-glass:hover {
  background: var(--bg-card-hover);
  border-color: var(--brand-primary);
  color: var(--text-primary);
  transform: translateY(-2px);
}

.btn-cyan {
  background: linear-gradient(135deg, var(--brand-cyan) 0%, #0891b2 100%);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: var(--shadow-sm), 0 0 20px -5px var(--brand-cyan-glow);
}
.btn-cyan:hover {
  background: linear-gradient(135deg, #22d3ee 0%, #06b6d4 100%);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md), 0 0 28px -2px var(--brand-cyan-glow);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--border-medium);
}
.btn-outline:hover {
  border-color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.btn-sm {
  padding: 0.45rem 0.85rem;
  font-size: var(--text-xs);
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 0.85rem 1.75rem;
  font-size: var(--text-base);
  border-radius: var(--radius-lg);
}

.btn-icon {
  width: 42px;
  height: 42px;
  padding: 0;
  border-radius: var(--radius-md);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* In Dark mode: show Sun icon to switch to light mode */
.theme-icon-sun {
  display: block;
}
.theme-icon-moon {
  display: none;
}
/* In Light mode: show Moon icon to switch to dark mode */
[data-theme="light"] .theme-icon-sun {
  display: none;
}
[data-theme="light"] .theme-icon-moon {
  display: block;
}

/* ====================================================
   BADGES & TECH PILLS
   ==================================================== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  border: 1px solid var(--border-subtle);
  background: var(--bg-elevated);
  color: var(--text-secondary);
}

.badge-featured {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15) 0%, rgba(217, 119, 6, 0.2) 100%);
  color: #fbbf24;
  border-color: rgba(245, 158, 11, 0.3);
}

.badge-verified {
  background: var(--brand-emerald-light);
  color: var(--brand-emerald);
  border-color: rgba(16, 185, 129, 0.3);
}

.badge-live {
  background: var(--brand-emerald-light);
  color: var(--brand-emerald);
  border-color: rgba(16, 185, 129, 0.3);
}
.badge-live::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--brand-emerald);
  animation: liveDotGlow 2s infinite ease-in-out;
}

/* Tech Framework Badges */
.tech-pill {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  transition: all var(--duration-fast) var(--ease-smooth);
}
.tech-pill:hover {
  border-color: var(--brand-primary);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.tech-react { border-color: rgba(97, 218, 251, 0.25); color: #61dafb; }
.tech-nextjs { border-color: rgba(255, 255, 255, 0.25); color: #ffffff; }
.tech-tailwind { border-color: rgba(56, 189, 248, 0.25); color: #38bdf8; }
.tech-vue { border-color: rgba(66, 184, 131, 0.25); color: #42b883; }
.tech-typescript { border-color: rgba(49, 120, 198, 0.25); color: #3178c6; }
.tech-python { border-color: rgba(255, 212, 59, 0.25); color: #ffd43b; }

/* Light Theme Contrast Overrides for Tech Pills */
[data-theme="light"] .tech-pill {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.1);
  color: var(--text-secondary);
}
[data-theme="light"] .tech-react { border-color: rgba(8, 126, 164, 0.3); color: #087ea4; background: rgba(8, 126, 164, 0.07); }
[data-theme="light"] .tech-nextjs { border-color: rgba(0, 0, 0, 0.25); color: #0f172a; background: rgba(0, 0, 0, 0.05); }
[data-theme="light"] .tech-tailwind { border-color: rgba(2, 132, 199, 0.3); color: #0284c7; background: rgba(2, 132, 199, 0.07); }
[data-theme="light"] .tech-vue { border-color: rgba(22, 163, 74, 0.3); color: #16a34a; background: rgba(22, 163, 74, 0.07); }
[data-theme="light"] .tech-typescript { border-color: rgba(37, 99, 235, 0.3); color: #2563eb; background: rgba(37, 99, 235, 0.07); }
[data-theme="light"] .tech-python { border-color: rgba(202, 138, 4, 0.3); color: #b45309; background: rgba(202, 138, 4, 0.07); }

/* ====================================================
   PRODUCT CARD (Marketplace Item)
   ==================================================== */
.product-card {
  background: rgba(14, 20, 33, 0.78);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-xl);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--duration-normal) var(--ease-spring), border-color var(--duration-normal) var(--ease-smooth), box-shadow var(--duration-normal) var(--ease-smooth);
  position: relative;
}

[data-theme="light"] .product-card {
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.09);
  box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.06), 0 2px 6px -1px rgba(15, 23, 42, 0.04);
}

[data-theme="light"] .product-card:hover {
  border-color: rgba(0, 168, 145, 0.45);
  box-shadow: 0 20px 45px -10px rgba(15, 23, 42, 0.12), 0 0 25px -5px rgba(0, 168, 145, 0.2);
}

/* Dynamic Cursor Spotlight Ring */
.product-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: radial-gradient(450px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(0, 210, 180, 0.45), transparent 45%);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0;
  transition: opacity 300ms ease;
  z-index: 5;
}

[data-theme="light"] .product-card::before {
  background: radial-gradient(450px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(0, 168, 145, 0.35), transparent 45%);
}

.product-card:hover::before {
  opacity: 1;
}

.product-card:hover {
  transform: translateY(-8px) scale(1.01);
  border-color: rgba(0, 210, 180, 0.4);
  box-shadow: 0 24px 50px -15px rgba(0, 0, 0, 0.8), 0 0 35px -5px rgba(0, 210, 180, 0.25);
}

/* Card Browser Mini Bar */
.card-browser-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.45rem 0.85rem;
  background: rgba(9, 13, 22, 0.95);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
  z-index: 2;
}

[data-theme="light"] .card-browser-bar {
  background: #f8fafc;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.card-browser-dots {
  display: flex;
  gap: 5px;
}

.card-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
}
.dot-r { background: #ff5f56; }
.dot-y { background: #ffbd2e; }
.dot-g { background: #27c93f; }

.card-framework-badge {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.06);
  padding: 0.1rem 0.5rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

[data-theme="light"] .card-framework-badge {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.12);
  color: #475569;
}

.card-live-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.65rem;
  font-weight: 800;
  color: var(--brand-emerald);
  letter-spacing: 0.05em;
}

.pulse-dot-sm {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand-emerald);
  box-shadow: 0 0 6px var(--brand-emerald);
  animation: pulseLive 2s infinite;
}

.product-thumbnail-wrap {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background-color: var(--bg-elevated);
}

.product-thumbnail {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--duration-slow) var(--ease-spring);
}

.product-card:hover .product-thumbnail {
  transform: scale(1.05);
}

.product-overlay {
  position: absolute;
  inset: 0;
  background: rgba(7, 9, 14, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  opacity: 0;
  visibility: hidden;
  transition: all var(--duration-fast) var(--ease-smooth);
  z-index: 4;
}

.product-card:hover .product-overlay {
  opacity: 1;
  visibility: visible;
}

.product-badge-corner {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  z-index: 2;
}

.product-card-body {
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-meta-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-2);
}

.product-category-link {
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  color: var(--brand-primary);
  letter-spacing: 0.04em;
}

.product-rating {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--brand-amber);
}

.product-title {
  font-size: var(--text-lg);
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: var(--space-3);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-title a {
  color: var(--text-primary);
}
.product-title a:hover {
  color: var(--brand-primary);
}

.product-tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: var(--space-4);
}

.product-card-footer {
  margin-top: auto;
  padding-top: var(--space-4);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.product-price-box {
  display: flex;
  flex-direction: column;
}

.product-price-label {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.product-price {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 800;
  color: var(--text-primary);
}

.product-sales {
  font-size: var(--text-xs);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

/* ====================================================
   SITE HEADER & NAVIGATION
   ==================================================== */
/* ====================================================
   SITE HEADER & NAVIGATION
   ==================================================== */
.site-header {
  position: sticky;
  top: 0;
  height: var(--header-height);
  z-index: var(--z-header);
  background: rgba(7, 9, 14, 0.85);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--border-subtle);
  transition: all var(--duration-normal) var(--ease-smooth);
}

/* WordPress Admin Bar Compatibility */
.admin-bar .site-header {
  top: 32px !important;
}

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

@media screen and (max-width: 600px) {
  .admin-bar .site-header {
    position: static !important;
  }
}

[data-theme="light"] .site-header {
  background: rgba(255, 255, 255, 0.88);
}

.site-header.is-scrolled {
  background: rgba(7, 9, 14, 0.95);
  border-bottom-color: var(--border-medium);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

[data-theme="light"] .site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 10px 25px -10px rgba(0, 0, 0, 0.08);
}

.site-header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}

.site-header-left {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  flex-shrink: 0;
}

.site-brand {
  display: inline-flex;
  align-items: center;
  height: 36px;
  max-height: 36px;
  max-width: 160px;
  overflow: hidden;
  text-decoration: none;
  flex-shrink: 0;
}

.brand-logo-img {
  height: 34px !important;
  max-height: 34px !important;
  width: auto !important;
  max-width: 155px !important;
  object-fit: contain !important;
  display: inline-block;
  transition: transform var(--duration-fast) var(--ease-spring);
}

.site-brand:hover .brand-logo-img {
  transform: scale(1.02);
}

.brand-logo-dark {
  display: inline-block !important;
}

.brand-logo-light {
  display: none !important;
}

[data-theme="light"] .brand-logo-dark {
  display: none !important;
}

[data-theme="light"] .brand-logo-light {
  display: inline-block !important;
}

/* Center Desktop Navigation */
.header-nav {
  display: flex;
  align-items: center;
}

.header-nav-list {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.header-nav-link {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-secondary);
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  transition: all var(--duration-fast) var(--ease-smooth);
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  line-height: 1;
  text-decoration: none;
}

.header-nav-link:hover,
.header-nav-dropdown-item:hover .header-dropdown-trigger {
  color: var(--text-primary);
  background: var(--bg-card);
  border-color: var(--border-subtle);
}

/* Dropdown Menu for SaaS Apps */
.header-nav-dropdown-item {
  position: relative;
}

.dropdown-chevron {
  transition: transform var(--duration-fast) var(--ease-smooth);
}

.header-nav-dropdown-item:hover .dropdown-chevron {
  transform: rotate(180deg);
}

.header-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  width: 300px;
  background: var(--bg-surface);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xl);
  padding: var(--space-3);
  box-shadow: var(--shadow-xl), 0 0 35px -10px var(--brand-primary-glow);
  opacity: 0;
  visibility: hidden;
  transition: all var(--duration-normal) var(--ease-spring);
  z-index: var(--z-dropdown);
}

.header-nav-dropdown-item:hover .header-dropdown-menu,
.header-nav-dropdown-item:focus-within .header-dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.dropdown-link {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: background var(--duration-fast) var(--ease-smooth);
}

.dropdown-link:hover {
  background: var(--bg-elevated);
}

.dropdown-link-icon {
  font-size: 1.15rem;
  line-height: 1;
  margin-top: 1px;
}

.dropdown-link-title {
  display: block;
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.dropdown-link-desc {
  display: block;
  font-size: var(--text-xs);
  color: var(--text-muted);
  line-height: 1.4;
}

/* Header Right Actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-shrink: 0;
}

.header-search-wrap {
  position: relative;
  width: 200px;
  transition: width var(--duration-normal) var(--ease-spring);
}

.header-search-wrap:focus-within {
  width: 280px;
}

.header-search-input {
  width: 100%;
  padding: 0.45rem 2.5rem 0.45rem 2.2rem;
  border-radius: var(--radius-full);
  background: var(--bg-input);
  border: 1px solid var(--border-medium);
  color: var(--text-primary);
  font-size: var(--text-xs);
  transition: all var(--duration-fast) var(--ease-smooth);
}

.header-search-input:focus {
  border-color: var(--brand-primary);
  background: var(--bg-surface);
  box-shadow: 0 0 0 3px var(--brand-primary-light);
  outline: none;
}

.header-search-icon {
  position: absolute;
  left: 0.8rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.search-key-hint {
  position: absolute;
  right: 0.65rem;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  padding: 1px 4px;
  pointer-events: none;
}

.cart-btn-indicator {
  position: relative;
}

.cart-count-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--brand-primary);
  color: #07090e;
  font-size: 10px;
  font-weight: 800;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 10px var(--brand-primary-glow);
}

/* Mobile Hamburger Button */
.mobile-menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 0;
  transition: all var(--duration-fast) var(--ease-smooth);
}

.mobile-menu-toggle:hover {
  background: var(--bg-card-hover);
  border-color: var(--brand-primary);
}

.hamburger-bar {
  width: 18px;
  height: 2px;
  background-color: var(--text-primary);
  border-radius: var(--radius-full);
  transition: all var(--duration-normal) var(--ease-spring);
}

body.drawer-open .hamburger-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

body.drawer-open .hamburger-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

body.drawer-open .hamburger-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ====================================================
   MOBILE SLIDE-OUT NAVIGATION DRAWER
   ==================================================== */
.mobile-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(7, 9, 14, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: var(--z-modal-backdrop);
  opacity: 0;
  visibility: hidden;
  transition: all var(--duration-normal) var(--ease-smooth);
}

body.drawer-open .mobile-drawer-backdrop {
  opacity: 1;
  visibility: visible;
}

.mobile-nav-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(86vw, 360px);
  background: var(--bg-surface);
  border-left: 1px solid var(--border-medium);
  box-shadow: var(--shadow-xl);
  z-index: var(--z-modal);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform var(--duration-slow) var(--ease-spring);
  overflow-y: auto;
}

body.drawer-open .mobile-nav-drawer {
  transform: translateX(0);
}

.mobile-drawer-header {
  padding: var(--space-5) var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-drawer-close {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-smooth);
}

.mobile-drawer-close:hover {
  color: var(--text-primary);
  border-color: var(--brand-primary);
}

.mobile-drawer-search {
  padding: var(--space-4) var(--space-6);
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-drawer-content {
  padding: var(--space-6);
  flex: 1;
  overflow-y: auto;
}

.mobile-drawer-group-label {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: var(--space-3);
}

.mobile-drawer-nav {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: 0.65rem var(--space-3);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all var(--duration-fast) var(--ease-smooth);
}

.mobile-nav-link:hover {
  background: var(--bg-card);
  color: var(--text-primary);
}

.mobile-nav-icon {
  font-size: 1.15rem;
  line-height: 1;
}

.mobile-drawer-footer {
  padding: var(--space-5) var(--space-6);
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-surface);
}

/* Responsive Header Breakpoints */
@media (max-width: 1080px) {
  .header-search-wrap {
    display: none;
  }
}

@media (max-width: 960px) {
  .header-nav {
    display: none;
  }
  .header-account-btn {
    display: none;
  }
  .mobile-menu-toggle {
    display: flex;
  }
}

@media (max-width: 640px) {
  .site-header {
    height: 64px;
  }
  .brand-logo-img {
    height: 32px;
  }
}

/* ====================================================
   FOOTER
   ==================================================== */
.site-footer {
  margin-top: auto;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-subtle);
  padding: var(--space-16) 0 var(--space-8);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-10);
  margin-bottom: var(--space-12);
}

@media (max-width: 900px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-8);
  }
}
@media (max-width: 580px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: var(--space-6);
  }
}

.footer-heading {
  font-size: var(--text-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-primary);
  margin-bottom: var(--space-4);
}

.footer-nav li {
  margin-bottom: var(--space-3);
}

.footer-nav a {
  color: var(--text-secondary);
  font-size: var(--text-sm);
}
.footer-nav a:hover {
  color: var(--brand-primary);
}

.footer-bottom {
  padding-top: var(--space-8);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-4);
  font-size: var(--text-sm);
  color: var(--text-muted);
}

/* ==========================================================================
   WooCommerce Modern UI Overrides (Cart, Checkout & Notices)
   ========================================================================== */

/* Notice Banners */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-6);
  margin-bottom: var(--space-6);
  border-radius: var(--radius-lg);
  font-size: var(--text-sm);
  line-height: 1.5;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  list-style: none;
}

.woocommerce-message {
  border-left: 4px solid var(--brand-emerald, #10b981);
}

.woocommerce-info {
  border-left: 4px solid var(--brand-primary);
}

.woocommerce-error {
  border-left: 4px solid #ef4444;
}

.woocommerce-message a.button,
.woocommerce-info a.button {
  order: 2;
  margin-left: auto;
  padding: 0.35rem 0.85rem;
  font-size: var(--text-xs);
  border-radius: var(--radius-full);
  background: var(--brand-primary);
  color: #fff;
  border: none;
  text-decoration: none;
  font-weight: 600;
  transition: all var(--duration-fast) var(--ease-smooth);
}

.woocommerce-message a.button:hover,
.woocommerce-info a.button:hover {
  filter: brightness(1.15);
  transform: translateY(-1px);
}

/* WooCommerce Buttons */
.woocommerce #respond input#submit,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit.alt,
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 0.65rem 1.4rem;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--brand-primary) 0%, var(--brand-primary-hover) 100%);
  color: #ffffff;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 14px var(--brand-primary-light);
  transition: all var(--duration-normal) var(--ease-spring);
  text-decoration: none;
}

.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover,
.woocommerce input.button.alt:hover {
  background: linear-gradient(135deg, var(--brand-primary-hover) 0%, var(--brand-primary) 100%);
  box-shadow: 0 6px 20px var(--brand-primary-light);
  transform: translateY(-2px);
  color: #ffffff;
}

/* Secondary Button (Coupon, Update Cart) */
.woocommerce button[name="apply_coupon"],
.woocommerce button[name="update_cart"] {
  background: var(--bg-surface);
  color: var(--text-primary);
  border: 1px solid var(--border-medium);
  box-shadow: none;
}

.woocommerce button[name="apply_coupon"]:hover,
.woocommerce button[name="update_cart"]:hover {
  background: var(--bg-card);
  border-color: var(--brand-primary);
  color: var(--brand-primary);
  box-shadow: 0 2px 8px var(--brand-primary-light);
}

/* Tables in Cart & Checkout */
.woocommerce table.shop_table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: var(--bg-card);
  margin-bottom: var(--space-8);
}

.woocommerce table.shop_table th {
  padding: var(--space-4) var(--space-6);
  background: var(--bg-surface);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-subtle);
}

.woocommerce table.shop_table td {
  padding: var(--space-4) var(--space-6);
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-size: var(--text-sm);
  vertical-align: middle;
}

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

/* Forms & Inputs */
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.woocommerce-input-wrapper input {
  width: 100%;
  padding: 0.65rem 1rem;
  border-radius: var(--radius-md);
  background: var(--bg-input);
  border: 1px solid var(--border-medium);
  color: var(--text-primary);
  font-size: var(--text-sm);
  transition: all var(--duration-fast) var(--ease-smooth);
}

.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce form .form-row select:focus,
.woocommerce-input-wrapper input:focus {
  outline: none;
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px var(--brand-primary-light);
}

/* Cart & Checkout Gutenberg Blocks Styling */
.wp-block-woocommerce-cart,
.wp-block-woocommerce-checkout {
  color: var(--text-primary);
}

.wp-block-woocommerce-cart .wc-block-components-sidebar,
.wp-block-woocommerce-checkout .wc-block-components-sidebar {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
}

.wc-block-components-totals-item,
.wc-block-components-order-summary-item {
  color: var(--text-primary);
}

.wc-block-components-button:not(.is-link) {
  border-radius: var(--radius-lg) !important;
  font-family: var(--font-body) !important;
  font-weight: 600 !important;
}

/* ==========================================================================
   Editorial & Blog Typography (.entry-content)
   ========================================================================== */

#readingProgressBar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--brand-primary) 0%, var(--brand-cyan) 100%);
  width: 0%;
  z-index: 99999;
  transition: width 0.08s ease-out;
}

.entry-content {
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 1.08rem;
  line-height: 1.85;
}

.entry-content > p:first-of-type {
  font-size: 1.18rem;
  line-height: 1.8;
  color: var(--text-primary);
  font-weight: 450;
  margin-bottom: var(--space-6);
}

.entry-content p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
  font-family: var(--font-display);
  color: var(--text-primary);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.entry-content h2 {
  font-size: 1.85rem;
  margin-top: 3rem;
  margin-bottom: 1.15rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border-subtle);
}

.entry-content h3 {
  font-size: 1.38rem;
  margin-top: 2.25rem;
  margin-bottom: 0.85rem;
}

.entry-content h4 {
  font-size: 1.15rem;
  margin-top: 1.75rem;
  margin-bottom: 0.65rem;
}

.entry-content a {
  color: var(--brand-primary);
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: color var(--duration-fast) var(--ease-smooth);
}

.entry-content a:hover {
  color: var(--brand-cyan);
}

.entry-content ul,
.entry-content ol {
  padding-left: 1.5rem;
  margin-bottom: 1.75rem;
  color: var(--text-secondary);
}

.entry-content li {
  margin-bottom: 0.65rem;
  line-height: 1.75;
}

.entry-content ul li::marker {
  color: var(--brand-primary);
}

.entry-content ol li::marker {
  color: var(--brand-primary);
  font-weight: 700;
}

/* Blockquotes / Callouts */
.entry-content blockquote,
.entry-content .wp-block-quote {
  position: relative;
  margin: 2rem 0;
  padding: 1.25rem 1.75rem;
  background: var(--bg-surface);
  border-left: 4px solid var(--brand-primary);
  border-radius: 0 var(--radius-xl) var(--radius-xl) 0;
  font-style: italic;
  color: var(--text-primary);
  box-shadow: var(--shadow-sm);
}

.entry-content blockquote p {
  color: var(--text-primary);
  margin-bottom: 0;
}

/* Code Blocks & Inline Code */
.entry-content code:not(pre code) {
  font-family: var(--font-mono);
  font-size: 0.88em;
  padding: 0.2rem 0.45rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-sm);
  color: var(--brand-cyan);
}

.entry-content pre,
.entry-content .wp-block-code {
  position: relative;
  background: #080c16 !important;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  margin: 2rem 0;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  line-height: 1.65;
  color: #f1f5f9;
  box-shadow: var(--shadow-lg);
}

.entry-content pre code {
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  color: inherit !important;
  font-size: inherit;
}

/* Images & Figures */
.entry-content figure,
.entry-content img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-xl);
  margin: 2rem 0;
}

.entry-content figcaption {
  text-align: center;
  font-size: var(--text-xs);
  color: var(--text-tertiary);
  margin-top: 0.5rem;
}

/* Tables inside Articles & Policies */
.entry-content table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin: 2rem 0;
}

.entry-content table th {
  padding: var(--space-4) var(--space-6);
  background: var(--bg-surface);
  color: var(--text-primary);
  font-weight: 700;
  font-size: var(--text-sm);
  border-bottom: 1px solid var(--border-subtle);
}

.entry-content table td {
  padding: var(--space-4) var(--space-6);
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: var(--text-sm);
}

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

/* ==========================================================================
   Editorial Components (Share Strip, Related Posts, Author Cards)
   ========================================================================== */

.article-share-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-4);
  padding: var(--space-4) 0;
  margin: var(--space-8) 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.share-buttons-group {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0.45rem 0.95rem;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  border: 1px solid var(--border-medium);
  color: var(--text-secondary);
  font-size: var(--text-xs);
  font-weight: 600;
  text-decoration: none;
  transition: all var(--duration-fast) var(--ease-smooth);
  cursor: pointer;
}

.share-btn:hover {
  background: var(--bg-elevated);
  border-color: var(--brand-primary);
  color: var(--text-primary);
  transform: translateY(-1px);
}

/* Related Articles Grid */
.related-articles-section {
  margin-top: var(--space-16);
  padding-top: var(--space-12);
  border-top: 1px solid var(--border-subtle);
}

.related-articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-6);
  margin-top: var(--space-8);
}

/* ==========================================================================
   Blog Index Enhancements (Featured Hero & Newsletter Card)
   ========================================================================== */

.blog-featured-card {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: var(--space-8);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: hidden;
  margin-bottom: var(--space-12);
  box-shadow: var(--shadow-lg);
  transition: all var(--duration-normal) var(--ease-spring);
}

.blog-featured-card:hover {
  border-color: var(--brand-primary-glow);
  box-shadow: var(--shadow-xl), 0 0 30px -10px var(--brand-primary-glow);
}

.blog-featured-thumb {
  position: relative;
  overflow: hidden;
  min-height: 320px;
}

.blog-featured-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease-spring);
}

.blog-featured-card:hover .blog-featured-thumb img {
  transform: scale(1.05);
}

.blog-featured-content {
  padding: var(--space-8);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

@media (max-width: 900px) {
  .blog-featured-card {
    grid-template-columns: 1fr;
  }
  .blog-featured-thumb {
    min-height: 240px;
  }
}

/* Developer Newsletter Card */
.developer-newsletter-card {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.7) 0%, rgba(15, 23, 42, 0.9) 100%);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-2xl);
  padding: var(--space-10);
  margin: var(--space-12) 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.developer-newsletter-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: 50%;
  transform: translateX(-50%);
  width: 400px;
  height: 200px;
  background: radial-gradient(circle, var(--brand-primary-glow) 0%, transparent 70%);
  pointer-events: none;
}

/* Category Filter Pills on Blog */
.blog-filter-pills {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
  margin-bottom: var(--space-8);
}

/* ==========================================================================
   Responsive Page Layouts (Contact, Licensing, FAQ)
   ========================================================================== */

/* Responsive Contact Layout */
.contact-layout-grid {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  gap: var(--space-10);
}

@media (max-width: 860px) {
  .contact-layout-grid {
    grid-template-columns: 1fr;
  }
}

/* Responsive Licensing Comparison Grid */
.licensing-comparison-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-8);
  margin-bottom: var(--space-12);
}

@media (max-width: 860px) {
  .licensing-comparison-grid {
    grid-template-columns: 1fr;
  }
}

/* Form Controls */
.form-control-input,
.form-control-select,
.form-control-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  background: var(--bg-input);
  border: 1px solid var(--border-medium);
  color: var(--text-primary);
  font-size: var(--text-sm);
  font-family: var(--font-body);
  transition: all var(--duration-fast) var(--ease-smooth);
}

.form-control-input:focus,
.form-control-select:focus,
.form-control-textarea:focus {
  outline: none;
  border-color: var(--brand-primary);
  background: var(--bg-surface);
  box-shadow: 0 0 0 3px var(--brand-primary-light);
}

/* FAQ Accordion Component */
.faq-accordion-wrap {
  margin-top: var(--space-16);
  max-width: 840px;
  margin-left: auto;
  margin-right: auto;
}

.faq-accordion-item {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  margin-bottom: var(--space-4);
  overflow: hidden;
  transition: border-color var(--duration-fast) var(--ease-smooth);
}

.faq-accordion-item:hover {
  border-color: var(--border-medium);
}

.faq-question-btn {
  width: 100%;
  padding: var(--space-5) var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  background: none;
  border: none;
  color: var(--text-primary);
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: 700;
  text-align: left;
  cursor: pointer;
}

.faq-question-btn .faq-icon {
  width: 20px;
  height: 20px;
  transition: transform var(--duration-fast) var(--ease-spring);
  color: var(--brand-primary);
  flex-shrink: 0;
}

.faq-accordion-item.is-open .faq-icon {
  transform: rotate(180deg);
}

.faq-answer-panel {
  display: none;
  padding: 0 var(--space-6) var(--space-6);
  color: var(--text-secondary);
  font-size: var(--text-sm);
  line-height: 1.7;
}

.faq-accordion-item.is-open .faq-answer-panel {
  display: block;
}

