/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Inter', 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #1d1d1f;
    background: linear-gradient(135deg, #fafafa 0%, #f5f5f7 50%, #e8e8ed 100%);
    min-height: 100vh;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(248, 248, 248, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 80px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.nav-logo a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.logo {
    height: 96px;
    width: auto;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.1));
}

.logo:hover {
    transform: scale(1.08);
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.15));
}

.logo-text {
    font-size: 2rem;
    font-weight: 600;
    color: #1d1d1f;
    letter-spacing: -0.04em;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
    background: linear-gradient(135deg, #007AFF, #5856D6, #AF52DE);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: logoTextShimmer 4s ease-in-out infinite, logoTextFloat 6s ease-in-out infinite 0.5s;
}

@keyframes logoTextShimmer {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes logoTextFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-2px); }
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    align-items: center;
    flex-wrap: wrap;
}

.nav-link {
    text-decoration: none;
    color: #1d1d1f;
    font-weight: 400;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    opacity: 0.8;
}

.nav-link:hover {
    color: #007AFF;
    opacity: 1;
    transform: translateY(-1px);
}

/* Language Selector */
.language-selector {
    display: flex;
    background: rgba(255, 255, 255, 0.8);
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 20px;
    overflow: hidden;
    backdrop-filter: blur(20px);
}

.lang-btn {
    background: transparent;
    border: none;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    font-weight: 500;
    color: #1d1d1f;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.lang-btn.active {
    background: linear-gradient(135deg, #007AFF, #5856D6);
    color: white;
}

.lang-btn:hover:not(.active) {
    background: rgba(0, 122, 255, 0.1);
    color: #007AFF;
}

/* Main Content */
.legal-main {
    padding-top: 120px;
    min-height: 100vh;
    padding-bottom: 2rem;
}

.legal-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
}

.legal-header h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 1rem;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
    letter-spacing: -0.03em;
    background: linear-gradient(135deg, #007AFF, #5856D6, #AF52DE);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: gradientShift 3s ease-in-out infinite;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.last-updated {
    font-size: 1rem;
    color: #86868b;
    font-style: italic;
}

/* Legal Content */
.legal-content {
    background: white;
    border-radius: 24px;
    padding: 3rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

.legal-section {
    margin-bottom: 2.5rem;
}

.legal-section:last-child {
    margin-bottom: 0;
}

.legal-section h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.legal-section p {
    color: #86868b;
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 1rem;
}

.legal-section ul {
    list-style: none;
    margin-left: 1rem;
}

.legal-section ul li {
    color: #86868b;
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 0.5rem;
    position: relative;
    padding-left: 1.5rem;
}

.legal-section ul li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: #007AFF;
    font-weight: bold;
    font-size: 1.2rem;
}

/* Legal Footer */
.legal-footer {
    text-align: center;
    margin-bottom: 2rem;
}

.back-button {
    background: linear-gradient(135deg, #007AFF, #5856D6);
    color: white;
    text-decoration: none;
    padding: 1rem 2rem;
    border-radius: 25px;
    font-weight: 500;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 6px 20px rgba(0, 122, 255, 0.3);
}

.back-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(0, 122, 255, 0.4);
    background: linear-gradient(135deg, #0056CC, #4C44CC);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
    
    .nav-container {
        padding: 1rem;
        flex-wrap: wrap;
        min-height: auto;
    }
    
    .nav-menu {
        width: 100%;
        justify-content: center;
        margin-top: 1rem;
        gap: 1rem;
    }
    
    .legal-main {
        padding-top: 160px;
    }
    
    .legal-content {
        padding: 2rem;
        border-radius: 16px;
    }
    
    .legal-header {
        padding: 1rem 0;
    }
}

@media (max-width: 480px) {
    .legal-content {
        padding: 1.5rem;
    }
    
    .legal-header h1 {
        font-size: 2rem;
    }
    
    .legal-section h2 {
        font-size: 1.25rem;
    }
    
    .legal-section p,
    .legal-section ul li {
        font-size: 0.95rem;
    }
}

/* Animations */
.legal-content {
    animation: fadeInUp 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}