/* ================================================
   NUMERO DEL CORAZON - APP STYLES
   ================================================ */

.nc-app {
    --nc-rosa: #ec4899;
    --nc-rosa-oscuro: #db2777;
    --nc-gradiente: linear-gradient(135deg, #ec4899 0%, #db2777 100%);
    --nc-sombra: 0 10px 30px rgba(236, 72, 153, 0.15);
    --nc-radio: 16px;
    --nc-transicion: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    position: relative;
    overflow: hidden;
}

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

.nc-fase {
    animation: ncFadeIn 0.6s ease;
}

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

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

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

@keyframes ncBrillar {
    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)); }
}

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

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

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

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

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

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

.nc-form-campo {
    max-width: 500px;
    margin: 0 auto 1.5rem;
    text-align: left;
}

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

.nc-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(236, 72, 153, 0.3);
    border-radius: 12px;
    padding: 0.9rem 1.2rem;
    color: #fff;
    font-family: inherit;
    font-size: 1.05rem;
    transition: var(--nc-transicion);
    box-sizing: border-box;
}

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

.nc-input::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

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

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

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

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

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

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

.nc-orbita-corazon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2.5rem;
    animation: ncLatido 1.5s ease-in-out infinite;
}

@keyframes ncLatido {
    0%, 100% { transform: translate(-50%, -50%) scale(1); }
    15% { transform: translate(-50%, -50%) scale(1.15); }
    30% { transform: translate(-50%, -50%) scale(1); }
    45% { transform: translate(-50%, -50%) scale(1.1); }
}

.nc-orbita-arc {
    position: absolute;
    top: 5px;
    left: 5px;
    width: 80px;
    height: 80px;
    border: 2px dashed rgba(236, 72, 153, 0.25);
    border-radius: 50%;
    animation: ncArcGiro 8s linear infinite;
}

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

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

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

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

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

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

.nc-nombre-badge {
    display: inline-block;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.8rem;
    background: rgba(236, 72, 153, 0.1);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    border: 1px solid rgba(236, 72, 153, 0.2);
}

.nc-num-grande {
    margin-bottom: 0.5rem;
}

.nc-num-grande-num {
    display: inline-block;
    font-size: 5rem;
    font-weight: 800;
    width: 100px;
    height: 100px;
    line-height: 100px;
    border-radius: 50%;
    text-align: center;
}

.nc-corazon-nombre {
    font-size: 1.3rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.3rem;
}

.nc-corazon-deseo {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
    line-height: 1.6;
}

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

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

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

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

.nc-titulo-significado { color: var(--nc-rosa); }

.nc-card-desc {
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.8;
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

/* Letters grid */
.nc-letras-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    margin-bottom: 1.2rem;
}

.nc-letra-item {
    text-align: center;
    min-width: 42px;
    padding: 0.5rem 0.4rem;
    border-radius: 10px;
    transition: var(--nc-transicion);
}

.nc-letra-item:hover {
    transform: translateY(-2px);
}

.nc-letra-vocal {
    background: rgba(236, 72, 153, 0.12);
    border: 1px solid rgba(236, 72, 153, 0.3);
}

.nc-letra-consonante {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.nc-letra-char {
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.15rem;
}

.nc-letra-vocal .nc-letra-char {
    color: var(--nc-rosa);
}

.nc-letra-valor {
    font-size: 0.75rem;
    font-weight: 600;
}

.nc-letra-vocal .nc-letra-valor {
    color: rgba(236, 72, 153, 0.8);
}

.nc-letra-consonante .nc-letra-valor {
    color: rgba(255, 255, 255, 0.4);
}

/* Sum row */
.nc-suma-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    flex-wrap: wrap;
    padding: 1rem;
    background: rgba(236, 72, 153, 0.05);
    border-radius: 12px;
    border: 1px solid rgba(236, 72, 153, 0.15);
}

.nc-suma-label {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

.nc-suma-valor {
    color: #fff;
    font-weight: 700;
    font-size: 1.1rem;
}

.nc-suma-arrow {
    color: var(--nc-rosa);
    font-size: 1.2rem;
}

.nc-suma-resultado {
    display: inline-block;
    font-weight: 800;
    font-size: 1.4rem;
    padding: 0.3rem 1rem;
    border-radius: 20px;
}

/* Desire box */
.nc-deseo-box {
    background: rgba(236, 72, 153, 0.08);
    border: 1px solid rgba(236, 72, 153, 0.2);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1rem;
    text-align: center;
}

.nc-deseo-label {
    display: block;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    margin-bottom: 0.3rem;
}

.nc-deseo-text {
    color: #fff;
    font-weight: 600;
    font-size: 1.05rem;
}

/* Traits */
.nc-rasgos-dual {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.nc-rasgos-col {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 1rem;
}

.nc-actividades {
    border: 1px solid rgba(16, 185, 129, 0.15);
}

.nc-evitar {
    border: 1px solid rgba(239, 68, 68, 0.15);
}

.nc-rasgos-label {
    font-size: 0.95rem;
    margin-bottom: 0.6rem;
}

.nc-label-act { color: #10b981; }
.nc-label-ev { color: #f87171; }

.nc-rasgos-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.nc-rasgo-badge {
    font-size: 0.8rem;
    padding: 5px 12px;
    border-radius: 20px;
}

.nc-rasgo-ev {
    background: rgba(239, 68, 68, 0.12);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Comparison */
.nc-comparar-grid {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.nc-comparar-item {
    text-align: center;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 1.2rem;
    min-width: 140px;
}

.nc-comparar-corazon {
    border: 1px solid rgba(236, 72, 153, 0.2);
}

.nc-comparar-personalidad {
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.nc-comparar-icon {
    font-size: 1.8rem;
    margin-bottom: 0.3rem;
}

.nc-comparar-label {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
}

.nc-comparar-num {
    display: inline-block;
    font-size: 2rem;
    font-weight: 800;
    width: 55px;
    height: 55px;
    line-height: 55px;
    border-radius: 50%;
    margin-bottom: 0.3rem;
}

.nc-comparar-personalidad .nc-comparar-num {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.nc-comparar-desc {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.8rem;
}

.nc-comparar-vs {
    font-size: 1.2rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.3);
}

/* Advice */
.nc-consejo-general {
    background: rgba(236, 72, 153, 0.05);
    border: 1px solid rgba(236, 72, 153, 0.15);
    border-radius: var(--nc-radio);
    padding: 1.5rem;
    animation: ncSlideIn 0.6s ease both;
}

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

/* New consultation button */
.nc-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(--nc-transicion);
    font-family: inherit;
}

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

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

.nc-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(219, 39, 119, 0.04) 0%, transparent 50%),
                radial-gradient(circle at 50% 80%, rgba(244, 114, 182, 0.03) 0%, transparent 50%);
    animation: ncFondo 25s linear infinite;
    pointer-events: none;
    z-index: 0;
}

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

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

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

@media (max-width: 768px) {
    .nc-titulo-form { font-size: 1.6rem; }
    .nc-icono-oraculo { font-size: 3rem; }
    .nc-rasgos-dual { grid-template-columns: 1fr; }
    .nc-comparar-grid { gap: 1rem; }
}

@media (max-width: 480px) {
    .nc-form-contenido { padding: 1.5rem 0.5rem; }
    .nc-titulo-form { font-size: 1.4rem; }
    .nc-subtitulo-form { font-size: 0.85rem; }
    .nc-resultado-contenido { padding: 1.5rem 0.5rem; }
    .nc-seccion { padding: 1.2rem; }
    .nc-btn-nueva { padding: 0.8rem 1.5rem; font-size: 0.9rem; }
    .nc-btn-calcular { padding: 0.8rem 1.8rem; font-size: 0.9rem; }
    .nc-num-grande-num { font-size: 3.5rem; width: 80px; height: 80px; line-height: 80px; }
    .nc-letra-item { min-width: 36px; padding: 0.4rem 0.25rem; }
}

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

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

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

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