html.cookie-consent-dismissed .cookie-consent {
    display: none !important;
}

/* Десктоп (по умолчанию): плавающая карточка */
.cookie-consent {
    position: fixed;
    left: auto;
    top: auto;
    right: 50px;
    bottom: 50px;
    width: 390px;
    z-index: 1200;
    display: flex;
    flex-direction: column;
    pointer-events: auto;
    padding-bottom: 0;
    padding-right: env(safe-area-inset-right, 0px);
    padding-left: env(safe-area-inset-left, 0px);
}

.cookie-consent__panel {
    background-color: var(--background-white);
    border-radius: 30px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.05);
    padding: 24px;
}

.cookie-consent__body {
    display: flex;
    flex-direction: column;
}

.cookie-consent__title {
    margin: 0;
    font-family: var(--font-primary);
    font-size: 18px;
    font-weight: 600;
    line-height: 26px;
    letter-spacing: -0.2px;
    color: var(--text-black);
}

.cookie-consent__text {
    margin: 0;
    padding-top: 10px;
    padding-bottom: 24px;
    font-family: var(--font-primary);
    font-size: 14px;
    font-weight: 400;
    line-height: 24px;
    letter-spacing: -0.1px;
    color: var(--color-grey-dark);
}

.cookie-consent__link {
    color: var(--link-blue);
    text-decoration: none;
    font-weight: 400;
}

.cookie-consent__link:hover {
    text-decoration: underline;
}

.cookie-consent__btn {
    display: block;
    width: 100%;
    margin: 0;
    border: none;
    background-color: var(--background-black);
    color: var(--text-white);
    font-family: var(--font-primary);
    font-size: 16px;
    font-weight: 500;
    line-height: 20px;
    padding-block: 12px 14px;
    padding-inline: 20px;
    border-radius: 1000px;
    cursor: pointer;
    text-align: center;
    -webkit-tap-highlight-color: transparent;
}

.cookie-consent__btn:hover {
    opacity: 0.92;
}

.cookie-consent__btn:focus-visible {
    outline: 2px solid var(--link-blue);
    outline-offset: 2px;
}

.cookie-consent__safari {
    display: none;
    flex-shrink: 0;
    min-height: 60px;
    align-items: center;
    justify-content: center;
    padding: 10px 16px 18px;
    background: rgba(245, 245, 247, 0.88);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.cookie-consent__safari-inner {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    max-width: 100%;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 100px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

.cookie-consent__safari-lock {
    flex-shrink: 0;
    color: #6b7280;
}

.cookie-consent__safari-host {
    font-family: var(--font-primary);
    font-size: 13px;
    font-weight: 500;
    line-height: 18px;
    color: var(--text-black);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Планшет / узкий десктоп: чуть больший отступ от края */
@media (max-width: 1200px) and (min-width: 769px) {
    

    .cookie-consent {
        bottom: 30px;
        right: 30px;
        width: 300px;
    }
}

/* Мобилка: нижний лист + safari-bar */
@media (max-width: 768px) {

    .cookie-consent {
        left: 0;
        right: 0;
        bottom: 0;
        width: auto;
        max-width: none;
        padding-bottom: env(safe-area-inset-bottom, 0px);
        padding-right: 0;
        padding-left: 0;
    }

    .cookie-consent__panel {
        border-radius: 30px 30px 0 0;
        box-shadow: 0 0 10px rgba(0, 0, 0, 0.07);
        padding: 20px 24px 30px;
    }

    .cookie-consent__title {
        font-size: 16px;
    }

    .cookie-consent__text {
        line-height: 22px;
        padding-top: 10px;
        padding-bottom: 20px;
    }

    .cookie-consent__safari {
        display: flex;
    }
}
