/* ============================================
   ANNUAIRE-FR.EU - CSS MODERNISÉ 2025
   Compatible avec structure HTML existante
   ============================================ */

/* === RESET & BASE === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 
                 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif;
    font-size: 15px;
    line-height: 1.6;
    color: #2c3e50;
    background: #f8f9fa;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* === TITRES === */
h2, h3 {
    font-family: inherit;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 1rem;
}

h2 {
    font-size: 1.8rem;
    border-bottom: 3px solid #3498db;
    padding-bottom: 0.5rem;
}

h3 {
    font-size: 1.4rem;
    color: #2980b9;
}

h5 {
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    color: #34495e;
    padding: 0.5rem 0;
    margin: 1rem 0;
    border-left: 4px solid #3498db;
    padding-left: 0.75rem;
    background: linear-gradient(to right, rgba(52, 152, 219, 0.1), transparent);
}

/* === CONTENEURS === */
div.titre_gauche,
div.titre_droite {
    width: 135px;
    background: linear-gradient(135deg, #667eea 0%, #788AAF 100%);
    border-radius: 8px;
    padding: 1rem;
    color: white;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

div.titre_bas,
div.titre_news {
    width: 100%;
    max-width: 200px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px;
    padding: 1rem;
    color: white;
    float: left;
    margin-right: 1rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

div.titre_article {
    width: 100%;
    max-width: 400px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px;
    padding: 1rem;
    color: white;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* === PARAGRAPHES & LISTES === */
p, li {
    font-family: inherit;
    font-size: 15px;
    color: #2c3e50;
    line-height: 1.7;
    margin: 0.5rem 0;
}

ul.orange {
    list-style: none;
    margin: 0;
    padding: 1rem;
}

ul.orange li::before {
    content: "?";
    color: #e67e22;
    font-weight: bold;
    display: inline-block;
    width: 1em;
    margin-left: -1em;
}

ul.bleu {
    list-style: none;
    padding: 0;
    margin: 0 0 0 1.5rem;
}

ul.bleu li::before {
    content: "?";
    color: #3498db;
    font-weight: bold;
    display: inline-block;
    width: 1em;
    margin-left: -1em;
}

/* === LIENS === */
a {
    font-family: inherit;
    font-size: inherit;
    color: #3498db;
    text-decoration: none;
    transition: all 0.2s ease;
}

a:visited {
    color: #8e44ad;
}

a:hover {
    color: #2980b9;
    background: rgba(52, 152, 219, 0.1);
    text-decoration: none;
    border-radius: 3px;
    padding-: 1px 2px;
}

a:focus {
    outline: 2px solid #3498db;
    outline-offset: 2px;
}

/* === MENU & PIED === */
div.menu,
#pied {
    color: white;
    font-weight: 600;
    font-family: inherit;
    font-size: 14px;
    background: linear-gradient(135deg, #667eea 0%, #788AAF 100%);
    width: 100%;
    min-height: 50px;
    text-align: center;
    padding: 1rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.menu a {
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.menu a:visited {
    color: white;
}

.menu a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* === BORDURES & SÉPARATEURS === */
.ligne_bas {
    border-bottom: 2px solid #e0e0e0;
    margin: 1rem 0;
}

.titre_news_barre {
    border-top: 3px solid #e67e22;
    width: 95%;
    margin: 1rem auto;
    padding-top: 1rem;
}

.cell_milieu {
    border-left: 1px solid #ddd;
    border-right: 1px solid #ddd;
    padding: 1rem;
}

/* === CARTES DE CONTENU === */
.couleur1,
.couleur2 {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin: 1rem 0;
    padding: 1.25rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.couleur1:hover,
.couleur2:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.couleur1 {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
}

.couleur2 {
    background: linear-gradient(135deg, #ffffff 0%, #f1f3f5 100%);
}

div.couleur1,
div.couleur2 {
    border-style: solid;
}

/* === TABLEAUX === */
table {
    width-: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
	margin-left:auto;
	margin-right:auto;
}

table th {
    background: linear-gradient(135deg, #667eea 0%, #788AAF 100%);
    color: white;
    padding: 6px;
    text-align: left;
    font-weight: 600;
}

table th p
{
	color:white !important;
}

table td {
    padding: 6px;
    border-bottom: 1px solid #e0e0e0;
}

table tr:last-child td {
    border-bottom: none;
}

table tr:hover {
    background: #f8f9fa;
}

/* === MÉTADONNÉES === */
.url {
    color: #7f8c8d;
    font-size: 13px;
    font-style: italic;
}

.hit,
.code {
    font-family: 'Courier New', Courier, monospace;
    font-size: 12px;
    background: #f1f3f5;
    padding: 2px 6px;
    border-radius: 3px;
    color: #495057;
}

a.motcle {
    font-family: inherit;
    font-size: 13px;
    background: #e3f2fd;
    padding: 4px 8px;
    border-radius: 4px;
    color: #1976d2;
    display: inline-block;
    margin: 2px;
    transition: all 0.2s ease;
}

a.motcle:hover {
    background: #2196f3;
    color: white;
    transform: scale(1.05);
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    body {
        font-size: 14px;
    }

    h2 {
        font-size: 1.5rem;
    }

    h3 {
        font-size: 1.2rem;
    }

    div.titre_gauche,
    div.titre_droite,
    div.titre_bas,
    div.titre_news,
    div.titre_article {
        width: 100%;
        max-width: 100%;
        float: none;
        margin: 0.5rem 0;
    }

    div.menu,
    #pied {
        font-size: 13px;
        padding: 0.75rem;
        min-height: auto;
    }

    .menu a {
        padding: 0.4rem 0.75rem;
        font-size: 13px;
    }

    table {
        font-size: 13px;
    }

    table th,
    table td {
        padding: 0.5rem;
    }

    .couleur1,
    .couleur2 {
        padding: 1rem;
        margin: 0.75rem 0;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 13px;
    }

    h2 {
        font-size: 1.3rem;
    }

    h3 {
        font-size: 1.1rem;
    }

    div.menu,
    #pied {
        font-size: 12px;
    }

    .couleur1,
    .couleur2 {
        padding: 0.75rem;
    }
}

/* === ANIMATIONS === */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.couleur1,
.couleur2 {
    animation: fadeIn 0.4s ease-out;
}

/* === ACCESSIBILITÉ === */
:focus-visible {
    outline: 2px solid #3498db;
    outline-offset: 2px;
    border-radius: 2px;
}

/* Amélioration des contrastes */
::selection {
    background: #3498db;
    color: white;
}

/* === IMPRESSION === */
@media print {
    body {
        background: white;
        color: black;
    }

    div.menu,
    #pied {
        display: none;
    }

    a {
        color: black;
        text-decoration: underline;
    }

    .couleur1,
    .couleur2 {
        box-shadow: none;
        border: 1px solid #ccc;
    }
}