/* ================================================
   ASCENDENTE CALCULADORA - APP STYLES
   ================================================ */

.asc-app {
    --asc-oro: #ffd700;
    --asc-amanecer: #ff9f43;
    --asc-cielo: #48dbfb;
    --asc-gradiente: linear-gradient(135deg, #ff9f43 0%, #ffd700 50%, #48dbfb 100%);
    --asc-gradiente-amanecer: linear-gradient(135deg, #ff9f43 0%, #ffd700 100%);
    --asc-sombra: 0 10px 30px rgba(255, 159, 67, 0.15);
    --asc-sombra-hover: 0 15px 40px rgba(255, 159, 67, 0.25);
    --asc-radio: 16px;
    --asc-transicion: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    position: relative;
    overflow: hidden;
}

/* ================================================
   FASE FORMULARIO
   ================================================ */

.asc-fase {
    animation: ascFadeIn 0.6s ease;
}

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

.asc-form-contenido {
    text-align: center;
    padding: 2.5rem 1rem;
}

.asc-icono-oraculo {
    font-size: 4rem;
    position: relative;
    display: inline-block;
    margin-bottom: 1.5rem;
    animation: ascBrillar 3s ease-in-out infinite;
}

@keyframes ascBrillar {
    0%, 100% { transform: scale(1); filter: brightness(1); }
    50% { transform: scale(1.1); filter: brightness(1.3); }
}

.asc-destello {
    position: absolute;
    font-size: 1rem;
    opacity: 0;
    animation: ascDestello 3s ease-in-out infinite;
    pointer-events: none;
}

.asc-destello::before { content: '\2726'; }
.asc-d2::before { content: '\2756'; }
.asc-d3::before { content: '\2727'; }

.asc-d1 { animation-delay: -0.5s; top: -10px; left: 10px; }
.asc-d2 { animation-delay: -1.5s; top: -5px; right: 15px; }
.asc-d3 { animation-delay: -2.5s; bottom: 5px; left: 25px; }

@keyframes ascDestello {
    0%, 100% { opacity: 0; transform: translateY(0) scale(0.5); }
    50% { opacity: 0.8; transform: translateY(-20px) scale(1); }
}

.asc-titulo-form {
    color: #fff;
    font-size: 2rem;
    margin-bottom: 0.5rem;
    background: var(--asc-gradiente-amanecer);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.asc-subtitulo-form {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 2rem;
    font-size: 1rem;
}

/* Form fields */
.asc-campo {
    max-width: 500px;
    margin: 0 auto 1.5rem;
    text-align: left;
}

.asc-label {
    display: block;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.asc-select {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 159, 67, 0.3);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    color: #fff;
    font-family: inherit;
    font-size: 0.95rem;
    transition: var(--asc-transicion);
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23ff9f43' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    cursor: pointer;
}

.asc-select:focus {
    outline: none;
    border-color: var(--asc-amanecer);
    box-shadow: 0 0 0 3px rgba(255, 159, 67, 0.15);
    background-color: rgba(255, 255, 255, 0.08);
}

.asc-select option {
    background: #1a1a2e;
    color: #fff;
}

.asc-campo-ayuda {
    display: block;
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.8rem;
    margin-top: 0.3rem;
}

/* Calculate button */
.asc-btn-calcular {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: var(--asc-gradiente-amanecer);
    color: #1a1a2e;
    border: none;
    border-radius: 50px;
    padding: 0.9rem 2.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--asc-transicion);
    margin-top: 1rem;
    font-family: inherit;
}

.asc-btn-calcular:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 159, 67, 0.3);
}

.asc-instruccion {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
    margin-top: 1.5rem;
}

/* ================================================
   LOADING
   ================================================ */

.asc-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
}

.asc-loading-rueda {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 159, 67, 0.2);
    border-top: 4px solid var(--asc-amanecer);
    border-radius: 50%;
    animation: ascGirar 1s linear infinite;
    margin-bottom: 1rem;
}

@keyframes ascGirar {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.asc-loading-texto {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    animation: ascPulso 1.5s ease-in-out infinite;
}

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

/* ================================================
   FASE RESULTADO
   ================================================ */

.asc-resultado-contenido {
    padding: 2rem 1rem;
}

.asc-resultado-header {
    text-align: center;
    margin-bottom: 2rem;
}

.asc-resultado-signo-grande {
    font-size: 5rem;
    margin-bottom: 1rem;
    animation: ascBrillar 3s ease-in-out infinite;
}

.asc-resultado-titulo {
    font-size: 2rem;
    background: var(--asc-gradiente-amanecer);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.asc-resultado-meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.asc-meta-item {
    font-size: 0.9rem;
    padding: 4px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.8);
}

.asc-elem-fuego { color: #f87171; background: rgba(239, 68, 68, 0.15); }
.asc-elem-tierra { color: #4ade80; background: rgba(34, 197, 94, 0.15); }
.asc-elem-agua { color: #60a5fa; background: rgba(59, 130, 246, 0.15); }
.asc-elem-aire { color: #c084fc; background: rgba(168, 85, 247, 0.15); }

.asc-meta-sep {
    color: rgba(255, 255, 255, 0.3);
}

.asc-resultado-seccion {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 159, 67, 0.1);
    border-radius: var(--asc-radio);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    animation: ascSlideIn 0.6s ease both;
}

.asc-resultado-seccion:nth-child(1) { animation-delay: 0s; }
.asc-resultado-seccion:nth-child(2) { animation-delay: 0.1s; }
.asc-resultado-seccion:nth-child(3) { animation-delay: 0.2s; }
.asc-resultado-seccion:nth-child(4) { animation-delay: 0.3s; }

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

.asc-seccion-titulo {
    color: var(--asc-amanecer);
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.asc-resultado-descripcion {
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.8;
    font-size: 1rem;
}

.asc-resultado-texto {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.7;
    font-size: 0.95rem;
    font-style: italic;
}

/* Rasgos grid */
.asc-rasgos-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.asc-rasgo-badge {
    font-size: 0.85rem;
    padding: 6px 16px;
    border-radius: 20px;
    background: rgba(255, 159, 67, 0.12);
    color: var(--asc-amanecer);
    border: 1px solid rgba(255, 159, 67, 0.2);
}

/* Consejo */
.asc-resultado-consejo {
    background: rgba(255, 159, 67, 0.08);
    border-left: 3px solid var(--asc-amanecer);
    padding: 1rem 1.2rem;
    border-radius: 0 10px 10px 0;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    font-style: italic;
    margin-bottom: 1.5rem;
}

.asc-resultado-consejo::before { content: '\1F4A1  '; }

/* Boton nueva consulta */
.asc-btn-nueva {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    border: 2px solid rgba(255, 159, 67, 0.3);
    border-radius: 50px;
    padding: 0.9rem 2rem;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--asc-transicion);
    font-family: inherit;
}

.asc-btn-nueva:hover {
    background: rgba(255, 159, 67, 0.15);
    border-color: var(--asc-amanecer);
    transform: translateY(-2px);
}

/* ================================================
   PARTICULAS DE FONDO
   ================================================ */

.asc-app::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle at 30% 40%, rgba(255, 159, 67, 0.06) 0%, transparent 50%),
                radial-gradient(circle at 70% 30%, rgba(72, 219, 251, 0.04) 0%, transparent 50%),
                radial-gradient(circle at 50% 80%, rgba(255, 215, 0, 0.05) 0%, transparent 50%);
    animation: ascFondo 25s linear infinite;
    pointer-events: none;
    z-index: 0;
}

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

.asc-fase { position: relative; z-index: 1; }
.asc-loading { position: relative; z-index: 1; }

/* ================================================
   RESPONSIVE
   ================================================ */

@media (max-width: 768px) {
    .asc-titulo-form { font-size: 1.6rem; }
    .asc-icono-oraculo { font-size: 3rem; }

    .asc-resultado-signo-grande { font-size: 4rem; }
    .asc-resultado-titulo { font-size: 1.6rem; }
}

@media (max-width: 480px) {
    .asc-form-contenido { padding: 1.5rem 0.5rem; }
    .asc-titulo-form { font-size: 1.4rem; }
    .asc-subtitulo-form { font-size: 0.85rem; }

    .asc-resultado-contenido { padding: 1.5rem 0.5rem; }
    .asc-resultado-signo-grande { font-size: 3.5rem; }
    .asc-resultado-titulo { font-size: 1.4rem; }
    .asc-resultado-seccion { padding: 1.2rem; }
    .asc-btn-nueva { padding: 0.8rem 1.5rem; font-size: 0.9rem; }
    .asc-btn-calcular { padding: 0.8rem 1.8rem; font-size: 0.9rem; }
}

/* ================================================
   ACCESIBILIDAD
   ================================================ */

@media (prefers-reduced-motion: reduce) {
    .asc-app::before { animation: none; }
    .asc-icono-oraculo { animation: none; }
    .asc-destello { animation: none; display: none; }
    .asc-loading-rueda { animation: none; }
    .asc-loading-texto { animation: none; opacity: 1; }
    .asc-resultado-seccion { animation: none; opacity: 1; transform: none; }
    .asc-resultado-signo-grande { animation: none; }
    * { transition-duration: 0.05ms !important; animation-duration: 0.05ms !important; }
}

@media (prefers-contrast: high) {
    .asc-resultado-seccion { border: 2px solid rgba(255, 255, 255, 0.4); }
    .asc-select { border: 2px solid rgba(255, 255, 255, 0.4); }
}

@media print {
    .asc-app::before { display: none; }
    .asc-btn-nueva { display: none; }
    .asc-resultado-seccion { break-inside: avoid; }
}