/* ==================== COMMON STYLES FOR ALL PAGES ==================== */

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

:root {
    --primary: #5865F2;
    --primary-dark: #4752C4;
    --primary-light: #7289DA;
    --success: #57F287;
    --danger: #ED4245;
    --warning: #FEE75C;
    --info: #3B82F6;
    --bg-dark: #0D0D12;
    --bg-card: #1A1A23;
    --bg-light: #23232E;
    --text-primary: #FFFFFF;
    --text-secondary: #B5BAC1;
    --text-muted: #80848E;
    --border: rgba(88, 101, 242, 0.15);
    --shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 12px 24px rgba(0, 0, 0, 0.4);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ==================== NAVIGATION ==================== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(13, 13, 18, 0.9);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    padding: 16px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    border-bottom: 1px solid var(--border);
    transition: var(--transition);
}

.navbar.scrolled {
    box-shadow: var(--shadow);
}

.navbar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 22px;
    font-weight: 700;
    text-decoration: none;
    color: var(--text-primary);
    transition: transform 0.3s ease;
}

.navbar-logo:hover {
    transform: scale(1.05);
}

.navbar-logo i {
    color: var(--primary);
    font-size: 28px;
    filter: drop-shadow(0 0 10px rgba(88, 101, 242, 0.5));
}

.navbar-links {
    display: flex;
    gap: 32px;
    align-items: center;
}

.navbar-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    transition: var(--transition);
    position: relative;
}

.navbar-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.navbar-links a:hover {
    color: var(--text-primary);
}

.navbar-links a:hover::after {
    width: 100%;
}

.navbar-btn {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    padding: 11px 24px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 12px rgba(88, 101, 242, 0.3);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.navbar-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(88, 101, 242, 0.5);
}

/* ==================== SECTIONS ==================== */
.section {
    padding: 100px 5% 80px;
    max-width: 1400px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    font-size: clamp(32px, 6vw, 48px);
    font-weight: 800;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #fff, #b8c1ec);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.02em;
}

.section-subtitle {
    text-align: center;
    font-size: clamp(16px, 2.5vw, 18px);
    color: var(--text-muted);
    margin-bottom: 48px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ==================== CARDS ==================== */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(88, 101, 242, 0.3);
    border-color: rgba(88, 101, 242, 0.4);
}

.card-title {
    font-size: 21px;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.card-description {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.7;
}

/* ==================== BUTTONS ==================== */
.btn {
    padding: 13px 28px;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    box-shadow: 0 6px 20px rgba(88, 101, 242, 0.35);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(88, 101, 242, 0.5);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--primary);
}

.btn-secondary:hover {
    background: rgba(88, 101, 242, 0.1);
    transform: translateY(-3px);
}

.btn-success {
    background: linear-gradient(135deg, var(--success), #3BA55D);
    color: white;
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger), #C13333);
    color: white;
}

/* ==================== BADGES ==================== */
.badge {
    display: inline-block !important;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    /* Forcer l'affichage sur tous les appareils */
    visibility: visible !important;
    opacity: 1 !important;
    /* Forcer le rendu GPU */
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    will-change: transform;
}

.badge-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-light)) !important;
    color: white !important;
}

.badge-success {
    background: linear-gradient(135deg, var(--success), #3BA55D) !important;
    color: white !important;
}

.badge-danger {
    background: linear-gradient(135deg, var(--danger), #C13333) !important;
    color: white !important;
}

.badge-warning {
    background: linear-gradient(135deg, var(--warning), #F59E0B) !important;
    color: var(--bg-dark) !important;
}

/* ==================== GRID LAYOUTS ==================== */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

/* ==================== FOOTER ==================== */
footer {
    text-align: center;
    padding: 40px 5%;
    background: var(--bg-card);
    border-top: 1px solid var(--border);
    margin-top: 60px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.footer-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

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

.footer-links a:hover::after {
    width: 100%;
}

.footer-social {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 24px;
}

.footer-social a {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--text-secondary);
    font-size: 20px;
    transition: var(--transition);
    background: rgba(88, 101, 242, 0.05);
    border: 1px solid transparent;
}

.footer-social a:hover {
    color: var(--primary);
    background: rgba(88, 101, 242, 0.15);
    border-color: rgba(88, 101, 242, 0.3);
    transform: translateY(-4px);
}

.footer-copyright {
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.8;
}

.footer-copyright a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

/* ==================== ANIMATIONS ==================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.9;
        transform: scale(1.02);
    }
}

/* ==================== UTILITIES ==================== */
.text-center {
    text-align: center;
}

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

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

.mb-1 {
    margin-bottom: 0.5rem;
}

.mb-2 {
    margin-bottom: 1rem;
}

.mb-3 {
    margin-bottom: 1.5rem;
}

.mb-4 {
    margin-bottom: 2rem;
}

.mt-1 {
    margin-top: 0.5rem;
}

.mt-2 {
    margin-top: 1rem;
}

.mt-3 {
    margin-top: 1.5rem;
}

.mt-4 {
    margin-top: 2rem;
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 1024px) {
    .navbar-links {
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 14px 20px;
    }

    .navbar-links {
        display: none;
    }

    .section {
        padding: 80px 20px 60px;
    }

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }

    .footer-links {
        gap: 20px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .navbar-btn {
        padding: 9px 18px;
        font-size: 13px;
    }

    .btn {
        padding: 11px 20px;
        font-size: 14px;
        width: 100%;
        justify-content: center;
    }

    .card {
        padding: 24px;
    }
}

/* ==================== SCROLLBAR ==================== */
::-webkit-scrollbar {
    width: 12px;
}

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

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 6px;
}

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

/* ==================== SELECTION ==================== */
::selection {
    background: var(--primary);
    color: white;
}

::-moz-selection {
    background: var(--primary);
    color: white;
}
