/* RESET Y CONFIGURACIÓN BASE */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #f7f5f0; /* Fondo crema suave muy elegante */
    color: #2b2523;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

/* CONTENEDOR PRINCIPAL */
.main-content {
    width: 100%;
    max-width: 850px;
}

/* CARD DE BÚSQUEDA */
.search-card {
    background-color: #ffffff;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
    border: 1px solid #e8e3d9;
}

h1 {
    font-size: 28px;
    color: #4a3b32;
    margin-bottom: 8px;
    font-weight: 700;
}

.subtitle {
    color: #7a6e65;
    font-size: 15px;
    margin-bottom: 30px;
}

/* GRID DE SELECTORES (4 COLUMNAS PARA ESCRITORIO) */
.selectors-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 15px;
    margin-bottom: 30px;
}

.select-group {
    display: flex;
    flex-direction: column;
}

.select-group label {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #615248;
    margin-bottom: 8px;
}

select {
    padding: 12px 14px;
    border: 1px solid #d1c7bd;
    border-radius: 6px;
    background-color: #faf9f6;
    font-size: 15px;
    color: #2b2523;
    outline: none;
    transition: all 0.2s ease;
    cursor: pointer;
}

select:focus {
    border-color: #8c7355;
    background-color: #ffffff;
    box-shadow: 0 0 0 3px rgba(140, 115, 85, 0.15);
}

select:disabled {
    background-color: #f0ece6;
    color: #a3988e;
    cursor: not-allowed;
    border-color: #e0d8ce;
}

/* RESULTADO Y TEXTO GRIEGO */
.result-container {
    margin-top: 25px;
    padding: 30px;
    background-color: #faf6f0;
    border-left: 4px solid #8c7355;
    border-radius: 0 8px 8px 0;
    text-align: left;
    transition: opacity 0.3s ease;
}

.result-container.hidden {
    display: none;
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    gap: 12px;
}

.result-header .reference-badge {
    margin-bottom: 0;
}

.copy-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: none;
    border: 1px solid #d1c7bd;
    color: #7a6e65;
    padding: 5px 10px;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.copy-btn:hover {
    background-color: #ffffff;
    border-color: #8c7355;
    color: #8c7355;
}

.copy-btn.copied {
    color: #4a7c59;
    border-color: #4a7c59;
}

.copy-btn .copy-icon {
    flex-shrink: 0;
}

.reference-badge {
    display: inline-block;
    background-color: #8c7355;
    color: #ffffff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 15px;
}

.greek-text {
    font-size: clamp(18px, 2.5vw, 24px);
    line-height: 1.7;
    color: #1a1411;
    font-family: 'Times New Roman', Times, serif; /* Fuente serif clásica para lectura en griego */
    text-align: left;
    margin: 0;
}

/* MENSAJE DE CARGA */
.loading-msg {
    text-align: center;
    color: #8c7355;
    font-style: italic;
    margin-top: 15px;
    font-size: 14px;
}

/* ===================== */
/* MENÚ HAMBURGUESA LATERAL */
/* ===================== */

.menu-btn {
    position: fixed;
    top: 18px;
    left: 18px;
    width: 44px;
    height: 44px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    background-color: #ffffff;
    border: 1px solid #e8e3d9;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    cursor: pointer;
    z-index: 1001;
    transition: background-color 0.2s ease;
}

.menu-btn:hover {
    background-color: #faf6f0;
}

.menu-btn span {
    display: block;
    width: 22px;
    height: 2px;
    background-color: #4a3b32;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.menu-btn.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.menu-btn.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.side-menu {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 280px;
    max-width: 80vw;
    background-color: #ffffff;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    padding: 90px 0 30px;
    overflow-y: auto;
}

.side-menu.active {
    transform: translateX(0);
}

.menu-title {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    color: #8c7355;
    text-transform: uppercase;
    padding: 0 25px 16px;
    border-bottom: 1px solid #e8e3d9;
    margin-bottom: 10px;
}

.menu-links {
    display: flex;
    flex-direction: column;
}

.menu-link {
    padding: 12px 25px;
    color: #2b2523;
    text-decoration: none;
    font-size: 15px;
    line-height: 1.15;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.menu-link:hover {
    background-color: #faf6f0;
    color: #8c7355;
}

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* DISEÑO RESPONSIVO (MÓVILES Y TABLETS) */
@media (max-width: 650px) {
    .search-card {
        padding: 25px 18px;
    }

    .selectors-grid {
        grid-template-columns: 1fr; /* Una columna vertical en dispositivos móviles */
        gap: 12px;
    }

    h1 {
        font-size: 22px;
    }

    .subtitle {
        font-size: 14px;
        margin-bottom: 20px;
    }

    .result-container {
        padding: 20px 15px;
    }
}