/* estilos.css */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@400;600&family=Montserrat:wght@300;400&family=Segoe+UI:wght@400;500&display=swap');

:root {
    --color-primario: #5d3a8c;
    --color-secundario: #d4af37;
    --fondo: #f8f4f0;
    --texto: #333;
    --sombra: rgba(93, 58, 140, 0.15);
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', sans-serif;
    background: var(--fondo);
    color: var(--texto);
    margin: 0;
    padding: 0;
    background-image: radial-gradient(circle at 10% 20%, rgba(93,58,140,0.03) 0%, transparent 20%),
                      radial-gradient(circle at 90% 80%, rgba(212,175,55,0.03) 0%, transparent 20%);
    min-height: 100vh;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    background: white;
    padding: 25px;
    border-radius: 16px;
    box-shadow: 0 8px 30px var(--sombra);
    border: 1px solid rgba(212,175,55,0.1);
    width: 94%;
    margin-left: auto;
    margin-right: auto;
}

h1 {
    text-align: center;
    color: var(--color-primario);
    font-family: 'Cormorant Garamond', serif;
    font-size: 2.2rem;
    margin-bottom: 20px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

h2 {
    color: var(--color-primario);
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.6rem;
    margin-top: 25px;
    margin-bottom: 15px;
    border-bottom: 1px dashed var(--color-secundario);
    padding-bottom: 8px;
}

label {
    font-weight: 600;
    display: block;
    margin-top: 15px;
    color: var(--color-primario);
}

input, button {
    padding: 12px;
    width: 100%;
    margin-top: 6px;
    border-radius: 8px;
    border: 1px solid #ddd;
    font-family: inherit;
    font-size: 1rem;
}

button {
    background: var(--color-primario);
    color: white;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
}

button:hover {
    background: #4a2d70;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--sombra);
}

/* --- CARTAS --- */
.carta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 15px;
}

.carta-item {
    display: flex;
    gap: 14px;
    padding: 16px;
    border-radius: 12px;
    background: white;
    box-shadow: 0 4px 12px var(--sombra);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    border: 1px solid rgba(212,175,55,0.15);
}

.carta-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px var(--sombra);
}

.carta-imagen {
    width: 70px;
    height: 110px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.carta-emoticon {
    width: 70px;
    height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    background: #f0f0f0;
    border-radius: 8px;
    flex-shrink: 0;
}

.carta-texto {
    flex: 1;
}

.carta-texto strong {
    display: block;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.25rem;
    color: var(--color-primario);
    margin-bottom: 6px;
}

.carta-texto p {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* --- MENSAJE DEL ORÁCULO --- */
.oraculo-container {
    max-width: 900px;
    margin: 30px auto;
    padding: 0 15px;
    width: 100%;
}

.oraculo-blockquote {
    background: linear-gradient(135deg, #fdf9f3 0%, #fff8e1 100%);
    border: 1px solid rgba(212, 175, 55, 0.3);
    padding: 25px;
    margin: 0;
    font-style: normal;
    line-height: 1.7;
    border-radius: 12px;
    font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    font-size: 1.15rem;
    color: #444;
    box-shadow: 0 4px 15px rgba(93, 58, 140, 0.08);
    text-align: justify;
}

.oraculo-blockquote em {
    font-style: italic;
    color: var(--color-primario);
}

.oraculo-blockquote strong {
    color: var(--color-primario);
    font-weight: 600;
}

/* --- CARGA --- */
#loading {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(248, 244, 240, 0.95);
    backdrop-filter: blur(3px);
    z-index: 10000;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    font-family: 'Cormorant Garamond', serif;
    color: var(--color-primario);
}

.spinner {
    width: 80px;
    height: 80px;
    border: 5px solid rgba(93, 58, 140, 0.2);
    border-top: 5px solid var(--color-secundario);
    border-radius: 50%;
    animation: spin 1.4s cubic-bezier(0.68, -0.55, 0.27, 1.55) infinite;
    margin-bottom: 24px;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.3);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

#loading h2 {
    font-size: 2rem;
    margin: 0;
    color: var(--color-primario);
    text-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

#loading p {
    margin-top: 12px;
    font-size: 1.2rem;
    color: #666;
    max-width: 80%;
    line-height: 1.5;
}

/* --- RESPONSIVE --- */
@media (max-width: 600px) {
    body {
        padding: 0;
    }

    .container {
        padding: 20px 15px;
        border-radius: 12px;
        width: 100%;
    }

    .oraculo-container {
        padding: 0 10px;
        margin: 25px 0;
    }

    .oraculo-blockquote {
        padding: 22px 18px;
        font-size: 1.25rem;
        line-height: 1.8;
    }

    h1 {
        font-size: 1.8rem;
    }

    .carta-item {
        flex-direction: column;
        text-align: center;
    }

    .carta-imagen,
    .carta-emoticon {
        width: 100px;
        height: 160px;
        margin: 0 auto;
    }

    .carta-texto strong {
        font-size: 1.3rem;
    }

    ol {
        padding-left: 20px;
    }

    li {
        margin-bottom: 8px;
    }
}

hr {
    border: 0;
    height: 1px;
    background: linear-gradient(to right, transparent, var(--color-secundario), transparent);
    margin: 25px 0;
}

/* --- FOOTER GLOBAL --- */
.footer {
    text-align: center;
    padding: 20px 15px;
    margin-top: 40px;
    border-top: 1px solid #eee;
    color: #666;
    font-size: 0.95rem;
    line-height: 1.6;
}

.footer a {
    color: var(--color-primario);
    text-decoration: none;
    transition: color 0.2s;
}

.footer a:hover {
    color: var(--color-secundario);
    text-decoration: underline;
}

.resumen-container {
    background: linear-gradient(135deg, #fff9e6 0%, #fff3cd 100%);
    border-radius: 15px;
    padding: 25px;
    margin: 30px 0;
    border-left: 5px solid #ffc107;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.2);
    position: relative;
    overflow: hidden;
}

.resumen-container::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(to right, #ffc107, #ff9800, #f44336);
}

.resumen-titulo {
    text-align: center;
    font-size: 1.4rem;
    font-weight: bold;
    color: #5d3a8c;
    margin-bottom: 20px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.resumen-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 12px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 8px;
    transition: transform 0.2s;
}

.resumen-item:hover {
    transform: translateX(5px);
    background: white;
}

.resumen-icono {
    font-size: 24px;
    min-width: 35px;
    margin-right: 12px;
    color: #5d3a8c;
}

.resumen-texto {
    flex: 1;
    font-size: 1.05rem;
    line-height: 1.6;
    color: #333;
}

.resumen-texto strong {
    color: #5d3a8c;
    font-weight: 600;
}

/* Separador decorativo */
.resumen-separador {
    height: 2px;
    background: linear-gradient(to right, transparent, #ffc107, transparent);
    margin: 20px 0;
}

/* Responsive */
@media (max-width: 600px) {
    .resumen-container {
        padding: 20px 15px;
    }
    .resumen-item {
        flex-direction: column;
        align-items: flex-start;
    }
    .resumen-icono {
        margin-bottom: 8px;
    }
}