/* ============================================================
   IrishLegalDocs.ie - Core Design System
   Version: 1.0.0
   ============================================================ */

/* --- CSS Variables / Design Tokens --- */
:root {
  /* Colour Architecture */
  --color-primary: #0B3D2E;
  --color-primary-light: #E8F8F0;
  --color-primary-rgb: 11, 61, 46;
  --color-accent: #157F4F;
  --color-accent-hover: #126C43;
  --color-accent-rgb: 21, 127, 79;
  --color-surface: #FFFFFF;
  --color-background: #FAF8F4;
  --color-text: #1A1A1A;
  --color-text-secondary: #6B7280;
  --color-text-tertiary: #646E7A;
  --color-border: #E5E7EB;
  --color-border-hover: #D1D5DB;
  --color-success: #10B981;
  --color-warning: #F59E0B;
  --color-error: #EF4444;

  /* Spacing System (8px base) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-7: 32px;
  --space-8: 40px;
  --space-9: 48px;
  --space-10: 64px;
  --space-11: 80px;
  --space-12: 96px;
  --space-13: 128px;

  /* Typography Scale */
  --text-xs: 12px;
  --lh-xs: 16px;
  --text-sm: 14px;
  --lh-sm: 20px;
  --text-base: 16px;
  --lh-base: 24px;
  --text-lg: 18px;
  --lh-lg: 28px;
  --text-xl: 20px;
  --lh-xl: 28px;
  --text-2xl: 24px;
  --lh-2xl: 32px;
  --text-3xl: 30px;
  --lh-3xl: 36px;
  --text-4xl: 36px;
  --lh-4xl: 40px;
  --text-5xl: 48px;
  --lh-5xl: 56px;
  --text-6xl: 60px;
  --lh-6xl: 68px;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.04);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.08), 0 8px 10px -6px rgba(0,0,0,0.04);
  --shadow-glow: 0 0 0 3px rgba(var(--color-accent-rgb), 0.15);

  /* Border Radius */
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 24px;
  --radius-full: 9999px;

  /* Layout */
  --nav-height: 64px;
  --max-width: 1200px;
  --content-width: 720px;
}


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

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

body {
  font-family: Georgia, 'Times New Roman', Times, serif;
  font-size: var(--text-base);
  line-height: 1.5;
  color: var(--color-text);
  background-color: var(--color-background);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

ul, ol {
  list-style: none;
}

input, textarea, select {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-base);
}


/* --- Skip to Content --- */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  background: var(--color-primary);
  color: #fff;
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-md);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  z-index: 9999;
  transition: top 0.2s;
}

.skip-link:focus {
  top: var(--space-3);
}


/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.15;
  color: var(--color-text);
}

h1 { font-size: var(--text-5xl); line-height: var(--lh-5xl); }
h2 { font-size: var(--text-3xl); line-height: var(--lh-3xl); }
h3 { font-size: var(--text-xl); line-height: var(--lh-xl); }
h4 { font-size: var(--text-lg); line-height: var(--lh-lg); }

@media (max-width: 768px) {
  h1 { font-size: var(--text-3xl); line-height: var(--lh-3xl); }
  h2 { font-size: var(--text-2xl); line-height: var(--lh-2xl); }
  h3 { font-size: var(--text-lg); line-height: var(--lh-lg); }
}

.ui-text {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

p {
  margin-bottom: var(--space-6);
}

p:last-child {
  margin-bottom: 0;
}


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

@media (max-width: 768px) {
  .container {
    padding: 0 var(--space-4);
  }
}

.section {
  padding: var(--space-12) 0;
}

@media (max-width: 768px) {
  .section {
    padding: var(--space-10) 0;
  }
}

.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto var(--space-10);
}

.section-header p {
  font-size: var(--text-lg);
  color: var(--color-text-secondary);
  margin-top: var(--space-4);
}

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

.section--dark {
  background: linear-gradient(135deg, var(--color-primary) 0%, #072A1F 100%);
  color: #fff;
}

.section--dark h2,
.section--dark h3,
.section--dark h4 {
  color: #fff;
}

.section--dark p {
  color: rgba(255,255,255,0.8);
}


/* --- Navigation --- */
.nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  height: var(--nav-height);
  transition: box-shadow 0.3s ease;
}

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

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

.nav__logo {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700;
  font-size: var(--text-xl);
  color: var(--color-primary);
  text-decoration: none;
  flex-shrink: 0;
}

.nav__logo svg {
  width: 36px;
  height: 36px;
}

.nav__logo .logo-dot {
  color: var(--color-accent);
}

.nav__links {
  display: flex;
  align-items: center;
  gap: var(--space-5);
}

.nav__link {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 500;
  font-size: 15px;
  color: var(--color-text-secondary);
  text-decoration: none;
  position: relative;
  padding: var(--space-2) 0;
  transition: color 0.2s ease;
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--color-accent);
  transition: width 0.25s ease, left 0.25s ease;
}

.nav__link:hover {
  color: var(--color-text);
}

.nav__link:hover::after {
  width: 100%;
  left: 0;
}

.nav__link--active {
  color: var(--color-primary);
}

.nav__link--active::after {
  width: 100%;
  left: 0;
}

/* Mega Dropdown */
.nav__dropdown-trigger {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.nav__dropdown-trigger svg {
  width: 16px;
  height: 16px;
  transition: transform 0.2s ease;
}

.nav__dropdown-trigger:hover svg,
.nav__dropdown-trigger[aria-expanded="true"] svg {
  transform: rotate(180deg);
}

.mega-dropdown {
  position: absolute;
  top: var(--nav-height);
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  width: 720px;
  max-width: calc(100vw - var(--space-8));
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  padding: var(--space-7);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease-out, transform 0.2s ease-out, visibility 0.2s;
  z-index: 999;
}

.mega-dropdown.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.mega-dropdown__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-6);
}

.mega-dropdown__category {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-3);
}

.mega-dropdown__link {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-3);
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: background 0.15s ease;
  min-height: 40px;
}

.mega-dropdown__link:hover {
  background: var(--color-primary-light);
}

.mega-dropdown__link-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: var(--color-accent);
}

.mega-dropdown__link-text {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text);
}

.mega-dropdown__link-desc {
  font-size: var(--text-xs);
  color: var(--color-text-tertiary);
  font-weight: 400;
}

/* Nav CTA */
.nav__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 0 var(--space-5);
  background: var(--color-accent);
  color: #fff;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-sm);
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: background 0.2s ease, transform 0.1s ease;
  white-space: nowrap;
}

.nav__cta:hover {
  background: var(--color-accent-hover);
}

.nav__cta:active {
  transform: scale(0.97);
}

/* Hamburger */
.nav__hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 44px;
  height: 44px;
  cursor: pointer;
  gap: 5px;
}

.nav__hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--color-text);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav__hamburger.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav__hamburger.active span:nth-child(2) {
  opacity: 0;
}

.nav__hamburger.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Nav Overlay */
.mobile-nav {
  position: fixed;
  top: var(--nav-height);
  right: 0;
  width: 100%;
  height: calc(100vh - var(--nav-height));
  background: var(--color-surface);
  z-index: 998;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  overflow-y: auto;
  padding: var(--space-6);
}

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

.mobile-nav__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-xl);
  font-weight: 500;
  color: var(--color-text);
  padding: var(--space-4) 0;
  border-bottom: 1px solid var(--color-border);
  text-decoration: none;
  min-height: 56px;
}

.mobile-nav__cta {
  display: block;
  width: 100%;
  text-align: center;
  background: var(--color-accent);
  color: #fff;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-lg);
  padding: var(--space-4);
  border-radius: var(--radius-md);
  margin-top: var(--space-7);
  text-decoration: none;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-nav__cta:hover {
  background: var(--color-accent-hover);
}

/* Mobile accordion in mega dropdown */
.mobile-nav__accordion {
  padding-left: var(--space-4);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.mobile-nav__accordion.open {
  max-height: 1000px;
}

.mobile-nav__accordion a {
  display: block;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-base);
  color: var(--color-text-secondary);
  padding: var(--space-3) 0;
  text-decoration: none;
}

@media (max-width: 900px) {
  .nav__links { display: none; }
  .nav__cta--desktop { display: none; }
  .nav__hamburger { display: flex; }
}


/* --- Breadcrumbs --- */
.breadcrumbs {
  padding: var(--space-3) 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  color: var(--color-text-tertiary);
}

.breadcrumbs a {
  color: var(--color-text-tertiary);
  text-decoration: none;
  transition: color 0.15s;
}

.breadcrumbs a:hover {
  color: var(--color-text);
}

.breadcrumbs__sep {
  margin: 0 var(--space-2);
  opacity: 0.5;
}

.breadcrumbs__current {
  color: var(--color-text);
}


/* --- Hero Sections --- */
.hero {
  min-height: 85vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--color-background) 0%, var(--color-primary-light) 100%);
  position: relative;
  overflow: hidden;
}

.hero__content {
  max-width: 640px;
  position: relative;
  z-index: 2;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-accent);
  background: rgba(var(--color-accent-rgb), 0.1);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  margin-bottom: var(--space-6);
}

.hero h1 {
  line-height: 1.12;
  margin-bottom: var(--space-5);
}

.hero__sub {
  font-size: var(--text-xl);
  color: var(--color-text-secondary);
  max-width: 520px;
  line-height: 1.5;
}

.hero__ctas {
  display: flex;
  gap: var(--space-4);
  margin-top: var(--space-8);
  flex-wrap: wrap;
}

.hero__trust {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-5);
  margin-top: var(--space-10);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  color: var(--color-text-tertiary);
}

.hero__trust-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.hero__trust-item svg {
  width: 16px;
  height: 16px;
  color: var(--color-accent);
  flex-shrink: 0;
}

/* Hero geometric decoration */
.hero__decoration {
  position: absolute;
  right: -80px;
  top: 50%;
  transform: translateY(-50%);
  width: 560px;
  height: 560px;
  opacity: 0.08;
  z-index: 1;
}

@media (max-width: 768px) {
  .hero {
    min-height: 70vh;
    padding: var(--space-10) 0 var(--space-12);
  }
  .hero__decoration { display: none; }
  .hero__trust { gap: var(--space-3); }
}

/* Hero entrance animations */
.hero__anim-1 {
  opacity: 0;
  transform: translateY(20px);
  animation: heroFadeUp 0.6s ease-out forwards;
}

.hero__anim-2 {
  opacity: 0;
  transform: translateY(20px);
  animation: heroFadeUp 0.6s ease-out 0.15s forwards;
}

.hero__anim-3 {
  opacity: 0;
  transform: translateY(20px);
  animation: heroFadeUp 0.6s ease-out 0.3s forwards;
}

.hero__anim-4 {
  opacity: 0;
  animation: heroFadeIn 0.5s ease-out 0.5s forwards;
}

@keyframes heroFadeUp {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes heroFadeIn {
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .hero__anim-1,
  .hero__anim-2,
  .hero__anim-3,
  .hero__anim-4 {
    opacity: 1;
    transform: none;
    animation: none;
  }
}

/* Secondary hero (inner pages) */
.hero--secondary {
  min-height: auto;
  padding: var(--space-10) 0;
  background: var(--color-primary-light);
}

@media (max-width: 768px) {
  .hero--secondary {
    padding: var(--space-8) 0;
  }
}


/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-lg);
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: background 0.2s ease, transform 0.1s ease, box-shadow 0.2s ease;
  cursor: pointer;
  white-space: nowrap;
}

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

.btn--primary {
  height: 52px;
  padding: 0 var(--space-7);
  background: var(--color-accent);
  color: #fff;
  box-shadow: var(--shadow-md);
}

.btn--primary:hover {
  background: var(--color-accent-hover);
  box-shadow: var(--shadow-lg);
}

.btn--secondary {
  height: 52px;
  padding: 0 var(--space-7);
  background: transparent;
  color: var(--color-text);
  border: 1px solid var(--color-border);
}

.btn--secondary:hover {
  border-color: var(--color-border-hover);
  background: rgba(0,0,0,0.02);
}

.btn--sm {
  height: 40px;
  padding: 0 var(--space-5);
  font-size: var(--text-sm);
}

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

.btn--ghost {
  height: 40px;
  padding: 0 var(--space-4);
  background: transparent;
  color: var(--color-accent);
  font-size: var(--text-sm);
}

.btn--ghost:hover {
  background: rgba(var(--color-accent-rgb), 0.08);
}

@media (max-width: 480px) {
  .btn--primary,
  .btn--secondary {
    width: 100%;
    justify-content: center;
  }
  .hero__ctas {
    flex-direction: column;
  }
}


/* --- Cards --- */
.card-grid {
  display: grid;
  gap: var(--space-6);
}

.card-grid--3 {
  grid-template-columns: repeat(3, 1fr);
}

.card-grid--4 {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 900px) {
  .card-grid--3, .card-grid--4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .card-grid--3, .card-grid--4 {
    grid-template-columns: 1fr;
  }
}

/* Product Card */
.product-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease-out, box-shadow 0.25s ease-out;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.product-card--featured {
  border-top: 3px solid var(--color-accent);
  position: relative;
}

.product-card__badge {
  position: absolute;
  top: -14px;
  left: var(--space-6);
  background: var(--color-accent);
  color: #fff;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-xs);
  font-weight: 700;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.product-card__icon {
  width: 48px;
  height: 48px;
  background: var(--color-primary-light);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-5);
}

.product-card__icon svg {
  width: 24px;
  height: 24px;
  color: var(--color-primary);
}

.product-card__title {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-lg);
  margin-bottom: var(--space-3);
}

.product-card__desc {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  margin-bottom: var(--space-5);
  flex: 1;
}

.product-card__price {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700;
  font-size: var(--text-2xl);
  color: var(--color-primary);
  margin-bottom: var(--space-5);
}

.product-card__price span {
  font-size: var(--text-sm);
  font-weight: 400;
  color: var(--color-text-tertiary);
}

.product-card .btn {
  margin-top: auto;
}

/* Content Card */
.content-card {
  display: block;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-decoration: none;
  transition: transform 0.25s ease-out, box-shadow 0.25s ease-out;
}

.content-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.content-card__img {
  aspect-ratio: 16/9;
  overflow: hidden;
}

.content-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.content-card:hover .content-card__img img {
  transform: scale(1.05);
}

.content-card__body {
  padding: var(--space-5);
}

.content-card__category {
  display: inline-block;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-accent);
  background: rgba(var(--color-accent-rgb), 0.1);
  padding: 2px var(--space-3);
  border-radius: var(--radius-full);
  margin-bottom: var(--space-3);
}

.content-card__title {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-lg);
  color: var(--color-text);
  margin-bottom: var(--space-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.content-card__meta {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-xs);
  color: var(--color-text-tertiary);
}


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

@media (max-width: 768px) {
  .steps {
    grid-template-columns: 1fr;
    gap: var(--space-7);
  }
}

.step {
  text-align: center;
  position: relative;
}

.step__number {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-full);
  background: var(--color-accent);
  color: #fff;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700;
  font-size: var(--text-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-5);
}

.step__title {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-lg);
  margin-bottom: var(--space-3);
}

.step__desc {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  max-width: 280px;
  margin: 0 auto;
}

/* Connector line (desktop) */
.steps::before {
  content: '';
  position: absolute;
  top: 28px;
  left: calc(16.66% + 28px);
  right: calc(16.66% + 28px);
  height: 2px;
  background: var(--color-border);
}

@media (max-width: 768px) {
  .steps::before { display: none; }
}


/* --- Two-Mode Tabs --- */
.mode-tabs {
  display: flex;
  justify-content: center;
  gap: var(--space-1);
  margin-bottom: var(--space-8);
  position: relative;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  padding: var(--space-1);
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

.mode-tab {
  position: relative;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-base);
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-full);
  cursor: pointer;
  color: var(--color-text-secondary);
  transition: color 0.25s ease;
  z-index: 1;
  background: none;
  border: none;
}

.mode-tab--active {
  color: #fff;
}

.mode-tabs__slider {
  position: absolute;
  top: var(--space-1);
  bottom: var(--space-1);
  left: var(--space-1);
  width: calc(50% - var(--space-1));
  background: var(--color-primary);
  border-radius: var(--radius-full);
  transition: transform 0.3s ease;
  z-index: 0;
}

.mode-tabs__slider--right {
  transform: translateX(100%);
}

.mode-content {
  display: none;
  animation: fadeIn 0.3s ease;
}

.mode-content--active {
  display: block;
}

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


/* --- Document Grid (homepage) --- */
.doc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
}

@media (max-width: 900px) {
  .doc-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .doc-grid { grid-template-columns: 1fr; }
}

.doc-item {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-5);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.doc-item:hover {
  border-color: var(--color-accent);
  box-shadow: var(--shadow-md);
}

.doc-item__icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  background: var(--color-primary-light);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
}

.doc-item__icon svg {
  width: 20px;
  height: 20px;
  color: var(--color-primary);
}

.doc-item__text {
  flex: 1;
  min-width: 0;
}

.doc-item__title {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-sm);
  color: var(--color-text);
}

.doc-item__price {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-xs);
  color: var(--color-accent);
  font-weight: 600;
}


/* --- Feature Cards (Generate vs Analyse) --- */
.feature-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-6);
}

@media (max-width: 768px) {
  .feature-cards { grid-template-columns: 1fr; }
}

.feature-card {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
}

.feature-card__icon {
  width: 56px;
  height: 56px;
  background: rgba(var(--color-accent-rgb), 0.15);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-5);
}

.feature-card__icon svg {
  width: 28px;
  height: 28px;
  color: var(--color-accent);
}

.feature-card h3 {
  margin-bottom: var(--space-3);
}

.feature-card ul {
  margin-top: var(--space-5);
}

.feature-card li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.8);
}

.feature-card li svg {
  width: 18px;
  height: 18px;
  color: var(--color-accent);
  flex-shrink: 0;
  margin-top: 2px;
}


/* --- Testimonials --- */
.testimonial-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-7);
}

.testimonial-card__stars {
  display: flex;
  gap: 2px;
  margin-bottom: var(--space-4);
}

.testimonial-card__stars svg {
  width: 18px;
  height: 18px;
  color: var(--color-warning);
  fill: var(--color-warning);
}

.testimonial-card__text {
  font-style: italic;
  color: var(--color-text-secondary);
  margin-bottom: var(--space-5);
  line-height: 1.65;
}

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

.testimonial-card__avatar {
  width: 40px;
  height: 40px;
  background: var(--color-primary-light);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700;
  color: var(--color-primary);
  font-size: var(--text-sm);
}

.testimonial-card__name {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-sm);
}

.testimonial-card__role {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-xs);
  color: var(--color-text-tertiary);
}


/* --- FAQ Accordion --- */
.faq-list {
  max-width: 720px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--color-border);
}

.faq-item__question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: var(--space-5) 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-base);
  color: var(--color-text);
  text-align: left;
  cursor: pointer;
  background: none;
  border: none;
  gap: var(--space-4);
  min-height: 44px;
}

.faq-item__question svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--color-text-tertiary);
  transition: transform 0.25s ease;
}

.faq-item.open .faq-item__question svg {
  transform: rotate(45deg);
}

.faq-item__answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}

.faq-item__answer-inner {
  padding: 0 0 var(--space-5);
  color: var(--color-text-secondary);
  font-size: var(--text-sm);
  line-height: 1.65;
}


/* --- Cross-Portfolio CTA Bar --- */
.cross-cta {
  display: flex;
  gap: var(--space-6);
  padding: var(--space-7);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
}

@media (max-width: 768px) {
  .cross-cta { flex-direction: column; }
}

.cross-cta__item {
  flex: 1;
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-5);
  border-radius: var(--radius-lg);
  text-decoration: none;
  transition: background 0.2s ease;
}

.cross-cta__item:hover {
  background: var(--color-primary-light);
}

.cross-cta__icon {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  background: var(--color-primary-light);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
}

.cross-cta__icon svg {
  width: 22px;
  height: 22px;
  color: var(--color-primary);
}

.cross-cta__title {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-sm);
  color: var(--color-text);
}

.cross-cta__desc {
  font-size: var(--text-xs);
  color: var(--color-text-tertiary);
}


/* --- Footer --- */
.footer {
  background: var(--color-primary);
  color: rgba(255,255,255,0.8);
  padding: var(--space-12) 0 var(--space-8);
}

.footer__grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: var(--space-8);
  margin-bottom: var(--space-10);
}

@media (max-width: 900px) {
  .footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .footer__grid {
    grid-template-columns: 1fr;
  }
}

.footer__brand {
  max-width: 280px;
}

.footer__logo {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700;
  font-size: var(--text-xl);
  color: #fff;
  margin-bottom: var(--space-4);
}

.footer__logo .logo-dot {
  color: var(--color-accent);
}

.footer__brand p {
  font-size: var(--text-sm);
  line-height: 1.6;
  color: rgba(255,255,255,0.6);
}

.footer__heading {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-5);
}

.footer__link {
  display: block;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  padding: var(--space-2) 0;
  transition: color 0.15s;
}

.footer__link:hover {
  color: #fff;
}

.footer__bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: var(--space-7);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-4);
}

.footer__copy {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.4);
}

.footer__bottom-links {
  display: flex;
  gap: var(--space-5);
}

.footer__bottom-links a {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.4);
  text-decoration: none;
  transition: color 0.15s;
}

.footer__bottom-links a:hover {
  color: rgba(255,255,255,0.7);
}


/* --- Newsletter (footer) --- */
.footer__newsletter {
  margin-top: var(--space-5);
}

.footer__newsletter-form {
  display: flex;
  gap: var(--space-2);
}

.footer__newsletter-input {
  flex: 1;
  height: 40px;
  padding: 0 var(--space-4);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius-md);
  color: #fff;
  font-size: var(--text-sm);
}

.footer__newsletter-input::placeholder {
  color: rgba(255,255,255,0.4);
}

.footer__newsletter-input:focus {
  outline: none;
  border-color: var(--color-accent);
}

.footer__newsletter-btn {
  height: 40px;
  padding: 0 var(--space-5);
  background: var(--color-accent);
  color: #fff;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-sm);
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.footer__newsletter-btn:hover {
  background: var(--color-accent-hover);
}

.footer__newsletter-consent {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  margin-top: var(--space-3);
}

.footer__newsletter-consent input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  accent-color: var(--color-accent);
}

.footer__newsletter-consent label {
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  line-height: 1.4;
}


/* --- Cookie Consent --- */
.cookie-banner {
  position: fixed;
  bottom: var(--space-5);
  left: var(--space-5);
  max-width: 420px;
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  padding: var(--space-6);
  z-index: 9999;
  transform: translateY(120%);
  transition: transform 0.4s ease;
}

.cookie-banner.visible {
  transform: translateY(0);
}

.cookie-banner__text {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  margin-bottom: var(--space-4);
  line-height: 1.5;
}

.cookie-banner__text a {
  color: var(--color-accent);
  text-decoration: underline;
}

.cookie-banner__actions {
  display: flex;
  gap: var(--space-3);
}

.cookie-banner__accept {
  height: 36px;
  padding: 0 var(--space-5);
  background: var(--color-accent);
  color: #fff;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 600;
  font-size: var(--text-sm);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background 0.2s;
}

.cookie-banner__accept:hover {
  background: var(--color-accent-hover);
}

.cookie-banner__decline {
  height: 36px;
  padding: 0 var(--space-4);
  background: none;
  color: var(--color-text-secondary);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 500;
  font-size: var(--text-sm);
  border: none;
  cursor: pointer;
}

.cookie-banner__decline:hover {
  color: var(--color-text);
}

@media (max-width: 480px) {
  .cookie-banner {
    left: var(--space-3);
    right: var(--space-3);
    max-width: none;
    bottom: var(--space-3);
  }
}


/* --- Focus & Accessibility --- */
*:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* Minimum touch target helper */
.touch-target {
  min-width: 44px;
  min-height: 44px;
}


/* --- Scroll Reveal (JS adds .revealed) --- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}


/* --- Stat Counter Animation --- */
.stat-number {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700;
  font-size: var(--text-4xl);
  color: var(--color-accent);
}

.stat-label {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
}


/* --- Pricing Table (placeholder for pricing.html) --- */
.pricing-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  margin-bottom: var(--space-8);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
}


/* --- Utility Classes --- */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-accent { color: var(--color-accent); }
.text-secondary { color: var(--color-text-secondary); }
.text-sm { font-size: var(--text-sm); }
.text-xs { font-size: var(--text-xs); }
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.w-full { width: 100%; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
