/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #0099ff;
    --primary-dark: #0077cc;
    --primary-blue: #0099ff; /* Legacy support */
    --secondary: #f8f9fa;
    --text-dark: #333333;
    --text-gray: #6c757d;
    --bg-light: #f8f9fa;
    --link-blue: #0099ff;
    --border-gray: #D7D8D9;
    --white: #ffffff;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --radius: 12px;
    --transition: all 0.3s ease;
    --max-width: 1200px;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--white);
    scroll-behavior: smooth;
}

/* Container */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    position: sticky;
    top: 0;
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    padding: 20px 0;
    z-index: 100;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    gap: 30px;
    list-style: none;
}

.nav-links a {
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-links a:hover {
    color: var(--primary);
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: var(--primary);
    transition: var(--transition);
}

.nav-links a:hover::after {
    width: 100%;
}

/* Language Switcher */
.lang-switcher {
    margin-left: 30px;
    position: relative;
}

.lang-switcher-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
    background-color: transparent;
    border: 1px solid transparent;
    border-radius: 999px;
    padding: 8px 14px;
    cursor: pointer;
    transition: var(--transition);
    line-height: 1;
}

.lang-switcher-trigger:hover {
    background-color: rgba(0, 153, 255, 0.08);
    color: var(--primary);
}

.lang-switcher-trigger:focus-visible {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0, 153, 255, 0.18);
}

.lang-switcher.is-open .lang-switcher-trigger {
    background-color: rgba(0, 153, 255, 0.08);
    color: var(--primary);
}

.lang-switcher-globe,
.lang-switcher-chevron {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.lang-switcher-globe svg {
    width: 18px;
    height: 18px;
}

.lang-switcher-chevron svg {
    width: 10px;
    height: 6px;
    transition: transform 0.2s ease;
}

.lang-switcher.is-open .lang-switcher-chevron svg {
    transform: rotate(180deg);
}

.lang-switcher-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 180px;
    margin: 0;
    padding: 8px;
    list-style: none;
    background-color: var(--white);
    border: 1px solid var(--border-gray);
    border-radius: var(--radius);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12), 0 2px 6px rgba(0, 0, 0, 0.05);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0.18s;
    z-index: 110;
}

.lang-switcher.is-open .lang-switcher-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s;
}

.lang-switcher-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 12px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.lang-switcher-item:hover,
.lang-switcher-item:focus {
    background-color: rgba(0, 153, 255, 0.08);
    color: var(--primary);
    outline: none;
}

.lang-switcher-item.is-current {
    color: var(--primary);
}

.lang-switcher-item-check svg {
    width: 14px;
    height: 14px;
    display: block;
}

/* Footer */
footer {
    background-color: var(--secondary);
    padding: 40px 0;
    text-align: center;
    margin-top: 60px;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.footer-links {
    display: flex;
    gap: 20px;
    list-style: none;
}

.footer-links a {
    color: var(--text-gray);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary);
}

.copyright {
    margin-top: 20px;
    color: var(--text-gray);
    font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        gap: 20px;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    header {
        padding: 15px 0;
    }

    nav {
        flex-direction: column;
        gap: 20px;
    }

    .nav-links {
        gap: 20px;
    }

    .lang-switcher {
        margin-left: 0;
    }
}