/* Couleurs et en-tête repris de whois.mancec.fr (bleu nuit, accent turquoise, Inter) ; lignes compactes façon start.me. */
@font-face {
  font-family: "Inter"; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url("/assets/fonts/inter-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Inter"; font-style: normal; font-display: swap; font-weight: 100 900;
  src: url("/assets/fonts/inter-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
:root {
  --navy-950: #060d1c; --navy-900: #0b1730; --navy-800: #11234a; --accent: #2dd4bf;
  --fond: #f5f7fb; --carte: #fff; --texte: #0e1a2f; --doux: #55627a;
  --titre-fond: var(--navy-900); --titre-texte: #e6ebf4; --lien: #0b7f75; --trait: #dbe1ec; --survol: #e3f6f3;
  --ombre: 0 1px 2px rgb(14 26 47 / .06), 0 8px 24px -12px rgb(14 26 47 / .18);
  --b-udrp: #e6ecfa; --t-udrp: #2f4a8a; --b-adaptee: #e3f6f3; --t-adaptee: #0b6b63;
  --b-specifique: #fdf0d5; --t-specifique: #7a4a00; --b-registre: #efe7fa; --t-registre: #5b3a8a;
  --b-judiciaire: #fde3e3; --t-judiciaire: #8a1c1c; --b-inconnu: #e7e9ef; --t-inconnu: #4a5468;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --fond: #070e1d; --carte: #0f1c35; --texte: #e6ebf4; --doux: #97a3ba;
    --titre-fond: #0a1427; --lien: #5eead4; --trait: #1d2d4f; --survol: #0f2f37;
    --ombre: 0 1px 2px rgb(0 0 0 / .3), 0 10px 30px -14px rgb(0 0 0 / .6);
    --b-udrp: #17264a; --t-udrp: #a9bdf0; --b-adaptee: #0f2f37; --t-adaptee: #5eead4;
    --b-specifique: #3a2a0a; --t-specifique: #f5c77a; --b-registre: #2a1f42; --t-registre: #cdb6f2;
    --b-judiciaire: #3a1414; --t-judiciaire: #f3a5a5; --b-inconnu: #1d2a44; --t-inconnu: #b4bfd3;
    color-scheme: dark;
  }
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: var(--fond); color: var(--texte); font: 14px/1.45 "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; font-feature-settings: "cv11", "ss01"; }
a { color: var(--lien); text-decoration: none; text-underline-offset: .2em; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

/* En-tête et lien retour, comme whois.mancec.fr */
.hero { background: radial-gradient(120% 140% at 85% -20%, var(--navy-800), var(--navy-950) 60%); color: #e6ebf4; }
.topbar { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; max-width: 1600px; margin: 0 auto; padding: 16px 16px 18px; }
.hero h1 { margin: 0 0 2px; font-size: clamp(18px, 2.4vw, 23px); font-weight: 750; line-height: 1.2; letter-spacing: -.02em; }
.lede { margin: 0; color: #c3cbdb; font-size: 13px; }
.home { display: inline-flex; align-items: center; gap: 7px; flex: none; color: var(--accent); font-weight: 600; font-size: 13px; padding: 5px 12px; border: 1px solid #2a3d66; border-radius: 999px; }
.home img { border-radius: 4px; }
.home:hover { background: var(--navy-800); text-decoration: none; }

.grille { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 14px; padding: 16px 16px 28px; max-width: 1600px; margin: 0 auto; align-items: start; }
.col, .pile { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.col--droite { gap: 20px; }

.carte { background: var(--carte); border: 1px solid var(--trait); border-radius: 12px; padding: 10px 14px; box-shadow: var(--ombre); }
.carte h2, .carte h3 { margin: 0 0 6px; font-size: 15px; font-weight: 650; letter-spacing: -.01em; }
.carte p { margin: 0; }
.carte--titre { background: var(--titre-fond); color: var(--titre-texte); border-color: transparent; border-left: 3px solid var(--accent); }
.carte--titre p { font-size: 13px; color: #c3cbdb; }
.carte--pied { background: transparent; border: 0; box-shadow: none; color: var(--doux); font-size: 12px; padding: 0 4px; }
.mini { font-size: 12px; color: var(--doux); margin-bottom: 6px !important; }
.compte { font-weight: 400; font-size: 12px; color: var(--doux); }

.lignes { list-style: none; margin: 0; padding: 0; }
.lignes li { line-height: 22px; }
.lignes b { font-weight: 600; }

/* Liste des ccTLD : une ligne par extension, détails en infobulle */
.outils { display: flex; gap: 6px; align-items: center; margin-bottom: 6px; flex-wrap: wrap; }
#q, #proc { font: inherit; font-size: 13px; padding: 4px 8px; border: 1px solid var(--trait); border-radius: 8px; background: var(--carte); color: var(--texte); }
#q { flex: 1 1 140px; min-width: 0; }
.case { font-size: 13px; display: flex; gap: 4px; align-items: center; white-space: nowrap; }
.carte--liste { display: flex; flex-direction: column; }
.lignes--tld { max-height: calc(100vh - 260px); min-height: 300px; overflow-y: auto; margin: 0 -14px; padding: 0 14px; position: relative; }
.lignes--tld li { display: flex; align-items: center; gap: 6px; height: 24px; white-space: nowrap; border-bottom: 1px solid var(--trait); }
.lignes--tld li[hidden] { display: none; }
.lignes--tld li.entete { position: sticky; top: 0; z-index: 2; background: var(--carte); font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: var(--doux); border-bottom: 2px solid var(--trait); }
.lignes--tld li.entete .tld, .lignes--tld li.entete .pays, .lignes--tld li.entete .langue { font-size: 11px; color: var(--doux); font-weight: 600; }
.type { flex: 0 0 82px; }
.langue { flex: 0 0 90px; overflow: hidden; text-overflow: ellipsis; font-size: 13px; }
.lignes--tld li:last-child { border-bottom: 0; }
.lignes--tld li:target { background: color-mix(in srgb, #d97706 18%, transparent); }
.tld { flex: 0 0 34px; font-weight: 600; font-variant-numeric: tabular-nums; }
.b { flex: 0 0 auto; font-size: 11px; font-weight: 600; line-height: 17px; padding: 0 7px; border-radius: 999px; white-space: nowrap; }
.b-udrp { background: var(--b-udrp); color: var(--t-udrp); } .b-adaptee { background: var(--b-adaptee); color: var(--t-adaptee); }
.b-specifique { background: var(--b-specifique); color: var(--t-specifique); } .b-registre, .b-mediation { background: var(--b-registre); color: var(--t-registre); }
.b-judiciaire { background: var(--b-judiciaire); color: var(--t-judiciaire); } .b-inconnu { background: var(--b-inconnu); color: var(--t-inconnu); }
.txt { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.pays { flex: 0 0 190px; color: var(--doux); overflow: hidden; text-overflow: ellipsis; font-size: 13px; }
.i { color: var(--doux); font-size: 12px; cursor: help; }
.act { flex: 0 0 120px; display: flex; gap: 8px; font-size: 12px; justify-content: flex-end; }

@media (max-width: 900px) {
  .grille { grid-template-columns: 1fr; padding: 12px 8px; }
  .topbar { padding: 12px; }
  .pays, .langue { display: none; }
}
@media (max-width: 720px) {
  .lignes--tld { max-height: 70vh; }
  .lede { display: none; }
  .topbar { align-items: center; }
}

/* Ligne entièrement cliquable vers la procédure (comme sur start.me) : le lien de l'extension couvre toute la ligne,
   les liens OMPI et Déc. restent au-dessus. */
.lignes--tld li[data-tld] { position: relative; }
.lignes--tld li.lien:hover { background: var(--survol); cursor: pointer; }
.lignes--tld a.tld::after { content: ""; position: absolute; inset: 0; }
.lignes--tld a.tld:hover { text-decoration: none; }
.act a { position: relative; z-index: 1; }

/* Favicons en début de ligne */
.fav { flex: 0 0 16px; width: 16px; height: 16px; display: inline-flex; }
.fav img { width: 16px; height: 16px; object-fit: contain; }
.lignes--ico li { display: flex; align-items: center; gap: 6px; }

/* Colonne Décisions */
.dec { flex: 0 0 120px; display: flex; gap: 8px; font-size: 12px; }
.dec a, .act a { position: relative; z-index: 1; }
.lignes--tld li.entete .dec, .lignes--tld li.entete .act { font-size: 11px; }
@media (max-width: 900px) { .act { display: none; } }

/* Grille du tableau ccTLD : colonnes réparties, texte long sur plusieurs lignes */
.lignes--tld li {
  display: grid;
  grid-template-columns: 16px 38px minmax(110px, 1.2fr) 78px minmax(70px, .6fr) minmax(150px, 1.6fr) minmax(95px, .8fr) minmax(120px, .9fr);
  column-gap: 10px; align-items: center;
  height: auto; min-height: 24px; padding: 2px 0; white-space: normal; line-height: 18px;
}
.lignes--tld li > span { min-width: 0; overflow: visible; text-overflow: clip; overflow-wrap: anywhere; }
.lignes--tld .act, .lignes--tld .dec { flex-wrap: wrap; column-gap: 8px; row-gap: 0; }
.lignes--tld .act { justify-content: flex-start; }
.lignes--tld li.entete { line-height: 14px; padding: 4px 0; align-items: end; }
@media (max-width: 900px) {
  .lignes--tld li { grid-template-columns: 16px 38px 78px minmax(0, 1fr) minmax(70px, auto); }
  .lignes--tld .pays, .lignes--tld .langue, .lignes--tld .act { display: none; }
}

/* Bloc ccTLD aussi haut que la colonne de droite : la liste occupe l'espace restant */
@media (min-width: 901px) {
  .grille { align-items: stretch; }
  #cctld .carte--liste { flex: 1 1 auto; min-height: 0; }
  #cctld .lignes--tld { flex: 1 1 0; max-height: none; min-height: 400px; }
}
