:root {
    --font-display: 'Syne', sans-serif;
    --font-sans: 'Plus Jakarta Sans', sans-serif;
    --ink: #1a1a1a;
    --cream: #FAF8F7;
    --gold: #e2b458;
}

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

html, body {
    height: 100%;
}

body {
    font-family: var(--font-sans);
    background:
        radial-gradient(ellipse 60% 45% at 18% 8%, rgba(253, 159, 159, 0.16), transparent 60%),
        radial-gradient(ellipse 55% 45% at 85% 12%, rgba(240, 127, 86, 0.14), transparent 60%),
        radial-gradient(ellipse 60% 50% at 50% 100%, rgba(172, 40, 45, 0.10), transparent 65%),
        var(--cream);
    color: var(--ink);
    min-height: 100vh;
    overflow-x: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 24px;
}

.portal {
    width: 100%;
    max-width: 1180px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 56px;
    animation: portalIn 1s cubic-bezier(0.16, 1, 0.3, 1) both;
}

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

.portal-hero {
    text-align: center;
    max-width: 640px;
}

.eyebrow {
    font-family: var(--font-sans);
    font-weight: 700;
    font-size: 0.78rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--gold);
}

.portal-title {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(3rem, 9vw, 6.2rem);
    line-height: 0.92;
    letter-spacing: -3px;
    text-transform: uppercase;
    margin-top: 14px;
    background: linear-gradient(100deg, #ac282d 0%, #d43c4e 28%, #f07f56 55%, #fd9f9f 78%, #df5953 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.portal-sub {
    margin-top: 18px;
    font-size: 1rem;
    line-height: 1.6;
    color: #5a5a5a;
    font-weight: 500;
}

/* ==========================================
   CHARACTER LINEUP — 3D tilt card select
   ========================================== */

.lineup {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: clamp(4px, 1.6vw, 20px);
    width: 100%;
    perspective: 1400px;
}

.quint-card {
    --rx: 0deg;
    --ry: 0deg;
    --scale: 1;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: clamp(120px, 16vw, 200px);
    padding: 22px 10px 20px;
    text-decoration: none;
    color: var(--ink);
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 14px 30px rgba(20, 15, 15, 0.08);
    transform-style: preserve-3d;
    transform: rotate(var(--fan-rot, 0deg)) translateY(var(--fan-y, 0px)) scale(var(--scale)) rotateX(var(--rx)) rotateY(var(--ry));
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease;
    cursor: pointer;
}

.lineup a:nth-child(1) { --fan-rot: -10deg; --fan-y: 26px; }
.lineup a:nth-child(2) { --fan-rot: -5deg;  --fan-y: 6px; }
.lineup a:nth-child(3) { --fan-rot: 0deg;   --fan-y: -10px; }
.lineup a:nth-child(4) { --fan-rot: 5deg;   --fan-y: 6px; }
.lineup a:nth-child(5) { --fan-rot: 10deg;  --fan-y: 26px; }

.quint-card:hover,
.quint-card:focus-visible {
    box-shadow: 0 26px 50px -8px color-mix(in srgb, var(--accent) 55%, rgba(20, 15, 15, 0.25));
    border-color: color-mix(in srgb, var(--accent) 45%, white);
    z-index: 5;
}

.quint-card-order {
    font-family: var(--font-display);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    color: color-mix(in srgb, var(--accent) 70%, #777);
    margin-bottom: 8px;
}

.quint-card-glow {
    position: absolute;
    top: 46%;
    left: 50%;
    width: 78%;
    height: 60%;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, var(--accent) 0%, transparent 72%);
    opacity: 0.45;
    filter: blur(18px);
    z-index: -1;
    transition: opacity 0.4s ease, filter 0.4s ease;
}

.quint-card:hover .quint-card-glow {
    opacity: 0.75;
    filter: blur(22px);
}

.quint-card-img {
    width: 100%;
    height: clamp(140px, 20vw, 230px);
    object-fit: contain;
    object-position: bottom center;
    filter: drop-shadow(6px 10px 14px rgba(0, 0, 0, 0.16));
    transform: translateZ(30px);
    pointer-events: none;
}

.quint-card-name {
    margin-top: 12px;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(0.95rem, 1.6vw, 1.25rem);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.portal-footer {
    font-size: 0.8rem;
    color: #8a8a8a;
    font-weight: 500;
    text-align: center;
}

@media (max-width: 900px) {
    .lineup {
        flex-wrap: wrap;
        row-gap: 28px;
    }
    .quint-card {
        width: clamp(120px, 40vw, 180px);
    }
    .lineup a:nth-child(n) { --fan-y: 0px; }
}

@media (prefers-reduced-motion: reduce) {
    .portal,
    .quint-card {
        animation: none !important;
        transition: none !important;
    }
}
