/* Main Styles for Pyramid Timberwoods Login Page */

:root {
    --primary-color: #924d0d; /* Wood brown color */
    --secondary-color: #dc974e; /* Darker brown */
    --accent-color: #d4a76a; /* Light wood color */
    --background-color: #f9f7f4; /* Off-white */
    --surface-color: #ffffff;
    --text-color: #555555;
    --text-secondary-color: #777777;
    --border-color: #ddd;
    --header-bg-default: #ffffff;
    /* Variables for glass effect */
    --login-bg-blur: 3px; /* UPDATED: Blur amount for the main background image */
    --login-brand-backdrop-blur: 15px; /* Blur for brown glass panel */
    --login-form-backdrop-blur: 10px;  /* Blur for white glass panel */
    --error-color: #e74c3c;
    --success-color: #2ecc71;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
    --logo-width: 150px; /* Default logo width */
    --logo-height: auto; /* Default logo height */
    --header-backdrop-blur: 10px; /* Blur for scrolled header */
    --card-backdrop-blur: 10px;   /* Blur for content cards */
    --collections-bg-blur: 9px;
    --header-height: 125px; /* Adjustable header height */
    --header-padding: 0 50px; /* Adjustable header padding */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    min-height: 100vh; /* Ensure body takes full viewport height */
    display: flex;
    flex-direction: column; /* Stack header, main, footer vertically */
    /* Remove centering styles */
    /* align-items: center; */ 
    /* justify-content: center; */
    /* Remove body padding */
    /* padding: 20px; */
    position: relative; /* Needed for ::before positioning */
    background-color: var(--background-color); /* Fallback if image fails */
}

/* Keep centering ONLY for login page */
body.login-page {
    align-items: center;
    justify-content: center;
    position: relative; /* Needed again for pseudo-element */
    overflow: hidden; /* Hide blur overflow */
    padding: 20px; /* OK to keep for login page */
}

/* Re-add Background Image and Blur for Login Page */
body.login-page::before {
    content: '';
    position: absolute;
    top: -10px; left: -10px; right: -10px; bottom: -10px; /* Cover edges */
    /* !!! CRITICAL: Replace with your actual image path below !!! */
    background-image: url('../images/Pyramid-Experience-Centre.jpg'); 
    background-size: cover;
    background-position: center;
    filter: blur(var(--login-bg-blur)); /* Uses the 3px blur */
    z-index: -1; /* Behind login container */
}

.container {
    width: 100%;
    max-width: 1000px; /* Or your desired max-width */
    margin: 0 auto;
    /* Remove padding: 20px; if present */
}

/* Ensure main content area fills available space */
main {
    flex-grow: 1;
    width: 100%;
    background-color: transparent; /* Important for body background to show */
    /* padding: 40px 50px; /* Optional: Add base padding or handle in species.css */ 
}

.login-container {
    display: flex;
    background-color: transparent; /* Container itself is transparent */
    z-index: 1; /* Ensure it's above the ::before */
    border-radius: 14px; 
    overflow: hidden; /* Keep overflow hidden */
    box-shadow: var(--shadow);
    min-height: 400px;
}

/* Brand Section Styles */
.brand-section {
    flex: 1;
    /* Remove solid gradient */
    /* background: linear-gradient(...); */ 
    
    /* Glass Effect */
    background-color: rgba(60, 40, 30, 0.35); /* Semi-transparent dark brown */
    backdrop-filter: blur(var(--login-brand-backdrop-blur));
    -webkit-backdrop-filter: blur(var(--login-brand-backdrop-blur)); /* Safari support */
    
    color: white;
    padding: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    /* Apply matching border-radius */
    border-top-left-radius: 14px;
    border-bottom-left-radius: 14px;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.4); /* Ensure text readability */
}


.logo {
    width: var(--logo-width);
    height: var(--logo-height);
    max-height: 65px;
    object-fit: contain;
    animation: fadeInDown 1s ease;
}

.brand-section h1 {
    font-size: 28px;
    margin-bottom: 10px;
    animation: fadeInUp 1s ease 0.2s both;
}

.brand-section p {
    font-size: 16px;
    opacity: 0.9;
    animation: fadeInUp 1s ease 0.4s both;
}

/* Form Container Styles */
.form-container {
    flex: 1.2; 
    padding: 50px 40px; 
    position: relative;
    /* Remove solid background */
    /* background-color: var(--surface-color); */

    /* Glass Effect */
    background-color: rgba(255, 255, 255, 0.45); /* Semi-transparent white (adjust alpha for tint) */
    backdrop-filter: blur(var(--login-form-backdrop-blur));
    -webkit-backdrop-filter: blur(var(--login-form-backdrop-blur)); /* Safari support */
    
    overflow: hidden;
    /* Apply matching border-radius */
    border-top-right-radius: 14px;
    border-bottom-right-radius: 14px;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.form-step {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 40px;
    opacity: 0;
    visibility: hidden;
    transform: translateX(30px);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.form-step.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

h2 {
    font-size: 24px;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.form-description {
    color: #777;
    margin-bottom: 30px;
}

/* Form Elements */
form {
    width: 100%;
}

.input-group {
    position: relative;
    margin-bottom: 25px;
}

.input-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
}

/* Modern professional phone input */
.phone-group {
    display: flex;
    align-items: center;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.phone-group:focus-within {
    border-color: rgba(146, 77, 13, 0.6);
    background: rgba(255, 255, 255, 0.25);
    box-shadow: 0 12px 40px rgba(146, 77, 13, 0.2);
    transform: translateY(-1px);
}

.country-code {
    padding: 18px 20px;
    font-family: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    font-weight: 600;
    font-size: 16px;
    color: #2c3e50;
    border-right: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
    letter-spacing: 0.5px;
}

.phone-group input[type="tel"] {
    border: none;
    flex-grow: 1;
    padding: 18px 20px;
    background: transparent;
    font-family: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #2c3e50;
    letter-spacing: 0.3px;
    /* Prevent iOS zoom on input focus */
    -webkit-appearance: none;
    -webkit-border-radius: 0;
    /* Improve mobile experience */
    touch-action: manipulation;
}

.phone-group input[type="tel"]::placeholder {
    color: rgba(44, 62, 80, 0.6);
    font-weight: 400;
}

/* Remove border/shadow from the input itself when inside the group */
.phone-group input[type="tel"]:focus {
    border: none;
    box-shadow: none;
    outline: none;
}


input[type="tel"],
input[type="text"] {
    width: 100%;
    padding: 15px; /* Adjusted padding */
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 6px;
    font-size: 16px;
    transition: var(--transition);
    background-color: rgba(255, 255, 255, 0.7);
    color: #333;
}

input[type="tel"]:focus,
input[type="text"]:focus {
    border-color: var(--primary-color);
    background-color: rgba(255, 255, 255, 0.85);
    box-shadow: 0 0 0 3px rgba(146, 77, 13, 0.15);
    outline: none;
}

/* OTP Input Styles */
.otp-inputs {
    display: flex;
    justify-content: space-between;
    margin-bottom: 25px;
}

.otp-input {
    width: 60px;
    height: 60px;
    text-align: center;
    font-size: 24px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 6px;
    margin: 0 5px;
    transition: var(--transition);
    background-color: rgba(255, 255, 255, 0.7);
    color: #333;
    /* Mobile improvements */
    -webkit-appearance: none;
    -webkit-border-radius: 6px;
    touch-action: manipulation;
    /* Prevent iOS zoom - use 16px minimum */
    font-size: 20px;
}

.otp-input:focus {
    border-color: var(--primary-color);
    background-color: rgba(255, 255, 255, 0.85);
    box-shadow: 0 0 0 3px rgba(146, 77, 13, 0.15);
    outline: none;
}

/* Button Styles */
.btn-primary {
    width: 100%;
    padding: 15px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    margin-bottom: 15px;
    /* Touch-friendly minimum size */
    min-height: 48px;
    /* Prevent zoom on iOS and improve touch experience */
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
    /* Improve tap target for accessibility */
    touch-action: manipulation;
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
}

/* Logo Size Utility Classes */
.logo-sm {
    --logo-width: 80px;
}

.logo-md {
    --logo-width: 120px;
}

.logo-lg {
    --logo-width: 160px;
}

.logo-xl {
    --logo-width: 200px;
}

.logo-login {
    --logo-width: 300px;
    max-height: 185px; /* Allow more height for login page */
}

/* Custom logo size using inline style */
/* Example: style="--logo-width: 150px;" */

.btn-secondary {
    width: 100%;
    padding: 15px;
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    border-radius: 6px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-secondary:hover {
    background-color: rgba(139, 90, 43, 0.1);
}

.resend-text {
    text-align: center;
    margin-bottom: 20px;
    font-size: 14px;
    color: #777;
}

.resend-text a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.resend-text a:hover {
    text-decoration: underline;
}

/* Animations */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Responsive Styles - More Aggressive Mobile Optimization */
@media (max-width: 768px) {
    /* Adjust body padding for mobile */
    body.login-page {
        padding: 5px;
        align-items: center;
        justify-content: center;
        min-height: 100vh;
    }
    
    .container {
        max-width: 100%;
        width: 100%;
        padding: 0;
    }
    
    .login-container {
        flex-direction: column;
        min-height: auto;
        max-width: 100%;
        width: 100%;
        margin: 0;
        border-radius: 12px;
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    }
    
    .brand-section {
        padding: 30px 20px 20px;
        text-align: center;
        min-height: auto;
    }
    
    .logo-container {
        margin-bottom: 15px;
    }
    
    .logo-login {
        max-width: 140px;
        height: auto;
    }
    
    .form-container {
        padding: 20px 25px 35px;
        width: 100%;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(15px);
    }
    
    .form-step {
        padding: 0;
        width: 100%;
    }
    
    .form-step h2 {
        font-size: 22px;
        margin-bottom: 12px;
        text-align: center;
        font-weight: 600;
        color: #2c3e50;
    }
    
    .form-description {
        font-size: 15px;
        text-align: center;
        margin-bottom: 30px;
        color: #5a6c7d;
        line-height: 1.4;
    }
    
    /* MUCH LARGER phone input for mobile */
    .phone-group {
        margin-bottom: 25px;
        min-height: 64px;
        border-radius: 12px;
        border: 2px solid rgba(146, 77, 13, 0.3);
        background: rgba(255, 255, 255, 0.9);
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    }
    
    .country-code {
        padding: 20px 22px;
        font-size: 18px;
        font-weight: 700;
        color: #2c3e50;
        min-width: 80px;
    }
    
    .phone-group input[type="tel"] {
        padding: 20px 22px;
        font-size: 18px;
        font-weight: 500;
        color: #2c3e50;
    }
    
    .phone-group input[type="tel"]::placeholder {
        font-size: 16px;
        color: rgba(44, 62, 80, 0.5);
    }
    
    /* LARGER OTP inputs for mobile */
    .otp-inputs {
        justify-content: center;
        gap: 12px;
        margin-bottom: 25px;
        flex-wrap: nowrap;
        padding: 0 10px;
    }
    
    .otp-input {
        width: 60px;
        height: 60px;
        font-size: 20px;
        font-weight: 700;
        margin: 0;
        border-radius: 12px;
        border: 2px solid rgba(146, 77, 13, 0.3);
        background: rgba(255, 255, 255, 0.95);
        color: #2c3e50;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }
    
    .otp-input:focus {
        border-color: var(--primary-color);
        background-color: rgba(255, 255, 255, 1);
        box-shadow: 0 0 0 4px rgba(146, 77, 13, 0.2);
        transform: scale(1.05);
    }
    
    /* LARGER buttons for mobile */
    .btn-primary {
        padding: 18px;
        font-size: 18px;
        font-weight: 600;
        border-radius: 12px;
        margin-bottom: 15px;
        min-height: 58px;
        box-shadow: 0 4px 16px rgba(146, 77, 13, 0.3);
        transition: all 0.3s ease;
    }
    
    .btn-primary:hover, .btn-primary:active {
        transform: translateY(-1px);
        box-shadow: 0 6px 20px rgba(146, 77, 13, 0.4);
    }
    
    .btn-secondary {
        padding: 16px;
        font-size: 16px;
        font-weight: 500;
        border-radius: 12px;
        min-height: 54px;
        border: 2px solid rgba(146, 77, 13, 0.3);
        background: rgba(255, 255, 255, 0.8);
        color: var(--primary-color);
    }
    
    /* Enhanced resend text styling for mobile */
    .resend-text {
        font-size: 15px;
        text-align: center;
        margin-bottom: 25px;
        line-height: 1.5;
    }
    
    .resend-text a {
        font-weight: 600;
        color: var(--primary-color);
        text-decoration: underline;
        padding: 8px;
        margin: -8px;
    }
}

/* Extra small screens (phones in portrait) - Even MORE aggressive */
@media (max-width: 480px) {
    body.login-page {
        padding: 3px;
        min-height: 100vh;
    }
    
    .login-container {
        border-radius: 8px;
        margin: 0;
        width: 100%;
    }
    
    .brand-section {
        padding: 25px 15px 15px;
    }
    
    .logo-login {
        max-width: 130px;
    }
    
    .form-container {
        padding: 15px 20px 30px;
    }
    
    .form-step h2 {
        font-size: 20px;
        margin-bottom: 10px;
    }
    
    .form-description {
        font-size: 14px;
        margin-bottom: 25px;
    }
    
    /* EVEN LARGER phone input for very small screens */
    .phone-group {
        min-height: 60px;
        border-radius: 10px;
        margin-bottom: 20px;
    }
    
    .country-code {
        padding: 18px 20px;
        font-size: 17px;
        font-weight: 700;
        min-width: 75px;
    }
    
    .phone-group input[type="tel"] {
        padding: 18px 20px;
        font-size: 17px;
        font-weight: 500;
    }
    
    .phone-group input[type="tel"]::placeholder {
        font-size: 15px;
    }
    
    /* LARGER OTP inputs for very small screens */
    .otp-inputs {
        gap: 10px;
        padding: 0 5px;
    }
    
    .otp-input {
        width: 55px;
        height: 55px;
        font-size: 18px;
        font-weight: 700;
        border-radius: 10px;
    }
    
    /* LARGER buttons for very small screens */
    .btn-primary {
        padding: 17px;
        font-size: 17px;
        min-height: 56px;
        font-weight: 600;
        border-radius: 10px;
    }
    
    .btn-secondary {
        padding: 15px;
        font-size: 15px;
        min-height: 52px;
        border-radius: 10px;
    }
    
    .resend-text {
        font-size: 14px;
        margin-bottom: 20px;
    }
    
    .resend-text a {
        padding: 10px;
        margin: -10px;
        font-size: 15px;
    }
}

/* Landscape orientation adjustments for mobile */
@media (max-width: 768px) and (orientation: landscape) {
    body.login-page {
        padding: 5px;
        align-items: center;
        justify-content: center;
    }
    
    .login-container {
        max-height: 90vh;
        overflow-y: auto;
    }
    
    .brand-section {
        padding: 15px 20px 10px;
    }
    
    .logo-login {
        max-width: 100px;
    }
    
    .form-container {
        padding: 15px 25px 25px;
    }
    
    .form-step {
        padding: 0;
    }
    
    .form-step h2 {
        font-size: 18px;
        margin-bottom: 8px;
    }
    
    .form-description {
        margin-bottom: 20px;
        font-size: 13px;
    }
    
    .phone-group {
        min-height: 56px;
        margin-bottom: 20px;
    }
    
    .country-code {
        padding: 16px 18px;
        font-size: 16px;
    }
    
    .phone-group input[type="tel"] {
        padding: 16px 18px;
        font-size: 16px;
    }
    
    .otp-input {
        width: 50px;
        height: 50px;
        font-size: 17px;
    }
    
    .btn-primary {
        padding: 15px;
        font-size: 16px;
        min-height: 52px;
    }
    
    .btn-secondary {
        padding: 13px;
        font-size: 14px;
        min-height: 48px;
    }
}

/* Very wide mobile screens (larger phones, small tablets) */
@media (min-width: 481px) and (max-width: 768px) {
    .phone-group {
        min-height: 68px;
    }
    
    .country-code {
        padding: 22px 24px;
        font-size: 19px;
        min-width: 85px;
    }
    
    .phone-group input[type="tel"] {
        padding: 22px 24px;
        font-size: 19px;
    }
    
    .phone-group input[type="tel"]::placeholder {
        font-size: 17px;
    }
    
    .otp-input {
        width: 65px;
        height: 65px;
        font-size: 22px;
    }
    
    .btn-primary {
        padding: 20px;
        font-size: 19px;
        min-height: 62px;
    }
    
    .btn-secondary {
        padding: 18px;
        font-size: 17px;
        min-height: 58px;
    }
    
    .form-step h2 {
        font-size: 24px;
    }
    
    .form-description {
        font-size: 16px;
    }
}

/* Footer Styles - Simplified in collections.css/species.css */
/* The background color, padding, etc. are set in page-specific CSS */

/* This container HOLDS the footer content and centers it */
.footer-container-new {
    max-width: 1200px; /* Example max-width, adjust as needed */
    margin-left: auto;
    margin-right: auto;
    padding: 0 40px; /* Ensure padding INSIDE the centered container */
    box-sizing: border-box;
    width: 100%; /* Take full width of the parent up to max-width */
}

/* Ensure these styles are not conflicting in page-specific CSS */
/* In species.css / collections.css, remove width/padding from .footer-container-new if present */

.footer-container-new h3 {
    color: #ffffff;
    font-size: 14px; 
    font-weight: 500;
    margin-bottom: 12px; 
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--primary-color);
    display: inline-block;
    padding-bottom: 4px;
}

.footer-container-new p {
    margin-bottom: 8px;
}

.footer-label {
    font-weight: 500;
    color: #ffffff;
    margin-right: 8px;
}

.copyright-text {
    margin-top: 15px; 
    padding-top: 12px;
    border-top: 1px solid #444;
    font-size: 11px; 
    color: #a0a0a0; 
    width: 100%; 
    text-align: center; /* Center copyright text */
}

/* Header base styles */
header {
    background-color: var(--header-bg-default, #ffffff); /* Default white */
    box-shadow: var(--shadow); /* Restore light shadow */
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    transition: none; /* Remove transition added for dark theme */
}

.header-container {
    display: flex;
    justify-content: space-between; /* Logo left, Nav right */
    align-items: center;
    padding: var(--header-padding);
    height: var(--header-height);
    width: 100%;
    box-sizing: border-box; /* Added box-sizing */
}


/* Navigation Link Styles */
nav ul {
    display: flex; /* CRITICAL: Makes items horizontal */
    flex-direction: row; /* Default, but explicit */
    list-style: none; /* Remove bullets */
    margin: 0;
    padding: 0;
    align-items: center; /* Vertically align items in the nav bar */
}

nav ul li {
    margin-left: 30px; /* Spacing between nav items */
}

/* Ensure the first item doesn't have left margin */
nav ul li:first-child {
    margin-left: 0;
}

nav ul li a {
    color: var(--text-color); /* Dark text for links */
    text-decoration: none;
    font-weight: 500;
    padding-bottom: 5px;
    position: relative;
    transition: color 0.3s ease; /* Add transition for color change */
}

/* Underline pseudo-element */
nav ul li a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color); /* Use primary color for underline */
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.3s ease;
}

/* Hover state */
nav ul li a:hover {
    color: var(--primary-color); /* Change text color on hover */
}

/* Underline animation on hover */
nav ul li a:hover::after {
    transform: scaleX(1);
}

footer {
    background-color: #1c1c1c; /* Consistent dark background */
    color: #e0e0e0; /* Light text color */
    width: 100%;
    padding: 30px 0; /* Adjusted padding */
    margin-top: auto; /* Push to bottom */
    position: relative;
    z-index: 10;
    font-size: 0.9rem; /* Base font size for footer */
}

.footer-container-new {
    max-width: 1200px; 
    margin-left: auto;
    margin-right: auto;
    padding: 0 40px; /* Horizontal padding within the container */
    box-sizing: border-box;
    width: 100%; 
    text-align: left; /* Ensure content aligns left */
}

/* Styles for elements within the footer container */
.footer-container-new h3 {
    font-size: 1.1rem;
    font-weight: 500;
    color: #ffffff;
    margin-bottom: 15px;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--primary-color); /* Keep accent border */
    display: inline-block;
    padding-bottom: 5px;
}

.footer-container-new p {
    margin-bottom: 10px;
    font-size: 0.85rem;
    color: #b0b0b0; /* Slightly adjusted grey */
    line-height: 1.6;
}

.footer-label {
    font-weight: 500;
    color: #d0d0d0; /* Slightly brighter label */
    margin-right: 8px;
}

.copyright-text {
    margin-top: 25px; 
    padding-top: 15px;
    border-top: 1px solid #444; /* Keep top border */
    font-size: 0.75rem; 
    color: #888; /* Copyright color */
    width: 100%; 
    text-align: center; /* Center copyright */
}

/* Updated Footer Styles */
.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    text-align: center;
    font-size: 0.85rem;
    color: #a0a0a0;
}

.footer-info span {
    margin: 0 10px;
}

.footer-copyright {
    margin-top: 10px;
    font-size: 0.75rem;
    color: #888;
}


/* Header base styles */
header {
    background-color: var(--header-bg-default, #ffffff); /* Default white */
    box-shadow: var(--shadow); /* Restore light shadow */
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    transition: none; /* Remove transition added for dark theme */
}

.header-container {
    display: flex;
    justify-content: space-between; /* Logo left, Nav right */
    align-items: center;
    padding: var(--header-padding);
    height: var(--header-height);
    width: 100%;
    box-sizing: border-box; /* Added box-sizing */
}


/* Navigation Link Styles */
nav ul {
    display: flex; /* CRITICAL: Makes items horizontal */
    flex-direction: row; /* Default, but explicit */
    list-style: none; /* Remove bullets */
    margin: 0;
    padding: 0;
    align-items: center; /* Vertically align items in the nav bar */
}

nav ul li {
    margin-left: 30px; /* Spacing between nav items */
}

/* Ensure the first item doesn't have left margin */
nav ul li:first-child {
    margin-left: 0;
}

nav ul li a {
    color: var(--text-color); /* Dark text for links */
    text-decoration: none;
    font-weight: 500;
    padding-bottom: 5px;
    position: relative;
    transition: color 0.3s ease; /* Add transition for color change */
}

/* Underline pseudo-element */
nav ul li a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color); /* Use primary color for underline */
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.3s ease;
}

/* Hover state */
nav ul li a:hover {
    color: var(--primary-color); /* Change text color on hover */
}

/* Underline animation on hover */
nav ul li a:hover::after {
    transform: scaleX(1);
}
