/*
Theme Name: Arkhis IPTV
Theme URI: https://arkhis.pro
Author: Arkhis
Author URI: https://arkhis.pro
Description: Ultra-fast, SEO-optimized custom theme for IPTV subscription service. Built for PageSpeed 100, clean minimal design, full WooCommerce support. RTL Arabic ready.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.9
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: arkhis
Tags: rtl-language, arabic, woocommerce, minimal, fast, iptv, one-page
*/

/* ==========================================================================
   Font face declarations — font-display:swap prevents invisible text (FOIT)
   size-adjust prevents layout shift when font swaps (CLS fix)
   ========================================================================== */
@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url('https://fonts.gstatic.com/s/cairo/v28/SLXVc1nY6HkvangtZmpcWmhzfH5lWWgcQyyS4J0.woff2') format('woff2');
}

/* ==========================================================================
   CSS Custom Properties
   ========================================================================== */
:root {
  /* Colors */
  --color-primary: #5B5BD6;
  --color-primary-dark: #4747c0;
  --color-primary-light: #ebebff;
  --color-accent: #FF6B35;
  --color-text: #0F0F14;
  --color-text-muted: #6B6B80;
  --color-text-light: #9999B0;
  --color-bg: #FFFFFF;
  --color-bg-alt: #F7F7FB;
  --color-bg-dark: #0F0F14;
  --color-border: #E8E8F0;
  --color-border-light: #F0F0F8;
  --color-success: #0A5C2B;
  --color-error: #EF4444;
  --color-warning: #F59E0B;
  --color-white: #FFFFFF;

  /* Typography */
  --font-heading: 'Cairo', 'Tajawal', system-ui, sans-serif;
  --font-body: 'Cairo', 'Tajawal', system-ui, sans-serif;
  --font-mono: 'Courier New', monospace;

  /* Font Sizes */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 1.875rem;
  --text-4xl: 2.25rem;
  --text-5xl: 3rem;
  --text-6xl: 3.75rem;

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* Layout */
  --container-max: 1200px;
  --container-narrow: 760px;
  --container-wide: 1400px;

  /* Borders */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow-md: 0 4px 16px rgba(0,0,0,.08), 0 2px 6px rgba(0,0,0,.04);
  --shadow-lg: 0 10px 40px rgba(0,0,0,.10), 0 4px 12px rgba(0,0,0,.06);
  --shadow-xl: 0 20px 60px rgba(0,0,0,.12), 0 8px 20px rgba(0,0,0,.08);
  --shadow-primary: 0 8px 30px rgba(91,91,214,.25);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 400ms ease;

  /* Z-index */
  --z-base: 1;
  --z-sticky: 100;
  --z-overlay: 200;
  --z-modal: 300;
  --z-tooltip: 400;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-bg);
  direction: rtl;
  overflow-x: hidden;
}

body.ltr {
  direction: ltr;
}

img, svg, video {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover { color: var(--color-primary-dark); }

ul, ol { list-style: none; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.25;
  color: var(--color-text);
}

p { margin-bottom: var(--space-4); }
p:last-child { margin-bottom: 0; }

input, textarea, select, button {
  font-family: inherit;
  font-size: inherit;
}

button { cursor: pointer; }

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* Skip to content */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  z-index: var(--z-tooltip);
  padding: var(--space-3) var(--space-6);
  background: var(--color-primary);
  color: var(--color-white);
  border-radius: var(--radius-md);
  font-weight: 600;
  transition: top var(--transition-fast);
}
.skip-link:focus { top: var(--space-4); }

/* ==========================================================================
   Layout
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-6);
}

.container--narrow { max-width: var(--container-narrow); }
.container--wide   { max-width: var(--container-wide); }

.section {
  padding-block: var(--space-24);
}

.section--sm { padding-block: var(--space-16); }
.section--lg { padding-block: var(--space-32); }

/* Grid helpers */
.grid { display: grid; }
.flex { display: flex; }

/* ==========================================================================
   Typography
   ========================================================================== */
.heading-xl {
  font-size: clamp(var(--text-3xl), 5vw, var(--text-6xl));
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.heading-lg {
  font-size: clamp(var(--text-2xl), 3.5vw, var(--text-4xl));
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.heading-md {
  font-size: clamp(var(--text-xl), 2.5vw, var(--text-3xl));
  font-weight: 700;
  line-height: 1.3;
}

.text-muted { color: var(--color-text-muted); }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-8);
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: var(--text-base);
  line-height: 1.5;
  border: 2px solid transparent;
  transition: all var(--transition-base);
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
}

.btn--primary {
  background: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
  box-shadow: var(--shadow-primary);
}
.btn--primary:hover {
  background: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
  box-shadow: 0 12px 35px rgba(91,91,214,.35);
  transform: translateY(-1px);
  color: var(--color-white);
}

.btn--outline {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}
.btn--outline:hover {
  background: var(--color-primary-light);
  color: var(--color-primary-dark);
}

.btn--ghost {
  background: transparent;
  color: var(--color-text);
  border-color: var(--color-border);
}
.btn--ghost:hover {
  background: var(--color-bg-alt);
  border-color: var(--color-text-light);
}

.btn--lg {
  padding: var(--space-4) var(--space-10);
  font-size: var(--text-lg);
}

.btn--sm {
  padding: var(--space-2) var(--space-5);
  font-size: var(--text-sm);
}

.btn--full { width: 100%; }

/* ==========================================================================
   Badges & Tags
   ========================================================================== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

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

.badge--accent {
  background: #FFF3EE;
  color: var(--color-accent);
}

.badge--success {
  background: #ECFDF5;
  color: var(--color-success);
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--color-border-light);
  transition: box-shadow var(--transition-base);
}

.site-header.scrolled {
  box-shadow: var(--shadow-md);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
  gap: var(--space-8);
}

.site-logo {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
  flex-shrink: 0;
}

.site-logo img {
  height: 40px;
  width: auto;
}

.site-logo-text {
  font-size: var(--text-xl);
  font-weight: 800;
  color: var(--color-text);
  letter-spacing: -0.02em;
}

.site-logo-text span {
  color: var(--color-primary);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.main-nav a {
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
  transition: all var(--transition-fast);
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--color-text);
  background: var(--color-bg-alt);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.cart-icon {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  color: var(--color-text-muted);
  transition: all var(--transition-fast);
  border: 1px solid var(--color-border);
}

.cart-icon:hover {
  background: var(--color-bg-alt);
  color: var(--color-text);
  border-color: var(--color-text-light);
}

.cart-count {
  position: absolute;
  top: -6px;
  left: -6px;
  width: 18px;
  height: 18px;
  background: var(--color-primary);
  color: white;
  border-radius: var(--radius-full);
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* Mobile menu toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  padding: 4px;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: all var(--transition-base);
}

.nav-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
  padding-block: var(--space-24) var(--space-20);
  background: linear-gradient(160deg, var(--color-bg) 0%, var(--color-bg-alt) 100%);
  overflow: hidden;
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 70%;
  height: 150%;
  background: radial-gradient(ellipse, rgba(91,91,214,.07) 0%, transparent 70%);
  pointer-events: none;
  /* CLS fix: contain so it doesn't affect layout */
  contain: strict;
  will-change: auto;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-16);
  align-items: center;
}

.hero-content {
  max-width: 560px;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-5);
}

.hero-eyebrow-dot {
  width: 8px;
  height: 8px;
  background: var(--color-success);
  border-radius: var(--radius-full);
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34,197,94,.4); }
  50% { box-shadow: 0 0 0 6px rgba(34,197,94,0); }
}

.hero-title {
  font-size: clamp(var(--text-3xl), 4.5vw, var(--text-5xl));
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: var(--space-5);
  color: var(--color-text);
}

.hero-title .highlight {
  color: var(--color-primary);
  position: relative;
}

.hero-title .highlight::after {
  content: '';
  position: absolute;
  bottom: 2px;
  right: 0;
  left: 0;
  height: 3px;
  background: var(--color-primary-light);
  border-radius: var(--radius-full);
}

.hero-desc {
  font-size: var(--text-lg);
  color: var(--color-text-muted);
  margin-bottom: var(--space-8);
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  flex-wrap: wrap;
}

.hero-trust {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-8);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.hero-trust-stars {
  display: flex;
  color: #FBBF24;
  font-size: var(--text-base);
  letter-spacing: -1px;
}

.hero-image {
  position: relative;
}

.hero-image-wrap {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  aspect-ratio: 1280 / 955;
  background: var(--color-bg-alt);
}

.hero-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.hero-stats {
  position: absolute;
  bottom: -var(--space-8);
  right: var(--space-6);
  display: flex;
  gap: var(--space-3);
}

.hero-stat-card {
  background: white;
  border-radius: var(--radius-lg);
  padding: var(--space-3) var(--space-5);
  box-shadow: var(--shadow-lg);
  text-align: center;
  min-width: 90px;
}

.hero-stat-num {
  font-size: var(--text-xl);
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1;
}

.hero-stat-label {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-top: var(--space-1);
}

/* Trust Bar */
.trust-bar {
  background: var(--color-bg-alt);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  padding-block: var(--space-5);
}

.trust-bar-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-10);
  flex-wrap: wrap;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text-muted);
}

.trust-item svg {
  width: 18px;
  height: 18px;
  color: var(--color-primary);
  flex-shrink: 0;
}

/* ==========================================================================
   Features Section
   ========================================================================== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-6);
}

.feature-card {
  padding: var(--space-8);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: var(--color-primary);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--transition-base);
}

.feature-card:hover {
  border-color: var(--color-primary-light);
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.feature-card:hover::before {
  transform: scaleX(1);
}

.feature-icon {
  width: 52px;
  height: 52px;
  background: var(--color-primary-light);
  color: var(--color-primary);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-5);
  flex-shrink: 0;
}

.feature-icon svg {
  width: 26px !important;
  height: 26px !important;
  stroke-width: 2;
}

.feature-title {
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-2);
  color: var(--color-text);
}

.feature-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
  margin: 0;
}

/* ==========================================================================
   Stats Section
   ========================================================================== */
.stats-section {
  background: var(--color-bg-dark);
  color: white;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-1);
}

.stat-item {
  padding: var(--space-10) var(--space-8);
  text-align: center;
  border-left: 1px solid rgba(255,255,255,.08);
}

.stat-item:last-child {
  border-left: none;
}

.stat-num {
  font-size: clamp(var(--text-3xl), 4vw, var(--text-5xl));
  font-weight: 800;
  color: white;
  line-height: 1;
  margin-bottom: var(--space-2);
  letter-spacing: -0.03em;
}

.stat-num span {
  color: var(--color-primary);
}

.stat-label {
  font-size: var(--text-sm);
  color: rgba(255,255,255,.5);
  font-weight: 500;
}

/* ==========================================================================
   Icon sizing — critical: prevent SVGs from stretching
   ========================================================================== */
svg {
  display: inline-block;
  flex-shrink: 0;
}

.feature-icon svg {
  width: 26px;
  height: 26px;
}

.trust-item svg {
  width: 18px;
  height: 18px;
}

.pricing-feature svg,
.product-feature-item svg {
  width: 16px;
  height: 16px;
  color: var(--color-success);
}

.pricing-savings svg {
  width: 14px;
  height: 14px;
}

.pricing-note svg {
  width: 16px;
  height: 16px;
  color: var(--color-primary);
}

.footer-social svg { width: 16px; height: 16px; }

.hero-trust svg { display: none; }

/* ==========================================================================
   Pricing Grid — RTL column order fix
   ========================================================================== */
.pricing-section {
  background: var(--color-bg-alt);
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-16);
  max-width: 600px;
  margin-inline: auto;
  margin-bottom: var(--space-16);
}

.section-eyebrow {
  display: inline-block;
  margin-bottom: var(--space-4);
}

.section-title {
  margin-bottom: var(--space-4);
}

.section-desc {
  font-size: var(--text-lg);
  color: var(--color-text-muted);
  margin: 0;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
  align-items: start;
  /* In RTL, grid columns fill right→left. Array order [annual, 6mo, monthly]
     renders as: annual(right) | 6months(center) | monthly(left) ✓ */
  direction: rtl;
}

.pricing-card {
  background: var(--color-bg);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  position: relative;
  transition: all var(--transition-base);
}

.pricing-card:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-xl);
  transform: translateY(-4px);
}

.pricing-card.featured {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-primary);
  position: relative;
  z-index: 1;
}

.pricing-card.featured:hover {
  transform: translateY(-4px);
}

.pricing-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-primary);
  color: white;
  padding: var(--space-1) var(--space-4);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  white-space: nowrap;
}

.pricing-period {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: var(--space-3);
}

.pricing-price {
  display: flex;
  align-items: baseline;
  gap: var(--space-1);
  margin-bottom: var(--space-2);
}

.pricing-currency {
  font-size: var(--text-xl);
  font-weight: 600;
  color: var(--color-text-muted);
}

.pricing-amount {
  font-size: clamp(var(--text-4xl), 5vw, 3.5rem);
  font-weight: 800;
  color: var(--color-text);
  line-height: 1;
  letter-spacing: -0.03em;
}

.pricing-per {
  font-size: var(--text-sm);
  color: var(--color-text-muted); /* was text-light (#9999B0) — fails contrast */
  font-weight: 500;
}

.pricing-savings {
  font-size: var(--text-sm);
  color: #0A5C2B; /* darker green — passes contrast on white bg */
  font-weight: 700;
  margin-bottom: var(--space-6);
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.pricing-divider {
  height: 1px;
  background: var(--color-border);
  margin: var(--space-6) 0;
}

.pricing-features {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-bottom: var(--space-8);
}

.pricing-feature {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.pricing-feature svg {
  width: 16px;
  height: 16px;
  color: var(--color-success);
  flex-shrink: 0;
}

.pricing-note {
  text-align: center;
  margin-top: var(--space-10);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
}

/* ==========================================================================
   How It Works
   ========================================================================== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-8);
  position: relative;
}

.steps-grid::before {
  content: '';
  position: absolute;
  top: 28px;
  right: 16.66%;
  left: 16.66%;
  height: 2px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-primary-light));
}

.step-card {
  text-align: center;
  position: relative;
  z-index: 1;
}

.step-num {
  width: 56px;
  height: 56px;
  background: var(--color-primary);
  color: white;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-xl);
  font-weight: 800;
  margin: 0 auto var(--space-5);
  box-shadow: var(--shadow-primary);
}

.step-title {
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-2);
}

.step-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
  margin: 0;
}

/* ==========================================================================
   Testimonials
   ========================================================================== */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
}

.testimonial-card {
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  transition: all var(--transition-base);
}

.testimonial-card:hover {
  border-color: var(--color-primary-light);
  box-shadow: var(--shadow-md);
}

.testimonial-stars {
  display: flex;
  color: #FBBF24;
  margin-bottom: var(--space-4);
  font-size: var(--text-base);
}

.testimonial-text {
  font-size: var(--text-base);
  color: var(--color-text);
  line-height: 1.8;
  margin-bottom: var(--space-5);
  font-style: italic;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.testimonial-avatar {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: var(--color-primary-light);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: var(--text-base);
  flex-shrink: 0;
}

.testimonial-name {
  font-weight: 700;
  font-size: var(--text-sm);
}

.testimonial-location {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

/* ==========================================================================
   FAQ Section
   ========================================================================== */
.faq-list {
  max-width: 760px;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.faq-item {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color var(--transition-fast);
}

.faq-item.active {
  border-color: var(--color-primary-light);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-5) var(--space-6);
  background: none;
  border: none;
  text-align: right;
  font-size: var(--text-base);
  font-weight: 600;
  color: var(--color-text);
  cursor: pointer;
  gap: var(--space-4);
  line-height: 1.5;
}

.faq-question svg {
  width: 20px;
  height: 20px;
  color: var(--color-primary);
  flex-shrink: 0;
  transition: transform var(--transition-base);
}

.faq-item.active .faq-question svg {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-slow);
}

.faq-item.active .faq-answer {
  max-height: 400px;
}

.faq-answer-inner {
  padding: 0 var(--space-6) var(--space-5);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.8;
}

/* ==========================================================================
   CTA Section
   ========================================================================== */
.cta-section {
  background: var(--color-primary);
  color: white;
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(255,255,255,.08) 0%, transparent 60%);
}

.cta-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 640px;
  margin-inline: auto;
}

.cta-title {
  font-size: clamp(var(--text-2xl), 4vw, var(--text-4xl));
  font-weight: 800;
  color: white;
  margin-bottom: var(--space-4);
  letter-spacing: -0.02em;
}

.cta-desc {
  font-size: var(--text-lg);
  color: rgba(255,255,255,.8);
  margin-bottom: var(--space-8);
}

.cta-actions {
  display: flex;
  gap: var(--space-4);
  justify-content: center;
  flex-wrap: wrap;
}

.btn--white {
  background: white;
  color: var(--color-primary);
  border-color: white;
}
.btn--white:hover {
  background: var(--color-primary-light);
  color: var(--color-primary-dark);
  border-color: white;
}

.btn--outline-white {
  background: transparent;
  color: white;
  border-color: rgba(255,255,255,.5);
}
.btn--outline-white:hover {
  background: rgba(255,255,255,.1);
  border-color: white;
  color: white;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--color-bg-dark);
  color: rgba(255,255,255,.6);
}

.footer-top {
  padding-block: var(--space-16);
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: var(--space-12);
}

.footer-brand {}

.footer-logo {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
  text-decoration: none;
}

.footer-logo-text {
  font-size: var(--text-xl);
  font-weight: 800;
  color: white;
}

.footer-logo-text span { color: var(--color-primary); }

.footer-tagline {
  font-size: var(--text-sm);
  line-height: 1.7;
  margin-bottom: var(--space-6);
  color: rgba(255,255,255,.5);
}

.footer-social {
  display: flex;
  gap: var(--space-3);
}

.social-link {
  width: 36px;
  height: 36px;
  background: rgba(255,255,255,.08);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,.6);
  transition: all var(--transition-fast);
}

.social-link:hover {
  background: var(--color-primary);
  color: white;
}

.social-link svg { width: 16px; height: 16px; }

.footer-col-title {
  font-size: var(--text-sm);
  font-weight: 700;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-5);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer-links a {
  font-size: var(--text-sm);
  color: rgba(255,255,255,.5);
  transition: color var(--transition-fast);
}

.footer-links a:hover { color: white; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding-block: var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: var(--text-sm);
  color: rgba(255,255,255,.6);
}

/* Fix contrast on footer links */
.footer-bottom a {
  color: rgba(255,255,255,.85); /* passes 4.5:1 on dark bg */
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-bottom a:hover {
  color: white;
}

.footer-payments {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.payment-icon {
  width: 40px;
  height: 24px;
  background: rgba(255,255,255,.1);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  color: rgba(255,255,255,.6);
}

/* ==========================================================================
   WooCommerce Base
   ========================================================================== */
.woocommerce-notices-wrapper { margin-bottom: var(--space-6); }

.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
  padding: var(--space-4) var(--space-6);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-4);
  font-size: var(--text-sm);
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.woocommerce-message {
  background: #ECFDF5;
  border: 1px solid #A7F3D0;
  color: #065F46;
}

.woocommerce-info {
  background: var(--color-primary-light);
  border: 1px solid #C7D2FE;
  color: var(--color-primary-dark);
}

.woocommerce-error {
  background: #FEF2F2;
  border: 1px solid #FECACA;
  color: #991B1B;
}

/* ==========================================================================
   Product Cards
   ========================================================================== */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-6);
}

.product-card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: all var(--transition-base);
}

.product-card:hover {
  border-color: var(--color-primary-light);
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.product-card-image {
  position: relative;
  overflow: hidden;
  background: var(--color-bg-alt);
  aspect-ratio: 3/2;
}

.product-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.product-card:hover .product-card-image img {
  transform: scale(1.04);
}

.product-card-body {
  padding: var(--space-6);
}

.product-card-cats {
  font-size: var(--text-xs);
  color: var(--color-primary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-2);
}

.product-card-title {
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-3);
  line-height: 1.4;
}

.product-card-title a { color: inherit; }
.product-card-title a:hover { color: var(--color-primary); }

.product-card-price {
  font-size: var(--text-xl);
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: var(--space-5);
}

/* Single Product */
.single-product-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-16);
  align-items: start;
  padding-block: var(--space-16);
}

.product-gallery-main {
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  background: var(--color-bg-alt);
}

.product-gallery-main img {
  width: 100%;
  height: auto;
}

.product-title {
  font-size: clamp(var(--text-2xl), 3vw, var(--text-4xl));
  font-weight: 800;
  margin-bottom: var(--space-4);
  letter-spacing: -0.02em;
}

.product-price-display {
  font-size: var(--text-4xl);
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: var(--space-6);
}

.product-description {
  color: var(--color-text-muted);
  line-height: 1.8;
  margin-bottom: var(--space-8);
}

.product-features-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-bottom: var(--space-8);
}

.product-feature-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.product-feature-item svg {
  width: 18px;
  height: 18px;
  color: var(--color-success);
  flex-shrink: 0;
}

/* ==========================================================================
   Cart & Checkout
   ========================================================================== */
.woocommerce-cart-form {
  background: var(--color-bg);
}

.cart-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
}

table.shop_table {
  width: 100%;
  border-collapse: collapse;
}

table.shop_table th {
  padding: var(--space-4) var(--space-6);
  text-align: right;
  font-size: var(--text-sm);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
  background: var(--color-bg-alt);
  border-bottom: 1px solid var(--color-border);
}

table.shop_table td {
  padding: var(--space-5) var(--space-6);
  border-bottom: 1px solid var(--color-border-light);
  vertical-align: middle;
}

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

.cart-collaterals {
  margin-top: var(--space-8);
  display: flex;
  justify-content: flex-end;
}

.cart_totals {
  width: 100%;
  max-width: 400px;
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
}

.cart_totals h2 {
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-6);
}

/* Checkout */
.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: var(--space-12);
  align-items: start;
}

.checkout-form-section {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
}

.checkout-form-section h3 {
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-6);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--color-border);
}

.form-group {
  margin-bottom: var(--space-5);
}

.form-label {
  display: block;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: var(--space-2);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg);
  color: var(--color-text);
  font-size: var(--text-base);
  transition: border-color var(--transition-fast);
  appearance: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(91,91,214,.12);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-5);
}

.order-review-box {
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  position: sticky;
  top: 90px;
}

.order-review-box h3 {
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-6);
}

/* ==========================================================================
   Page Templates
   ========================================================================== */
.page-hero {
  padding-block: var(--space-16);
  background: var(--color-bg-alt);
  border-bottom: 1px solid var(--color-border);
}

.page-hero-title {
  font-size: clamp(var(--text-3xl), 4vw, var(--text-5xl));
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: var(--space-3);
}

.page-hero-breadcrumbs {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.breadcrumb-sep { color: var(--color-border); }

/* Content area */
.entry-content {
  font-size: var(--text-lg);
  line-height: 1.9;
  color: var(--color-text-muted);
}

.entry-content h2 {
  font-size: var(--text-2xl);
  color: var(--color-text);
  margin-top: var(--space-10);
  margin-bottom: var(--space-4);
}

.entry-content h3 {
  font-size: var(--text-xl);
  color: var(--color-text);
  margin-top: var(--space-8);
  margin-bottom: var(--space-3);
}

/* ==========================================================================
   Utilities
   ========================================================================== */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border-width: 0;
}

.hidden { display: none !important; }
.relative { position: relative; }

/* Divider */
.divider {
  height: 1px;
  background: var(--color-border);
  margin-block: var(--space-8);
}

/* Loading state */
.loading-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid var(--color-border);
  border-top-color: var(--color-primary);
  border-radius: var(--radius-full);
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; gap: var(--space-12); }
  .hero-image { order: -1; max-width: 500px; margin-inline: auto; }
  .hero-stats { position: static; margin-top: var(--space-4); justify-content: center; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .pricing-grid { grid-template-columns: 1fr; max-width: 400px; margin-inline: auto; direction: rtl; }
  .pricing-card.featured { position: static; box-shadow: var(--shadow-xl); }
  .footer-top { grid-template-columns: 1fr 1fr; gap: var(--space-8); }
  .checkout-layout { grid-template-columns: 1fr; }
  .order-review-box { position: static; }
  .single-product-wrap { grid-template-columns: 1fr; }
  .testimonials-grid { grid-template-columns: 1fr 1fr; }
  .steps-grid { grid-template-columns: 1fr; }
  .steps-grid::before { display: none; }
}

@media (max-width: 768px) {
  :root {
    --space-24: 4rem;
    --space-20: 3rem;
    --space-16: 2.5rem;
    --space-12: 2rem;
  }

  .main-nav { display: none; }
  .nav-toggle { display: flex; }

  .main-nav.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 70px;
    right: 0;
    left: 0;
    bottom: 0;
    background: white;
    z-index: var(--z-overlay);
    padding: var(--space-8);
    gap: var(--space-2);
    border-top: 1px solid var(--color-border);
    overflow-y: auto;
  }

  .main-nav.open a {
    padding: var(--space-4);
    font-size: var(--text-lg);
    border-radius: var(--radius-md);
  }

  .hero { padding-block: var(--space-16) var(--space-12); }
  .hero-title { font-size: clamp(1.75rem, 7vw, 2.5rem); }
  .hero-desc { font-size: var(--text-base); }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn { justify-content: center; }
  .hero-stats { gap: var(--space-2); }
  .hero-stat-card { min-width: 75px; padding: var(--space-2) var(--space-3); }
  .hero-stat-num { font-size: var(--text-lg); }

  .features-grid { grid-template-columns: 1fr; gap: var(--space-4); }
  .feature-card { padding: var(--space-6); }

  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-item { padding: var(--space-6) var(--space-4); }

  .trust-bar-inner { gap: var(--space-4); }
  .trust-item { font-size: var(--text-xs); }

  .pricing-grid { max-width: 100%; gap: var(--space-4); }
  .pricing-card { padding: var(--space-6); }

  .steps-grid { gap: var(--space-8); }
  .step-card { padding: var(--space-2); }

  .testimonials-grid { grid-template-columns: 1fr; gap: var(--space-4); }

  .faq-list { gap: var(--space-2); }
  .faq-question { padding: var(--space-4); font-size: var(--text-sm); }

  .footer-top { grid-template-columns: 1fr; gap: var(--space-6); }
  .footer-bottom { flex-direction: column; gap: var(--space-4); text-align: center; }

  .cta-actions { flex-direction: column; align-items: center; }
  .cta-actions .btn { width: 100%; justify-content: center; max-width: 300px; }

  .form-row { grid-template-columns: 1fr; }
  table.shop_table th, table.shop_table td { padding: var(--space-3) var(--space-4); font-size: var(--text-sm); }

  .section-header { margin-bottom: var(--space-8); }
  .section-desc { font-size: var(--text-base); }
}

@media (max-width: 480px) {
  .container { padding-inline: var(--space-4); }
  .section { padding-block: var(--space-12); }
  .stat-item { padding: var(--space-8) var(--space-5); }
  .pricing-grid { max-width: 100%; }
  .checkout-form-section { padding: var(--space-6); }
  .order-review-box { padding: var(--space-6); }
}

/* Print */
@media print {
  .site-header, .site-footer, .cta-section { display: none; }
}
