/* Main CSS - Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #1a365d;
    background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%);
    min-height: 100vh;
    padding-top: 160px;
    padding-bottom: 0;
    display: flex;
    flex-direction: column;
}

.container {
    margin: 0 auto;
    padding: 0 40px;
    width: 100%;
}

/* Header Styles */
header {
    background-color: transparent !important;
    background-image: none !important;
    background: transparent !important;
    color: #1a365d;
    padding: 1.2rem 0;
    box-shadow: 0 4px 20px rgba(26, 54, 93, 0.15);
    border-bottom: 4px solid #2b6cb0;
    border-radius: 0 0 12px 12px;
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: calc(100% - 80px);
    z-index: 1000;
    overflow: hidden;
    min-height: auto;
    height: auto;
}

/* Keep header transparent even with image */
header:has(.header-bg[style*="background-image"]) {
    background: transparent !important;
    backdrop-filter: blur(5px);
}

.header-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    /* Background will be set by JavaScript dynamically */
    background-size: auto 100% !important;
    background-position: left center !important;
    background-repeat: no-repeat !important;
    background-attachment: local !important;
    border-radius: 0 0 12px 12px;
    overflow: hidden;
    z-index: -1;
    min-height: 100%;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: nowrap; /* Prevent wrapping to force mobile menu */
    position: relative;
    z-index: 1;
    margin-top: 1.5rem;
    padding: 0 40px;
    min-height: 60px; /* Ensure consistent height */
}

.logo {
    font-size: 2.4rem;
    font-weight: 700;
    color: #ffffff;
    text-shadow: none;
    letter-spacing: -0.5px;
    margin-left: 10rem;
}

/* Mobile Menu Toggle Button */
.mobile-menu-toggle {
    display: none;
    background: rgba(43, 108, 176, 0.95);
    border: none;
    color: #ffffff;
    font-size: 1.3rem;
    padding: 0.5rem 0.7rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    min-width: 40px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    line-height: 1;
    font-weight: 400;
    margin-left: auto;
}

.mobile-menu-toggle:hover {
    background: rgba(43, 108, 176, 1);
    box-shadow: 0 4px 12px rgba(43, 108, 176, 0.4);
    color: #ffffff;
}

.mobile-menu-toggle.active {
    background: rgba(35, 74, 135, 0.98);
    color: white;
    box-shadow: 0 4px 12px rgba(35, 74, 135, 0.4);
}

/* Navigation Menu */
nav ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
    align-items: center;
    white-space: nowrap;
    transition: all 0.3s ease;
}

nav a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
    padding: 0.9rem 1.8rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    background: transparent;
    letter-spacing: 0.3px;
    display: inline-block;
    text-align: center;
    min-width: 100px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.7);
}

nav a:hover {
    background: linear-gradient(135deg, #2b6cb0 0%, #234a87 100%);
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.5);
}

nav a.active {
    background: linear-gradient(135deg, #2b6cb0 0%, #234a87 100%);
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}


.management-icon {
    background: #6c757d;
    color: white;
    padding: 0.8rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1.2rem;
    box-shadow: none;
    text-decoration: none;
    display: inline-block;
}

.management-icon:hover {
    background: #495057;
    transform: none;
    box-shadow: none;
}

/* Cookie Consent Banner */
.cookie-consent {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: calc(100% - 80px);
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 2px solid #2b6cb0;
    border-radius: 12px 12px 0 0;
    box-shadow: 0 -8px 32px rgba(26, 54, 93, 0.2);
    padding: 1.5rem 40px;
    z-index: 1001;
    display: none;
}

.cookie-consent.show {
    display: block;
    animation: slideUp 0.5s ease-out;
}

.cookie-consent.hidden {
    display: none;
}

.cookie-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.cookie-text {
    flex: 1;
    min-width: 300px;
}

.cookie-text h4 {
    color: #2b6cb0;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.cookie-text p {
    color: #4a5568;
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

.cookie-buttons {
    display: flex;
    gap: 1rem;
    flex-shrink: 0;
}

.cookie-accept {
    background: linear-gradient(135deg, #2b6cb0 0%, #2c5aa0 100%);
    padding: 0.8rem 1.5rem;
    font-size: 0.9rem;
}

.cookie-decline {
    background: #6c757d;
    padding: 0.8rem 1.5rem;
    font-size: 0.9rem;
}

@keyframes slideUp {
    from {
        transform: translateX(-50%) translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }
}

@keyframes slideDown {
    from {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }
    to {
        transform: translateX(-50%) translateY(100%);
        opacity: 0;
    }
}

/* Main Content */
main {
    flex: 1;
    padding: 3rem 0;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 12px;
    margin: 0 auto 2rem auto;
    box-shadow: 0 8px 32px rgba(26, 54, 93, 0.1);
    width: 100%;
    max-width: calc(100% - 80px);
    position: relative;
    z-index: 0;
    backdrop-filter: blur(0.5px);
}

/* Animations */
@keyframes fadeInSlide {
    from { 
        opacity: 0; 
        transform: translateY(30px) scale(0.95); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0) scale(1); 
    }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.1); opacity: 0.4; }
}

@keyframes headerPulse {
    0%, 100% { background-color: transparent !important; }
    50% { background-color: transparent !important; }
}

/* Form Elements */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.8rem;
    font-weight: 600;
    color: #2c3e50;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1rem;
}

/* Buttons */
.btn {
    background: linear-gradient(135deg, #2b6cb0 0%, #2c5aa0 100%);
    color: white;
    border: none;
    padding: 1.2rem 2.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(43, 108, 176, 0.3);
    text-decoration: none;
    display: inline-block;
    text-align: center;
    letter-spacing: 0.5px;
}

.btn:hover {
    background: linear-gradient(135deg, #2c5aa0 0%, #1a365d 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(43, 108, 176, 0.4);
}

.btn-secondary {
    background: #6c757d;
}

.btn-danger {
    background: #dc3545;
}

.cta-button {
    background: linear-gradient(135deg, #2b6cb0 0%, #2c5aa0 100%);
    color: white;
    padding: 1.2rem 2.8rem;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    box-shadow: 0 6px 20px rgba(43, 108, 176, 0.3);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.cta-button:hover {
    background: linear-gradient(135deg, #2c5aa0 0%, #1a365d 100%);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(43, 108, 176, 0.4);
}

/* File Upload */
.file-upload {
    position: relative;
    overflow: hidden;
    display: inline-block;
    background: #0056b3;
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.file-upload:hover {
    background: #004494;
    transform: none;
    box-shadow: none;
}

.file-upload input[type=file] {
    position: absolute;
    left: -9999px;
}

/* Messages */
.success-message {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    padding: 1.2rem;
    border-radius: 8px;
    margin: 1rem 0;
    text-align: center;
    font-weight: 600;
    font-size: 1.1rem;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
    animation: slideInDown 0.4s ease-out;
    border: 2px solid rgba(255, 255, 255, 0.3);
    position: relative;
    z-index: 1000;
}

.error-message {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white;
    padding: 1.2rem;
    border-radius: 8px;
    margin: 1rem 0;
    text-align: center;
    font-weight: 600;
    font-size: 1.1rem;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
    animation: slideInDown 0.4s ease-out;
    border: 2px solid rgba(255, 255, 255, 0.3);
    position: relative;
    z-index: 1000;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Footer */
footer {
    background: linear-gradient(135deg, #1a365d 0%, #2b6cb0 100%);
    color: #e2e8f0;
    border-top: 4px solid #bee3f8;
    text-align: center;
    padding: 1rem 40px 0.25rem 40px;
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: calc(100% - 80px);
    border-radius: 12px 12px 0 0;
    z-index: 999;
    margin: 2rem auto 0 auto;
}

.footer-content {
    position: relative;
}

.footer-cms-btn {
    position: absolute;
    bottom: 0;
    right: 0.05rem;
    background: rgba(255, 255, 255, 0.1);
    color: #e2e8f0;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.7rem;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
}

.footer-cms-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.footer-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('../images/footer-background.png') center center / cover no-repeat;
    opacity: 0.3;
}

.footer-content {
    position: relative;
    z-index: 1;
}

#footerContent {
    font-size: 0.8rem;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid rgba(226, 232, 240, 0.3);
    color: #cbd5e0;
}

/* Responsive Design */
/* Large screens */
@media (max-width: 1240px) {
    header {
        max-width: calc(100% - 60px);
    }
    
    .header-content {
        padding: 0 30px;
    }
    
    footer {
        padding: 1rem 30px 0.25rem 30px;
        max-width: calc(100% - 60px);
    }
    
    main {
        padding: 3rem 0;
        max-width: calc(100% - 60px);
    }
    
    .cookie-consent {
        padding: 1.5rem 30px;
        max-width: calc(100% - 60px);
    }
    
    .container {
        padding: 0 30px;
    }
}

/* Medium screens - tablets */
@media (max-width: 1024px) {
    header {
        max-width: calc(100% - 50px);
    }
    
    .header-content {
        padding: 0 25px;
    }
    
    footer {
        padding: 1rem 25px 0.25rem 25px;
        max-width: calc(100% - 50px);
    }
    
    main {
        padding: 2rem 0;
        max-width: calc(100% - 50px);
    }
    
    .cookie-consent {
        padding: 1.5rem 25px;
        max-width: calc(100% - 50px);
    }
    
    .container {
        padding: 0 25px;
    }
}

/* Medium-large screens - prevent navigation wrapping under logo */
@media (max-width: 1200px) {
    .header-content {
        padding: 0 25px;
    }

    /* Logo stays at original position and size - no changes */

    nav ul {
        gap: 1rem;
    }

    nav a {
        padding: 0.8rem 1.4rem;
        min-width: 90px;
        font-size: 0.95rem;
    }
}

/* Medium screens - logo stays unchanged */
@media (max-width: 1100px) {
    /* Logo keeps original position and size - no changes */
}

/* Small-medium screens - switch to mobile menu earlier */
@media (max-width: 950px) {
    body {
        padding-top: 160px;
    }

    header {
        min-height: auto;
        max-width: calc(100% - 40px);
        overflow: visible;
    }

    .header-content {
        padding: 0 20px;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 0.75rem;
    }

    /* Hide logo on mobile */
    .logo {
        display: none;
    }

    /* Show mobile menu toggle centered below logo */
    .mobile-menu-toggle {
        display: block;
        z-index: 1001;
        margin-left: 0;
        position: relative;
    }

    /* Hide navigation by default on mobile to prevent wrapping */
    nav ul {
        display: none;
        position: absolute;
        top: calc(100% + 0.5rem);
        left: 50%;
        transform: translateX(-50%);
        width: 180px;
        background: rgba(43, 108, 176, 0.98);
        backdrop-filter: blur(10px);
        border-radius: 8px;
        padding: 0.4rem;
        flex-direction: column;
        gap: 0.25rem;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
        animation: slideDownMenu 0.3s ease-out;
        z-index: 9999;
        border: 1px solid rgba(255, 255, 255, 0.2);
    }

    /* Show navigation when menu is active */
    nav ul.show {
        display: flex;
    }

    nav a {
        width: 100%;
        text-align: center;
        padding: 0.5rem 0.8rem;
        margin: 0;
        border-radius: 5px;
        min-width: auto;
        background: transparent;
        transition: all 0.2s ease;
        font-weight: 500;
        letter-spacing: 0.3px;
        color: #ffffff;
        border: none;
        box-shadow: none;
        text-shadow: none;
        font-size: 0.9rem;
    }

    nav a:hover {
        background: rgba(255, 255, 255, 0.15);
        color: #ffffff;
        transform: none;
    }

    nav a.active {
        background: rgba(255, 255, 255, 0.25);
        color: #ffffff;
        font-weight: 600;
    }

    .header-bg {
        height: 100%;
        min-height: 100%;
        background-attachment: local !important;
        background-size: auto 100% !important;
        background-position: left center !important;
    }

    footer {
        padding: 1rem 20px 0.25rem 20px;
        max-width: calc(100% - 40px);
    }

    main {
        margin-top: 1rem;
        padding: 1.5rem 0;
        max-width: calc(100% - 40px);
    }

    .cookie-consent {
        padding: 1.5rem 20px;
        border-radius: 12px;
        max-width: calc(100% - 40px);
    }

    .cookie-content {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }

    .cookie-buttons {
        justify-content: center;
        flex-wrap: wrap;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .container {
        padding: 0 20px;
    }
}

/* Mobile menu animation */
@keyframes slideDownMenu {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Additional mobile menu enhancements */
@media (max-width: 950px) {
    /* Improve touch targets for mobile */
    nav a {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        touch-action: manipulation;
    }

    /* Smooth menu transitions */
    nav ul {
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Better visual feedback for menu toggle */
    .mobile-menu-toggle:active {
        transform: scale(0.95);
    }

    /* Prevent horizontal scrolling when menu is open */
    body.menu-open {
        overflow-x: hidden;
    }

    /* Overlay effect when menu is open */
    .header-content::after {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 999;
        pointer-events: none;
    }

    .header-content.menu-open::after {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }
}

/* Extra small screens - mobile portrait */
@media (max-width: 480px) {
    body {
        padding-top: 120px;
        padding-bottom: 0;
    }

    header {
        min-height: auto;
        max-width: calc(100% - 30px);
    }

    .header-content {
        padding: 0 15px;
        margin-top: 0.5rem;
    }

    /* Logo keeps original position and size - no changes */

    .mobile-menu-toggle {
        padding: 0.5rem;
        font-size: 1.3rem;
    }

    nav ul {
        padding: 1rem;
    }

    nav a {
        padding: 0.8rem;
        margin: 0.1rem 0;
        font-size: 0.9rem;
    }

    .header-bg {
        height: 100%;
        min-height: 100%;
        background-attachment: local !important;
        background-size: auto 100% !important;
        background-position: left center !important;
    }

    footer {
        padding: 1rem 15px 0.25rem 15px;
        max-width: calc(100% - 30px);
    }

    main {
        padding: 1rem 0;
        max-width: calc(100% - 30px);
    }

    .cookie-consent {
        padding: 1.5rem 15px;
        max-width: calc(100% - 30px);
    }

    .container {
        padding: 0 15px;
    }
}

/* Force header transparency - highest specificity */
header, 
header.header, 
#header,
body header,
html body header {
    background: transparent !important;
    background-color: transparent !important;
    background-image: none !important;
}

/* Allow header-bg to show CMS images but remove default background */
.header-bg,
header .header-bg,
body header .header-bg,
html body header .header-bg {
    background-color: transparent !important;
    /* Don't override background-image - let CMS images show */
    opacity: 1 !important;
    display: block !important;
}

/* Allow JavaScript to set header background images */
.header-bg {
    /* JavaScript will set background-image */
}

/* Utility Classes */
.hidden {
    display: none !important;
}

.text-center {
    text-align: center;
}

.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mb-3 { margin-bottom: 3rem; }

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }

/* ============================================
   🎨 HEADER ANIMATIONS - EASY TO REMOVE
   Delete this entire section to undo animations
   ============================================ */

/* Animation 1: Scroll-Based Header Shrink */
header {
    transition: all 0.3s ease;
}

header.scrolled {
    padding: 0.6rem 0;
    box-shadow: 0 2px 15px rgba(26, 54, 93, 0.2);
}

header.scrolled .header-content {
    margin-top: 0.8rem;
}

header.scrolled .logo {
    font-size: 1.8rem;
    transition: font-size 0.3s ease;
}

/* Animation 2: Nav Link Underline on Hover */
nav a {
    position: relative;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 80%;
    height: 2px;
    background: #ffffff;
    transition: transform 0.3s ease;
}

nav a:hover::after,
nav a.active::after {
    transform: translateX(-50%) scaleX(1);
}

/* Mobile: Remove underline animation */
@media (max-width: 950px) {
    nav a::after {
        display: none;
    }
}

/* ============================================
   END OF HEADER ANIMATIONS
   ============================================ */