/* ============================================================
   ioappio — Shared Stylesheet
   Applies to: index.html, about.html, careers.html,
               privacy.html, terms.html
   ============================================================ */

/* ── 1. CSS Custom Properties ─────────────────────────────── */
:root {
  --c-primary:          #72d8c8;
  --c-primary-dim:      #34a192;
  --c-secondary:        #41e575;
  --c-tertiary:         #c0c1ff;
  --c-bg:               #0b0e11;
  --c-surface:          #111417;
  --c-surface-mid:      #1d2023;
  --c-surface-high:     #272a2e;
  --c-surface-highest:  #323538;
  --c-on-surface:       #e1e2e7;
  --c-on-surface-muted: #bdc9c5;
  --c-outline:          #3d4946;
  --c-error:            #ffb4ab;

  --font-main: 'Montserrat', system-ui, sans-serif;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 32px;
  --radius-full: 9999px;

  --shadow-glow-primary: 0 0 24px rgba(114,216,200,.25);
  --shadow-glow-secondary: 0 0 24px rgba(65,229,117,.25);
  --transition-fast: 0.18s ease;
  --transition-med:  0.35s ease;
  --transition-slow: 0.6s cubic-bezier(.22,1,.36,1);
}

html.light {
  --c-bg:               #f3f7f8;
  --c-surface:          #ffffff;
  --c-surface-mid:      #f0f5f6;
  --c-surface-high:     #e4ecee;
  --c-surface-highest:  #d7e5e8;
  --c-on-surface:       #152327;
  --c-on-surface-muted: #415861;
  --c-outline:          rgba(21,35,39,.18);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-main);
  background-color: var(--c-bg);
  color: var(--c-on-surface);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

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

/* ── 3. Typography Utilities ──────────────────────────────── */
.text-gradient {
  background: linear-gradient(135deg, var(--c-primary) 0%, var(--c-secondary) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-gradient-warm {
  background: linear-gradient(135deg, #72d8c8 0%, #c0c1ff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ── 4. Glass / Card Utilities ────────────────────────────── */
.glass {
  background: rgba(30,41,59,.42);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border: 1px solid rgba(255,255,255,.09);
}

html.light .glass {
  background: rgba(255,255,255,.78);
  border-color: rgba(21,35,39,.12);
}

.card-hover {
  transition: transform var(--transition-med), box-shadow var(--transition-med), border-color var(--transition-med);
}
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow-primary);
  border-color: rgba(114,216,200,.3);
}

/* ── 5. Buttons ───────────────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #128C7E 0%, #25D366 100%);
  color: #fff;
  font-family: var(--font-main);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: .04em;
  padding: 12px 28px;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), opacity var(--transition-fast);
  box-shadow: 0 0 20px rgba(37,211,102,.28);
}
.btn-primary:hover { box-shadow: 0 0 36px rgba(37,211,102,.45); transform: translateY(-1px); }
.btn-primary:active { transform: scale(.96); }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(30,41,59,.42);
  backdrop-filter: blur(12px);
  color: var(--c-on-surface);
  font-family: var(--font-main);
  font-weight: 700;
  font-size: 14px;
  padding: 12px 28px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255,255,255,.12);
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast);
}
.btn-ghost:hover { border-color: var(--c-primary); background: rgba(114,216,200,.08); transform: translateY(-1px); }
html.light .btn-ghost { background: rgba(255,255,255,.8); border-color: rgba(21,35,39,.2); }

/* ── 6. Navigation ────────────────────────────────────────── */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(11,14,17,.78);
  backdrop-filter: blur(18px) saturate(1.5);
  -webkit-backdrop-filter: blur(18px) saturate(1.5);
  border-bottom: 1px solid rgba(255,255,255,.07);
  transition: background var(--transition-med), box-shadow var(--transition-med);
}
.site-nav.scrolled {
  background: rgba(11,14,17,.95);
  box-shadow: 0 4px 32px rgba(0,0,0,.4);
}
html.light .site-nav {
  background: rgba(243,247,248,.82);
  border-bottom-color: rgba(21,35,39,.1);
}

.nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 32px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav-brand {
  font-weight: 800;
  font-size: clamp(24px,4vw,32px);
  color: var(--c-primary);
  letter-spacing: -.02em;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}
.nav-links a {
  font-weight: 600;
  font-size: 14px;
  color: var(--c-on-surface-muted);
  transition: color var(--transition-fast);
  position: relative;
  padding-bottom: 2px;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 0; height: 2px;
  background: var(--c-primary);
  transition: width var(--transition-med);
  border-radius: 2px;
}
.nav-links a:hover, .nav-links a.active { color: var(--c-primary); }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

/* Hamburger */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px; height: 42px;
  background: rgba(30,41,59,.45);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius-sm);
  cursor: pointer;
  padding: 10px;
  transition: background var(--transition-fast);
}
.nav-hamburger span {
  display: block;
  height: 2px;
  background: var(--c-on-surface);
  border-radius: 2px;
  transition: transform var(--transition-med), opacity var(--transition-fast), width var(--transition-med);
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile drawer */
.nav-drawer {
  display: none;
  position: fixed;
  top: 68px; left: 0; right: 0;
  background: rgba(11,14,17,.97);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,255,255,.07);
  padding: 20px 24px 28px;
  z-index: 99;
  flex-direction: column;
  gap: 4px;
  transform: translateY(-8px);
  opacity: 0;
  transition: transform var(--transition-med), opacity var(--transition-med);
}
.nav-drawer.open {
  display: flex;
  transform: translateY(0);
  opacity: 1;
}
html.light .nav-drawer { background: rgba(243,247,248,.98); }
.nav-drawer a {
  display: block;
  padding: 12px 8px;
  font-weight: 600;
  font-size: 16px;
  color: var(--c-on-surface-muted);
  border-bottom: 1px solid rgba(255,255,255,.05);
  transition: color var(--transition-fast), padding-left var(--transition-fast);
}
.nav-drawer a:hover { color: var(--c-primary); padding-left: 16px; }
.nav-drawer .drawer-actions { margin-top: 16px; display: flex; flex-direction: column; gap: 10px; }

/* ── 7. Theme Toggle ──────────────────────────────────────── */
.theme-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px; height: 42px;
  background: rgba(30,41,59,.45);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius-sm);
  cursor: pointer;
  color: var(--c-on-surface-muted);
  transition: background var(--transition-fast), color var(--transition-fast), transform var(--transition-fast);
  font-size: 20px;
}
.theme-btn:hover { background: rgba(114,216,200,.12); color: var(--c-primary); transform: rotate(15deg); }
html.light .theme-btn { background: rgba(255,255,255,.8); border-color: rgba(21,35,39,.15); }

/* ── 8. Section Utilities ─────────────────────────────────── */
.section-wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 32px;
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  background: rgba(114,216,200,.1);
  border: 1px solid rgba(114,216,200,.2);
  border-radius: var(--radius-full);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--c-primary);
  margin-bottom: 16px;
}

/* ── 9. Scroll Reveal ─────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity var(--transition-slow), transform var(--transition-slow);
}
.reveal.active { opacity: 1; transform: translateY(0); }

.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity var(--transition-slow), transform var(--transition-slow);
}
.reveal-left.active { opacity: 1; transform: translateX(0); }

.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity var(--transition-slow), transform var(--transition-slow);
}
.reveal-right.active { opacity: 1; transform: translateX(0); }

.reveal-scale {
  opacity: 0;
  transform: scale(.9);
  transition: opacity var(--transition-slow), transform var(--transition-slow);
}
.reveal-scale.active { opacity: 1; transform: scale(1); }

/* Stagger delays via CSS */
.stagger > *:nth-child(1) { transition-delay: 0s; }
.stagger > *:nth-child(2) { transition-delay: .1s; }
.stagger > *:nth-child(3) { transition-delay: .2s; }
.stagger > *:nth-child(4) { transition-delay: .3s; }
.stagger > *:nth-child(5) { transition-delay: .4s; }

/* ── 10. Keyframe Animations ──────────────────────────────── */

/* Floating up-down */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-12px); }
}
.float       { animation: float 5s ease-in-out infinite; }
.float-slow  { animation: float 8s ease-in-out infinite; }
.float-fast  { animation: float 3s ease-in-out infinite; }

/* Glow pulse */
@keyframes glowPulse {
  0%, 100% { box-shadow: 0 0 20px rgba(114,216,200,.2); }
  50%       { box-shadow: 0 0 40px rgba(114,216,200,.5), 0 0 80px rgba(114,216,200,.15); }
}
.glow-pulse { animation: glowPulse 3s ease-in-out infinite; }

/* Status dot pulse */
@keyframes statusPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: .55; transform: scale(.85); }
}
.status-pulse { animation: statusPulse 2s cubic-bezier(.4,0,.6,1) infinite; }

/* Shimmer sweep */
@keyframes shimmer {
  0%   { background-position: -200% center; }
  100% { background-position:  200% center; }
}
.shimmer {
  background: linear-gradient(90deg,
    rgba(255,255,255,0) 0%,
    rgba(255,255,255,.06) 40%,
    rgba(255,255,255,.12) 50%,
    rgba(255,255,255,.06) 60%,
    rgba(255,255,255,0) 100%
  );
  background-size: 200% auto;
  animation: shimmer 3.5s linear infinite;
}

/* Slow spin */
@keyframes spinSlow {
  to { transform: rotate(360deg); }
}
.spin-slow { animation: spinSlow 20s linear infinite; }

/* Morphing blob */
@keyframes morphBlob {
  0%,100% { border-radius: 60% 40% 55% 45% / 55% 45% 60% 40%; }
  25%     { border-radius: 40% 60% 45% 55% / 45% 55% 40% 60%; }
  50%     { border-radius: 55% 45% 60% 40% / 60% 40% 55% 45%; }
  75%     { border-radius: 45% 55% 40% 60% / 40% 60% 45% 55%; }
}
.morph-blob { animation: morphBlob 10s ease-in-out infinite; }

/* Gradient shift */
@keyframes gradientShift {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
.gradient-animated {
  background-size: 200% 200%;
  animation: gradientShift 6s ease infinite;
}

/* Flow dash animation (used on SVG paths) */
@keyframes dashFlow {
  from { stroke-dashoffset: 200; }
  to   { stroke-dashoffset: 0; }
}

/* Particle drift */
@keyframes particleDrift {
  0%   { transform: translateY(0) translateX(0) scale(1); opacity: .7; }
  33%  { transform: translateY(-30px) translateX(15px) scale(1.1); opacity: .5; }
  66%  { transform: translateY(-15px) translateX(-10px) scale(.9); opacity: .8; }
  100% { transform: translateY(0) translateX(0) scale(1); opacity: .7; }
}

/* Fade-in for page load */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.page-fade-in { animation: fadeIn .7s ease both; }

/* Typing cursor blink */
@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

/* ── 11. SVG Decoration Helpers ───────────────────────────── */
.svg-bg-mesh {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .04;
}
html.light .svg-bg-mesh { opacity: .06; }

.hero-blob {
  position: absolute;
  width: min(700px,90vw);
  height: min(700px,90vw);
  background: radial-gradient(circle, rgba(114,216,200,.12) 0%, transparent 70%);
  filter: blur(60px);
  pointer-events: none;
  z-index: 0;
}

.deco-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(114,216,200,.12);
  pointer-events: none;
}

/* Wave divider wrapper */
.wave-divider {
  width: 100%;
  overflow: hidden;
  line-height: 0;
  margin: 0;
}
.wave-divider svg { display: block; width: 100%; }

/* ── 12. Hero Section ─────────────────────────────────────── */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 16px;
  background: rgba(114,216,200,.08);
  border: 1px solid rgba(114,216,200,.18);
  border-radius: var(--radius-full);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--c-primary);
  margin-bottom: 20px;
}

.hero-title {
  font-size: clamp(38px,7vw,72px);
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -.025em;
  color: var(--c-on-surface);
  max-width: 800px;
}

.hero-subtitle {
  font-size: clamp(16px,2.2vw,18px);
  line-height: 1.65;
  color: var(--c-on-surface-muted);
  max-width: 600px;
  margin: 20px auto 36px;
}

/* Animated flow panel */
.flow-panel {
  position: relative;
  width: 100%;
  max-width: 900px;
  margin: 48px auto 0;
  border-radius: var(--radius-xl);
  overflow: hidden;
  border: 1px solid rgba(114,216,200,.12);
}
.flow-panel::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(114,216,200,.15), rgba(65,229,117,.1), transparent);
  z-index: 0;
  animation: gradientShift 6s ease infinite;
  background-size: 200% 200%;
}

/* ── 13. Feature Cards ────────────────────────────────────── */
.feature-card {
  padding: 28px;
  border-radius: var(--radius-lg);
  background: rgba(30,41,59,.42);
  border: 1px solid rgba(255,255,255,.07);
  backdrop-filter: blur(12px);
  transition: transform var(--transition-med), border-color var(--transition-med), box-shadow var(--transition-med);
  position: relative;
  overflow: hidden;
}
.feature-card::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 60%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(114,216,200,.04), transparent);
  transition: left .6s ease;
}
.feature-card:hover { transform: translateY(-5px); border-color: rgba(114,216,200,.25); box-shadow: 0 12px 40px rgba(0,0,0,.3), var(--shadow-glow-primary); }
.feature-card:hover::after { left: 150%; }

html.light .feature-card { background: #ffffff; border-color: rgba(21,35,39,.1); box-shadow: 0 2px 12px rgba(21,35,39,.08); }

.feature-icon {
  width: 52px; height: 52px;
  border-radius: var(--radius-md);
  background: rgba(114,216,200,.1);
  border: 1px solid rgba(114,216,200,.2);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  transition: background var(--transition-fast), transform var(--transition-fast);
}
.feature-card:hover .feature-icon { background: rgba(114,216,200,.18); transform: scale(1.08); }

/* ── 14. Stats ────────────────────────────────────────────── */
.stat-number {
  font-size: clamp(32px,5vw,48px);
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: 1;
  color: var(--c-primary);
}

/* ── 15. Pricing Cards ────────────────────────────────────── */
.pricing-featured {
  position: relative;
  border-color: var(--c-primary) !important;
  border-width: 2px !important;
}
.pricing-featured .pricing-badge {
  position: absolute;
  top: -14px; left: 50%;
  transform: translateX(-50%);
  background: var(--c-primary);
  color: #003731;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 4px 16px;
  border-radius: var(--radius-full);
  white-space: nowrap;
}

/* ── 16. Footer ───────────────────────────────────────────── */
.site-footer {
  background: rgba(11,14,17,.98);
  border-top: 1px solid rgba(255,255,255,.06);
  padding-top: 64px;
}
html.light .site-footer { background: #f3f7f8; border-top-color: rgba(21,35,39,.1); }

/* ── 17. Page-specific (inner pages) ─────────────────────── */
.inner-wrap {
  max-width: 860px;
  margin: 0 auto;
  padding: 96px 24px 64px;
}

.inner-card {
  padding: 20px 24px;
  border-radius: var(--radius-md);
  background: rgba(30,41,59,.42);
  border: 1px solid rgba(255,255,255,.08);
  margin-bottom: 14px;
  transition: border-color var(--transition-fast);
}
.inner-card:hover { border-color: rgba(114,216,200,.2); }
html.light .inner-card { background: #ffffff; border-color: rgba(21,35,39,.1); }

.inner-card h2 { font-size: 18px; font-weight: 700; color: var(--c-on-surface); margin-bottom: 8px; }
.inner-card p,
.inner-card li { font-size: 14px; line-height: 1.75; color: var(--c-on-surface-muted); }
.inner-card li { margin-left: 16px; margin-bottom: 4px; list-style: disc; }

/* ── 18. Particles CSS ────────────────────────────────────── */
.particles {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}
.particle {
  position: absolute;
  width: 3px; height: 3px;
  border-radius: 50%;
  background: var(--c-primary);
  animation: particleDrift var(--dur, 8s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
  opacity: .4;
}

/* ── 19. Progress Bars ────────────────────────────────────── */
@keyframes fillBar {
  from { width: 0; }
  to   { width: var(--fill, 75%); }
}
.progress-bar {
  height: 6px;
  background: var(--c-surface-highest);
  border-radius: 6px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--c-primary), var(--c-secondary));
  border-radius: 6px;
  width: 0;
  transition: width 1.2s cubic-bezier(.22,1,.36,1);
}
.progress-fill.animated { width: var(--fill, 75%); }

/* ── 20. Responsive ───────────────────────────────────────── */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-hamburger { display: flex; }
  .nav-inner { padding: 0 18px; }

  .section-wrap { padding: 0 18px; }
  .hero-title { font-size: clamp(32px,9vw,48px); }
  .hero-subtitle { font-size: 15px; }

  .inner-wrap { padding: 84px 16px 48px; }
}

@media (max-width: 480px) {
  .nav-inner { height: 60px; }
  .nav-drawer { top: 60px; }

  .hero-title { letter-spacing: -.015em; }
}

/* ── 21. Accessibility ────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

:focus-visible {
  outline: 2px solid var(--c-primary);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── 22. Scrollbar ────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--c-bg); }
::-webkit-scrollbar-thumb { background: var(--c-outline); border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: var(--c-primary); }

/* ── 23. Selection ────────────────────────────────────────── */
::selection { background: rgba(114,216,200,.25); color: var(--c-on-surface); }
