:root {
    --ww-blue: #1452cc;
    --ww-blue-dark: #0e3a96;
    --ww-blue-soft: #f7faff;
    --ww-border: #e6ecf5;
    --ww-ink: #1a1a2e;
    --ww-muted: #6b7385;
    --ww-ok: #0a7d35;
    --ww-warn: #b4690e;
    --ww-radius: 12px;
    --ww-shadow: 0 1px 4px rgba(20, 82, 204, 0.05);
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background: #ffffff;
    color: var(--ww-ink);
    line-height: 1.5;
    min-height: 100vh;
}

.wrap { max-width: 960px; margin: 0 auto; padding: 28px 20px 60px; }

.brand-head {
    display: flex; align-items: baseline; justify-content: space-between;
    flex-wrap: wrap; gap: 10px; margin-bottom: 6px;
}
.brand {
    font-size: 32px; font-weight: 800; color: var(--ww-blue);
    letter-spacing: -1px;
}
.brand span { font-weight: 400; letter-spacing: 4px; font-size: 13px; display:block; }
.brand-sub { color: var(--ww-muted); font-size: 14px; }

.layout { display: grid; grid-template-columns: 1fr 320px; gap: 22px; align-items: start; }
@media (max-width: 820px) { .layout { grid-template-columns: 1fr; } }

.card {
    background: #fdfdff; border: 1px solid var(--ww-border);
    border-radius: var(--ww-radius); box-shadow: var(--ww-shadow);
    padding: 22px; margin-bottom: 18px;
}
.card h2 {
    margin: 0 0 14px; font-size: 15px; color: var(--ww-blue);
    text-transform: uppercase; letter-spacing: 0.5px;
    border-bottom: 2px solid var(--ww-blue); padding-bottom: 6px;
}

.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 5px; color: var(--ww-ink); }
.field input[type=text], .field input[type=email], .field input[type=number], .field select, .field textarea {
    width: 100%; padding: 10px 12px; font-size: 14px;
    border: 1px solid var(--ww-border); border-radius: 8px; background: #fff;
    transition: border-color .15s, box-shadow .15s;
    font-family: inherit;
}
.field textarea { resize: vertical; min-height: 84px; }
.field input:focus, .field select:focus, .field textarea:focus {
    outline: none; border-color: var(--ww-blue);
    box-shadow: 0 0 0 3px rgba(20, 82, 204, 0.12);
}
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 520px) { .row { grid-template-columns: 1fr; } }

.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.choice {
    border: 1.5px solid #c7d2e8; border-radius: 10px; padding: 14px; background: #fff;
    cursor: pointer; transition: all .15s; position: relative;
}
.choice:hover { border-color: var(--ww-blue); background: var(--ww-blue-soft); }
.choice input { position: absolute; opacity: 0; }
.choice.selected { border-color: var(--ww-blue); background: var(--ww-blue-soft); box-shadow: var(--ww-shadow); }
.choice .c-title { font-weight: 700; color: var(--ww-blue); }
.choice .c-price { font-size: 13px; color: var(--ww-muted); margin-top: 2px; }

.periods { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.period {
    text-align: center; border: 1.5px solid #c7d2e8; border-radius: 10px;
    padding: 12px 8px; cursor: pointer; transition: all .15s; background: #fff;
}
.period:hover { border-color: var(--ww-blue); background: var(--ww-blue-soft); }
.period input { position: absolute; opacity: 0; }
.period.selected { border-color: var(--ww-blue); background: var(--ww-blue-soft); box-shadow: var(--ww-shadow); }
.period .p-label { font-weight: 600; font-size: 14px; color: var(--ww-ink); }
.period .p-price { color: var(--ww-blue); font-weight: 700; margin-top: 4px; font-size: 14px; }

.sign-block { background: var(--ww-blue-soft); border-radius: 10px; padding: 16px; }
.checkbox-line { display: flex; gap: 10px; align-items: flex-start; margin-top: 10px; }
.checkbox-line input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--ww-blue); }
.checkbox-line label { font-size: 13px; color: var(--ww-ink); }

/* Récapitulatif sticky */
.recap { position: sticky; top: 20px; }
.recap .amount-line { display: flex; justify-content: space-between; padding: 7px 0; border-bottom: 1px solid var(--ww-border); font-size: 14px; }
.recap .amount-line.total { border-bottom: none; border-top: 2px solid var(--ww-blue); margin-top: 4px; padding-top: 12px; font-size: 18px; font-weight: 800; color: var(--ww-blue); }
.recap .muted { color: var(--ww-muted); }
.recap .visual-note { font-size: 12px; color: var(--ww-muted); margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--ww-border); }

.btn {
    display: inline-block; background: var(--ww-blue); color: #fff; border: none;
    padding: 13px 22px; font-size: 15px; font-weight: 700; border-radius: 10px;
    cursor: pointer; text-decoration: none; transition: background .15s; width: 100%;
    text-align: center;
}
.btn:hover { background: var(--ww-blue-dark); }
.btn-ghost { background: #fff; color: var(--ww-blue); border: 1.5px solid var(--ww-blue); }
.btn-ghost:hover { background: var(--ww-blue-soft); }

.errors { background: #fdecec; border: 1px solid #f5c2c2; color: #a12525; border-radius: 10px; padding: 14px 16px; margin-bottom: 18px; }
.errors ul { margin: 6px 0 0; padding-left: 20px; }

.devis-field { display: none; margin-top: 12px; }
.devis-field.show { display: block; }

/* Page de confirmation */
.confirm { max-width: 520px; margin: 80px auto; background: #fff; border: 1px solid var(--ww-border); border-radius: var(--ww-radius); box-shadow: var(--ww-shadow); padding: 40px; text-align: center; }
.confirm .check { width: 64px; height: 64px; border-radius: 50%; background: var(--ww-ok); color: #fff; font-size: 36px; line-height: 64px; margin: 0 auto 16px; }
.confirm h1 { color: var(--ww-blue); font-size: 22px; margin: 0 0 12px; }
.confirm .amount-recap { font-size: 18px; margin: 18px 0; }
.confirm .actions { display: flex; gap: 12px; margin-top: 24px; }
.confirm .actions .btn { flex: 1; }
.warn { color: var(--ww-warn); font-weight: 600; }
