/*
 * Shared header visual parity.
 *
 * The homepage owns the canonical header palette. These rules keep that
 * palette consistent across the storefront while preserving each template's
 * existing header dimensions and responsive layout.
 */

:root {
    --km-header-color-primary: #0284c7;
    --km-header-color-primary-hover: #0369a1;
    --km-header-color-action: #0369a1;
    --km-header-color-action-hover: #075985;
    --km-header-color-primary-subtle: #f0f9ff;
    --km-header-color-surface: #ffffff;
    --km-header-color-text: #131a33;
    --km-header-color-text-muted: #64748b;
    --km-header-color-border: #e2e8f0;
}

.site-header {
    border-bottom-color: rgba(226, 232, 240, .82);
    background: rgba(255, 255, 255, .92);
    box-shadow: 0 1px 0 rgba(15, 23, 42, .02);
    backdrop-filter: blur(18px);
}

.site-header.is-scrolled {
    box-shadow: 0 12px 34px rgba(15, 23, 42, .06);
}

.brand-mark,
.brand-mark:hover {
    color: var(--km-header-color-text);
}

.brand-mark__icon {
    color: var(--km-header-color-surface);
    background: var(--km-header-color-primary);
    box-shadow: 0 8px 18px rgba(2, 132, 199, .18);
}

.primary-navigation a,
.header-link,
.header-register-link {
    color: var(--km-header-color-text-muted);
}

.primary-navigation a:hover,
.header-link:hover,
.header-register-link:hover {
    color: var(--km-header-color-primary-hover);
}

.header-register-link,
.header-register-link:hover {
    border-color: transparent;
    color: var(--km-header-color-text-muted);
    background: transparent;
    transform: none;
}

.header-register-link:hover {
    color: var(--km-header-color-primary-hover);
}

.cart-link {
    border-color: var(--km-header-color-border);
    color: var(--km-header-color-text);
    background: var(--km-header-color-surface);
}

.cart-count {
    background: var(--km-header-color-action);
}

.header-actions .km-home-button--secondary,
.primary-navigation .km-navigation-actions .km-home-button--secondary {
    border-color: var(--km-header-color-border);
    color: var(--km-header-color-text);
    background: var(--km-header-color-surface);
}

.header-actions .km-home-button--secondary:hover,
.primary-navigation .km-navigation-actions .km-home-button--secondary:hover {
    border-color: rgba(2, 132, 199, .4);
    color: var(--km-header-color-primary-hover);
    background: var(--km-header-color-primary-subtle);
}

.header-actions .km-home-button--primary,
.primary-navigation .km-navigation-actions .km-home-button--primary {
    border-color: var(--km-header-color-action);
    color: var(--km-header-color-surface);
    background: var(--km-header-color-action);
    box-shadow: 0 10px 28px rgba(2, 132, 199, .22);
}

.header-actions .km-home-button--primary:hover,
.primary-navigation .km-navigation-actions .km-home-button--primary:hover {
    border-color: var(--km-header-color-action-hover);
    color: var(--km-header-color-surface);
    background: var(--km-header-color-action-hover);
}

.menu-toggle > span:not(.screen-reader-text) {
    background: var(--km-header-color-text);
}

/* Match the established inner-page primary-menu size on the homepage. */
body.kimora-home .primary-navigation a {
    font-size: .94rem;
}

@media (min-width: 1025px) {
    body.kimora-home .header-inner {
        width: min(calc(100% - 40px), var(--km-container));
        grid-template-columns: auto 1fr auto;
        gap: 28px;
    }

    body.kimora-home .brand-mark {
        gap: 10px;
        font-family: Manrope, sans-serif;
        font-size: 1.1rem;
        font-weight: 800;
        letter-spacing: normal;
    }

    body.kimora-home .brand-mark__icon {
        width: 38px;
        height: 38px;
        border-radius: 11px;
    }

    body.kimora-home .primary-navigation ul {
        gap: 28px;
    }

    body.kimora-home .primary-navigation a {
        font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
        font-weight: 600;
    }

    body.kimora-home .header-actions {
        gap: 16px;
    }

    body.kimora-home .km-header-commerce {
        gap: 10px;
    }

    body.kimora-home .account-links {
        gap: 7px;
    }

    body.kimora-home .header-link {
        font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
        font-size: .92rem;
        font-weight: 600;
    }

    body.kimora-home .header-register-link {
        min-height: 38px;
        padding-inline: 14px;
        border-radius: 10px;
        font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
        font-size: .88rem;
        font-weight: 700;
    }

    body.kimora-home .cart-link {
        width: 42px;
        height: 42px;
        border-radius: 12px;
    }

    body.kimora-home .header-actions .km-home-button {
        min-height: 42px;
        padding-inline: 16px;
        font-size: .82rem;
    }

    body.kimora-home .header-actions .km-header-primary {
        padding-inline: 16px !important;
    }
}

/* #0187.8 — keep every interactive header target comfortably operable. */
.brand-mark,
.primary-navigation a,
.header-link,
.header-register-link,
.header-actions .km-home-button,
.primary-navigation .km-navigation-actions .km-home-button {
    min-height: 44px;
}

.brand-mark {
    min-width: 44px;
}

.primary-navigation a,
.header-link,
.header-register-link {
    min-width: 44px;
    justify-content: center;
}

.cart-link {
    width: 44px;
    height: 44px;
}

.menu-toggle {
    min-width: 44px;
    min-height: 44px;
}

.km-site-footer a {
    display: inline-flex;
    min-width: 44px;
    min-height: 44px;
    align-items: center;
}

/* Footer hotfix — compact navigation, trust marks and social links. */
.km-site-footer .km-site-footer__inner {
    padding-bottom: 0;
}

.km-site-footer .km-site-footer__nav ul {
    gap: .375rem;
}

.km-site-footer .km-site-footer__nav a {
    min-width: 24px;
    min-height: 24px;
}

.km-site-footer__brand-copy {
    display: grid;
    max-width: 34rem;
    justify-items: end;
    gap: .75rem;
}

.km-site-footer__brand-copy > p {
    margin: 0;
    color: #94a3b8;
    font-size: .875rem;
    text-align: right;
}

.km-site-footer__socials {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: .5rem;
}

.km-site-footer .km-site-footer__socials a {
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(148, 163, 184, .22);
    border-radius: .625rem;
    color: #94a3b8;
    background: rgba(255, 255, 255, .035);
    transition: border-color .2s ease, color .2s ease, background-color .2s ease;
}

.km-site-footer .km-site-footer__socials a:hover {
    border-color: rgba(56, 189, 248, .55);
    color: #f8fafc;
    background: rgba(56, 189, 248, .1);
}

.km-site-footer__socials svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.km-site-footer__assurance {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 2rem;
    margin-top: 2.75rem;
    padding-block: 1.5rem;
    border-top: 1px solid rgba(148, 163, 184, .16);
}

.km-site-footer__trust-badges,
.km-site-footer__payment-methods,
.km-site-footer__payment-methods ul {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.km-site-footer__trust-badges {
    gap: .75rem;
}

.km-site-footer__trust-badge {
    display: inline-flex;
    min-height: 32px;
    align-items: center;
    gap: .5rem;
    padding: .375rem .75rem;
    border: 1px solid rgba(148, 163, 184, .2);
    border-radius: .5rem;
    color: #cbd5e1;
    background: rgba(255, 255, 255, .035);
    font-size: .6875rem;
    line-height: 1;
}

.km-site-footer__trust-icon {
    width: 15px;
    height: 15px;
    color: #38bdf8;
}

.km-site-footer__trust-badge > span {
    width: 1px;
    height: .875rem;
    background: rgba(148, 163, 184, .28);
}

.km-site-footer__trust-badge small {
    color: #94a3b8;
    font-size: .625rem;
}

.km-site-footer__payment-methods {
    justify-content: flex-end;
    gap: .75rem;
}

.km-site-footer__payment-methods > span {
    color: #94a3b8;
    font-size: .6875rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.km-site-footer__payment-methods ul {
    gap: .5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.km-site-footer__payment-mark {
    display: inline-flex;
    min-width: 50px;
    height: 32px;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: .35rem .5rem;
    border: 1px solid rgba(148, 163, 184, .24);
    border-radius: .5rem;
    background: #f8fafc;
}

.km-site-footer__payment-mark img {
    display: block;
    width: auto;
    max-width: 52px;
    height: 18px;
    object-fit: contain;
}

.km-site-footer__payment-mark--paypal {
    min-width: 64px;
}

@media (max-width: 900px) {
    .km-site-footer__brand-copy {
        justify-items: start;
    }

    .km-site-footer__brand-copy > p {
        text-align: left;
    }

    .km-site-footer__socials,
    .km-site-footer__payment-methods {
        justify-content: flex-start;
    }
}

@media (max-width: 520px) {
    .km-site-footer__assurance {
        align-items: flex-start;
        margin-top: 2rem;
    }

    .km-site-footer__trust-badges,
    .km-site-footer__payment-methods {
        width: 100%;
    }

    .km-site-footer__payment-methods {
        display: grid;
        gap: .75rem;
    }
}

body :where(.gdpr-preferences, .gdpr-agreement) {
    min-height: 44px;
}

@media (max-width: 1024px) {
    /* The base selector loses to `.header-actions .km-home-button`. */
    .header-actions .km-header-demo {
        display: none;
    }
}
