/* CSS Design for Malmö MUF - Refined per feedback */
@font-face {
    font-family: 'Gotham Narrow';
    src: url('../fonts/GothamNarrow-Book.otf') format('opentype');
    font-weight: normal;
}

@font-face {
    font-family: 'Gotham Narrow';
    src: url('../fonts/GothamNarrow-Bold.otf') format('opentype');
    font-weight: bold;
}

:root {
    --muf-cyan: #64C1EC;
    --muf-navy: #001489;
    --muf-dark: #224776;
    --muf-beige: #EFE7DC;
    --muf-yellow: #FFD200;
    --swish-green: #37A144;
    /* Official Swish Green or similar */
    --white: #ffffff;
    --black: #000000;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    /* Z-Index Stacking Layers */
    --z-base: 0;
    --z-card-overlay: 1;
    --z-interact: 10;
    --z-sticky: 1000;
    --z-modal-overlay: 10000;
    --z-modal-content: 10001;
    --z-navbar: 2147483647;
}

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

html {
    scroll-behavior: smooth;
}

html, body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

body {
    font-family: 'Gotham Narrow', sans-serif;
    color: var(--muf-dark);
    background-color: var(--white);
    line-height: 1.5;
}

/* Header & Navigation */
header {
    position: fixed;
    top: 0;
    width: 100%;
    height: 120px;
    background: var(--white);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 4rem;
    z-index: 1000;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
}

.logo img {
    height: 80px;
    width: auto;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 3rem;
}

.desktop-nav {
    display: flex;
    gap: 2.5rem;
}

.nav-link {
    text-decoration: none;
    color: var(--muf-dark);
    font-weight: bold;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition);
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--muf-cyan);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.hamburger-btn {
    font-size: 26px;
    background: none;
    border: none;
    cursor: pointer;
    display: none; /* Hidden on desktop */
    z-index: 1001;
    color: var(--muf-navy);
}

/* Mobile slide-down menu overlay */
.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9998;
}

.mobile-menu.open {
    display: block;
}

.mobile-menu-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(2px);
}

.mobile-menu-panel {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: #fff;
    padding: 1.5rem 2rem 2rem;
    border-radius: 0 0 24px 24px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
    transform: translateY(-105%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 9999;
}

.mobile-menu.open .mobile-menu-panel {
    transform: translateY(0);
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #f0f0f0;
}

.mobile-menu-header img {
    height: 44px;
    width: auto;
}

.mobile-menu-close {
    font-size: 1.6rem;
    color: var(--muf-navy);
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
    transition: var(--transition);
}

.mobile-menu-close:hover {
    background: rgba(100,193,236,0.15);
    color: var(--muf-cyan);
}

.mobile-menu-links {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.mobile-menu-links a {
    text-decoration: none;
    font-weight: 900;
    font-size: 1.05rem;
    text-transform: uppercase;
    color: var(--muf-navy);
    padding: 0.75rem 1rem;
    border-radius: 12px;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: var(--transition);
}

.mobile-menu-links a:hover,
.mobile-menu-links a.active {
    background: linear-gradient(135deg, rgba(100,193,236,0.15), rgba(0,20,137,0.08));
    color: var(--muf-navy);
    padding-left: 1.5rem;
}

.mobile-menu-links .menu-divider {
    height: 1px;
    background: #f0f0f0;
    margin: 0.5rem 0;
}

.mobile-menu-links .logout-link {
    color: #ff5252 !important;
}

.mobile-menu-links .logout-link:hover {
    background: rgba(255,82,82,0.1) !important;
}

/* Mobile header profile badge */
.mobile-profile-btn {
    display: none;
    align-items: center;
    gap: 6px;
    font-weight: 900;
    font-size: 0.9rem;
    color: var(--muf-navy);
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 50px;
    background: rgba(0,20,137,0.06);
    cursor: pointer;
}

/* Header Right Tools container */
.header-right-tools {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

/* Dropdown Navigation */
.dropdown {
    position: relative;
    display: flex;
    align-items: center;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--white);
    min-width: 200px;
    box-shadow: 0px 10px 25px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    top: 100%;
    left: 0;
    border-radius: 12px;
    padding: 10px 0;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

/* Osynlig brygga för att brygga gapet mellan länk och meny */
.dropdown-content::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 0;
    width: 100%;
    height: 20px;
}

.dropdown:hover .dropdown-content,
.dropdown.active .dropdown-content {
    display: block;
}

.dropdown-content a {
    color: var(--muf-dark);
    padding: 12px 20px;
    text-decoration: none;
    display: block;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.95rem;
    transition: var(--transition);
}

.dropdown-content a:hover {
    background-color: var(--muf-beige);
    color: var(--muf-navy);
}

.dropdown i {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.dropdown:hover > .nav-link i {
    transform: rotate(180deg);
}

.dropdown-content a i {
    font-size: 1rem;
    vertical-align: middle;
    margin-right: 12px;
}

/* Sections */
.section {
    padding: 120px 0;
    min-height: 80vh;
}

.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
}

.beige-bg {
    background-color: var(--muf-beige);
}

.section-title {
    font-size: 3.5rem;
    text-transform: uppercase;
    font-weight: bold;
    margin-bottom: 5rem;
    text-align: center;
    letter-spacing: 1px;
}

.section-title-small {
    font-size: 2.5rem;
    text-transform: uppercase;
    font-weight: bold;
    margin-bottom: 1.5rem;
    letter-spacing: 1px;
}

.activity-section {
    position: relative;
    overflow: hidden;
    padding: 100px 0;
}

.activity-scroll-track {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    display: flex;
    width: max-content;
    /* Fit all images in a row */
    animation: scrollTrack 60s linear infinite;
    z-index: 0;
    /* Background layer */
}

.activity-slide {
    width: 400px;
    /* Width of each image */
    height: 100%;
    background-size: cover;
    background-position: right center;
    /* Focus on the faces usually on the right */
    flex-shrink: 0;
    opacity: 0.35;
    /* Increased opacity slightly for visibility */
}

@keyframes scrollTrack {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }

    /* Scroll through the first set */
}

.activity-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.7);
    /* White overlay for background images */
    z-index: 1;
    /* Above images, below content */
    pointer-events: none;
}

/* Onsdagsaktiviteter */
.activity-card {
    background: #ffffff;
    /* Helt solid vit för maximal skärpa */
    border: 5px solid var(--muf-navy);
    /* Ännu tydligare ram */
    padding: 3.5rem;
    border-radius: 40px;
    text-align: center;
    max-width: 850px;
    margin: 0 auto;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.2);
    position: relative;
    z-index: 10;
    /* Högst upp */
}

.activity-badge {
    display: inline-block;
    background: var(--muf-navy);
    color: var(--white);
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    font-weight: 900;
    font-size: 0.9rem;
    margin-bottom: 2rem;
}

.activity-desc {
    font-size: 1.3rem;
    font-weight: 500;
    margin-bottom: 3rem;
    color: var(--muf-dark);
    line-height: 1.6;
}

.contact-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.contact-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.contact-box p {
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.8rem;
    color: #888;
    margin: 0;
}

.contact-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: var(--muf-dark);
    color: var(--white);
    padding: 0.8rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 900;
    font-size: 0.9rem;
    transition: var(--transition);
    min-width: 160px;
}

.instagram-btn {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
}

.contact-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    filter: brightness(1.1);
}

/* Hero Section */
.hero-section {
    min-height: 100vh;
    background-image: url('../img/MUF valstuga.jpg');
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 140px 0 60px;
    /* Space for fixed header and some bottom padding */
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.45);
    /* Lighter tint to show more of the images */
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    z-index: 1;
}

.hero-bg-secondary {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../img/moderata-ungdomsförbundet-valkonvent.jpg');
    background-size: cover;
    background-position: center;
    z-index: 0;
    opacity: 0;
    animation: heroFade 10s ease-in-out infinite alternate;
}

@keyframes heroFade {
    0% { opacity: 0; }
    40% { opacity: 0; }
    60% { opacity: 1; }
    100% { opacity: 1; }
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--muf-dark);
    /* Dark text for contrast on white tint */
    max-width: 900px;
}

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

.hero-content h1,
.hero-content h2 {
    font-size: 5.5rem;
    font-weight: 900;
    margin-bottom: 0.5rem;
    letter-spacing: -1px;
    text-shadow: 0 2px 20px rgba(255, 255, 255, 1), 0 0 5px rgba(255, 255, 255, 0.5);
    /* White halo to pop against images */
}

.hero-content p {
    font-size: 1.6rem;
    font-weight: 900;
    margin-bottom: 3.5rem;
    letter-spacing: 0px;
    text-shadow: 0 0 15px rgba(255, 255, 255, 1), 0 0 5px rgba(255, 255, 255, 1);
    /* Stronger white halo for paragraph text */
    line-height: 1.4;
    color: var(--muf-navy); /* Use a slightly darker blue for better contrast */
}

/* Swish Card - Transparent per request */
/* Small Swish Card - Glassmorphism */
.swish-card-small {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 1.5rem;
    border-radius: 20px;
    color: var(--muf-dark);
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.2);
    max-width: 380px;
}

.swish-btn-green-small {
    background-color: var(--swish-green);
    color: var(--white);
    padding: 1rem 2.5rem;
    border-radius: 40px;
    text-decoration: none;
    font-weight: 800;
    font-size: 1.1rem;
    transition: var(--transition);
    box-shadow: 0 8px 15px rgba(55, 161, 68, 0.3);
}

.swish-btn-green-small:hover {
    transform: scale(1.03);
    filter: brightness(1.1);
}

.swish-info-text {
    font-size: 0.9rem;
    opacity: 0.9;
    text-align: center;
}

.qr-container-small {
    display: flex;
    align-items: center;
    justify-content: center;
}

.swish-qr-img {
    width: 120px;
    height: auto;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.swish-number-small {
    font-size: 1rem;
    font-weight: bold;
    color: var(--muf-cyan);
}

/* Board Grid Equal Distribution */
.board-grid-equal {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 4rem;
    justify-items: center;
}

.member-card {
    position: relative; /* Audit Fix */
    background: var(--white);
    padding: 3rem;
    border-radius: 24px;
    text-align: center;
    transition: var(--transition);
    width: 100%;
    max-width: 350px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.member-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.member-img {
    width: 160px;
    height: 160px;
    background-color: var(--muf-beige);
    background-size: cover;
    background-position: center;
    border-radius: 50%;
    margin: 0 auto 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: var(--muf-navy);
}

.member-img i {
    opacity: 0.5;
    /* Gör placeholder-ikonen lite svagare om en bild dyker upp? Eller bara göm i html, men bra att ha */
}

.member-info h3 {
    font-size: 1.6rem;
    margin-bottom: 0.5rem;
    font-weight: bold;
}

.member-info p {
    color: var(--muf-cyan);
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.9rem;
}

/* Social Media Collage */
.social-collage {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 250px;
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.collage-item {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    background-color: var(--muf-navy);
}

.collage-item::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    opacity: 0.3;
    transition: var(--transition);
}

.collage-item:hover::before {
    opacity: 0.8;
}

.collage-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.social-overlay {
    position: absolute;
    color: var(--white);
    font-size: 3.5rem;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 2;
}

.collage-item:hover .social-overlay {
    opacity: 1;
    transform: scale(1);
}

/* Tiktok specific overlay color on hover if wanted, otherwise white is fine */
.social-overlay.tiktok-color {
    text-shadow: 2px 2px 0px #ff0050, -2px -2px 0px #00f2fe;
}

/* Span classes for masonry effect */
.collage-item-large {
    grid-column: span 2;
    grid-row: span 2;
}

.collage-item-tall {
    grid-row: span 2;
}

.collage-item-wide {
    grid-column: span 2;
}

.social-buttons-classic {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

/* TikTok Button Style */
.tiktok-btn {
    background: #000;
}

.tiktok-btn:hover {
    background: #333;
}

/* Footer */
footer {
    background: var(--muf-dark);
    color: var(--white);
    padding: 5rem 2rem;
    text-align: center;
}

.footer-logo {
    height: 50px;
    margin-bottom: 2rem;
}

/* Base Styles for Subpages */
.subpage-hero {
    padding: 180px 0 100px;
    background: var(--muf-navy);
    color: var(--white);
    text-align: center;
}

.subpage-hero h1,
.subpage-hero h2 {
    font-size: 4rem;
    text-transform: uppercase;
    font-weight: 900;
}

/* Mobile Responsive */
@media (max-width: 1024px) {
    header {
        padding: 0 2rem;
    }

    .hero-content h1,
    .hero-content h2 {
        font-size: 4.5rem;
    }

    .container {
        padding: 0 1.5rem;
    }
}

@media (max-width: 768px) {
    .hero-content h1,
    .hero-content h2,
    .subpage-hero h1,
    .subpage-hero h2 {
        font-size: 2.8rem;
        word-break: break-word;
    }

    header {
        height: 70px;
        padding: 0 1rem;
    }

    .logo img {
        height: 44px;
    }

    /* Hide desktop nav on mobile */
    header > nav,
    header nav {
        display: none !important;
    }

    /* Hide desktop dropdown on mobile (Exempt the notification bell) */
    header > div:last-child > .dropdown:not(.notif-dropdown) {
        display: none !important;
    }
    
    .header-right-tools {
        gap: 0.8rem !important;
    }

    .notif-dropdown {
        display: block !important;
    }
    
    /* Streak visible on mobile */
    header > div:last-child > div:first-child {
        display: flex !important;
        padding: 4px 8px !important;
        font-size: 0.8rem !important;
    }

    .hamburger-btn {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-profile-btn {
        display: flex;
        padding: 6px !important;
        background: none !important;
    }
    
    .mobile-profile-btn span {
        display: none; /* Hide name on mobile header to save space */
    }

    .swish-card,
    .swish-card-small {
        padding: 1.5rem;
        width: 100%;
        margin-top: 1rem;
    }

    .swish-btn-green,
    .swish-btn-green-small {
        padding: 1rem 1.5rem;
        font-size: 1rem;
        width: 100%;
        text-align: center;
        margin-top: 1rem; /* Bättre spacing */
    }

    .hero-section {
        padding: 120px 0 40px;
    }

    .hero-content p {
        font-size: 1.1rem;
        margin-bottom: 2rem;
    }

    .activity-card {
        padding: 2rem 1.5rem;
    }

    .activity-desc {
        font-size: 1.1rem;
        margin-bottom: 2rem;
    }

    .section-title {
        font-size: 2.2rem;
        margin-bottom: 3rem;
    }

    .section-title-small {
        font-size: 1.8rem;
    }

    /* Social Collage Responsive */
    .social-collage {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 200px;
    }

    .collage-item-large,
    .collage-item-wide,
    .collage-item-tall {
        grid-column: span 1;
        grid-row: span 1;
    }
}

@media (max-width: 480px) {
    .social-collage {
        grid-template-columns: 1fr;
        grid-auto-rows: 250px;
    }
}

/* Interest Form */
.interest-form-container {
    max-width: 700px;
    margin: 0 auto;
    background: var(--white);
    padding: 3rem;
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.interest-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group label {
    font-weight: bold;
    font-size: 0.9rem;
    color: var(--muf-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 1rem;
    border: 2px solid var(--muf-beige);
    border-radius: 12px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--muf-cyan);
    box-shadow: 0 0 0 4px rgba(0, 217, 255, 0.1);
}

/* Responsive Form */
@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }

    .interest-form-container {
        padding: 1.5rem;
    }
}

/* Hot Streak Fire Animation - Förstärkt */
@keyframes flameGlow {
    0% { 
        box-shadow: 0 0 10px orange, 0 0 5px #ff4500; 
        border-color: #ff4500;
        transform: scale(1);
    }
    100% { 
        box-shadow: 0 0 25px red, 0 0 15px #ff8c00, 0 0 10px rgba(255,140,0,0.5); 
        border-color: #ff8c00;
        transform: scale(1.02);
    }
}

.hot-streak {
    border-radius: 50% !important;
    animation: flameGlow 1.2s infinite alternate ease-in-out;
    border: 3px solid #ff4500 !important;
    position: relative;
    z-index: 2;
}

.hot-streak::after {
    content: '🔥';
    position: absolute;
    top: -12px;
    right: -12px;
    font-size: 1.4rem;
    filter: drop-shadow(0 0 5px orange);
    z-index: 5;
    animation: pulse 1s infinite alternate;
}

/* Topp 3 Rank Colors - High Visibility */
.rank-1 { color: #FFD700 !important; font-weight: 900 !important; text-shadow: 0 0 8px rgba(255, 215, 0, 0.4); } 
.rank-2 { color: #B0B0B0 !important; font-weight: 900 !important; text-shadow: 0 0 8px rgba(192, 192, 192, 0.4); } 
.rank-3 { color: #CD7F32 !important; font-weight: 900 !important; text-shadow: 0 0 8px rgba(205, 127, 50, 0.4); } 

.rank-text { transition: 0.3s; text-decoration: none; display: inline-block; }
.rank-text:hover { transform: scale(1.05); filter: brightness(1.2); }

/* Badge & Achievement System */
.badge-section { margin-top: 4rem; text-align: left; }
.badge-category { margin-bottom: 3rem; }
.badge-category h3 { text-transform: uppercase; font-size: 0.9rem; color: #999; margin-bottom: 1.5rem; letter-spacing: 1px; }

.badge-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.5rem; }
.badge-card { background: white; padding: 2rem 1.5rem; border-radius: 24px; box-shadow: 0 5px 15px rgba(0,0,0,0.03); transition: 0.3s; border: 2px solid #efefef; text-align: center; position: relative; }
.badge-card:hover { transform: translateY(-5px); box-shadow: 0 12px 30px rgba(0,0,0,0.08); }

.badge-card.locked { opacity: 0.6; filter: grayscale(1); background: #fafafa; }
.badge-card.locked:hover { transform: none; }

.badge-icon-large { font-size: 3rem; margin-bottom: 1.2rem; display: block; }
.badge-name { font-size: 1rem; font-weight: 900; text-transform: uppercase; color: #001489; margin-bottom: 0.5rem; display: block; }
.badge-desc { font-size: 0.75rem; color: #666; line-height: 1.4; margin-bottom: 1rem; min-height: 32px; display: block; }

.badge-progress { background: #eee; height: 8px; border-radius: 10px; overflow: hidden; margin-bottom: 0.5rem; }
.badge-progress-fill { background: #64C1EC; height: 100%; border-radius: 10px; transition: width 0.5s; }
.badge-progress-text { font-size: 0.65rem; font-weight: 900; color: #999; text-transform: uppercase; }

.badge-unlocked-tag { font-size: 0.65rem; font-weight: 900; color: #4caf50; text-transform: uppercase; margin-top: 5px; display: block; }

.badge-popup { position: fixed; bottom: 30px; right: 30px; background: white; padding: 2rem; border-radius: 24px; box-shadow: 0 20px 50px rgba(0,0,0,0.2); border: 4px solid #001489; z-index: 9999; animation: slideInUp 0.5s cubic-bezier(0.18, 0.89, 0.32, 1.28); }
@keyframes slideInUp { from { transform: translateY(100px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

@media (max-width: 768px) {
    .hamburger-btn {
        display: block !important;
    }
    
    header {
        height: 70px;
        padding: 0 1rem;
    }
}

/* Notification Styles */
.notif-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: #FF4B2B;
    color: white;
    font-size: 0.6rem;
    padding: 2px 5px;
    border-radius: 50%;
    font-weight: 900;
    border: 2px solid white;
}
.notif-content {
    width: 320px !important;
    padding: 0 !important;
    border-radius: 20px !important;
    overflow: hidden;
}
.notif-header {
    padding: 1rem;
    border-bottom: 1px solid #eee;
    font-weight: 900;
    text-transform: uppercase;
    font-size: 0.7rem;
    color: #001489;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fcfdfe;
}

/* Push Switch CSS */
.push-control {
    display: flex;
    align-items: center;
}

.push-switch {
    position: relative;
    display: inline-block;
    width: 34px;
    height: 18px;
}

.push-switch input { 
    opacity: 0;
    width: 0;
    height: 0;
}

.push-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 34px;
}

.push-slider:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .push-slider {
    background-color: #22c55e;
}

input:checked + .push-slider:before {
    transform: translateX(16px);
}

.notif-item {
    display: flex !important;
    gap: 12px;
    padding: 12px 15px !important;
    border-bottom: 1px solid #f8f9fa;
    transition: 0.2s;
    align-items: center;
}
.notif-item:hover {
    background: #f8f9fa !important;
}
.notif-item.unread {
    background: rgba(100, 193, 236, 0.05) !important;
}
.notif-avatar {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    object-fit: cover;
}
.notif-item div {
    font-size: 0.8rem;
    line-height: 1.3;
    color: #333;
}
.notif-time {
    display: block;
    font-size: 0.65rem;
    color: #999;
    margin-top: 2px;
}
.mention-link {
    color: #001489;
    font-weight: 900;
    text-decoration: none;
    background: rgba(0, 20, 137, 0.05);
    padding: 2px 6px;
    border-radius: 6px;
}
.mention-link:hover {
    background: rgba(0, 20, 137, 0.1);
}

/* Reactions Styles */
.post-reactions {
    display: flex;
    gap: 8px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}
.reaction-btn {
    background: #f8f9fa;
    border: none;
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: 0.2s;
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 900;
    color: #666;
}
.reaction-btn:hover {
    background: #eee;
    transform: scale(1.05);
}
.reaction-btn.active {
    background: rgba(100, 193, 236, 0.2);
    color: #001489;
}

/* --- Point Registration Page Improvements --- */

.points-display-container {
    text-align: center;
    padding: 2.5rem 1rem;
    background: transparent;
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.points-label {
    display: block;
    font-weight: 900;
    text-transform: uppercase;
    font-size: 0.9rem;
    color: var(--muf-navy);
    letter-spacing: 1.5px;
    margin-bottom: 0.5rem;
    opacity: 0.7;
}

.points-score {
    font-size: 48px;
    font-weight: 900;
    color: var(--muf-navy);
    line-height: 1;
    display: inline-block;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Animations */
@keyframes score-pop {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.pop-animation {
    animation: score-pop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

/* Point Selection Section */
.point-selection-container {
    margin-top: 2rem;
    text-align: center;
}

.selected-amount-preview {
    font-weight: 900;
    font-size: 0.9rem;
    color: var(--muf-cyan);
    text-transform: uppercase;
    margin-bottom: 1rem;
    display: block;
    letter-spacing: 1px;
}

.point-selection-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    width: 100%;
    max-width: 100%;
}

.point-option-btn {
    height: 54px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 14px;
    font-weight: 900;
    font-size: 1.2rem;
    color: var(--muf-navy);
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-tap-highlight-color: transparent;
    outline: none;
}

.point-option-btn:active {
    transform: scale(0.94);
}

.point-option-btn.selected {
    background: var(--muf-navy);
    color: var(--white);
    border-color: var(--muf-navy);
    box-shadow: 0 10px 20px rgba(0, 20, 137, 0.15);
    animation: selection-pop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes selection-pop {
    0% { transform: scale(1); }
    50% { transform: scale(1.08); }
    100% { transform: scale(1); }
}

/* Mobile specific fixes */
@media (max-width: 600px) {
    .points-score {
        font-size: 40px;
    }
    .point-option-btn {
        height: 50px;
        font-size: 1.1rem;
        border-radius: 12px;
    }
    .point-selection-grid {
        gap: 8px;
    }
}

/* --- Category & Modal Selection System --- */

.category-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-top: 20px;
}

.category-card {
    position: relative; /* Audit Fix: Ensured relative positioning for clickable surface scoping */
    background: var(--white);
    border: 2px solid #efefef;
    border-radius: 24px;
    padding: 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.2s, border-color 0.2s;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
}

.category-card:active {
    transform: scale(0.95);
}

.category-card .cat-icon {
    font-size: 2.5rem;
    transition: transform 0.2s;
}

.category-card:hover .cat-icon {
    transform: scale(1.1);
}

.category-card span {
    font-weight: 900;
    text-transform: uppercase;
    font-size: 0.9rem;
    color: var(--muf-navy);
    letter-spacing: 1px;
}

/* Modal System */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 20, 137, 0.4);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal-overlay.active {
    display: block;
    opacity: 1;
}

.activity-modal {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--white);
    border-radius: 30px 30px 0 0;
    padding: 2.5rem 1.5rem 3rem;
    z-index: 2001;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.2);
}

.activity-modal.active {
    transform: translateY(0);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.modal-header h3 {
    font-weight: 900;
    text-transform: uppercase;
    color: var(--muf-navy);
    font-size: 1.4rem;
    margin: 0;
}

.close-modal {
    background: #f1f5f9;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--muf-navy);
}

/* Activity Items in Modal */
.modal-activity-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.modal-activity-item {
    background: #f8fafc;
    border: 2px solid #f1f5f9;
    border-radius: 20px;
    padding: 1rem 1.2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: transform 0.2s, border-color 0.2s, background 0.2s;
}

.modal-activity-item.has-count {
    border-color: var(--muf-navy);
    background: var(--white);
    box-shadow: 0 4px 12px rgba(0, 20, 137, 0.05);
}

.act-info-wrap {
    display: flex;
    flex-direction: column;
}

.act-info-wrap strong {
    font-weight: 900;
    color: var(--muf-navy);
    font-size: 1rem;
}

.act-info-wrap span {
    font-size: 0.8rem;
    color: var(--muf-cyan);
    font-weight: 700;
}

/* Quantity Controls */
.quantity-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    background: #f1f5f9;
    padding: 6px;
    border-radius: 50px;
}

.q-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: var(--white);
    color: var(--muf-navy);
    font-weight: 900;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.1s;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.q-btn:active {
    transform: scale(0.85);
}

.q-number {
    font-weight: 900;
    min-width: 25px;
    text-align: center;
    color: var(--muf-navy);
    font-size: 1.1rem;
    display: inline-block;
}

.q-pop {
    animation: q-pop-anim 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes q-pop-anim {
    0% { transform: scale(1); }
    50% { transform: scale(1.4); }
    100% { transform: scale(1); }
}

.reset-btn {
    margin-top: 2rem;
    width: 100%;
    padding: 1rem;
    border-radius: 16px;
    border: 2px dashed #cbd5e1;
    background: transparent;
    color: #64748b;
    font-weight: 900;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.2s;
}

.reset-btn:hover {
    background: #f1f5f9;
    color: var(--muf-navy);
    border-color: #94a3b8;
}


/* Modal Description & Suggestions */
.modal-description-container {
    margin-top: 2rem;
    padding: 1.5rem;
    background: linear-gradient(145deg, #ffffff, #f1f5f9);
    border-radius: 24px;
    border: 1px solid rgba(226, 232, 240, 0.8);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
    display: none;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.modal-description-container.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.modal-description-container label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 1rem;
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.7rem;
    color: #64748b;
    letter-spacing: 0.5px;
}

.modal-description-container label::before {
    content: '📝';
    font-size: 1rem;
}

.modal-description-container input {
    width: 100%;
    padding: 1.1rem 1.25rem;
    border: 2px solid #e2e8f0;
    border-radius: 18px;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 500;
    outline: none;
    background: var(--white);
    color: var(--muf-navy);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.modal-description-container input::placeholder {
    color: #94a3b8;
    font-weight: 400;
}

.modal-description-container input:focus {
    border-color: var(--muf-navy);
    box-shadow: 0 10px 15px -3px rgba(0, 20, 137, 0.15);
    background: #fff;
}

.modal-description-container input.input-error {
    border-color: #ff4d4d;
    background-color: #fff5f5;
    box-shadow: 0 0 0 4px rgba(255, 77, 77, 0.15);
}

.shake {
    animation: shake 0.5s cubic-bezier(.36,.07,.19,.97) both;
}

@keyframes shake {
    10%, 90% { transform: translate3d(-1px, 0, 0) translateY(-1px); }
    20%, 80% { transform: translate3d(2px, 0, 0) translateY(-1px); }
    30%, 50%, 70% { transform: translate3d(-4px, 0, 0) translateY(-1px); }
    40%, 60% { transform: translate3d(4px, 0, 0) translateY(-1px); }
}

.suggestion-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 1rem;
}

.suggestion-chip {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.suggestion-chip:hover {
    background: var(--white);
    border-color: var(--muf-navy);
    color: var(--muf-navy);
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 20, 137, 0.1);
}

.suggestion-chip:active {
    transform: translateY(0) scale(0.96);
}

.category-card img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.category-card:hover img {
    transform: scale(1.1);
}

.category-card span {
    font-weight: 900;
    text-transform: uppercase;
    font-size: 0.9rem;
    color: var(--muf-navy);
    letter-spacing: 1px;
}

/* Desktop Modal */
@media (min-width: 601px) {
    .activity-modal {
        bottom: auto;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -40%) scale(0.95);
        opacity: 0;
        visibility: hidden;
        width: 500px;
        border-radius: 30px;
        transition: transform 0.3s cubic-bezier(0.165, 0.84, 0.44, 1), opacity 0.3s, visibility 0.3s;
    }

    .activity-modal.active {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
        visibility: visible;
        bottom: auto;
    }
}

/* Gamified XP Animation */
.floating-xp-card {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(0);
    background: #22c55e; /* Modern Green */
    color: var(--white);
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 900;
    font-size: 1.2rem;
    box-shadow: 0 10px 25px rgba(34, 197, 94, 0.3);
    z-index: 9999;
    pointer-events: none;
    opacity: 0;
}

.floating-xp-card.animate {
    animation: xp-float 1.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes xp-float {
    0% {
        opacity: 0;
        transform: translateX(-50%) translateY(20px) scale(0.8);
    }
    15% {
        opacity: 1;
        transform: translateX(-50%) translateY(0) scale(1.1);
    }
    30% {
        transform: translateX(-50%) translateY(0) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateX(-50%) translateY(-100px) scale(0.9);
    }
}

.score-pop {
    animation: score-pop 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes score-pop {
    0% { transform: scale(1); color: inherit; }
    30% { transform: scale(1.2); color: #22c55e; }
    70% { transform: scale(1.1); color: #22c55e; }
    100% { transform: scale(1); color: inherit; }

}

/* Pull to Refresh Indicator - Refined */
#ptr-indicator {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    transition: height 0.3s cubic-bezier(0.19, 1, 0.22, 1), opacity 0.3s;
    border-bottom: 1px solid rgba(0, 20, 137, 0.1);
    opacity: 0;
    pointer-events: none;
    transform: translateY(0);
}

#ptr-indicator.refreshing {
    height: 80px !important;
    opacity: 1 !important;
}

.ptr-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transform: translateY(0);
}

.ptr-logo-wrapper {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.1s linear;
    transform: scale(0); /* Starts hidden */
}

.ptr-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.ptr-text {
    font-size: 0.65rem;
    font-weight: 950;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--muf-navy);
    opacity: 0.6;
}

/* Spinning Animation */
#ptr-indicator.refreshing .ptr-logo {
    animation: ptr-spin 1s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes ptr-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@media (min-width: 1025px) {
    #ptr-indicator { display: none !important; }
}


/* --- LOOTBOX SPINNER (CS:GO STYLE) --- */
.loot-spinner-container {
    width: 100%;
    margin: 2rem 0;
    position: relative;
    overflow: hidden;
    background: #0f172a;
    border-radius: 24px;
    height: 180px;
    border: 4px solid #1e293b;
    box-shadow: inset 0 0 80px rgba(0,0,0,0.8);
    display: flex;
    align-items: center;
}

.spinner-viewport {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.spinner-ribbon {
    display: flex;
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    transition: transform 7s cubic-bezier(0.1, 0.45, 0.1, 1);
    padding-left: 50%; /* Center the first item initially */
}

.spinner-item {
    width: 150px;
    height: 150px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.5) 0%, rgba(15, 23, 42, 0.8) 100%);
    border: 1px solid rgba(255, 255, 255, 0.05);
    margin: 0 5px;
    border-radius: 20px;
    position: relative;
    transition: 0.3s;
}

.spinner-item img {
    width: 90px;
    height: 90px;
    object-fit: contain;
    filter: drop-shadow(0 8px 15px rgba(0,0,0,0.4));
}

.spinner-item.rarity-common { border-bottom: 5px solid #94a3b8; }
.spinner-item.rarity-rare { border-bottom: 5px solid #3b82f6; }
.spinner-item.rarity-epic { border-bottom: 5px solid #a855f7; }
.spinner-item.rarity-legendary { border-bottom: 5px solid #f59e0b; }

.spinner-center-line {
    position: absolute;
    left: 50%;
    top: -5px;
    bottom: -5px;
    width: 4px;
    background: #ff4d00;
    z-index: 100;
    transform: translateX(-50%);
    box-shadow: 0 0 20px rgba(255, 77, 0, 0.6);
}

.spinner-center-line::before, .spinner-center-line::after {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    border-left: 12px solid transparent;
    border-right: 12px solid transparent;
}

.spinner-center-line::before {
    top: 0;
    border-top: 18px solid #ff4d00;
}

.spinner-center-line::after {
    bottom: 0;
    border-bottom: 18px solid #ff4d00;
}

.spinner-reveal-card {
    animation: revealPop 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes revealPop {
    from { transform: scale(0); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* PRIORITY 3: Global Status Notifications */
.status-toast {
 position: fixed;
 bottom: 2rem;
 left: 50%;
 transform: translateX(-50%) translateY(100px);
 background: rgba(0, 20, 137, 0.95);
 color: white;
 padding: 12px 24px;
 border-radius: 50px;
 font-weight: 800;
 font-size: 0.95rem;
 box-shadow: 0 10px 30px rgba(0,0,0,0.3);
 z-index: 99999;
 transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s;
 opacity: 0;
 pointer-events: none;
 display: flex;
 align-items: center;
 gap: 10px;
}
.status-toast.show {
 transform: translateX(-50%) translateY(0);
 opacity: 1;
}
.status-toast.status-error {
 background: rgba(220, 38, 38, 0.95);
}
.status-toast.status-success {
 background: rgba(34, 197, 94, 0.95);
}
/* --- Premium Social Interaction Feedback --- */
@keyframes popBounce {
    0% { transform: scale(1); }
    40% { transform: scale(1.25); }
    100% { transform: scale(1); }
}

.pop-anim {
    animation: popBounce 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes votePulseUp {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
    50% { transform: scale(1.2); box-shadow: 0 0 10px 2px rgba(34, 197, 94, 0.2); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

@keyframes votePulseDown {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4); }
    50% { transform: scale(1.2); box-shadow: 0 0 10px 2px rgba(239, 68, 68, 0.2); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

.vote-anim-up {
    animation: votePulseUp 0.3s ease-out;
}

.vote-anim-down {
    animation: votePulseDown 0.3s ease-out;
}

@keyframes countJump {
    0% { transform: scale(1) translateY(0); opacity: 1; }
    50% { transform: scale(1.1) translateY(-4px); opacity: 0.8; }
    100% { transform: scale(1) translateY(0); opacity: 1; }
}

.count-jump {
    animation: countJump 0.2s ease-out;
}

.reaction-btn, .vote-btn {
    transition: transform 0.15s cubic-bezier(0.4, 0, 0.2, 1), background 0.2s;
    user-select: none;
}

.reaction-btn:hover {
    transform: scale(1.1);
}

.vote-btn:hover {
    transform: scale(1.15);
}

/* Premium Category Chips (Create Post) */
.category-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    width: 100%;
}

.category-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: white;
    border: 2px solid #edf2f7;
    border-radius: 50px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 900;
    color: #4a5568 !important;
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.category-chip img {
    width: 16px;
    height: 16px;
    opacity: 0.5;
    transition: 0.2s;
}


.category-chip:hover {
    border-color: #cbd5e0;
    transform: translateY(-2px);
}

.category-chip.active {
    background: #001489 !important;
    color: white !important;
    border-color: #001489 !important;
    box-shadow: 0 5px 15px rgba(0, 20, 137, 0.3);
}

.category-chip.active img {
    filter: brightness(0) invert(1);
    opacity: 1;
}

.btn-publish {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%) !important;
    color: white !important;
    border: none !important;
    padding: 14px 28px !important;
    border-radius: 18px !important;
    font-weight: 950 !important;
    font-size: 1rem !important;
    cursor: pointer !important;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
    box-shadow: 0 4px 15px rgba(34, 197, 94, 0.3) !important;
    text-transform: uppercase !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 2px !important;
    min-width: 150px !important;
}

.btn-publish:hover {
    transform: translateY(-4px) scale(1.03) !important;
    box-shadow: 0 10px 30px rgba(34, 197, 94, 0.4) !important;
}

.btn-publish:active {
    transform: translateY(-1px) scale(0.97) !important;
}



/* Secondary Pills (The ones with counts) */
.reaction-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}

.reaction-btn:hover {
    background: #e2e8f0;
    border-color: #cbd5e0;
}

.reaction-btn.active {
    background: rgba(100, 193, 236, 0.15);
    border-color: #64C1EC;
    color: #001489;
}

.pill-emo { font-size: 0.9rem; }
.reaction-count { font-size: 0.75rem; }

.add-reaction-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #94a3b8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.add-reaction-btn:hover {
    background: #e2e8f0;
    border-color: #cbd5e0;
    color: #475569;
    transform: scale(1.05);
}

/* Picker Popup */
.discord-picker-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.1);
    z-index: 10000;
    display: none; /* Controlled by JS */
    align-items: center;
    justify-content: center;
}

.discord-picker-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    width: 280px;
    overflow: hidden;
    animation: pickerSpawn 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes pickerSpawn {
    from { transform: scale(0.9) translateY(10px); opacity: 0; }
    to { transform: scale(1) translateY(0); opacity: 1; }
}

.picker-header {
    padding: 12px;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    color: #94a3b8;
    background: #f8fafc;
    border-bottom: 1px solid #f1f5f9;
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    padding: 8px;
    gap: 4px;
}

.emoji-opt {
    background: none;
    border: none;
    font-size: 1.5rem;
    padding: 8px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.1s;
}

.emoji-opt:hover {
    background: #f1f5f9;
    transform: scale(1.2);
}

/* --- DISCORD REACTIONS UI --- */
.reaction-container {
    display: flex;
    gap: 5px;
    align-items: center;
    flex-wrap: wrap;
    margin: 8px 0;
}

.reaction-btn {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 3px 8px;
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    transition: all 0.15s ease-out;
}

.reaction-btn:hover {
    background: #e2e8f0;
    border-color: #cbd5e0;
}

.reaction-btn.active {
    background: rgba(0, 20, 137, 0.05); /* Subtle MUF-blue background */
    border-color: #001489;
    color: #001489;
}

.pill-emo {
    font-size: 0.9rem;
}

.reaction-count {
    font-size: 0.8rem;
    font-weight: 700;
}

.add-reaction-btn {
    width: 28px;
    height: 28px;
    border-radius: 50% !important;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    color: #94a3b8;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.8rem;
}

.add-reaction-btn:hover {
    background: #e2e8f0;
    border-color: #cbd5e0;
    color: #475569;
    transform: scale(1.1);
}

.add-reaction-btn i {
    font-size: 0.75rem;
}

/* --- PREMIUM FLOATING BOTTOM NAV (Apple-tier Island) --- */
.mobile-bottom-nav.premium-navbar {
    position: fixed !important;
    /* DEL 2 Fix: Use bottom margin only, no padding combinations */
    bottom: max(env(safe-area-inset-bottom), 12px) !important; 
    left: 12px !important;
    right: 12px !important;
    width: auto !important; /* Floating look */
    
    height: 64px !important;
    background: rgba(255, 255, 255, 0.88) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border: 1.5px solid rgba(255, 255, 255, 0.4) !important; /* Glass border */
    border-radius: 28px !important; /* Premium rounded */
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15) !important;
    
    display: none; /* Hidden on desktop */
    z-index: 2147483647 !important; /* Absolute top layer */
    padding: 0 10px !important;
    
    /* Perfect centering for the island look */
    justify-content: space-around;
    align-items: center !important;
}

@media (max-width: 768px) {
    .mobile-bottom-nav.premium-navbar {
        display: flex;
    }
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    height: 100%;
    text-decoration: none;
    color: #8A99AF;
    gap: 4px;
    transition: all 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
    -webkit-tap-highlight-color: transparent;
}

.bottom-nav-item i {
    font-size: 22px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease, transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.bottom-nav-item span {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.4px;
    line-height: 1;
    transition: color 0.2s ease;
}

/* Singular Active Signifier */
.bottom-nav-item.active {
    color: #001489;
}

/* Tactile feedback */
.bottom-nav-item:active {
    transform: scale(0.97);
    opacity: 0.8;
}

/* Optical alignment */
#nav-points i {
    transform: translateX(0.5px);
}

@media (max-width: 768px) {
    /* Premium Mobile Header Adjustments */
    header {
        height: 70px !important;
        padding: 0 1rem !important;
    }
    .logo img {
        height: 45px !important;
    }
    .header-left {
        gap: 1rem !important;
    }
    .mobile-profile-btn.app-profile-circle {
        display: flex !important;
        width: 36px;
        height: 36px;
        background: white;
        border: 2px solid white;
        border-radius: 50% !important;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
        overflow: hidden;
        padding: 0 !important;
        cursor: pointer;
    }
    .mobile-profile-btn.app-profile-circle img {
        width: 100%;
        height: 100%;
        object-fit: cover !important;
    }

    .post-card {
        position: relative;
        padding: 12px;
        margin-bottom: 0.8rem;
        border-radius: 12px;
    }
}

@media (min-width: 769px) {
    .post-card {
        position: relative;
        padding: 1.5rem;
        border-radius: 20px;
        margin-bottom: 0.8rem;
    }
    .post-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 30px rgba(0,0,0,0.08);
    }
    .post-avatar {
        width: 34px !important;
        height: 34px !important;
    }
}

/* Achievement Variant */
.post-card.type-achievement {
    border-left: 4px solid #FFD200;
    background: #fffcf0;
}

.post-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.post-avatar {
  width: 34px;
  height: 34px;
  min-width: 34px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
}

.post-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.comment-avatar {
  width: 20px;
  height: 20px;
  min-width: 20px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
}

.comment-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.post-content img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  margin-top: 10px;
}


.post-header-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.post-u-name {
    font-size: 14.5px;
    font-weight: 600;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.post-u-level {
    font-size: 10px;
    font-weight: 800;
    background: rgba(0, 20, 137, 0.05);
    color: #001489;
    padding: 1px 6px;
    border-radius: 4px;
    text-transform: uppercase;
}

.post-timestamp {
    font-size: 11.5px;
    color: #94a3b8;
    margin-left: auto;
}

.post-content {
    font-size: 15px;
    font-weight: 400;
    line-height: 1.52;
    color: #1e293b;
    word-break: break-word;
}

/* REACTIONS (Pill Style) */
.reaction-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}

@keyframes react-bounce {
    0%   { transform: scale(1); box-shadow: none; }
    12%  { transform: scale(0.88); }              /* trycks in */
    40%  { transform: scale(1.22); box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
    65%  { transform: scale(0.94); box-shadow: 0 2px 6px rgba(0,0,0,0.1); }
    82%  { transform: scale(1.06); }
    100% { transform: scale(1); box-shadow: none; }
}

.compact-react {
    display: flex;
    align-items: center;
    background: #f1f5f9;
    padding: 3px 8px;
    border-radius: 14px;
    gap: 5px;
    font-size: 13px;
    font-weight: 700;
    color: #334155;
    border: 1px solid transparent;
    cursor: pointer;
    user-select: none;
    transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
    will-change: transform;
}

@media (hover: hover) {
    .compact-react:not(.add-reaction-trigger):hover {
        background: rgba(0, 0, 0, 0.06);
        transform: scale(1.05);
    }
}

.compact-react.active {
    background: rgba(0, 20, 137, 0.08);
    border-color: rgba(0, 20, 137, 0.2);
    color: #001489;
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(0, 20, 137, 0.15);
}

.compact-react.react-bounce-anim {
    animation: react-bounce 0.42s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.add-reaction-trigger {
    width: auto;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    padding: 3px 12px 3px 10px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #64748b;
    font-size: 14px;
    gap: 6px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.add-reaction-trigger i {
    font-size: 13px;
}

.add-reaction-trigger::after {
    content: "Reagera";
    font-size: 12px;
    font-weight: 600;
}

.add-reaction-trigger:hover {
    background: rgba(0, 20, 137, 0.04);
    border-color: rgba(0, 20, 137, 0.15);
    color: #001489;
    transform: scale(1.05);
}

/* EVENT CARD INTEGRATION */
.feed-event-mini {
    position: relative;
    border-left: 4px solid #001489;
    background: #f1f5ff;
    padding: 10px 14px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0.8rem 0;
    transition: all 0.2s;
    cursor: pointer;
}

.feed-event-mini:hover { transform: scale(1.01); }

/* LIVE EVENT SPECIFIC */
.feed-event-mini.is-live {
    background: #eef2ff;
    box-shadow: 0 4px 15px rgba(0, 20, 137, 0.12);
    border-left-color: #ef4444;
}

.live-badge {
    position: absolute;
    top: 10px;
    right: 12px;
    background: #ef4444;
    color: white;
    font-size: 10px;
    font-weight: 900;
    padding: 2px 8px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 4px;
    text-transform: uppercase;
    animation: pulse-live 1.5s infinite;
}

@keyframes pulse-live {
    0% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(0.98); }
    100% { opacity: 1; transform: scale(1); }
}

.live-cta {
    font-size: 11.5px;
    font-weight: 700;
    color: #ef4444;
    margin-top: 4px;
    display: block;
}

.event-mini-icon {
    width: 42px;
    height: 42px;
    background: #001489;
    color: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}
.is-live .event-mini-icon { background: #ef4444; }

.event-mini-details { flex: 1; min-width: 0; }
.event-mini-details h4 { 
    margin: 0 0 2px 0; 
    font-size: 15px; 
    color: #1e293b; 
    font-weight: 800;
}
.event-mini-details p { 
    margin: 0; 
    font-size: 12px; 
    color: #64748b; 
    font-weight: 500; 
}

/* Legacy components removed in favor of modular system above */
/* 
   Consistent Clickable Card Pattern 
   Ensures robust navigation overlays and safe interactive elements.
*/
.clickable-card {
    position: relative !important;
    cursor: pointer;
}

/* The invisible overlay that makes the whole card clickable */
.clickable-card .stretched-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: var(--z-card-overlay) !important;
    background: transparent;
    text-decoration: none;
}

/* Ensures nested interactive elements stay on top of the stretched-link */
.clickable-card button,
.clickable-card a:not(.stretched-link),
.clickable-card .btn,
.clickable-card .interactive-element,
.clickable-card input,
.clickable-card select {
    position: relative;
    z-index: var(--z-interact) !important;
}
