.nav-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
}

.theme-toggle {
    display: inline-grid;
    place-items: center;
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    border: 1px solid #94a3b8;
    border-radius: 999px;
    color: #1d4ed8;
    background: #fff;
    font: inherit;
    cursor: pointer;
}

.theme-toggle[hidden] {
    display: none;
}

.theme-toggle:hover {
    background: #eff6ff;
}

.warning {
    padding: 0.75rem 1rem;
    border-left: 0.25rem solid #b45309;
    border-radius: 0.5rem;
    color: #334155;
    background: #fffbeb;
}

:root[data-theme="dark"] {
    color-scheme: dark;
    color: #f1f1f1;
    background: #0e0e10;
}

[data-theme="dark"] body {
    background: radial-gradient(circle at top left, #161618, #0e0e10);
}

[data-theme="dark"] .shell,
[data-theme="dark"] .panel {
    border-color: #444;
    background: linear-gradient(135deg, #1c1c1c, #171717);
    box-shadow: 0 0.4rem 1.2rem rgba(0, 0, 0, 0.6);
}

[data-theme="dark"] .product,
[data-theme="dark"] .card {
    border-color: #454545;
    background: #232323;
}

[data-theme="dark"] .feature,
[data-theme="dark"] .support {
    border-color: #555;
    background: #2b2b2b;
}

[data-theme="dark"] p,
[data-theme="dark"] figcaption,
[data-theme="dark"] .caption,
[data-theme="dark"] .language-links [aria-current] {
    color: #ddd;
}

[data-theme="dark"] a,
[data-theme="dark"] .lead {
    color: #a9c8ff;
}

[data-theme="dark"] .badge {
    border-color: #4b5258;
    color: #e0e5e9;
    background: #292e32;
}

[data-theme="dark"] .button {
    border-color: #687480;
    color: #fff;
    background: #292f38;
}

[data-theme="dark"] .button:hover {
    background: #343d47;
}

[data-theme="dark"] .button.secondary,
[data-theme="dark"] .theme-toggle {
    border-color: #9da8b4;
    color: #e8edf2;
    background: #30363c;
}

[data-theme="dark"] .button.secondary:hover,
[data-theme="dark"] .theme-toggle:hover {
    background: #414b56;
}

[data-theme="dark"] .warning,
[data-theme="dark"] .notice {
    border-color: #fbbf24;
    color: #fef3c7;
    background: #4a3618;
}

[data-theme="dark"] :focus-visible {
    outline-color: #f8fafc;
}

[data-theme="dark"] .preview-dialog {
    border-color: #555;
    color: #f1f1f1;
    background: #1c1c1c;
}
