/*
 * "standard" theme — conventional navigation on top of the elegance look.
 * Loaded after the parent theme's CSS (includes/head-theme.php), so it only overrides what changes.
 */

:root {
    --site-accent: #f89d36;
    --site-text: #f5deb3;          /* wheat, the brand colour of elegance */
    --site-bar-bg: rgba(24, 24, 24, 0.96);
    --site-nav-height: 72px;
}

/* ---------------------------------------------------------------------------------------------------------------
 * Layout: elegance shifted containers/footer 50px left at desktop widths to make room for its vertical side bar.
 * The top navigation needs none of that.
 * ------------------------------------------------------------------------------------------------------------- */
body.theme-standard .container,
body.theme-standard .container-sm,
body.theme-standard .container-md,
body.theme-standard .container-lg,
body.theme-standard .container-xl,
body.theme-standard .container-xxl,
body.theme-standard .carousel-indicators,
body.theme-standard footer {
    transform: none;
}

body.theme-standard .container,
body.theme-standard .container-sm,
body.theme-standard .container-md,
body.theme-standard .container-lg,
body.theme-standard .container-xl,
body.theme-standard .container-xxl {
    padding-left: calc(var(--bs-gutter-x, 1.5rem) * 0.5);
    padding-right: calc(var(--bs-gutter-x, 1.5rem) * 0.5);
}

body.theme-standard .carousel-control-prev,
body.theme-standard .carousel-control-next {
    transform: none;
}

/* Slider logo and page loader (spinner.css): elegance moves them 50px left at >= 768px (the cube grid with !important),
 * to stay centred next to its side bar — centre them on the page again. The two logos overlap for the loading transition. */
body.theme-standard .carousel-brand,
body.theme-standard .carousel-brand-spinner {
    transform: translate(-50%, -70%);
}

body.theme-standard .sk-cube-grid {
    transform: translate(52%, -67%) !important;
}

body.theme-standard {
    background: #333;
}

/* ---------------------------------------------------------------------------------------------------------------
 * Top navigation bar
 * ------------------------------------------------------------------------------------------------------------- */
.site-navbar {
    min-height: var(--site-nav-height);
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    /* Transparent over the page header image, readable thanks to the gradient */
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0));
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.site-navbar.is-scrolled {
    background: var(--site-bar-bg);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

/* One row at every width: the brand shrinks, the actions (language, account, menu button) always stay visible */
.site-navbar > .container-xl {
    flex-wrap: nowrap;
}

.site-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    min-width: 0;
    color: var(--site-text);
    text-decoration: none;
}

/* Same golden (wheat) colour as the logo; .site-navbar raises specificity above Bootstrap's .navbar-dark .navbar-brand (#fff) */
.site-navbar .site-brand {
    color: var(--site-text);
}

.site-brand:hover,
.site-brand:focus,
.site-navbar .site-brand:hover,
.site-navbar .site-brand:focus {
    color: var(--site-accent);
}

.site-brand-logo {
    display: inline-flex;
    width: 44px;
    height: 44px;
}

.site-brand-logo svg {
    width: 100%;
    height: 100%;
}

.site-brand-logo .logo-path {
    fill: var(--site-text);
}

.site-brand:hover .logo-path {
    fill: var(--site-accent);
}

.site-brand-name {
    font-family: Comfortaa, Montserrat, sans-serif;
    font-size: 1.05rem;
    letter-spacing: 0.02em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.site-actions {
    flex-shrink: 0;
}

.site-brand-logo {
    flex-shrink: 0;
}

@media (max-width: 400px) {
    .site-brand-name {
        font-size: 0.9rem;
    }
}

.site-menu .nav-link {
    color: var(--site-text);
    padding: 0.5rem 0.9rem;
    font-size: 0.95rem;
    border-bottom: 2px solid transparent;
}

.site-menu .nav-link:hover,
.site-menu .nav-link:focus,
.site-menu .nav-link.active,
.site-menu .show > .nav-link {
    color: #fff;
    border-bottom-color: var(--site-accent);
}

.site-dropdown {
    background: var(--site-bar-bg);
    border: 1px solid rgba(245, 222, 179, 0.15);
    border-top: 2px solid var(--site-accent);
    border-radius: 0 0 0.35rem 0.35rem;
    min-width: 14rem;
}

.site-dropdown .dropdown-item {
    color: var(--site-text);
    padding: 0.5rem 1rem;
    white-space: normal;
}

.site-dropdown .dropdown-item:hover,
.site-dropdown .dropdown-item:focus,
.site-dropdown .dropdown-item.active {
    background: rgba(248, 157, 54, 0.15);
    color: #fff;
}

.site-actions {
    gap: 0.25rem;
}

.site-action,
.site-action.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--site-text);
    text-decoration: none;
    font-size: 0.9rem;
    padding: 0.5rem 0.6rem;
    border: 0;
    border-radius: 0.35rem;
    box-shadow: none;
}

.site-action:hover,
.site-action:focus {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

.site-action img {
    border-radius: 2px;
}

.site-burger {
    font-size: 1.35rem;
}

/* Keyboard focus must stay visible on the dark bar */
.site-navbar a:focus-visible,
.site-navbar button:focus-visible,
.site-offcanvas a:focus-visible,
.site-offcanvas button:focus-visible {
    outline: 2px solid var(--site-accent);
    outline-offset: 2px;
    box-shadow: none;
}

.site-skip-link {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    z-index: 1100;
    padding: 0.5rem 1rem;
    background: var(--site-accent);
    color: #1a1a1a;
    font-weight: 600;
    border-radius: 0.35rem;
}

/* ---------------------------------------------------------------------------------------------------------------
 * Mobile off-canvas menu
 * ------------------------------------------------------------------------------------------------------------- */
.site-offcanvas {
    background: #1f1f1f;
    color: var(--site-text);
    width: min(320px, 85vw);
}

.site-offcanvas .offcanvas-header {
    border-bottom: 1px solid rgba(245, 222, 179, 0.15);
}

.site-side-menu {
    margin: 0;
}

.site-side-menu > li {
    border-bottom: 1px solid rgba(245, 222, 179, 0.08);
}

.site-side-menu a,
.site-side-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0.8rem 0.25rem;
    color: var(--site-text);
    text-decoration: none;
    background: none;
    border: 0;
    text-align: left;
    font-size: 1rem;
}

.site-side-menu a:hover,
.site-side-toggle:hover,
.site-side-menu a[aria-current="page"] {
    color: #fff;
}

.site-side-menu a[aria-current="page"] {
    border-left: 3px solid var(--site-accent);
    padding-left: 0.6rem;
}

.site-side-toggle .fa-chevron-down {
    font-size: 0.8rem;
    transition: transform 0.2s ease;
}

.site-side-toggle:not(.collapsed) .fa-chevron-down {
    transform: rotate(180deg);
}

.site-side-sub {
    padding-left: 1rem;
    margin-bottom: 0.5rem;
}

.site-side-sub a {
    padding: 0.55rem 0.25rem;
    font-size: 0.95rem;
    opacity: 0.9;
}

.site-side-account {
    margin-top: 1.5rem;
}

.site-side-heading {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    opacity: 0.7;
    margin-bottom: 0.25rem;
}

.site-side-account a,
.site-side-lang {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0.25rem;
    color: var(--site-text);
    text-decoration: none;
}

.site-side-lang {
    margin-top: 1rem;
    border-top: 1px solid rgba(245, 222, 179, 0.15);
    padding-top: 1rem;
}

.site-side-account a:hover,
.site-side-lang:hover {
    color: #fff;
}

/* Readable secondary text in content cards (Bootstrap's .text-muted is below WCAG AA on the light card background) */
body.theme-standard .card .text-muted {
    color: #555 !important;
}

/* ---------------------------------------------------------------------------------------------------------------
 * Page header images: leave room for the fixed bar
 * ------------------------------------------------------------------------------------------------------------- */
body.theme-standard .masthead .container {
    margin-top: calc(var(--site-nav-height) + 1rem) !important;
}

@media (prefers-reduced-motion: reduce) {
    .site-navbar,
    .site-side-toggle .fa-chevron-down {
        transition: none;
    }
}
