:root {
            --primary-color: #7b2657;
            --secondary-color: #9b1b51;
            --accent-color: #b31a47;
            --text-color: #2c3e50;
            --light-text: #7f8c8d;
            --bg-color: #ffffff;
            --white: #ffffff;
            --bg-secondary: #ecf0f1;
            --border-color: #bdc3c7;
            --success-color: #27ae60;
            --error-color: #e74c3c;
            --warning-color: #f39c12;
            --shadow: 0 2px 10px rgba(0,0,0,0.1);
            --gradient: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            line-height: 1.6;
            color: var(--text-color);
            background-color: var(--bg-color);
        }

        .container {
            max-width: 1200px;
            margin: 0 auto;
            padding: 0 20px;
        }

        /* Header */
        header {
            background: var(--gradient);
            color: white;
            padding: 1rem 0;
            box-shadow: var(--shadow);
            position: sticky;
            top: 0;
            z-index: 100;
        }

        .header-content {
            display: flex;
            justify-content: space-between;
            align-items: center;
            flex-wrap: wrap;
            gap: 1rem;
        }

        .logo {
            font-size: 1.8rem;
            font-weight: bold;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        .logo-img {
            height: 60px;
            margin-right: 10px;
        }

        .logo::before {
            content: "";
            font-size: 1.5rem;
        }

        nav ul {
            list-style: none;
            display: flex;
            gap: 2rem;
            align-items: center;
        }

        nav a {
            color: white;
            text-decoration: none;
            font-weight: 500;
            transition: all 0.3s ease;
            padding: 0.5rem 1rem;
            border-radius: 5px;
        }

        nav a:hover {
            background: rgba(255,255,255,0.2);
            transform: translateY(-2px);
        }

        .logout-btn, .login-btn, .register-btn {
            background: var(--accent-color);
            color: white;
            border: none;
            padding: 0.7rem 1.5rem;
            border-radius: 25px;
            cursor: pointer;
            font-weight: bold;
            transition: all 0.3s ease;
        }

        .logout-btn:hover, .login-btn:hover, .register-btn:hover {
            background: #c01f39;
            transform: translateY(-2px);
        }

        /* Hero Section */
        .hero {
            background: linear-gradient(#9b1b51, #b31a47), 
                        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><rect fill="%23ecf0f1" width="1200" height="600"/><circle fill="%23e74c3c" opacity="0.1" cx="200" cy="150" r="80"/><circle fill="%23f39c12" opacity="0.1" cx="800" cy="300" r="120"/><circle fill="%23e74c3c" opacity="0.1" cx="1000" cy="100" r="60"/></svg>');
            background-size: cover;
            color: white;
            text-align: center;
            padding: 4rem 0;
        }

        .hero h1 {
            font-size: 3rem;
            margin-bottom: 1rem;
            text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
        }

        .hero p {
            font-size: 1.3rem;
            margin-bottom: 2rem;
            text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
        }

        .logo i {
            font-size: 2rem;
            color: #f39c12;
            animation: pulse 2s infinite;
        }

        @keyframes pulse {
            0%, 100% { transform: scale(1); }
            50% { transform: scale(1.1); }
        }

        .news-section h2 i,
        .widget h3 i {
            color: #f39c12;
            margin-right: 0.5rem;
        }

        .news-category i {
            margin-right: 0.3rem;
        }

        .news-meta i {
            color: #7f8c8d;
            margin-right: 0.3rem;
        }

        .cta-button {
            background: var(--accent-color);
            color: white;
            padding: 1rem 2rem;
            border: none;
            border-radius: 30px;
            font-size: 1.1rem;
            font-weight: bold;
            cursor: pointer;
            transition: all 0.3s ease;
            text-decoration: none;
            display: inline-block;
        }

        .cta-button:hover {
            background: #c01f39;
            transform: translateY(-3px);
            box-shadow: 0 5px 15px rgba(0,0,0,0.2);
        }

        /* Main Content */
        main {
            padding: 3rem 0;
            background: var(--bg-secondary);
        }

        .content-grid {
            display: grid;
            grid-template-columns: 2fr 1fr;
            gap: 3rem;
        }

        /* News Section */
        .news-section h2 {
            color: var(--primary-color);
            font-size: 2.2rem;
            margin-bottom: 2rem;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        .news-grid {
            display: grid;
            gap: 2rem;
        }

        .news-card {
            background: var(--bg-color);
            border-radius: 15px;
            padding: 2rem;
            box-shadow: var(--shadow);
            transition: all 0.3s ease;
            border-left: 4px solid var(--primary-color);
        }

        .news-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 5px 20px rgba(0,0,0,0.15);
        }

        .news-meta {
            color: var(--light-text);
            font-size: 0.9rem;
            margin-bottom: 1rem;
            display: flex;
            gap: 1rem;
            align-items: center;
        }

        .news-category {
            background: var(--primary-color);
            color: white;
            padding: 0.2rem 0.8rem;
            border-radius: 20px;
            font-size: 0.8rem;
            font-weight: bold;
        }

        .news-card h3 {
            color: var(--text-color);
            font-size: 1.4rem;
            margin-bottom: 1rem;
        }

        .news-card p {
            color: var(--light-text);
            margin-bottom: 1rem;
        }

        .read-more {
            color: var(--primary-color);
            text-decoration: none;
            font-weight: bold;
            transition: color 0.3s ease;
        }

        .read-more:hover {
            color: var(--secondary-color);
        }

        /* Sidebar */
        .sidebar {
            display: flex;
            flex-direction: column;
            gap: 2rem;
        }

        .widget {
            background: var(--bg-color);
            border-radius: 15px;
            padding: 2rem;
            box-shadow: var(--shadow);
        }

        .widget h3 {
            color: var(--primary-color);
            margin-bottom: 1.5rem;
            font-size: 1.3rem;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        .quick-actions .action-btn {
            display: block;
            width: 100%;
            background: var(--gradient);
            color: white;
            padding: 1rem;
            border: none;
            border-radius: 10px;
            margin-bottom: 1rem;
            cursor: pointer;
            font-weight: bold;
            transition: all 0.3s ease;
            text-decoration: none;
            text-align: center;
        }

        .action-btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(0,0,0,0.2);
        }

        .upcoming-events .event {
            padding: 1rem;
            border-left: 3px solid var(--accent-color);
            margin-bottom: 1rem;
            background: var(--bg-secondary);
            border-radius: 0 8px 8px 0;
        }

        .event-date {
            color: var(--primary-color);
            font-weight: bold;
            font-size: 0.9rem;
        }

        /* ===============================
           MODAUX AMÉLIORÉES - RESPONSIVE
        =============================== */

        .modal {
            display: none;
            position: fixed;
            z-index: 2000;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0,0,0,0.6);
            backdrop-filter: blur(5px);
            animation: fadeIn 0.3s ease;
        }

        .modal.show {
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .modal-content {
            background-color: var(--white);
            margin: auto;
            border-radius: 20px;
            width: 95%;
            max-width: 500px;
            max-height: 95vh;
            overflow: hidden;
            box-shadow: 0 20px 60px rgba(0,0,0,0.3);
            transform: scale(0.7);
            animation: modalSlideIn 0.3s ease forwards;
            position: relative;
        }

        @keyframes modalSlideIn {
            to {
                transform: scale(1);
            }
        }

        .modal-header {
            background: var(--gradient);
            color: var(--white);
            padding: 2rem;
            border-radius: 20px 20px 0 0;
            display: flex;
            justify-content: space-between;
            align-items: center;
            position: relative;
            overflow: hidden;
        }

        .modal-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%);
            border-radius: 50%;
        }

        .modal-header h3 {
            font-size: 1.5rem;
            font-weight: bold;
            margin: 0;
            position: relative;
            z-index: 1;
        }

        .close {
            color: rgba(255,255,255,0.8);
            font-size: 28px;
            font-weight: bold;
            cursor: pointer;
            transition: all 0.3s ease;
            padding: 0.5rem;
            border-radius: 50%;
            width: 45px;
            height: 45px;
            display: flex;
            align-items: center;
            justify-content: center;
            position: relative;
            z-index: 1;
        }

        .close:hover {
            color: var(--white);
            background: rgba(255,255,255,0.2);
            transform: rotate(90deg) scale(1.1);
        }

        .form-container {
            padding: 2.5rem;
            max-height: calc(95vh - 120px);
            overflow-y: auto;
        }

        .form-container::-webkit-scrollbar {
            width: 6px;
        }

        .form-container::-webkit-scrollbar-track {
            background: var(--bg-secondary);
            border-radius: 10px;
        }

        .form-container::-webkit-scrollbar-thumb {
            background: var(--primary-color);
            border-radius: 10px;
        }

        .form-group {
            margin-bottom: 1.5rem;
            position: relative;
        }

        .form-group label {
            display: block;
            margin-bottom: 0.5rem;
            color: var(--text-color);
            font-weight: 600;
            font-size: 0.95rem;
        }

        .form-group input, 
        .form-group select {
            width: 100%;
            padding: 1rem;
            border: 2px solid var(--border-color);
            border-radius: 12px;
            font-size: 1rem;
            transition: all 0.3s ease;
            background: var(--bg-color);
            font-family: inherit;
        }

        .form-group input:focus, 
        .form-group select:focus {
            outline: none;
            border-color: var(--primary-color);
            box-shadow: 0 0 0 3px rgba(123, 38, 87, 0.1);
            transform: translateY(-2px);
        }

        .form-group input::placeholder {
            color: var(--light-text);
            opacity: 0.8;
        }

        .checkbox-group {
            display: flex;
            align-items: flex-start;
            gap: 0.75rem;
            margin-bottom: 1.5rem;
        }

        .checkbox-group input[type="checkbox"] {
            width: 20px;
            height: 20px;
            min-width: 20px;
            accent-color: var(--primary-color);
            cursor: pointer;
            margin-top: 2px;
        }

        .checkbox-group label {
            margin: 0;
            cursor: pointer;
            line-height: 1.4;
            font-size: 0.9rem;
        }

        .submit-btn {
            width: 100%;
            background: var(--gradient);
            color: white;
            padding: 1.2rem;
            border: none;
            border-radius: 12px;
            font-size: 1.1rem;
            font-weight: bold;
            cursor: pointer;
            transition: all 0.3s ease;
            position: relative;
            overflow: hidden;
        }

        .submit-btn::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
            transition: left 0.5s;
        }

        .submit-btn:hover::before {
            left: 100%;
        }

        .submit-btn:hover {
            transform: translateY(-3px);
            box-shadow: 0 8px 25px rgba(123, 38, 87, 0.3);
        }

        .submit-btn:active {
            transform: translateY(-1px);
        }

        .form-switch {
            text-align: center;
            margin-top: 1.5rem;
            padding-top: 1.5rem;
            border-top: 1px solid var(--border-color);
        }

        .form-switch p {
            color: var(--light-text);
            margin: 0;
        }

        .form-switch a {
            color: var(--primary-color);
            text-decoration: none;
            font-weight: bold;
            transition: color 0.3s ease;
        }

        .form-switch a:hover {
            color: var(--secondary-color);
            text-decoration: underline;
        }

        /* Alerts améliorées */
        .alert {
            padding: 1rem 1.2rem;
            margin-bottom: 1.5rem;
            border-radius: 10px;
            display: none;
            border-left: 4px solid;
            font-weight: 500;
            animation: slideDown 0.3s ease;
        }

        @keyframes slideDown {
            from {
                opacity: 0;
                transform: translateY(-10px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .alert.success {
            background-color: #d1f2eb;
            border-left-color: var(--success-color);
            color: #0d7f56;
        }

        .alert.error {
            background-color: #fadbd8;
            border-left-color: var(--error-color);
            color: #a93226;
        }

        .password-strength {
            margin-top: 0.5rem;
            font-size: 0.85rem;
            font-weight: 500;
        }

        .strength-weak { 
            color: var(--error-color); 
        }
        
        .strength-medium { 
            color: var(--warning-color); 
        }
        
        .strength-strong { 
            color: var(--success-color); 
        }

        /* Footer */
        footer {
            background: var(--text-color);
            color: white;
            text-align: center;
            padding: 2rem 0;
        }

        .footer-content {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
            gap: 2rem;
            margin-bottom: 2rem;
        }

        .footer-section h4 {
            color: var(--accent-color);
            margin-bottom: 1rem;
        }

        .footer-section a {
            color: white;
            text-decoration: none;
            display: block;
            margin-bottom: 0.5rem;
            transition: color 0.3s ease;
        }

        .footer-section a:hover {
            color: var(--accent-color);
        }

        /* Animations */
        @keyframes fadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }

        /* User indicator */
        .user-info {
            display: none;
            align-items: center;
            gap: 1rem;
            color: white;
        }

        .user-info.active {
            display: flex;
        }

        .logout-btn {
            background: transparent;
            color: white;
            border: 1px solid white;
            padding: 0.5rem 1rem;
            border-radius: 20px;
            cursor: pointer;
            font-size: 0.9rem;
            transition: all 0.3s ease;
        }

        .logout-btn:hover {
            background: white;
            color: var(--primary-color);
        }
        

        /* ===============================
           RESPONSIVE DESIGN
        =============================== */

        /* Tablettes */
        @media (max-width: 1024px) {
            .content-grid {
                grid-template-columns: 1fr;
                gap: 2rem;
            }
            
            .modal-content {
                width: 90%;
                max-width: 450px;
            }
            
            .form-container {
                padding: 2rem;
            }
        }

        /* Smartphones et petites tablettes */
        @media (max-width: 768px) {
            .header-content {
                flex-direction: column;
                text-align: center;
                gap: 1rem;
            }

            nav ul {
                flex-wrap: wrap;
                justify-content: center;
                gap: 1rem;
            }

            .hero h1 {
                font-size: 2rem;
            }

            .hero p {
                font-size: 1.1rem;
            }

            .modal-content {
                width: 95%;
                max-width: 420px;
                margin: 10px;
            }

            .modal-header {
                padding: 1.5rem;
            }

            .modal-header h3 {
                font-size: 1.3rem;
            }

            .form-container {
                padding: 1.5rem;
            }

            .form-group input, 
            .form-group select {
                padding: 0.9rem;
            }

            .submit-btn {
                padding: 1rem;
            }

            .footer-content {
                grid-template-columns: 1fr;
                text-align: left;
            }

            .logo {
                font-size: 1.5rem;
            }

            .logo-img {
                height: 50px;
            }

            .news-card {
                padding: 1.5rem;
            }

            .widget {
                padding: 1.5rem;
            }
        }

        /* Petits smartphones */
        @media (max-width: 480px) {
            .container {
                padding: 0 15px;
            }

            .hero {
                padding: 2rem 0;
            }

            .hero h1 {
                font-size: 1.7rem;
            }

            .hero p {
                font-size: 1rem;
            }

            .modal-content {
                width: 98%;
                margin: 5px;
                border-radius: 15px;
            }

            .modal-header {
                padding: 1.2rem;
                border-radius: 15px 15px 0 0;
            }

            .modal-header h3 {
                font-size: 1.2rem;
            }

            .close {
                font-size: 24px;
                width: 40px;
                height: 40px;
            }

            .form-container {
                padding: 1.2rem;
            }

            .form-group {
                margin-bottom: 1.2rem;
            }

            .form-group input, 
            .form-group select {
                padding: 0.8rem;
                font-size: 0.95rem;
            }

            .checkbox-group {
                gap: 0.6rem;
            }

            .checkbox-group label {
                font-size: 0.85rem;
            }

            .submit-btn {
                padding: 0.9rem;
                font-size: 1rem;
            }

            nav ul {
                gap: 0.5rem;
            }

            nav a {
                padding: 0.4rem 0.8rem;
                font-size: 0.9rem;
            }

            .login-btn, .register-btn {
                padding: 0.5rem 1rem;
                font-size: 0.9rem;
            }

            .news-card {
                padding: 1.2rem;
            }

            .news-card h3 {
                font-size: 1.2rem;
            }

            .widget {
                padding: 1.2rem;
            }

            .action-btn {
                padding: 0.8rem;
                font-size: 0.9rem;
            }
        }

        /* Mode paysage sur mobile */
        @media (max-height: 600px) and (orientation: landscape) {
            .modal-content {
                max-height: 98vh;
            }

            .modal-header {
                padding: 1rem 1.5rem;
            }

            .form-container {
                padding: 1rem 1.5rem;
                max-height: calc(98vh - 80px);
            }

            .form-group {
                margin-bottom: 1rem;
            }

            .form-group input, 
            .form-group select {
                padding: 0.7rem;
            }
        }

        /* Très grands écrans */
        @media (min-width: 1400px) {
            .container {
                max-width: 1400px;
            }

            .modal-content {
                max-width: 550px;
            }

            .form-container {
                padding: 3rem;
            }
        }