:root {
    color-scheme: dark;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #020c17;
    color: #effcff;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }

body {
    margin: 0;
    min-width: 320px;
    overflow-x: hidden;
    background: #020c17;
}

button { font: inherit; }

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

body.home-intro-active { overflow: hidden; }

.home-intro {
    position: fixed;
    z-index: 100000;
    inset: 0;
    overflow: hidden;
    isolation: isolate;
    background: #010813;
    opacity: 1;
    transition: opacity .42s ease, visibility .42s ease;
}

.home-intro.is-leaving {
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
}

.home-intro-video {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    background: #010813;
}

.home-intro-shade {
    position: absolute;
    z-index: 1;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(180deg, rgba(1, 8, 19, .5), transparent 24%, transparent 72%, rgba(1, 8, 19, .62)),
        radial-gradient(circle at 50% 50%, transparent 45%, rgba(1, 8, 19, .3) 100%);
}

.home-intro-bar {
    position: absolute;
    z-index: 2;
    top: clamp(16px, 3vw, 34px);
    right: clamp(16px, 3vw, 38px);
    left: clamp(16px, 3vw, 38px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.home-intro-brand {
    display: flex;
    align-items: center;
    gap: 11px;
    color: #f2fdff;
    text-shadow: 0 2px 18px #000;
}

.home-intro-brand img {
    width: 46px;
    height: 46px;
    border: 1px solid rgba(82, 226, 241, .45);
    border-radius: 50%;
    object-fit: contain;
    background: rgba(3, 20, 31, .72);
    box-shadow: 0 0 24px rgba(42, 217, 235, .18);
}

.home-intro-brand strong,
.home-intro-brand small { display: block; }
.home-intro-brand strong { font-size: .85rem; letter-spacing: .12em; }
.home-intro-brand small { margin-top: 3px; color: #9bd7df; font-size: .61rem; letter-spacing: .16em; text-transform: uppercase; }
.home-intro-actions { display: flex; align-items: center; gap: 9px; }

.home-intro-actions button {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 14px;
    border: 1px solid rgba(87, 221, 235, .4);
    border-radius: 999px;
    color: #dffbff;
    background: rgba(3, 22, 33, .7);
    box-shadow: 0 10px 30px rgba(0, 0, 0, .28), inset 0 1px rgba(255, 255, 255, .06);
    backdrop-filter: blur(14px);
    font-size: .75rem;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
    transition: transform .2s ease, border-color .2s ease, background .2s ease;
}

.home-intro-actions button:hover,
.home-intro-actions button:focus-visible {
    border-color: #5ee7f2;
    background: rgba(7, 52, 65, .88);
    outline: none;
    transform: translateY(-2px);
}

.home-intro-actions svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.home-intro-skip {
    color: #031820 !important;
    border-color: rgba(91, 240, 226, .76) !important;
    background: linear-gradient(135deg, #50e5df, #50cfe9) !important;
    box-shadow: 0 10px 32px rgba(40, 218, 226, .2) !important;
}

.home-intro-progress {
    position: absolute;
    z-index: 2;
    right: 0;
    bottom: 0;
    left: 0;
    height: 4px;
    background: rgba(255, 255, 255, .12);
}

.home-intro-progress i {
    display: block;
    width: 0;
    height: 100%;
    border-radius: 0 99px 99px 0;
    background: linear-gradient(90deg, #22e3db, #4ad6f4);
    box-shadow: 0 0 16px rgba(53, 224, 235, .72);
    transition: width .12s linear;
}

.brand-stage {
    position: relative;
    isolation: isolate;
    display: flex;
    width: 100%;
    max-width: 100%;
    min-height: 100svh;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    overflow: hidden;
    padding: 32px 48px 40px;
    border: 1px solid rgba(43, 219, 224, .44);
    border-radius: 30px;
    background:
        linear-gradient(180deg, rgba(1, 14, 29, .16), rgba(1, 14, 29, .48)),
        radial-gradient(circle at 50% 38%, rgba(18, 160, 190, .13), transparent 42%),
        url('/imagenes/fondoEstelar.png') center center / cover no-repeat;
    box-shadow: inset 0 1px 0 rgba(69, 226, 237, .14);
}

.brand-stage::before,
.brand-stage::after {
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    content: "";
    filter: blur(12px);
    pointer-events: none;
}

.brand-stage::before { top: -190px; left: -90px; background: rgba(24, 218, 215, .11); }
.brand-stage::after { right: -170px; bottom: -180px; background: rgba(0, 142, 204, .13); }

.brand-aura {
    position: absolute;
    z-index: -1;
    top: 42%;
    left: 50%;
    width: min(560px, 72vw);
    aspect-ratio: 1;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, rgba(18, 191, 217, .17), rgba(12, 91, 119, .07) 39%, transparent 68%);
    filter: blur(5px);
    animation: aura-pulse 4.8s ease-in-out infinite;
}

.brand-heading {
    position: absolute;
    z-index: 3;
    top: clamp(25px, 5vh, 46px);
    left: clamp(25px, 5vw, 66px);
    text-align: left;
}

.brand-heading span {
    display: block;
    margin-bottom: 7px;
    color: #41e6e2;
    font-size: .66rem;
    font-weight: 900;
    letter-spacing: .27em;
}

.brand-heading h1 {
    margin: 0;
    color: #f3fcff;
    font-size: clamp(1.28rem, 2.35vw, 2.15rem);
    font-weight: 900;
    letter-spacing: .045em;
    line-height: 1;
    text-transform: uppercase;
    text-shadow: 0 0 22px rgba(50, 220, 238, .28);
}

.brand-heading h1::after {
    display: block;
    width: 64px;
    height: 3px;
    margin-top: 13px;
    border-radius: 999px;
    background: linear-gradient(90deg, #32e3df, rgba(50, 227, 223, 0));
    box-shadow: 0 0 12px rgba(50, 227, 223, .46);
    content: "";
}

.brand-heading p {
    max-width: 390px;
    margin: 13px 0 0;
    color: #a8c8d3;
    font-size: clamp(.76rem, 1.05vw, .9rem);
    font-weight: 500;
    line-height: 1.55;
    text-wrap: balance;
}

.brand-logo {
    position: relative;
    z-index: 1;
    display: grid;
    width: 100%;
    min-width: 0;
    place-items: center;
    margin: -34px 0 -54px;
}

.brand-logo img {
    display: block;
    width: clamp(330px, 39vw, 500px);
    max-width: 100%;
    aspect-ratio: 1;
    object-fit: contain;
    filter: drop-shadow(0 0 28px rgba(17, 194, 235, .35));
    animation: logo-heartbeat 4.8s ease-in-out infinite;
    will-change: transform, filter;
}

.brand-actions {
    position: relative;
    z-index: 2;
    display: grid;
    width: min(900px, 100%);
    min-width: 0;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-top: 30px;
}

.brand-action {
    display: grid;
    min-width: 0;
    min-height: 88px;
    grid-template-columns: 48px minmax(0, 1fr);
    grid-template-rows: auto auto;
    column-gap: 12px;
    align-items: center;
    padding: 14px 15px;
    border: 1px solid rgba(66, 201, 215, .28);
    border-radius: 18px;
    color: #def9fb;
    background: linear-gradient(145deg, rgba(19, 58, 72, .94), rgba(10, 39, 52, .91));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05), 0 14px 26px rgba(0, 0, 0, .2);
    text-align: left;
    cursor: pointer;
    transition: transform .22s ease, border-color .22s ease, background .22s ease, box-shadow .22s ease;
}

.brand-action-icon {
    grid-row: 1 / 3;
    display: grid;
    width: 48px;
    height: 48px;
    place-items: center;
    border: 1px solid rgba(43, 222, 225, .46);
    border-radius: 15px;
    color: #3ce4e1;
    background: rgba(4, 58, 72, .84);
    box-shadow: 0 0 18px rgba(32, 211, 218, .12);
}

.brand-action:nth-child(2) .brand-action-icon { color: #57edbd; border-color: rgba(63, 224, 168, .42); background: rgba(6, 67, 64, .82); }
.brand-action:nth-child(3) .brand-action-icon { color: #c1a2ff; border-color: rgba(164, 127, 240, .44); background: rgba(47, 43, 79, .8); }
.brand-action:nth-child(4) .brand-action-icon { color: #52d9f2; }

.brand-action svg {
    width: 23px;
    height: 23px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.brand-action strong { align-self: end; overflow-wrap: anywhere; color: #f1fbfc; font-size: .84rem; letter-spacing: .02em; text-transform: uppercase; }
.brand-action small { align-self: start; overflow: hidden; overflow-wrap: anywhere; color: #88abb8; font-size: .67rem; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }

.brand-action:hover,
.brand-action:focus-visible {
    transform: translateY(-4px);
    border-color: rgba(48, 225, 222, .68);
    background: linear-gradient(145deg, rgba(19, 73, 83, .98), rgba(9, 47, 59, .96));
    box-shadow: 0 16px 32px rgba(0, 0, 0, .24), 0 0 22px rgba(30, 211, 215, .12);
    outline: none;
}

.info-dialog {
    width: min(520px, calc(100% - 30px));
    padding: 0;
    border: 1px solid rgba(58, 218, 225, .38);
    border-radius: 22px;
    color: #eefcff;
    background: linear-gradient(145deg, #0d2a37, #071a25);
    box-shadow: 0 28px 90px rgba(0, 0, 0, .62), 0 0 32px rgba(30, 211, 215, .12);
}

.info-dialog::backdrop { background: rgba(0, 8, 16, .75); backdrop-filter: blur(8px); }
.info-dialog-card { position: relative; padding: 34px; }
.info-dialog-kicker { color: #42e1dd; font-size: .66rem; font-weight: 900; letter-spacing: .23em; }
.info-dialog h2 { margin: 9px 38px 12px 0; font-size: clamp(1.35rem, 4vw, 1.8rem); }
.info-dialog p { margin: 0; color: #a8c8d3; line-height: 1.7; }
.info-dialog-close { position: absolute; top: 16px; right: 17px; width: 38px; height: 38px; border: 1px solid rgba(74, 211, 221, .3); border-radius: 12px; color: #d9fbff; background: rgba(6, 36, 48, .72); font-size: 1.45rem; cursor: pointer; }
.info-dialog-confirm { margin-top: 24px; padding: 11px 20px; border: 0; border-radius: 12px; color: #04191d; background: linear-gradient(135deg, #35e1d8, #5eddf1); font-weight: 900; cursor: pointer; }
.info-dialog-close:focus-visible, .info-dialog-confirm:focus-visible { outline: 2px solid #78f6f2; outline-offset: 3px; }

@keyframes logo-heartbeat {
    0%, 100% { transform: translateY(0) rotate(-.7deg) scale(1); filter: drop-shadow(0 0 28px rgba(17, 194, 235, .34)); }
    50% { transform: translateY(-13px) rotate(.8deg) scale(1.025); filter: drop-shadow(0 0 42px rgba(25, 214, 240, .52)); }
}

@keyframes aura-pulse {
    0%, 100% { opacity: .72; transform: translate(-50%, -50%) scale(.92); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.08); }
}

@media (max-width: 900px) {
    .brand-stage { justify-content: flex-start; min-height: 100svh; padding: 120px 34px 34px; }
    .brand-logo { margin: -28px 0 -50px; }
    .brand-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 650px; margin-top: 28px; }
}

@media (max-width: 600px) {
    .home-intro-video {
        object-fit: contain;
        object-position: center;
    }
    .home-intro-bar { align-items: flex-start; }
    .home-intro-brand span { display: none; }
    .home-intro-brand img { width: 40px; height: 40px; }
    .home-intro-actions button { min-height: 40px; padding: 8px 12px; }
    .home-intro-sound span { display: none; }
    .brand-stage { gap: 8px; padding: 172px 18px 24px; border-radius: 0; }
    .brand-heading { top: 28px; right: 24px; left: 24px; text-align: center; }
    .brand-heading h1::after { margin-right: auto; margin-left: auto; }
    .brand-heading p { max-width: 430px; margin-right: auto; margin-left: auto; }
    .brand-logo { margin: -18px 0 -40px; }
    .brand-logo img { width: min(94vw, 360px); }
    .brand-actions { gap: 9px; margin-top: 20px; }
    .brand-action { min-height: 78px; grid-template-columns: 40px minmax(0, 1fr); column-gap: 9px; padding: 10px; border-radius: 15px; }
    .brand-action-icon { width: 40px; height: 40px; border-radius: 13px; }
    .brand-action svg { width: 20px; height: 20px; }
    .brand-action strong { font-size: .72rem; }
    .brand-action small { font-size: .59rem; white-space: normal; }
    .info-dialog-card { padding: 30px 23px 24px; }
}

@media (orientation: portrait) {
    .home-intro-video {
        object-fit: contain;
        object-position: center;
    }
}

@media (max-width: 390px) {
    .brand-logo { margin-bottom: -34px; }
}

@media (prefers-reduced-motion: reduce) {
    .home-intro,
    .home-intro-progress i { transition: none; }
    .brand-aura, .brand-logo img { animation: none; }
    .brand-action { transition: none; }
}
