/* ================================================
   SINASTRIA - APP STYLES
   ================================================ */

.sn-app {
    --sn-rosa: #ec4899;
    --sn-rosa-oscuro: #db2777;
    --sn-oro: #f59e0b;
    --sn-luna: #8b5cf6;
    --sn-gradiente: linear-gradient(135deg, #ec4899 0%, #db2777 100%);
    --sn-gradiente-rosa: linear-gradient(135deg, #f472b6 0%, #ec4899 100%);
    --sn-sombra: 0 10px 30px rgba(236, 72, 153, 0.15);
    --sn-sombra-hover: 0 15px 40px rgba(236, 72, 153, 0.25);
    --sn-radio: 16px;
    --sn-transicion: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    position: relative;
    overflow: hidden;
}

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

.sn-fase {
    animation: snFadeIn 0.6s ease;
}

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

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

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

@keyframes snBrillar {
    0%, 100% { transform: scale(1); filter: brightness(1); }
    50% { transform: scale(1.1); filter: brightness(1.3) drop-shadow(0 0 20px rgba(236, 72, 153, 0.5)); }
}

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

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

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

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

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

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

/* Dual form */
.sn-dual-form {
    display: flex;
    gap: 1rem;
    max-width: 800px;
    margin: 0 auto 1.5rem;
    align-items: flex-start;
}

.sn-persona-form {
    flex: 1;
}

.sn-persona-titulo {
    color: var(--sn-rosa);
    font-size: 1rem;
    margin-bottom: 0.8rem;
    text-align: center;
}

.sn-separador {
    font-size: 1.5rem;
    color: var(--sn-rosa);
    align-self: center;
    padding-top: 2rem;
}

.sn-form-campos {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 0.6rem;
}

.sn-campo {
    text-align: left;
}

.sn-label {
    display: block;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
    font-weight: 500;
}

.sn-select {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(236, 72, 153, 0.3);
    border-radius: 12px;
    padding: 0.7rem 0.8rem;
    color: #fff;
    font-family: inherit;
    font-size: 0.9rem;
    transition: var(--sn-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='%23ec4899' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.7rem center;
    cursor: pointer;
}

.sn-select:focus {
    outline: none;
    border-color: var(--sn-rosa);
    box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.15);
    background-color: rgba(255, 255, 255, 0.08);
}

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

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

.sn-btn-calcular:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(236, 72, 153, 0.3);
}

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

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

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

.sn-loading-orbita {
    width: 90px;
    height: 90px;
    position: relative;
    margin-bottom: 1.5rem;
}

.sn-orbita-p1 {
    position: absolute;
    font-size: 1.3rem;
    top: 10px;
    left: 10px;
    animation: snOrbita1 3s ease-in-out infinite;
    color: var(--sn-rosa);
}

.sn-orbita-p2 {
    position: absolute;
    font-size: 1.3rem;
    bottom: 10px;
    right: 10px;
    animation: snOrbita2 3s ease-in-out infinite;
    color: var(--sn-oro);
}

@keyframes snOrbita1 {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(20px, 20px); }
}

@keyframes snOrbita2 {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-20px, -20px); }
}

.sn-orbita-arc {
    position: absolute;
    top: 5px;
    left: 5px;
    width: 80px;
    height: 80px;
    border: 1px dashed rgba(236, 72, 153, 0.3);
    border-radius: 50%;
    animation: snArcGiro 6s linear infinite;
}

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

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

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

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

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

.sn-resultado-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(236, 72, 153, 0.2);
}

.sn-puntuacion-display {
    margin-bottom: 0.5rem;
}

.sn-pct {
    font-size: 3rem;
    font-weight: 800;
    background: var(--sn-gradiente);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sn-pct-simbolo {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.6);
}

.sn-nivel-badge {
    display: inline-block;
    font-size: 0.95rem;
    padding: 0.4rem 1.2rem;
    border-radius: 20px;
    font-weight: 600;
}

.sn-seccion {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(236, 72, 153, 0.1);
    border-radius: var(--sn-radio);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    animation: snSlideIn 0.6s ease both;
}

.sn-seccion:nth-child(1) { animation-delay: 0s; }
.sn-seccion:nth-child(2) { animation-delay: 0.1s; }
.sn-seccion:nth-child(3) { animation-delay: 0.15s; }
.sn-seccion:nth-child(4) { animation-delay: 0.2s; }
.sn-seccion:nth-child(5) { animation-delay: 0.25s; }

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

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

.sn-titulo-pers { color: var(--sn-rosa); }
.sn-titulo-sol { color: var(--sn-oro); }
.sn-titulo-luna { color: var(--sn-luna); }
.sn-titulo-elem { color: #10b981; }

/* Dual profile */
.sn-dual-perfil {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 1rem;
    align-items: start;
}

.sn-perfil {
    text-align: center;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 1.2rem 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.sn-perfil-signo {
    font-size: 2.5rem;
    margin-bottom: 0.3rem;
}

.sn-perfil-nombre {
    color: var(--sn-rosa);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.sn-perfil-sol {
    color: var(--sn-oro);
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 0.3rem;
}

.sn-perfil-luna {
    color: var(--sn-luna);
    font-size: 0.9rem;
    margin-bottom: 0.8rem;
}

.sn-perfil-desc {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.85rem;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.sn-perfil-busca {
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.85rem;
    line-height: 1.5;
    margin-bottom: 0.5rem;
    background: rgba(236, 72, 153, 0.06);
    border-radius: 8px;
    padding: 0.5rem;
}

.sn-perfil-luna-nec {
    color: rgba(139, 92, 246, 0.9);
    font-size: 0.8rem;
    font-style: italic;
}

.sn-perfil-conector {
    font-size: 2rem;
    color: var(--sn-rosa);
    align-self: center;
    padding-top: 3rem;
}

/* Aspect items */
.sn-aspecto-item {
    padding: 1rem;
    border-radius: 10px;
    margin-bottom: 0.5rem;
}

.sn-aspecto-armonico {
    background: rgba(16, 185, 129, 0.08);
    border-left: 3px solid #10b981;
}

.sn-aspecto-tenso {
    background: rgba(239, 68, 68, 0.08);
    border-left: 3px solid #ef4444;
}

.sn-aspecto-neutro {
    background: rgba(139, 92, 246, 0.08);
    border-left: 3px solid #8b5cf6;
}

.sn-aspecto-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.sn-aspecto-nombre {
    font-weight: 600;
    color: #fff;
    font-size: 0.95rem;
}

.sn-aspecto-angulo {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
}

.sn-aspecto-desc {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* Element compatibility */
.sn-elem-compat {
    text-align: center;
}

.sn-elem-punt {
    font-size: 2.5rem;
    font-weight: 800;
    color: #10b981;
    margin-bottom: 0.5rem;
}

.sn-elem-pct {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.5);
}

.sn-elem-desc {
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.7;
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.sn-elem-consejo {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    font-style: italic;
    background: rgba(16, 185, 129, 0.06);
    border-radius: 8px;
    padding: 0.6rem 1rem;
}

/* Overall advice */
.sn-consejo-general {
    background: rgba(236, 72, 153, 0.05);
    border: 1px solid rgba(236, 72, 153, 0.15);
    border-radius: var(--sn-radio);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    animation: snSlideIn 0.6s ease both;
}

.sn-consejo-texto {
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.8;
    font-size: 1rem;
}

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

.sn-btn-nueva:hover {
    background: rgba(236, 72, 153, 0.15);
    border-color: var(--sn-rosa);
    transform: translateY(-2px);
}

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

.sn-app::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle at 30% 40%, rgba(236, 72, 153, 0.06) 0%, transparent 50%),
                radial-gradient(circle at 70% 30%, rgba(244, 114, 182, 0.04) 0%, transparent 50%),
                radial-gradient(circle at 50% 80%, rgba(245, 158, 11, 0.03) 0%, transparent 50%);
    animation: snFondo 25s linear infinite;
    pointer-events: none;
    z-index: 0;
}

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

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

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

@media (max-width: 768px) {
    .sn-titulo-form { font-size: 1.6rem; }
    .sn-icono-oraculo { font-size: 3rem; }
    .sn-dual-form { flex-direction: column; }
    .sn-separador { padding-top: 0; transform: rotate(90deg); }
    .sn-dual-perfil { grid-template-columns: 1fr; gap: 0.5rem; }
    .sn-perfil-conector { display: none; }
}

@media (max-width: 480px) {
    .sn-form-contenido { padding: 1.5rem 0.5rem; }
    .sn-titulo-form { font-size: 1.4rem; }
    .sn-subtitulo-form { font-size: 0.85rem; }
    .sn-form-campos { grid-template-columns: 1fr 1fr 1fr; gap: 0.4rem; }
    .sn-resultado-contenido { padding: 1.5rem 0.5rem; }
    .sn-seccion { padding: 1.2rem; }
    .sn-btn-nueva { padding: 0.8rem 1.5rem; font-size: 0.9rem; }
    .sn-btn-calcular { padding: 0.8rem 1.8rem; font-size: 0.9rem; }
    .sn-pct { font-size: 2.5rem; }
    .sn-elem-punt { font-size: 2rem; }
    .sn-perfil-signo { font-size: 2rem; }
}

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

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

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

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