.kp-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 28px;
}

.kp-brand {
    font-size: 28px;
    font-weight: 800;
    color: #222;
    text-decoration: none;
    letter-spacing: -.03em;
}

.kp-nav {
    display: flex;
    gap: 22px;
    flex-wrap: wrap;
    align-items: center;
}

.kp-nav a {
    color: #4b4a47;
    text-decoration: none;
    font-weight: 700;
    font-size: 15px;
}

.kp-nav a:hover {
    text-decoration: underline;
}


/* Univerzální přihlášení / účet / odhlášení */

.auth-nav {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
}

.auth-nav a {
    color: #4b4a47;
    text-decoration: none;
    font-weight: 700;
    font-size: 15px;
}

.auth-nav a:hover {
    text-decoration: underline;
}


@media (max-width: 800px) {
    .kp-topbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .kp-nav {
        gap: 14px;
    }

    .auth-nav {
        gap: 14px;
    }
}

.auth-nav {
    display: flex;
    align-items: center;
    gap: 18px;
}

.auth-nav a {
    color: #555;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
}

.auth-nav a:hover {
    text-decoration: underline;
}


/* Samostatné auth menu na branded doméně */

/* Samostatné auth menu na branded doméně */

.page > .auth-nav {
    width: fit-content;
    margin-left: auto;
    margin-bottom: 12px;
    padding: 10px 16px;

    background: rgba(255, 255, 255, 0.88);
    border-radius: 14px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);

    justify-content: flex-end;
}


/* Auth menu vložené do hlavního Kapitelo menu */

.kp-nav .auth-nav {
    margin: 0;
    padding: 0;
    justify-content: flex-start;
}

.kp-nav-group {
    position: relative;
}

.kp-nav-group summary {
    cursor: pointer;
    list-style: none;

    color: #4b4a47;
    font-weight: 700;
    font-size: 15px;
}

.kp-nav-group summary::-webkit-details-marker {
    display: none;
}

.kp-nav-group summary::after {
    content: " ▾";
    font-size: 11px;
    opacity: 0.6;
}

.kp-nav-group[open] summary::after {
    content: " ▴";
}

.kp-nav-dropdown {
    position: absolute;
    z-index: 100;

    top: calc(100% + 10px);
    left: -16px;

    min-width: 240px;
    padding: 10px;

    background: #fff;
    border-radius: 14px;

    box-shadow:
        0 8px 30px rgba(0, 0, 0, 0.12);
}

.kp-nav-dropdown a {
    display: block;
    padding: 9px 12px;

    border-radius: 9px;
    white-space: nowrap;
}

.kp-nav-dropdown a:hover {
    background: rgba(0, 0, 0, 0.045);
    text-decoration: none;
}


.kp-nav-group {
    position: relative;
}

.kp-nav-group summary {
    cursor: pointer;
    list-style: none;

    display: inline-flex;
    align-items: center;
    gap: 6px;

    color: #4b4a47;
    font-weight: 700;
    font-size: 15px;

    padding: 0;
    border: 0;
    outline: none;
}

.kp-nav-group summary::-webkit-details-marker {
    display: none;
}

.kp-nav-group summary::after {
    content: "";
    width: 6px;
    height: 6px;

    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;

    transform: rotate(45deg) translateY(-2px);
    transform-origin: center;

    opacity: 0.55;
    transition: transform 0.15s ease;
}

.kp-nav-group[open] summary::after {
    transform: rotate(225deg) translateY(-1px);
}

.kp-nav-dropdown {
    position: absolute;
    z-index: 1000;

    top: calc(100% + 12px);
    left: 50%;

    min-width: 260px;

    padding: 8px;

    background: rgba(255, 255, 255, 0.98);

    border-radius: 18px;

    box-shadow:
        0 18px 45px rgba(0, 0, 0, 0.12),
        0 2px 8px rgba(0, 0, 0, 0.05);

    transform: translateX(-50%);
}

.kp-nav-dropdown::before {
    content: "";

    position: absolute;
    top: -6px;
    left: 50%;

    width: 12px;
    height: 12px;

    background: #fff;

    transform:
        translateX(-50%)
        rotate(45deg);

    border-radius: 3px;
}

.kp-nav-dropdown a {
    position: relative;
    z-index: 1;

    display: block;

    padding: 11px 14px;

    border-radius: 11px;

    color: #2f2f2d;
    font-size: 14px;
    font-weight: 700;

    text-decoration: none;

    white-space: nowrap;
}

.kp-nav-dropdown a:hover {
    background: #f3f0ea;
    text-decoration: none;
}

.kp-nav-dropdown a:first-child {
    font-size: 13px;
    font-weight: 600;
    opacity: 0.65;
}

.kp-nav-dropdown .kp-nav-overview {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    opacity: 0.55;
}

.auth-user-menu {
    position: relative;
}

.auth-user-menu > summary {
    display: flex;
    align-items: center;
    gap: 8px;

    list-style: none;
    cursor: pointer;

    color: #444;
    font-size: 14px;
    font-weight: 700;
}

.auth-user-menu > summary::-webkit-details-marker {
    display: none;
}

.auth-user-menu > summary::after {
    content: "";

    width: 6px;
    height: 6px;

    margin-left: 2px;

    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;

    transform: rotate(45deg) translateY(-2px);
    opacity: .55;
}

.auth-user-menu[open] > summary::after {
    transform: rotate(225deg);
}


.auth-user-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 28px;
    height: 28px;
    font-size: 12px;

    border-radius: 50%;

    background: #222;
    color: #fff;

    font-size: 13px;
    font-weight: 800;
}


.auth-user-dropdown {
    position: absolute;
    z-index: 1200;

    top: calc(100% + 12px);
    right: 0;

    min-width: 190px;
    padding: 6px;

    background: rgba(255,255,255,.98);
    border-radius: 16px;

    box-shadow:
        0 18px 45px rgba(0,0,0,.12),
        0 2px 8px rgba(0,0,0,.05);
}


.auth-user-dropdown a {
    display: block;

    padding: 9px 11px;
    font-size: 13px;

    border-radius: 10px;

    color: #333;
    text-decoration: none;

    font-size: 14px;
    font-weight: 700;
}

.auth-user-dropdown a:hover {
    background: #f3f0ea;
    text-decoration: none;
}


.auth-user-domain-info {
    padding: 8px 12px 6px;

    color: #999;

    font-size: 11px;
    font-weight: 800;
    letter-spacing: .05em;
    text-transform: uppercase;
}


.auth-user-divider {
    height: 1px;

    margin: 6px 4px;

    background: rgba(0,0,0,.08);
}


.auth-user-dropdown .auth-user-logout {
    color: #777;
}

.auth-user-menu > summary {
    display: flex;
    align-items: center;
    gap: 8px;

    padding: 4px 8px 4px 4px;

    border-radius: 999px;
    background: rgba(255,255,255,.72);

    list-style: none;
    cursor: pointer;

    border: 0;
    outline: 0;

    color: #444;
    font-size: 14px;
    font-weight: 700;
}

/* --------------------------------------------------
   Kapitelo header v3
   Utility úplně nahoře, hlavní menu níže a vycentrované
   -------------------------------------------------- */

.kp-site-header{
    margin-bottom:28px;
}

.kp-utility-row{
    min-height:24px;
    display:flex;
    justify-content:flex-end;
    align-items:center;
    margin:-8px 0 20px;
}

.kp-utility-nav{
    display:flex;
    align-items:center;
    justify-content:flex-end;
    gap:18px;
}

.kp-utility-nav .kp-nav-group summary,
.kp-utility-link{
    color:#66635f;
    font-size:13px;
    font-weight:750;
    text-decoration:none;
}

.kp-main-row{
    display:grid;
    grid-template-columns:220px minmax(0,1fr) 220px;
    align-items:center;
    gap:24px;
}

.kp-main-nav{
    justify-self:center;
    display:flex;
    align-items:center;
    justify-content:center;
    gap:30px;
    min-width:0;
}

.kp-main-nav > a,
.kp-main-nav > .kp-nav-group > summary{
    color:#403f3c;
    text-decoration:none;
    font-size:15px;
    font-weight:800;
    white-space:nowrap;
}

.kp-main-nav > a:hover{
    text-decoration:underline;
}

.kp-main-balance{
    width:220px;
}

.kp-nav-dropdown-right{
    left:auto;
    right:0;
    transform:none;
}

.kp-nav-dropdown-right::before{
    left:auto;
    right:18px;
    transform:rotate(45deg);
}

.kp-account-dropdown{
    min-width:210px;
}

.kp-account-dropdown a:first-child{
    font-size:14px;
    font-weight:700;
    opacity:1;
}

.kp-account-separator{
    height:1px;
    margin:6px 8px;
    background:rgba(0,0,0,.08);
}

.kp-explore-dropdown{
    min-width:280px;
}

.kp-explore-section + .kp-explore-section{
    margin-top:7px;
    padding-top:7px;
    border-top:1px solid rgba(0,0,0,.07);
}

.kp-explore-dropdown .kp-explore-heading{
    font-weight:850;
}

.kp-explore-section .kp-explore-heading ~ a{
    padding-left:22px;
    font-weight:600;
    opacity:.82;
}

.kp-explore-separator{
    height:1px;
    margin:7px 8px;
    background:rgba(0,0,0,.08);
}

@media (max-width:1050px){
    .kp-main-row{
        grid-template-columns:auto 1fr;
    }

    .kp-main-nav{
        justify-self:end;
        gap:20px;
        flex-wrap:wrap;
    }

    .kp-main-balance{
        display:none;
    }
}

@media (max-width:700px){
    .kp-utility-row{
        margin:0 0 14px;
    }

    .kp-utility-nav{
        width:100%;
        gap:12px;
        flex-wrap:wrap;
    }

    .kp-main-row{
        display:flex;
        flex-direction:column;
        align-items:flex-start;
        gap:14px;
    }

    .kp-main-nav{
        width:100%;
        justify-content:flex-start;
        gap:16px 20px;
        flex-wrap:wrap;
    }

    .kp-explore-dropdown{
        left:0;
        transform:none;
    }

    .kp-explore-dropdown::before{
        left:24px;
        transform:rotate(45deg);
    }
}

/* --------------------------------------------------
   Language / currency navigation details
   -------------------------------------------------- */

.kp-language-switch .kp-language-current {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
}

.kp-language-switch .kp-nav-dropdown {
    min-width: 190px;
}

.kp-language-switch .kp-nav-dropdown a {
    display: grid !important;
    grid-template-columns: 21px 1fr auto !important;
    align-items: center !important;
    gap: .55rem !important;
    white-space: nowrap;
}

.kp-language-switch svg.kp-lang-flag,
.kp-language-switch .kp-nav-dropdown svg.kp-lang-flag {
    display: inline-block !important;
    width: 21px !important;
    height: 14px !important;
    min-width: 21px !important;
    min-height: 14px !important;
    max-width: 21px !important;
    max-height: 14px !important;
    flex: 0 0 21px !important;
    border-radius: 2px;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, .14);
    vertical-align: -2px;
}

.kp-language-switch .kp-nav-dropdown small,
.kp-currency-switch .kp-nav-dropdown small {
    opacity: .55;
    font-size: .75em;
    letter-spacing: .04em;
}

.kp-currency-switch .kp-nav-dropdown {
    min-width: 115px;
}

.kp-currency-switch .kp-nav-dropdown a {
    display: grid !important;
    grid-template-columns: 1fr auto !important;
    gap: .7rem !important;
    align-items: center !important;
}

.kp-account-switch .kp-nav-dropdown {
    min-width: 165px;
}

/* Keep the preference bar above the centered primary navigation. */
.kp-site-header{margin-bottom:12px}
.kp-site-header .kp-utility-nav{align-items:center}
.kp-site-header .kp-utility-nav > .kp-nav-group,
.kp-site-header .kp-utility-nav > .kp-utility-link{display:flex;align-items:center}
.kp-site-header .kp-utility-nav .kp-nav-group summary{min-height:22px;line-height:22px;align-items:center}
.kp-site-header .kp-language-switch .kp-language-current{line-height:22px}
.kp-site-header .kp-language-switch svg.kp-lang-flag{vertical-align:middle}
