/* World Design — Design System */
:root {
  /* Brand — from logo */
  --color-primary: #0096c7;
  --color-primary-light: #48cae4;
  --color-primary-dark: #0077b6;
  --color-navy: #03045e;
  --color-navy-deep: #0a0e1a;
  --color-purple: #7c3aed;
  --color-purple-soft: #a78bfa;
  --color-white: #f8f9fa;
  --color-muted: #94a3b8;
  --color-border: rgba(255, 255, 255, 0.08);
  --color-glass: rgba(255, 255, 255, 0.04);
  --color-glass-border: rgba(255, 255, 255, 0.12);

  /* Gradients */
  --gradient-hero: radial-gradient(ellipse 80% 60% at 50% -20%, rgba(0, 150, 199, 0.35), transparent 60%),
    radial-gradient(ellipse 60% 50% at 100% 50%, rgba(124, 58, 237, 0.2), transparent 50%),
    radial-gradient(ellipse 50% 40% at 0% 80%, rgba(0, 119, 182, 0.15), transparent 50%);
  --gradient-card: linear-gradient(135deg, rgba(0, 150, 199, 0.08) 0%, rgba(124, 58, 237, 0.06) 100%);
  --gradient-btn: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 50%, var(--color-purple) 100%);
  --gradient-text: linear-gradient(135deg, var(--color-primary-light) 0%, var(--color-white) 50%, var(--color-purple-soft) 100%);

  /* Typography */
  --font-en: 'Inter', system-ui, sans-serif;
  --font-ar: 'Cairo', 'IBM Plex Sans Arabic', system-ui, sans-serif;

  /* Spacing */
  --section-py: clamp(4rem, 10vw, 7rem);
  --container-max: 1280px;
  --header-h: clamp(68px, 10vw, 84px);

  /* Effects */
  --shadow-glow: 0 0 40px rgba(0, 150, 199, 0.25);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.4);
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --color-navy-deep: #f1f5f9;
  --color-white: #0f172a;
  --color-muted: #64748b;
  --color-border: rgba(15, 23, 42, 0.1);
  --color-glass: rgba(255, 255, 255, 0.7);
  --color-glass-border: rgba(15, 23, 42, 0.08);
  --gradient-hero: radial-gradient(ellipse 80% 60% at 50% -20%, rgba(0, 150, 199, 0.12), transparent 60%),
    radial-gradient(ellipse 60% 50% at 100% 50%, rgba(124, 58, 237, 0.08), transparent 50%);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

html[lang="ar"] body {
  font-family: var(--font-ar);
}

html[lang="en"] body {
  font-family: var(--font-en);
}

body {
  background: transparent;
  color: var(--color-white);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background var(--transition), color var(--transition);
}

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

/* Fallback if cosmic script has not run yet */
body:not(.has-cosmic-header) {
  background: var(--color-navy-deep);
}

/* Cosmic background replaces body::before — see cosmic-bg.css */

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

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

ul {
  list-style: none;
}

.container {
  width: min(100% - 2rem, var(--container-max));
  margin-inline: auto;
  position: relative;
  z-index: 1;
}

.section {
  padding-block: var(--section-py);
  position: relative;
  z-index: 1;
}

main {
  position: relative;
  z-index: 1;
}

/* Inner pages: header over subtle cosmic */
body.has-cosmic-header .page-hero {
  padding-top: calc(var(--header-h) + 2rem);
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-primary-light);
  margin-bottom: 1rem;
}

.section-label::before {
  content: '';
  width: 24px;
  height: 2px;
  background: var(--gradient-btn);
  border-radius: 2px;
}

.section-title {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.section-desc {
  color: var(--color-muted);
  font-size: 1.05rem;
  max-width: 600px;
}

.text-gradient {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

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