/* ═══════════════════════════════════════════════════════════════
   SHANI FINSERVE — GLOBAL DESIGN SYSTEM v1.0
   ═══════════════════════════════════════════════════════════════
   
   This is the SINGLE SOURCE OF TRUTH for all design tokens,
   utilities, component patterns, and animations across the 
   entire platform.
   
   CSS Hierarchy (load order):
   1. variables.css       — Design tokens
   2. design-system.css   — THIS FILE (resets, typography, components)
   3. header.css          — Navigation system
   4. footer.css          — Footer system
   5. premium.css         — Page-specific styles
   6. service-page.css    — Service template
   
   DO NOT override these styles with !important in other files.
   ═══════════════════════════════════════════════════════════════ */

/* ═══ FONT IMPORTS ═══════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&display=swap');

/* ═══ SOFT RESET ═════════════════════════════════════════════ */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.6;
    color: #0d5152;
    background: #ffffff;
    overflow-x: hidden;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.25s ease;
}

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

/* ═══ TYPOGRAPHY SYSTEM ══════════════════════════════════════ */
.sf-text-h1 {
    font-size: clamp(40px, 6vw, 72px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.sf-text-h2 {
    font-size: clamp(32px, 4.5vw, 52px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.025em;
}

.sf-text-h3 {
    font-size: clamp(24px, 3vw, 36px);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.sf-text-h4 {
    font-size: clamp(20px, 2.5vw, 28px);
    font-weight: 600;
    line-height: 1.25;
    letter-spacing: -0.015em;
}

.sf-text-body {
    font-size: 16px;
    line-height: 1.65;
    color: #64748b;
}

.sf-text-body-lg {
    font-size: 18px;
    line-height: 1.7;
    color: #64748b;
}

.sf-text-sm {
    font-size: 14px;
    line-height: 1.5;
}

.sf-text-xs {
    font-size: 12px;
    line-height: 1.4;
    letter-spacing: 0.02em;
}

.sf-text-mono {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
}

.sf-text-gradient {
    background: linear-gradient(135deg, #23dbe0, #00C2FF);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sf-text-gradient-premium {
    background: linear-gradient(135deg, #f8fafc, #23dbe0, #00C2FF);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ═══ SPACING UTILITIES ══════════════════════════════════════ */
.sf-mt-0 { margin-top: 0; }
.sf-mt-2 { margin-top: 8px; }
.sf-mt-4 { margin-top: 16px; }
.sf-mt-6 { margin-top: 24px; }
.sf-mt-8 { margin-top: 32px; }
.sf-mt-12 { margin-top: 48px; }
.sf-mt-16 { margin-top: 64px; }
.sf-mt-20 { margin-top: 80px; }

.sf-mb-0 { margin-bottom: 0; }
.sf-mb-2 { margin-bottom: 8px; }
.sf-mb-4 { margin-bottom: 16px; }
.sf-mb-6 { margin-bottom: 24px; }
.sf-mb-8 { margin-bottom: 32px; }
.sf-mb-12 { margin-bottom: 48px; }
.sf-mb-16 { margin-bottom: 64px; }
.sf-mb-20 { margin-bottom: 80px; }

.sf-py-section {
    padding-top: clamp(60px, 8vw, 120px);
    padding-bottom: clamp(60px, 8vw, 120px);
}

.sf-py-section-sm {
    padding-top: clamp(40px, 5vw, 80px);
    padding-bottom: clamp(40px, 5vw, 80px);
}

/* ═══ LAYOUT UTILITIES ═══════════════════════════════════════ */
.sf-container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

.sf-container-sm {
    max-width: 960px;
}

.sf-container-lg {
    max-width: 1440px;
}

.sf-flex {
    display: flex;
}

.sf-flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.sf-flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sf-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.sf-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.sf-grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

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

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

/* ═══ BUTTON SYSTEM ══════════════════════════════════════════ */
.sf-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 15px;
    border-radius: 12px;
    padding: 14px 28px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
    white-space: nowrap;
    cursor: pointer;
    border: none;
    text-decoration: none;
}

.sf-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent);
    opacity: 0;
    transition: opacity 0.3s;
}

.sf-btn:hover::after {
    opacity: 1;
}

/* Primary button — teal/cyan accent */
.sf-btn-primary {
    background: linear-gradient(135deg, #23dbe0, #1bc5c9);
    color: #060a0c;
    box-shadow: 0 4px 16px rgba(35, 219, 224, 0.3);
}

.sf-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(35, 219, 224, 0.4);
}

/* Ghost/outline button */
.sf-btn-ghost {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #f8fafc;
}

.sf-btn-ghost:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(35, 219, 224, 0.4);
    color: #23dbe0;
    transform: translateY(-2px);
}

/* Dark button */
.sf-btn-dark {
    background: #0d5152;
    color: #fff;
}

.sf-btn-dark:hover {
    background: #0a3f40;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(13, 81, 82, 0.3);
}

/* Small button */
.sf-btn-sm {
    padding: 10px 20px;
    font-size: 13px;
    border-radius: 10px;
}

/* Large button */
.sf-btn-lg {
    padding: 18px 36px;
    font-size: 17px;
    border-radius: 14px;
}

/* ═══ CARD SYSTEM ════════════════════════════════════════════ */

/* Glass card — light */
.sf-card-glass {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    padding: 32px;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.sf-card-glass:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
    border-color: rgba(35, 219, 224, 0.2);
}

/* Glass card — dark */
.sf-card-glass-dark {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 20px;
    padding: 32px;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.sf-card-glass-dark:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-4px);
    border-color: rgba(35, 219, 224, 0.15);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* Gradient border card */
.sf-card-gradient {
    position: relative;
    background: #fff;
    border-radius: 20px;
    padding: 32px;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid transparent;
    background-clip: padding-box;
}

.sf-card-gradient::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    background: linear-gradient(135deg, rgba(35, 219, 224, 0.3), rgba(0, 194, 255, 0.1));
    z-index: -1;
    opacity: 0;
    transition: opacity 0.4s;
}

.sf-card-gradient:hover::before {
    opacity: 1;
}

.sf-card-gradient:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 64px rgba(35, 219, 224, 0.12);
}

/* Stat card */
.sf-card-stat {
    text-align: center;
    padding: 32px 24px;
}

.sf-card-stat-value {
    font-size: clamp(36px, 4vw, 52px);
    font-weight: 800;
    color: #23dbe0;
    line-height: 1;
    margin-bottom: 8px;
}

.sf-card-stat-label {
    font-size: 13px;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
}

/* ═══ BADGE SYSTEM ═══════════════════════════════════════════ */
.sf-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 6px 16px;
    border-radius: 100px;
}

.sf-badge-accent {
    background: rgba(35, 219, 224, 0.1);
    border: 1px solid rgba(35, 219, 224, 0.2);
    color: #23dbe0;
}

.sf-badge-dark {
    background: rgba(13, 81, 82, 0.08);
    border: 1px solid rgba(13, 81, 82, 0.15);
    color: #0d5152;
}

.sf-badge-glow {
    background: rgba(35, 219, 224, 0.08);
    border: 1px solid rgba(35, 219, 224, 0.15);
    color: #23dbe0;
    box-shadow: 0 0 20px rgba(35, 219, 224, 0.1);
}

/* ═══ SECTION SYSTEM ═════════════════════════════════════════ */
.sf-section {
    position: relative;
    overflow: hidden;
}

.sf-section-dark {
    background: var(--sf-bg-base, #031314);
    color: #f8fafc;
}

.sf-section-surface {
    background: var(--sf-bg-surface, #07191A);
    color: #f8fafc;
}

.sf-section-light {
    background: #f8fafb;
}

.sf-section-white {
    background: #ffffff;
}

/* Section header pattern */
.sf-section-header {
    text-align: center;
    max-width: 720px;
    margin: 0 auto;
    margin-bottom: clamp(40px, 5vw, 64px);
}

.sf-section-header .sf-badge {
    margin-bottom: 16px;
}

.sf-section-header h2 {
    margin-bottom: 16px;
}

.sf-section-header p {
    font-size: 17px;
    line-height: 1.7;
    color: #94a3b8;
}

/* ═══ DECORATIVE ELEMENTS ════════════════════════════════════ */
/* Ambient orbs for dark sections */
.sf-orb {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(80px);
    opacity: 0.5;
}

.sf-orb-teal {
    background: radial-gradient(circle, rgba(35, 219, 224, 0.15), transparent 70%);
}

.sf-orb-blue {
    background: radial-gradient(circle, rgba(0, 194, 255, 0.1), transparent 70%);
}

/* Dot grid background */
.sf-dot-grid {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 32px 32px;
    pointer-events: none;
}

/* Gradient line divider */
.sf-divider-gradient {
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(35, 219, 224, 0.3), transparent);
    border: none;
}

/* ═══ ANIMATION SYSTEM ═══════════════════════════════════════ */
/* Entrance animations — triggered by IntersectionObserver */
.sf-reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.sf-reveal.sf-in-view {
    opacity: 1;
    transform: translateY(0);
}

.sf-reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.sf-reveal-left.sf-in-view {
    opacity: 1;
    transform: translateX(0);
}

.sf-reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.sf-reveal-right.sf-in-view {
    opacity: 1;
    transform: translateX(0);
}

.sf-reveal-scale {
    opacity: 0;
    transform: scale(0.92);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.sf-reveal-scale.sf-in-view {
    opacity: 1;
    transform: scale(1);
}

/* Stagger delays for child elements */
.sf-stagger > *:nth-child(1) { transition-delay: 0s; }
.sf-stagger > *:nth-child(2) { transition-delay: 0.06s; }
.sf-stagger > *:nth-child(3) { transition-delay: 0.12s; }
.sf-stagger > *:nth-child(4) { transition-delay: 0.18s; }
.sf-stagger > *:nth-child(5) { transition-delay: 0.24s; }
.sf-stagger > *:nth-child(6) { transition-delay: 0.30s; }
.sf-stagger > *:nth-child(7) { transition-delay: 0.36s; }
.sf-stagger > *:nth-child(8) { transition-delay: 0.42s; }
.sf-stagger > *:nth-child(9) { transition-delay: 0.48s; }
.sf-stagger > *:nth-child(10) { transition-delay: 0.54s; }

/* Keyframe animations */
@keyframes sf-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

@keyframes sf-pulse-glow {
    0%, 100% { box-shadow: 0 0 20px rgba(35, 219, 224, 0.2); }
    50% { box-shadow: 0 0 40px rgba(35, 219, 224, 0.4); }
}

@keyframes sf-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

@keyframes sf-rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes sf-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes sf-slide-up {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes sf-count-up {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Hover micro-interactions */
.sf-hover-lift {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
                box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.sf-hover-lift:hover {
    transform: translateY(-6px);
}

.sf-hover-glow {
    transition: box-shadow 0.4s ease;
}

.sf-hover-glow:hover {
    box-shadow: 0 0 30px rgba(35, 219, 224, 0.15);
}

/* ═══ ICON SYSTEM ════════════════════════════════════════════ */
.sf-icon-box {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.sf-icon-box-sm {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    font-size: 18px;
}

.sf-icon-box-lg {
    width: 72px;
    height: 72px;
    border-radius: 20px;
    font-size: 32px;
}

.sf-icon-box-teal {
    background: rgba(35, 219, 224, 0.1);
    color: #23dbe0;
}

.sf-icon-box-dark {
    background: rgba(13, 81, 82, 0.08);
    color: #0d5152;
}

/* ═══ POINTER-EVENTS SAFETY NET ══════════════════════════════ */
/* Ensure decorative elements NEVER block interaction */
.sf-orb,
.sf-dot-grid,
.sf-divider-gradient,
.sf-section::before,
.sf-section::after,
[class*="sf-bg-"],
.sf-card-gradient::before {
    pointer-events: none !important;
}

/* ═══ INTERSECTION OBSERVER AUTO-INIT ════════════════════════ */
/* This script is loaded in header.php after design-system.css */
