/* ============================================================
   KHUVSGUL AI — GLOBAL DESIGN SYSTEM
   style.css
   ============================================================ */

/* ── Google Fonts ─────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* ── CSS Custom Properties ────────────────────────────────── */
:root {
  /* Colors */
  --navy-900:    #0A1628;
  --navy-800:    #0D1E35;
  --navy-700:    #0F2544;
  --navy-600:    #142d52;
  --blue-600:    #0055AA;
  --blue-500:    #0066CC;
  --blue-400:    #1a7fd4;
  --cyan-400:    #00A8E8;
  --cyan-300:    #33BCEF;
  --cyan-200:    #7DDEF8;
  --cyan-glow:   rgba(0,168,232,0.25);
  --white:       #FFFFFF;
  --offwhite:    #F5F7FA;
  --gray-100:    #E8EDF2;
  --gray-200:    #D0D9E4;
  --gray-400:    #8899AA;
  --gray-600:    #556677;
  --text-dark:   #0D1B2A;
  --text-light:  #E0E8F0;
  --text-muted-dark: #8899AA;
  --text-muted-light: #667788;
  --danger:      #E84040;
  --success:     #00C97A;

  /* Typography */
  --font-base:   'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --fw-regular:  400;
  --fw-medium:   500;
  --fw-semibold: 600;
  --fw-bold:     700;
  --fw-extrabold:800;

  /* Spacing */
  --space-1:  4px;
  --space-2:  8px;
  --space-3:  12px;
  --space-4:  16px;
  --space-5:  20px;
  --space-6:  24px;
  --space-8:  32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;
  --space-24: 96px;
  --space-32: 128px;

  /* Border Radius */
  --radius-sm:  6px;
  --radius-md:  12px;
  --radius-lg:  20px;
  --radius-xl:  28px;
  --radius-full:9999px;

  /* Shadows */
  --shadow-sm:  0 2px 8px rgba(0,0,0,0.08);
  --shadow-md:  0 4px 20px rgba(0,0,0,0.12);
  --shadow-lg:  0 8px 40px rgba(0,0,0,0.18);
  --shadow-xl:  0 16px 64px rgba(0,0,0,0.24);
  --shadow-blue:0 0 30px rgba(0,168,232,0.3);
  --shadow-blue-sm: 0 0 15px rgba(0,168,232,0.2);

  /* Transitions */
  --transition-fast: 150ms cubic-bezier(0.4,0,0.2,1);
  --transition-base: 250ms cubic-bezier(0.4,0,0.2,1);
  --transition-slow: 400ms cubic-bezier(0.4,0,0.2,1);

  /* Layout */
  --container-max: 1200px;
  --container-wide: 1400px;
  --section-py: var(--space-24);

  /* Nav */
  --nav-height: 72px;
}

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

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

section[id] {
  scroll-margin-top: calc(var(--nav-height) + 12px);
}

body {
  font-family: var(--font-base);
  font-weight: var(--fw-regular);
  color: var(--text-dark);
  background: var(--white);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

.svg-icon {
  width: 1em;
  height: 1em;
  display: inline-block;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: middle;
}

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

button {
  font-family: var(--font-base);
  cursor: pointer;
  border: none;
  background: none;
}

ul, ol {
  list-style: none;
}

/* ── Skip Link (Accessibility) ────────────────────────────── */
.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  background: var(--blue-500);
  color: var(--white);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-weight: var(--fw-semibold);
  z-index: 9999;
  transition: top var(--transition-fast);
}
.skip-link:focus {
  top: 16px;
}

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

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

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

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

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

/* Backgrounds */
.bg-dark    { background: var(--navy-900); color: var(--text-light); }
.bg-dark-2  { background: var(--navy-800); color: var(--text-light); }
.bg-dark-3  { background: var(--navy-700); color: var(--text-light); }
.bg-light   { background: var(--offwhite); }
.bg-white   { background: var(--white); }
.bg-gradient-dark {
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-700) 100%);
  color: var(--text-light);
}
.bg-gradient-dark-blue {
  background: linear-gradient(135deg, var(--navy-900) 0%, #0a2040 60%, #0d2d5a 100%);
  color: var(--text-light);
}

/* Grid */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-8);
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
}
.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-6);
}
.grid-auto {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-6);
}

/* Flex utilities */
.flex        { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between{ display: flex; align-items: center; justify-content: space-between; }
.flex-col    { flex-direction: column; }
.gap-2       { gap: var(--space-2); }
.gap-3       { gap: var(--space-3); }
.gap-4       { gap: var(--space-4); }
.gap-6       { gap: var(--space-6); }
.gap-8       { gap: var(--space-8); }

/* Text alignment */
.text-center  { text-align: center; }
.text-left    { text-align: left; }
.text-right   { text-align: right; }

/* ── Typography ───────────────────────────────────────────── */
.heading-display {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: var(--fw-extrabold);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.heading-1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: var(--fw-bold);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.heading-2 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: var(--fw-bold);
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.heading-3 {
  font-size: clamp(1.2rem, 2vw, 1.6rem);
  font-weight: var(--fw-semibold);
  line-height: 1.3;
}

.heading-4 {
  font-size: 1.1rem;
  font-weight: var(--fw-semibold);
  line-height: 1.4;
}

.body-lg {
  font-size: 1.125rem;
  line-height: 1.75;
}

.body-md {
  font-size: 1rem;
  line-height: 1.7;
}

.body-sm {
  font-size: 0.875rem;
  line-height: 1.6;
}

.label {
  font-size: 0.75rem;
  font-weight: var(--fw-semibold);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.text-accent  { color: var(--cyan-400); }
.text-blue    { color: var(--blue-500); }
.text-muted   { color: var(--gray-600); }
.text-muted-light { color: var(--gray-400); }
.text-white   { color: var(--white); }

/* Section label */
.section-label {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: var(--fw-semibold);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cyan-400);
  margin-bottom: var(--space-4);
  position: relative;
  padding-left: 28px;
}
.section-label::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 2px;
  background: var(--cyan-400);
}

/* ── Buttons ──────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 14px 32px;
  border-radius: var(--radius-full);
  font-size: 0.9rem;
  font-weight: var(--fw-semibold);
  letter-spacing: 0.04em;
  transition: all var(--transition-base);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

.btn--primary {
  background: linear-gradient(135deg, var(--blue-500), var(--cyan-400));
  color: var(--white);
  box-shadow: 0 4px 20px rgba(0,102,204,0.35);
}
.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(0,102,204,0.5), 0 0 20px rgba(0,168,232,0.3);
}
.btn--primary:active {
  transform: translateY(0);
}

.btn--outline {
  background: transparent;
  border: 2px solid var(--cyan-400);
  color: var(--cyan-400);
}
.btn--outline:hover {
  background: var(--cyan-400);
  color: var(--navy-900);
  transform: translateY(-2px);
  box-shadow: var(--shadow-blue-sm);
}

.btn--ghost-light {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.2);
  color: var(--white);
  backdrop-filter: blur(8px);
}
.btn--ghost-light:hover {
  background: rgba(255,255,255,0.15);
  border-color: rgba(255,255,255,0.4);
  transform: translateY(-2px);
}

.btn--sm {
  padding: 10px 22px;
  font-size: 0.82rem;
}

.btn--lg {
  padding: 18px 42px;
  font-size: 1rem;
}

/* Ripple inner element */
.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0);
  transition: background var(--transition-fast);
}
.btn:hover::after {
  background: rgba(255,255,255,0.04);
}

/* ── Cards ────────────────────────────────────────────────── */
.card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  box-shadow: var(--shadow-md);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.dark-card {
  background: var(--navy-700);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  transition: transform var(--transition-base), border-color var(--transition-base), box-shadow var(--transition-base);
}
.dark-card:hover {
  transform: translateY(-4px);
  border-color: var(--cyan-400);
  box-shadow: 0 0 20px rgba(0,168,232,0.15);
}

.glass-card {
  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  transition: border-color var(--transition-base), box-shadow var(--transition-base);
}
.glass-card:hover {
  border-color: rgba(0,168,232,0.4);
  box-shadow: 0 0 25px rgba(0,168,232,0.12);
}

.glass-card--light {
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(0,102,204,0.12);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  box-shadow: var(--shadow-sm);
}

/* ── Badge / Pill ─────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: var(--fw-medium);
  transition: all var(--transition-fast);
}

.badge--blue {
  background: rgba(0,102,204,0.12);
  color: var(--blue-500);
  border: 1px solid rgba(0,102,204,0.2);
}
.badge--blue:hover {
  background: var(--blue-500);
  color: var(--white);
}

.badge--cyan {
  background: rgba(0,168,232,0.12);
  color: var(--cyan-400);
  border: 1px solid rgba(0,168,232,0.2);
}

.badge--dark {
  background: var(--navy-700);
  color: var(--text-light);
  border: 1px solid rgba(255,255,255,0.08);
}
.badge--dark:hover {
  background: var(--blue-500);
  border-color: var(--blue-500);
}

.badge--light {
  background: var(--gray-100);
  color: var(--text-dark);
  border: 1px solid var(--gray-200);
}

/* ── Section Header ───────────────────────────────────────── */
.section-header {
  margin-bottom: var(--space-16);
}

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

.section-header p {
  margin-top: var(--space-4);
  color: var(--gray-600);
  font-size: 1.05rem;
}

.section-header.dark p {
  color: var(--text-muted-dark);
}

/* ── Divider ──────────────────────────────────────────────── */
.divider {
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--blue-500), var(--cyan-400));
  border-radius: var(--radius-full);
  margin: var(--space-4) 0;
}

.divider--center {
  margin: var(--space-4) auto;
}

/* ── CTA Strip ────────────────────────────────────────────── */
.cta-strip {
  padding: var(--space-20) 0;
  background: linear-gradient(135deg, var(--navy-900), var(--navy-700));
  text-align: center;
}

.cta-strip .heading-2 {
  color: var(--white);
  margin-bottom: var(--space-4);
}

.cta-strip p {
  color: var(--text-muted-dark);
  margin-bottom: var(--space-8);
  font-size: 1.05rem;
}

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

/* ── Icon circle ──────────────────────────────────────────── */
.icon-circle {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-full);
  background: rgba(0,168,232,0.12);
  border: 1px solid rgba(0,168,232,0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
  transition: background var(--transition-base);
}

.icon-circle--lg {
  width: 72px;
  height: 72px;
  font-size: 2rem;
}

/* ── Glow Elements ────────────────────────────────────────── */
.glow-dot {
  width: 6px;
  height: 6px;
  background: var(--cyan-400);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--cyan-400), 0 0 20px var(--cyan-400);
}

/* ── Site Footer ──────────────────────────────────────────── */
.site-footer {
  padding: var(--space-8) 0 var(--space-6);
}

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

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

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 1024px) {
  :root {
    --section-py: var(--space-20);
  }
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  :root {
    --section-py: var(--space-16);
  }
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .container {
    padding: 0 var(--space-5);
  }
  .btn--lg {
    padding: 14px 28px;
    font-size: 0.9rem;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-8);
  }
}

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

/* ── Print ────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
