body {
    font-family: verdana, sans-serif;
    font-size: 0.85em;
    background-color: #eee;
}

.hp-field {
    position: absolute;
    left: -10000px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.full,
.short {
    filter: drop-shadow(1px 0 white) drop-shadow(-1px 0 white) drop-shadow(0 1px white)
        drop-shadow(0 -1px white);
    margin-top: 15px;
    margin-bottom: -15px;
}

#head {
    background-color: #131EAE;
    padding: 40px;
    margin-bottom: 50px;
}

.loader-box {
    width: 300px; /* ici */
    max-width: 80vw;
    text-align: center;
}

.loader-box img {
    width: 100%;
    height: auto;
}

#loader.loader-hidden {
    display: none;
}

.img-center,
.logo-center {
    display: block;
    margin: 0 auto;
}

#ssl-head {
    color: white;
    font-size: 1.3rem;
    display: none;
    margin-top: 70px;
    margin-left: 15px;
    margin-right: 15px;
    padding: 40px;
    background-color: #6b7280;

    justify-content: center;
    align-items: center;

    text-align: center;
    /* important */
}

#ssl-head.visible {
    display: flex;
    flex-direction: column;
    /* clé du problème */
}

form {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

button {
    width: 120px;
    color: #333;
    padding: 10px;
    border: 1px solid #000000;
    border-radius: 6px;
    font-size: 16px;
    background-color: yellow;
}

input[type='text'] {
    flex: 1;
    max-width: 50%;
    padding: 10px 14px;
    font-size: 16px;
    border: 1px solid #000000;
    border-radius: 6px;
    background-color: #ffffcc;
}

.scheme-choice {
    display: flex;
    flex-direction: column; /* l’un sous l’autre */
    align-items: left;
    gap: 6px;
    text-align: left;
}

.scheme-choice label {
    cursor: pointer;
}

.tab1,
.tab2,
.tab3,
.tab4 {
    text-align: left;
}

table {
    border-collapse: collapse;
    width: 90%;
    margin: 20px auto;
    table-layout: fixed;
}

th,
td {
    border: 1px solid #ccc;
    padding: 6px 10px;
    vertical-align: middle;
    /* centre verticalement */
    word-break: break-word;
    /* permet de casser les mots longs (affichage smartphone par exemple)*/
    overflow-wrap: anywhere;
}

td.cell {
    max-width: 0;
    /* important avec table-layout: fixed */
    white-space: normal;
    overflow-x: auto;
    /* Permet le scroll pour CSP/cookies très longs */
}

td.cell pre {
    white-space: pre-wrap;
    word-break: break-word;
}

th.tab1 {
    background: #ffffb3;
    width: 30%;
    text-align: left;
}

th.tab2 {
    background: #dfdbfc;
    width: 30%;
    text-align: left;
}

th.tab3 {
    background: #f9e1f7;
    width: 30%;
    text-align: left;
}

th.tab4 {
    background: #dbfce1;
    width: 30%;
    text-align: left;
}

/* le flex est ici, pas sur th */

.th-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.th-label {
    flex: 1;
}

.missing {
    color: red;
}

.cell {
    background-color: #ddd;
}

#example {
    color: #fff;
    font-size: 1em;
}

.white-big {
    color: #fff;
    font-size: 1.5rem;
}

.white-sml {
    color: #fff;
    font-size: 0.9rem;
}

.author {
    font-size: 0.9rem;
}

#noir {
    color: #000;
}

.titre-headers1 {
    position: relative;
    white-space: normal;
    margin: 30px 10px 10px 30px;
    text-align: center;
    background-color: #ffffb3;
    width: 50%;
    padding: 5px;
    border-radius: 5px;
    border: 1px solid #999;
}

@media (max-width: 800px) {
    .titre-headers1 {
        position: relative;
        white-space: normal;
        margin: 30px 10px 10px 30px;
        text-align: center;
        background-color: #ffffb3;
        width: 80%;
        padding: 5px;
        border-radius: 5px;
        border: 1px solid #999;
    }
}

.titre-headers2 {
    margin-top: 50px;
    margin-bottom: 10px;
    margin-left: 30px;
    text-align: center;
    background-color: #dfdbfc;
    width: 50%;
    padding: 5px;
    border-radius: 5px;
    border: 1px solid #999;
}

.titre-headers3 {
    margin-top: 50px;
    margin-bottom: 10px;
    margin-left: 30px;
    text-align: center;
    background-color: #f9e1f7;
    width: 50%;
    padding: 5px;
    border-radius: 5px;
    border: 1px solid #999;
}

.titre-headers4 {
    margin-top: 50px;
    margin-bottom: 10px;
    margin-left: 30px;
    text-align: center;
    background-color: #dbfce1;
    width: 50%;
    padding: 5px;
    border-radius: 5px;
    border: 1px solid #999;
}

ul {
    margin: 0;
    padding-left: 18px;
}

.blue {
    color: #2563eb;
    /* bleu lisible */
    font-weight: 500;
}

.blue-cookie {
    color: #2563eb;
    /* bleu lisible */
    font-weight: bold;
}

.red {
    color: #c00000;
    /* rouge lisible */
    font-weight: 500;
}

.red-cookie {
    color: #c00000;
    /* rouge lisible */
    font-weight: bold;
}

.orange {
    color: #de6e1e;
    /* rouge lisible */
    font-weight: 500;
}

/* comportement commun */
.btn-why {
    margin-left: 6px;
    width: auto;
    padding: 2px 6px 4px 6px;
    cursor: pointer;
    flex-shrink: 0;
    border-radius: 4px;
    font-size: 1.1em;
    border: 1px solid #444;
}

/* boutons headers HTTP */
.btn-headers {
    background-color: #ffff14;
}

/* boutons DNS */
.btn-dns {
    background: #ffff14;
    color: #000;
}

/* hover léger */
.btn-why:hover {
    filter: brightness(0.95);
}

.btn-csp {
    margin-top: 6px;
    margin-left: -2px;
}

.justif {
    display: none;
    margin-top: 8px;
    padding: 10px;
    background: #f8f9fa;
    border-left: 4px solid #3b82f6;
    font-size: 0.9em;
}

.justif.open {
    display: block;
}

.th-header {
    position: relative;
    text-align: left;
    padding-right: 36px;
}

.th-title {
    display: inline-block;
}

.info-btn {
    position: absolute;
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
    border: none;
    background: none;
    cursor: pointer;
    font-size: 16px;
    opacity: 0.7;
}

.info-btn:hover {
    opacity: 1;
}

.info-box {
    display: none;
    margin-top: 8px;
    padding: 10px;
    background: #f6f8fa;
    border-left: 4px solid #3b82f6;
    font-size: 0.9em;
}

.grade-A-Plus {
    color: #16a34a;
}

/* vert */

.grade-A {
    color: #16a34a;
}

/* vert */

.grade-B {
    color: #22c55e;
}

.grade-C {
    color: #eab308;
}

/* jaune */

.grade-D {
    color: #f97316;
}

/* orange */

.grade-E {
    color: #dc2626;
}

/* rouge */

.box-grade-A-Plus {
    display: none;
    position: absolute;
    font-size: 3em;
    width: 85px;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid white;
    color: white;
    text-align: center;
    background-color: #16a34a;
}

/* vert */

.box-grade-A {
    display: none;
    position: absolute;
    font-size: 3em;
    width: 60px;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid white;
    color: white;
    text-align: center;
    background-color: #16a34a;
}

/* vert */

.box-grade-B {
    display: none;
    position: absolute;
    font-size: 3em;
    width: 60px;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid white;
    color: white;
    text-align: center;
    background-color: #22c55e;
}

/* vert clair */

.box-grade-C {
    display: none;
    position: absolute;
    font-size: 3em;
    width: 60px;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid white;
    color: white;
    text-align: center;
    background-color: #eab308;
}

/* jaune */

.box-grade-D {
    display: none;
    position: absolute;
    font-size: 3em;
    width: 60px;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid white;
    color: white;
    text-align: center;
    background-color: #f97316;
}

/* orange */

.box-grade-E {
    display: none;
    position: absolute;
    font-size: 3em;
    width: 60px;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid white;
    color: white;
    text-align: center;
    background-color: #dc2626;
}

/* rouge */

.note-dns {
    margin-bottom: 12px;
    margin-right: 30px;
    margin-left: 30px;
    padding: 10px 12px;
    border-left: 4px solid;
    background: #f8f9fa;
    font-size: 0.95em;
}

.note-dns.green {
    border-color: #16a34a;
    background: #ecfdf5;
}
.note-dns.yellow {
    border-color: #eab308;
    background: #fffbeb;
}
.note-dns.orange {
    border-color: #f97316;
    background: #fff7ed;
}
.note-dns.red {
    border-color: #dc2626;
    background: #fef2f2;
}

.header-note {
    padding-top: 6px;
}

html.no-scroll,
body.no-scroll {
    overflow: hidden !important;
    height: 100%;
}

#titre {
    color: #fff;
    margin: auto;
    text-align: center;
    background-color: #131EAE;
    width: 85%;
    padding: 10px;
    border: 1px solid #fff;
    border-radius: 10px;
    position: relative;
}

#image-mg {
    width: 100px;
    position: absolute;
    left: -50px;
    top: 50%;
    transform: translateY(-50%);
}

/* Cacher #image-mg sous 800px */
@media (max-width: 850px) {
    #image-mg {
        display: none;
    }
    .img-center {
        width: 400px;
    }
    #titre {
        color: #fff;
        margin: auto;
        text-align: center;
        background-color: #131EAE;
        width: 95%;
        padding: 10px;
        border: 1px solid #fff;
        border-radius: 10px;
        position: relative;
    }
}

#display-url {
    color: blue;
}

.preview-full {
    white-space: nowrap;
    width: 80%;
    overflow: hidden;
    margin-top: 4px;
    padding-top: 6px;
    padding-bottom: 6px;
    border-radius: 4px;
}

.preview-truncated {
    white-space: nowrap;
    width: 80%;
    overflow: hidden;
    font-size: 0.85em;
    background: #fff;
    margin-top: 4px;
    padding : 4px 6px;
    border-radius: 4px;
}

.info-box {
    display: none;
}
.info-box.open {
    display: block;
}

.ligne {
    display: block; /* force le retour à la ligne */
    margin-bottom: 0.4em; /* ajuste exactement l’espace voulu */
}

#loader::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
}

#loader {
    position: fixed;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;

    opacity: 1;
    transition: opacity 0.35s ease;
}

.loader-text {
    color: #fff;
    font-size: 1rem;
    background: rgba(0, 0, 0, 0.75);
    padding: 6px 12px;
    border-radius: 6px;
    text-align: center;
    max-width: 90vw;
}

.loader-box {
    position: fixed;
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;

    transform: scale(1);
    transition: transform 0.35s ease;
}

.loader-box img {
    width: 300px;
    max-width: 70vw;
    height: auto;
    opacity: 0.5;
}

#loader.loader-hidden {
    opacity: 0;
    pointer-events: none;
}

#loader.loader-hidden .loader-box {
    transform: scale(0.96); /* léger zoom-out */
}

.analysis-hidden {
    display: none;
}

.btn-cookie {
    margin: 8px 0px 3px -2px;
}

td.cell ul li {
    margin: 3px 0;
}

.dns-empty {
    color: #666;
}

.api-info {
    color: red;
    font-weight: 300;
    font-size: 0.8rem;
    margin-bottom: 5px;
}

.ssl-ev { color:#1CA64F; font-weight:bold; }
.ssl-ov { color:#078CC5; }
.ssl-dv { color:#F95E10; }


/* ==========================================================
   MOBILE 375px-like
   ========================================================== */
@media (max-width: 420px) {
    body {
        font-size: 14px;
    }

    /* ===== HEADER ===== */
    #head {
        padding: 20px 10px;
    }

    #titre {
        width: 95%;
        padding: 10px;
    }

    .full {
        width: 100%;
        max-width: 320px;
        height: auto;
    }

    .short {
        width: 100%;
        max-width: 280px;
        height: auto;
    }

    .author {
        display: block;
        margin-top: 6px;
        font-size: 0.8rem;
    }

    /* ===== FORMULAIRE ===== */
    form {
        flex-direction: column;
        gap: 10px;
        margin-top: 20px;
    }

    input[type='text'] {
        max-width: 100%;
        width: 100%;
        font-size: 0.95rem;
    }

    button {
        width: 100%;
        font-size: 0.95rem;
        padding: 12px;
    }

    .scheme-choice {
        flex-direction: row;
        gap: 15px;
        justify-content: center;
    }

    /* ===== TITRES ===== */
    .titre-headers1,
    .titre-headers2,
    .titre-headers3,
    .titre-headers4 {
        width: 95%;
        margin: 25px auto 10px auto;
        font-size: 0.95rem;
    }

    /* ===== TABLES : SCROLL HORIZONTAL ===== */
    table {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    table::after {
        content: '↔ glisser';
        display: block;
        text-align: right;
        font-size: 0.7rem;
        color: #666;
        padding: 4px 6px;
    }

    th,
    td {
        white-space: nowrap;
        font-size: 0.8rem;
    }

    th {
        min-width: 140px;
    }

    td.cell {
        min-width: 260px;
    }

    /* ===== PREVIEW CSP / COOKIES ===== */
    .preview-full,
    .preview-truncated {
        width: 100%;
        font-size: 0.8rem;
    }

    pre {
        font-size: 0.75rem;
    }

    /* ===== JUSTIFICATIONS ===== */
    .justif,
    .info-box,
    .dns-note {
        font-size: 0.8rem;
        padding: 8px;
    }

    /* ===== BOUTONS INFO ===== */
    .btn-why {
        font-size: 0.9rem;
        padding: 4px 6px;
    }

    /* ===== LOADER ===== */
    .loader-box img {
        width: 200px;
        max-width: 70vw;
    }

    .loader-text {
        font-size: 0.85rem;
    }

    /* ===== FOOTER IMAGES ===== */
    .img-center {
        width: 90%;
        max-width: 320px;
        margin-top: -15px;
    }

    .logo-center {
        width: 80px;
    }

    #url-input {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box; /* 👈 clé du fix */
    }

    #ssl-head {
    margin-top: 5px;
    margin-left: 5px;
    margin-right: 5px;

}
}
