/* ========== CSS Variables ========== */
:root {
    /* Colors */
    --primary-color: #007AFF;
    --secondary-color: #0A84FF;
    --text-color: rgba(255, 255, 255, 0.85);
    --text-color-light: rgba(255, 255, 255, 0.7);
    --background-color: #000000;
    --background-color-light: #1C1C1E;
    
    /* Typography */
    --font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', Roboto, sans-serif;
    --font-size-base: 16px;
    --font-size-h1: 64px;
    --font-size-h2: 48px;
    --font-size-h3: 32px;
    --font-size-h4: 24px;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 8rem;
    
    /* Border Radius */
    --border-radius-sm: 12px;
    --border-radius-md: 20px;
    --border-radius-lg: 30px;
}

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

html {
    font-size: var(--font-size-base);
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    line-height: 1.5;
    color: var(--text-color);
    background-color: #0a0a0a;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ========== Layout Utilities ========== */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

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

.grid-two-columns {
    display: grid;
    gap: var(--spacing-md);
}

@media (min-width: 768px) {
    .grid-two-columns {
        grid-template-columns: 1fr 1fr;
    }
}

/* ========== Typography ========== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.section-title {
    font-size: var(--font-size-h2);
    margin-bottom: var(--spacing-md);
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
}

.section-description {
    color: var(--text-color-light);
    margin-bottom: var(--spacing-lg);
    font-size: 20px;
    line-height: 1.6;
    text-align: center;
}

/* ========== Buttons ========== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    font-size: 16px;
    letter-spacing: -0.01em;
}

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

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

.btn-secondary {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

/* ========== Sections ========== */
section {
    padding: var(--spacing-lg) 0;
}

/* ========== Responsive Design ========== */
@media (max-width: 768px) {
    :root {
        --font-size-h1: 48px;
        --font-size-h2: 36px;
        --font-size-h3: 24px;
        --font-size-h4: 20px;
        --spacing-xl: 4rem;
    }
    
    .section-description {
        font-size: 18px;
    }
    
    .container {
        padding: 0 var(--spacing-sm);
    }
}

/* ========== Loading Overlay ========== */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--background-color);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.3s ease;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 14px;
    font-weight: 500;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ========== Device Frame Styles ========== */
.device-mockup {
    position: relative;
    display: inline-block;
    width: 280px;
    margin: 0 auto;
    transform-style: preserve-3d;
    transition: transform 0.5s ease;
}

/* Hover animations with specific third child */
.device-mockup:hover {
    transform: translateY(-10px) rotateY(10deg);
}

.device-mockup:nth-child(2):hover {
    transform: translateY(-10px) rotateY(-10deg);
}

.device-mockup:nth-child(3):hover {
    transform: translateY(-10px) rotateY(-10deg);
}

/* Steps section alternating animations */
.step:nth-child(odd) .device-mockup:hover {
    transform: translateY(-10px) rotateY(-10deg);
}

.step:nth-child(even) .device-mockup:hover {
    transform: translateY(-10px) rotateY(10deg);
}

.device-mockup .mockup-image,
.device-mockup .app-screenshot,
.step-image .mockup-image {
    position: relative;
    z-index: 1;
    width: 100%;
    height: auto;
    border-radius: 40px;
    padding: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.device-mockup::before,
.step-image .device-mockup::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('/assets/images/iPhone_14_Pro_frame.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-position: center;
    z-index: 2;
    pointer-events: none;
}

@media (max-width: 1024px) {
    .device-mockup {
        width: 220px;
    }
}

@media (max-width: 768px) {
    .device-mockup {
        width: 180px;
    }
}

@media (max-width: 480px) {
    .device-mockup {
        width: 240px;
    }
}

/* Common styles for text pages */
.legal-page, .support-page {
    background-color: #0a0a0a;
    color: rgba(255, 255, 255, 0.9);
    min-height: 100vh;
}

.legal-page main, .support-page main {
    padding: 240px 0 60px;
}

.legal-page .container, .support-page .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.legal-page h1, .support-page h1 {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 4rem;
    color: #ffffff;
    text-align: center;
    padding: 0 1rem;
}

.legal-page h1::after, .support-page h1::after {
    content: '';
    display: block;
    width: 100px;
    height: 4px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    margin: 2rem auto 0;
    border-radius: 2px;
}

.legal-content, .support-content {
    font-size: 1.25rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 2rem;
}

.legal-content h2, .support-content h2 {
    font-size: 2.5rem;
    font-weight: 600;
    margin: 2.5rem 0 1.5rem;
    color: #ffffff;
}

.legal-content p, .support-content p {
    margin-bottom: 1.5rem;
    max-width: 800px;
}

.legal-content ul, .support-content ul {
    margin: 1.5rem 0;
    padding-left: 1.5rem;
}

.legal-content li, .support-content li {
    margin-bottom: 1rem;
}

.legal-content a, .support-content a {
    color: #3b82f6;
    text-decoration: none;
    transition: color 0.3s ease;
}

.legal-content a:hover, .support-content a:hover {
    color: #60a5fa;
    text-decoration: underline;
}

.support-intro {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
}

.contact-info {
    background: rgba(255, 255, 255, 0.05);
    padding: 2rem;
    border-radius: 1rem;
    margin: 2rem 0;
}

.response-time {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.7);
    font-style: italic;
}

/* Mobile Overlay Styles */
.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: black;
    color: white;
    z-index: 9999;
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.mobile-overlay.active {
    display: flex;
}

.overlay-close {
    position: absolute;
    top: 2rem;
    right: 2rem;
    background: none;
    border: none;
    font-size: 2.5rem;
    color: white;
    cursor: pointer;
}

.overlay-nav-links {
    list-style: none;
    padding: 0;
    margin-top: 3rem;
    text-align: center;
}

.overlay-nav-links li {
    margin: 1.5rem 0;
}

.overlay-nav-links a {
    font-size: 1.5rem;
    color: white;
    text-decoration: none;
}

.overlay-nav-links a:hover {
    opacity: 0.8;
} 