:root {
    --bg-page: #0d1117;
    --bg-gradient: radial-gradient(120% 90% at 15% 0%, rgba(24, 24, 42, 0.9) 0%, rgba(18, 26, 48, 0.92) 45%, rgba(10, 22, 42, 0.94) 100%);
    --surface: rgba(255, 255, 255, 0.03);
    --surface-hover: rgba(255, 255, 255, 0.06);
    --surface-strong: rgba(255, 255, 255, 0.08);
    --border: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.16);
    --text: #ffffff;
    --text-dim: rgba(255, 255, 255, 0.65);
    --text-mute: rgba(255, 255, 255, 0.42);
    --accent: #b88e68;
    --accent-light: #d4a574;
    --accent-soft: rgba(184, 142, 104, 0.18);
    --danger: #ef4444;
    --shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
    --shadow-soft: 0 12px 30px rgba(0, 0, 0, 0.22);
    --blur: 16px;
    --radius-lg: 24px;
    --radius-md: 16px;
    --radius-sm: 10px;
    --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    --container: 1280px;
    --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
    --bg-photo: url("../assets/backgrounds/site-dark.jpg");
    --bg-photo-opacity: 0.62;
}

:root.light-theme,
body.light-theme {
    --bg-page: #e9eaee;
    --bg-gradient: radial-gradient(120% 90% at 15% 0%, rgba(244, 245, 247, 0.88) 0%, rgba(230, 231, 234, 0.9) 45%, rgba(216, 217, 221, 0.92) 100%);
    --surface: rgba(255, 255, 255, 0.55);
    --surface-hover: rgba(255, 255, 255, 0.75);
    --surface-strong: rgba(255, 255, 255, 0.9);
    --border: rgba(45, 55, 72, 0.12);
    --border-strong: rgba(45, 55, 72, 0.22);
    --text: #22262e;
    --text-dim: rgba(34, 38, 46, 0.68);
    --text-mute: rgba(34, 38, 46, 0.45);
    --accent: #8d6440;
    --accent-light: #a97b4f;
    --accent-soft: rgba(141, 100, 64, 0.16);
    --shadow: 0 24px 60px rgba(45, 55, 72, 0.18);
    --shadow-soft: 0 12px 30px rgba(45, 55, 72, 0.12);
    --bg-photo: url("../assets/backgrounds/site-light.jpg");
    --bg-photo-opacity: 0.5;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    background-color: var(--bg-page);
    transition: background-color 0.9s var(--ease);
    scrollbar-width: none;
    -ms-overflow-style: none;
}

html::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    -webkit-user-select: none;
    user-select: none;
    background-color: transparent;
    background-image: var(--bg-gradient);
    background-repeat: no-repeat;
    background-size: 100% 100%;
    -webkit-font-smoothing: antialiased;
    transition: background-color 0.9s var(--ease), color 0.9s var(--ease);
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background-image: var(--bg-photo);
    background-size: cover;
    background-position: center;
    opacity: var(--bg-photo-opacity);
    transition: opacity 0.8s var(--ease);
    pointer-events: none;
}

h1,
h2,
h3,
h4,
p,
figure,
blockquote {
    margin: 0;
}

h1,
h2,
h3,
h4 {
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: -0.02em;
}

a {
    color: inherit;
    text-decoration: none;
}

img,
svg {
    display: block;
    max-width: 100%;
    -webkit-user-drag: none;
    -webkit-user-select: none;
    user-select: none;
}

button {
    font: inherit;
    color: inherit;
    background: none;
    border: none;
    cursor: pointer;
}

html,
body,
a,
button,
summary,
label,
input,
textarea,
svg,
img {
    -webkit-tap-highlight-color: transparent;
}

a,
button,
summary,
label {
    -webkit-user-select: none;
    user-select: none;
}

:focus:not(:focus-visible) {
    outline: none;
}

:focus-visible {
    outline: 2px solid var(--accent-light);
    outline-offset: 3px;
    border-radius: 6px;
}

::selection {
    background: var(--accent-soft);
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
}

.skip-link {
    position: absolute;
    top: -60px;
    left: 24px;
    z-index: 100;
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    background: var(--accent);
    color: #fff;
    transition: top 0.3s var(--ease);
}

.skip-link:focus {
    top: 16px;
}