/* Ensure full viewport coverage */
html, body {
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, #041322 0%, #0A1A33 50%, #041322 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Override footer background for consistency */
.footer-container {
    background: linear-gradient(135deg, #041322 0%, #0A1A33 50%, #041322 100%);
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

/* Mobile responsiveness */
@media screen and (max-width: 768px) {
    .page-wrapper {
        padding: 100px 15px 60px;
    }
}

/* Smooth scroll behavior for anchor links */
html {
    scroll-behavior: smooth;
}

/* Ensure navigation is properly styled */
.nav.scrolled {
    background: rgba(4, 19, 34, 0.95);
    backdrop-filter: blur(10px);
}

/* Code of Conduct Page Specific Styles */

.page-background {
    background: linear-gradient(135deg, #041322 0%, #0A1A33 50%, #041322 100%);
    width: 100vw;
    min-height: 100vh;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    padding: 0;
}

.page-wrapper {
    background: transparent; /* Remove duplicate background */
    color: white;
    padding: 120px 20px 80px;
    min-height: calc(100vh - 200px);
    max-width: 900px;
    margin: 0 auto;
    line-height: 1.7;
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
    width: 100%;
    box-sizing: border-box;
    position: relative;
    left: 0;
    right: 0;
    margin-left: auto;
    margin-right: auto;
}

/* Animation for page load */
.main-content:not(.loaded) .page-wrapper {
    opacity: 0;
    transform: translateY(20px);
}

.page-title {
    font-family: 'Encode Sans Semi Condensed', sans-serif;
    font-size: 3.5rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 3rem;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    background: linear-gradient(135deg, #ffffff, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 1px;
}

.page-paragraph {
    font-family: 'Encode Sans Semi Condensed', sans-serif;
    font-size: 1.2rem;
    line-height: 1.8;
    margin-bottom: 2.5rem;
    text-align: justify;
    color: #E6F3FF;
    padding: 0 1rem;
}

.code-section {
    margin-bottom: 3rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 15px;
    padding: 2rem;
    border-left: 4px solid #6fa8c7;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.code-section:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.section-subtitle {
    font-family: 'Encode Sans Semi Condensed', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: #6fa8c7;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.5rem;
    letter-spacing: 0.5px;
}

.section-subtitle::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background: linear-gradient(90deg, #6fa8c7, #a78bfa);
    border-radius: 2px;
}

.section-paragraph {
    font-family: 'Encode Sans Semi Condensed', sans-serif;
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
    color: #E6F3FF;
    text-align: justify;
}

.styled-list {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.styled-list li {
    position: relative;
    padding: 0.8rem 0 0.8rem 2rem;
    font-size: 1.1rem;
    line-height: 1.6;
    color: #E6F3FF;
    margin-bottom: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.styled-list li:hover {
    background: rgba(111, 168, 199, 0.1);
    padding-left: 2.5rem;
}

.styled-list li::before {
    content: '▶';
    position: absolute;
    left: 0.5rem;
    top: 0.8rem;
    color: #6fa8c7;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.styled-list li:hover::before {
    color: #a78bfa;
    transform: scale(1.2);
}

/* Mobile Responsiveness */
@media screen and (max-width: 768px) {
    .page-wrapper {
        padding: 100px 15px 60px;
    }
    
    .page-title {
        font-size: 2.5rem;
        margin-bottom: 2rem;
    }
    
    .page-paragraph {
        font-size: 1.1rem;
        padding: 0 0.5rem;
    }
    
    .code-section {
        padding: 1.5rem;
        margin-bottom: 2rem;
    }
    
    .section-subtitle {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .section-paragraph {
        font-size: 1rem;
    }
    
    .styled-list li {
        font-size: 1rem;
        padding: 0.6rem 0 0.6rem 1.8rem;
    }
}

@media screen and (max-width: 480px) {
    .page-wrapper {
        padding: 90px 10px 50px;
    }
    
    .page-title {
        font-size: 2rem;
        margin-bottom: 1.5rem;
    }
    
    .page-paragraph {
        font-size: 1rem;
        text-align: left;
    }
    
    .section-paragraph {
        font-size: 0.95rem;
        text-align: left;
    }
    
    .code-section {
        padding: 1rem;
        border-left: 3px solid #6fa8c7;
    }
    
    .section-subtitle {
        font-size: 1.3rem;
    }
    
    .styled-list li {
        font-size: 0.95rem;
        padding: 0.5rem 0 0.5rem 1.5rem;
    }
}

/* Animation for sections */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.code-section {
    animation: fadeInUp 0.6s ease forwards;
}

.code-section:nth-child(even) {
    animation-delay: 0.1s;
}

.code-section:nth-child(odd) {
    animation-delay: 0.2s;
}

/* Print styles */
@media print {
    .nav, .footer-container {
        display: none;
    }
    
    .page-wrapper {
        background: white;
        color: black;
        box-shadow: none;
        padding: 20px;
    }
    
    .page-title, .section-subtitle {
        color: black;
    }
    
    .section-paragraph, .page-paragraph, .styled-list li {
        color: black;
    }
    
    .code-section {
        background: #f5f5f5;
        border-left: 4px solid #333;
        page-break-inside: avoid;
    }
}