/* 
 * Loop108 Privacy Policy - Premium Stylesheet
 * Developer: FG Designs
 */

:root {
    /* Color Palette */
    --primary-color: #4f46e5;
    --primary-hover: #4338ca;
    --primary-subtle: rgba(79, 70, 229, 0.1);
    
    --dark-color: #0f172a;
    --light-color: #f8fafc;
    --text-main: #334155;
    --text-muted: #64748b;
    
    --success-subtle: rgba(34, 197, 94, 0.1);
    --danger-subtle: rgba(239, 68, 68, 0.1);
    --warning-subtle: rgba(245, 158, 11, 0.1);
    --info-subtle: rgba(6, 182, 212, 0.1);
    --secondary-subtle: rgba(100, 116, 139, 0.1);
    --dark-subtle: rgba(15, 23, 42, 0.1);

    /* Typography */
    --font-family: 'Inter', system-ui, -apple-system, sans-serif;
    
    /* Layout */
    --border-radius: 1rem;
    --border-radius-lg: 1.5rem;
    --box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.01);
    --box-shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Base Styles */
body {
    font-family: var(--font-family);
    color: var(--text-main);
    background-color: var(--light-color);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--dark-color);
    letter-spacing: -0.025em;
}

p {
    font-size: 1.05rem;
    margin-bottom: 1.25rem;
}

/* Custom Utilities */
.text-primary { color: var(--primary-color) !important; }
.bg-primary { background-color: var(--primary-color) !important; }
.bg-primary-subtle { background-color: var(--primary-subtle) !important; }
.bg-success-subtle { background-color: var(--success-subtle) !important; }
.bg-danger-subtle { background-color: var(--danger-subtle) !important; }
.bg-warning-subtle { background-color: var(--warning-subtle) !important; }
.bg-info-subtle { background-color: var(--info-subtle) !important; }
.bg-secondary-subtle { background-color: var(--secondary-subtle) !important; }
.bg-dark-subtle { background-color: var(--dark-subtle) !important; }

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.3);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: var(--light-color);
}
::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Scroll Progress Bar */
.scroll-progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: transparent;
    z-index: 1050; /* Above navbar */
}
.scroll-progress-bar {
    height: 100%;
    background: var(--primary-color);
    width: 0%;
    transition: width 0.1s ease-out;
    box-shadow: 0 0 10px rgba(79, 70, 229, 0.5);
}

/* Navbar */
.glass-navbar {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    padding: 1rem 0;
}
.glass-navbar.scrolled {
    padding: 0.5rem 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}
.navbar-nav .nav-link {
    font-weight: 500;
    color: var(--text-main);
    transition: color 0.2s ease;
}
.navbar-nav .nav-link:hover {
    color: var(--primary-color);
}
.toggle-icon {
    font-size: 1.5rem;
}
.navbar-toggler:focus {
    box-shadow: none;
}

/* Hero Section */
.hero-section {
    position: relative;
    padding: 150px 0 100px;
    background: linear-gradient(135deg, #f0f4ff 0%, #ffffff 100%);
    overflow: hidden;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}
.hero-bg-shapes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
    pointer-events: none;
}
.shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
    z-index: -1;
}
.shape-1 {
    top: -10%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: rgba(79, 70, 229, 0.15);
}
.shape-2 {
    bottom: -10%;
    right: -5%;
    width: 400px;
    height: 400px;
    background: rgba(6, 182, 212, 0.1);
}
.hero-content {
    position: relative;
    z-index: 1;
}

/* Cards & Containers */
.glass-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.5);
}
.rounded-4 {
    border-radius: var(--border-radius-lg) !important;
}

/* Sidebar / Table of Contents */
.sticky-sidebar {
    position: sticky;
    top: 100px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}
.toc-nav .nav-link {
    color: var(--text-muted);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.2s ease;
    margin-bottom: 0.25rem;
}
.toc-nav .nav-link:hover, .toc-nav .nav-link.active {
    color: var(--primary-color);
    background-color: var(--primary-subtle);
}

/* Policy Content Sections */
.content-section {
    padding-top: 80px;
    margin-top: -60px; /* Offset for sticky navbar */
}
.icon-box {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}
.custom-list li {
    padding: 0.5rem 0;
    font-size: 1.05rem;
    display: flex;
    align-items: flex-start;
}
.custom-list li i {
    margin-top: 4px;
}

/* Gradient Card */
.bg-gradient-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, #818cf8 100%);
}

/* Permission Cards */
.permission-card {
    background-color: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.05) !important;
    transition: box-shadow 0.3s ease;
}
.permission-card:hover {
    box-shadow: var(--box-shadow-hover) !important;
}

/* Footer */
.site-footer {
    border-top: 1px solid rgba(255,255,255,0.1);
}
.footer-links a {
    transition: color 0.2s ease;
}
.footer-links a:hover {
    color: #ffffff !important;
    text-decoration: underline !important;
}

/* Back to Top Button */
#backToTop {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    padding: 0;
}
#backToTop.show {
    opacity: 1;
    visibility: visible;
}
#backToTop:hover {
    transform: translateY(-5px);
}

/* Animations */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Dark Mode Support (Optional/OS Level) */
@media (prefers-color-scheme: dark) {
    :root {
        --dark-color: #f8fafc;
        --light-color: #0f172a;
        --text-main: #94a3b8;
        --text-muted: #64748b;
    }
    
    body {
        background-color: #0f172a;
        color: #e2e8f0;
    }
    
    h1, h2, h3, h4, h5, h6 {
        color: #ffffff;
    }
    
    .glass-navbar {
        background: rgba(15, 23, 42, 0.85);
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .navbar-nav .nav-link {
        color: #e2e8f0;
    }
    .navbar-toggler .toggle-icon {
        color: #e2e8f0 !important;
    }
    
    .hero-section {
        background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
        border-bottom-color: rgba(255,255,255,0.05);
    }
    
    .glass-card, .card.bg-light, .permission-card {
        background: #1e293b !important;
        border-color: rgba(255,255,255,0.05) !important;
    }
    
    .alert-light {
        background-color: #1e293b;
        color: #e2e8f0;
    }
    
    .toc-nav .nav-link {
        color: #94a3b8;
    }
    .toc-nav .nav-link:hover, .toc-nav .nav-link.active {
        background-color: rgba(79, 70, 229, 0.2);
    }
    
    hr {
        border-color: rgba(255,255,255,0.1);
    }
}

/* Responsive adjustments */
@media (max-width: 991.98px) {
    .content-section {
        padding-top: 100px;
    }
    .hero-section {
        padding: 120px 0 80px;
    }
}
