:root {
    --gm-primary:#E23E4D;
    --gm-secondary:#25A9E0;
    --gm-navy:#111A5A;
    --gm-surface:#FFFDFC;
    --gm-text:#202124;
}

html.gmcm-lock,
html.gmcm-lock body {
    overflow: hidden !important;
}


.gmcm-root [hidden] {
    display: none !important;
}

.gmcm-root,
.gmcm-root * {
    box-sizing: border-box;
}

.gmcm-backdrop {
    position: fixed;
    inset: 0;
    z-index: 2147483000;
    background: rgba(8, 18, 55, .56);
    backdrop-filter: blur(2px);
    opacity: 0;
    transition: opacity .18s ease;
}

.gmcm-backdrop.is-visible {
    opacity: 1;
}

.gmcm-modal {
    position: fixed;
    z-index: 2147483001;
    left: 50%;
    top: 50%;
    width: min(560px, calc(100vw - 28px));
    max-height: min(780px, calc(100vh - 28px));
    overflow: auto;
    transform: translate(-50%, -48%) scale(.985);
    opacity: 0;
    padding: 28px;
    border-radius: 22px;
    border-top: 4px solid var(--gm-primary);
    background: var(--gm-surface);
    color: var(--gm-text);
    box-shadow: 0 28px 80px rgba(10, 22, 70, .28);
    font-family: inherit;
    transition: opacity .18s ease, transform .18s ease;
}

.gmcm-modal.is-visible {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.gmcm-position-bottom .gmcm-modal {
    top: auto;
    bottom: 20px;
    transform: translate(-50%, 18px);
}

.gmcm-position-bottom .gmcm-modal.is-visible {
    transform: translate(-50%, 0);
}

.gmcm-brand {
    min-height: 38px;
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.gmcm-logo {
    display: block;
    width: auto;
    max-width: 175px;
    max-height: 54px;
    object-fit: contain;
}

.gmcm-wordmark {
    font-size: 22px;
    font-weight: 700;
    color: var(--gm-primary);
    letter-spacing: -.02em;
}

.gmcm-wordmark strong {
    color: var(--gm-secondary);
}

.gmcm-modal h2 {
    margin: 0 0 10px;
    color: var(--gm-navy);
    font-size: clamp(24px, 4vw, 32px);
    line-height: 1.08;
    letter-spacing: -.035em;
}

.gmcm-lead {
    margin: 0 0 16px;
    color: #5c6270;
    font-size: 15px;
    line-height: 1.58;
}

.gmcm-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin: 10px 0 18px;
    font-size: 13px;
}

.gmcm-links a {
    color: var(--gm-navy);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.gmcm-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.gmcm-btn {
    appearance: none;
    min-height: 48px;
    border-radius: 12px;
    padding: 12px 16px;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    transition: transform .14s ease, filter .14s ease, box-shadow .14s ease;
}

.gmcm-btn:hover {
    transform: translateY(-1px);
    filter: brightness(.98);
}

.gmcm-btn-primary {
    border: 1px solid var(--gm-primary);
    background: linear-gradient(135deg, var(--gm-primary), #f14b67);
    color: #fff;
    box-shadow: 0 8px 24px rgba(226,62,77,.18);
}

.gmcm-btn-secondary {
    border: 1px solid rgba(17,26,90,.22);
    background: #fff;
    color: var(--gm-navy);
}

.gmcm-details {
    padding-top: 26px;
}

.gmcm-close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid rgba(17,26,90,.18);
    background: #fff;
    color: var(--gm-navy);
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

.gmcm-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 16px;
    align-items: center;
    padding: 15px 0;
    border-top: 1px solid rgba(17,26,90,.09);
}

.gmcm-row strong {
    display: block;
    margin-bottom: 4px;
    color: var(--gm-navy);
    font-size: 15px;
}

.gmcm-row p {
    margin: 0;
    color: #6a6f7c;
    font-size: 12.5px;
    line-height: 1.45;
}

.gmcm-switch {
    position: relative;
    display: inline-flex;
    width: 47px;
    height: 28px;
    flex: 0 0 47px;
}

.gmcm-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.gmcm-switch span {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: #a7adba;
    cursor: pointer;
    transition: .18s ease;
}

.gmcm-switch span::after {
    content: "";
    position: absolute;
    width: 22px;
    height: 22px;
    left: 3px;
    top: 3px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 7px rgba(0,0,0,.22);
    transition: .18s ease;
}

.gmcm-switch input:checked + span {
    background: linear-gradient(135deg, var(--gm-primary), var(--gm-secondary));
}

.gmcm-switch input:checked + span::after {
    transform: translateX(19px);
}

.gmcm-switch.is-locked {
    opacity: .8;
}

.gmcm-switch.is-locked span {
    cursor: not-allowed;
}

.gmcm-manage {
    position: fixed;
    z-index: 2147482999;
    bottom: 18px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 43px;
    padding: 9px 14px 9px 10px;
    border: 1px solid rgba(255,255,255,.5);
    border-radius: 999px;
    background: var(--gm-navy);
    color: #fff;
    box-shadow: 0 8px 26px rgba(17,26,90,.22);
    font: inherit;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}

.gmcm-manage-right { right: 18px; }
.gmcm-manage-left { left: 18px; }

.gmcm-cookie-icon {
    display: grid;
    place-items: center;
    color: var(--gm-primary);
    background: #fff;
    width: 28px;
    height: 28px;
    border-radius: 50%;
}

@media (max-width: 600px) {
    .gmcm-modal {
        width: calc(100vw - 20px);
        max-height: calc(100dvh - 20px);
        padding: 22px 18px;
        border-radius: 18px;
    }

    .gmcm-actions {
        grid-template-columns: 1fr;
    }

    .gmcm-btn {
        min-height: 50px;
    }

    .gmcm-manage {
        bottom: 12px;
        right: 12px;
        left: auto;
        padding-right: 12px;
    }

    .gmcm-manage-left {
        left: 12px;
        right: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    .gmcm-backdrop,
    .gmcm-modal,
    .gmcm-btn,
    .gmcm-switch span,
    .gmcm-switch span::after {
        transition: none !important;
    }
}
