/* =========================================
   ORKYA OS - PREMIUM DESIGN SYSTEM
   Version: 1.3 (Catering Extensions)
   ========================================= */

/* --- SPACING SCALE (GAP VALUES) ---
   gap: 2px / 0.25rem - Extra tight (special effects, compact indicators)
   gap: 0.5rem         - Tight spacing (badges, chips, small groups)
   gap: 0.75rem        - Medium spacing (form fields, button groups)
   gap: 1rem           - Normal spacing (card content, sections)
   gap: 1.5rem         - Large spacing (major sections)
   gap: 2rem           - Extra large (page-level sections)
   gap: 0              - No gap (seamless grids, special layouts)
   ========================================= */

/* --- 0. GLOBAL RESET & BOX MODEL --- */
*, *::before, *::after {
    box-sizing: border-box;
}

/* Global link reset - no purple! */
a {
    color: inherit;
    text-decoration: none;
}

a:visited {
    color: inherit;
}

:root {
    /* --- COLOR PALETTE --- */
    --bg-app: #0f172a;
    --bg-secondary: #111827;
    --bg-surface: #1e293b;
    --glass-bg: rgba(30, 41, 59, 0.6);
    --glass-border: rgba(255, 255, 255, 0.08);
    --bg-glass: rgba(255, 255, 255, 0.03);
    --bg-glass-hover: rgba(255, 255, 255, 0.06);
    
    /* Borders */
    --border-subtle: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.12);
    --border-accent: rgba(245, 158, 11, 0.5);
    
    /* Accents */
    --accent-primary: #6366f1;   /* Indigo 500 */
    --accent-success: #10b981;   /* Emerald 500 */
    --accent-warning: #f59e0b;   /* Amber 500 */
    --accent-danger:  #f43f5e;   /* Rose 500 */
    --accent-purple:  #8b5cf6;
    --accent-cyan:    #06b6d4;
    --accent-info:    #3b82f6;
    --success-light: rgba(16, 185, 129, 0.15);
    --danger-light: rgba(239, 68, 68, 0.15);
    --info-light: rgba(59, 130, 246, 0.15);

    /* Text */
    --text-primary: #ffffff;
    --text-secondary: #94a3b8;   /* Slate 400 */
    --text-muted:     #64748b;   /* Slate 500 */
    --text-disabled:  #475569;

    /* Premium Gradients (Blue to Orange) */
    --premium-gradient: linear-gradient(135deg, #6366f1 0%, #f59e0b 100%);
    --premium-glow: 0 0 20px rgba(99, 102, 241, 0.3);
    
    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 20px rgba(245, 158, 11, 0.3);
    
    /* Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.25s ease;
    --transition-slow: 0.4s ease;
}

/* --- UTILITIES --- */
.text-gradient, .text-gradient-span {
    background-image: var(--premium-gradient) !important;
    background-size: 100% !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
    color: transparent !important;
    display: inline-block !important;
}

.icon-gradient i, .icon-gradient {
    background-image: var(--premium-gradient) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
    color: transparent !important;
}


/* --- LAYOUTS --- */
.dashboard-container {
    padding: 4rem 0;
    max-width: 1400px;
    margin: 0 auto;
    width: 95%; /* Responsive safety */
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 340px; /* Main vs Sidebar */
    gap: 2rem;
}

@media (max-width: 1024px) {
    .dashboard-grid { grid-template-columns: 1fr; }
}

/* --- COMPONENTS: HEADER --- */
.haiku-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 3rem;
}

/* PREMIUM BRANDING HEADER (LOGO REPLACEMENT) */
.orka-brand-header {
    font-size: 2.25rem;
    font-weight: 900;
    letter-spacing: -2px;
    background: var(--premium-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-flex;
    align-items: center;
    gap: 2px;
    margin-bottom: 1.5rem;
    line-height: 1;
    filter: drop-shadow(0 4px 12px rgba(99, 102, 241, 0.2));
}

.orka-brand-header span {
    font-size: 0.5em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 0.5rem;
}

.orka-brand-header-sm {
    font-size: 1.5rem;
}

.user-welcome-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.1;
    letter-spacing: -1px;
}

.user-welcome-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.org-badge {
    background: rgba(255,255,255,0.1);
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: 1px solid var(--glass-border);
}

/* --- CONFIG BOXES (Equal Size) --- */
.config-box {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 220px;
    background: rgba(30, 41, 59, 0.3);
    border: 1px solid var(--border-subtle);
    border-radius: 20px;
    padding: 1.5rem;
    transition: transform 0.2s, border-color 0.2s;
}

.config-box:hover {
/* --- SUPER DESIGN / RESCUE MODE (Glassmorphism & Neon) --- */
.super-glass-modal {
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7);
}

/* Super Input (Ghost + Neon Glow) */
.super-input, .super-select, .super-textarea {
    background: rgba(15, 23, 42, 0.6) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: white !important;
    border-radius: 12px !important;
    width: 100%;
    padding: 12px 16px;
    font-size: 0.95rem;
    outline: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.super-input::placeholder, .super-textarea::placeholder {
    color: rgba(148, 163, 184, 0.5); /* Slate 400/50 */
}

/* Focus States (Neon) */
.super-input:focus, .super-select:focus, .super-textarea:focus {
    background: rgba(15, 23, 42, 0.8) !important;
    border-color: #6366f1 !important; /* Indigo 500 */
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.25) !important;
    transform: translateY(-1px);
}

/* Color Variants for Focus */
.focus-neon-emerald:focus {
    border-color: #10b981 !important;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.25) !important;
}

.focus-neon-amber:focus {
    border-color: #f59e0b !important;
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.25) !important;
}

.focus-neon-cyan:focus {
    border-color: #06b6d4 !important;
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.25) !important;
}

.focus-neon-rose:focus {
    border-color: #f43f5e !important;
    box-shadow: 0 0 20px rgba(244, 63, 94, 0.25) !important;
}

/* Magic Button (Super Glow) */
.btn-super-magic {
    background: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
    color: white;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    padding: 14px 24px;
    border-radius: 14px;
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.4);
    transition: all 0.3s ease;
}

.btn-super-magic:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 0 40px rgba(99, 102, 241, 0.6);
    background: linear-gradient(135deg, #6366f1 0%, #d946ef 100%);
}

/* Section Cards (Interactive) */
.super-card-section {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.super-card-section:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 30px -10px rgba(0,0,0,0.5);
}

/* Typography */
.super-label {
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 8px;
    display: block;
    color: #94a3b8; /* Default */
}

/* Visibility Utilities (since Tailwind is missing) */
.hidden { display: none !important; }
.block { display: block !important; }
.relative { position: relative !important; }
.absolute { position: absolute !important; }
.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.z-50 { z-index: 50; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.w-full { width: 100%; }
.h-full { height: 100%; }
.gap-4 { gap: 1rem; }
.p-6 { padding: 1.5rem; }
.rounded-2xl { border-radius: 1rem; }
.text-white { color: white; }
.text-center { text-align: center; }

.orka-flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* --- COMPONENTS: BUTTONS --- */
.action-deck {
    display: flex;
    gap: 1rem;
}

.btn-action-glass {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 100px; /* Pill */
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem; /* Standardized gap */
    min-height: 44px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
    text-align: center;
}

.btn-action-glass i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    line-height: 1;
    flex-shrink: 0; /* Prevent icon from shrinking */
}

/* Ensure text in span wraps properly when needed */
.btn-action-glass > span {
    flex-shrink: 1;
    min-width: 0; /* Allow text to shrink if needed */
}

.btn-action-glass:hover {
    background: rgba(255,255,255,0.15);
    transform: translateY(-2px);
    border-color: rgba(255,255,255,0.3);
    color: white;
}

/* PRIMARY / MAGIC (Blue-to-Orange) */
.btn-action-primary, .btn-action-magic {
    background: linear-gradient(135deg, #6366f1 0%, #f59e0b 100%);
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

.btn-action-primary:hover, .btn-action-magic:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(245, 158, 11, 0.5);
    filter: brightness(1.1);
    color: white;
}

/* VIVID MAGIC BUTTON (Refined: Indigo to Cyan) */
.orka-btn-magic-vivid {
    background: linear-gradient(135deg, #6366f1 0%, #3b82f6 50%, #06b6d4 100%);
    color: white;
    border: none;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4);
    position: relative;
    overflow: hidden;
}

.orka-btn-magic-vivid::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.2) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.3s;
}

.orka-btn-magic-vivid:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(6, 182, 212, 0.5);
    filter: brightness(1.1);
    color: white;
}

.orka-btn-magic-vivid:hover::after {
    opacity: 1;
}

/* SUCCESS (Emerald-Teal) */
.btn-action-success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
}

.btn-action-success:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(5, 150, 105, 0.5);
    filter: brightness(1.1);
}

/* WARNING (Amber-Orange) */
.btn-action-warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.btn-action-warning:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(217, 119, 6, 0.5);
    filter: brightness(1.1);
}

/* DANGER (Rose-Red) */
.btn-action-danger {
    background: linear-gradient(135deg, #f43f5e 0%, #e11d48 100%);
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(244, 63, 94, 0.3);
}

.btn-action-danger:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(225, 29, 72, 0.4);
    filter: brightness(1.1);
}

/* INFO (Sky-Blue) */
.btn-action-info {
    background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(14, 165, 233, 0.3);
}

.btn-action-info:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(37, 99, 235, 0.4);
    filter: brightness(1.1);
}

/* --- COMPONENTS: CARDS --- */
.glass-panel {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    backdrop-filter: blur(12px);
    padding: 1.5rem;
}

/* HERO CARD */
.hero-card {
    background: linear-gradient(145deg, rgba(30,41,59,0.8), rgba(15,23,42,0.95));
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
    margin-bottom: 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.hero-bg-glow {
    position: absolute;
    top: -50%;
    left: -20%;
    width: 80%;
    height: 200%;
    background: radial-gradient(circle, rgba(99,102,241,0.15) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.hero-content { position: relative; z-index: 1; }

.hero-label {
    color: var(--accent-success); /* Default Emerald */
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.8rem;
    margin-bottom: 1rem;
    display: block;
}

.hero-title {
    font-size: 2rem; 
    font-weight: 800; 
    color: white; 
    margin-bottom: 0.5rem;
}

.hero-meta {
    color: var(--text-secondary);
    font-size: 1rem;
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.hero-action {
    position: relative; 
    z-index: 1;
}

/* APP GRID */
.app-grid-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.app-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 28px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(16px);
}

.app-card:hover {
    background: rgba(255,255,255,0.05);
    border-color: rgba(255,255,255,0.2);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.app-card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    gap: 1rem;
}

/* HUB/RING SPECIFIC */
.ring-kpi-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    background: rgba(0,0,0,0.2);
    border-radius: 20px;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
}

.ring-kpi-item {
    display: flex;
    flex-direction: column;
}

.ring-kpi-label {
    font-size: 0.65rem;
    font-weight: 800;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 2px;
}

.ring-kpi-value {
    font-size: 1.25rem;
    font-weight: 900;
    color: white;
}

.app-icon {
    width: 50px;
    height: 50px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.app-name {
    color: white;
    font-weight: 700;
    font-size: 1rem;
    margin: 0;
}

.app-desc {
    color: var(--text-muted);
    font-size: 0.75rem;
    line-height: 1.4;
    margin: 0;
}

/* SIDEBAR */
.sidebar-panel {
    background: rgba(15, 23, 42, 0.4);
    border-radius: 24px;
    border: 1px solid var(--glass-border);
    padding: 1.5rem;
    height: fit-content;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

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

.stat-val { color: white; font-weight: 700; font-size: 1.1rem; }
.stat-key { color: var(--text-secondary); font-size: 0.9rem; }


/* --- EXTENSIONS (From Event Hub) --- */

/* TABS */
.tab-group {
    display: flex;
    gap: 0.5rem;
    background: rgba(0,0,0,0.2);
    padding: 6px;
    border-radius: 24px;
    width: fit-content;
    margin-bottom: 2.5rem;
    border: 1px solid var(--glass-border);
}
.tab-item {
    padding: 0.75rem 1.5rem;
    border-radius: 18px;
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.tab-item.active {
    background: white;
    color: black;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* --- COMPONENTS: MODALS (ORKA OS PREMIUM) --- */
.orka-modal-backdrop, .os-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(12px);
    z-index: 2000;
    display: none; /* Hidden by default */
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    animation: fadeIn 0.3s ease-out;
}

.orka-modal-content, .os-modal-card {
    background: #1e293b;
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    width: 100%;
    max-width: 500px;
    padding: 2.5rem;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 40px rgba(99, 102, 241, 0.1);
    animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.orka-form-group {
    margin-bottom: 1.5rem;
}

.orka-label {
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--text-secondary);
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
    display: block;
}

.orka-input, .orka-select {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 0.8rem 1.2rem;
    color: white;
    width: 100%;
    font-size: 0.95rem;
    font-weight: 500;
    outline: none;
    transition: all 0.2s;
}

.orka-input:focus, .orka-select:focus {
    border-color: var(--accent-primary);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 15px rgba(99, 102, 241, 0.2);
}

/* AUTH SPECIFIC DENSITY */
.orka-input-auth {
    padding: 0.7rem 1.1rem !important;
    font-size: 0.9rem !important;
    border-radius: 14px !important;
    height: 48px !important; /* Fixed but professional height */
    box-sizing: border-box !important;
}

.orka-label-auth {
    font-size: 0.7rem !important;
    margin-bottom: 0.4rem !important;
    opacity: 0.8;
}

/* --- ANIMATIONS --- */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

.animate-float {
    animation: float 4s ease-in-out infinite;
}

/* --- DATA TABLES & LISTS --- */
.table-os {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 0.5rem;
    margin-top: 1rem;
}
.table-os thead th {
    text-align: left;
    padding: 1rem;
    color: var(--text-secondary);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}
.table-os tbody tr {
    background: rgba(30, 41, 59, 0.4);
    transition: all 0.2s;
}
.table-os tbody tr:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: scale(1.005);
}
.table-os td {
    padding: 1rem;
    color: white;
    border-top: 1px solid var(--glass-border);
    border-bottom: 1px solid var(--glass-border);
}
.table-os td:first-child {
    border-left: 1px solid var(--glass-border);
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;
}
.table-os td:last-child {
    border-right: 1px solid var(--glass-border);
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}

/* --- BADGES --- */
.badge-os {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.badge-success {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.2);
}
.badge-warning {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.2);
}
.badge-neutral {
    background: rgba(148, 163, 184, 0.2);
    color: #cbd5e1;
    border: 1px solid rgba(148, 163, 184, 0.2);
}

/* --- MEDIA CARDS (Recipes) --- */
.card-media {
    background: linear-gradient(180deg, rgba(255,255,255,0.04) 0%, rgba(255,255,255,0.01) 100%);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}
.card-media:hover {
    transform: translateY(-6px);
    border-color: var(--accent-primary);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}
.card-media-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    background: rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: center;
}
.card-media-content {
    padding: 1.25rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* --- FILTERS --- */
.filter-bar {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    align-items: center;
}
.filter-input {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    color: var(--text-primary);
    min-width: 200px;
}
/* --- HUB LAYOUTS --- */
.haiku-header-xl h1 { 
    font-size: 5rem; 
    letter-spacing: -3px; 
    line-height: 0.9; 
    font-weight: 900; 
    margin-bottom: 2rem;
}
.haiku-header-xl .text-gradient { display: inline; }

.hub-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr)); 
    gap: 2rem; 
}

.meal-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
}

@media (max-width: 1024px) {
    .haiku-header-xl h1 { font-size: 3.5rem; }
}

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

/* === MOBILE RESPONSIVENESS (B-MAD Approved) === */
@media (max-width: 768px) {
    /* Layout */
    .dashboard-container { padding: 1rem; width: 100%; }
    .dashboard-grid { grid-template-columns: 1fr; gap: 1rem; }
    
    /* Header */
    .haiku-header { flex-direction: column; align-items: flex-start; gap: 1rem; }
    .haiku-header-xl { flex-direction: column !important; gap: 2rem !important; align-items: flex-start !important; margin-bottom: 3rem !important; }
    .haiku-header-xl h1 { font-size: 2.5rem !important; letter-spacing: -1px !important; }
    .haiku-header-xl > div:last-child { 
        width: 100% !important; 
        align-items: flex-start !important; 
        padding: 0 !important;
        border: none !important;
    }

    /* Hub Card Internal Layouts */
    .finance-card-body {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 2rem !important;
    }
    .finance-card-body > div {
        width: 100% !important;
    }
    .finance-stats-grid {
        grid-template-columns: 1fr !important;
        gap: 1.5rem !important;
    }
    .finance-actions {
        width: 100% !important;
    }

    .user-welcome-title { font-size: 1.75rem; }
    .action-deck { width: 100%; flex-wrap: wrap; }
    .btn-action-glass { flex: 1 1 45%; font-size: 0.8rem; }
    
    /* Hub Grid */
    .hub-grid { grid-template-columns: 1fr !important; gap: 1.5rem !important; }
    .col-span-2, .col-span-3 { grid-column: span 1 !important; }

    .meal-grid { 
        grid-template-columns: 1fr !important; 
    }
    .meal-slot-card {
        border-right: none !important;
        border-bottom: 1px solid var(--border-subtle) !important;
    }
    .meal-slot-card:last-child {
        border-bottom: none !important;
    }
    
    /* Hero */
    .hero-card { 
        flex-direction: column; 
        padding: 1.5rem; 
        border-radius: 20px; 
        text-align: center; 
    }
    .hero-title { font-size: 1.5rem; }
    .hero-meta { flex-wrap: wrap; justify-content: center; gap: 0.75rem; }
    
    /* App/Hub Grid */
    .app-grid { grid-template-columns: 1fr; gap: 1rem; }
    .app-card { padding: 1.25rem; border-radius: 20px; }
    
    /* Tabs - Horizontal scroll */
    .tab-group { overflow-x: auto; width: 100%; -webkit-overflow-scrolling: touch; }
    .tab-item { padding: 0.5rem 1rem; font-size: 0.75rem; white-space: nowrap; }
    
    /* Tables → Card Layout */
    .table-os { display: block; }
    .table-os thead { display: none; }
    .table-os tbody tr { 
        display: flex; 
        flex-direction: column; 
        margin-bottom: 1rem; 
        border-radius: 12px; 
        background: rgba(30, 41, 59, 0.6);
        padding: 1rem;
    }
    .table-os td { 
        display: flex; 
        justify-content: space-between; 
        padding: 0.5rem 0;
        border: none !important;
        border-radius: 0 !important;
    }
    .table-os td::before { 
        content: attr(data-label); 
        font-weight: 700; 
        color: var(--text-muted); 
        margin-right: 1rem;
    }
    
    /* Modals */
    .orka-modal-content, .os-modal-card { 
        max-width: 95%; 
        padding: 1.5rem; 
        border-radius: 24px; 
        max-height: 90vh;
        overflow-y: auto;
    }
    
    /* Filters */
    .filter-bar { flex-direction: column; }
    .filter-input { width: 100%; min-width: unset; }
    
    /* Sidebar panel */
    .sidebar-panel { border-radius: 16px; margin-top: 1rem; }
    
    /* Ring KPI Grid */
    .ring-kpi-grid { grid-template-columns: 1fr; gap: 0.75rem; }
}

/* Small phones */
@media (max-width: 480px) {
    .hero-title { font-size: 1.25rem; }
    .user-welcome-title { font-size: 1.5rem; }
    .btn-action-glass { flex: 1 1 100%; }
    .app-card { padding: 1rem; }
}

/* Touch Optimization (Sally's recommendation) */
@media (pointer: coarse) {
    .btn-action-glass, .orka-btn { min-height: 44px; }
    .tab-item { min-height: 44px; display: flex; align-items: center; }
    .orka-sidebar-link { padding: 0.75rem; }
    .filter-input, .orka-input, .orka-select { min-height: 44px; }
}

/* --- NAV BUBBLES (Standardized) --- */
.orka-nav-bubbles {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
}

.nav-card {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    background: rgba(30, 41, 59, 0.4); /* fallback for bg-surface */
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.nav-card i {
    font-size: 1rem;
    opacity: 0.7;
}

.nav-card:hover {
    background: var(--bg-glass-hover);
    border-color: var(--accent-primary);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.nav-card:hover i {
    opacity: 1;
    color: var(--accent-primary);
}

.nav-card.active {
    background: var(--premium-gradient);
    border-color: transparent;
    color: white;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

.nav-card.active i {
    opacity: 1;
    color: white;
}

/* =========================================
   VOLUNTEER HUB - EVENT DETAIL (Party Mode #8)
   ========================================= */

/* --- EVENT HERO --- */
.event-hero {
    background: linear-gradient(145deg, rgba(30,41,59,0.8), rgba(15,23,42,0.95));
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
    margin-bottom: 2rem;
}

.event-hero .glow {
    position: absolute;
    top: -50%;
    left: -20%;
    width: 80%;
    height: 200%;
    background: radial-gradient(circle, rgba(99,102,241,0.15) 0%, transparent 70%);
    pointer-events: none;
}

/* --- COUNTDOWN BADGES --- */
.countdown-badge {
    background: var(--premium-gradient);
    padding: 0.5rem 1.25rem;
    border-radius: 100px;
    font-weight: 800;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
}

.countdown-badge.dday-badge {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    animation: pulse-glow 2s infinite;
}

@keyframes pulse-glow {
    0%, 100% { opacity: 1; box-shadow: 0 0 15px rgba(16, 185, 129, 0.3); }
    50% { opacity: 0.85; box-shadow: 0 0 25px rgba(16, 185, 129, 0.5); }
}

/* --- INFO CARDS --- */
.info-card {
    background: rgba(30, 41, 59, 0.7); /* Slightly more solid */
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 1.5rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.info-card:hover {
    border-color: var(--accent-primary);
    background: rgba(30, 41, 59, 0.9);
}

/* --- SHIFT ITEMS --- */
.shift-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1rem 1.25rem;
    margin-bottom: 0.75rem;
    transition: all 0.2s ease;
}

.shift-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(4px);
}

/* --- QR CONTAINER --- */
.qr-container {
    background: white;
    padding: 1rem;
    border-radius: 20px;
    display: inline-block;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    transition: transform 0.2s ease;
}

.qr-container:hover {
    transform: scale(1.05);
}

/* --- PASS STATES --- */
.pass-locked {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
}

.pass-active {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
}

.pass-suspended {
    background: rgba(244, 63, 94, 0.15);
    border: 1px solid rgba(244, 63, 94, 0.3);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
}

/* --- AVAILABILITY SLOTS (Ultra Robust Visibility) --- */
.slot-toggle {
    display: flex !important;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1rem;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 48px;
    background: rgba(30, 41, 59, 0.5) !important;
    color: #cbd5e1;
    position: relative;
    user-select: none;
}

.slot-toggle:hover {
    background: rgba(255, 255, 255, 0.08) !important;
    border-color: rgba(255, 255, 255, 0.3) !important;
}

.slot-toggle.active {
    background: #6366f1 !important; /* solid Indigo 500 */
    border-color: #818cf8 !important;
    color: white !important;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.5) !important;
}

.slot-check {
    margin-left: auto;
    display: none !important; /* Force hide */
    font-size: 0.9rem;
    color: white !important;
}

.slot-toggle.active .slot-check {
    display: block !important; /* Force show when active */
    animation: bounceScale 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

/* Day Card Refinement */
.day-card {
    background: rgba(30, 41, 59, 0.4) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 20px;
    overflow: hidden;
}

.day-card:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

.day-card-header {
    background: rgba(0, 0, 0, 0.3);
    padding: 0.875rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
}

.day-card-body {
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

/* Day Tags */
.day-tag {
    font-size: 0.65rem;
    font-weight: 800;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    text-transform: uppercase;
    border: 1px solid transparent; /* For borders to work */
}

.day-tag-event {
    background: rgba(99, 102, 241, 0.2); /* Indigo 500/20 */
    color: #818cf8; /* Indigo 400 */
    border-color: rgba(99, 102, 241, 0.3);
}

.day-tag-montage {
    background: rgba(245, 158, 11, 0.2); /* Amber 500/20 */
    color: #fbbf24; /* Amber 400 */
    border-color: rgba(245, 158, 11, 0.3);
}

.day-tag-demontage {
    background: rgba(100, 116, 139, 0.2); /* Slate 500/20 */
    color: #94a3b8; /* Slate 400 */
    border-color: rgba(100, 116, 139, 0.3);
}

.day-tag-prep {
    background: rgba(30, 41, 59, 0.5); /* Slate 800 */
    color: #64748b; /* Slate 500 */
    border-color: rgba(255, 255, 255, 0.05);
}

/* --- ENGAGEMENT CARD --- */
.engagement-card {
    background: rgba(99, 102, 241, 0.05);
    border: 1px dashed rgba(99, 102, 241, 0.3);
    border-radius: 20px;
    padding: 1.25rem;
}

.engagement-input {
    width: 5rem;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    padding: 0.75rem 1rem;
    text-align: center;
    font-size: 1.5rem;
    font-weight: 900;
    color: white;
    min-height: 48px; /* Touch target */
}

.engagement-input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 15px rgba(99, 102, 241, 0.2);
}

/* Motivational Message Animation */
.motivation-msg {
    animation: slideIn 0.3s ease-out;
}

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

/* --- BUDDY SYSTEM --- */
.buddy-card {
    background: linear-gradient(145deg, rgba(139, 92, 246, 0.05), rgba(99, 102, 241, 0.05));
    border: 1px solid rgba(139, 92, 246, 0.2);
}

.buddy-tabs {
    display: flex;
    background: rgba(0,0,0,0.4);
    padding: 0.25rem;
    border-radius: 14px;
}

.buddy-tab {
    flex: 1;
    padding: 0.75rem;
    text-align: center;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--text-secondary);
    min-height: 44px; /* Touch target */
    display: flex;
    align-items: center;
    justify-content: center;
}

.buddy-tab.active {
    background: var(--accent-purple);
    color: white;
}

.buddy-code-display {
    background: rgba(139, 92, 246, 0.1);
    padding: 0.875rem;
    border-radius: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.buddy-code {
    font-size: 1.25rem;
    font-weight: 900;
    color: white;
    letter-spacing: 0.15em;
}

/* Member Avatars */
.member-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.member-chip {
    background: rgba(255,255,255,0.05);
    padding: 0.5rem 0.75rem;
    border-radius: 10px;
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    animation: fadeInUp 0.3s ease-out backwards;
}

.member-chip:nth-child(1) { animation-delay: 0ms; }
.member-chip:nth-child(2) { animation-delay: 50ms; }
.member-chip:nth-child(3) { animation-delay: 100ms; }
.member-chip:nth-child(4) { animation-delay: 150ms; }
.member-chip:nth-child(5) { animation-delay: 200ms; }

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.member-avatar {
    width: 24px;
    height: 24px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-purple));
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 0.65rem;
    font-weight: 800;
    color: white;
}

.member-status {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent-success);
}

/* --- SAVED INDICATOR --- */
.saved-indicator {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--accent-success);
    font-size: 0.75rem;
    font-weight: 700;
    animation: fadeInScale 0.3s ease-out;
}

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

/* --- TOP BAR (Event Detail) --- */
.event-topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 64px;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    z-index: 1001;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
}

.event-topbar-back {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 700;
    transition: color 0.2s ease;
    min-height: 44px; /* Touch target */
    min-width: 44px;
}

.event-topbar-back:hover {
    color: white;
}

.event-topbar-title {
    font-size: 1.125rem;
    font-weight: 900;
    background: linear-gradient(135deg, #818cf8, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --- MOBILE OPTIMIZATIONS (Volunteer Hub) --- */
@media (max-width: 768px) {
    .event-hero {
        padding: 1.5rem;
        border-radius: 24px;
    }
    
    .event-hero h1 {
        font-size: 1.75rem !important;
    }
    
    .info-card {
        padding: 1.25rem;
        border-radius: 20px;
    }
    
    .day-card-header {
        padding: 0.75rem;
    }
    
    .slot-toggle {
        padding: 1rem;
    }
    
    .buddy-code {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .event-topbar-title {
        max-width: 150px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    
    .countdown-badge {
        font-size: 0.75rem;
        padding: 0.4rem 1rem;
    }
}

/* Touch devices - ensure 48px targets */
@media (pointer: coarse) {
    .slot-toggle {
        min-height: 52px;
        padding: 1rem 1.25rem;
    }
    
    .buddy-tab {
        min-height: 48px;
    }
    
    .event-topbar-back {
        min-height: 48px;
        padding: 0 0.5rem;
    }
}

/* Hide x-cloak elements until Alpine loads */
[x-cloak] { display: none !important; }

/* =========================================
   ORKA LEGACY EXTENSIONS (Merged from orka.css)
   ========================================= */

/* --- NAVBAR --- */
.orka-nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1rem 2rem;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-subtle);
    position: sticky;
    top: 0;
    z-index: 100;
}

.orka-nav-brand {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--accent-warning);
    text-decoration: none;
}

.orka-nav-links {
    display: flex;
    gap: 1rem;
    margin-left: auto;
}

.orka-nav-link {
    color: var(--text-muted);
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.orka-nav-link:hover {
    color: var(--text-primary);
    background: var(--bg-glass);
}

.orka-nav-link.active {
    color: var(--accent-primary);
}

/* --- ORKA CARDS --- */
.orka-card {
    background: var(--bg-glass);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    transition: all var(--transition-normal);
}

.orka-card:hover {
    background: var(--bg-glass-hover);
    border-color: var(--border-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.orka-card-glass {
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}

.orka-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-subtle);
}

.orka-card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* --- ORKA BUTTONS --- */
.orka-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
    /* Rigorous sizing */
    box-sizing: border-box;
    line-height: 1.2;
}

.orka-btn-primary {
    background: linear-gradient(135deg, var(--accent-warning) 0%, #d97706 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.orka-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(245, 158, 11, 0.4);
    color: white;
}

.orka-btn-secondary {
    background: var(--bg-glass);
    border: 1px solid var(--border-light);
    color: var(--text-secondary);
}

.orka-btn-secondary:hover {
    background: var(--bg-glass-hover);
    color: var(--text-primary);
}

.orka-btn-ghost {
    background: transparent;
    color: var(--text-muted);
    padding: 0.5rem 1rem;
}

.orka-btn-ghost:hover {
    color: var(--text-primary);
    background: var(--bg-glass);
}

.orka-btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
}

.orka-btn-icon {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: var(--radius-sm);
}

/* --- ORKA TABLES --- */
.orka-table {
    width: 100%;
    border-collapse: collapse;
}

.orka-table thead {
    background: rgba(255, 255, 255, 0.03);
}

.orka-table th {
    text-align: left;
    padding: 1rem;
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--border-subtle);
}

.orka-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-secondary);
}

.orka-table tbody tr {
    transition: background var(--transition-fast);
}

.orka-table tbody tr:hover {
    background: var(--bg-glass);
}

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

/* --- ORKA BADGES --- */
.orka-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.orka-badge-success {
    background: var(--success-light);
    color: var(--accent-success);
}

.orka-badge-danger {
    background: var(--danger-light);
    color: var(--accent-danger);
}

.orka-badge-info {
    background: var(--info-light);
    color: var(--accent-info);
}

.orka-badge-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--accent-warning);
}

.orka-badge-neutral {
    background: rgba(148, 163, 184, 0.15);
    color: var(--text-muted);
}

/* --- ALERTS --- */
.orka-alert {
    padding: 1rem 1.25rem;
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.orka-alert-success {
    background: var(--success-light);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: var(--accent-success);
}

.orka-alert-danger {
    background: var(--danger-light);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: var(--accent-danger);
}

.orka-alert-info {
    background: var(--info-light);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: var(--accent-info);
}

/* --- UTILITIES (Tailwind-like) --- */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.w-full { width: 100%; }

/* --- COLOR UTILITIES --- */
.text-primary { color: var(--text-primary) !important; }
.text-secondary { color: var(--text-secondary) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-accent { color: var(--accent-warning) !important; }

/* --- SPACING UTILITIES --- */
.mb-2 { margin-bottom: 0.5rem !important; }
.mb-4 { margin-bottom: 1rem !important; }
.mb-6 { margin-bottom: 1.5rem !important; }
.mb-8 { margin-bottom: 2rem !important; }
.mb-10 { margin-bottom: 2.5rem !important; }
.mb-12 { margin-bottom: 3rem !important; }
.mt-4 { margin-top: 1rem !important; }
.mt-8 { margin-top: 2rem !important; }
.py-4 { padding-top: 1rem !important; padding-bottom: 1rem !important; }
.py-6 { padding-top: 1.5rem !important; padding-bottom: 1.5rem !important; }
.px-6 { padding-left: 1.5rem !important; padding-right: 1.5rem !important; }

/* --- ICON CIRCLES --- */
.orka-icon-circle {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.orka-icon-circle.success {
    background: linear-gradient(135deg, var(--accent-success) 0%, #059669 100%);
}

.orka-icon-circle.danger {
    background: linear-gradient(135deg, var(--accent-danger) 0%, #dc2626 100%);
}

.orka-icon-circle.info {
    background: linear-gradient(135deg, var(--accent-info) 0%, #2563eb 100%);
}

.orka-icon-circle.accent {
    background: linear-gradient(135deg, var(--accent-warning) 0%, #d97706 100%);
}

.orka-icon-circle.purple {
    background: linear-gradient(135deg, var(--accent-purple) 0%, #7c3aed 100%);
}

/* --- SECTION TITLE --- */
.orka-section-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-subtle);
}

/* --- BACK LINK --- */
.orka-back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary); /* Plus clair que muted */
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    transition: all var(--transition-fast);
    text-decoration: none;
}

.orka-back-link:hover {
    color: white;
    transform: translateX(-4px);
}

/* --- EMPTY STATE --- */
.orka-empty {
    text-align: center;
    padding: 3rem;
    color: var(--text-muted);
}

.orka-empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

/* --- GRIDS --- */
.orka-grid {
    display: grid;
    gap: 1.5rem;
}

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

@media (max-width: 1024px) {
    .orka-grid-4, .orka-grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .orka-grid-4, .orka-grid-3, .orka-grid-2 { grid-template-columns: 1fr; }
}

/* --- RADIO/CHECKBOX CARDS --- */
.radio-card-label {
    cursor: pointer;
    display: block;
    position: relative;
}

.radio-card-label input[type="radio"],
.radio-card-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.radio-card-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    color: var(--text-muted);
    font-weight: 500;
    transition: all var(--transition-fast);
}

.radio-card-label:hover .radio-card-content {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--border-light);
    color: var(--text-primary);
}

.radio-card-label input:checked + .radio-card-content {
    background: rgba(245, 158, 11, 0.15);
    border-color: var(--accent-warning);
    color: var(--accent-warning);
    box-shadow: 0 0 0 1px var(--accent-warning);
}

.yes-no-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* --- MOVED FROM ADMIN LIST --- */
.volunteer-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-success) 0%, #059669 100%);
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 1.1rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
}

/* =========================================
   UTILITY CLASSES (Tailwind-style)
   ========================================= */

/* Margin utilities */
.mr-1 { margin-right: 0.25rem !important; }
.mr-2 { margin-right: 0.5rem !important; }
.mr-3 { margin-right: 0.75rem !important; }
.mr-4 { margin-right: 1rem !important; }

.ml-1 { margin-left: 0.25rem !important; }
.ml-2 { margin-left: 0.5rem !important; }
.ml-3 { margin-left: 0.75rem !important; }
.ml-4 { margin-left: 1rem !important; }

.mt-1 { margin-top: 0.25rem !important; }
.mt-2 { margin-top: 0.5rem !important; }
.mt-3 { margin-top: 0.75rem !important; }
.mt-4 { margin-top: 1rem !important; }

.mb-1 { margin-bottom: 0.25rem !important; }
.mb-2 { margin-bottom: 0.5rem !important; }
.mb-3 { margin-bottom: 0.75rem !important; }
.mb-4 { margin-bottom: 1rem !important; }

/* --- PROFILE / BIO LAYOUTS (ORKYA OS) --- */
.bio-grid {
    display: grid;
    grid-template-columns: 300px 1fr 340px;
    gap: 1.5rem;
    align-items: start;
}

@media (max-width: 1280px) {
    .bio-grid { grid-template-columns: 280px 1fr; }
    .bio-col-command { grid-column: 2; grid-row: 1; }
    .bio-col-intel { grid-column: 1 / -1; grid-row: 2; }
}

@media (max-width: 900px) {
    .bio-grid { grid-template-columns: 1fr; }
    .bio-col-command { grid-column: 1; grid-row: 1; margin-bottom: 2rem; }
    .bio-col-identity { grid-column: 1; margin-bottom: 2rem; }
    .bio-col-intel { grid-column: 1; }
}

.sticky-card { position: sticky; top: 2rem; }

.avatar-ring { 
    width: 120px; height: 120px; 
    border-radius: 50%; 
    padding: 4px; 
    border: 1px solid var(--glass-border);
    margin: 0 auto 1.5rem;
    overflow: hidden;
    background: rgba(255,255,255,0.03);
}

.avatar-ring img { 
    width: 100%; height: 100%; 
    object-fit: cover; 
    border-radius: 50%; 
}

.initials { 
    display: flex; align-items: center; justify-content: center; 
    width: 100%; height: 100%; 
    font-size: 2.5rem; 
    color: rgba(255,255,255,0.2); 
    background: rgba(255,255,255,0.05); 
    border-radius: 50%; 
}

.data-item {
    display: flex; justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    font-size: 0.9rem;
}

.data-item:last-child { border-bottom: none; }
.data-item .label { color: var(--text-secondary); }
.data-item .value { color: white; font-weight: 500; }

.availability-grid {
    display: flex; flex-wrap: wrap; gap: 0.5rem;
}

.avail-item {
    display: flex; align-items: center; gap: 0.5rem;
    padding: 0.5rem 0.8rem;
    border-radius: 8px;
    font-size: 0.85rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--glass-border);
}

.avail-true { border-color: rgba(16, 185, 129, 0.3); background: rgba(16, 185, 129, 0.1); }
.avail-false { opacity: 0.5; }
.avail-item .slot-name { color: white; font-weight: 600; }

.dynamic-info-tiny {
    background: rgba(255,255,255,0.03);
    padding: 0.5rem;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.05);
}

.stream-feed .msg-pair {
    border-bottom: 1px solid rgba(255,255,255,0.05);
    padding-bottom: 0.5rem;
}
.stream-feed .msg-pair:last-child { border-bottom: none; }
.msg-system { font-size: 0.7rem; text-transform: uppercase; color: var(--text-muted); font-weight: 700; margin-bottom: 0.25rem; }
.msg-user { background: rgba(255,255,255,0.03); padding: 0.75rem; border-radius: 0 12px 12px 12px; border-left: 2px solid var(--accent-primary); }

.bg-warning-low { background: rgba(245, 158, 11, 0.1); border: 1px solid rgba(245, 158, 11, 0.2); }
.text-accent { color: var(--accent-primary); }
.border-accent { border-color: var(--accent-primary) !important; }

.mb-4 { margin-bottom: 1rem !important; }

/* --- Premium Cheese Form (Console Products) --- */
.cheese-modal {
    position: relative;
    background:
        radial-gradient(1200px 700px at 8% 0%, rgba(99, 102, 241, 0.14), transparent 45%),
        radial-gradient(900px 600px at 92% 12%, rgba(245, 158, 11, 0.12), transparent 40%),
        linear-gradient(160deg, rgba(10, 16, 30, 0.96), rgba(8, 12, 22, 0.95));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 28px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.7), inset 0 0 0 1px rgba(255, 255, 255, 0.03);
    overflow: hidden;
}

.cheese-modal::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px);
    background-size: 28px 28px;
    opacity: 0.14;
    pointer-events: none;
}

.cheese-modal-topbar {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(8, 12, 22, 0.7);
    backdrop-filter: blur(14px);
}

.cheese-modal-title {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.cheese-modal-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.35), rgba(99, 102, 241, 0.05));
    border: 1px solid rgba(99, 102, 241, 0.35);
    color: #c7d2fe;
    box-shadow: 0 0 24px rgba(99, 102, 241, 0.35);
}

.cheese-modal-kicker {
    display: block;
    text-transform: uppercase;
    letter-spacing: 0.24em;
    font-size: 0.65rem;
    font-weight: 800;
    color: rgba(148, 163, 184, 0.9);
}

.cheese-modal-name {
    display: block;
    font-size: 1.15rem;
    font-weight: 800;
    color: white;
}

.cheese-modal-close {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.05);
    color: rgba(226, 232, 240, 0.85);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.cheese-modal-close:hover {
    background: rgba(255, 255, 255, 0.14);
    color: white;
    transform: translateY(-1px);
}

.cheese-modal-body {
    position: relative;
    z-index: 1;
    padding: 1.5rem 1.75rem 1.75rem;
}

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

.cheese-form-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1.25rem 1.5rem;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.cheese-form-title {
    max-width: 560px;
}

.cheese-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(226, 232, 240, 0.9);
    background: rgba(99, 102, 241, 0.2);
    border: 1px solid rgba(99, 102, 241, 0.35);
}

.cheese-title {
    margin: 0.6rem 0 0.35rem;
    font-size: 1.8rem;
    font-weight: 800;
    color: white;
    letter-spacing: -0.02em;
}

.cheese-subtitle {
    margin: 0;
    color: rgba(148, 163, 184, 0.9);
    font-size: 0.95rem;
}

.cheese-form-status {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.cheese-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0.9rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    color: rgba(226, 232, 240, 0.9);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.cheese-pill.ghost {
    background: transparent;
    color: rgba(148, 163, 184, 0.9);
    border: 1px dashed rgba(255, 255, 255, 0.18);
}

.cheese-form-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
    align-items: start;
}

.cheese-panel {
    --panel-accent: #6366f1;
    --panel-glow: rgba(99, 102, 241, 0.25);
    position: relative;
    background: rgba(12, 18, 32, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 1.25rem;
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.35);
    overflow: hidden;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.cheese-panel::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 45%);
    opacity: 0.5;
    pointer-events: none;
}

.cheese-panel > * {
    position: relative;
    z-index: 1;
}

.cheese-panel:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.45);
}

.cheese-panel.accent-indigo {
    --panel-accent: #818cf8;
    --panel-glow: rgba(99, 102, 241, 0.35);
}

.cheese-panel.accent-emerald {
    --panel-accent: #34d399;
    --panel-glow: rgba(16, 185, 129, 0.35);
}

.cheese-panel.accent-cyan {
    --panel-accent: #22d3ee;
    --panel-glow: rgba(6, 182, 212, 0.35);
}

.cheese-panel.accent-amber {
    --panel-accent: #fbbf24;
    --panel-glow: rgba(245, 158, 11, 0.35);
}

.cheese-panel.accent-rose {
    --panel-accent: #fb7185;
    --panel-glow: rgba(244, 63, 94, 0.35);
}

.cheese-panel-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.cheese-panel-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.02));
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--panel-accent);
    box-shadow: 0 0 22px var(--panel-glow);
}

.cheese-panel-title {
    margin: 0;
    font-size: 0.85rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: rgba(226, 232, 240, 0.95);
}

.cheese-panel-subtitle {
    margin: 0.2rem 0 0;
    font-size: 0.75rem;
    color: rgba(148, 163, 184, 0.8);
}

.cheese-panel-body {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.cheese-field {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.cheese-label {
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: rgba(148, 163, 184, 0.9);
}

.cheese-input,
.cheese-select,
.cheese-textarea {
    width: 100%;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(10, 15, 26, 0.7);
    color: #e2e8f0;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.cheese-input::placeholder,
.cheese-textarea::placeholder {
    color: rgba(148, 163, 184, 0.55);
}

.cheese-panel .cheese-input:focus,
.cheese-panel .cheese-select:focus,
.cheese-panel .cheese-textarea:focus {
    outline: none;
    border-color: var(--panel-accent);
    background: rgba(12, 18, 30, 0.9);
    box-shadow: 0 0 0 1px var(--panel-accent), 0 0 24px var(--panel-glow);
}

.cheese-select-wrap {
    position: relative;
}

.cheese-select {
    appearance: none;
    padding-right: 2.4rem;
}

.cheese-select-wrap i {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(148, 163, 184, 0.7);
    pointer-events: none;
    font-size: 0.85rem;
}

.cheese-textarea {
    min-height: 110px;
    resize: vertical;
}

.cheese-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.cheese-toggle-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.cheese-toggle-card {
    position: relative;
    cursor: pointer;
}

.cheese-toggle-input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.cheese-toggle-surface {
    --toggle-accent: #6366f1;
    --toggle-bg: rgba(99, 102, 241, 0.16);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 1rem;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.03);
    color: rgba(148, 163, 184, 0.9);
    min-height: 88px;
    transition: all 0.2s ease;
}

.cheese-toggle-surface i {
    font-size: 1.1rem;
}

.cheese-toggle-input:checked + .cheese-toggle-surface {
    border-color: var(--toggle-accent);
    background: var(--toggle-bg);
    color: white;
    box-shadow: 0 0 0 1px var(--toggle-accent), 0 10px 24px rgba(0, 0, 0, 0.3);
}

.cheese-toggle-input:focus-visible + .cheese-toggle-surface {
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.25);
}

.cheese-dropzone {
    position: relative;
    width: 100%;
    min-height: 220px;
    border-radius: 18px;
    border: 1px dashed rgba(255, 255, 255, 0.18);
    background: rgba(8, 12, 22, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.cheese-dropzone:hover {
    border-color: rgba(251, 113, 133, 0.55);
    box-shadow: 0 0 24px rgba(244, 63, 94, 0.2);
}

.cheese-dropzone-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cheese-dropzone-empty {
    text-align: center;
    color: rgba(148, 163, 184, 0.85);
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    font-size: 0.85rem;
}

.cheese-dropzone-empty i {
    font-size: 2.2rem;
    color: rgba(248, 113, 113, 0.8);
}

.cheese-dropzone-empty span {
    font-size: 0.7rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(148, 163, 184, 0.7);
}

.cheese-dropzone-input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.cheese-actions {
    position: sticky;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.25rem 0 0.25rem;
    background: linear-gradient(180deg, rgba(8, 12, 22, 0) 0%, rgba(8, 12, 22, 0.85) 35%, rgba(8, 12, 22, 0.98) 100%);
    backdrop-filter: blur(12px);
}

.cheese-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.85rem 1.4rem;
    border-radius: 14px;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    border: 1px solid transparent;
    transition: all 0.2s ease;
}

.cheese-btn-ghost {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    color: rgba(226, 232, 240, 0.85);
}

.cheese-btn-ghost:hover {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    transform: translateY(-1px);
}

.cheese-btn-primary {
    background: linear-gradient(135deg, #6366f1 0%, #f59e0b 100%);
    color: white;
    box-shadow: 0 12px 26px rgba(99, 102, 241, 0.35);
}

.cheese-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 32px rgba(245, 158, 11, 0.35);
    filter: brightness(1.08);
}

.cheese-span-2 {
    grid-column: span 2;
}

@media (max-width: 1200px) {
    .cheese-form-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .cheese-span-2 {
        grid-column: span 2;
    }
}

@media (max-width: 900px) {
    .cheese-modal-body {
        padding: 1.25rem;
    }
    .cheese-form-hero {
        flex-direction: column;
        align-items: flex-start;
    }
    .cheese-form-grid {
        grid-template-columns: 1fr;
    }
    .cheese-span-2 {
        grid-column: span 1;
    }
    .cheese-grid-2,
    .cheese-toggle-grid {
        grid-template-columns: 1fr;
    }
    .cheese-actions {
        flex-direction: column;
        align-items: stretch;
    }
    .cheese-btn {
        width: 100%;
    }
}
/* =========================================
   MOBILE FIRST REFACTORING (2026)
   ========================================= */

@media (max-width: 768px) {
    /* --- 1. GLOBAL RESET & TYPOGRAPHY --- */
    html {
        font-size: 16px; /* Ensure readable base size */
    }
    
    body {
        line-height: 1.6; /* Improve readability */
        overflow-x: hidden; /* Prevent horizontal scroll */
        -webkit-font-smoothing: antialiased;
    }

    p {
        font-size: 1.05rem; /* Slightly larger body text */
        margin-bottom: 1.5rem;
        color: rgba(255, 255, 255, 0.8) !important;
    }

    /* --- 2. IMAGES & MEDIA --- */
    img, video, iframe, svg {
        max-width: 100%;
        height: auto;
        display: block;
    }

    /* --- 3. LAYOUT STACKING (FORCE COLUMN) --- */
    .dashboard-grid, 
    .site-nav-container, 
    .footer-grid, 
    .hero-buttons,
    .story-container,
    .catalog-grid,
    .hero-content {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        min-width: 0 !important; /* Fix flex overflow */
        align-items: center !important; /* Center content on mobile */
    }

    /* --- 4. SAFE PADDING --- */
    .dashboard-container, 
    .site-nav-container, 
    .footer-container, 
    .hero-content, 
    .story-container, 
    .catalog-container,
    section {
        padding-left: 24px !important; /* 1.5rem safe zone */
        padding-right: 24px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* Reset margins that might push content */
    * {
        scroll-margin-top: 80px; /* For sticky header */
    }

    /* --- 5. TOUCH TARGETS --- */
    button, a, input, select, textarea, .site-nav-link {
        min-height: 48px; /* Thumb-friendly */
        min-width: 48px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
    
    /* Exceptions for inline text links */
    p a {
        display: inline;
        min-height: auto;
        padding: 0.5rem 0; /* Add vertical padding for hit area */
    }

    /* --- 6. TYPOGRAPHY OVERRIDES --- */
    h1, .hero-title {
        font-size: 2.75rem !important;
        line-height: 1.1 !important;
        word-wrap: break-word; /* Prevent overflow */
        text-align: center;
    }
    
    h2, .story-title, .catalog-title {
        font-size: 2rem !important;
        line-height: 1.2 !important;
        text-align: center;
        margin-bottom: 1.5rem !important;
    }

    .hero-subtitle {
        font-size: 1.1rem !important;
        text-align: center;
        max-width: 100% !important;
    }

    /* --- 7. COMPONENT SPECIFIC FIXES --- */
    
    /* Hero Buttons */
    .hero-buttons {
        gap: 1rem !important;
        width: 100%;
    }
    
    .hero-btn-primary, .hero-btn-secondary {
        width: 100%; /* Full width buttons */
        text-align: center;
        justify-content: center;
        padding: 1rem !important;
    }

    /* Story Section */
    .story-section {
        padding: 4rem 0 !important;
    }
    
    .story-image-wrapper {
        order: -1 !important; /* Image first on mobile */
        width: 100%;
        margin-bottom: 2rem;
    }
    
    .story-image {
        aspect-ratio: 1/1 !important; /* Square for mobile looks better */
        object-fit: cover;
        border-radius: 16px;
    }
    
    /* Catalog */
    .catalog-grid {
        display: grid !important;
        grid-template-columns: 1fr !important; /* Single column */
        gap: 2rem !important;
    }
    
    /* Footer */
    .footer-container {
        padding: 3rem 1.5rem !important;
        text-align: center;
    }
    
    .footer-social {
        justify-content: center;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 1.5rem;
    }
}
