/* Landing page specific styles */

.landing-page {
    width: 100%;
    background: #0a0c10;
    overflow-x: hidden;
    position: relative;
    max-width: 100vw;
}

/* Section spacing */
section {
    position: relative;
    width: 100%;
}

/* Live status indicator */
.status-indicator-live {
    color: #10b981;
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.status-indicator-offline {
    color: rgba(255, 255, 255, 0.3);
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Container max-width */
.mud-container-maxwidth-xl,
.mud-container-maxwidth-lg {
    max-width: 1400px;
}

/* Typography overrides for landing */
.landing-page h1,
.landing-page h2,
.landing-page h3 {
    font-family: 'Roboto Flex', sans-serif;
}

/* Section headers */
.section-header {
    animation: sectionHeaderFadeIn 1s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes sectionHeaderFadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Feature cards grid responsive */
.features-grid .mud-grid-item {
    transition: opacity 0.3s ease-out;
}

/* Integration section visual effects */
.integration-showcase {
    position: relative;
    overflow: hidden;
    border-radius: 16px; /* Ensure border radius matches content if needed, or just clips the glow */
}

.integration-showcase::after {
    content: '';
    position: absolute;
    top: -20%;
    right: -20%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 42, 0, 0.15) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

/* Server cards hover effect */
.server-card {
    cursor: pointer;
}

/* Section dividers - Superseded by lower definition */
.section-divider-base {
    display: none;
}

/* Activity Feed - Dynamic Glass Design */
.activity-feed {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 800px;
    margin: 0 auto;
    /* Removed container background for clearer float effect */
    position: relative;
    min-height: 350px;
    padding: 10px;
    perspective: 1000px;
}

.activity-item {
    background: rgba(29, 31, 39, 0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-left: 3px solid rgba(255, 42, 0, 0.5);
    border-radius: 12px;
    padding: 14px 22px;
    transition: all 0.4s cubic-bezier(0.19, 1, 0.22, 1);
    animation: slideInFromTop 0.6s cubic-bezier(0.19, 1, 0.22, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.activity-item:hover {
    background: rgba(29, 31, 39, 0.75);
    border-left-color: #FF2A00;
    transform: translateX(8px) scale(1.02);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
    z-index: 10;
}

.activity-item.activity-new {
    animation: slideInFromTop 0.5s ease-out, highlightFade 2s ease-out;
    border-left-color: #FF2A00;
    box-shadow: 0 0 15px rgba(255, 42, 0, 0.2);
}

.activity-item:last-child.activity-old {
    animation: slideOutToBottom 0.4s ease-in forwards;
}

/* Horizontal layout for compact display */
.activity-content {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.activity-avatar-container {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
}

.activity-avatar-sm {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 42, 0, 0.3);
    display: block;
    background-color: #1d1f27;
}

.activity-details {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    min-width: 0; /* Allow text truncation */
}

.activity-user {
    font-weight: 600;
    color: #FF2A00;
    white-space: nowrap;
}

.activity-separator {
    color: rgba(255, 255, 255, 0.3);
}

.activity-desc {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
}

.activity-amount {
    font-weight: 600;
    font-size: 0.85rem;
    padding: 2px 8px;
    border-radius: 4px;
    white-space: nowrap;
}

.amount-positive {
    color: #4caf50;
    background: rgba(76, 175, 80, 0.15);
}

.amount-negative {
    color: #f44336;
    background: rgba(244, 67, 54, 0.15);
}

.amount-xp {
    color: #2196f3;
    background: rgba(33, 150, 243, 0.15);
}

.activity-timestamp {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
    white-space: nowrap;
    margin-left: auto;
    flex-shrink: 0;
}

/* Slide in animation from top */
@keyframes slideInFromTop {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Slide out animation to bottom */
@keyframes slideOutToBottom {
    from {
        opacity: 1;
        transform: translateY(0);
        max-height: 60px;
    }
    to {
        opacity: 0;
        transform: translateY(20px);
        max-height: 0;
        padding-top: 0;
        padding-bottom: 0;
        margin-top: 0;
        margin-bottom: 0;
    }
}

/* Highlight new items */
@keyframes highlightFade {
    0% {
        background: rgba(255, 42, 0, 0.2);
    }
    100% {
        background: rgba(29, 31, 39, 0.8);
    }
}

/* Responsive adjustments */
@media (max-width: 600px) {
    .activity-card-content {
        padding: 16px;
        padding-left: 20px;
        gap: 12px;
    }
    
    .activity-avatar {
        width: 44px;
        height: 44px;
    }
    
    .activity-type-indicator {
        width: 20px;
        height: 20px;
    }
    
    .activity-username {
        font-size: 0.875rem;
    }
    
    .activity-title {
        font-size: 0.85rem;
    }
}

/* Mobile responsiveness */
@media (max-width: 960px) {
    section:not(.hero-section) {
        padding: 4rem 0 !important;
    }
}

@media (max-width: 600px) {
    section:not(.hero-section) {
        padding: 3rem 0 !important;
    }
}
/* Mobile responsive for activity feed */
@media (max-width: 768px) {
    .activity-details {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    
    .activity-timestamp {
        margin-left: 0;
        align-self: flex-end;
    }
}

/* Section transitions */
.stats-section, .activity-section {
    animation: fadeInUp 0.6s ease-out;
    animation-fill-mode: both;
}

.activity-section {
    animation-delay: 0.2s; /* Slight delay for staggered effect */
}

.section-divider {
    height: 140px;
    margin: 40px 0;
    position: relative;
    pointer-events: none;
    overflow: hidden;
    width: 100%;
}

.section-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: -10%;
    width: 120%;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 42, 0, 0.3) 40%, rgba(255, 42, 0, 0.0) 80%);
    transform: rotate(-2deg);
    filter: blur(1px);
}

.section-divider::after {
    content: '';
    position: absolute;
    top: 50%;
    right: -10%;
    width: 120%;
    height: 1px;
    background: linear-gradient(90deg, transparent 20%, rgba(255, 42, 0, 0.2) 60%, transparent 100%);
    transform: rotate(1.5deg);
}

.section-divider .divider-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255, 42, 0, 0.08) 0%, transparent 70%);
    filter: blur(30px);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Section spacing improvements */
.stats-section {
    margin-bottom: 20px;
}

.activity-section {
    margin-top: 20px;
}

/* Fix for navbar gap - allow content to go behind transparent navbar */
.landing-content {
    padding-top: 0;
}
/* ========================================= */
/* LEADERBOARD REDESIGN                      */
/* ========================================= */

/* Remove default table row borders and spacing to enable "card" rows */
.leaderboard-table .mud-table-container {
    background: transparent !important;
    box-shadow: none !important;
}

.leaderboard-table .mud-table-root {
    background: transparent !important;
    border-collapse: separate !important;
    border-spacing: 0 8px !important;
}

/* Header Styling */
.leaderboard-table thead th {
    background: transparent !important;
    border: none !important;
    color: rgba(255, 255, 255, 0.5) !important;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.75rem;
    font-weight: 700 !important;
    padding-bottom: 12px !important;
}

.leaderboard-table thead th .mud-table-sort-label {
    color: rgba(255, 255, 255, 0.5) !important;
}

.leaderboard-table thead th .mud-table-sort-label:hover {
    color: white !important;
}

/* Row Styling - "Floating Strip" look */
.leaderboard-row {
    background: rgba(30, 33, 42, 0.6) !important;
    backdrop-filter: blur(8px);
    transition: all 0.2s ease-out;
}

.leaderboard-row td {
    border: none !important;
    padding: 16px 24px !important;
    /* Vertical Center content */
    vertical-align: middle !important;
}

/* Add borders/radius to the row via first/last cells */
.leaderboard-row td:first-child {
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;
    border-left: 1px solid rgba(255, 255, 255, 0.05) !important;
}

.leaderboard-row td:last-child {
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
    border-right: 1px solid rgba(255, 255, 255, 0.05) !important;
}

/* Top/Bottom borders for all cells */
.leaderboard-row td {
    border-top: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}

.leaderboard-row:hover {
    background: rgba(40, 44, 56, 0.9) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.leaderboard-row:hover td {
    border-color: rgba(255, 255, 255, 0.15) !important;
}

/* Rank Styling */
.rank-badge {
    font-weight: 900;
    font-family: 'Roboto Flex', sans-serif;
    font-size: 1.25rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.5);
    position: relative;
}

.rank-1 .rank-badge {
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #000;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.4);
    animation: glow-pulse 2s infinite;
}

.rank-2 .rank-badge {
    background: linear-gradient(135deg, #E0E0E0 0%, #B0B0B0 100%);
    color: #333;
    box-shadow: 0 0 10px rgba(192, 192, 192, 0.3);
}

.rank-3 .rank-badge {
    background: linear-gradient(135deg, #CD7F32 0%, #A0522D 100%);
    color: #fff;
    box-shadow: 0 0 10px rgba(205, 127, 50, 0.3);
}

@keyframes glow-pulse {
    0% { box-shadow: 0 0 15px rgba(255, 215, 0, 0.4); }
    50% { box-shadow: 0 0 25px rgba(255, 215, 0, 0.6); }
    100% { box-shadow: 0 0 15px rgba(255, 215, 0, 0.4); }
}

/* User Info */
.leaderboard-user {
    display: flex;
    align-items: center;
    gap: 16px;
}

.leaderboard-avatar {
    width: 48px;
    height: 48px;
    border-radius: 12px; /* Soft square looks more modern */
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.1);
    background: #1a1c24;
}

.rank-1 .leaderboard-avatar { border-color: #FFD700; }
.rank-2 .leaderboard-avatar { border-color: #C0C0C0; }
.rank-3 .leaderboard-avatar { border-color: #CD7F32; }

.leaderboard-username {
    font-weight: 700;
    font-size: 1.1rem;
    color: white;
}

/* Stat Pills */
.stat-pill {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
}

.stat-xp {
    background: rgba(33, 150, 243, 0.1);
    color: #4dabf5;
    border: 1px solid rgba(77, 171, 245, 0.2);
}

.stat-balance {
    background: rgba(76, 175, 80, 0.1);
    color: #66bb6a;
    border: 1px solid rgba(102, 187, 106, 0.2);
}

.stat-funny {
    background: rgba(233, 30, 99, 0.1);
    color: #f06292;
    border: 1px solid rgba(240, 98, 146, 0.2);
}

.level-badge {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.9);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-right: 8px;
}