:root {
    --tmec-cookie-blue: #0b3b82;
    --tmec-cookie-blue-dark: #06295d;
    --tmec-cookie-border: #d7dce5;
    --tmec-cookie-text: #162033;
    --tmec-cookie-bg: #ffffff;
}

.tmec-cookie-banner {
    position: fixed;
    z-index: 999990;
    right: 20px;
    bottom: 20px;
    left: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    max-width: 1180px;
    margin: 0 auto;
    padding: 22px;
    color: var(--tmec-cookie-text);
    background: var(--tmec-cookie-bg);
    border: 1px solid var(--tmec-cookie-border);
    border-radius: 14px;
    box-shadow: 0 18px 60px rgba(6, 41, 93, 0.22);
}

.tmec-cookie-banner[hidden],
.tmec-cookie-modal[hidden] {
    display: none !important;
}

.tmec-cookie-banner__content {
    max-width: 690px;
}

.tmec-cookie-banner h2,
.tmec-cookie-modal h2 {
    margin: 0 0 8px;
    color: var(--tmec-cookie-blue-dark);
    font-size: 1.25rem;
}

.tmec-cookie-banner p,
.tmec-cookie-modal p {
    margin: 0;
    line-height: 1.55;
}

.tmec-cookie-banner a {
    color: var(--tmec-cookie-blue);
    font-weight: 600;
}

.tmec-cookie-banner__actions,
.tmec-cookie-modal__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.tmec-cookie-button,
.tmec-policy-preferences,
.tmec-cookie-manage {
    min-height: 42px;
    padding: 9px 16px;
    font: inherit;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
    border-radius: 8px;
}

.tmec-cookie-button--primary,
.tmec-policy-preferences {
    color: #fff;
    background: var(--tmec-cookie-blue);
    border: 2px solid var(--tmec-cookie-blue);
}

.tmec-cookie-button--primary:hover,
.tmec-cookie-button--primary:focus,
.tmec-policy-preferences:hover,
.tmec-policy-preferences:focus {
    color: #fff;
    background: var(--tmec-cookie-blue-dark);
    border-color: var(--tmec-cookie-blue-dark);
}

.tmec-cookie-button--secondary {
    color: var(--tmec-cookie-blue);
    background: #fff;
    border: 2px solid var(--tmec-cookie-blue);
}

.tmec-cookie-button:focus-visible,
.tmec-policy-preferences:focus-visible,
.tmec-cookie-manage:focus-visible,
.tmec-cookie-modal__close:focus-visible {
    outline: 3px solid #f0b429;
    outline-offset: 2px;
}

.tmec-cookie-modal {
    position: fixed;
    z-index: 999999;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(8, 19, 38, 0.7);
}

.tmec-cookie-modal__panel {
    position: relative;
    width: min(680px, 100%);
    max-height: min(760px, calc(100vh - 40px));
    overflow: auto;
    padding: 28px;
    color: var(--tmec-cookie-text);
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 20px 70px rgba(0, 0, 0, 0.35);
}

.tmec-cookie-modal__close {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 40px;
    height: 40px;
    color: var(--tmec-cookie-text);
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    background: transparent;
    border: 0;
}

.tmec-cookie-category {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 16px;
    padding: 16px;
    border: 1px solid var(--tmec-cookie-border);
    border-radius: 10px;
}

.tmec-cookie-category p {
    margin-top: 4px;
    font-size: 0.94rem;
}

.tmec-cookie-switch input {
    width: 22px;
    height: 22px;
    accent-color: var(--tmec-cookie-blue);
}

.tmec-cookie-modal__actions {
    margin-top: 20px;
}

.tmec-cookie-modal-open {
    overflow: hidden;
}

.tmec-cookie-manage {
    position: fixed;
    z-index: 999980;
    bottom: 12px;
    left: 12px;
    min-height: 34px;
    padding: 7px 11px;
    color: #fff;
    font-size: 0.82rem;
    background: var(--tmec-cookie-blue-dark);
    border: 1px solid rgba(255, 255, 255, 0.65);
    border-radius: 999px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.18);
}

.tmec-policy-hero {
    padding: clamp(52px, 8vw, 96px) 20px;
    color: #fff;
    background: linear-gradient(135deg, #06295d 0%, #0b3b82 65%, #1764ba 100%);
}

.tmec-policy-container {
    width: min(1120px, 100%);
    margin: 0 auto;
}

.tmec-policy-eyebrow {
    margin: 0 0 8px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.tmec-policy-hero h1 {
    margin: 0;
    color: #fff;
    font-size: clamp(2rem, 5vw, 3.5rem);
}

.tmec-policy-section {
    padding: clamp(42px, 7vw, 76px) 20px;
}

.tmec-cookie-policy {
    color: #1d2939;
    line-height: 1.7;
}

.tmec-cookie-policy h2 {
    margin-top: 2.1em;
    color: #06295d;
}

.tmec-policy-updated {
    padding: 12px 16px;
    background: #eef5ff;
    border-left: 4px solid var(--tmec-cookie-blue);
}

.tmec-policy-owner {
    display: grid;
    gap: 0;
    border: 1px solid var(--tmec-cookie-border);
    border-radius: 10px;
    overflow: hidden;
}

.tmec-policy-owner > div {
    display: grid;
    grid-template-columns: minmax(150px, 220px) 1fr;
    gap: 16px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--tmec-cookie-border);
}

.tmec-policy-owner > div:last-child {
    border-bottom: 0;
}

.tmec-policy-owner dt {
    font-weight: 700;
}

.tmec-policy-owner dd {
    margin: 0;
}

.tmec-cookie-table-wrap {
    max-width: 100%;
    overflow-x: auto;
    border: 1px solid var(--tmec-cookie-border);
    border-radius: 10px;
}

.tmec-cookie-table {
    width: 100%;
    min-width: 1050px;
    border-collapse: collapse;
    font-size: 0.94rem;
}

.tmec-cookie-table th,
.tmec-cookie-table td {
    padding: 12px;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid var(--tmec-cookie-border);
}

.tmec-cookie-table th {
    color: #fff;
    background: var(--tmec-cookie-blue-dark);
}

.tmec-cookie-table tbody tr:last-child td {
    border-bottom: 0;
}

.tmec-cookie-table tbody tr:nth-child(even) {
    background: #f7f9fc;
}

@media (max-width: 860px) {
    .tmec-cookie-banner {
        align-items: stretch;
        flex-direction: column;
        gap: 16px;
    }

    .tmec-cookie-banner__actions {
        justify-content: stretch;
    }

    .tmec-cookie-button {
        flex: 1 1 150px;
    }
}

@media (max-width: 560px) {
    .tmec-cookie-banner {
        right: 10px;
        bottom: 10px;
        left: 10px;
        padding: 18px;
    }

    .tmec-cookie-banner__actions {
        flex-direction: column;
    }

    .tmec-cookie-category,
    .tmec-policy-owner > div {
        align-items: flex-start;
        grid-template-columns: 1fr;
    }

    .tmec-cookie-category {
        flex-direction: column;
    }
}

@media (prefers-reduced-motion: reduce) {
    .tmec-cookie-banner,
    .tmec-cookie-modal {
        scroll-behavior: auto;
    }
}
