/* Portail Partners : une seule feuille, servie en statique (CSP style-src 'self').
   La couleur d'accent vient de /theme.css (config du programme) et ne sert
   qu'aux boutons, a la marque et aux liens. */

:root {
    --accent: #1f2328;
    --ink: #1f2328;
    --muted: #57606a;
    --line: #d8dee4;
    --soft: #f6f8fa;
    --red: #b42318;
    --green: #11703a;
    --amber: #b26a00;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font: 16px/1.55 system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
    color: var(--ink);
    background: #fff;
}

.bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: .9rem 1.5rem;
    border-bottom: 1px solid var(--line);
}

.brand { font-weight: 700; color: var(--accent); text-decoration: none; }
.bar nav { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }
.bar a { text-decoration: none; }
a { color: var(--accent); }
.inline { display: inline; margin: 0; }

button.link {
    background: none;
    border: 0;
    padding: 0;
    color: var(--accent);
    font: inherit;
    cursor: pointer;
}

main { padding: 1.5rem; max-width: 52rem; margin: 0 auto; }

footer {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    padding: 1.5rem;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: .9rem;
}

h1 { font-size: 1.7rem; line-height: 1.25; margin: 0 0 .5rem; }
h2 { font-size: 1.2rem; margin: 2rem 0 .75rem; }
.lead { color: var(--muted); margin: 0 0 1.5rem; }

table { border-collapse: collapse; width: 100%; margin-bottom: 1rem; }
th, td { border-bottom: 1px solid var(--line); padding: .5rem .6rem; text-align: left; vertical-align: top; }
th { background: var(--soft); font-weight: 600; white-space: nowrap; }

.button {
    display: inline-block;
    padding: .55rem 1.1rem;
    background: var(--accent);
    color: #fff;
    border: 0;
    border-radius: 6px;
    font: inherit;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}

.actions { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; }

form { margin: 0 0 1rem; }
fieldset { border: 1px solid var(--line); margin: 0 0 1rem; padding: 1rem; }
legend { font-weight: 600; padding: 0 .4rem; }
label { display: block; font-weight: 600; margin-top: .75rem; }
input[type=text], input[type=email], input[type=url], textarea, select {
    width: 100%;
    max-width: 32rem;
    font: inherit;
    padding: .45rem .55rem;
    border: 1px solid var(--line);
    border-radius: 4px;
}
.check { display: flex; gap: .5rem; align-items: baseline; font-weight: 400; }
.radio { display: flex; gap: .5rem; align-items: baseline; font-weight: 600; }

.message { padding: .6rem .8rem; border-left: 3px solid var(--line); background: var(--soft); }
.error { border-left-color: var(--red); color: var(--red); }
.success { border-left-color: var(--green); color: var(--green); }
.banner { padding: .6rem .8rem; background: #fff8e1; border-left: 3px solid var(--amber); margin-bottom: 1rem; }
.note { color: var(--muted); font-size: .9rem; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: 1rem; margin: 1rem 0; }
.stat { border: 1px solid var(--line); border-radius: 6px; padding: .75rem 1rem; }
.stat strong { display: block; font-size: 1.4rem; }
.stat span { color: var(--muted); font-size: .9rem; }

code { background: var(--soft); padding: .1rem .3rem; border-radius: 3px; word-break: break-all; }
dt { font-weight: 600; margin-top: 1rem; }
dd { margin: .25rem 0 0; }

/* Pot de miel du formulaire de candidature : hors ecran, jamais display:none
   (certains robots sautent les champs display:none). */
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* Releve d'un payout : deux parties cote a cote, adresses sur plusieurs
   lignes sans <br>, total en gras. */
.parties { display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); gap: 1.5rem; margin: 1rem 0 1.5rem; }
.parties h2 { margin-top: 0; }
.address { white-space: pre-line; margin: .25rem 0 0; }
tfoot td { font-weight: 700; }

/* Impression du releve : la coque, la navigation et les aides disparaissent,
   il reste la piece comptable. */
@media print {
    .bar, footer, .no-print { display: none; }
    main { max-width: none; padding: 0; }
    a { color: inherit; text-decoration: none; }
}

/* Kit marketing : posts a copier sur toute la largeur, apercus a la taille
   de la colonne au plus. */
textarea[readonly] { max-width: none; background: var(--soft); }
.kit-files { list-style: none; padding: 0; }
.kit-files li { margin: 0 0 1.25rem; }
.kit-files img { display: block; max-width: 100%; height: auto; border: 1px solid var(--line); margin-bottom: .4rem; }
