:root {
    color-scheme: light;
    --theme-primary: #ca9d66;
    --theme-primary-strong: #836642;
    --theme-primary-soft: #f9f3ed;
    --theme-primary-gradient-soft: linear-gradient(90deg, rgba(202, 157, 102, 0.14) 0%, rgba(202, 157, 102, 0.06) 100%);
    --theme-primary-gradient-strong: linear-gradient(90deg, rgba(202, 157, 102, 0.22) 0%, rgba(202, 157, 102, 0.1) 100%);

    --theme-bg: #f6f8fa;
    --theme-surface: #ffffff;
    --theme-surface-subtle: #f8fafc;
    --theme-border: #d0d7de;
    --theme-text: #1f2328;
    --theme-muted: #57606a;

    --theme-shadow: 0 1px 0 rgba(31, 35, 40, 0.04);
    --theme-shadow-elevated: 0 12px 28px rgba(31, 35, 40, 0.12), 0 2px 8px rgba(31, 35, 40, 0.06);
}

body.site-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: linear-gradient(180deg, #f6f8fa 0%, #f9fbfd 100%);
    color: var(--theme-text);
}

.container {
    max-width: 1200px;
}

.skip-link {
    position: absolute;
    left: 0.5rem;
    top: -3rem;
    z-index: 2000;
    background: var(--theme-surface);
    color: var(--theme-primary-strong);
    border: 2px solid var(--theme-primary-strong);
    border-radius: 0.25rem;
    padding: 0.5rem 0.75rem;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 0.5rem;
}

a {
    color: var(--theme-primary-strong);
}

a:hover {
    color: var(--theme-primary);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[role="button"]:focus-visible {
    outline: 3px solid var(--theme-primary);
    outline-offset: 2px;
}

main[tabindex="-1"]:focus {
    outline: none;
}

.site-header.navbar {
    min-height: 4.25rem;
    background: var(--theme-surface);
    border-bottom: 1px solid var(--theme-border);
    box-shadow: var(--theme-shadow);
    position: sticky;
    top: 0;
    z-index: 1020;
}

.header-title {
    font-size: clamp(1.05rem, 1.25vw + 0.9rem, 1.45rem);
    color: var(--theme-text);
}

.header-subtitle {
    color: var(--theme-primary-strong) !important;
    font-size: 0.9rem;
}

.site-header .nav-link {
    color: var(--theme-text) !important;
    border: 0 !important;
    box-shadow: none !important;
}

.site-header .nav-link:hover,
.site-header .nav-link:focus,
.site-header .nav-item.show > .nav-link {
    color: var(--theme-primary-strong) !important;
    background: var(--theme-primary-gradient-soft) !important;
}

.site-header .nav-link.active {
    color: var(--theme-primary-strong) !important;
    background: var(--theme-primary-gradient-strong) !important;
}

.site-header .dropdown-menu {
    min-width: 14rem;
    margin-top: 0.25rem;
    border: 1px solid var(--theme-border) !important;
    border-radius: 0.375rem;
    box-shadow: var(--theme-shadow-elevated);
    background: var(--theme-surface);
    backdrop-filter: blur(8px);
    padding: 0.4rem;
}

.site-header .dropdown-item {
    color: var(--theme-text);
}

.site-header .dropdown-item:hover,
.site-header .dropdown-item:focus {
    background: var(--theme-primary-gradient-soft);
    color: var(--theme-primary-strong);
}

.content {
    flex: 1;
    padding-top: 1rem;
}

.site-main {
    padding-top: 0.25rem;
    padding-bottom: 1rem;
}

.content .content-block,
.card,
.sidebar-nav,
.cookie-settings-container,
.cookie-consent-banner {
    border-radius: 0.25rem;
}

.content .content-block,
.card,
.sidebar-nav {
    border: 1px solid var(--theme-border);
    background: var(--theme-surface);
    box-shadow: var(--theme-shadow);
}

.content .content-block .list-group-item.list-group-item-action:hover,
.content .content-block .list-group-item.list-group-item-action:focus {
    background: var(--theme-primary-gradient-soft) !important;
    color: var(--theme-primary-strong) !important;
}

.content .content-block h1,
.content .content-block h2,
.content .content-block h3,
.content .content-block h4,
.content .content-block h5,
.content .content-block h6 {
    color: var(--theme-primary-strong);
}

.page-shell .page-header {
    border-bottom: 1px solid var(--theme-border);
    padding-bottom: 0.5rem;
    margin-bottom: 0.75rem;
}

.page-content-block {
    min-height: 22rem;
}

.site-footer {
    background: var(--theme-surface);
    border-top-color: var(--theme-border) !important;
}

.site-footer a {
    color: var(--theme-primary-strong);
}

.site-footer a:hover {
    color: var(--theme-primary);
}

.cookie-consent-banner .button-row {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.cookie-consent-banner .btn-link {
    text-decoration: underline;
}

#overlay .cookie-settings-container {
    width: min(95vw, 46rem);
    max-height: 85vh;
    overflow-y: auto;
    background: var(--theme-surface);
    border: 1px solid var(--theme-border);
    color: var(--theme-text);
}

.account-layout,
.administration-layout {
    padding-top: 1rem;
}

@media (max-width: 768px) {
    .site-main {
        padding-left: 0.25rem;
        padding-right: 0.25rem;
    }

    .site-header.navbar {
        min-height: 3.75rem;
    }

    .header-logo {
        max-width: 52px;
    }

    .header-text .header-subtitle {
        display: none;
    }

    .primary-nav.navbar-collapse {
        margin-top: 0.5rem;
        padding-top: 0.5rem;
        border-top: 1px solid var(--theme-border);
    }

    .site-header .dropdown-menu {
        margin-top: 0;
        border-radius: 0.25rem;
        box-shadow: none;
        background: var(--theme-surface-subtle);
        backdrop-filter: none;
    }

    .page-content-block {
        min-height: auto;
    }

    .site-footer {
        text-align: center;
    }
}

@media (min-width: 1024px) {
    .site-main {
        padding-top: 0.5rem;
    }

    .content {
        padding-top: 1.25rem;
    }

    .site-footer {
        padding-top: 1rem;
        padding-bottom: 1rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
