main {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.language-selector {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    border: 1px solid #ccc;
    border-radius: 10px;
    overflow: hidden;
    background-color: white;
    width: 150px;
    height: 38px;
    box-sizing: border-box;
}

.language-selector select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    border: none;
    background-color: transparent;
    padding: 0 40px 0 40px;
    font-size: 16px;
    cursor: pointer;
    width: 100%;
    height: 100%;
    outline: none;
    position: relative;
    z-index: 2;
    color: #333;
    box-sizing: border-box;
    line-height: normal;
}

.language-selector select option {
    background-color: white;
    color: #333;
    padding: 8px 10px;
    line-height: 1.4;
}

.language-selector select option:hover {
    background-color: #f0f0f0;
    color: #333;
}

.language-selector select option:checked {
    background-color: #e0e0e0;
    color: #333;
}

.language-selector .flag {
    position: absolute;
    top: 50%;
    left: 10px;
    transform: translateY(-50%);
    width: 24px;
    height: auto;
    z-index: 1;
    pointer-events: none;
}

.language-selector::after {
    content: '▼';
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    font-size: 12px;
    color: #555;
    pointer-events: none;
    z-index: 3;
}

/* Posicionamiento del modal */
.cookie-modal {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    max-width: 520px;
    width: calc(100% - 3rem);
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    z-index: 9999;
}

/* Contenedor del contenido */
.cookie-box {
    padding: 1.5rem;
    font-size: 0.80rem;
    color: #333;
    position: relative;
}

/* Título */
.cookie-box h2 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 0;
    margin-bottom: 0.75rem;
    color: #1e3438;
}

/* Botones */
.cookie-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1.25rem;
    justify-content: center;
}

.cookie-buttons .btn {
    padding: 0.4rem 1rem;
    font-size: 0.80rem;
    font-weight: 500;
    border-radius: 5px;
    cursor: pointer;
    border: none;
    white-space: nowrap;
    min-width: 140px;
    flex-grow: 0;
}

/* Versión responsive: botones a bloque completo si pantalla < 590px */
@media (max-width: 590px) {
    .cookie-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .cookie-buttons .btn {
        width: 100%;
        white-space: normal; /* permitir salto de línea si es necesario */
        text-align: center;
    }
}

.cookie-buttons .accept {
    background-color: #1e3438;
    color: #fff;
}

.cookie-buttons .accept:hover {
    background-color: #29494c;
}

.cookie-buttons .decline {
    background-color: #f2f2f2;
    color: #333;
}

.cookie-buttons .decline:hover {
    background-color: #e1e1e1;
}

.cookie-buttons .preferences {
    background-color: #e4e4e4;
    color: #333;
}

.cookie-buttons .preferences:hover {
    background-color: #d3d3d3;
}

/* Cierre */
.cookie-close {
    position: absolute;
    top: 0.75rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.25rem;
    color: #888;
    cursor: pointer;
}

/* Enlaces */
.cookie-links {
    margin-top: 1rem;
    font-size: 0.85rem;
    color: #666;
    text-align: center;
}

.cookie-links a {
    color: #1e3438;
    text-decoration: underline;
}

.cookie-category {
    padding: 0.75rem 0;
    border-top: 1px solid #eee;
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.always-active {
    font-size: 0.85rem;
    color: green;
}

/* Switch estilo iOS */
.switch {
    position: relative;
    display: inline-block;
    width: 42px;
    height: 22px;
}

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

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    border-radius: 34px;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    border-radius: 50%;
    transition: .4s;
}

input:checked + .slider {
    background-color: #1e3438;
}

input:checked + .slider:before {
    transform: translateX(20px);
}

.cookie-revisit {
    position: fixed;
    bottom: 1.5rem;
    left: 1.5rem;
    z-index: 9999;
}

.cookie-revisit button {
    background-color: #d2e7e7;
    border: none;
    padding: 0.6rem;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.cookie-revisit button:hover {
    background-color: #bcd6d6;
}

.cookie-revisit img {
    display: block;
    margin: 0 auto;
    width: 24px;
    height: 24px;
    filter: none;
}

.tooltip-wrapper {
    position: relative;
    display: inline-block;
}

.custom-tooltip {
    position: absolute;
    bottom: 130%;
    left: 0;
    background-color: #1e3438;
    color: white;
    padding: 0.4em 0.75em;
    border-radius: 4px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 10000;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    min-width: max-content;
    max-width: 200px;
    text-align: center;
}


.tooltip-wrapper:hover .custom-tooltip {
    opacity: 1;
}

.custom-tooltip::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 1rem;
    border-width: 5px;
    border-style: solid;
    border-color: #1e3438 transparent transparent transparent;
}