/* ================================
   BASE STYLES & VARIABLES
   ================================ */

:root {
    --primary-header-bg: #2F394D;
    --header-height: 80px;
    --max-width: 1216px;
    --transition-normal: 0.3s ease;
    --text-light: #FFFFFF;
    --font-primary: 'Montserrat', sans-serif;
    --font-weight-semibold: 600;
    --primary-brand-accent: #FFD36E;
    --space-lg: 48px;
    --space-md: 32px;
    --space-sm: 16px;
}

/* Apply border-box globally */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* ================================
   TYPOGRAPHY & COLORS
   ================================ */
html,
body {
    margin: 0;
    font-family: 'Source Sans Pro', sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    color: #2F394D;
    background-color: #F7F7F7;
    transition: opacity 0.3s ease;
    overflow-x: hidden;
    width: 100%;
    max-width: 100vw;
}

h1, h2, h3, h4, h5, h6 {
    margin: 0;
    padding: 0;
    font-weight: 700;
    color: #2F394D;
}

p {
    margin: 0;
    padding: 0;
    margin-bottom: var(--space-md);
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition-normal);
}

a:hover {
    color: var(--primary-brand-accent);
}

/* ================================
   UTILITY CLASSES
   ================================ */
.u-margin-bottom {
    margin-bottom: var(--space-md) !important;
}

.u-text-center {
    text-align: center !important;
}

.u-flex {
    display: flex !important;
}

.u-flex-column {
    flex-direction: column !important;
}

.u-align-center {
    align-items: center !important;
}

.u-justify-center {
    justify-content: center !important;
}

.u-hidden {
    display: none !important;
}

/* ================================
   COMPONENT STYLES
   ================================ */

/* Buttons */
.cta-button, .cta-btn {
    display: inline-block;
    padding: 14px 32px;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 16px;
    line-height: 1.5;
    text-align: center;
    color: #2F394D;
    background-color: #FFD36E;
    border: none;
    border-radius: 40px;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.cta-button:hover, .cta-btn:hover {
    background-color: #ffca45;
}

.cta-button:active, .cta-btn:active {
    transform: scale(0.98);
}

/* Form elements */
input, textarea, select, button {
    font-family: 'Source Sans Pro', sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: #2F394D;
    border: 1px solid #CCCCCC;
    border-radius: 4px;
    padding: 10px;
    margin-bottom: var(--space-md);
    width: 100%;
    box-sizing: border-box;
}

input:focus, textarea:focus, select:focus, button:focus {
    outline: none;
    border-color: var(--primary-brand-accent);
}

/* Cards */
.card {
    background-color: #FFFFFF;
    border: 1px solid #CCCCCC;
    border-radius: 8px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
    padding: 24px;
    margin-bottom: var(--space-lg);
}

.card-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 20px;
    margin-bottom: 16px;
}

.card-description {
    font-family: 'Source Sans Pro', sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.5;
    color: #2F394D;
}

/* ================================
   ANIMATIONS
   ================================ */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* ================================
   DARK MODE SUPPORT
   ================================ */
@media (prefers-color-scheme: dark) {
    :root {
        --primary-header-bg: #1E1E2E;
        --text-light: #FFFFFF;
        --font-primary: 'Montserrat', sans-serif;
        --font-weight-semibold: 600;
        --primary-brand-accent: #FFD36E;
    }
    
    body {
        background-color: #121212;
        color: #E0E0E0;
    }
    
    .header {
        background-color: var(--primary-header-bg);
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .card {
        background-color: #1E1E2E;
        border: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    input, textarea, select, button {
        background-color: #2C2C3E;
        color: #E0E0E0;
        border: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    a {
        color: #FFD36E;
    }
    
    a:hover {
        color: #ffca45;
    }
}

/* ================================
   PRINT STYLES
   ================================ */
@media print {
    body {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .header, .footer {
        display: none;
    }
    
    .main-content {
        padding: 0;
    }
    
    .card {
        page-break-inside: avoid;
    }
}