/* ==========================================================================
   Legal & Governance Pages Styles (Terms & Conditions, Privacy Policy)
   Gravity Elite Fitness Studio - Premium, Human-Designed & Production Ready
   ========================================================================== */

body.legal-page {
    background-color: #F8FAFC;
    color: #1E293B;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    padding-top: 104px;
}

@media (max-width: 991px) {
    body.legal-page {
        padding-top: 76px;
    }
}

/* ── HERO BANNER ── */
.legal-hero {
    background: #0B132B;
    background-image: 
        radial-gradient(circle at 85% 15%, rgba(220, 38, 38, 0.16) 0%, transparent 55%),
        radial-gradient(circle at 10% 90%, rgba(108, 130, 147, 0.12) 0%, transparent 45%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 3.25rem 2.5rem;
    position: relative;
    overflow: hidden;
    margin-bottom: 2.5rem;
    box-shadow: 0 10px 30px -10px rgba(11, 19, 43, 0.4);
}

.legal-hero::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 280px;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(220, 38, 38, 0.04));
    pointer-events: none;
}

.legal-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(220, 38, 38, 0.12);
    color: #F87171;
    border: 1px solid rgba(220, 38, 38, 0.35);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.38rem 0.95rem;
    border-radius: 9999px;
    margin-bottom: 1.25rem;
}

.legal-hero-title {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(2rem, 3.8vw, 3rem);
    font-weight: 850;
    line-height: 1.15;
    color: #FFFFFF;
    margin-bottom: 1rem;
    letter-spacing: -0.5px;
}

.legal-hero-title .text-accent-red {
    color: #DC2626;
}

.legal-hero-lead {
    font-size: 1.05rem;
    color: #94A3B8;
    line-height: 1.65;
    max-width: 740px;
    margin-bottom: 1.75rem;
}

.legal-meta-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.legal-meta-pill {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #E2E8F0;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.35rem 0.85rem;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.legal-meta-pill i {
    color: #DC2626;
    font-size: 0.9rem;
}

/* ── SIDEBAR STICKY NAVIGATION ── */
.legal-sidebar {
    position: sticky;
    top: 110px;
    z-index: 10;
}

.legal-toc-card {
    background: #FFFFFF;
    border: 1.5px solid #E2E8F0;
    border-radius: 18px;
    padding: 1.5rem;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.04);
    margin-bottom: 1.25rem;
}

.legal-toc-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #F1F5F9;
}

.legal-toc-title {
    font-family: 'Outfit', sans-serif;
    font-size: 0.88rem;
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #0F172A;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.legal-toc-title i {
    color: #DC2626;
}

.legal-toc-count {
    font-size: 0.75rem;
    font-weight: 700;
    background: #F1F5F9;
    color: #64748B;
    padding: 0.2rem 0.55rem;
    border-radius: 6px;
}

.legal-toc-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    max-height: calc(100vh - 380px);
    overflow-y: auto;
    scrollbar-width: thin;
}

.legal-toc-links::-webkit-scrollbar {
    width: 4px;
}

.legal-toc-links::-webkit-scrollbar-thumb {
    background: #E2E8F0;
    border-radius: 4px;
}

.legal-toc-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.55rem 0.75rem;
    border-radius: 10px;
    color: #475569;
    font-size: 0.86rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.legal-toc-link:hover,
.legal-toc-link.active {
    background: #FEF2F2;
    color: #DC2626;
    border-left-color: #DC2626;
    font-weight: 700;
}

.legal-toc-link i {
    font-size: 0.82rem;
    color: #94A3B8;
    transition: color 0.2s ease;
}

.legal-toc-link:hover i,
.legal-toc-link.active i {
    color: #DC2626;
}

/* ── SIDEBAR HELP CARD ── */
.legal-help-card {
    background: linear-gradient(145deg, #0B132B 0%, #172554 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 18px;
    padding: 1.5rem;
    color: #FFFFFF;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px -2px rgba(11, 19, 43, 0.25);
}

.legal-help-title {
    font-family: 'Outfit', sans-serif;
    font-size: 1.05rem;
    font-weight: 800;
    color: #FFFFFF;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.legal-help-title i {
    color: #22C55E;
}

.legal-help-desc {
    font-size: 0.86rem;
    color: #94A3B8;
    line-height: 1.55;
    margin-bottom: 1.15rem;
}

.legal-help-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: #DC2626;
    color: #FFFFFF;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.65rem 1.15rem;
    border-radius: 9999px;
    text-decoration: none;
    width: 100%;
    transition: background-color 0.2s ease;
    border: none;
}

.legal-help-btn:hover {
    background: #B91C1C;
    color: #FFFFFF;
}

/* ── MOBILE HORIZONTAL SCROLL PILLS ── */
.mobile-legal-pills {
    display: none;
    overflow-x: auto;
    white-space: nowrap;
    gap: 0.5rem;
    padding-bottom: 0.85rem;
    margin-bottom: 1.5rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.mobile-legal-pills::-webkit-scrollbar {
    display: none;
}

@media (max-width: 991px) {
    .mobile-legal-pills {
        display: flex;
    }
}

.mobile-legal-pill-link {
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    color: #334155;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.4rem 0.85rem;
    border-radius: 9999px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    flex-shrink: 0;
}

.mobile-legal-pill-link.active,
.mobile-legal-pill-link:hover {
    background: #FEF2F2;
    border-color: #FECACA;
    color: #DC2626;
    font-weight: 700;
}

/* ── LEGAL CONTENT CARDS ── */
.legal-card {
    background: #FFFFFF;
    border: 1.5px solid #E2E8F0;
    border-radius: 20px;
    padding: 2.25rem 2.25rem;
    margin-bottom: 1.75rem;
    box-shadow: 0 4px 18px -2px rgba(15, 23, 42, 0.03);
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
    scroll-margin-top: 110px;
}

.legal-card:hover {
    border-color: #CBD5E1;
    box-shadow: 0 8px 24px -4px rgba(15, 23, 42, 0.06);
}

.legal-card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.35rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #F1F5F9;
}

.legal-card-num {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #FEF2F2;
    color: #DC2626;
    border: 1px solid #FECACA;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Outfit', sans-serif;
    font-size: 0.95rem;
    font-weight: 850;
    flex-shrink: 0;
}

.legal-card-title {
    font-family: 'Outfit', sans-serif;
    font-size: 1.35rem;
    font-weight: 850;
    color: #0F172A;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: -0.3px;
    line-height: 1.25;
}

.legal-card-body p {
    font-size: 0.96rem;
    color: #334155;
    line-height: 1.7;
    margin-bottom: 1rem;
}

.legal-card-body p:last-child {
    margin-bottom: 0;
}

.legal-card-body ul {
    list-style: none;
    padding: 0;
    margin: 0 0 1.15rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

.legal-card-body li {
    font-size: 0.93rem;
    color: #334155;
    line-height: 1.6;
    display: flex;
    align-items: flex-start;
    gap: 0.7rem;
}

.legal-check-icon {
    color: #DC2626;
    font-size: 1.05rem;
    flex-shrink: 0;
    margin-top: 0.15rem;
}

/* ── CALLOUT HIGHLIGHT BOXES ── */
.legal-callout {
    border-radius: 12px;
    padding: 1.15rem 1.35rem;
    margin: 1.25rem 0;
    font-size: 0.92rem;
    line-height: 1.6;
}

.legal-callout-red {
    background: #FEF2F2;
    border-left: 4px solid #DC2626;
    color: #991B1B;
}

.legal-callout-red strong {
    color: #7F1D1D;
}

.legal-callout-blue {
    background: #F0F9FF;
    border-left: 4px solid #0284C7;
    color: #075985;
}

.legal-callout-blue strong {
    color: #0C4A6E;
}

.legal-callout-gold {
    background: #FFFBEB;
    border-left: 4px solid #D97706;
    color: #92400E;
}

.legal-callout-gold strong {
    color: #78350F;
}

/* ── BOTTOM CALLOUT CTA ── */
.legal-bottom-cta {
    background: #FFFFFF;
    border: 1.5px solid #FECACA;
    border-radius: 20px;
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow: 0 4px 20px -2px rgba(220, 38, 38, 0.08);
    margin-top: 2rem;
    margin-bottom: 3.5rem;
}

.legal-bottom-cta h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 850;
    color: #0F172A;
    text-transform: uppercase;
    margin-bottom: 0.65rem;
}

.legal-bottom-cta p {
    font-size: 0.96rem;
    color: #64748B;
    max-width: 600px;
    margin: 0 auto 1.5rem auto;
    line-height: 1.6;
}

.legal-cta-buttons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.85rem;
}

.btn-legal-wa {
    background: #DC2626;
    color: #FFFFFF;
    font-family: 'Outfit', sans-serif;
    font-size: 0.92rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.75rem 1.75rem;
    border-radius: 9999px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: background-color 0.2s ease;
    border: none;
}

.btn-legal-wa:hover {
    background: #B91C1C;
    color: #FFFFFF;
}

.btn-legal-alt {
    background: #FFFFFF;
    color: #0F172A;
    border: 1.5px solid #E2E8F0;
    font-family: 'Outfit', sans-serif;
    font-size: 0.92rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.75rem 1.75rem;
    border-radius: 9999px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s ease;
}

.btn-legal-alt:hover {
    background: #F8FAFC;
    border-color: #CBD5E1;
    color: #0F172A;
}

/* ── RESPONSIVE TWEAKS ── */
@media (max-width: 767px) {
    .legal-hero {
        padding: 2rem 1.25rem !important;
        border-radius: 18px !important;
        margin-bottom: 1.5rem !important;
    }
    
    .legal-hero-title {
        font-size: 1.75rem !important;
    }
    
    .legal-hero-lead {
        font-size: 0.92rem !important;
        margin-bottom: 1.25rem !important;
    }
    
    .legal-card {
        padding: 1.5rem 1.25rem !important;
        border-radius: 16px !important;
        margin-bottom: 1.25rem !important;
    }
    
    .legal-card-title {
        font-size: 1.15rem !important;
    }
    
    .legal-bottom-cta {
        padding: 1.75rem 1.25rem !important;
        border-radius: 16px !important;
    }
}
