/* Apple Liquid Glass Design System - Optimized for Performance */

/* Animated SVG Mesh Gradient Background */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: url('/assets/images/mesh-gradient.svg') no-repeat center center;
    background-size: cover;
    will-change: auto; /* Only animate when needed */
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   Site Header - Glass Navigation Bar
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    padding: calc(var(--spacing-md) + env(safe-area-inset-top)) calc(var(--spacing-lg) + env(safe-area-inset-right)) var(--spacing-md) calc(var(--spacing-lg) + env(safe-area-inset-left));
    background: transparent;
}

.site-header .header-content {
    max-width: var(--container-max);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-lg);
}

.site-header .header-logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.site-header .header-logo:hover {
    opacity: 0.8;
}

.site-header .header-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    object-fit: cover;
}

.site-header .header-title {
    font-size: var(--text-lg);
    font-weight: var(--font-semibold);
    color: var(--color-text);
}

.site-header .header-nav {
    display: flex;
    gap: var(--spacing-lg);
}

.site-header .header-nav a {
    font-size: var(--text-sm);
    color: var(--color-text-secondary);
    transition: color 0.2s ease;
    position: relative;
    padding-bottom: 2px;
}

.site-header .header-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--color-accent);
    transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.site-header .header-nav a:hover::after {
    width: 100%;
}

.site-header .header-nav a:hover {
    color: var(--color-accent);
}

@media (max-width: 768px) {
    .site-header {
        padding: var(--spacing-sm) var(--spacing-md);
    }

    .site-header .header-icon {
        width: 28px;
        height: 28px;
    }

    .site-header .header-title {
        font-size: var(--text-base);
    }

    .site-header .header-nav {
        gap: var(--spacing-md);
    }

    .site-header .header-nav a {
        font-size: var(--text-xs);
    }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   Glass Utilities - Optimized blur values for smooth performance
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px) saturate(140%);
    -webkit-backdrop-filter: blur(8px) saturate(140%);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.glass-light {
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px) saturate(150%);
    -webkit-backdrop-filter: blur(12px) saturate(150%);
    border: 1px solid rgba(255, 255, 255, 0.25);
}

.glass-heavy {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

@media (prefers-color-scheme: dark) {
    .glass {
        background: rgba(0, 0, 0, 0.15);
        border: 1px solid rgba(255, 255, 255, 0.15);
    }

    .glass-light {
        background: rgba(0, 0, 0, 0.2);
        border: 1px solid rgba(255, 255, 255, 0.18);
    }

    .glass-heavy {
        background: rgba(0, 0, 0, 0.25);
        border: 1px solid rgba(255, 255, 255, 0.22);
    }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   Standardized Button Styles
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.button {
    display: inline-block;
    padding: 0.875rem 1.75rem;
    font-size: var(--text-base);
    font-weight: 600;
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    border: none;
    white-space: nowrap;
    position: relative;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    /* Performance optimization */
    will-change: transform;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Glass Button - Primary action style (Sign Up, Submit, Get Notified) */
.button-glass {
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px) saturate(150%);
    -webkit-backdrop-filter: blur(12px) saturate(150%);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--color-text);
    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.button-glass:hover {
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transform: translateY(-1px);
    box-shadow:
        0 4px 16px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.button-glass:active {
    transform: translateY(0);
    background: rgba(255, 255, 255, 0.15);
    box-shadow:
        0 1px 4px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

@media (prefers-color-scheme: dark) {
    .button-glass {
        background: rgba(0, 0, 0, 0.2);
        border: 1px solid rgba(255, 255, 255, 0.15);
        box-shadow:
            0 2px 8px rgba(0, 0, 0, 0.3),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
    }

    .button-glass:hover {
        background: rgba(0, 0, 0, 0.3);
        border: 1px solid rgba(255, 255, 255, 0.22);
        box-shadow:
            0 4px 16px rgba(0, 0, 0, 0.4),
            inset 0 1px 0 rgba(255, 255, 255, 0.15);
    }

    .button-glass:active {
        background: rgba(0, 0, 0, 0.25);
        box-shadow:
            0 1px 4px rgba(0, 0, 0, 0.3),
            inset 0 1px 0 rgba(255, 255, 255, 0.08);
    }
}

/* Secondary Button Style - For less prominent actions */
.button-secondary {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(8px) saturate(140%);
    -webkit-backdrop-filter: blur(8px) saturate(140%);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--color-text-secondary);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

.button-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--color-text);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.button-secondary:active {
    transform: translateY(0);
    background: rgba(255, 255, 255, 0.1);
}

@media (prefers-color-scheme: dark) {
    .button-secondary {
        background: rgba(0, 0, 0, 0.15);
        border: 1px solid rgba(255, 255, 255, 0.1);
    }

    .button-secondary:hover {
        background: rgba(0, 0, 0, 0.2);
        border: 1px solid rgba(255, 255, 255, 0.15);
    }

    .button-secondary:active {
        background: rgba(0, 0, 0, 0.18);
    }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   Glass Cards & Containers - Optimized
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.glass-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    box-shadow:
        0 4px 16px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    /* Performance */
    transform: translateZ(0);
    will-change: auto;
}

@media (prefers-color-scheme: dark) {
    .glass-card {
        background: rgba(0, 0, 0, 0.2);
        border: 1px solid rgba(255, 255, 255, 0.15);
        box-shadow:
            0 4px 16px rgba(0, 0, 0, 0.3),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
    }
}

/* Glass Icon - For app icons and circular elements */
.glass-icon {
    background: transparent;
    backdrop-filter: blur(12px) saturate(150%);
    -webkit-backdrop-filter: blur(12px) saturate(150%);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    border-radius: inherit;
    /* Performance */
    transform: translateZ(0);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-icon:hover {
    transform: scale(1.05) translateZ(0);
}

@media (prefers-color-scheme: dark) {
    .glass-icon {
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
    }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   Footer Glass Effects - Optimized
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.footer {
    padding: var(--spacing-2xl) var(--spacing-lg);
    background: transparent;
    margin-top: auto;
}

.footer-content {
    max-width: var(--container-max);
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-lg);
}

.footer-nav {
    display: flex;
    gap: var(--spacing-xl);
    flex-wrap: wrap;
    justify-content: center;
}

.footer-nav a {
    font-size: var(--text-sm);
    color: var(--color-text-secondary);
    transition: color 0.2s ease;
    position: relative;
    padding-bottom: 2px;
}

/* Animated underline - Simplified */
.footer-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--color-accent);
    transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.footer-nav a:hover::after {
    width: 100%;
}

.footer-nav a:hover {
    color: var(--color-accent);
}

.footer-copyright {
    font-size: var(--text-xs);
    color: var(--color-text-secondary);
    text-align: center;
    opacity: 0.6;
    transition: opacity 0.25s ease;
}

.footer-copyright:hover {
    opacity: 0.9;
}

/* Responsive */
@media (max-width: 768px) {
    .footer {
        padding: var(--spacing-xl) var(--spacing-md);
    }

    .footer-nav {
        gap: var(--spacing-lg);
    }
}

.footer-glass {
    background: transparent;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   Performance Optimizations
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Hardware acceleration for smoother animations */
.button,
.glass-card,
.glass-icon,
.footer-glass {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
