/* -----------------------------------------------------
   Root Variables
----------------------------------------------------- */
:root {
    --bg-gradient: radial-gradient(circle at top, #ff004d 0, #0a0a1a 40%, #050510 100%);
    --card-bg: rgba(10, 10, 30, 0.8);
    --card-border: rgba(255, 255, 255, 0.08);
    --accent: #ff1e56;
    --accent-soft: rgba(255, 30, 86, 0.4);
    --accent-green: #35e48c;
    --accent-amber: #ffbf3c;
    --accent-red: #ff4b4b;
    --text-main: #f9fafb;
    --text-subtle: #9ca3af;
    --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.6);
    --radius-lg: 20px;
    --radius-pill: 999px;
    --nav-height: 68px;
}

/* -----------------------------------------------------
   Global Reset
----------------------------------------------------- */
* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

.text-left {
    text-align: left;
}

html {
    background-color: #691426;
    min-height: 100%;
}


body {
    position: relative;
    /* required */
    background: transparent;
    /* turn off normal background */
    font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text-main);
    overflow-x: hidden;
    scroll-behavior: smooth;
    padding: 0;
    min-height: 100%;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    background: var(--bg-gradient);
    background-size: cover;
    z-index: -1;
}

.app-shell {
    max-width: 768px;
    min-height: 100vh;
    margin: 0 auto;
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);

}

/* -----------------------------------------------------
   Header (unified with hero cards)
----------------------------------------------------- */

.app-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px;
    background: transparent !important;
}

/* Brand chip (left) */
.header-chip {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px 6px 6px;
    border-radius: 999px;
    background: radial-gradient(circle at top left, rgba(255, 255, 255, 0.06), transparent 60%),
        linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.96));
    border: 1px solid rgba(148, 163, 184, 0.55);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.65);
}

/* App icon: subtle circular glyph, no red block */
.header-app-icon {
    width: 30px;
    height: 30px;
    border-radius: 999px;
    background: radial-gradient(circle at 30% 0%, rgba(255, 255, 255, 0.22), transparent 55%),
        radial-gradient(circle at bottom, rgba(255, 30, 86, 0.45), rgba(15, 23, 42, 1));
    border: 1px solid rgba(248, 250, 252, 0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
}

.header-app-icon i {
    color: #f9fafb;
    font-size: 0.85rem;
}

/* Title stack */
.header-titles {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.header-title {
    font-family: "Space Grotesk", sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.76rem;
    font-weight: 600;
    color: #f9fafb;
}

.header-subtitle {
    font-size: 0.64rem;
    color: var(--text-subtle);
    opacity: 0.95;
}

/* Profile pill (right) – matches other glass buttons */
.header-profile-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 12px 5px 5px;
    border-radius: 999px;
    background: radial-gradient(circle at top right, rgba(255, 30, 86, 0.28), transparent 60%),
        linear-gradient(135deg, rgba(15, 23, 42, 0.98), rgba(15, 23, 42, 0.96));
    border: 1px solid rgba(148, 163, 184, 0.6);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.65);
    text-decoration: none;
    transition: transform 0.06s ease-out, box-shadow 0.12s ease-out, background 0.15s ease;
}

.header-profile-pill:active {
    transform: scale(0.97);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.6);
}

/* Avatar – remove white border, use subtle dark ring */
.header-profile-pill img {
    width: 30px;
}

.header-profile-labels {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.header-username {
    color: var(--text-main);
    font-size: 0.78rem;
    font-weight: 600;
}

.header-profile-pill small {
    font-size: 0.65rem;
    color: var(--accent-amber);
}

/* Slightly tighter layout on very small screens */
@media (max-width: 360px) {
    .header-subtitle {
        display: none;
    }

    .header-chip {
        padding-right: 8px;
    }

    .header-profile-pill {
        padding-right: 8px;
    }
}

/* -----------------------------------------------------
   Main Layout
----------------------------------------------------- */
.app-main {
    padding: 4px 4px 60px 4px;
}

.section-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: rgba(148, 163, 184, 0.9);
    margin: 8px 0 4px;
}

/* -----------------------------------------------------
   Hero Card (Next Up)
----------------------------------------------------- */

/* -----------------------------------------------------
   Hero Card (Next Up)
----------------------------------------------------- */

.hero-card {
    position: relative;
    margin-top: 8px;
    margin-bottom: 20px;
    padding: 18px 16px 16px;
    border-radius: 24px;
    background: radial-gradient(circle at top left, rgba(255, 255, 255, 0.10), transparent 60%),
        radial-gradient(circle at bottom right, rgba(255, 30, 86, 0.30), transparent 55%),
        rgba(17, 24, 39, 0.96);
    border: 1px solid rgba(148, 163, 184, 0.35);
    box-shadow: 0 22px 45px rgba(0, 0, 0, 0.75);
    /* overflow: hidden; Removed to allow tooltip overflow */
}

/* Per-match background image */
.hero-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 24px;
    /* Added to clip background manually */
    background: var(--team-bg) center/84% no-repeat;
    opacity: 0.05;
    pointer-events: none;
    mix-blend-mode: screen;
    filter: saturate(1.15) blur(10px);
}

.hero-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: relative;
    z-index: 1;
}

.hero-team {
    font-family: "Space Grotesk", system-ui;
    font-size: 1.1rem;
    line-height: 1.2;
    font-weight: 600;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

/* “Matchday 2025-11-22” */
.hero-date {
    margin-top: 4px;
    font-size: 0.8rem;
    color: var(--text-subtle);
}

.top-match-chip {
    font-size: 0.7rem;
    padding: 4px 10px;
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(248, 113, 113, 0.45));
    border: 1px solid rgba(248, 113, 113, 0.9);
    color: #fee2e2;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 10px 22px rgba(248, 113, 113, 0.5);
}

.hero-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.meta-pill {
    font-size: 0.72rem;
    padding: 5px 11px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.5);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-subtle);
}

.deadline-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 11px;
    border-radius: 999px;
    background: radial-gradient(circle at top, rgba(251, 191, 36, 0.25), rgba(15, 23, 42, 0.9));
    border: 1px solid rgba(245, 158, 11, 0.8);
    color: #fed7aa;
    font-size: 0.72rem;
}

/* Main body: info + CTA */
.hero-body {
    margin-top: 18px;
    position: relative;
    z-index: 1;
    column-gap: 16px;
    row-gap: 14px;
    align-items: stretch;
}

/* Info block as “card inside card” */
.hero-info-block {
    padding: 10px 12px;
    border-radius: 16px;
    /*background: rgba(15, 23, 42, 0.40);*/
    border: 1px solid rgba(31, 41, 55, 0.10);
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 0.8rem;
    /*backdrop-filter: blur(2px);*/
}

.info-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
}

.info-label {
    color: var(--text-subtle);
    font-size: 0.76rem;
}

.info-value {
    font-weight: 500;
    font-size: 0.82rem;
    text-align: right;
}

.info-value--win {
    color: var(--accent-green);
}

.info-value--lose {
    color: var(--accent-red);
}

/* Compact status chip below Result */
.registration-status-chip {
    margin-top: 6px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.72rem;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.98);
    border: 1px dashed rgba(148, 163, 184, 0.6);
    color: var(--text-subtle);
}

.status-accepted {
    color: var(--accent-green) !important;
}

.status-rejected {
    color: var(--accent-red) !important;
}

/* ===================================
   LOGIN PAGE STYLES
   =================================== */
.login-card {
    margin-top: 20px;
    padding-bottom: 30px;
}

.login-icon {
    color: var(--accent-amber);
}

.login-body {
    display: block;
    margin-top: 20px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-label {
    font-size: 0.75rem;
    color: var(--text-subtle);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Timeline Styles */
.timeline-container {
    padding: 0 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.timeline-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.timeline-item:last-child {
    border-bottom: none;
}

.timeline-time {
    font-weight: 700;
    color: var(--accent-color);
    width: 30px;
    text-align: center;
    font-size: 0.9rem;
}

.timeline-content {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.timeline-icon {
    width: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1rem;
}

.timeline-icon .fa-futbol {
    color: #ffffff;
}

.timeline-icon .fa-right-left {
    color: var(--text-subtle);
    font-size: 0.8rem;
}

.card-icon {
    width: 14px;
    height: 18px;
    border-radius: 2px;
}

.card-yellow {
    background-color: #fbbf24;
}

.card-red {
    background-color: #ef4444;
}

/* Home/Away alignment */
.timeline-item.timeline-home {
    flex-direction: row;
    text-align: left;
}

.timeline-item.timeline-away {
    flex-direction: row-reverse;
    text-align: right;
}

.timeline-item.timeline-away .timeline-content {
    flex-direction: row-reverse;
}

.timeline-item.timeline-away .timeline-details {
    align-items: flex-end;
}

.timeline-details {
    display: flex;
    flex-direction: column;
}

.timeline-main-text {
    font-weight: 500;
    font-size: 0.95rem;
}

.timeline-sub-text {
    font-size: 0.8rem;
    color: var(--text-subtle);
}

.timeline-player-in {
    color: #4ade80;
}

.timeline-player-out {
    color: #f87171;
}

.timeline-sub-arrow {
    font-size: 0.7rem;
    color: var(--text-subtle);
    margin: 0 4px;
}

.match-link-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.match-item {
    position: relative;
}

.match-team-logo a,
.match-attendees-inline a {
    position: relative;
    z-index: 2;
}

.form-input {
    background: rgba(10, 10, 30, 0.6);
    border: 1px solid rgba(148, 163, 184, 0.3);
    border-radius: 12px;
    padding: 12px 16px;
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255, 30, 86, 0.2);
}

.form-submit {
    margin-top: 10px;
}

.btn-full-width {
    width: 100%;
    justify-content: center;
}

/* ===================================
   PROFILE PAGE STYLES
   =================================== */
.profile-section {
    text-align: center;
    padding-top: 24px;
}

.profile-avatar {
    width: 110px;
    height: 110px;
}

.profile-header {
    font-family: 'Space Grotesk';
    margin-bottom: 4px;
}

.profile-subtitle {
    color: var(--text-subtle);
    font-size: 0.8rem;
    margin-top: 0;
}

.section-card-header--centered {
    justify-content: center;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-subtle);
}

.stat-value {
    font-size: 1.1rem;
    font-weight: 600;
}

.text-green {
    color: var(--accent-green);
}

.text-red {
    color: var(--accent-red);
}

.empty-state {
    text-align: center;
    color: var(--text-subtle);
    font-size: 0.82rem;
}

/* ===================================
   SETTINGS PAGE STYLES
   =================================== */
.header-link {
    color: var(--text-main);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 600;
}

.settings-group {
    margin-bottom: 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.settings-label {
    font-size: 0.85rem;
    color: var(--text-subtle);
    font-weight: 500;
}

.settings-input {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(148, 163, 184, 0.3);
    border-radius: 12px;
    padding: 10px 12px;
    color: var(--text-main);
    font-family: inherit;
    font-size: 0.9rem;
    width: 100%;
    transition: border-color 0.2s;
}

.settings-input:focus {
    outline: none;
    border-color: var(--accent);
}

.match-link-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.match-item {
    position: relative;
}

.match-team-logo a,
.match-attendees-inline a {
    position: relative;
    z-index: 2;
}

.settings-help {
    font-size: 0.7rem;
    color: rgba(148, 163, 184, 0.6);
}

.settings-actions {
    margin-top: 24px;
    display: flex;
    justify-content: flex-end;
}

/* ===================================
   BASE TEMPLATE STYLES
   =================================== */
.footer-link {
    color: inherit;
    text-decoration: underline;
}


/* Lottery explanation pill */
.lottery-chip {
    margin-top: 10px;
    font-size: 0.72rem;
    padding: 7px 10px;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.96);
    border: 1px dashed rgba(148, 163, 184, 0.75);
    display: inline-flex;
    align-items: flex-start;
    gap: 8px;
    color: var(--text-subtle);
}

.lottery-chip strong {
    color: var(--accent-amber);
}

/* CTA column */
.hero-cta-block {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 10px;
    padding-left: 14px;
}

/* Buttons */
.btn-pill {
    border-radius: var(--radius-pill);
    border: none;
    font-size: 0.86rem;
    font-weight: 600;
    padding: 10px 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.08s ease-out,
        box-shadow 0.16s ease-out,
        background 0.16s ease-out,
        opacity 0.12s ease-out;
    white-space: nowrap;
}

.btn-pill.pressed {
    transform: scale(0.94);
    opacity: 0.9;
}

.btn-pill i {
    font-size: 0.9rem;
}

.btn-pill:active {
    transform: scale(0.97);
}

.btn-primary-glass {
    background: linear-gradient(135deg, #ff416c, #ff9a3c);
    color: #ffffff;
    box-shadow: 0 18px 36px rgba(248, 113, 113, 0.6);
}

.btn-secondary-glass {
    background: radial-gradient(circle at top, rgba(15, 23, 42, 0.9), rgba(2, 6, 23, 1));
    border: 1px solid rgba(148, 163, 184, 0.8);
    color: var(--text-main);
}

/* -----------------------------------------------------
   Enhanced Button Interactions (safe overlay)
----------------------------------------------------- */

/* Improve touch behavior */
.btn-pill {
    touch-action: manipulation;
    position: relative;
    overflow: hidden;
    /* enables ripple */
    transform-origin: center;
}

/* -----------------------------------------------------
   Index Page Specifics (Refactored)
----------------------------------------------------- */
.result-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-share {
    font-size: 0.7rem;
    padding: 2px 8px;
    width: auto;
    height: auto;
    min-height: unset;
    line-height: 1.2;
}


/* Hover glow — desktop only */
@media (hover: hover) and (pointer: fine) {
    .btn-pill:hover {
        box-shadow: 0 0 14px rgba(255, 255, 255, 0.12),
            0 0 26px rgba(255, 30, 86, 0.25),
            0 0 44px rgba(255, 154, 60, 0.15);
        transform: translateY(-1px);
    }
}

/* Active press — slightly deeper, keeping your scale */
@media (hover: none) {
    .btn-pill:active {
        transform: scale(0.94);
        opacity: 0.9;
    }
}

/* Keyboard focus ring */
.btn-pill:focus-visible {
    outline: none;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3),
        0 0 0 6px rgba(255, 30, 86, 0.35);
    transition: box-shadow 0.15s ease-out;
}

/* Ripple effect (pure CSS, non-blocking) */
.btn-pill::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.30);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    opacity: 0;
    pointer-events: none;
}

.btn-pill:active::after {
    width: 180%;
    height: 180%;
    opacity: 0.15;
    transition: width 0.45s ease-out,
        height 0.45s ease-out,
        opacity 0.6s ease-out;
}

/* Icon alignment improvement */
.btn-pill i {
    transform: translateY(1px);
}

/* Smaller screens → auto-scale */
@media (max-width: 360px) {
    .btn-pill {
        font-size: 0.78rem;
        padding: 9px 12px;
    }
}

/* -----------------------------------------------------
   UNIVERSAL BUTTON RESPONSIVENESS
   Applies to all buttons except ones you explicitly opt-out
----------------------------------------------------- */

.btn,
button,
a[role="button"],
.btn-plain {
    position: relative;
    touch-action: manipulation;
    cursor: pointer;
    user-select: none;
    overflow: hidden;
    /* enable ripple */
    transition: transform 0.08s ease-out,
        box-shadow 0.16s ease-out,
        background 0.16s ease-out,
        opacity 0.12s ease-out;
    transform-origin: center;
}

/* Hover glow (desktop only) */
@media (hover: hover) and (pointer: fine) {

    .btn:hover,
    button:hover,
    a[role="button"]:hover,
    .btn-plain:hover {
        transform: translateY(-1px);
        box-shadow: 0 0 12px rgba(255, 255, 255, 0.08),
            0 0 24px rgba(255, 30, 86, 0.25);
    }
}

/* Active press (mobile) */
@media (hover: none) {

    .btn:active,
    button:active,
    a[role="button"]:active,
    .btn-plain:active {
        transform: scale(0.94);
        opacity: 0.9;
    }
}

/* Keyboard focus ring */
.btn:focus-visible,
button:focus-visible,
a[role="button"]:focus-visible,
.btn-plain:focus-visible {
    outline: none;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3),
        0 0 0 6px rgba(255, 30, 86, 0.35);
    transition: box-shadow 0.15s ease-out;
}

/* Ripple effect */
.btn::after,
button::after,
a[role="button"]::after,
.btn-plain::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    opacity: 0;
    pointer-events: none;
}

.btn:active::after,
button:active::after,
a[role="button"]:active::after,
.btn-plain:active::after {
    width: 180%;
    height: 180%;
    opacity: 0.12;
    transition: width 0.45s ease-out,
        height 0.45s ease-out,
        opacity 0.55s ease-out;
}


/* Slight auto-scale on tiny screens */
@media (max-width: 360px) {

    .btn,
    button,
    a[role="button"],
    .btn-plain {
        font-size: 0.82rem;
        padding: 8px 12px;
    }
}

/* When there is no CTA (registration closed), keep layout tidy */
.registration-closed-text {
    font-size: 0.76rem;
    color: var(--text-subtle);
    text-align: center;
}


/* -----------------------------------------------------
   Avatars
----------------------------------------------------- */
.avatar-row {
    margin-top: 10px;
    display: flex;
    gap: 20px;
    padding-bottom: 4px;
    justify-content: center;
}

.avatar-pill {
    position: relative;
    flex: 0 0 auto;
    width: 46px;
}

@keyframes goldGlow {
    0% {
        filter: drop-shadow(0 0 2px #ffffff) drop-shadow(0 0 4px #ffdf8c);
    }

    25% {
        filter: drop-shadow(0 0 3px #ffe9ad) drop-shadow(0 0 6px #ffcc57);
    }

    50% {
        filter: drop-shadow(0 0 4px #fff2c2) drop-shadow(0 0 10px #ffd34d);
    }

    75% {
        filter: drop-shadow(0 0 3px #ffe9ad) drop-shadow(0 0 6px #ffcc57);
    }

    100% {
        filter: drop-shadow(0 0 2px #ffffff) drop-shadow(0 0 4px #ffdf8c);
    }
}

.gold-glow {
    animation: goldGlow 3s ease-in-out infinite;
}

.avatar-pill img {
    width: 64px;
    height: 64px;
    border-radius: 999px;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.0);
}

.avatar-status-dot {
    position: absolute;
    bottom: 0;
    right: -2px;
    width: 16px;
    height: 16px;
    border-radius: 999px;
    border: 2px solid #020617;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #020617;
    font-size: 0.6rem;
    z-index: 1;
}

.avatar-status-dot.accepted {
    color: var(--accent-green);
}

.avatar-status-dot.rejected {
    color: var(--accent-red);
}

.avatar-status-dot.no_response {
    color: var(--accent-amber);
}

.avatar-crown {
    position: absolute;
    top: -12px;
    left: 18px;
    font-size: 1.4rem;
    color: #fbbf24;
    text-shadow: 0 0 4px rgba(0, 0, 0, 0.8);
}

/* Avatar section inside hero card */
.avatar-section {
    margin-top: 14px;
    padding-top: 10px;
    border-top: 1px solid rgba(15, 23, 42, 0.2);
    position: relative;
    z-index: 1;
}

.avatar-label {
    margin-bottom: 6px;
    display: block;
}

.avatar-ticket-badge {
    position: absolute;
    bottom: 0px;
    left: 20px;
    background: linear-gradient(135deg, #ffbf3c, #ff8a3c);
    color: #000;
    font-size: 0.5rem;
    font-weight: 700;
    padding: 2px 5px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
    z-index: 0;
}

/* -----------------------------------------------------
   Section Cards
----------------------------------------------------- */
.section-card {
    margin-top: 16px;
    margin-bottom: 16px;
    padding: 14px 14px 10px;
    border-radius: var(--radius-lg);
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    box-shadow: var(--shadow-soft);
}

.section-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.section-card-header h2 {
    font-size: 0.9rem;
    font-weight: 600;
    margin: 0;
}

.section-card-header small {
    font-size: 0.7rem;
    color: var(--text-subtle);
}

/* -----------------------------------------------------
   Match List (Schedule & History)
----------------------------------------------------- */
.match-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.match-item {
    padding: 10px 12px 8px;
    border-radius: 18px;
    background: rgba(5, 10, 30, 0.96);
    border: 1px solid rgba(30, 64, 175, 0.6);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
}

/* Top row: logo + title + date/time + count */
.match-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.hero-team-link-icon {
    display: inline-flex;
    align-items: center;
    margin-left: 6px;
    text-decoration: none;
    vertical-align: middle;
}

.hero-team-logo-small {
    width: 1.1em;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    transition: transform 0.2s ease;
}

.hero-team-link-icon:hover .hero-team-logo-small {
    transform: scale(1.1);
}

.match-header-main {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.match-team-logo {
    width: 32px;
    height: 32px;
    border-radius: 999px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.9);
}

.match-team-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.match-header-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.match-team-name {
    font-size: 0.88rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.badge-top {
    font-size: 0.65rem;
    padding: 3px 7px;
    border-radius: 999px;
    background: rgba(248, 113, 113, 0.22);
    color: #fecaca;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-left: 4px;
}

.badge-top i {
    font-size: 0.75rem;
}

.match-header-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    font-size: 0.72rem;
    color: var(--text-subtle);
}

.match-meta-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(51, 65, 85, 0.8);
}

.match-meta-pill i {
    font-size: 0.75rem;
}

/* Small attendee count bubble on the right */
.match-attendees-count {
    min-width: 24px;
    height: 24px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(148, 163, 184, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    color: var(--text-subtle);
}

/* Remove any accidental underline */
.match-attendees-row a {
    text-decoration: none;
}

/* History cards slightly dimmer */
.history-item {
    opacity: 0.82;
    background: rgba(5, 10, 25, 0.85);
}

/* History toggle button */
.history-toggle {
    margin: 8px auto 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 0.8rem;
}

/* Collapsible "older" history block */
.history-older {
    margin-top: 8px;
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transform: translateY(-4px);
    transition:
        max-height 0.28s ease,
        opacity 0.2s ease,
        transform 0.2s ease;
}

/* Expanded state */
.history-older[data-collapsed="false"] {
    max-height: fit-content;
    opacity: 1;
    transform: translateY(0);
}

/* Right-side block in header (avatars or empty text) */
.match-header-right {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: 8px;
}

/* Inline avatars on the right */
.match-attendees-inline {
    display: flex;
    align-items: center;
    gap: 4px;
}

.match-avatar {
    display: inline-block;
    text-decoration: none;
}

.match-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 999px;
    object-fit: cover;
    border: 2px solid rgba(5, 10, 30, 1);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.6);
}

.match-attendees-empty {
    font-size: 0.72rem;
    color: var(--text-subtle);
    opacity: 0.9;
}

/* Old bottom-row layout no longer used, but keep safe defaults */
.match-attendees-row {
    display: none;
}

/* -----------------------------------------------------
   Register Section
----------------------------------------------------- */
.register-card {
    text-align: center;
}

.register-card h3 {
    font-size: 1rem;
    margin-bottom: 4px;
}

.register-card h4 {
    font-size: 0.85rem;
    color: var(--text-subtle);
    margin-bottom: 12px;
}

.register-cta {
    display: flex;
    gap: 10px;
    justify-content: center;
}

/* -----------------------------------------------------
   Bottom Navigation
----------------------------------------------------- */
.bottom-nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 6px 16px calc(env(safe-area-inset-bottom) - 8px);
    background: linear-gradient(to top, rgba(10, 10, 30, 0.97), rgba(10, 10, 30, 0.94));
    backdrop-filter: blur(18px);
    border-top: 1px solid rgba(148, 163, 184, 0.25);
    z-index: 40;
}

.bottom-nav-inner {
    max-width: 768px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-chip {
    flex: 1;
    text-align: center;
    color: var(--text-subtle);
    font-size: 0.65rem;
    text-decoration: none;
    padding: 6px 0;
    border-radius: var(--radius-pill);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    transition: background 0.15s ease, color 0.15s ease, transform 0.08s ease-out;
}

.nav-chip i {
    font-size: 1rem;
}

.nav-chip.active {
    background: radial-gradient(circle at top, var(--accent-soft), transparent 70%);
    color: var(--text-main);
}

.nav-chip:active {
    transform: scale(0.96);
}

/* Footer */
footer.footer {
    background: transparent;
    color: var(--text-subtle);
    font-size: 0.7rem;
    margin-top: 12px;
    text-align: center;
}

footer.footer .container {
    max-width: 480px;
}


/* Fullscreen overlay */
.app-loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease-out;
}

/* Visible state */
.app-loading-overlay.show {
    opacity: 1;
    pointer-events: all;
}

/* Spinner */
.spinner {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 4px solid rgba(255, 255, 255, 0.15);
    border-top-color: var(--accent);
    animation: spin 0.9s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* -----------------------------------------------------
   Flash Messages
----------------------------------------------------- */
.alert {
    padding: 12px 16px;
    margin-bottom: 16px;
    border-radius: var(--radius-lg);
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

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

.alert-success {
    background: rgba(53, 228, 140, 0.15);
    border: 1px solid rgba(53, 228, 140, 0.3);
    color: #6ee7b7;
}

.alert-error {
    background: rgba(255, 75, 75, 0.15);
    border: 1px solid rgba(255, 75, 75, 0.3);
    color: #fca5a5;
}

/* ===================================
   STATS TABLE STYLES
   =================================== */
.stats-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.stats-table thead tr {
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.stats-table tbody tr {
    border-bottom: 1px solid rgba(148, 163, 184, 0.1);
}

.stats-table tbody tr:last-child {
    border-bottom: none;
}

.stats-table th {
    padding: 8px;
    color: var(--text-subtle);
    font-size: 0.85rem;
    font-weight: 600;
}

.stats-table td {
    padding: 12px 8px;
    font-size: 0.9rem;
}

.stats-table .text-left {
    text-align: left;
}

.stats-table .text-center {
    text-align: center;
}

.stats-table .stat-label-cell {
    color: var(--text-subtle);
}

.stats-table .stat-value-cell {
    font-weight: 600;
    font-size: 1rem;
}

/* Form Pills */
.form-pills {
    display: flex;
    gap: 6px;
    justify-content: flex-end;
}

.form-pill {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--text-subtle);
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(148, 163, 184, 0.2);
    cursor: help;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    transition: all 0.2s ease;
}

.form-pill:hover {
    transform: translateY(-1px) scale(1.05);
    z-index: 1;
}

.form-pill--win {
    color: var(--accent-green);
    border-color: rgba(53, 228, 140, 0.25);
    background: radial-gradient(circle, rgba(53, 228, 140, 0.12) 0%, rgba(15, 23, 42, 0.4) 70%);
    box-shadow: 0 0 12px rgba(53, 228, 140, 0.05);
}

.form-pill--win:hover {
    border-color: rgba(53, 228, 140, 0.5);
    box-shadow: 0 0 16px rgba(53, 228, 140, 0.2);
    color: #fff;
    text-shadow: 0 0 8px rgba(53, 228, 140, 0.8);
}

.form-pill--loss {
    color: var(--accent-red);
    border-color: rgba(255, 75, 75, 0.25);
    background: radial-gradient(circle, rgba(255, 75, 75, 0.12) 0%, rgba(15, 23, 42, 0.4) 70%);
    box-shadow: 0 0 12px rgba(255, 75, 75, 0.05);
}

.form-pill--loss:hover {
    border-color: rgba(255, 75, 75, 0.5);
    box-shadow: 0 0 16px rgba(255, 75, 75, 0.2);
    color: #fff;
    text-shadow: 0 0 8px rgba(255, 75, 75, 0.8);
}

.form-pill--draw {
    color: var(--accent-amber);
    border-color: rgba(255, 191, 60, 0.25);
    background: radial-gradient(circle, rgba(255, 191, 60, 0.12) 0%, rgba(15, 23, 42, 0.4) 70%);
    box-shadow: 0 0 12px rgba(255, 191, 60, 0.05);
}

.form-pill--draw:hover {
    border-color: rgba(255, 191, 60, 0.5);
    box-shadow: 0 0 16px rgba(255, 191, 60, 0.2);
    color: #fff;
    text-shadow: 0 0 8px rgba(255, 191, 60, 0.8);
}

/* Tooltip Styles */
.form-pill {
    position: relative;
}

.form-pill::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    background: rgba(15, 23, 42, 0.95);
    color: #fff;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 0.75rem;
    white-space: nowrap;
    max-width: none;
    text-align: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.form-pill::before {
    content: "";
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-2px);
    border-width: 6px;
    border-style: solid;
    border-color: rgba(15, 23, 42, 0.95) transparent transparent transparent;
    opacity: 0;
    transition: opacity 0.2s;
    pointer-events: none;
    z-index: 100;
}

.form-pill:hover::after,
.form-pill:focus::after,
.form-pill:active::after,
.form-pill:hover::before,
.form-pill:focus::before,
.form-pill:active::before {
    opacity: 1;
    pointer-events: auto;
}

/* Prevent right-side overflow for the last few items */
.form-pill:nth-last-child(-n+3)::after {
    left: auto;
    right: -4px;
    /* Slight offset to align better visually */
    transform: translateY(-8px);
}

.form-pill:nth-last-child(-n+3)::before {
    left: auto;
    right: 6px;
    /* Center of 24px pill */
    transform: translateY(-2px);
}

/* ===================================
   TEAM PROFILE STYLES
   =================================== */

.team-header-card {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 24px;
    background: rgba(30, 41, 59, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(20px) saturate(140%);
    -webkit-backdrop-filter: blur(20px) saturate(140%);
    background: radial-gradient(circle at top left, rgba(255, 255, 255, 0.15), transparent 70%), linear-gradient(135deg, var(--team-c1, rgba(30, 41, 59, 0.4)), var(--team-c2, rgba(30, 41, 59, 0.4)));
}

.team-header-card.has-c3 {
    background: radial-gradient(circle at top left, rgba(255, 255, 255, 0.15), transparent 70%), linear-gradient(135deg, var(--team-c1, rgba(30, 41, 59, 0.4)), var(--team-c2, rgba(30, 41, 59, 0.4)), var(--team-c3, rgba(30, 41, 59, 0.4)));
}

.team-banner {
    height: 160px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.team-banner-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.2), rgba(15, 23, 42, 0.9));
}

.team-identity {
    position: relative;
    margin-top: -40px;
    padding: 0 20px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.team-badge-lg {
    width: 80px;
    height: 80px;
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.4));
    margin-bottom: 12px;
}

.team-name-lg {
    font-family: "Space Grotesk", sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    color: #f8fafc;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.players-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 12px;
    padding-bottom: 24px;
}

.player-card {
    background: rgba(30, 41, 59, 0.4);
    border: 1px solid rgba(148, 163, 184, 0.1);
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px 8px;
    transition: transform 0.2s ease;
    text-decoration: none;
    color: inherit;
}

.player-identity {
    position: relative;
    margin: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    text-align: center;
}

.player-image-lg {
    height: 200px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.3));
}

.player-image-thumb {
    height: 200px;
    width: auto;
    border-radius: 12px;
    object-fit: cover;
}

.player-placeholder-lg {
    width: 120px;
    height: 120px;
    font-size: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.5);
}

.player-subtitle {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.1rem;
    margin-top: 5px;
}

.bio-content {
    padding: 0 20px 20px;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

.socials-container {
    padding: 0 20px 20px;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.player-card:active {
    transform: scale(0.98);
}

.player-image-wrapper {
    width: 80px;
    height: 80px;
    margin-bottom: 8px;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-end;
}

.player-cutout {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.3));
}

.player-placeholder {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(148, 163, 184, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(148, 163, 184, 0.5);
    font-size: 1.5rem;
}

.player-info {
    text-align: center;
    width: 100%;
}

.player-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-position {
    font-size: 0.65rem;
    color: var(--text-subtle);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* -----------------------------------------------------
   Chat & Reactions Styles
----------------------------------------------------- */

.chat-submit-btn {
    background: #fff;
    color: #000;
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: bold;
    cursor: pointer;
    transition: opacity 0.2s;
}

.chat-messages-container {
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
}

.chat-message-row {
    display: flex;
    gap: 10px;
    align-items: flex-end;
}

.chat-message-row.is-me {
    flex-direction: row-reverse;
}

.chat-user-avatar-container {
    width: 40px;
    height: 40px;
    overflow: hidden;
    flex-shrink: 0;
}

.chat-user-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.chat-user-avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: bold;
}

.chat-bubble {
    position: relative;
    background: rgba(255, 255, 255, 0.05);
    padding: 6px 12px;
    margin-bottom: 15px;
    border-radius: 12px 12px 12px 0;
    max-width: 80%;
    cursor: pointer;
    user-select: none;
    margin-left: 6px;
}

.chat-bubble::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: -12px;
    width: 12px;
    height: 12px;
    background: inherit;
    clip-path: polygon(100% 0, 0% 100%, 100% 100%);
}

.chat-message-row.is-me .chat-bubble {
    background: #3b82f6;
    border-radius: 12px 12px 0 12px;
    margin-left: 0;
    margin-right: 6px;
}

.chat-message-row.is-me .chat-bubble::after {
    left: auto;
    right: -6px;
    clip-path: polygon(0 0, 0 100%, 100% 100%);
    transform: none;
}

.chat-bubble-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
    gap: 10px;
}

.chat-message-row.is-me .chat-bubble-header {
    flex-direction: row-reverse;
}

.chat-media-container {
    margin-top: 10px;
}

.chat-media-img,
.chat-media-video {
    max-width: 100%;
    max-height: 300px;
    border-radius: 8px;
}

.chat-media-link {
    color: #fff;
    text-decoration: underline;
}

.chat-text-content {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.4;
}

.chat-message-row.is-me .chat-text-content {
    text-align: right;
}

.chat-timestamp {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
}

.chat-reactions-pill {
    position: absolute;
    bottom: -12px;
    left: 0;
    display: flex;
    gap: 2px;
    background: #222;
    padding: 2px 6px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    align-items: center;
    z-index: 1;
}

.chat-message-row.is-me .chat-reactions-pill {
    left: auto;
    right: 0;
}

.reaction-emoji {
    font-size: 0.8rem;
    line-height: 1;
}

.reaction-count {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.9);
    margin-left: 4px;
    font-weight: 500;
}

.no-messages-placeholder {
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    padding: 20px;
}

/* Modal Styles */
.reaction-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.reaction-modal-content {
    background: #1a1a1a;
    width: 90%;
    max-width: 400px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
}

.reaction-tabs-container {
    display: flex;
    background: #222;
    padding: 10px;
    gap: 10px;
    overflow-x: auto;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.reaction-list-scroll {
    max-height: 300px;
    overflow-y: auto;
    padding: 10px;
}

.reaction-modal-close-container {
    padding: 10px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.reaction-modal-close-btn {
    background: transparent;
    border: none;
    color: #3b82f6;
    font-weight: bold;
    cursor: pointer;
}

/* Global Picker Styles */
.global-reaction-picker {
    display: none;
    position: absolute;
    background: #222;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 25px;
    padding: 5px 10px;
    gap: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
    z-index: 90;
    transform: translateX(-50%);
}

.picker-emoji-btn {
    background: transparent;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    transition: transform 0.1s;
    animation: popIn 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}

/* Animation */
@keyframes popIn {
    from {
        transform: scale(0);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.reaction-tab {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    padding: 5px 10px;
    border-radius: 15px;
    cursor: pointer;
    white-space: nowrap;
    font-size: 0.9rem;
}

.reaction-tab.active {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.reaction-user-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.reaction-user-row:last-child {
    border-bottom: none;
}

/* Chat Input Redesign */
.chat-form {
    margin-top: auto;
    position: relative;
    z-index: 10;
}

.chat-input-wrapper {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    background: rgba(10, 10, 30, 0.8);
    padding: 10px;
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.chat-input-field {
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    font-family: inherit;
    font-size: 0.95rem;
    padding: 8px 0;
    resize: none;
    max-height: 100px;
    min-height: 24px;
    outline: none;
}

.chat-action-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.1s, background 0.2s;
    flex-shrink: 0;
}

.attachment-toggle-btn {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
}

.attachment-toggle-btn:active {
    transform: scale(0.95);
    background: rgba(255, 255, 255, 0.2);
}

.send-btn {
    background: #3b82f6;
    color: #fff;
}

.send-btn:active {
    transform: scale(0.95);
    background: #2563eb;
}

.attachment-dropdown {
    position: relative;
}

.attachment-menu {
    position: absolute;
    bottom: 50px;
    left: 0;
    background: #222;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 5px;
    min-width: 150px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    display: none;
    flex-direction: column;
    gap: 5px;
    animation: slideUp 0.2s ease-out;
}

.attachment-menu.show {
    display: flex;
}

.attachment-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    color: #fff;
    font-size: 0.9rem;
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.2s;
}

.attachment-option:hover {
    background: rgba(255, 255, 255, 0.1);
}

.attachment-option i {
    width: 20px;
    text-align: center;
    color: #3b82f6;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

/* Date Bubble */
.chat-date-bubble {
    align-self: center;
    background: rgba(40, 40, 40, 0.8);
    color: rgba(255, 255, 255, 0.9);
    padding: 5px 12px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 500;
    margin: 15px 0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(4px);
    z-index: 5;
    text-align: center;
    width: fit-content;
}

.video-container {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 12px;
}

.video-iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.event-header-bg {
    background: radial-gradient(circle at top left, rgba(255, 255, 255, 0.15), transparent 70%), linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(0, 0, 0, 0.5));
}

.event-header-image {
    height: 200px;
    width: auto;
    border-radius: 12px;
    object-fit: cover;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.3));
}

.section-content-padded {
    padding: 0 20px 20px;
}

/* Reaction User List Styles */
.reaction-user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.reaction-user-avatar {
    width: 32px;
    height: 32px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: bold;
    font-size: 0.8rem;
}

.reaction-user-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.reaction-user-name {
    color: #fff;
    font-size: 0.9rem;
}

.reaction-remove-btn {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    text-decoration: underline;
}

.reaction-emoji-display {
    font-size: 1.2rem;
}

/* -----------------------------------------------------
   Fullscreen Media Overlay
----------------------------------------------------- */
.media-fullscreen-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(10, 10, 20, 0.1);
    /* Semi-transparent dark background */
    backdrop-filter: blur(15px);
    /* Glassmorphism blur effect */
    -webkit-backdrop-filter: blur(15px);
    /* Safari support */
    display: none;
    /* Hidden by default */
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.media-fullscreen-overlay.show {
    display: flex;
    opacity: 1;
}

.media-fullscreen-content {
    position: relative;
    max-width: 100%;
    max-height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
}

.fullscreen-media-item {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.media-fullscreen-close {
    position: absolute;
    top: env(safe-area-inset-top);
    right: 20px;
    background: rgba(255, 255, 255, 0.4);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 10000;
    margin-top: 20px;
    backdrop-filter: blur(4px);
}

.media-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: white;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 10000;
    backdrop-filter: blur(4px);
    transition: background 0.2s;
}

.media-nav-btn:active {
    background: rgba(255, 255, 255, 0.3);
}

.media-nav-btn:hover {
    transform: translateY(-50%) scale(1.1);
    background: rgba(255, 255, 255, 0.25);
}

.media-prev-btn {
    left: 15px;
}

.media-next-btn {
    right: 15px;
}