/* ==========================================================================
   CSS Variables & Tokens
   ========================================================================== */
:root {
    /* 100% White Theme Palette */
    --color-bg: #ffffff;
    --color-surface: #ffffff;
    --color-surface-hover: #f8f9fa;
    --color-border: #e9ecef;
    
    /* Typography */
    --color-text-primary: #111827;
    --color-text-secondary: #4b5563;
    --color-text-muted: #9ca3af;
    
    /* Brand Colors (Gradients) */
    --gradient-connect: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
    --gradient-connect-hover: linear-gradient(135deg, #172554 0%, #2563eb 100%);
    --gradient-text: linear-gradient(135deg, #111827 0%, #4b5563 100%);
    
    /* WhatsApp Color */
    --color-whatsapp: #25D366;
    
    /* Shadows (3D & Shiny Effects) */
    --shadow-header: 0 10px 30px -10px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
    --shadow-card: 0 20px 40px -15px rgba(0, 0, 0, 0.05);
    --shadow-card-hover: 0 30px 60px -20px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0,0,0,0.02);
    --shadow-btn: 0 10px 20px -10px rgba(59, 130, 246, 0.5);
    --shadow-btn-hover: 0 15px 25px -10px rgba(59, 130, 246, 0.7);
    
    /* Layout */
    --header-height: 80px;
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   Reset & Global Styles
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--color-bg);
    color: var(--color-text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

main {
    padding-top: calc(var(--header-height) + 20px);
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.text-center { text-align: center; }
.text-gradient {
    background: var(--gradient-connect);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.text-whatsapp { color: var(--color-whatsapp); }
.bg-light { background-color: var(--color-surface-hover); }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 100px; /* Pill shape */
    cursor: pointer;
    transition: var(--transition-normal);
    text-decoration: none;
}

.btn-large {
    padding: 16px 32px;
    font-size: 1.125rem;
}

.btn-small {
    padding: 9px 19px;
    font-size: 0.8rem;
}

.btn-whatsapp-mild {
    background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%);
    color: #166534;
    box-shadow: 0 4px 10px -2px rgba(34, 197, 94, 0.3);
}

.btn-whatsapp-mild:hover {
    background: linear-gradient(135deg, #bbf7d0 0%, #86efac 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px -2px rgba(34, 197, 94, 0.4);
}

.btn-join-mild {
    background: linear-gradient(135deg, #f3e8ff 0%, #e9d5ff 100%);
    color: #581c87;
    box-shadow: 0 4px 10px -2px rgba(168, 85, 247, 0.3);
}

.btn-join-mild:hover {
    background: linear-gradient(135deg, #e9d5ff 0%, #d8b4fe 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px -2px rgba(168, 85, 247, 0.4);
}

.btn-connect {
    background: var(--gradient-connect);
    color: white;
    box-shadow: var(--shadow-btn);
    position: relative;
    overflow: hidden;
}

/* Shiny effect overlay */
.btn-connect::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 100%);
    transform: skewX(-25deg);
    animation: shine 6s infinite;
}

@keyframes shine {
    0% { left: -100%; }
    20% { left: 200%; }
    100% { left: 200%; }
}

.btn-connect:hover {
    background: var(--gradient-connect-hover);
    box-shadow: var(--shadow-btn-hover);
    transform: translateY(-2px);
}

.btn-primary {
    background-color: var(--color-text-primary);
    color: white;
}

.btn-primary:hover {
    background-color: #000000;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -10px rgba(0,0,0,0.3);
}

.btn-secondary {
    background-color: white;
    color: var(--color-text-primary);
    border: 1px solid var(--color-border);
}

.btn-secondary:hover {
    background-color: var(--color-surface-hover);
    border-color: var(--color-text-primary);
    transform: translateY(-2px);
}

/* ==========================================================================
   Header
   ========================================================================== */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow-header);
    transition: var(--transition-normal);
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.logo-img {
    height: 40px;
    width: auto;
    object-fit: contain;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
    padding-top: 30px;
    padding-bottom: 30px;
    min-height: calc(100vh - var(--header-height) - 60px);
    display: flex;
    align-items: center;
    overflow: hidden;
    position: relative;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at center, rgba(59, 130, 246, 0.03) 0%, rgba(255,255,255,0) 50%);
    z-index: -1;
}

.hero-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.hero-title {
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--color-text-secondary);
    margin-bottom: 20px;
    max-width: 90%;
}

.hero-actions {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.hero-microtext {
    font-size: 0.875rem;
    color: var(--color-text-muted);
    font-weight: 500;
}

.app-mockup {
    position: relative;
    border-radius: var(--border-radius-lg);
    background: transparent;
    padding: 0;
    border: none;
    -webkit-mask-image: linear-gradient(to bottom, black 50%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 50%, transparent 100%);
    mix-blend-mode: multiply;
    width: 91%;
    margin: 0 auto;
}

.mockup-img {
    width: 100%;
    height: auto;
    border-radius: var(--border-radius-lg);
    display: block;
}

/* Forcibly disable any hover/tilt effect on the main image */
.app-mockup:hover, 
.mockup-img:hover, 
.hero-visual:hover {
    transform: none !important;
    box-shadow: none !important;
}

.mockup-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(59,130,246,0.15) 0%, rgba(255,255,255,0) 70%);
    transform: translate(-50%, -50%);
    z-index: -1;
    pointer-events: none;
}

/* ==========================================================================
   Sections & Grids
   ========================================================================== */
.top-actions {
    padding-bottom: 20px;
    background: var(--color-bg);
    width: 100%;
}

.top-actions-container {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%;
    max-width: 100%;
}

.value-section, .features-section, .cta-section {
    padding: 30px 0;
}

.section-header {
    margin-bottom: 30px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.01em;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--color-text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.value-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
}

.value-card {
    background: white;
    padding: 40px;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-card);
    border: 1px solid rgba(0,0,0,0.02);
    transition: var(--transition-normal);
    text-align: center;
}

.value-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-card-hover);
}

.value-icon {
    width: 64px;
    height: 64px;
    background: var(--color-surface-hover);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    color: #3b82f6; /* Blue tint for icons */
}

.value-icon svg {
    width: 32px;
    height: 32px;
}

.value-card h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
}

.value-card p {
    color: var(--color-text-secondary);
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 24px;
}

.feature-card {
    background: white;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-md);
    padding: 32px 24px;
    text-align: center;
    transition: var(--transition-normal);
    cursor: pointer;
}

.feature-card:hover {
    box-shadow: var(--shadow-card-hover);
    transform: translateY(-5px) scale(1.02);
    border-color: #3b82f6; /* Slight blue border on hover */
}

.feature-icon {
    margin-bottom: 16px;
    color: var(--color-text-primary);
    transition: var(--transition-fast);
}

.feature-card:hover .feature-icon {
    color: #3b82f6;
    transform: scale(1.1);
}

.feature-icon svg {
    width: 40px;
    height: 40px;
    stroke-width: 1.5px;
}

.feature-card h4 {
    font-size: 1.125rem;
    font-weight: 600;
}

/* CTA Section */
.cta-title {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 16px;
}

.cta-subtitle {
    font-size: 1.25rem;
    color: var(--color-text-secondary);
    margin-bottom: 40px;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.main-footer {
    background-color: var(--color-surface-hover);
    padding: 48px 0;
    border-top: 1px solid var(--color-border);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 24px;
}

.footer-logo p {
    color: var(--color-text-muted);
    font-size: 0.875rem;
    margin-top: 8px;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: var(--color-text-secondary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: var(--transition-fast);
}

.footer-links a:hover {
    color: var(--color-text-primary);
}

/* ==========================================================================
   Animations & Utils
   ========================================================================== */
.icon-sm {
    width: 20px;
    height: 20px;
}

/* Initial state for JS scroll animations */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.slide-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1s cubic-bezier(0.2, 0.8, 0.2, 1), transform 1s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.zoom-in {
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

/* Active states added by JS */
.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 992px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-actions {
        justify-content: center;
    }
    
    .hero-title {
        font-size: 3.5rem;
    }
    
    .hero-subtitle {
        margin: 0 auto 40px;
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .btn-large {
        width: 100%;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}

/* ==========================================================================
   Global Modal (Premium Glassmorphism)
   ========================================================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.5s;
    padding: 24px;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.shiny-modal {
    position: relative;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(40px) saturate(200%);
    -webkit-backdrop-filter: blur(40px) saturate(200%);
    width: 100%;
    max-width: 420px;
    border-radius: var(--border-radius-lg);
    padding: 48px 40px;
    box-shadow: 
        0 0 0 1px rgba(255, 255, 255, 0.6) inset,
        0 40px 80px -20px rgba(0, 0, 0, 0.3),
        0 0 40px rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.8);
    transform: scale(0.95) translateY(10px);
    opacity: 0;
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.modal-overlay.active .shiny-modal {
    transform: scale(1) translateY(0);
    opacity: 1;
}

/* Ethereal Glow */
.shiny-modal::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 50% 50%, rgba(59, 130, 246, 0.08), transparent 60%),
                radial-gradient(circle at 80% 20%, rgba(139, 92, 246, 0.08), transparent 50%);
    z-index: -1;
    animation: etherealRotate 15s linear infinite;
    pointer-events: none;
    border-radius: 50%;
}

@keyframes etherealRotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.8);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-secondary);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.modal-close:hover {
    background: #ffffff;
    color: var(--color-text-primary);
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.modal-icon {
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 28px;
    color: white;
    box-shadow: 
        0 12px 24px -8px rgba(59, 130, 246, 0.5),
        0 0 0 4px rgba(59, 130, 246, 0.1) inset;
    position: relative;
}

.modal-icon::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 28px;
    border: 2px solid rgba(59, 130, 246, 0.4);
    animation: ripple 2s infinite cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes ripple {
    0% { transform: scale(1); opacity: 1; }
    100% { transform: scale(1.4); opacity: 0; }
}

.modal-icon svg {
    width: 36px;
    height: 36px;
    stroke-width: 2px;
}

.modal-title {
    font-size: 2.25rem;
    font-weight: 800;
    margin-bottom: 12px;
    background: linear-gradient(135deg, #1e293b 0%, #3b82f6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.modal-message {
    font-size: 1.125rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
    margin-bottom: 32px;
}

.modal-action {
    width: 100%;
    padding: 16px;
    border-radius: 100px;
    background: var(--color-text-primary);
    color: white;
    font-family: inherit;
    font-size: 1.05rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 20px -10px rgba(0,0,0,0.3);
}

.modal-action:hover {
    background: #000;
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -10px rgba(0,0,0,0.4);
}

/* ==========================================================================
   WhatsApp Modal Specifics
   ========================================================================== */
.whatsapp-shiny-modal {
    border: 1px solid rgba(37, 211, 102, 0.4);
    box-shadow: 
        0 0 0 1px rgba(255, 255, 255, 0.6) inset,
        0 40px 80px -20px rgba(0, 0, 0, 0.3),
        0 0 40px rgba(37, 211, 102, 0.2);
}

.whatsapp-shiny-modal::before {
    background: radial-gradient(circle at 50% 50%, rgba(37, 211, 102, 0.1), transparent 60%);
}

.whatsapp-icon-container {
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    box-shadow: 
        0 12px 24px -8px rgba(37, 211, 102, 0.5),
        0 0 0 4px rgba(37, 211, 102, 0.1) inset;
}

.whatsapp-icon-container::after {
    border: 2px solid rgba(37, 211, 102, 0.4);
}

.whatsapp-pulsing-icon {
    width: 36px;
    height: 36px;
    animation: iconPulse 2s infinite ease-in-out;
}

@keyframes iconPulse {
    0% { transform: scale(0.9); }
    50% { transform: scale(1.1); }
    100% { transform: scale(0.9); }
}

.whatsapp-loader {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.whatsapp-loader .dot {
    width: 10px;
    height: 10px;
    background-color: var(--color-whatsapp);
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out both;
}

.whatsapp-loader .dot:nth-child(1) { animation-delay: -0.32s; }
.whatsapp-loader .dot:nth-child(2) { animation-delay: -0.16s; }

@keyframes bounce {
    0%, 80%, 100% { transform: scale(0); }
    40% { transform: scale(1); }
}
