/* Dinastia.by Cookie Consent — isolated BEM layer over the existing Aspro theme. */
.cookie-consent {
    --cookie-accent: var(--theme-base-color, #23babf);
    --cookie-text: #333;
    --cookie-muted: #777;
    --cookie-border: #e7e7e7;
    color: var(--cookie-text);
    font-family: "Open Sans", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.65;
}

.cookie-consent [hidden] { display: none !important; }
.cookie-consent, .cookie-consent * { box-sizing: border-box; }

.cookie-consent__banner {
    position: fixed;
    bottom: 18px;
    left: 50%;
    z-index: 99990;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    width: calc(100% - 32px);
    max-width: 1130px;
    padding: 23px 28px;
    background: #fff;
    border: 1px solid var(--cookie-border);
    border-radius: 5px;
    box-shadow: 0 14px 48px rgba(23, 34, 42, .18);
    transform: translateX(-50%);
}

.cookie-consent__banner-copy { min-width: 0; max-width: 630px; }
.cookie-consent__title,
.cookie-consent__modal-title {
    margin: 0 0 10px;
    color: #333;
    font-family: "Roboto", Arial, sans-serif;
    font-weight: 600;
    line-height: 1.3;
}
.cookie-consent__title { font-size: 20px; }
.cookie-consent__description { margin: 0 0 10px; color: #666; }
.cookie-consent__link {
    color: var(--cookie-accent);
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
}
.cookie-consent__link:hover { color: #0c9ea6; text-decoration: underline; }
.cookie-consent__banner-actions,
.cookie-consent__modal-actions {
    justify-content: center;
    gap: 8px;
}
.cookie-consent__banner-actions { flex: 0 0 auto; }
.cookie-consent .cookie-consent__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 43px;
    padding: 10px 16px;
    margin: 0;
    border-radius: 4px;
    font-family: "Open Sans", Arial, sans-serif;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.3;
    text-transform: none;
    white-space: nowrap;
    transition: background-color .2s, color .2s, border-color .2s;
}
/* The primary button also keeps the site's existing .btn.btn-default class. */
.cookie-consent .cookie-consent__button--primary {
    background: var(--cookie-accent);
    border: 1px solid var(--cookie-accent);
    color: #fff;
}
.cookie-consent .cookie-consent__button--primary:hover {
    background: #0fa8ae;
    border-color: #0fa8ae;
    color: #fff;
}
.cookie-consent .cookie-consent__button--outline {
    background: #fff;
    border: 1px solid rgba(35, 186, 191, .55);
    color: var(--cookie-accent);
}
.cookie-consent .cookie-consent__button--outline:hover {
    background: rgba(35, 186, 191, .08);
    color: var(--cookie-accent);
}
.cookie-consent :is(button, a, input):focus-visible, .cookie-consent :is(button, a, input):focus {
    outline: 3px solid rgba(35, 186, 191, .48);
    outline-offset: 3px;
}

.cookie-consent__overlay {
    position: fixed;
    inset: 0;
    z-index: 100100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(17, 20, 23, .87);
}
.cookie-consent__modal {
    position: relative;
    width: 100%;
    max-width: 570px;
    max-height: min(90vh, 820px);
    padding: 38px 42px 34px;
    overflow-y: auto;
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 12px 35px rgba(0, 0, 0, .12);
}
.cookie-consent__close {
    position: absolute;
    top: 13px;
    right: 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 6px;
    background: transparent;
    border: 0;
    color: #777;
    cursor: pointer;
}
.cookie-consent__close:hover { color: #333; }
.cookie-consent__modal-title { padding-right: 14px; margin-bottom: 12px; font-size: 22px; }
.cookie-consent__modal-intro { margin: 0 0 22px; color: #777; }
.cookie-consent__categories { border-top: 1px solid var(--cookie-border); }
.cookie-consent__category {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 16px 0;
    border-bottom: 1px solid var(--cookie-border);
}
.cookie-consent__category-copy { display: flex; flex-direction: column; flex: 1 1 auto; min-width: 0; }
.cookie-consent__category-title { display: block; margin: 0 0 4px; font-size: 15px; font-weight: 600; line-height: 1.4; }
.cookie-consent__category-description { display: block; margin: 0; font-size: 13px; font-weight: 400; color: #777; line-height: 1.55; }
.cookie-consent__always-on { flex: 0 0 auto; font-size: 12px; color: #777; }
.cookie-consent__category--toggle { margin: 0; font-weight: normal; cursor: pointer; }
.cookie-consent__switch { position: relative; display: inline-flex; flex: 0 0 44px; width: 44px; height: 25px; }
.cookie-consent__switch-input { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.cookie-consent__switch-track { width: 44px; height: 25px; background: #c8cdd0; border-radius: 25px; transition: background-color .2s; }
.cookie-consent__switch-track::before { content: ""; position: absolute; top: 3px; left: 3px; width: 19px; height: 19px; background: #fff; border-radius: 50%; box-shadow: 0 1px 3px rgba(0,0,0,.18); transition: transform .2s; }
.cookie-consent__switch-input:checked + .cookie-consent__switch-track { background: var(--cookie-accent); }
.cookie-consent__switch-input:checked + .cookie-consent__switch-track::before { transform: translateX(19px); }
.cookie-consent__switch-input:focus-visible + .cookie-consent__switch-track { outline: 3px solid rgba(35, 186, 191, .48); outline-offset: 3px; }
.cookie-consent__policy-link { display: inline-block; margin: 18px 0 22px; font-size: 13px; }
.cookie-consent__modal-actions { justify-content: flex-start; }
body.cookie-consent--dialog-open { overflow: hidden; }
.cookie-consent__footer-link { padding: 0; border: 0; background: transparent; color: #999; font: inherit; font-size: 13px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.cookie-consent__footer-link:hover { color: var(--theme-base-color, #23babf); }
.cookie-consent__footer-link:focus-visible { outline: 3px solid rgba(35, 186, 191, .48); outline-offset: 3px; }

@media (max-width: 991px) {
    .cookie-consent__banner { align-items: flex-start; flex-direction: column; gap: 16px; max-width: 720px; }
    .cookie-consent__banner-actions { width: 100%; }
}
@media (max-width: 575px) {
    .cookie-consent__banner { bottom: 10px; width: calc(100% - 20px); padding: 18px; gap: 13px; }
    .cookie-consent__title { font-size: 19px; }
    .cookie-consent__description { font-size: 13px; line-height: 1.6; }
    .cookie-consent__banner-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
    .cookie-consent__banner-actions .cookie-consent__button--primary { grid-column: 1 / -1; grid-row: 1; }
    .cookie-consent .cookie-consent__button { min-width: 0; padding: 10px 12px; font-size: 13px; }
    .cookie-consent__overlay { padding: 12px; }
    .cookie-consent__modal { max-height: 95vh; padding: 32px 22px 24px; }
    .cookie-consent__modal-title { font-size: 20px; }
    .cookie-consent__always-on { max-width: 85px; text-align: right; line-height: 1.3; }
    .cookie-consent__modal-actions { display: grid; grid-template-columns: 1fr; }
    .cookie-consent__modal-actions .cookie-consent__button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .cookie-consent__switch-track, .cookie-consent__switch-track::before, .cookie-consent .cookie-consent__button { transition: none; }
}


/* Fixed cookie settings launcher */
.cookie-consent__launcher {
    position: fixed;
    bottom: 23px;
    left: 24px;
    z-index: 99;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 44px;
    height: 44px;
    padding: 0;

    border: 0;
    border-radius: 50%;

    background-color: #23babf;
    color: #fff;

    cursor: pointer;

    transition:
        background-color 0.3s ease,
        transform 0.3s ease;
}

.cookie-consent__launcher:hover {
    background-color: #0dbc91;
    transform: translateY(-2px);
}

.cookie-consent__launcher:focus-visible {
    outline: 2px solid #23babf;
    outline-offset: 3px;
}

.cookie-consent__launcher svg {
    display: block;
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

@media (max-width: 767px) {
    .cookie-consent__launcher {
        bottom: max(16px, env(safe-area-inset-bottom));
        left: 16px;
    }
}

body:has([data-cookie-banner]:not([hidden]))
.cookie-consent__launcher {
    display: none;
}

/* Keep floating buttons above the mobile bottom navigation */
@media (max-width: 991px) {
    body .cookie-consent__launcher,
    body .scroll-to-top {
        bottom: 72px !important;
    }
}