@import url("https://fonts.googleapis.com/css2?family=Fira+Sans:wght@300;400;500;600;700&display=swap");

body {
    position: relative;
    isolation: isolate;
    overflow-x: hidden;
    margin: 0;
    font-family: "Fira Sans", sans-serif;
    font-weight: 500;
    background: #d8c6f4;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 2rem;
    text-align: center;
    box-sizing: border-box;
}

body::before,
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
}

/* Base mesh gradient */
body::before {
    z-index: -2;
    background:
        radial-gradient(circle at 8% 12%, rgba(214, 125, 255, 0.7), transparent 38%),
        radial-gradient(circle at 90% 82%, rgba(121, 169, 255, 0.65), transparent 42%),
        radial-gradient(circle at 70% 10%, rgba(180, 140, 255, 0.45), transparent 34%),
        radial-gradient(circle at 20% 90%, rgba(150, 190, 255, 0.45), transparent 36%),
        linear-gradient(135deg, #e8cfff 0%, #c6b8f5 48%, #d7e2ff 100%);
    filter: saturate(115%);
    animation: background-drift 18s ease-in-out infinite alternate;
}

/* Light sweep + vignette (top layer of the background stack) */
body::after {
    z-index: -1;
    background:
        linear-gradient(115deg, transparent 20%, rgba(255, 255, 255, 0.16) 45%, transparent 70%),
        radial-gradient(ellipse at center, transparent 42%, rgba(76, 29, 149, 0.16) 100%);
    background-size: 180% 180%, 100% 100%;
    animation: light-sweep 16s ease-in-out infinite alternate;
}

body > * {
    position: relative;
    z-index: 1;
}

/* ---------- Background layer stack ---------- */

body > .ambient-background,
body > .ambient-aurora,
body > .ambient-canvas,
body > .ambient-spotlight,
body > .ambient-grain {
    position: fixed;
    z-index: -1;
    pointer-events: none;
}

.ambient-background {
    inset: -18%;
    overflow: hidden;
    filter: blur(36px) saturate(112%);
    opacity: 0.62;
}

.ambient-orb {
    --orb-x: 0px;
    --orb-y: 0px;
    --orb-sx: 1;
    --orb-sy: 1;
    position: absolute;
    width: 32vw;
    height: 32vw;
    min-width: 18rem;
    min-height: 18rem;
    border-radius: 48% 52% 64% 36% / 42% 38% 62% 58%;
    transform: translate3d(var(--orb-x), var(--orb-y), 0) scale(var(--orb-sx), var(--orb-sy));
    animation: orb-morph 14s ease-in-out infinite alternate,
               orb-float 22s ease-in-out infinite alternate;
    will-change: transform, border-radius;
}

/* Large base orbs */
.ambient-orb--pink {
    top: -12%;
    left: -8%;
    width: 38vw;
    height: 38vw;
    background: radial-gradient(circle at 40% 40%, rgba(232, 125, 255, 0.5), rgba(224, 106, 255, 0.22) 68%, rgba(224, 106, 255, 0.1));
}

.ambient-orb--blue {
    right: -12%;
    bottom: -18%;
    width: 38vw;
    height: 38vw;
    background: radial-gradient(circle at 40% 40%, rgba(110, 170, 255, 0.5), rgba(91, 157, 255, 0.22) 68%, rgba(91, 157, 255, 0.1));
    animation-delay: -5s;
}

.ambient-orb--violet {
    top: 28%;
    left: 36%;
    width: 28vw;
    height: 28vw;
    background: radial-gradient(circle at 40% 40%, rgba(170, 130, 255, 0.45), rgba(157, 113, 255, 0.2) 68%, rgba(157, 113, 255, 0.08));
    animation-delay: -9s;
}

.ambient-orb--rose {
    top: 52%;
    left: -10%;
    width: 26vw;
    height: 26vw;
    background: radial-gradient(circle at 40% 40%, rgba(245, 155, 255, 0.42), rgba(240, 150, 255, 0.18) 68%, rgba(240, 150, 255, 0.08));
    animation-delay: -3s, -11s;
}

.ambient-orb--sky {
    top: -10%;
    right: 6%;
    width: 24vw;
    height: 24vw;
    background: radial-gradient(circle at 40% 40%, rgba(150, 200, 255, 0.45), rgba(130, 185, 255, 0.2) 68%, rgba(130, 185, 255, 0.08));
    animation-delay: -7s, -4s;
}

/* Extra orbs that fill the gaps so the whole page has soft colour */
.ambient-orb--lilac {
    top: 4%;
    left: 30%;
    width: 22vw;
    height: 22vw;
    background: radial-gradient(circle at 40% 40%, rgba(200, 160, 255, 0.45), rgba(190, 150, 255, 0.2) 68%, rgba(190, 150, 255, 0.08));
    animation-delay: -2s, -8s;
}

.ambient-orb--periwinkle {
    bottom: 4%;
    left: 16%;
    width: 28vw;
    height: 28vw;
    background: radial-gradient(circle at 40% 40%, rgba(130, 150, 255, 0.45), rgba(120, 140, 255, 0.2) 68%, rgba(120, 140, 255, 0.08));
    animation-delay: -6s, -13s;
}

.ambient-orb--magenta {
    top: 38%;
    right: -6%;
    width: 24vw;
    height: 24vw;
    background: radial-gradient(circle at 40% 40%, rgba(235, 120, 255, 0.42), rgba(224, 106, 255, 0.18) 68%, rgba(224, 106, 255, 0.07));
    animation-delay: -10s, -2s;
}

.ambient-orb--ice {
    bottom: -8%;
    left: 52%;
    width: 22vw;
    height: 22vw;
    background: radial-gradient(circle at 40% 40%, rgba(170, 215, 255, 0.45), rgba(150, 200, 255, 0.2) 68%, rgba(150, 200, 255, 0.08));
    animation-delay: -1s, -9s;
}

.ambient-orb--blush {
    top: 16%;
    left: 56%;
    width: 16vw;
    height: 16vw;
    min-width: 12rem;
    min-height: 12rem;
    background: radial-gradient(circle at 40% 40%, rgba(250, 170, 255, 0.4), rgba(240, 150, 255, 0.16) 68%, rgba(240, 150, 255, 0.06));
    animation-delay: -12s, -6s;
}

.ambient-orb--cobalt {
    top: 62%;
    left: 30%;
    width: 18vw;
    height: 18vw;
    min-width: 13rem;
    min-height: 13rem;
    background: radial-gradient(circle at 40% 40%, rgba(110, 160, 255, 0.42), rgba(91, 157, 255, 0.16) 68%, rgba(91, 157, 255, 0.06));
    animation-delay: -4s, -15s;
}

/* Slowly rotating aurora ribbons */
.ambient-aurora {
    inset: -35%;
    background: conic-gradient(
        from 0deg at 50% 50%,
        rgba(224, 106, 255, 0) 0%,
        rgba(224, 106, 255, 0.55) 12%,
        rgba(91, 157, 255, 0) 28%,
        rgba(157, 113, 255, 0.5) 44%,
        rgba(91, 157, 255, 0.55) 62%,
        rgba(224, 106, 255, 0) 78%,
        rgba(157, 113, 255, 0.4) 90%,
        rgba(224, 106, 255, 0) 100%
    );
    filter: blur(60px) saturate(150%);
    opacity: 0.5;
    mix-blend-mode: soft-light;
    translate: var(--aurora-x, 0px) var(--aurora-y, 0px);
    animation: aurora-spin 48s linear infinite;
}

/* Interactive constellation layer */
.ambient-canvas {
    inset: 0;
    width: 100%;
    height: 100%;
}

/* Soft glow that eases after the cursor */
.ambient-spotlight {
    inset: 0;
    background: radial-gradient(
        520px circle at var(--mx, 50%) var(--my, 30%),
        rgba(255, 255, 255, 0.16),
        rgba(236, 200, 255, 0.07) 40%,
        transparent 70%
    );
    mix-blend-mode: soft-light;
}

/* Fine film grain to remove gradient banding and add depth */
.ambient-grain {
    inset: 0;
    opacity: 0.16;
    mix-blend-mode: soft-light;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='saturate' values='0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
    background-size: 180px 180px;
}

@keyframes background-drift {
    from {
        transform: scale(1) rotate(0deg);
    }
    to {
        transform: scale(1.08) rotate(2deg);
    }
}

@keyframes orb-morph {
    0% {
        border-radius: 48% 52% 64% 36% / 42% 38% 62% 58%;
        margin: 0;
    }
    50% {
        border-radius: 67% 33% 42% 58% / 58% 64% 36% 42%;
    }
    100% {
        border-radius: 38% 62% 54% 46% / 64% 42% 58% 36%;
        margin: 2rem -1rem;
    }
}

@keyframes orb-float {
    from {
        scale: 1;
        rotate: 0deg;
    }
    to {
        scale: 1.18;
        rotate: 24deg;
    }
}

@keyframes aurora-spin {
    from {
        transform: rotate(0deg) scale(1);
    }
    50% {
        transform: rotate(180deg) scale(1.12);
    }
    to {
        transform: rotate(360deg) scale(1);
    }
}

@keyframes light-sweep {
    from {
        background-position: 0% 50%, center;
    }
    to {
        background-position: 100% 50%, center;
    }
}

/* ---------- Content ---------- */

::selection {
    background: rgba(167, 120, 255, 0.35);
    color: #2e1065;
}

h1 {
    font-size: clamp(3rem, 10vw, 7rem);
    font-weight: bold;
    color: #2e1065;
    margin: 0 0 1rem 0;
    cursor: default;
    text-shadow: 0 2px 4px rgba(76, 29, 149, 0.12),
                 0 8px 28px rgba(139, 92, 246, 0.22);
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1),
                text-shadow 0.4s ease,
                color 0.4s ease;
}

h1:hover {
    color: #3b1478;
    transform: translateY(-3px) scale(1.015);
    text-shadow: 0 3px 6px rgba(76, 29, 149, 0.16),
                 0 14px 42px rgba(167, 100, 255, 0.42);
}

p.intro {
    max-width: 700px;
    font-size: clamp(1.1rem, 3.5vw, 2rem);
    color: #4c1d95;
    margin-top: 1rem;
    margin-bottom: 3.5rem;
    line-height: 1.7;
    text-shadow: 0 1px 8px rgba(124, 58, 237, 0.2),
                 0 3px 14px rgba(139, 92, 246, 0.16);
}

@media (prefers-reduced-motion: reduce) {
    h1 {
        transition: none;
    }

    h1:hover {
        transform: none;
    }
}

.holder {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Liquid glass effect for all buttons */
.button,
.social-button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    height: 4rem;
    min-width: 4rem;
    padding: 0 1.5rem;
    font-size: 1.5rem;
    background: rgba(255, 255, 255, 0.28);
    color: #3b0764;
    border: 1px solid rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(18px) saturate(180%);
    -webkit-backdrop-filter: blur(18px) saturate(180%);
    box-shadow: 0 8px 32px rgba(139, 92, 246, 0.22),
                inset 0 1px 0 rgba(255, 255, 255, 0.7),
                inset 0 -1px 0 rgba(139, 92, 246, 0.15);
    transition: background 0.25s, transform 0.25s, box-shadow 0.25s;
    font-family: "Fira Sans", sans-serif;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
}

/* Main button roundness */
.button {
    border-radius: 2rem;
}

/* Row holding the Map24 and PFStrip call-to-action buttons */
.button-row {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.75rem;
}

/* Call-to-action buttons (Map24, PFStrip) */
.cta-button {
    position: relative;
    overflow: hidden;
    gap: 0.75rem;
    padding: 0 2.25rem;
}

.cta-button::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.55) 50%, transparent 70%);
    transform: translateX(-120%);
    transition: transform 0.7s ease;
    pointer-events: none;
}

.cta-button:hover::after {
    transform: translateX(120%);
}

.cta-button__icon {
    display: inline-block;
    transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.cta-button:hover .cta-button__icon {
    transform: translate(4px, -4px) rotate(8deg);
}

/* Social buttons */
.social-button {
    width: 4rem;
    border-radius: 50%;
    padding: 0;
}

.social-button img,
.social-button svg {
    width: 50%;
    height: 50%;
}

/* Hover effects */
.button:hover,
.social-button:hover {
    background: rgba(255, 255, 255, 0.5);
    box-shadow: 0 12px 40px rgba(139, 92, 246, 0.35),
                inset 0 1px 0 rgba(255, 255, 255, 0.9),
                inset 0 -1px 0 rgba(139, 92, 246, 0.2);
    transform: translateY(-3px);
}

/* Responsive for smaller screens */
@media (max-width: 600px) {
    .social-button {
        height: 3.5rem;
        width: 3.5rem;
    }

    .cta-button {
        height: 3.5rem;
        font-size: 1.25rem;
        padding: 0 1.75rem;
    }

    .ambient-aurora {
        filter: blur(50px) saturate(130%);
    }
}

/* Note: the background animations intentionally keep running even when the
   system "reduce motion" setting is on, so the page always feels alive. */
