/* Variables et Thème */
:root {
    --bg-color: #0d0d12;
    --bg-color-light: #16161e;
    --text-main: #ffffff;
    --text-muted: #a0a0b0;
    --accent-color: #ff007f; /* Magenta du logo */
    --accent-glow: rgba(255, 0, 127, 0.4);
    --accent-hover: #ff3399;
    --border-color: rgba(255, 255, 255, 0.1);
    --glass-bg: rgba(22, 22, 30, 0.6);
    --glass-border: rgba(255, 255, 255, 0.05);
}

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

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(-45deg, #0d0d12, #1a0b1c, #0a1128, #0d0d12);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

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

.hidden {
    display: none !important;
}

/* Glassmorphism utils */
.glass-panel, .glass-card {
    background: rgba(22, 22, 30, 0.4);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(255, 0, 127, 0.15);
    border-color: rgba(255, 0, 127, 0.3);
}

.p-2 { padding: 1.5rem; }
.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }
.text-muted { color: var(--text-muted); }

/* Boutons */
.btn {
    padding: 0.6rem 1.2rem;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-size: 0.9rem;
    font-family: 'Inter', sans-serif;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn-accent {
    background-color: var(--accent-color);
    color: white;
    box-shadow: 0 4px 15px var(--accent-glow);
}

.btn-accent:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--accent-glow);
}

.btn-outline {
    background-color: transparent;
    color: var(--text-main);
    border: 1px solid var(--border-color);
}

.btn-outline:hover {
    background-color: rgba(255,255,255,0.05);
    border-color: var(--text-main);
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    background: rgba(13, 13, 18, 0.8);
    backdrop-filter: blur(15px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 800;
}

.nav-brand .logo {
    height: 40px;
    filter: drop-shadow(0 0 8px var(--accent-glow));
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--text-main);
}

#user-profile {
    display: flex;
    align-items: center;
    gap: 15px;
}

.badge {
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: bold;
    text-transform: uppercase;
}

.badge-accent {
    background: rgba(255, 0, 127, 0.2);
    color: var(--accent-color);
    border: 1px solid var(--accent-color);
}

/* Hero Section */
.hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 80vh;
    padding: 0 5%;
    position: relative;
    overflow: hidden;
}

.hero-content {
    max-width: 600px;
    z-index: 2;
}

.hero h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.hero-graphic {
    position: relative;
    z-index: 1;
    width: 400px;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.glow-circle {
    position: absolute;
    width: 300px;
    height: 300px;
    background: var(--accent-color);
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.4;
    animation: pulse 4s infinite alternate;
}

.floating-logo {
    width: 250px;
    position: relative;
    z-index: 2;
    animation: float 6s ease-in-out infinite;
    filter: drop-shadow(0 10px 30px var(--accent-glow));
}

/* Animations d'entrée */
.fade-in-up {
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
    transform: translateY(30px);
}
.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }
.delay-3 { animation-delay: 0.6s; }

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

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.3; }
    100% { transform: scale(1.2); opacity: 0.5; }
}

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

/* Dashboard / Gestion */
.gestion-body {
    background-color: var(--bg-color-light);
}

.auth-guard {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 80vh;
}

.loader {
    width: 50px;
    height: 50px;
    border: 3px solid var(--border-color);
    border-top-color: var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

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

.dashboard-container {
    display: flex;
    min-height: calc(100vh - 73px);
}

.sidebar {
    width: 250px;
    padding: 2rem 0;
    border-right: 1px solid var(--border-color);
    border-radius: 0;
}

.sidebar-menu {
    list-style: none;
}

.sidebar-menu li {
    padding: 1rem 2rem;
    cursor: pointer;
    transition: all 0.2s;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-menu li:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
}

.sidebar-menu li.active {
    background: rgba(255, 0, 127, 0.1);
    color: var(--accent-color);
    border-right: 3px solid var(--accent-color);
}

.dashboard-main {
    flex: 1;
    padding: 2rem;
}

.header-action {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

/* Forms */
.input-modern {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(0,0,0,0.2);
    border: 1px solid var(--border-color);
    color: white;
    border-radius: 8px;
    font-family: inherit;
    margin-top: 0.5rem;
}

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

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

.admin-form {
    max-width: 400px;
}

.msg {
    padding: 10px;
    border-radius: 6px;
    font-size: 0.9rem;
    display: none;
}

.msg.success { display: block; background: rgba(0, 255, 100, 0.1); color: #00ff64; border: 1px solid #00ff64; }
.msg.error { display: block; background: rgba(255, 0, 0, 0.1); color: #ff3333; border: 1px solid #ff3333; }

/* Responsive */
@media (max-width: 768px) {
    .hero { flex-direction: column; text-align: center; justify-content: center; padding-top: 2rem; }
    .hero h1 { font-size: 2.5rem; }
    .dashboard-container { flex-direction: column; }
    .sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--border-color); display: flex; padding: 0; }
    .sidebar-menu { display: flex; width: 100%; }
    .sidebar-menu li { flex: 1; justify-content: center; border-right: none !important; border-bottom: 3px solid transparent; }
    .sidebar-menu li.active { border-bottom-color: var(--accent-color); }
}

/* Footer */
.footer {
    background: var(--bg-color-light);
    padding: 3rem 5% 1rem;
    border-top: 1px solid var(--border-color);
    margin-top: 4rem;
}
.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2rem;
}
.footer-brand h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}
.footer-logo {
    height: 50px;
    margin-bottom: 1rem;
    filter: drop-shadow(0 0 5px var(--accent-glow));
}
.footer-links h4 {
    margin-bottom: 1rem;
    color: var(--text-main);
}
.social-icons {
    display: flex;
    gap: 1rem;
}
.social-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 1.2rem;
    transition: all 0.3s;
    border: 1px solid var(--border-color);
}
.social-icon:hover {
    background: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px var(--accent-glow);
}
.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.05);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Nouvelles classes V2 (Intranet & Premium) */
.event-card-premium {
    background: rgba(22, 22, 30, 0.5);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    overflow: hidden;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
    margin-bottom: 2rem;
    position: relative;
}

.event-card-premium:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 15px 45px rgba(255, 0, 127, 0.2);
    border-color: rgba(255, 0, 127, 0.4);
}

.event-banner {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 2px solid var(--accent-color);
}

.event-content {
    padding: 1.5rem;
}

.status-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: 800;
    font-size: 0.8rem;
    text-transform: uppercase;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

.status-avenir {
    background: rgba(0, 200, 255, 0.2);
    color: #00c8ff;
    border: 1px solid #00c8ff;
}

.status-termine {
    background: rgba(0, 255, 100, 0.2);
    color: #00ff64;
    border: 1px solid #00ff64;
}

.staff-notes {
    margin-top: 1rem;
    padding: 1rem;
    background: rgba(255, 170, 0, 0.1);
    border-left: 4px solid #ffaa00;
    border-radius: 4px;
    color: #ffaa00;
    font-size: 0.9rem;
}

/* Calendrier Basique */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.calendar-day {
    background: rgba(0,0,0,0.3);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1rem;
    text-align: center;
}

.calendar-day h4 {
    color: var(--accent-color);
    margin-bottom: 10px;
    font-size: 1.2rem;
}
