
/* =========================================
   DANDADAN — UNIVERSO SOBRENATURAL
   Cumpleaños de Vanesa
   ========================================= */

:root {
    --dd-bg: #100b20;
    --dd-bg-light: #1b1235;
    --dd-pink: #ff65c5;
    --dd-pink-light: #ffc1eb;
    --dd-purple: #a47aff;
    --dd-blue: #64d9ff;
    --dd-white: #fff8ff;
    --dd-muted: #c0b4d8;
}

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

html {
    min-height: 100%;
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    min-height: 100svh;
    overflow-x: hidden;

    color: var(--dd-white);
    background: var(--dd-bg);
    font-family: "Segoe UI", sans-serif;
}

.dandadan-page {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-height: 100svh;
    overflow: hidden;
    isolation: isolate;
}

.dandadan-page::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -3;
    pointer-events: none;

    background:
        radial-gradient(ellipse at 50% 35%, rgba(105, 48, 170, 0.17), transparent 48%),
        radial-gradient(circle at 10% 20%, rgba(255, 101, 197, 0.09), transparent 32%),
        linear-gradient(140deg, rgba(9, 6, 21, 0.52), rgba(20, 10, 38, 0.57));
}

/* Fondo decorativo */

.dd-background {
    position: absolute;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.dd-grid {
    position: absolute;
    inset: 0;
    opacity: 0.10;

    background-image:
        linear-gradient(
            rgba(164, 122, 255, 0.35) 1px,
            transparent 1px
        ),
        linear-gradient(
            90deg,
            rgba(164, 122, 255, 0.35) 1px,
            transparent 1px
        );

    background-size: 52px 52px;

    mask-image: linear-gradient(
        to bottom,
        transparent,
        black 20%,
        black 75%,
        transparent
    );
}

.dd-orb {
    position: absolute;
    width: 300px;
    aspect-ratio: 1;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.18;
    animation: orb-pulse 7s ease-in-out infinite;
}

.orb-one {
    top: 15%;
    left: -150px;
    background: var(--dd-pink);
}

.orb-two {
    right: -150px;
    bottom: 12%;
    background: var(--dd-blue);
    animation-delay: -3.5s;
}

.dd-symbol {
    position: absolute;
    color: var(--dd-purple);
    font-size: 1.8rem;
    opacity: 0.8;
    animation: symbol-float 5s ease-in-out infinite;
}

.symbol-one {
    top: 18%;
    left: 12%;
}

.symbol-two {
    top: 35%;
    right: 10%;
    color: var(--dd-pink);
    animation-delay: -2s;
}

.symbol-three {
    bottom: 19%;
    left: 8%;
    color: var(--dd-blue);
    animation-delay: -1s;
}

.symbol-four {
    bottom: 28%;
    right: 13%;
    animation-delay: -3s;
}

.dd-sticker {
    position: absolute;
    font-size: clamp(1.6rem, 4vw, 2.7rem);
    opacity: 0.75;
    animation: sticker-float 6s ease-in-out infinite;
}

.sticker-one {
    top: 27%;
    left: 5%;
}

.sticker-two {
    top: 13%;
    right: 19%;
    animation-delay: -2s;
}

.sticker-three {
    bottom: 23%;
    right: 6%;
    animation-delay: -4s;
}

.sticker-four {
    bottom: 12%;
    left: 20%;
    animation-delay: -1s;
}

/* Cabecera */

.dd-header {
    position: relative;
    z-index: 3;

    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;

    width: min(100%, 1300px);
    margin: 0 auto;
    padding: 26px 32px;
}

.dd-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    justify-self: start;

    color: var(--dd-muted);
    font-size: 0.83rem;
    text-decoration: none;

    transition: color 0.2s ease;
}

.dd-back:hover {
    color: var(--dd-pink);
}

.dd-back span {
    font-size: 1.2rem;
}

.dd-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    color: var(--dd-muted);
    font-size: 0.60rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-align: center;
}

.brand-dot {
    width: 5px;
    height: 5px;
    flex: 0 0 auto;

    background: var(--dd-pink);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--dd-pink);
}

.dd-chapter {
    justify-self: end;
    color: var(--dd-muted);
    font-size: 0.75rem;
    letter-spacing: 0.08em;
}

/* Contenido */

.dd-content {
    position: relative;
    z-index: 2;

    display: flex;
    flex-direction: column;
    align-items: center;

    width: min(100% - 32px, 820px);
    margin: 0 auto;
    padding: 27px 0 48px;

    text-align: center;

    animation: content-enter 0.9s ease both;
}

.dd-kicker {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;

    color: var(--dd-blue);
    font-size: 0.64rem;
    font-weight: 700;
    letter-spacing: 0.18em;
}

.kicker-line {
    width: 30px;
    height: 1px;
    background: currentColor;
    opacity: 0.65;
}

/* Título */

.dd-title {
    display: flex;
    flex-direction: column;
    align-items: center;

    margin-top: 22px;
    line-height: 1;
}

.title-small {
    margin-bottom: 12px;

    color: var(--dd-muted);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.30em;
}

.title-main {
    color: var(--dd-white);
    font-family: Impact, "Arial Black", sans-serif;
    font-size: clamp(3.4rem, 11vw, 7.4rem);
    font-weight: 900;
    letter-spacing: -0.035em;

    text-shadow:
        3px 3px 0 var(--dd-pink),
        -2px -2px 0 rgba(100, 217, 255, 0.65),
        0 0 35px rgba(255, 101, 197, 0.25);
}

.title-sub {
    margin-top: 12px;

    color: var(--dd-pink);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.48em;
    text-indent: 0.48em;
}

/* Escena central */

.dd-artwork {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: center;

    width: min(100%, 490px);
    height: 245px;
    margin: 8px auto 0;
}

.art-ring {
    position: absolute;
    aspect-ratio: 1;
    border-radius: 50%;
    pointer-events: none;
}

.ring-one {
    width: 200px;
    border: 1px solid rgba(255, 101, 197, 0.48);
    box-shadow:
        0 0 25px rgba(255, 101, 197, 0.08),
        inset 0 0 25px rgba(255, 101, 197, 0.05);

    animation: ring-rotate 16s linear infinite;
}

.ring-two {
    width: 155px;
    border: 1px dashed rgba(100, 217, 255, 0.55);
    animation: ring-rotate 22s linear infinite reverse;
}

.art-center {
    position: relative;
    z-index: 2;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    width: 150px;
    height: 150px;
}

.art-glow {
    position: absolute;
    inset: 10px;

    background: linear-gradient(
        135deg,
        rgba(255, 101, 197, 0.35),
        rgba(100, 217, 255, 0.24)
    );

    border-radius: 50%;
    filter: blur(25px);
}

.art-alien {
    position: relative;
    font-size: 5.7rem;
    filter: drop-shadow(0 0 18px rgba(100, 217, 255, 0.30));

    animation: alien-hover 3.5s ease-in-out infinite;
}

.art-caption {
    position: relative;
    margin-top: 9px;

    color: var(--dd-blue);
    font-size: 0.48rem;
    font-weight: 800;
    letter-spacing: 0.18em;
}

.art-character {
    position: absolute;
    z-index: 3;
    font-size: 3.1rem;
    filter: drop-shadow(0 0 14px rgba(164, 122, 255, 0.25));

    animation: character-hover 4s ease-in-out infinite;
}

.character-left {
    left: 7%;
    top: 28%;
}

.character-right {
    right: 7%;
    bottom: 23%;
    animation-delay: -2s;
}

.art-star,
.art-spark {
    position: absolute;
    color: var(--dd-pink);
    font-size: 1.5rem;
    animation: sparkle 3s ease-in-out infinite;
}

.star-left {
    top: 19%;
    left: 25%;
}

.star-right {
    top: 17%;
    right: 24%;
    color: var(--dd-blue);
    animation-delay: -1.5s;
}

.spark-one {
    left: 17%;
    bottom: 18%;
}

.spark-two {
    right: 18%;
    top: 42%;
    color: var(--dd-blue);
    animation-delay: -1s;
}

.spark-three {
    bottom: 12%;
    right: 33%;
    animation-delay: -2s;
}

/* Mensaje */

.dd-message {
    position: relative;
    width: min(100%, 590px);

    margin-top: 8px;
    padding: 28px clamp(20px, 5vw, 42px) 27px;

    background: linear-gradient(
        145deg,
        rgba(37, 24, 60, 0.83),
        rgba(21, 15, 39, 0.92)
    );

    border: 1px solid rgba(164, 122, 255, 0.28);
    border-radius: 20px;

    box-shadow:
        0 15px 50px rgba(0, 0, 0, 0.20),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.message-label {
    margin-bottom: 14px;

    color: var(--dd-blue);
    font-size: 0.59rem;
    font-weight: 800;
    letter-spacing: 0.23em;
}

.dd-message h2 {
    color: var(--dd-white);
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1.6rem, 4.5vw, 2.3rem);
    font-weight: 400;
    line-height: 1.35;
    text-wrap: balance;
}

.dd-message h2 span {
    display: block;
    color: var(--dd-pink);
    font-style: italic;
}

.message-body {
    max-width: 450px;
    margin: 17px auto 0;

    color: var(--dd-muted);
    font-size: 0.92rem;
    line-height: 1.9;
    text-wrap: pretty;
}

.dd-signature {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;

    margin-top: 23px;

    color: var(--dd-pink-light);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 0.95rem;
    font-style: italic;
}

.dd-signature span {
    color: var(--dd-blue);
    font-size: 0.8rem;
}

/* Navegación */

.dd-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 17px;

    margin-top: 29px;
}

.next-hint {
    color: var(--dd-muted);
    font-size: 0.61rem;
    font-weight: 700;
    letter-spacing: 0.17em;
}

.dd-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 15px;

    min-height: 53px;
    padding: 15px 27px;

    color: var(--dd-white);
    background: linear-gradient(
        110deg,
        #a12d82,
        #7049be
    );

    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 999px;

    box-shadow: 0 9px 30px rgba(161, 45, 130, 0.23);

    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        filter 0.25s ease;
}

.button-arrow {
    font-size: 1.15rem;
    transition: transform 0.25s ease;
}

.dd-button:hover {
    transform: translateY(-3px);
    filter: brightness(1.15);
    box-shadow: 0 13px 35px rgba(161, 45, 130, 0.35);
}

.dd-button:hover .button-arrow {
    transform: translate(3px, -3px);
}

.dd-button:focus-visible,
.dd-back:focus-visible {
    outline: 2px solid var(--dd-blue);
    outline-offset: 5px;
}

/* Pie de página */

.dd-footer {
    position: relative;
    z-index: 2;

    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;

    margin-top: auto;
    padding: 22px 15px;

    color: rgba(192, 180, 216, 0.65);
    font-size: 0.57rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-align: center;
}

.footer-cross {
    color: var(--dd-pink);
}

/* Animaciones */

@keyframes content-enter {
    from {
        opacity: 0;
        transform: translateY(22px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes orb-pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.13;
    }

    50% {
        transform: scale(1.2);
        opacity: 0.23;
    }
}

@keyframes symbol-float {
    0%, 100% {
        translate: 0 0;
        rotate: -8deg;
    }

    50% {
        translate: 0 -15px;
        rotate: 12deg;
    }
}

@keyframes sticker-float {
    0%, 100% {
        translate: 0 0;
        rotate: -5deg;
    }

    50% {
        translate: 0 -18px;
        rotate: 7deg;
    }
}

@keyframes ring-rotate {
    from {
        rotate: 0deg;
    }

    to {
        rotate: 360deg;
    }
}

@keyframes alien-hover {
    0%, 100% {
        translate: 0 0;
        rotate: -3deg;
    }

    50% {
        translate: 0 -10px;
        rotate: 3deg;
    }
}

@keyframes character-hover {
    0%, 100% {
        translate: 0 0;
    }

    50% {
        translate: 0 -12px;
    }
}

@keyframes sparkle {
    0%, 100% {
        opacity: 0.4;
        scale: 0.8;
    }

    50% {
        opacity: 1;
        scale: 1.2;
    }
}

/* Móviles */

@media (max-width: 600px) {
    .dd-header {
        grid-template-columns: 1fr auto;
        gap: 12px;
        padding: 20px 17px;
    }

    .dd-brand {
        display: none;
    }

    .dd-content {
        width: min(100% - 26px, 500px);
        padding-top: 29px;
        padding-bottom: 38px;
    }

    .dd-kicker {
        gap: 7px;
        font-size: 0.53rem;
        letter-spacing: 0.10em;
    }

    .kicker-line {
        width: 17px;
    }

    .title-main {
        font-size: clamp(3rem, 13vw, 5rem);
        letter-spacing: -0.045em;
    }

    .title-small {
        font-size: 0.55rem;
        letter-spacing: 0.22em;
    }

    .title-sub {
        font-size: 0.66rem;
        letter-spacing: 0.36em;
        text-indent: 0.36em;
    }

    .dd-artwork {
        height: 205px;
        margin-top: 8px;
    }

    .ring-one {
        width: 160px;
    }

    .ring-two {
        width: 125px;
    }

    .art-center {
        width: 125px;
        height: 125px;
    }

    .art-alien {
        font-size: 4.6rem;
    }

    .art-character {
        font-size: 2.4rem;
    }

    .character-left {
        left: 5%;
    }

    .character-right {
        right: 5%;
    }

    .dd-message {
        padding: 25px 20px;
        border-radius: 17px;
    }

    .message-body {
        font-size: 0.87rem;
        line-height: 1.85;
    }

    .dd-button {
        width: min(100%, 290px);
    }

    .next-hint {
        font-size: 0.54rem;
        letter-spacing: 0.11em;
        text-align: center;
    }

    .dd-sticker {
        opacity: 0.45;
    }

    .sticker-one {
        left: 1%;
    }

    .sticker-four {
        left: 5%;
    }

    .dd-footer {
        gap: 8px;
        font-size: 0.49rem;
        letter-spacing: 0.10em;
    }
}

/* Accesibilidad */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Transición al cambiar de universo */

.dd-content {
    transition:
        opacity 0.3s ease,
        transform 0.3s ease;
}

.dd-content.is-leaving {
    opacity: 0;
    transform: translateY(-10px);
}

body.page-leaving {
    pointer-events: none;
}
