/* ============================================================
   RANKAYA — Global Design System
   ============================================================ */

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

/* ── CSS Custom Properties ── */
:root {
  /* Colors */
  --color-bg:          #0A0A0A;
  --color-bg-card:     #111111;
  --color-bg-elevated: #161616;
  --color-accent:      #00FF88;
  --color-accent-dim:  rgba(0, 255, 136, 0.12);
  --color-accent-glow: rgba(0, 255, 136, 0.25);
  --color-white:       #FFFFFF;
  --color-text-muted:  #888888;
  --color-text-dim:    #555555;
  --color-border:      rgba(255, 255, 255, 0.08);
  --color-border-hover:rgba(255, 255, 255, 0.16);

  /* Typography */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-size-xs:   0.75rem;
  --font-size-sm:   0.875rem;
  --font-size-base: 1rem;
  --font-size-lg:   1.125rem;
  --font-size-xl:   1.25rem;
  --font-size-2xl:  1.5rem;
  --font-size-3xl:  2rem;
  --font-size-4xl:  2.5rem;
  --font-size-hero: clamp(2.5rem, 6vw, 5rem);
  --line-height:    1.7;

  /* Spacing (8px base unit) */
  --space-1:  0.5rem;   /* 8px */
  --space-2:  1rem;     /* 16px */
  --space-3:  1.5rem;   /* 24px */
  --space-4:  2rem;     /* 32px */
  --space-5:  2.5rem;   /* 40px */
  --space-6:  3rem;     /* 48px */
  --space-8:  4rem;     /* 64px */
  --space-10: 5rem;     /* 80px */
  --space-12: 6.25rem;  /* 100px */

  /* Section padding */
  --section-padding: 100px;
  --section-padding-mobile: 60px;

  /* Borders & Radius */
  --radius-sm:   6px;
  --radius-md:   12px;
  --radius-lg:   20px;
  --radius-xl:   32px;
  --radius-full: 9999px;

  /* Transitions */
  --transition: 0.3s ease;
  --transition-slow: 0.6s ease;

  /* Shadows */
  --shadow-card: 0 4px 24px rgba(0,0,0,0.4);
  --shadow-glow: 0 0 30px var(--color-accent-glow);
  --shadow-glow-strong: 0 0 60px rgba(0, 255, 136, 0.35);

  /* Layout */
  --container-max: 1200px;
  --container-padding: 1.5rem;
  --header-height: 80px;
}

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

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

body {
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  line-height: var(--line-height);
  color: var(--color-white);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

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

ul, ol {
  list-style: none;
}

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

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

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

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

/* ── Typography ── */
h1, h2, h3, h4, h5, h6 {
  line-height: 1.15;
  font-weight: 700;
  color: var(--color-white);
}

h1 { font-size: var(--font-size-hero); font-weight: 800; }
h2 { font-size: var(--font-size-4xl); }
h3 { font-size: var(--font-size-3xl); }
h4 { font-size: var(--font-size-2xl); }
h5 { font-size: var(--font-size-xl); }
h6 { font-size: var(--font-size-lg); }

p { color: var(--color-text-muted); }

/* ── Accent Label ── */
.label {
  display: inline-block;
  font-size: var(--font-size-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--color-accent);
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 0.75rem 1.75rem;
  border-radius: var(--radius-full);
  font-size: var(--font-size-sm);
  font-weight: 600;
  transition: all var(--transition);
  white-space: nowrap;
  cursor: pointer;
  text-decoration: none;
}

.btn-primary {
  background: var(--color-accent);
  color: #000;
  border: 2px solid var(--color-accent);
}
.btn-primary:hover {
  background: transparent;
  color: var(--color-accent);
  box-shadow: var(--shadow-glow);
}

.btn-outline {
  background: transparent;
  color: var(--color-white);
  border: 2px solid var(--color-border-hover);
}
.btn-outline:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

.btn-ghost {
  background: transparent;
  color: var(--color-accent);
  border: none;
  padding-inline: 0;
  gap: 0.5rem;
}
.btn-ghost:hover { gap: 0.75rem; }
.btn-ghost svg { transition: transform var(--transition); }
.btn-ghost:hover svg { transform: translateX(4px); }

/* ── Cards ── */
.card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  transition: all var(--transition);
}
.card:hover {
  border-color: var(--color-accent-dim);
  box-shadow: var(--shadow-glow);
  transform: translateY(-4px);
}

.card-glass {
  background: rgba(17, 17, 17, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  transition: all var(--transition);
}
.card-glass:hover {
  border-color: rgba(0, 255, 136, 0.2);
  box-shadow: var(--shadow-glow);
  transform: translateY(-4px);
}

/* ── Badge Pill ── */
.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  background: var(--color-accent-dim);
  color: var(--color-accent);
  border: 1px solid rgba(0, 255, 136, 0.2);
}

/* ── Section Header ── */
.section-header {
  margin-bottom: var(--space-8);
}
.section-header .label {
  margin-bottom: var(--space-2);
}
.section-header h2 {
  margin-bottom: var(--space-2);
}
.section-header p {
  max-width: 600px;
  font-size: var(--font-size-lg);
}
.section-header.centered {
  text-align: center;
}
.section-header.centered p {
  margin-inline: auto;
}

/* ── Divider ── */
.divider {
  width: 48px;
  height: 3px;
  background: var(--color-accent);
  margin-block: var(--space-3);
  border-radius: var(--radius-full);
}
.divider.centered { margin-inline: auto; }

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

/* ── 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     { display: flex; flex-direction: column; }
.gap-2        { gap: var(--space-2); }
.gap-3        { gap: var(--space-3); }
.gap-4        { gap: var(--space-4); }

/* ── Scroll Reveal ── */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ── Page Hero (inner pages) ── */
.page-hero {
  padding-top: calc(var(--header-height) + 80px);
  padding-bottom: 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(0,255,136,0.06) 0%, transparent 70%);
  pointer-events: none;
}
.page-hero .label { margin-bottom: var(--space-2); }
.page-hero h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  margin-bottom: var(--space-3);
}
.page-hero p {
  font-size: var(--font-size-lg);
  max-width: 580px;
  margin-inline: auto;
}

/* ── CTA Banner ── */
.cta-banner {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-10) var(--space-8);
  text-align: center;
  position: relative;
  overflow: hidden;
  margin: var(--space-8) 0;
}
.cta-banner::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-accent), transparent);
}
.cta-banner h3 {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  margin-bottom: var(--space-2);
}
.cta-banner p {
  max-width: 480px;
  margin-inline: auto;
  margin-bottom: var(--space-5);
}

/* ── WhatsApp Floating Button ── */
.whatsapp-float {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 56px;
  height: 56px;
  background: #25D366;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  transition: all var(--transition);
  z-index: 9000;
}
.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 30px rgba(37, 211, 102, 0.6);
}
.whatsapp-float svg { width: 28px; height: 28px; }

/* ── Grain texture overlay ── */
.grain-overlay {
  position: relative;
}
.grain-overlay::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  opacity: 0.4;
  z-index: 0;
}
.grain-overlay > * { position: relative; z-index: 1; }

/* ── Text Utilities ── */
.text-accent  { color: var(--color-accent); }
.text-muted   { color: var(--color-text-muted); }
.text-white   { color: var(--color-white); }
.text-center  { text-align: center; }
.fw-800       { font-weight: 800; }
.fw-700       { font-weight: 700; }
.fw-600       { font-weight: 600; }

/* ── Responsive ── */
@media (max-width: 1199px) {
  :root {
    --section-padding: 80px;
  }
}

@media (max-width: 767px) {
  :root {
    --section-padding: var(--section-padding-mobile);
    --container-padding: 1.25rem;
  }
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }
  h2 { font-size: 1.9rem; }
  h3 { font-size: 1.6rem; }
  .cta-banner {
    padding: var(--space-8) var(--space-3);
  }
}
