/* ========================================
   NextGen RP - Premium SaaS Dashboard
   Professional Design System
======================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Roboto:wght@300;400;500;700;900&display=swap');

:root {
    color-scheme: dark;
    /* ===== COLOR SYSTEM ===== */

    /* Background Hierarchy */
    --bg-primary: #000000;
    --bg-secondary: #0a0a0a;
    --bg-tertiary: #141414;
    --bg-elevated: #1a1a1a;

    /* Surface Colors (Glassmorphism) */
    --surface-card: rgba(10, 10, 10, 0.6);
    --surface-card-hover: rgba(20, 20, 20, 0.8);
    --surface-overlay: rgba(0, 0, 0, 0.8);

    /* Border System */
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-default: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.12);
    --border-active: rgba(215, 21, 21, 0.5);

    /* Accent Colors */
    --accent-primary: #D71515;
    --accent-primary-hover: #ef4444;
    --accent-primary-muted: rgba(215, 21, 21, 0.15);
    --accent-red: #D71515;
    --accent-red-muted: rgba(215, 21, 21, 0.15);
    --hover-state: #8B0000;

    /* Text Hierarchy */
    --text-primary: #FFFFFF;
    --text-secondary: #9CA3AF;
    --text-muted: #6B7280;
    --text-disabled: #4B5563;

    /* Semantic Colors */
    --status-success: #10B981;
    --status-success-bg: rgba(16, 185, 129, 0.1);
    --status-warning: #F59E0B;
    --status-warning-bg: rgba(245, 158, 11, 0.1);
    --status-error: #EF4444;
    --status-error-bg: rgba(239, 68, 68, 0.1);
    --status-info: #3B82F6;
    --status-info-bg: rgba(59, 130, 246, 0.1);

    /* Legacy support */
    --glass-bg: var(--surface-card);
    --glass-bg-solid: rgba(8, 8, 8, 0.85);
    --glass-border: var(--border-subtle);
    --glass-border-hover: var(--border-hover);
    --status-online: var(--status-success);
    --status-offline: var(--status-error);

    /* ===== SPACING SYSTEM (8px base) ===== */
    --spacing-0: 0;
    --spacing-1: 4px;
    --spacing-2: 8px;
    --spacing-3: 12px;
    --spacing-4: 16px;
    --spacing-5: 20px;
    --spacing-6: 24px;
    --spacing-8: 32px;
    --spacing-10: 40px;
    --spacing-12: 48px;
    --spacing-16: 64px;
    --spacing-20: 80px;

    /* Legacy spacing aliases */
    --spacing-xs: var(--spacing-1);
    --spacing-sm: var(--spacing-2);
    --spacing-md: var(--spacing-4);
    --spacing-lg: var(--spacing-6);
    --spacing-xl: var(--spacing-8);
    --spacing-2xl: var(--spacing-12);
    --spacing-3xl: var(--spacing-16);

    /* ===== BORDER RADIUS ===== */
    --radius-xs: 4px;
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-2xl: 20px;
    --radius-full: 9999px;

    /* ===== SHADOWS ===== */
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.2);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.25);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.3);
    --shadow-xl: 0 16px 32px rgba(0, 0, 0, 0.35);
    --shadow-glow: 0 0 20px rgba(215, 21, 21, 0.15);
    --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.2), 0 1px 2px rgba(0, 0, 0, 0.15);
    --shadow-card-hover: 0 4px 12px rgba(0, 0, 0, 0.25);

    /* ===== TRANSITIONS ===== */
    --transition-fast: 150ms ease;
    --transition-normal: 200ms ease;
    --transition-slow: 300ms ease;
    --transition-bounce: 300ms cubic-bezier(0.34, 1.56, 0.64, 1);

    /* ===== TYPOGRAPHY ===== */
    --font-sans: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-display: 'Roboto', var(--font-sans);
    --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-family: var(--font-sans);

    /* Font Sizes */
    --text-xs: 0.75rem;      /* 12px */
    --text-sm: 0.875rem;     /* 14px */
    --text-base: 1rem;       /* 16px */
    --text-lg: 1.125rem;     /* 18px */
    --text-xl: 1.25rem;      /* 20px */
    --text-2xl: 1.5rem;      /* 24px */
    --text-3xl: 1.875rem;    /* 30px */
    --text-4xl: 2.25rem;     /* 36px */

    /* Font Weights */
    --font-light: 300;
    --font-normal: 400;
    --font-medium: 500;
    --font-semibold: 600;
    --font-bold: 700;

    /* Line Heights */
    --leading-tight: 1.25;
    --leading-normal: 1.5;
    --leading-relaxed: 1.625;

    /* Letter Spacing */
    --tracking-tight: -0.025em;
    --tracking-normal: 0;
    --tracking-wide: 0.025em;
    --tracking-wider: 0.05em;
}

/* ========================================
   Professional Button System
======================================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-2);
    padding: var(--spacing-3) var(--spacing-5);
    font-family: var(--font-sans);
    font-size: var(--text-sm);
    font-weight: var(--font-medium);
    line-height: 1;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
    white-space: nowrap;
}

.btn:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* Primary Button */
.btn-primary {
    background: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

.btn-primary:hover {
    background: var(--accent-primary-hover);
    border-color: var(--accent-primary-hover);
}

.btn-primary:active {
    transform: translateY(1px);
}

/* Secondary Button */
.btn-secondary {
    background: var(--surface-card);
    color: var(--text-primary);
    border-color: var(--border-default);
}

.btn-secondary:hover {
    background: var(--surface-card-hover);
    border-color: var(--border-hover);
}

/* Ghost Button */
.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border-color: transparent;
}

.btn-ghost:hover {
    background: var(--surface-card);
    color: var(--text-primary);
}

/* Danger Button */
.btn-danger {
    background: var(--accent-red);
    color: white;
    border-color: var(--accent-red);
}

.btn-danger:hover {
    background: #DC2626;
    border-color: #DC2626;
}

/* Button Sizes */
.btn-sm {
    padding: var(--spacing-2) var(--spacing-3);
    font-size: var(--text-xs);
}

.btn-lg {
    padding: var(--spacing-4) var(--spacing-6);
    font-size: var(--text-base);
}

/* ========================================
   Professional Card System
======================================== */

.card {
    background: var(--surface-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--spacing-6);
    transition: all var(--transition-normal);
}

.card:hover {
    border-color: var(--border-default);
    box-shadow: var(--shadow-card-hover);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-4);
}

.card-title {
    font-family: var(--font-display);
    font-size: var(--text-lg);
    font-weight: var(--font-semibold);
    color: var(--text-primary);
    letter-spacing: var(--tracking-tight);
}

.card-subtitle {
    font-size: var(--text-sm);
    color: var(--text-muted);
    margin-top: var(--spacing-1);
}

.card-body {
    color: var(--text-secondary);
}

.card-footer {
    margin-top: var(--spacing-4);
    padding-top: var(--spacing-4);
    border-top: 1px solid var(--border-subtle);
}

/* ========================================
   Image Filters
======================================== */

.img-bw {
    filter: grayscale(100%);
    transition: filter 0.4s ease;
}

.img-bw:hover {
    filter: grayscale(0%);
}

/* Image wrapper for red gradient overlay effect */
.img-hover-red {
    position: relative;
    display: block;
    overflow: hidden;
}

.img-hover-red::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(215, 21, 21, 0.4) 0%, rgba(139, 0, 0, 0.3) 50%, rgba(215, 21, 21, 0.2) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.img-hover-red:hover::after {
    opacity: 1;
}

.img-hover-red:hover .img-bw {
    filter: grayscale(0%);
}

.img-bw-always {
    filter: grayscale(100%);
}

.img-dark {
    filter: grayscale(100%) brightness(0.7);
}

.img-dark:hover {
    filter: grayscale(0%) brightness(1);
}

/* Glass Panel (Legacy Support + Enhanced) */
.glass-panel {
    background: var(--surface-card);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: var(--spacing-5);
    transition: all var(--transition-normal);
}

.glass-panel:hover {
    border-color: var(--border-default);
    background: var(--surface-card-hover);
}

/* ========================================
   Typography Classes
======================================== */

.heading-1 {
    font-family: var(--font-display);
    font-size: var(--text-4xl);
    font-weight: var(--font-bold);
    line-height: var(--leading-tight);
    letter-spacing: var(--tracking-tight);
    color: var(--text-primary);
}

.heading-2 {
    font-family: var(--font-display);
    font-size: var(--text-3xl);
    font-weight: var(--font-bold);
    line-height: var(--leading-tight);
    letter-spacing: var(--tracking-tight);
    color: var(--text-primary);
}

.heading-3 {
    font-family: var(--font-display);
    font-size: var(--text-2xl);
    font-weight: var(--font-semibold);
    line-height: var(--leading-tight);
    color: var(--text-primary);
}

.heading-4 {
    font-family: var(--font-display);
    font-size: var(--text-xl);
    font-weight: var(--font-semibold);
    line-height: var(--leading-tight);
    color: var(--text-primary);
}

.body-text {
    font-size: var(--text-base);
    line-height: var(--leading-relaxed);
    color: var(--text-secondary);
}

.caption {
    font-size: var(--text-xs);
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wider);
    font-weight: var(--font-medium);
}

/* ========================================
   Form Elements
======================================== */

.input {
    width: 100%;
    padding: var(--spacing-3) var(--spacing-4);
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    font-family: var(--font-sans);
    font-size: var(--text-sm);
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

.input::placeholder {
    color: var(--text-muted);
}

.input:hover {
    border-color: var(--border-hover);
}

.input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px var(--accent-primary-muted);
}

.label {
    display: block;
    font-size: var(--text-sm);
    font-weight: var(--font-medium);
    color: var(--text-secondary);
    margin-bottom: var(--spacing-2);
}

/* ========================================
   Badge System
======================================== */

.badge {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-1);
    padding: var(--spacing-1) var(--spacing-2);
    font-size: var(--text-xs);
    font-weight: var(--font-medium);
    border-radius: var(--radius-sm);
}

.badge-primary {
    background: var(--accent-primary-muted);
    color: var(--accent-primary);
}

.badge-success {
    background: var(--status-success-bg);
    color: var(--status-success);
}

.badge-warning {
    background: var(--status-warning-bg);
    color: var(--status-warning);
}

.badge-error {
    background: var(--status-error-bg);
    color: var(--status-error);
}

/* ========================================
   Reset & Base Styles
======================================== */

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
}

/* Subtle texture overlay */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        radial-gradient(ellipse at 20% 20%, rgba(215, 21, 21, 0.03) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(215, 21, 21, 0.02) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.01) 0%, transparent 100%);
    pointer-events: none;
    z-index: 0;
}

/* Noise texture */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    opacity: 0.012;
    pointer-events: none;
    z-index: 0;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

/* Grid pattern overlay */
.page-grid-overlay {
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
    z-index: 0;
    opacity: 0.5;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

/* ========================================
   Ambient Background Effects
======================================== */

.ambient-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

/* Grid pattern */
.ambient-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
    background-size: 60px 60px;
    opacity: 0.8;
}

/* Noise texture */
.ambient-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    opacity: 0.012;
}

.ambient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.3;
}

.ambient-orb-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(215, 21, 21, 0.08) 0%, transparent 70%);
    top: -200px;
    right: -100px;
    animation: float 20s ease-in-out infinite;
}

.ambient-orb-2 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(215, 21, 21, 0.05) 0%, transparent 70%);
    bottom: -100px;
    left: -100px;
    animation: float 25s ease-in-out infinite reverse;
}

.ambient-orb-3 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(215, 21, 21, 0.1) 0%, transparent 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: pulse 15s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-30px) rotate(5deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 0.2; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 0.4; transform: translate(-50%, -50%) scale(1.1); }
}

/* ========================================
   Glass Panel Styles
======================================== */

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
}

.glass-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg,
        transparent,
        rgba(255, 255, 255, 0.05) 50%,
        transparent
    );
}

.glass-panel-inner {
    background: rgba(26, 10, 14, 0.4);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
}

/* ========================================
   Container & Layout
======================================== */

.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

.main-content {
    position: relative;
    z-index: 1;
    padding-top: 100px;
    padding-bottom: var(--spacing-3xl);
    min-height: 100vh;
}

/* ========================================
   Navigation
======================================== */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: var(--spacing-md) 0;
    background: var(--glass-bg-solid);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 32px;
}

.nav-brand {
    flex-shrink: 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--accent-red) 0%, var(--hover-state) 100%);
    border-radius: var(--radius-md);
    font-weight: 800;
    font-size: 14px;
    letter-spacing: -0.5px;
}

.logo-text {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

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

.logo-img {
    height: 60px;
    width: auto;
    object-fit: contain;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    background: rgba(255, 255, 255, 0.03);
    padding: 6px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(255, 255, 255, 0.06);
    overflow: hidden;
}

.nav-link {
    position: relative;
    padding: 10px 20px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-muted);
    border-radius: var(--radius-full);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.3px;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 6px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--accent-red);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateX(-50%);
    border-radius: 2px;
}

.nav-link:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.08);
}

.nav-link:hover::after {
    width: 20px;
}

.nav-link:active {
    transform: scale(0.95);
    transition: transform 0.1s ease;
}

.nav-link.active {
    color: white;
    background: linear-gradient(135deg, var(--accent-red) 0%, #8B0000 100%);
    box-shadow: 0 4px 15px rgba(215, 21, 21, 0.3);
}

.nav-link.active::after {
    display: none;
}

.nav-profile {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.notification-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.notification-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.notification-badge {
    position: absolute;
    top: 6px;
    right: 6px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    background: var(--accent-red);
    border-radius: var(--radius-full);
    font-size: 10px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-info {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.profile-info:hover {
    background: rgba(255, 255, 255, 0.05);
}

.profile-avatar {
    position: relative;
    width: 36px;
    height: 36px;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    border-radius: var(--radius-md);
    background: var(--bg-secondary);
}

.status-dot {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid var(--bg-primary);
}

.status-dot.online {
    background: var(--status-online);
}

.status-dot.offline {
    background: var(--status-offline);
}

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

.profile-name {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
}

.profile-role {
    font-size: 11px;
    color: var(--text-muted);
    line-height: 1.2;
}

.profile-chevron {
    color: var(--text-muted);
    transition: transform var(--transition-fast);
}

.profile-info:hover .profile-chevron {
    transform: rotate(180deg);
}

/* Profile Dropdown */
.profile-wrapper {
    position: relative;
}

.profile-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 240px;
    background: rgba(20, 20, 20, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-default);
    border-top: 2px solid var(--accent-red);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 20px rgba(215, 21, 21, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all var(--transition-normal);
    z-index: 1000;
    overflow: hidden;
}

.profile-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
    background: rgba(255, 255, 255, 0.02);
}

.dropdown-header img {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: var(--bg-secondary);
}

.dropdown-user-info {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.dropdown-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dropdown-email {
    font-size: 12px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dropdown-divider {
    height: 1px;
    background: var(--border-subtle);
    margin: 0;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: all var(--transition-fast);
}

.dropdown-item:hover {
    background: rgba(215, 21, 21, 0.1);
    color: var(--text-primary);
}

.dropdown-item:hover svg {
    stroke: var(--accent-red);
}

.dropdown-item svg {
    flex-shrink: 0;
    transition: stroke var(--transition-fast);
}

.dropdown-item-danger {
    color: var(--status-error);
}

.dropdown-item-danger:hover {
    background: rgba(239, 68, 68, 0.1);
    color: var(--status-error);
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: var(--spacing-sm);
}

.mobile-menu-btn span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all var(--transition-fast);
}

/* ========================================
   Hero Section
======================================== */

.hero-section {
    position: relative;
    height: 300px;
    margin-bottom: var(--spacing-2xl);
    overflow: hidden;
    border-radius: var(--radius-xl);
    margin: var(--spacing-6);
    margin-bottom: var(--spacing-2xl);
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-bg-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: filter 0.4s ease;
}

/* Red gradient overlay on hero hover */
.hero-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(215, 21, 21, 0.5) 0%, rgba(139, 0, 0, 0.3) 50%, rgba(215, 21, 21, 0.2) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
    pointer-events: none;
    border-radius: var(--radius-xl);
}

.hero-section:hover::before {
    opacity: 1;
}

.hero-section:hover .hero-bg-img {
    filter: grayscale(0%);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg,
        rgba(0, 0, 0, 0.5) 0%,
        rgba(0, 0, 0, 0.85) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    padding: var(--spacing-8);
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.4) 0%, transparent 70%);
    border-radius: var(--radius-xl);
}

.hero-title {
    font-size: 48px;
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 2px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8),
                 0 4px 12px rgba(0, 0, 0, 0.6),
                 0 8px 24px rgba(0, 0, 0, 0.4);
}

.hero-subtitle {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.95);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8),
                 0 4px 12px rgba(0, 0, 0, 0.5);
}

.text-accent {
    color: var(--accent-red);
    text-shadow: 0 0 20px rgba(215, 21, 21, 0.5),
                 0 2px 4px rgba(0, 0, 0, 0.8);
}

.welcome-panel {
    padding: var(--spacing-xl);
}

.welcome-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--spacing-xl);
}

.welcome-label {
    display: block;
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: var(--spacing-xs);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.welcome-name {
    font-size: 42px;
    font-weight: 800;
    letter-spacing: -1px;
    line-height: 1.1;
    margin-bottom: var(--spacing-xs);
}

.welcome-subtitle {
    font-size: 16px;
    color: var(--text-secondary);
}

.welcome-badge {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: var(--spacing-sm) var(--spacing-md);
    background: linear-gradient(135deg, var(--accent-red) 0%, var(--hover-state) 100%);
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 600;
}

.badge-icon {
    font-size: 14px;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-md);
}

.stat-card {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    transition: all var(--transition-normal);
}

.stat-card:hover {
    background: rgba(255, 255, 255, 0.03);
    border-color: var(--glass-border-hover);
}

.stat-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
}

.stat-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.2;
}

.stat-label {
    font-size: 12px;
    color: var(--text-muted);
}

.stat-badge {
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--radius-sm);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-badge.priority {
    background: rgba(215, 21, 21, 0.15);
    color: var(--accent-red);
}

.stat-trend {
    font-size: 12px;
    font-weight: 500;
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--radius-sm);
}

.stat-trend.up {
    background: rgba(34, 197, 94, 0.1);
    color: var(--status-online);
}

.stat-trend.neutral {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
}

/* ========================================
   Section Headers
======================================== */

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-lg);
}

.section-title {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.section-subtitle {
    font-size: 14px;
    color: var(--text-muted);
    margin-top: var(--spacing-xs);
}

.view-all-link {
    font-size: 14px;
    color: var(--text-secondary);
    transition: color var(--transition-fast);
}

.view-all-link:hover {
    color: var(--accent-red);
}

/* ========================================
   Quick Actions Section
======================================== */

.actions-section {
    margin-bottom: var(--spacing-2xl);
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
}

.action-card {
    position: relative;
    padding: var(--spacing-lg);
    cursor: pointer;
    transition: all var(--transition-normal);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.action-card:hover {
    transform: translateY(-4px);
    border-color: var(--glass-border-hover);
    box-shadow: var(--shadow-lg);
}

.action-accent {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(215, 21, 21, 0.1) 0%, transparent 50%);
    opacity: 0;
    transition: opacity var(--transition-normal);
    pointer-events: none;
    border-radius: inherit;
}

.action-accent::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-red), transparent);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.action-card:hover .action-accent {
    opacity: 1;
}

.action-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    transition: all var(--transition-normal);
}

.action-card:hover .action-icon {
    background: rgba(215, 21, 21, 0.1);
    color: var(--accent-red);
}

.action-content {
    flex: 1;
}

.action-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: var(--spacing-xs);
}

.action-description {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
}

.action-status {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-indicator.pending {
    background: var(--status-warning);
}

.status-indicator.active {
    background: var(--accent-red);
}

.status-indicator.success {
    background: var(--status-online);
}

.status-indicator.info {
    background: var(--status-info);
}

.status-text {
    font-size: 12px;
    color: var(--text-muted);
}

.action-arrow {
    position: absolute;
    bottom: var(--spacing-lg);
    right: var(--spacing-lg);
    color: var(--text-muted);
    opacity: 0;
    transform: translateX(-8px);
    transition: all var(--transition-normal);
}

.action-card:hover .action-arrow {
    opacity: 1;
    transform: translateX(0);
    color: var(--accent-red);
}

/* ========================================
   Server Status Section
======================================== */

.status-section {
    margin-bottom: var(--spacing-2xl);
}

.status-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
}

.server-status-panel {
    padding: var(--spacing-xl);
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-lg);
}

.panel-title {
    font-size: 18px;
    font-weight: 600;
}

.last-updated {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    font-size: 12px;
    color: var(--text-muted);
}

.status-main {
    display: flex;
    align-items: center;
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-xl);
    padding: var(--spacing-lg);
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-md);
}

.status-indicator-large {
    position: relative;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.status-pulse {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    animation: statusPulse 2s ease-in-out infinite;
}

.status-indicator-large.online .status-pulse {
    background: rgba(34, 197, 94, 0.2);
}

.status-indicator-large.offline .status-pulse {
    background: rgba(239, 68, 68, 0.2);
}

.status-core {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    z-index: 1;
}

.status-indicator-large.online .status-core {
    background: var(--status-online);
    box-shadow: 0 0 20px rgba(34, 197, 94, 0.5);
}

.status-indicator-large.offline .status-core {
    background: var(--status-offline);
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.5);
}

@keyframes statusPulse {
    0%, 100% { transform: scale(0.8); opacity: 0.5; }
    50% { transform: scale(1); opacity: 0.2; }
}

.status-text-large {
    display: flex;
    flex-direction: column;
}

.status-text-large .status-label {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: var(--spacing-xs);
}

.status-text-large .status-value {
    font-size: 28px;
    font-weight: 700;
}

.status-text-large .status-value.online {
    color: var(--status-online);
}

.status-text-large .status-value.offline {
    color: var(--status-offline);
}

.status-details {
    margin-bottom: var(--spacing-xl);
}

.status-detail-item {
    margin-bottom: var(--spacing-lg);
}

.detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-sm);
}

.detail-label {
    font-size: 14px;
    color: var(--text-secondary);
}

.detail-value {
    font-size: 14px;
    font-weight: 600;
}

.progress-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: var(--spacing-xs);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-red), var(--hover-state));
    border-radius: var(--radius-full);
    transition: width var(--transition-slow);
}

.detail-sublabel {
    font-size: 11px;
    color: var(--text-muted);
}

.status-metrics {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.metric-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-md);
}

.metric-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
}

.metric-info {
    display: flex;
    flex-direction: column;
}

.metric-value {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
}

.metric-label {
    font-size: 11px;
    color: var(--text-muted);
}

/* Join Button */
.join-section {
    text-align: center;
}

.join-button {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-xs);
    padding: var(--spacing-lg) var(--spacing-2xl);
    background: linear-gradient(135deg, var(--accent-red) 0%, var(--hover-state) 100%);
    border-radius: var(--radius-lg);
    font-weight: 600;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.join-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    transition: left var(--transition-slow);
}

.join-button:hover::before {
    left: 100%;
}

.join-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(215, 21, 21, 0.3);
}

.join-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.join-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.join-text {
    font-size: 18px;
}

.join-subtext {
    font-size: 12px;
    opacity: 0.8;
}

.join-note {
    margin-top: var(--spacing-md);
    font-size: 12px;
    color: var(--text-muted);
}

/* ========================================
   Activity Panel
======================================== */

.activity-panel {
    padding: var(--spacing-xl);
}

.activity-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    transition: background var(--transition-fast);
}

.activity-item:hover {
    background: rgba(255, 255, 255, 0.02);
}

.activity-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    flex-shrink: 0;
}

.activity-icon.success {
    background: rgba(34, 197, 94, 0.1);
    color: var(--status-online);
}

.activity-icon.info {
    background: rgba(59, 130, 246, 0.1);
    color: var(--status-info);
}

.activity-icon.warning {
    background: rgba(245, 158, 11, 0.1);
    color: var(--status-warning);
}

.activity-icon.reward {
    background: rgba(215, 21, 21, 0.1);
    color: var(--accent-red);
}

.activity-icon.neutral {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
}

.activity-content {
    flex: 1;
    min-width: 0;
}

.activity-title {
    display: block;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 2px;
}

.activity-desc {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.activity-time {
    font-size: 11px;
    color: var(--text-muted);
    white-space: nowrap;
}

/* ========================================
   Announcements Section
======================================== */

.announcements-section {
    margin-bottom: var(--spacing-2xl);
}

.announcements-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-lg);
}

.announcement-card {
    padding: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    transition: all var(--transition-normal);
}

.announcement-card:hover {
    transform: translateY(-4px);
    border-color: var(--glass-border-hover);
}

.announcement-card.featured {
    grid-column: span 1;
    border-color: rgba(215, 21, 21, 0.2);
}

.announcement-badge {
    display: inline-flex;
    align-self: flex-start;
    padding: var(--spacing-xs) var(--spacing-sm);
    background: rgba(215, 21, 21, 0.15);
    color: var(--accent-red);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: var(--radius-sm);
    margin-bottom: var(--spacing-md);
}

.announcement-content {
    flex: 1;
    margin-bottom: var(--spacing-md);
}

.announcement-date {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: var(--spacing-sm);
}

.announcement-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    line-height: 1.3;
}

.announcement-excerpt {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.announcement-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--spacing-md);
    border-top: 1px solid var(--glass-border);
}

.announcement-author {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.announcement-author img {
    width: 24px;
    height: 24px;
    border-radius: var(--radius-sm);
    background: var(--bg-secondary);
}

.announcement-author span {
    font-size: 12px;
    color: var(--text-muted);
}

.read-more-link {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
    transition: color var(--transition-fast);
}

.read-more-link:hover {
    color: var(--accent-red);
}

/* ========================================
   Footer
======================================== */

.footer {
    position: relative;
    z-index: 1;
    background: var(--glass-bg-solid);
    border-top: 1px solid var(--glass-border);
    padding: var(--spacing-3xl) 0 var(--spacing-xl);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    margin-bottom: var(--spacing-2xl);
}

.footer-brand {
    max-width: 300px;
}

.footer-brand .logo {
    margin-bottom: var(--spacing-md);
}

.footer-tagline {
    font-size: 14px;
    color: var(--text-muted);
}

.footer-links-grid {
    display: flex;
    gap: var(--spacing-3xl);
}

.footer-column h4 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: var(--spacing-md);
    color: var(--text-primary);
}

.footer-column a {
    display: block;
    font-size: 14px;
    color: var(--text-muted);
    padding: var(--spacing-xs) 0;
    transition: color var(--transition-fast);
}

.footer-column a:hover {
    color: var(--text-primary);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--spacing-xl);
    border-top: 1px solid var(--glass-border);
}

.footer-bottom p {
    font-size: 13px;
    color: var(--text-muted);
}

.footer-legal {
    display: flex;
    gap: var(--spacing-lg);
}

.footer-legal a {
    font-size: 13px;
    color: var(--text-muted);
    transition: color var(--transition-fast);
}

.footer-legal a:hover {
    color: var(--text-primary);
}

/* ========================================
   Responsive Design
======================================== */

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

    .actions-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .status-grid {
        grid-template-columns: 1fr;
    }

    .announcements-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .announcement-card.featured {
        grid-column: span 2;
    }
}

@media (max-width: 992px) {
    .nav-links,
    .nav-cta,
    .nav-profile,
    .profile-notifications,
    .profile-wrapper,
    .profile-info,
    .notification-btn {
        display: none !important;
    }

    .mobile-menu-btn {
        display: flex;
        cursor: pointer;
        background: none;
        border: none;
    }

    .mobile-menu-btn.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-btn.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    .profile-details {
        display: none;
    }

    .profile-chevron {
        display: none;
    }
}

/* Mobile Sidebar Menu */
.nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 998;
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.mobile-sidebar {
    position: fixed;
    top: 0;
    right: -300px;
    width: 300px;
    height: 100vh;
    background: #0a0a0a;
    z-index: 999;
    transition: right 0.3s ease;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.mobile-sidebar.active {
    right: 0;
}

.mobile-sidebar-header {
    background: linear-gradient(135deg, var(--accent-red, #D71515) 0%, #8B0000 100%);
    padding: 40px 24px 30px;
    position: relative;
    overflow: hidden;
}

.mobile-sidebar-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
}

.mobile-sidebar-brand {
    position: relative;
    z-index: 1;
}

.mobile-sidebar-logo {
    height: 45px;
    width: auto;
    margin-bottom: 12px;
}

.mobile-sidebar-tagline {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
    letter-spacing: 0.5px;
}

.mobile-sidebar-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    background: rgba(0, 0, 0, 0.2);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.mobile-sidebar-close svg {
    width: 18px;
    height: 18px;
    stroke: white;
}

.mobile-sidebar-nav {
    padding: 20px 0;
    flex: 1;
}

.mobile-nav-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 24px;
    color: var(--text-secondary, rgba(255,255,255,0.7));
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.mobile-nav-item:hover,
.mobile-nav-item.active {
    background: rgba(215, 21, 21, 0.08);
    color: var(--text-primary, #fff);
    border-left-color: var(--accent-red, #D71515);
}

.mobile-nav-item svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    stroke-width: 1.5;
    fill: none;
}

.mobile-sidebar-footer {
    padding: 20px 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.mobile-sidebar-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, var(--accent-red, #D71515) 0%, #8B0000 100%);
    color: white;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.mobile-sidebar-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(215, 21, 21, 0.3);
}

.mobile-sidebar-cta svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

/* Mobile Sidebar Profile */
.mobile-sidebar-profile {
    display: none;
    padding: 16px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.mobile-sidebar-profile.visible {
    display: block;
}

.mobile-profile-info {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.mobile-profile-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid var(--accent-red, #D71515);
    object-fit: cover;
}

.mobile-profile-details {
    flex: 1;
}

.mobile-profile-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary, #fff);
    display: block;
}

.mobile-profile-role {
    font-size: 12px;
    color: var(--text-muted, rgba(255,255,255,0.5));
}

.mobile-logout-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text-secondary, rgba(255,255,255,0.7));
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.mobile-logout-btn:hover {
    background: rgba(215, 21, 21, 0.1);
    border-color: rgba(215, 21, 21, 0.3);
    color: var(--accent-red, #D71515);
}

.mobile-logout-btn svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
}

.mobile-sidebar-login {
    display: block;
}

.mobile-sidebar-login.hidden {
    display: none;
}

.mobile-nav-badge {
    margin-left: auto;
    padding: 2px 8px;
    background: var(--accent-red, #D71515);
    color: white;
    font-size: 11px;
    font-weight: 600;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
}

@media (max-width: 768px) {
    :root {
        --spacing-xl: 24px;
        --spacing-2xl: 32px;
        --spacing-3xl: 48px;
    }

    .container {
        padding: 0 var(--spacing-md);
    }

    .welcome-name {
        font-size: 32px;
    }

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

    .actions-grid {
        grid-template-columns: 1fr;
    }

    .status-metrics {
        grid-template-columns: 1fr;
    }

    .announcements-grid {
        grid-template-columns: 1fr;
    }

    .announcement-card.featured {
        grid-column: span 1;
    }

    .footer-content {
        flex-direction: column;
        gap: var(--spacing-xl);
    }

    .footer-links-grid {
        flex-wrap: wrap;
        gap: var(--spacing-xl);
    }

    .footer-bottom {
        flex-direction: column;
        gap: var(--spacing-md);
        text-align: center;
    }
}

@media (max-width: 480px) {
    .welcome-header {
        flex-direction: column;
        gap: var(--spacing-md);
    }

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

    .stat-badge,
    .stat-trend {
        margin-top: var(--spacing-sm);
        width: 100%;
        text-align: center;
    }

    .status-main {
        flex-direction: column;
        text-align: center;
    }

    .join-button {
        width: 100%;
    }
}

/* ========================================
   Enhanced Mobile Responsive Styles
======================================== */

/* Extra small devices (phones, 375px and below) */
@media (max-width: 375px) {
    html {
        font-size: 14px;
    }

    .container {
        padding: 0 12px;
    }

    .nav-container {
        padding: 0 12px;
    }

    .navbar {
        padding: 12px 0;
    }

    .nav-logo img {
        height: 32px;
    }

    h1, .page-title {
        font-size: 28px !important;
    }

    h2, .section-title {
        font-size: 22px !important;
    }

    .btn, button {
        padding: 12px 16px;
        font-size: 13px;
    }
}

/* Small devices (phones, 576px and below) */
@media (max-width: 576px) {
    .container {
        padding: 0 16px;
    }

    /* Typography scaling */
    h1 {
        font-size: 32px;
        line-height: 1.2;
    }

    h2 {
        font-size: 24px;
    }

    h3 {
        font-size: 20px;
    }

    p {
        font-size: 14px;
    }

    /* Cards */
    .card, .glass-card {
        padding: 16px;
        border-radius: 12px;
    }

    /* Buttons full width on mobile */
    .btn-primary, .btn-secondary, .btn-outline {
        width: 100%;
        justify-content: center;
    }

    /* Grid layouts */
    .grid, .features-grid, .cards-grid {
        grid-template-columns: 1fr !important;
        gap: 16px;
    }

    /* Flex layouts */
    .flex-row {
        flex-direction: column;
    }

    /* Hide decorative elements on mobile */
    .bg-orb, .particles, .grid-pattern {
        opacity: 0.3;
    }

    /* Footer */
    .footer {
        padding: 40px 0 20px;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }

    .footer-links {
        flex-direction: column;
        gap: 24px;
    }

    .footer-column {
        text-align: center;
    }

    .footer-social {
        justify-content: center;
    }
}

/* Medium devices (tablets, 768px and below) - Enhanced */
@media (max-width: 768px) {
    /* Navigation */
    .navbar {
        padding: 12px 0;
    }

    .nav-logo img {
        height: 36px;
    }

    /* Hero sections */
    .hero, .page-hero {
        padding: 80px 0 60px;
        min-height: auto;
    }

    .hero-content {
        text-align: center;
    }

    .hero-title {
        font-size: 36px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .hero-buttons {
        flex-direction: column;
        gap: 12px;
    }

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

    /* Sections */
    section {
        padding: 48px 0;
    }

    .section-header {
        margin-bottom: 32px;
    }

    /* Tables responsive */
    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    /* Forms */
    .form-group {
        margin-bottom: 16px;
    }

    .form-input, .form-textarea, input, textarea, select {
        padding: 14px 16px;
        font-size: 16px; /* Prevents zoom on iOS */
    }

    /* Modal */
    .modal-box {
        width: 95%;
        max-width: none;
        margin: 16px;
        max-height: 90vh;
        overflow-y: auto;
    }

    .modal-content {
        padding: 20px;
    }
}

/* Landscape phones */
@media (max-width: 812px) and (orientation: landscape) {
    .hero {
        min-height: auto;
        padding: 40px 0;
    }

    .modal-box {
        max-height: 85vh;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Larger touch targets */
    .btn, button, a.btn, .nav-link, .mobile-nav-item {
        min-height: 44px;
        min-width: 44px;
    }

    /* Remove hover effects that don't work on touch */
    .card:hover, .product-card:hover {
        transform: none;
    }

    /* Keep focus states for accessibility */
    .btn:active, button:active {
        transform: scale(0.98);
    }
}

/* High DPI screens */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* Sharper borders */
    .card, .glass-card {
        border-width: 0.5px;
    }
}

/* Safe area for notched phones (iPhone X+) */
@supports (padding: max(0px)) {
    .navbar {
        padding-top: max(12px, env(safe-area-inset-top));
    }

    .footer {
        padding-bottom: max(20px, env(safe-area-inset-bottom));
    }

    .mobile-sidebar {
        padding-top: env(safe-area-inset-top);
        padding-bottom: env(safe-area-inset-bottom);
    }
}

/* Print styles */
@media print {
    .navbar, .footer, .mobile-menu-btn, .mobile-sidebar {
        display: none !important;
    }

    body {
        background: white;
        color: black;
    }

    .container {
        max-width: 100%;
    }
}

/* ========================================
   Utility Classes
======================================== */

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

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-accent);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--hover-state);
}

/* Selection */
::selection {
    background: rgba(215, 21, 21, 0.3);
    color: var(--text-primary);
}
