/* global.css - Styles communs à toutes les pages */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    background: #001529 url('images/cloud-it-background.png') center center fixed;
    background-size: cover;
    background-attachment: fixed;
    overflow-x: hidden;
    min-height: 100vh;
    position: relative;
    width: 100%;
}

body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 21, 41, 0.3);
    pointer-events: none;
    z-index: 1;
}

body::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 30%, rgba(0, 48, 87, 0.4) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(26, 84, 144, 0.3) 0%, transparent 50%);
    pointer-events: none;
    z-index: 1;
}

.container {
    position: relative;
    z-index: 2;
    max-width: 1920px;
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header commun - Version compacte */
.header {
    background: rgba(0, 48, 87, 0.85);
    backdrop-filter: blur(10px);
    border-bottom: 3px solid rgba(74, 144, 200, 0.6);
    padding: 10px 30px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    flex-shrink: 0;
    box-shadow: 0 2px 20px rgba(0, 48, 87, 0.5);
    z-index: 100;
    position: sticky;
    top: 0;
}

.header-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.header-top {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    width: 100%;
    gap: 10px;
    position: relative;
}

/* Logo Cloud - Version compacte */
.cloud-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    width: clamp(100px, 12vw, 140px);
    height: clamp(60px, 8vw, 80px);
    padding: 5px;
    cursor: pointer;
    text-decoration: none;
    justify-self: start;
}

.cloud-particles {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-cloud {
    width: 85px;
    height: 34px;
    background: linear-gradient(135deg, #003057, #4a90c8);
    border-radius: 17px;
    position: relative;
    z-index: 2;
    box-shadow: 0 4px 16px rgba(0, 48, 87, 0.4);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 6px;
}

.main-cloud::before,
.main-cloud::after {
    content: '';
    position: absolute;
    background: inherit;
    border-radius: 50%;
}

.main-cloud::before {
    width: 24px;
    height: 24px;
    top: -11px;
    left: 50%;
    margin-left: -15px;
    z-index: 1;
}

.main-cloud::after {
    width: 18px;
    height: 18px;
    top: -8px;
    left: 50%;
    margin-left: -2px;
    z-index: 2;
}

.cloud-text {
    color: white;
    font-weight: 700;
    font-size: clamp(0.75em, 1.3vw, 0.95em);
    letter-spacing: 0.5px;
    text-align: center;
    z-index: 3;
    position: relative;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.particle {
    position: absolute;
    background: #1a5490;
    border-radius: 50%;
    opacity: 0.6;
    animation: float 3s ease-in-out infinite;
}

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

.particle1 { width: 5px; height: 5px; top: 50%; left: 4px; margin-top: -12px; animation-delay: 0s; }
.particle2 { width: 6px; height: 6px; top: 50%; left: 8px; margin-top: 4px; animation-delay: 0.5s; }
.particle3 { width: 4px; height: 4px; top: 50%; left: 6px; margin-top: 12px; animation-delay: 1s; }
.particle4 { width: 5px; height: 5px; top: 50%; right: 4px; margin-top: -10px; animation-delay: 1.5s; }
.particle5 { width: 3px; height: 3px; top: 50%; right: 8px; margin-top: 6px; animation-delay: 2s; }
.particle6 { width: 4px; height: 4px; top: 50%; right: 6px; margin-top: 14px; animation-delay: 2.5s; }

.header-slogan {
    font-size: clamp(1.2em, 2.5vw, 1.6em);
    font-style: italic;
    font-weight: 600;
    position: relative;
    justify-self: center;
    text-align: center;
    white-space: nowrap;
}

/* Navigation - Version compacte */
.nav-menu {
    display: flex;
    gap: 15px;
    margin-top: 3px;
}

.nav-menu a {
    color: #e8f4ff;
    text-decoration: none;
    font-size: 0.85em;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 4px;
    transition: all 0.3s ease;
    cursor: pointer;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.nav-menu a:hover {
    background: rgba(74, 144, 200, 0.3);
    transform: translateY(-2px);
}

.nav-menu a.active {
    background: rgba(74, 144, 200, 0.5);
    border-bottom: 2px solid #4a90c8;
}

/* Sélecteur de langue et bouton contact - En haut à droite de la première ligne */
.language-selector {
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 5px;
}

.lang-select {
    background: rgba(255, 255, 255, 0.15);
    color: #e8f4ff;
    border: 2px solid rgba(74, 144, 200, 0.6);
    padding: 8px 10px;
    cursor: pointer;
    font-size: 0.9em;
    font-weight: 600;
    border-radius: 4px;
    transition: all 0.3s ease;
    min-width: 60px;
    backdrop-filter: blur(5px);
}

.lang-select:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: #4a90c8;
}

.lang-select:focus {
    outline: none;
    border-color: #4a90c8;
    box-shadow: 0 0 0 2px rgba(74, 144, 200, 0.3);
}

.lang-select option {
    background: #003057;
    color: white;
}

/* Contenu principal */
.content {
    flex: 1;
    padding: 30px 50px;
    overflow-y: auto;
}

/* Typographie */
h1, h2 {
    color: #e8f4ff;
    margin-bottom: 25px;
    border-bottom: 2px solid rgba(74, 144, 200, 0.6);
    padding-bottom: 12px;
    font-weight: 600;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
}

h1 {
    font-size: clamp(2em, 4.5vw, 2.8em);
}

h2 {
    font-size: clamp(1.8em, 4vw, 2.4em);
}

h3 {
    color: #4a90c8;
    font-size: clamp(1.2em, 2.5vw, 1.5em);
    margin-top: 20px;
    margin-bottom: 12px;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.6);
}

h4 {
    font-size: clamp(1em, 1.8vw, 1.1em);
    color: #e8f4ff;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

p {
    color: #e8f4ff;
    line-height: 1.7;
    font-size: clamp(0.95em, 1.5vw, 1.05em);
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

/* Listes */
ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

ul li {
    padding: 5px 0;
    padding-left: 22px;
    position: relative;
    color: #d8e8f5;
    font-size: clamp(0.85em, 1.4vw, 0.95em);
    line-height: 1.5;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

ul li:before {
    content: "•";
    position: absolute;
    left: 5px;
    color: #4a90c8;
    font-weight: bold;
}

/* Boutons - ORDRE IMPORTANT : .btn d'abord, .btn-contact après */
.btn {
    background: #2a6aa0;
    color: white;
    border: none;
    padding: 12px 24px;
    cursor: pointer;
    font-size: 0.95em;
    font-weight: 500;
    transition: all 0.3s ease;
    border-radius: 4px;
    text-decoration: none;
    display: inline-block;
}

.btn:hover {
    background: #3a7ab5;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(42, 106, 160, 0.3);
}

/* BOUTON CONTACT - DOIT VENIR APRÈS .btn POUR SURCHARGER */
.btn-contact {
    background: linear-gradient(135deg, #d4a34a, #b8892e) !important;
    color: white !important;
    border: none;
    padding: 8px 20px;
    cursor: pointer;
    font-size: 0.8em;
    font-weight: 600;
    border-radius: 4px;
    transition: all 0.3s ease;
    white-space: nowrap;
    animation: slowBlink 3s ease-in-out infinite;
    box-shadow: 0 0 10px rgba(212, 163, 74, 0.5);
}

@keyframes slowBlink {
    0%, 100% { 
        opacity: 1; 
        box-shadow: 0 0 10px rgba(212, 163, 74, 0.5); 
    }
    50% { 
        opacity: 0.85; 
        box-shadow: 0 0 20px rgba(212, 163, 74, 0.8); 
    }
}

.btn-contact:hover {
    background: linear-gradient(135deg, #e0b55d, #d4a34a) !important;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(212, 163, 74, 0.4);
    animation: none;
}

/* Responsive Mobile */
@media (max-width: 768px) {
    .header {
        padding: 6px 10px;
    }
    
    .header-content {
        width: 100%;
    }
    
    .header-top {
        grid-template-columns: auto 1fr;
        gap: 6px;
        padding-right: 80px; /* Espace pour le sélecteur de langue + bouton */
    }
    
    /* Logo plus petit en mobile */
    .cloud-logo {
        width: clamp(70px, 12vw, 90px);
        height: clamp(45px, 8vw, 60px);
    }
    
    .main-cloud {
        width: 65px;
        height: 26px;
        border-radius: 13px;
    }
    
    .cloud-text {
        font-size: clamp(0.6em, 1.1vw, 0.75em);
    }
    
    /* Slogan centré et réduit */
    .header-slogan {
        font-size: clamp(0.75em, 2.8vw, 0.95em);
        overflow: hidden;
        text-overflow: ellipsis;
        justify-self: center;
    }
    
    /* Sélecteur de langue et bouton en haut à droite - mobile */
    .language-selector {
        position: absolute;
        top: 50%;
        right: 10px;
        transform: translateY(-50%);
        flex-direction: column;
        align-items: flex-end;
        gap: 4px;
    }
    
    .lang-select {
        font-size: 0.65em;
        padding: 3px 5px;
        min-width: 40px;
    }
    
    .btn-contact {
        font-size: 0.65em;
        padding: 4px 10px;
    }
    
    /* Navigation horizontale en mobile */
    .nav-menu {
        flex-wrap: nowrap;
        justify-content: flex-start;
        gap: 5px;
        margin-top: 5px;
        overflow-x: auto;
        width: 100%;
        padding: 0 5px;
        scrollbar-width: thin;
    }
    
    .nav-menu::-webkit-scrollbar {
        height: 3px;
    }
    
    .nav-menu::-webkit-scrollbar-track {
        background: rgba(74, 144, 200, 0.2);
    }
    
    .nav-menu::-webkit-scrollbar-thumb {
        background: rgba(74, 144, 200, 0.5);
        border-radius: 3px;
    }
    
    .nav-menu a {
        font-size: 0.65em;
        padding: 4px 7px;
        white-space: nowrap;
        flex-shrink: 0;
    }
    
    .content {
        padding: 20px 15px;
    }
}

/* Pour les très petits écrans */
@media (max-width: 480px) {
    .header-top {
        padding-right: 75px;
    }
    
    .header-slogan {
        font-size: 0.7em;
    }
    
    .nav-menu a {
        font-size: 0.6em;
        padding: 3px 6px;
    }
    
    .lang-select {
        font-size: 0.6em;
        padding: 2px 4px;
        min-width: 35px;
    }
    
    .btn-contact {
        font-size: 0.6em;
        padding: 3px 8px;
    }
}
