/* Root Variables for Colors and Fonts */
:root {
    --primary-color: #004080;
    --accent-color: #ff6347;
    --background-gradient-start: #e0f7fa;
    --background-gradient-end: #f4f4f4;
    --text-color: #333333; /* Dark text color */
    --text-color-light: #777777; /* Lighter text color */
    --white: #ffffff;
    --black: #000000;
    --font-family-sans: 'Roboto', sans-serif;
    --font-family-serif: 'Lora', serif;
    --border-radius: 8px;
}

/* Dark Mode Variables */
@media (prefers-color-scheme: dark) {
    :root {
        --primary-color: #1f1f1f; /* Dark header and footer background */
        --accent-color: #ff6347;  /* Keep accent color the same */
        --background-gradient-start: #121212; /* Darker body background */
        --background-gradient-end: #1d1d1d;   /* Darker body background */
        /* Keep text colors the same */
        --white: #ffffff;
        --black: #000000;
    }

    /* Optional: Adjust Links in Header */
    header a {
        color: var(--white);
    }

    /* No need to override header text color here */
}

/* General Styles */
html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-family-sans);
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, var(--background-gradient-start), var(--background-gradient-end));
    color: var(--text-color); /* Dark text color */
    line-height: 1.6;
}

/* Container for the entire page */
.container {
    max-width: 62.5rem; /* 1000px / 16 */
    margin: 0 auto;
    padding: 1.25rem;
}

/* Header Styles */
header {
    background-color: var(--primary-color); /* Dark in dark mode */
    color: var(--white); /* Default text color */
    padding: 1.25rem;
    text-align: center;
}

header .header-content {
    text-align: center;
}

/* Header Text Styles */
header h1, header p {
    color: var(--white); /* Ensure header text is white */
}

header h1 {
    font-family: var(--font-family-serif);
    font-size: 2rem;
    margin: 0;
}

header p {
    font-size: 1rem;
    margin-top: 0.625rem;
}

header img {
    border-radius: 50%;
    width: 9.375rem;
    height: 9.375rem;
    object-fit: cover;
    margin-top: 0.9375rem;
    border: 0.3125rem solid var(--white);
}

/* Global Heading Styles */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family-serif);
    color: var(--primary-color); /* Dark in dark mode */
}

h2 {
    font-size: 1.5rem;
}

/* Global Paragraph Styles */
p {
    font-size: 1rem;
    color: var(--text-color); /* Dark text color */
}

/* Section Styles */
section {
    background-color: var(--white); /* White background */
    padding: 1.25rem;
    margin: 1.25rem 0;
    box-shadow: 0 0 0.625rem rgba(0, 0, 0, 0.1);
    border-radius: var(--border-radius);
}

h2 {
    border-bottom: 0.125rem solid var(--accent-color);
    padding-bottom: 0.625rem;
    margin-bottom: 1.25rem;
}

/* Simplified List Styles */
.section-list {
    list-style: none;
    padding: 0;
}

.section-list li {
    margin-bottom: 1.25rem;
}

.section-list li strong {
    font-size: 1.125rem;
    color: var(--primary-color); /* Dark in dark mode */
    display: block;
}

.section-list li em {
    display: block;
    margin-top: 0.3125rem;
    font-size: 0.875rem;
    color: var(--text-color-light); /* Lighter dark text */
}

/* Contact Section */
#contact {
    text-align: center;
}

#contact p {
    font-size: 1rem;
    margin-bottom: 0.625rem;
}

#contact a {
    font-size: 1.125rem;
    color: var(--primary-color); /* Dark in dark mode */
    text-decoration: none;
    transition: color 0.3s ease, text-decoration 0.3s ease;
}

#contact a:hover {
    text-decoration: underline;
    color: var(--accent-color);
}

/* Global Link Styles */
a {
    color: var(--primary-color); /* Dark in dark mode */
    text-decoration: none;
    transition: color 0.3s ease, text-decoration 0.3s ease;
}

a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

/* Footer */
footer {
    background-color: var(--primary-color);
    text-align: center;
    padding: 1.25rem 0;
    /* Remove color property here */
}

/* Footer Paragraph Styles */
footer p {
    color: var(--white); /* Ensure footer paragraph text is white */
}

/* Language Buttons */
.language-selection {
    margin-top: 1.25rem;
    text-align: center;
}

.language-selection p {
    font-size: 0.875rem;
    color: var(--white);
    margin-bottom: 0.625rem;
}

.flag-icon {
    width: 1.875rem;
    height: auto;
    border: none;
    background-color: transparent;
    cursor: pointer;
    margin: 0 0.3125rem;
    transition: transform 0.3s ease;
}

.flag-icon:hover {
    transform: scale(1.1);
}

.flag-icon.selected {
    border: 0.125rem solid var(--white);
}

.flag-icon:focus {
    border: 0.125rem solid var(--accent-color);
    outline: none;
}

/* Media Queries for Responsive Design */
@media (max-width: 48rem) {
    html {
        font-size: 15px;
    }

    header h1 {
        font-size: 1.5rem;
    }

    header img {
        width: 7.5rem;
        height: 7.5rem;
    }

    .container {
        padding: 0.9375rem;
    }

    section {
        padding: 0.9375rem;
        margin: 0.9375rem 0;
    }
}

