/* 
   SlapIA - Premium Design System 
   Inspiration: UmbrelOS, Apple, Linear
*/

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

:root {
    /* Core Palette - Deep Space & Aurora */
    --bg-deep: #000000;
    --bg-surface: #0a0a0a;

    /* The "Glow" Colors */
    --accent-blue: #2997ff;
    /* Apple Blue */
    --accent-purple: #bf5af2;
    /* Apple Purple */
    --accent-cyan: #30d158;
    /* Apple Greenish */

    /* Omni-present Borders */
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-highlight: rgba(255, 255, 255, 0.12);

    /* Surfaces */
    --glass-panel: rgba(20, 20, 20, 0.6);
    --glass-panel-hover: rgba(30, 30, 30, 0.8);

    /* Typography */
    --text-primary: #ffffff;
    --text-secondary: #98989d;
    /* San Francisco Gray */
    --text-tertiary: #6e6e73;
}

/* Accessibility: Focus Styles */
:focus-visible {
    outline: 2px solid var(--accent-purple);
    outline-offset: 2px;
    border-radius: 4px;
}

.btn-apple:focus-visible {
    outline: 2px solid white;
    outline-offset: 2px;
    background: rgba(255, 255, 255, 0.2);
}

.dock-link:focus-visible {
    background: rgba(255, 255, 255, 0.1);
    outline: none;
}

html,
body {
    max-width: 100%;
    overflow-x: hidden;
}

body {
    background-color: var(--bg-deep);
    color: var(--text-primary);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    -webkit-font-smoothing: antialiased;
    margin: 0;
    padding: 0;
    /* Subtle noise texture */
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E");
}


/* Typography Overrides */
h1,
h2,
h3,
h4 {
    letter-spacing: -0.025em;
    /* Tight apple tracking */
    font-weight: 700;
}

.display-title {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.05;
    background: linear-gradient(180deg, #fff 0%, #a1a1aa 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-gradient-purple {
    background: linear-gradient(135deg, #c471f5 0%, #fa71cd 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Container & Navbar */
.container {
    max-width: 1100px;
    /* Tighter container for focus */
}


/* Bento Grid System */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 24px;
}

.bento-card {
    background: var(--glass-panel);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    /* Large UmbelsOS radius */
    padding: 32px;
    overflow: hidden;
    position: relative;
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), border-color 0.3s ease;
}

.bento-card:hover {
    transform: translateY(-4px) scale(1.01);
    border-color: var(--glass-highlight);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
}

.span-12 {
    grid-column: span 12;
}

.span-6 {
    grid-column: span 6;
}

.span-4 {
    grid-column: span 4;
}

.span-8 {
    grid-column: span 8;
}

/* =========================================
   RESPONSIVE DESIGN - All Platforms
   ========================================= */

/* Large Tablets & Small Desktops (max-width: 991px) */
@media (max-width: 991px) {

    .span-4,
    .span-6,
    .span-8 {
        grid-column: span 12;
    }

    .display-title {
        font-size: 3rem;
    }

    .dock-nav {
        padding: 10px 16px;
        gap: 16px;
    }

    .dock-link {
        padding: 6px 14px;
        font-size: 0.85rem;
    }

    .bento-card {
        padding: 24px;
        border-radius: 24px;
    }

    .container {
        padding-left: 20px;
        padding-right: 20px;
    }
}

/* Tablets (max-width: 768px) */
@media (max-width: 768px) {
    .display-title {
        font-size: 2.5rem;
        line-height: 1.1;
    }

    .dock-nav {
        top: 12px;
        padding: 8px 12px;
        gap: 12px;
        max-width: calc(100% - 24px);
    }

    .dock-brand {
        font-size: 0.95rem;
        padding-right: 10px;
        gap: 6px;
    }

    .dock-brand i {
        font-size: 1rem;
    }

    .bento-grid {
        gap: 16px;
    }

    .bento-card {
        padding: 20px;
        border-radius: 20px;
    }

    /* Touch-friendly buttons */
    .btn-apple {
        padding: 14px 24px;
        font-size: 0.95rem;
        width: 100%;
        justify-content: center;
    }

    .btn-apple-glass {
        width: 100%;
        justify-content: center;
    }

    /* Stack buttons on mobile */
    .d-flex.gap-3 {
        flex-direction: column;
        width: 100%;
    }

    /* Form inputs larger for touch */
    .form-control {
        font-size: 16px !important;
        /* Prevents iOS zoom */
        padding: 14px 16px !important;
    }

    /* Footer adjustments */
    footer {
        padding: 40px 0;
        margin-top: 60px;
    }

    footer .row {
        text-align: center;
    }

    footer .col-6 {
        margin-bottom: 20px;
    }

    /* Icon boxes */
    .icon-box {
        width: 48px;
        height: 48px;
        font-size: 1.25rem;
        border-radius: 16px;
    }

    /* Aurora orbs smaller on mobile */
    .orb-1 {
        width: 300px;
        height: 300px;
    }

    .orb-2 {
        width: 250px;
        height: 250px;
    }

    .orb-3 {
        width: 150px;
        height: 150px;
    }

    /* Spacer for nav */
    .nav-spacer {
        height: 100px !important;
    }
}

/* Mobile Phones (max-width: 576px) */
@media (max-width: 576px) {
    .display-title {
        font-size: 2rem;
        line-height: 1.15;
    }

    h2 {
        font-size: 1.75rem;
    }

    h3 {
        font-size: 1.35rem;
    }

    h4 {
        font-size: 1.15rem;
    }

    .dock-nav {
        top: 8px;
        padding: 6px 10px;
        gap: 8px;
        border-radius: 50px;
    }

    .dock-brand {
        font-size: 0.85rem;
        padding-right: 8px;
    }

    .dock-link {
        padding: 6px 10px;
        font-size: 0.8rem;
    }

    .bento-grid {
        gap: 12px;
    }

    .bento-card {
        padding: 16px;
        border-radius: 16px;
    }

    /* Disable hover transformations on touch devices */
    .bento-card:hover {
        transform: none;
    }

    .btn-apple:hover {
        transform: none;
    }

    /* Better text sizing */
    .lead {
        font-size: 1rem;
    }

    .text-secondary.small {
        font-size: 0.85rem;
    }

    /* Container padding */
    .container {
        padding-left: 16px;
        padding-right: 16px;
    }

    /* Section padding */
    section {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }

    /* Hero section specific */
    section[style*="padding: 60px"] {
        padding: 30px 0 60px !important;
    }

    /* Cards for grid display on small screens */
    .row.g-3>.col-4 {
        flex: 0 0 50%;
        max-width: 50%;
    }
}

/* Extra Small Phones (max-width: 380px) */
@media (max-width: 380px) {
    .display-title {
        font-size: 1.75rem;
    }

    .dock-nav {
        flex-wrap: wrap;
        justify-content: center;
        gap: 6px;
        border-radius: 20px;
    }

    .dock-brand {
        border-right: none;
        padding-right: 0;
        width: 100%;
        justify-content: center;
        margin-bottom: 4px;
    }

    .bento-card {
        padding: 14px;
    }

    .btn-apple {
        padding: 12px 20px;
        font-size: 0.9rem;
    }

    .icon-box {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
        border-radius: 12px;
    }
}

/* Landscape phones */
@media (max-height: 500px) and (orientation: landscape) {
    .dock-nav {
        top: 8px;
        padding: 6px 12px;
    }

    .nav-spacer {
        height: 80px !important;
    }

    section[style*="padding: 60px"] {
        padding: 20px 0 40px !important;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    .bento-card:hover {
        transform: none;
        box-shadow: none;
    }

    .btn-apple:hover {
        transform: none;
    }

    /* Active states for touch */
    .bento-card:active {
        transform: scale(0.98);
        transition: transform 0.1s;
    }

    .btn-apple:active {
        transform: scale(0.97);
        background: #e5e5e7;
    }

    .dock-link:active {
        opacity: 0.7;
    }

    /* Hide spotlight effect on touch */
    .bento-card::after {
        display: none;
    }
}

/* High resolution screens */
@media (-webkit-min-device-pixel-ratio: 2),
(min-resolution: 192dpi) {
    body {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .aurora-orb {
        animation: none;
    }
}

/* Apple-style Buttons */
.btn-apple {
    background: white;
    color: black;
    border-radius: 100px;
    padding: 14px 32px;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    transition: transform 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-apple:hover {
    transform: scale(1.03);
    background: #f5f5f7;
    color: black;
}

.btn-apple-glass {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.btn-apple-glass:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

/* Feature Icons */
.icon-box {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
}

/* Ensure enough safe area at bottom of page for scrolling past floating elements */
body {
    padding-bottom: 20px;
}







/* =========================================
   Page Loader (Homepage Only)
   ========================================= */
/* Page Loader styles removed */


/* n8n Chat Widget Overrides */
.n8n-chat-widget {
    left: 20px !important;
    right: auto !important;
    bottom: 20px !important;
    z-index: 10000 !important;
}


/* Interactive Form Validation */
.form-control:valid {
    border-color: rgba(46, 213, 115, 0.5) !important;
    background: rgba(46, 213, 115, 0.05) !important;
}

.form-control:invalid:not(:placeholder-shown) {
    border-color: rgba(255, 71, 87, 0.5) !important;
    background: rgba(255, 71, 87, 0.05) !important;
}

/* Accordion Styles */
.accordion-button::after {
    display: none;
}

.accordion-button:not(.collapsed) .transition-icon {
    transform: rotate(180deg);
}

.transition-icon {
    transition: transform 0.3s ease;
}


/* Link Hover Effect */
.hover-underline:hover {
    text-decoration: underline !important;
}






/* Scroll Indicator Transitions */
#scroll-indicator {
    transition: opacity 0.3s ease, transform 0.2s ease;
}

#scroll-indicator:hover {
    transform: scale(1.1);
}


/* Utility Classes */
.hover-white:hover {
    color: white !important;
}

.transition-all {
    transition: all 0.3s ease;
}

/* Cleaning up old Emoji Rain CSS if any conflict - New one uses inline styles/JS animations */