:root {
    --bg: #fafafa;
    --surface: #ffffff;
    --text: #1f2430;
    --muted: #555;
    --border: #e5e7ef;
    --accent: #667eea;
    --accent-2: #764ba2;
    --shadow: 0 2px 5px rgba(0,0,0,0.05);
    --card-shadow: 0 2px 5px rgba(0,0,0,0.1);
    --code-bg: #2d2d2d;
    --code-text: #f8f8f2;
    --header-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --nav-bg: #ffffff;
    --footer-bg: #333333;
    --footer-text: #ffffff;
    --link: #667eea;
    --link-hover: #4e5ad4;
    --pill-bg: #f4f4f4;
    --pill-border: #667eea;
    --switcher-bg: #ffffff;
    --switcher-border: #dddddd;
 }

[data-theme="dark"] {
    --bg: #0f1117;
    --surface: #161925;
    --text: #e7eaf3;
    --muted: #c3cad5;
    --border: #2a2f3c;
    --accent: #8fa2ff;
    --accent-2: #9b7bff;
    --shadow: 0 2px 8px rgba(0,0,0,0.35);
    --card-shadow: 0 2px 10px rgba(0,0,0,0.45);
    --code-bg: #0c0f17;
    --code-text: #e8ecf5;
    --header-gradient: linear-gradient(135deg, #2b3a67 0%, #513b7c 100%);
    --nav-bg: #141722;
    --footer-bg: #0d1018;
    --footer-text: #e7eaf3;
    --link: #9bb0ff;
    --link-hover: #c3d1ff;
    --pill-bg: #1f2533;
    --pill-border: #9bb0ff;
    --switcher-bg: #1b2130;
    --switcher-border: #2d3446;
 }

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}

header {
    background: var(--header-gradient);
    color: white;
    padding: 60px 20px;
    text-align: center;
}

header h1 {
    font-size: 3em;
    margin-bottom: 10px;
}

header p {
    font-size: 1.2em;
    opacity: 0.9;
}

nav {
    background: var(--nav-bg);
    padding: 15px;
    text-align: center;
    border-bottom: 2px solid var(--accent);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav a {
    margin: 0 20px;
    text-decoration: none;
    color: var(--text);
    font-weight: 500;
    display: inline-block;
}

nav a:hover {
    color: var(--accent);
    border-bottom: 2px solid var(--accent);
    padding-bottom: 5px;
}

nav a.active {
    color: var(--accent);
    border-bottom: 2px solid var(--accent);
    padding-bottom: 5px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

section {
    margin: 40px 0;
}

section h2 {
    color: var(--accent);
    margin-bottom: 20px;
    font-size: 2em;
    border-bottom: 2px solid var(--border);
    padding-bottom: 10px;
}

section h3 {
    color: var(--muted);
    margin-top: 25px;
    margin-bottom: 15px;
    font-size: 1.4em;
}

code {
    background: var(--pill-bg);
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
}

pre {
    background: var(--code-bg);
    color: var(--code-text);
    padding: 20px;
    border-radius: 5px;
    overflow-x: auto;
    margin: 20px 0;
    border-left: 4px solid var(--accent);
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.feature-card {
    background: var(--surface);
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid var(--accent);
    box-shadow: var(--card-shadow);
    transition: transform 0.3s, box-shadow 0.3s;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
}

.feature-card h3 {
    color: var(--accent);
    margin-bottom: 10px;
}

.button {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    text-decoration: none;
    margin: 10px 10px 10px 0;
    transition: background 0.3s;
}

.button:hover {
    background: var(--accent-2);
}

.button.secondary {
    background: var(--pill-bg);
    color: var(--text);
    border: 2px solid var(--pill-border);
}

.button.secondary:hover {
    background: var(--accent);
    color: white;
}

.button.aur {
    background: #1793d1;
}

.button.aur:hover {
    background: #0f5b8d;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background: var(--surface);
    border-radius: 5px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
}

th {
    background: var(--accent);
    color: var(--surface);
    padding: 15px;
    text-align: left;
}

td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--border);
}

tr:hover {
    background: var(--pill-bg);
}

footer {
    background: var(--footer-bg);
    color: var(--footer-text);
    text-align: center;
    padding: 30px 20px;
    margin-top: 60px;
}

footer p {
    margin: 5px 0;
}

footer a {
    color: var(--link);
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

.example-block {
    background: var(--surface);
    padding: 20px;
    border-radius: 5px;
    border-left: 4px solid var(--accent);
    margin: 20px 0;
    box-shadow: var(--card-shadow);
}

.breadcrumb {
    padding: 10px 0;
    margin-bottom: 20px;
    font-size: 0.9em;
    color: var(--muted);
}

.breadcrumb a {
    color: var(--link);
    text-decoration: none;
}

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

/* Language Switcher Styles */
.language-switcher {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    gap: 8px;
    z-index: 1000;
    background: var(--switcher-bg);
    padding: 8px;
    border-radius: 8px;
    box-shadow: var(--card-shadow);
    border: 1px solid var(--switcher-border);
}

.lang-btn {
    background: var(--surface);
    border: 1px solid var(--switcher-border);
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.85em;
    font-weight: 500;
    color: var(--text);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 4px;
}

.lang-btn:hover {
    background: var(--pill-bg);
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.lang-btn.active {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
    color: white;
    border-color: var(--accent);
    font-weight: 600;
}

.lang-btn.active:hover {
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

/* Mobile responsive for language switcher */
@media (max-width: 768px) {
    .language-switcher {
        top: auto;
        right: auto;
        bottom: 20px;
        left: 20px;
        flex-wrap: wrap;
        max-width: calc(100vw - 40px);
    }

    .lang-btn {
        font-size: 0.8em;
        padding: 6px 10px;
    }
}

/* Theme toggle control */
.theme-toggle {
    position: fixed;
    top: 76px;
    right: 20px;
    z-index: 1000;
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--switcher-border);
    border-radius: 8px;
    padding: 10px 14px;
    cursor: pointer;
    font-weight: 600;
    box-shadow: var(--card-shadow);
    transition: all 0.25s ease;
}

.theme-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.35);
    border-color: var(--accent);
    color: var(--accent);
}

@media (max-width: 768px) {
    .theme-toggle {
        top: auto;
        right: auto;
        bottom: 80px;
        left: 20px;
    }
}

/* SEO and Accessibility Improvements */
[data-i18n],
[data-i18n-html] {
    /* Ensure proper display of translated content */
    display: inline;
}

h1[data-i18n],
h2[data-i18n],
h3[data-i18n],
h4[data-i18n],
h5[data-i18n],
h6[data-i18n] {
    display: block;
}

p[data-i18n],
span[data-i18n] {
    display: inline;
}

section[data-i18n],
div[data-i18n] {
    display: block;
}

/* Screen reader only content for SEO */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border-width: 0;
}

/* Skip to main content link (SEO + Accessibility) */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: #667eea;
    color: white;
    padding: 8px;
    text-decoration: none;
    z-index: 100;
    border-radius: 0 0 5px 0;
}

.skip-link:focus {
    top: 0;
}

