/* Legal Pages Specific Styles */

/* Legal Header */
.legal-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 3rem 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 20px;
    border: 1px solid rgba(102, 126, 234, 0.1);
    position: relative;
    overflow: hidden;
}

.legal-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="legalHeaderPattern" width="40" height="40" patternUnits="userSpaceOnUse"><rect x="19" y="19" width="2" height="2" fill="%23667eea" opacity="0.05"/></pattern></defs><rect width="100" height="100" fill="url(%23legalHeaderPattern)"/></svg>');
}

.legal-header .header-visual {
    position: relative;
    z-index: 1;
}

.legal-header .page-title {
    color: #1a1a1a;
    font-size: clamp(2rem, 4vw, 2.75rem);
    font-weight: 800;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
    z-index: 1;
}

.legal-header .last-updated {
    color: #4a5568;
    font-size: 1rem;
    font-style: italic;
    margin-bottom: 0;
    position: relative;
    z-index: 1;
}

/* Legal Page Layout */
.legal-page {
    padding: 6rem 0;
    background: #ffffff;
    position: relative;
}

.legal-page::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="legalPagePattern" width="60" height="60" patternUnits="userSpaceOnUse"><circle cx="30" cy="30" r="1.5" fill="%23667eea" opacity="0.02"/></pattern></defs><rect width="100" height="100" fill="url(%23legalPagePattern)"/></svg>');
}

.legal-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.95);
    padding: 3rem;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(102, 126, 234, 0.1);
}

/* Typography for Legal Content */
.legal-content h2 {
    color: #1a1a1a;
    font-size: clamp(1.5rem, 3vw, 1.875rem);
    font-weight: 700;
    margin: 2.5rem 0 1.5rem 0;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid rgba(102, 126, 234, 0.2);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.legal-content h2:first-child {
    margin-top: 0;
}

.legal-content h3 {
    color: #2d3748;
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    font-weight: 600;
    margin: 2rem 0 1rem 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.legal-content h4 {
    color: #4a5568;
    font-size: clamp(1.125rem, 2vw, 1.25rem);
    font-weight: 600;
    margin: 1.5rem 0 0.75rem 0;
}

.legal-content p {
    color: #2d3748;
    font-size: 1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    text-align: justify;
}

.legal-content ul,
.legal-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.legal-content li {
    color: #2d3748;
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 0.75rem;
}

.legal-content li::marker {
    color: #667eea;
    font-weight: 600;
}

.legal-content strong {
    color: #1a1a1a;
    font-weight: 600;
}

.legal-content em {
    color: #4a5568;
    font-style: italic;
}

.legal-content a {
    color: #667eea;
    text-decoration: underline;
    font-weight: 500;
    transition: color 0.3s ease;
}

.legal-content a:hover {
    color: #5a6fd8;
    text-decoration: none;
}

/* Special Sections */
.legal-section {
    margin: 3rem 0;
    padding: 2rem;
    background: rgba(102, 126, 234, 0.03);
    border-radius: 12px;
    border: 1px solid rgba(102, 126, 234, 0.1);
    position: relative;
}

.legal-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 2px;
}

.legal-highlight {
    background: rgba(102, 126, 234, 0.05);
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px solid rgba(102, 126, 234, 0.15);
    margin: 1.5rem 0;
    position: relative;
}

.legal-highlight::before {
    content: '💡';
    position: absolute;
    top: -8px;
    left: 16px;
    background: #ffffff;
    padding: 0 8px;
    font-size: 1.2rem;
}

.legal-highlight p {
    margin-bottom: 0;
    font-weight: 500;
    color: #1a1a1a;
}

/* Contact Information */
.contact-info {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    border-radius: 16px;
    margin: 3rem 0;
    text-align: center;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.contact-info h3 {
    color: white;
    margin-bottom: 1rem;
    background: none;
    -webkit-text-fill-color: white;
}

.contact-info p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 0.75rem;
    text-align: center;
}

.contact-info a {
    color: #FFD700;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.contact-info a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Table of Contents */
.table-of-contents {
    background: rgba(102, 126, 234, 0.05);
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid rgba(102, 126, 234, 0.1);
    margin-bottom: 3rem;
    position: sticky;
    top: 100px;
    z-index: 10;
}

.table-of-contents h3 {
    color: #1a1a1a;
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.table-of-contents ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.table-of-contents li {
    margin-bottom: 0.5rem;
}

.table-of-contents a {
    color: #4a5568;
    text-decoration: none;
    font-weight: 500;
    padding: 8px 12px;
    border-radius: 8px;
    display: block;
    transition: all 0.3s ease;
}

.table-of-contents a:hover {
    background: rgba(102, 126, 234, 0.1);
    color: #667eea;
    transform: translateX(5px);
}

/* Back to Top */
.back-to-top {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 24px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 3rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.back-to-top:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

/* Responsive Design */
@media (max-width: 768px) {
    .legal-page {
        padding: 4rem 0;
    }
    
    .legal-content {
        padding: 2rem;
        margin: 0 1rem;
    }
    
    .legal-header {
        padding: 2rem 0;
        margin-bottom: 2rem;
    }
    
    .legal-section,
    .legal-highlight {
        padding: 1.5rem;
        margin: 2rem 0;
    }
    
    .contact-info {
        padding: 1.5rem;
        margin: 2rem 0;
    }
    
    .table-of-contents {
        position: static;
        margin-bottom: 2rem;
    }
}

@media (max-width: 480px) {
    .legal-page {
        padding: 3rem 0;
    }
    
    .legal-content {
        padding: 1.5rem;
        margin: 0 0.5rem;
    }
    
    .legal-content ul,
    .legal-content ol {
        padding-left: 1.5rem;
    }
    
    .legal-section,
    .legal-highlight {
        padding: 1.25rem;
    }
    
    .contact-info {
        padding: 1.25rem;
    }
}
