/* ==========================================
   VARIABLES Y RESET GLOBAL
   ========================================== */

:root {
    --primary-color: #E91E63;
    --gold-color: #FFD700;
    --dark-color: #1a1a1a;
    --light-color: #ffffff;
    --gray-light: #f5f5f5;
    --gray-medium: #cccccc;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    --shadow-light: 0 5px 15px rgba(0, 0, 0, 0.05);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    width: 100%;
    overflow-x: hidden;
}

body {
    font-family: 'Lato', sans-serif;
    color: var(--dark-color);
    background-color: var(--light-color);
    line-height: 1.6;
}

/* ==========================================
   TIPOGRAFÍA
   ========================================== */

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    letter-spacing: 1px;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    text-decoration: underline;
    color: #d81b50;
}

/* ==========================================
   HEADER Y NAVEGACIÓN
   ========================================== */

.header {
    background: linear-gradient(135deg, var(--dark-color) 0%, #2a2a2a 100%);
    color: var(--light-color);
    padding: 20px 0;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

.logo-section h1 {
    font-size: 24px;
    color: var(--gold-color);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.ad-space {
    min-height: 60px;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
}

/* ==========================================
   CONTENEDOR PRINCIPAL
   ========================================== */

.main-container {
    min-height: calc(100vh - 200px);
    padding: 40px 20px;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
}

/* ==========================================
   PANTALLAS Y TRANSICIONES
   ========================================== */

.screen {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
}

.screen.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================
   PANTALLA DE BIENVENIDA
   ========================================== */

.welcome-content {
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
    animation: slideUp 0.6s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.welcome-icon {
    width: 120px;
    height: 120px;
    margin-bottom: 30px;
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.welcome-title {
    font-size: 42px;
    color: var(--primary-color);
    margin-bottom: 10px;
    line-height: 1.2;
}

.welcome-subtitle {
    font-size: 20px;
    color: var(--gold-color);
    margin-bottom: 20px;
    font-weight: 300;
}

.welcome-description {
    font-size: 16px;
    color: var(--dark-color);
    margin-bottom: 25px;
    line-height: 1.8;
}

.welcome-stats {
    background: linear-gradient(135deg, rgba(233, 30, 99, 0.1), rgba(255, 215, 0, 0.1));
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 30px;
    font-size: 14px;
    border-left: 4px solid var(--primary-color);
}

.welcome-stats strong {
    color: var(--primary-color);
}

.welcome-disclaimer {
    font-size: 12px;
    color: var(--gray-medium);
    margin-top: 20px;
}

.welcome-disclaimer a {
    color: var(--primary-color);
}

/* ==========================================
   BOTONES
   ========================================== */

.btn {
    padding: 14px 32px;
    font-size: 16px;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Lato', sans-serif;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, #d81b50 100%);
    color: var(--light-color);
    box-shadow: var(--shadow-light);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.btn-primary:active {
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: var(--gray-light);
    color: var(--dark-color);
    border: 2px solid var(--gray-medium);
}

.btn-secondary:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background-color: rgba(233, 30, 99, 0.05);
}

.btn-secret {
    background: linear-gradient(135deg, var(--gold-color), #ffed4e);
    color: var(--dark-color);
    margin: 20px 0;
    font-weight: 700;
    box-shadow: var(--shadow-light);
}

.btn-secret:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
    background: linear-gradient(135deg, #ffed4e, var(--gold-color));
}

.btn-back {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    font-size: 14px;
    padding: 10px 20px;
    margin-bottom: 20px;
}

.btn-back:hover {
    background-color: rgba(233, 30, 99, 0.1);
}

.btn-share {
    width: 100%;
    margin: 10px 0;
    font-weight: 600;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-share span {
    flex: 1;
}

.btn-share.whatsapp {
    background-color: #25D366;
    color: white;
}

.btn-share.whatsapp:hover {
    background-color: #20ba5a;
}

.btn-share.facebook {
    background-color: #1877F2;
    color: white;
}

.btn-share.facebook:hover {
    background-color: #0a66c2;
}

.btn-share.instagram {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    color: white;
}

.btn-share.instagram:hover {
    opacity: 0.8;
}

/* ==========================================
   TEST - BARRA DE PROGRESO
   ========================================== */

.test-container {
    max-width: 700px;
    margin: 0 auto;
    padding: 40px 20px;
}

.progress-bar-container {
    width: 100%;
    height: 6px;
    background-color: var(--gray-light);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 20px;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--gold-color));
    border-radius: 3px;
    transition: width 0.4s ease;
    width: 0%;
}

.progress-text {
    font-size: 14px;
    color: var(--gray-medium);
    text-align: center;
    margin-bottom: 30px;
    font-weight: 600;
}

/* ==========================================
   TARJETA DE PREGUNTA
   ========================================== */

.question-card {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 30px;
    animation: slideUp 0.4s ease-out;
}

.question-title {
    font-size: 24px;
    color: var(--dark-color);
    margin-bottom: 30px;
    line-height: 1.4;
}

.options-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* ==========================================
   OPCIONES DE RESPUESTA
   ========================================== */

.option {
    padding: 18px 20px;
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    background-color: white;
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
    font-size: 16px;
    position: relative;
    padding-left: 50px;
}

.option::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    border: 2px solid var(--gray-medium);
    border-radius: 50%;
    transition: var(--transition);
}

.option:hover {
    border-color: var(--primary-color);
    background-color: rgba(233, 30, 99, 0.02);
}

.option:hover::before {
    border-color: var(--primary-color);
}

.option.selected {
    border-color: var(--primary-color);
    background-color: rgba(233, 30, 99, 0.08);
    font-weight: 600;
}

.option.selected::before {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: inset 0 0 0 3px white;
}

/* ==========================================
   NAVEGACIÓN DEL TEST
   ========================================== */

.navigation-buttons {
    display: flex;
    gap: 15px;
    justify-content: space-between;
    flex-wrap: wrap;
}

.navigation-buttons .btn {
    flex: 1;
    min-width: 150px;
}

/* ==========================================
   PANTALLA DE ANÁLISIS
   ========================================== */

.analysis-container {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
    padding: 60px 20px;
}

.analysis-content {
    margin-bottom: 40px;
}

.loading-animation {
    width: 80px;
    height: 80px;
    margin-bottom: 30px;
}

.analysis-title {
    font-size: 32px;
    color: var(--dark-color);
    margin-bottom: 30px;
}

.analysis-messages {
    height: 40px;
    position: relative;
}

.analysis-message {
    position: absolute;
    font-size: 16px;
    color: var(--primary-color);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.analysis-message.active {
    opacity: 1;
}

/* ==========================================
   PANTALLA DE RESULTADOS
   ========================================== */

.results-container {
    max-width: 700px;
    margin: 0 auto;
    padding: 40px 20px;
}

.result-card {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 30px;
    text-align: center;
    animation: slideUp 0.5s ease-out;
}

.result-icon {
    width: 120px;
    height: 120px;
    margin-bottom: 20px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--gold-color);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
}

.result-type {
    font-size: 36px;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.result-description {
    font-size: 16px;
    color: var(--dark-color);
    margin-bottom: 30px;
    line-height: 1.8;
}

.result-stats {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

.stat-box {
    background: linear-gradient(135deg, rgba(233, 30, 99, 0.1), rgba(255, 215, 0, 0.1));
    padding: 20px 30px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-label {
    font-size: 12px;
    color: var(--gray-medium);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.stat-value {
    font-size: 36px;
    color: var(--primary-color);
    font-weight: 700;
    font-family: 'Playfair Display', serif;
}

.stat-unit {
    font-size: 14px;
    color: var(--gray-medium);
}

.action-buttons {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.action-buttons .btn {
    flex: 1;
    min-width: 150px;
}

/* ==========================================
   SECCIÓN DE COMPARTIR
   ========================================== */

.share-section {
    background-color: var(--gray-light);
    padding: 30px;
    border-radius: 12px;
    margin-top: 30px;
}

.share-section h3 {
    font-size: 20px;
    color: var(--dark-color);
    margin-bottom: 20px;
    text-align: center;
}

.share-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* ==========================================
   ANÁLISIS SECRETO
   ========================================== */

.secret-analysis-container {
    max-width: 700px;
    margin: 0 auto;
    padding: 20px;
}

.secret-loading-screen {
    text-align: center;
    padding: 80px 20px;
    display: none;
}

.secret-loading-screen.active {
    display: block;
    animation: fadeIn 0.5s ease-in-out;
}

.secret-analysis-content {
    margin-bottom: 40px;
}

.secret-loading {
    width: 100px;
    height: 100px;
    margin-bottom: 30px;
}

.secret-title {
    font-size: 32px;
    color: var(--dark-color);
    margin-bottom: 30px;
}

.secret-messages {
    height: 40px;
    position: relative;
    margin-bottom: 40px;
}

.secret-message {
    position: absolute;
    font-size: 16px;
    color: var(--primary-color);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.secret-message.active {
    opacity: 1;
}

.secret-content-screen {
    display: none;
    animation: slideUp 0.5s ease-out;
}

.secret-content-screen.active {
    display: block;
}

.secret-analysis-title {
    font-size: 28px;
    color: var(--dark-color);
    margin-bottom: 30px;
    text-align: center;
}

.secret-analysis-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.analysis-card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--shadow-light);
    border-left: 4px solid var(--primary-color);
}

.analysis-card h3 {
    font-size: 18px;
    color: var(--dark-color);
    margin-bottom: 15px;
}

.analysis-insight {
    font-size: 14px;
    color: var(--dark-color);
    line-height: 1.8;
    margin-bottom: 15px;
}

.risk-indicator {
    height: 8px;
    border-radius: 4px;
    background: linear-gradient(90deg, #4CAF50, #FFC107, #F44336);
    position: relative;
}

.risk-indicator::after {
    content: '';
    position: absolute;
    width: 2px;
    height: 14px;
    background-color: var(--dark-color);
    top: -3px;
    left: var(--risk-position, 50%);
    transform: translateX(-50%);
}

.commitment-meter {
    text-align: center;
}

.commitment-bar {
    height: 12px;
    border-radius: 6px;
    background: linear-gradient(90deg, var(--primary-color), var(--gold-color));
    margin: 15px 0;
    width: 0%;
    transition: width 1s ease-out;
}

.commitment-percentage {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
    margin-top: 10px;
}

.secret-recommendation {
    background: linear-gradient(135deg, rgba(233, 30, 99, 0.1), rgba(255, 215, 0, 0.1));
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 30px;
    border-left: 4px solid var(--gold-color);
}

.secret-recommendation h3 {
    font-size: 18px;
    color: var(--dark-color);
    margin-bottom: 15px;
}

.secret-recommendation p {
    font-size: 14px;
    color: var(--dark-color);
    line-height: 1.8;
}

/* ==========================================
   CANVAS PARA TARJETA DESCARGABLE
   ========================================== */

#canvas-card {
    display: none;
}

/* ==========================================
   FOOTER
   ========================================== */

.footer {
    background: var(--dark-color);
    color: var(--light-color);
    text-align: center;
    padding: 30px 20px;
    margin-top: 60px;
    border-top: 2px solid var(--gold-color);
}

.footer p {
    margin: 10px 0;
    font-size: 14px;
}

.footer a {
    color: var(--gold-color);
}

.footer a:hover {
    color: var(--primary-color);
}

/* ==========================================
   RESPONSIVE DESIGN - TABLET
   ========================================== */

@media (max-width: 768px) {
    .logo-section h1 {
        font-size: 18px;
    }

    .logo {
        width: 40px;
        height: 40px;
    }

    .welcome-title {
        font-size: 32px;
    }

    .welcome-subtitle {
        font-size: 18px;
    }

    .welcome-icon {
        width: 100px;
        height: 100px;
    }

    .question-card {
        padding: 25px;
    }

    .question-title {
        font-size: 20px;
    }

    .option {
        padding: 15px 15px 15px 45px;
        font-size: 15px;
    }

    .result-card {
        padding: 25px;
    }

    .result-type {
        font-size: 28px;
    }

    .result-icon {
        width: 100px;
        height: 100px;
    }

    .stat-box {
        padding: 15px 20px;
    }

    .stat-value {
        font-size: 28px;
    }

    .secret-analysis-cards {
        grid-template-columns: 1fr;
    }

    .action-buttons {
        flex-direction: column;
    }

    .action-buttons .btn {
        width: 100%;
    }

    .share-buttons {
        flex-direction: column;
    }

    .share-buttons .btn {
        width: 100%;
    }
}

/* ==========================================
   RESPONSIVE DESIGN - MÓVIL
   ========================================== */

@media (max-width: 480px) {
    .main-container {
        padding: 20px 15px;
    }

    .header .container {
        flex-direction: column;
        gap: 15px;
    }

    .ad-space {
        width: 100%;
    }

    .welcome-content {
        padding: 0 10px;
    }

    .welcome-title {
        font-size: 28px;
    }

    .welcome-subtitle {
        font-size: 16px;
    }

    .welcome-description {
        font-size: 14px;
    }

    .welcome-icon {
        width: 80px;
        height: 80px;
        margin-bottom: 20px;
    }

    .btn {
        padding: 12px 24px;
        font-size: 14px;
    }

    .test-container {
        padding: 20px 0;
    }

    .question-card {
        padding: 20px;
        margin-bottom: 20px;
    }

    .question-title {
        font-size: 18px;
        margin-bottom: 20px;
    }

    .option {
        padding: 12px 12px 12px 40px;
        font-size: 14px;
    }

    .option::before {
        width: 18px;
        height: 18px;
        left: 12px;
    }

    .navigation-buttons {
        flex-direction: column;
    }

    .navigation-buttons .btn {
        width: 100%;
    }

    .result-card {
        padding: 20px;
    }

    .result-type {
        font-size: 24px;
    }

    .result-description {
        font-size: 14px;
    }

    .result-icon {
        width: 80px;
        height: 80px;
    }

    .stat-box {
        padding: 15px;
    }

    .stat-value {
        font-size: 24px;
    }

    .stat-label {
        font-size: 11px;
    }

    .stat-unit {
        font-size: 12px;
    }

    .action-buttons {
        flex-direction: column;
        margin-bottom: 20px;
    }

    .action-buttons .btn {
        width: 100%;
    }

    .share-section {
        padding: 20px;
    }

    .share-section h3 {
        font-size: 18px;
    }

    .secret-analysis-container {
        padding: 10px;
    }

    .secret-analysis-title {
        font-size: 22px;
    }

    .analysis-card {
        padding: 20px;
    }

    .analysis-card h3 {
        font-size: 16px;
    }

    .analysis-insight {
        font-size: 13px;
    }

    .secret-recommendation {
        padding: 20px;
    }

    .secret-recommendation h3 {
        font-size: 16px;
    }

    .secret-recommendation p {
        font-size: 13px;
    }

    .footer {
        padding: 20px 15px;
    }

    .footer p {
        font-size: 12px;
    }
}

/* ==========================================
   ANIMACIONES ADICIONALES
   ========================================== */

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}