:root {
    --theme-primary: #8e4de8;
    --theme-secondary: #ff5fa2;
    --theme-accent: #42b7ff;
    --theme-gold: #f6c85f;
    --ink: #241b3a;
    --muted: #6e6480;
    --paper: #fffafc;
    --line: rgba(36, 27, 58, 0.12);
    --shadow: 0 20px 55px rgba(45, 25, 83, 0.18);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    color: var(--ink);
    background: #fff8fc;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    letter-spacing: 0;
}

a {
    text-decoration: none;
}

.btn {
    border-radius: 8px;
    font-weight: 700;
}

.btn-premium {
    color: #20152f;
    border: 0;
    background: linear-gradient(135deg, var(--theme-gold), #ffe7a3 42%, var(--theme-secondary));
    box-shadow: 0 12px 28px rgba(255, 95, 162, 0.28);
}

.btn-premium:hover,
.btn-premium:focus {
    color: #20152f;
    transform: translateY(-1px);
    box-shadow: 0 16px 34px rgba(142, 77, 232, 0.28);
}

.btn-glass {
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.7);
    background: rgba(36, 27, 58, 0.56);
    backdrop-filter: blur(14px);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.34);
}

.btn-glass:hover {
    color: #fff;
    border-color: #fff;
    background: rgba(36, 27, 58, 0.72);
}

.btn-outline-premium {
    color: var(--theme-primary);
    border-color: rgba(142, 77, 232, 0.42);
    background: #fff;
}

.btn-outline-premium:hover {
    color: #fff;
    border-color: var(--theme-primary);
    background: var(--theme-primary);
}

.premium-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0.8rem;
    color: #fff;
    background: rgba(36, 27, 58, 0.46);
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 8px;
    font-weight: 800;
    backdrop-filter: blur(16px);
}

.home-hero,
.invite-hero {
    position: relative;
    overflow: hidden;
    background:
        linear-gradient(90deg, rgba(42, 22, 75, 0.55), rgba(78, 29, 105, 0.18) 45%, rgba(255, 248, 252, 0.08)),
        url("../img/hero-huntrix-premium.png") center / cover no-repeat;
}

.home-hero::after,
.invite-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(19, 12, 35, 0.12), rgba(255, 250, 252, 0.18) 72%, #fff8fc 100%);
}

.home-hero > .container,
.invite-hero > .container {
    position: relative;
    z-index: 2;
}

.home-title,
.invite-hero h1 {
    margin: 1rem 0 0.25rem;
    color: #fff;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 5rem;
    line-height: 1;
    text-shadow: 0 12px 30px rgba(36, 27, 58, 0.34);
}

.home-subtitle,
.invite-hero h2 {
    color: #fff5fb;
    font-size: 1.6rem;
    font-weight: 800;
    text-shadow: 0 10px 22px rgba(36, 27, 58, 0.26);
}

.home-badges,
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.home-badges span {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.72rem 0.9rem;
    color: #fff;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.34);
    border-radius: 8px;
    font-weight: 800;
    backdrop-filter: blur(14px);
}

.access-card,
.guest-pass,
.not-found-card,
.event-ended,
.dress-card,
.location-panel,
.rsvp-panel,
.admin-panel,
.stat-card,
.login-card {
    border: 1px solid rgba(255, 255, 255, 0.56);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.84);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.access-card,
.login-card {
    padding: 2rem;
}

.access-card h2,
.login-card h1 {
    margin-top: 1rem;
    font-weight: 900;
}

.access-card p,
.login-card p {
    color: var(--muted);
}

.card-icon,
.brand-mark {
    display: inline-flex;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    color: #20152f;
    background: linear-gradient(135deg, var(--theme-gold), #fff1bb);
    border-radius: 8px;
}

.access-form {
    display: grid;
    gap: 1rem;
    margin-top: 1.25rem;
}

.admin-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.25rem;
    color: var(--theme-primary);
    font-weight: 800;
}

.invite-welcome {
    max-width: 620px;
    color: #fff;
    font-size: 1.15rem;
    text-shadow: 0 8px 18px rgba(36, 27, 58, 0.24);
}

.hero-mini-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    max-width: 620px;
    margin-top: 1.25rem;
}

.hero-mini-grid div {
    display: flex;
    min-height: 64px;
    align-items: center;
    gap: 0.65rem;
    padding: 0.8rem;
    color: #fff !important;
    border: 1px solid rgba(255, 255, 255, 0.62);
    border-radius: 8px;
    background: rgba(36, 27, 58, 0.76);
    box-shadow: 0 16px 34px rgba(36, 27, 58, 0.28);
    backdrop-filter: blur(16px);
}

.hero-mini-grid i {
    display: grid;
    min-width: 38px;
    height: 38px;
    place-items: center;
    color: #20152f;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--theme-gold), #fff4c7);
}

.hero-mini-grid span {
    display: grid;
    gap: 0.1rem;
    min-width: 0;
    color: #fff !important;
    font-size: 0.95rem;
    font-weight: 900;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.42);
}

.hero-mini-grid span small {
    color: rgba(255, 255, 255, 0.82) !important;
    font-size: 0.68rem;
    font-weight: 900;
    line-height: 1;
    text-transform: uppercase;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.guest-pass {
    position: relative;
    overflow: hidden;
    padding: 1.5rem;
}

.guest-pass::before,
.guest-pass::after {
    content: "";
    position: absolute;
    top: 50%;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 248, 252, 0.92);
    transform: translateY(-50%);
}

.guest-pass::before {
    left: -14px;
}

.guest-pass::after {
    right: -14px;
}

.pass-label,
.section-heading span,
.location-type,
.admin-panel .panel-heading span {
    display: inline-flex;
    color: var(--theme-secondary);
    font-size: 0.82rem;
    font-weight: 900;
    text-transform: uppercase;
}

.guest-pass h3 {
    margin: 0.45rem 0;
    color: var(--ink);
    font-size: 2rem;
    font-weight: 900;
}

.guest-pass p {
    color: var(--muted);
    font-weight: 700;
}

.ticket-ribbon {
    display: inline-flex;
    gap: 0.45rem;
    align-items: center;
    margin: 0.45rem 0 0.25rem;
    padding: 0.48rem 0.7rem;
    color: #20152f;
    border-radius: 8px;
    background: linear-gradient(135deg, #fff2bd, #ffd6e8);
    font-size: 0.82rem;
    font-weight: 900;
}

.pass-meta {
    display: grid;
    gap: 0.75rem;
    margin: 1rem 0;
}

.pass-meta div {
    padding: 0.85rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.pass-meta small,
.event-summary small,
.admin-table small {
    display: block;
    color: var(--muted);
    font-size: 0.78rem;
}

.pass-meta strong,
.small-code {
    overflow-wrap: anywhere;
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 0.82rem;
}

.huntrix-pass {
    display: grid;
    gap: 1.15rem;
    padding: 1.25rem;
    background:
        radial-gradient(circle at 20% 18%, rgba(255, 95, 162, 0.22), transparent 28%),
        radial-gradient(circle at 84% 18%, rgba(66, 183, 255, 0.24), transparent 24%),
        linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(255, 247, 252, 0.78));
}

.huntrix-art {
    position: relative;
    width: min(100%, 420px);
    max-height: min(42vh, 360px);
    margin: 0 auto;
    overflow: hidden;
    border: 1px solid rgba(142, 77, 232, 0.18);
    border-radius: 8px;
    background: #25153f;
    box-shadow: 0 18px 38px rgba(36, 27, 58, 0.18);
    aspect-ratio: 16 / 11;
}

.huntrix-art img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 34%;
}

.huntrix-copy {
    display: grid;
    gap: 0.65rem;
}

.huntrix-copy h3 {
    margin: 0;
}

.pass-code {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.95rem 1rem;
    border: 1px solid rgba(142, 77, 232, 0.16);
    border-radius: 8px;
    background: #fff;
}

.pass-code small {
    color: var(--muted);
    font-weight: 900;
    text-transform: uppercase;
}

.pass-code strong {
    color: var(--theme-primary);
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 1.1rem;
    font-weight: 950;
    letter-spacing: 0.02em;
}


.invitation-shell {
    background:
        linear-gradient(180deg, #fff8fc 0%, #f7efff 34%, #fff8fc 68%, #f1f9ff 100%);
}

.invite-band {
    position: relative;
    overflow: hidden;
}

.invite-band::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.42;
    background-image:
        radial-gradient(circle at 12% 22%, rgba(246, 200, 95, 0.45) 0 2px, transparent 3px),
        radial-gradient(circle at 83% 28%, rgba(255, 95, 162, 0.34) 0 2px, transparent 3px),
        radial-gradient(circle at 48% 82%, rgba(66, 183, 255, 0.28) 0 2px, transparent 3px);
    background-size: 180px 180px, 210px 210px, 240px 240px;
}

.invite-band > .container {
    position: relative;
    z-index: 1;
}

.countdown-section {
    background:
        linear-gradient(135deg, rgba(36, 27, 58, 0.96), rgba(119, 59, 160, 0.86)),
        url("../img/hero-huntrix-premium.png") center / cover no-repeat;
}

.section-heading {
    max-width: 760px;
    margin: 0 auto 2rem;
    text-align: center;
}

.section-heading h2 {
    margin: 0.35rem 0 0;
    font-weight: 950;
}

.section-heading p {
    color: var(--muted);
}

.heading-light span,
.heading-light h2 {
    color: #fff;
    text-shadow: 0 8px 22px rgba(0, 0, 0, 0.25);
}

.countdown-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.countdown-grid div {
    min-height: 132px;
    display: grid;
    place-items: center;
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.36);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 18px 40px rgba(18, 9, 35, 0.22);
    backdrop-filter: blur(14px);
}

.countdown-grid strong {
    display: block;
    font-size: 2.8rem;
    line-height: 1;
    color: var(--theme-primary);
}

.countdown-grid small {
    color: var(--muted);
    font-weight: 900;
    text-transform: uppercase;
}

.schedule-section {
    background: linear-gradient(180deg, #fff8fc, #f5edff);
}

.timeline {
    max-width: 780px;
    margin: 0 auto;
    padding: 1.2rem;
    border: 1px solid rgba(142, 77, 232, 0.12);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.72);
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
}

.timeline-item {
    display: grid;
    grid-template-columns: 120px 44px 1fr;
    gap: 1rem;
    align-items: center;
    padding: 0.7rem 0;
}

.timeline-time {
    color: var(--theme-primary);
    font-weight: 950;
    text-align: right;
}

.timeline-dot {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border: 4px solid #fff;
    border-radius: 8px;
    color: #241b3a;
    background: linear-gradient(135deg, var(--theme-gold), #fff3bc);
    box-shadow: 0 0 0 2px rgba(142, 77, 232, 0.22), 0 12px 24px rgba(142, 77, 232, 0.2);
}

.timeline-content {
    padding: 1.05rem 1.15rem;
    border: 1px solid rgba(142, 77, 232, 0.14);
    border-radius: 8px;
    background: linear-gradient(135deg, #fff, #fff8fc);
    box-shadow: 0 12px 26px rgba(36, 27, 58, 0.08);
    font-weight: 850;
}

.dress-section {
    background: linear-gradient(135deg, #fff7d9, #fff4fb 45%, #edf8ff);
}

.dress-card {
    display: flex;
    gap: 1rem;
    align-items: center;
    padding: 1.4rem;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(255, 247, 217, 0.92)),
        url("../img/huntrix-inspired-dolls.jpg") right center / auto 220% no-repeat;
}

.dress-card i {
    display: grid;
    min-width: 54px;
    height: 54px;
    place-items: center;
    color: var(--theme-primary);
    border-radius: 8px;
    background: #fff;
}

.dress-card h2 {
    margin: 0.25rem 0 0;
    font-size: 1.35rem;
}

.dress-swatches {
    display: flex;
    gap: 0.5rem;
    margin-left: auto;
}

.dress-swatches span {
    width: 34px;
    height: 34px;
    border: 3px solid #fff;
    border-radius: 8px;
    box-shadow: 0 10px 20px rgba(36, 27, 58, 0.16);
}

.dress-swatches span:nth-child(1) { background: var(--theme-primary); }
.dress-swatches span:nth-child(2) { background: var(--theme-secondary); }
.dress-swatches span:nth-child(3) { background: var(--theme-accent); }
.dress-swatches span:nth-child(4) { background: var(--theme-gold); }

.locations-section {
    background: linear-gradient(180deg, #f8f3ff, #fff8fc);
}

.location-panel {
    height: 100%;
    padding: 1.4rem;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 248, 252, 0.9));
}

.location-panel h2 {
    margin: 0.5rem 0;
    font-size: 1.45rem;
    font-weight: 900;
}

.location-panel p {
    min-height: 48px;
    color: var(--muted);
}

.location-panel iframe {
    width: 100%;
    height: 280px;
    margin-top: 1rem;
    border: 1px solid rgba(142, 77, 232, 0.12);
    border-radius: 8px;
    box-shadow: 0 16px 34px rgba(36, 27, 58, 0.12);
}

.gallery-section {
    background: linear-gradient(135deg, #fff7fc, #eef8ff);
}

.photo-drive-card {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 1.4rem;
    align-items: center;
    overflow: hidden;
    padding: 1.4rem;
    border: 1px solid rgba(142, 77, 232, 0.16);
    border-radius: 8px;
    background:
        radial-gradient(circle at 9% 15%, rgba(255, 95, 162, 0.18), transparent 28%),
        radial-gradient(circle at 92% 22%, rgba(66, 183, 255, 0.18), transparent 28%),
        linear-gradient(135deg, #fff, #fff7fc);
    box-shadow: var(--shadow);
}

.photo-drive-card > div:last-child > span {
    display: inline-flex;
    color: var(--theme-secondary);
    font-size: 0.82rem;
    font-weight: 950;
    text-transform: uppercase;
}

.photo-drive-card h2 {
    margin: 0.3rem 0 0.45rem;
    font-weight: 950;
}

.photo-drive-card p {
    max-width: 640px;
    color: var(--muted);
    font-weight: 700;
}

.drive-link-box {
    max-width: 720px;
    margin: 1rem 0;
    padding: 0.95rem 1rem;
    border: 1px solid rgba(142, 77, 232, 0.16);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: 0 12px 24px rgba(36, 27, 58, 0.08);
}

.drive-link-box small {
    display: block;
    margin-bottom: 0.35rem;
    color: var(--theme-secondary);
    font-weight: 950;
    text-transform: uppercase;
}

.drive-link-box a {
    display: block;
    color: #241b3a;
    font-weight: 850;
    overflow-wrap: anywhere;
    text-decoration: none;
}

.drive-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.photo-drive-visual {
    position: relative;
    display: grid;
    min-height: 210px;
    place-items: center;
    overflow: hidden;
    border-radius: 8px;
    background:
        linear-gradient(145deg, rgba(36, 27, 58, 0.95), rgba(98, 44, 142, 0.88)),
        radial-gradient(circle at center, rgba(255, 255, 255, 0.18), transparent 58%);
}

.photo-drive-visual i {
    z-index: 2;
    display: grid;
    width: 92px;
    height: 92px;
    place-items: center;
    color: #241b3a;
    border-radius: 50%;
    background: linear-gradient(135deg, #fff6cb, var(--theme-gold));
    box-shadow: 0 0 0 14px rgba(255, 255, 255, 0.08), 0 18px 36px rgba(0, 0, 0, 0.24);
    font-size: 2.2rem;
}

.photo-drive-visual span {
    position: absolute;
    border: 2px solid rgba(255, 255, 255, 0.18);
    border-radius: 50%;
}

.photo-drive-visual span:nth-child(2) {
    width: 178px;
    height: 178px;
}

.photo-drive-visual span:nth-child(3) {
    width: 132px;
    height: 132px;
    border-color: rgba(246, 200, 95, 0.32);
}

.photo-drive-visual span:nth-child(4) {
    width: 230px;
    height: 230px;
    border-color: rgba(66, 183, 255, 0.24);
}

.rsvp-panel {
    padding: 2rem;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(245, 238, 255, 0.95)),
        url("../img/huntrix-inspired-dolls.jpg") right bottom / auto 150% no-repeat;
}

.rsvp-section {
    background: linear-gradient(180deg, #f4efff, #fff8fc);
}

.rsvp-form {
    display: grid;
    gap: 1.25rem;
}

.music-player {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 50;
    display: flex;
    gap: 0.7rem;
    align-items: center;
    max-width: calc(100vw - 36px);
    padding: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.52);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 18px 42px rgba(36, 27, 58, 0.18);
    backdrop-filter: blur(18px);
}

.music-player .btn {
    display: inline-flex;
    gap: 0.5rem;
    align-items: center;
    white-space: nowrap;
}

.music-player.is-playing .btn {
    background: linear-gradient(135deg, var(--theme-accent), #c4f0ff 45%, var(--theme-gold));
}

.music-player.needs-gesture .btn {
    animation: music-pulse 1.4s ease-in-out infinite;
}

.music-meta {
    display: grid;
    line-height: 1.1;
}

.music-meta strong {
    font-size: 0.86rem;
}

.music-meta small {
    color: var(--muted);
    font-size: 0.74rem;
}

.music-gate {
    position: fixed;
    right: 18px;
    bottom: 88px;
    z-index: 60;
    display: flex;
    gap: 0.55rem;
    align-items: stretch;
    width: min(360px, calc(100vw - 36px));
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.22s ease, transform 0.22s ease;
    pointer-events: none;
}

.music-gate.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.music-gate-card {
    display: grid;
    grid-template-columns: 46px 1fr;
    gap: 0.15rem 0.75rem;
    align-items: center;
    width: 100%;
    padding: 0.85rem 1rem;
    color: #241b3a;
    text-align: left;
    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 8px;
    background:
        radial-gradient(circle at 10% 0%, rgba(255, 95, 162, 0.22), transparent 32%),
        linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(255, 244, 251, 0.94));
    box-shadow: 0 18px 42px rgba(36, 27, 58, 0.2);
    backdrop-filter: blur(18px);
}

.music-gate-card span {
    grid-row: span 2;
    display: grid;
    width: 46px;
    height: 46px;
    place-items: center;
    color: #241b3a;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--theme-gold), #fff2bd);
}

.music-gate-card strong,
.music-gate-card small {
    display: block;
}

.music-gate-card strong {
    font-size: 0.98rem;
    font-weight: 950;
    line-height: 1.1;
}

.music-gate-card small {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 750;
    line-height: 1.25;
}

.music-gate-close {
    display: grid;
    width: 42px;
    min-width: 42px;
    place-items: center;
    color: #241b3a;
    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 18px 42px rgba(36, 27, 58, 0.14);
}

.event-ended,
.not-found-card {
    max-width: 720px;
    margin: 5rem auto;
    padding: 2rem;
    text-align: center;
}

.event-ended i,
.not-found-card i,
.empty-state i {
    color: var(--theme-secondary);
    font-size: 3rem;
}

.sparkle-field {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    opacity: 0.45;
    background-image:
        radial-gradient(circle at 20% 25%, rgba(255, 255, 255, 0.95) 0 1px, transparent 2px),
        radial-gradient(circle at 68% 18%, rgba(246, 200, 95, 0.95) 0 1px, transparent 2px),
        radial-gradient(circle at 42% 72%, rgba(255, 255, 255, 0.86) 0 1px, transparent 2px);
    animation: sparkle-drift 7s ease-in-out infinite alternate;
}

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

.party-confetti span {
    position: absolute;
    top: -24px;
    width: 8px;
    height: 14px;
    border-radius: 3px;
    background: var(--theme-gold);
    opacity: 0.78;
    animation: confetti-fall 10s linear infinite;
}

.party-confetti span:nth-child(3n) {
    width: 10px;
    height: 10px;
    background: var(--theme-secondary);
}

.party-confetti span:nth-child(4n) {
    background: var(--theme-accent);
}

.party-confetti span:nth-child(1) { left: 7%; animation-delay: 0s; }
.party-confetti span:nth-child(2) { left: 14%; animation-delay: 2.1s; }
.party-confetti span:nth-child(3) { left: 22%; animation-delay: 4.3s; }
.party-confetti span:nth-child(4) { left: 31%; animation-delay: 1.3s; }
.party-confetti span:nth-child(5) { left: 39%; animation-delay: 5.1s; }
.party-confetti span:nth-child(6) { left: 47%; animation-delay: 3.2s; }
.party-confetti span:nth-child(7) { left: 55%; animation-delay: 6.4s; }
.party-confetti span:nth-child(8) { left: 63%; animation-delay: 1.8s; }
.party-confetti span:nth-child(9) { left: 71%; animation-delay: 4.8s; }
.party-confetti span:nth-child(10) { left: 79%; animation-delay: 2.9s; }
.party-confetti span:nth-child(11) { left: 87%; animation-delay: 5.8s; }
.party-confetti span:nth-child(12) { left: 94%; animation-delay: 0.9s; }
.party-confetti span:nth-child(13) { left: 11%; animation-delay: 7.1s; }
.party-confetti span:nth-child(14) { left: 27%; animation-delay: 8.3s; }
.party-confetti span:nth-child(15) { left: 43%; animation-delay: 6.7s; }
.party-confetti span:nth-child(16) { left: 59%; animation-delay: 9s; }
.party-confetti span:nth-child(17) { left: 75%; animation-delay: 7.8s; }
.party-confetti span:nth-child(18) { left: 91%; animation-delay: 8.7s; }

.floating-balloons {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
}

.balloon {
    position: absolute;
    width: 54px;
    height: 68px;
    border-radius: 50% 50% 46% 46%;
    box-shadow: inset -10px -12px 18px rgba(36, 27, 58, 0.18), 0 18px 34px rgba(36, 27, 58, 0.18);
    animation: balloon-float 6s ease-in-out infinite alternate;
}

.balloon::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 64px;
    width: 1px;
    height: 66px;
    background: rgba(255, 255, 255, 0.58);
}

.balloon-pink {
    left: 4%;
    top: 62%;
    background: linear-gradient(135deg, #ffd1e8, var(--theme-secondary));
}

.balloon-blue {
    right: 9%;
    top: 16%;
    background: linear-gradient(135deg, #d6f3ff, var(--theme-accent));
    animation-delay: 1.2s;
}

.balloon-gold {
    right: 2.5%;
    bottom: 12%;
    background: linear-gradient(135deg, #fff0b7, var(--theme-gold));
    animation-delay: 2.3s;
}

@keyframes sparkle-drift {
    from { transform: translate3d(0, 0, 0); }
    to { transform: translate3d(0, -16px, 0); }
}

@keyframes confetti-fall {
    0% {
        transform: translate3d(0, -30px, 0) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.84;
    }
    100% {
        transform: translate3d(32px, 110vh, 0) rotate(360deg);
        opacity: 0;
    }
}

@keyframes balloon-float {
    from { transform: translate3d(0, 0, 0) rotate(-2deg); }
    to { transform: translate3d(0, -22px, 0) rotate(3deg); }
}

@keyframes music-pulse {
    0%, 100% { box-shadow: 0 12px 28px rgba(255, 95, 162, 0.28); }
    50% { box-shadow: 0 0 0 7px rgba(246, 200, 95, 0.24), 0 16px 34px rgba(142, 77, 232, 0.28); }
}

@media (prefers-reduced-motion: reduce) {
    .sparkle-field,
    .party-confetti span,
    .balloon,
    .music-player.needs-gesture .btn {
        animation: none;
    }
}

/* Admin */
.login-screen {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 1.25rem;
    background:
        linear-gradient(90deg, rgba(42, 22, 75, 0.48), rgba(255, 248, 252, 0.2)),
        url("../img/hero-huntrix-premium.png") center / cover no-repeat;
}

.login-card {
    width: min(100%, 460px);
}

.login-brand,
.admin-brand {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.admin-brand strong {
    display: block;
    color: #fff;
    font-size: 1rem;
}

.admin-brand small {
    display: block;
    color: rgba(255, 255, 255, 0.75);
}

.login-brand strong {
    color: var(--ink);
}

.login-brand small {
    color: var(--muted);
}

.admin-body {
    background: #f6f2fb;
}

.admin-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 280px 1fr;
}

.admin-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    padding: 1rem;
    color: #fff;
    background: linear-gradient(180deg, #2c1c46, #5a2d86 58%, #22405f);
}

.admin-nav {
    display: grid;
    gap: 0.35rem;
}

.admin-nav a {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    padding: 0.82rem 0.9rem;
    color: rgba(255, 255, 255, 0.78);
    border-radius: 8px;
    font-weight: 800;
}

.admin-nav a.active,
.admin-nav a:hover {
    color: #20152f;
    background: linear-gradient(135deg, var(--theme-gold), #ffe8a5);
}

.admin-user {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding: 0.85rem;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
}

.admin-user strong,
.admin-user small {
    display: block;
}

.admin-user small {
    max-width: 150px;
    overflow: hidden;
    color: rgba(255, 255, 255, 0.7);
    text-overflow: ellipsis;
}

.admin-main {
    min-width: 0;
    padding: 1.5rem;
}

.admin-topbar {
    display: flex;
    gap: 1rem;
    align-items: center;
    margin-bottom: 1.5rem;
}

.admin-topbar h1 {
    margin: 0;
    font-size: 1.9rem;
    font-weight: 950;
}

.admin-topbar p {
    margin: 0;
    color: var(--muted);
}

.admin-menu-toggle {
    display: none;
}

.event-selector,
.settings-actions {
    display: flex;
    gap: 0.8rem;
    align-items: end;
    margin-bottom: 1rem;
}

.event-selector label {
    display: block;
    margin-bottom: 0.35rem;
    color: var(--muted);
    font-size: 0.8rem;
    font-weight: 900;
    text-transform: uppercase;
}

.event-selector .form-select {
    min-width: 320px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.stat-card {
    display: grid;
    gap: 0.35rem;
    padding: 1.25rem;
    background: #fff;
}

.stat-card i {
    color: var(--theme-primary);
    font-size: 1.45rem;
}

.stat-card span {
    color: var(--muted);
    font-weight: 800;
}

.stat-card strong {
    font-size: 2rem;
    line-height: 1;
}

.admin-panel {
    padding: 1.25rem;
    background: #fff;
}

.panel-heading {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.panel-heading h2 {
    margin: 0.15rem 0 0;
    font-size: 1.3rem;
    font-weight: 950;
}

.event-summary {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.event-summary div {
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff8fc;
}

.event-summary i {
    color: var(--theme-secondary);
}

.event-summary strong {
    display: block;
    margin-top: 0.5rem;
}

.admin-table {
    margin-bottom: 0;
}

.admin-table th {
    color: var(--muted);
    font-size: 0.78rem;
    text-transform: uppercase;
}

.admin-table td {
    vertical-align: middle;
}

.chart-box {
    position: relative;
    width: 100%;
    height: 280px;
    min-height: 280px;
    max-height: 280px;
    overflow: hidden;
}

.chart-box-sm {
    height: 230px;
    min-height: 230px;
    max-height: 230px;
}

.chart-box canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
}

.table-message {
    max-width: 320px;
    white-space: normal;
}

.user-agent {
    max-width: 360px;
    overflow-wrap: anywhere;
    color: var(--muted);
    font-size: 0.82rem;
}

.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.admin-form .form-control,
.admin-form .form-select,
.access-form .form-control,
.rsvp-form .form-control,
.rsvp-form .form-select,
.login-card .form-control {
    border-color: rgba(142, 77, 232, 0.18);
    border-radius: 8px;
}

.color-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.color-grid label {
    display: grid;
    gap: 0.55rem;
    padding: 0.9rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    font-weight: 850;
    background: #fff8fc;
}

.color-grid input {
    width: 100%;
    height: 44px;
    border: 0;
    background: transparent;
}

.code-textarea {
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 0.88rem;
}

.sticky-save {
    position: sticky;
    bottom: 0;
    z-index: 20;
    display: flex;
    justify-content: flex-end;
    padding: 1rem 0;
    background: linear-gradient(180deg, rgba(246, 242, 251, 0), #f6f2fb 38%);
}

.empty-state {
    display: grid;
    place-items: center;
    min-height: 360px;
    padding: 2rem;
    text-align: center;
    border: 1px dashed rgba(142, 77, 232, 0.28);
    border-radius: 8px;
    background: #fff;
}

@media (max-width: 1199px) {
    .stats-grid,
    .event-summary {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 991px) {
    .home-title,
    .invite-hero h1 {
        font-size: 3.6rem;
    }

    .admin-shell {
        grid-template-columns: 1fr;
    }

    .admin-sidebar {
        position: fixed;
        inset: 0 auto 0 0;
        z-index: 100;
        width: 280px;
        transform: translateX(-102%);
        transition: transform 0.25s ease;
    }

    .admin-sidebar.open {
        transform: translateX(0);
    }

    .admin-menu-toggle {
        display: inline-flex;
    }
}

@media (max-width: 767px) {
    .home-title,
    .invite-hero h1 {
        font-size: 2.8rem;
    }

    .home-subtitle,
    .invite-hero h2 {
        font-size: 1.25rem;
    }

    .countdown-grid,
    .stats-grid,
    .event-summary,
    .color-grid,
    .hero-mini-grid {
        grid-template-columns: 1fr 1fr;
    }

    .countdown-grid strong {
        font-size: 2.2rem;
    }

    .timeline-item {
        grid-template-columns: 92px 44px minmax(0, 1fr);
        gap: 0.75rem;
    }

    .settings-actions,
    .event-selector {
        align-items: stretch;
        flex-direction: column;
    }

    .event-selector .form-select {
        min-width: 0;
        width: 100%;
    }

    .photo-drive-card {
        grid-template-columns: 1fr;
    }

    .photo-drive-visual {
        min-height: 180px;
    }

    .huntrix-art {
        max-height: 320px;
        aspect-ratio: 16 / 10;
    }

    .dress-card,
    .rsvp-panel {
        background-image: none;
    }

    .dress-card {
        flex-wrap: wrap;
    }

    .dress-swatches {
        width: 100%;
        margin-left: 0;
    }
}

@media (max-width: 575px) {
    .access-card,
    .guest-pass,
    .rsvp-panel,
    .admin-panel,
    .login-card {
        padding: 1rem;
    }

    .countdown-grid,
    .color-grid {
        grid-template-columns: 1fr;
    }

    .hero-actions {
        flex-direction: column;
    }

    .hero-actions .btn {
        width: 100%;
    }

    .drive-actions .btn {
        width: 100%;
    }

    .hero-mini-grid {
        grid-template-columns: 1fr;
    }

    .timeline-time {
        font-size: 0.86rem;
    }

    .admin-main {
        padding: 1rem;
    }

    .floating-balloons {
        display: none;
    }

    .music-meta {
        display: none;
    }

    .music-gate {
        right: 12px;
        bottom: 82px;
        width: calc(100vw - 24px);
    }

    .music-gate-card {
        padding: 0.78rem 0.85rem;
    }

    .location-panel iframe {
        height: 220px;
    }

    .timeline {
        padding: 0.85rem;
    }

    .timeline-item {
        grid-template-columns: 44px minmax(0, 1fr);
        grid-template-areas:
            "time time"
            "icon content";
        gap: 0.55rem 0.75rem;
        align-items: start;
        padding: 0.85rem 0;
    }

    .timeline-time {
        grid-area: time;
        text-align: left;
        font-size: 0.92rem;
    }

    .timeline-dot {
        grid-area: icon;
    }

    .timeline-content {
        grid-area: content;
        min-width: 0;
        padding: 0.9rem 1rem;
        overflow-wrap: anywhere;
    }

    .huntrix-art {
        max-height: 240px;
        aspect-ratio: 16 / 9;
    }

    .huntrix-art img {
        object-position: center 30%;
    }
}
