body {
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

.navbar-brand {
    font-weight: 600;
}

/*
 * Bootstrap's default placeholder color is dark enough that a placeholder
 * (a hint, never actually submitted) can be mistaken for a real saved value
 * at a glance - see Settings > ISPConfig's Endpoint field, 2026-08-27.
 * Force it visibly lighter and italic so hint text never reads as content.
 */
.form-control::placeholder {
    color: #6c757d !important;
    font-style: italic;
    opacity: 1;
}

/* ---------- New-website wizard (Build 1.8.0) ---------- */

/* 1. Step indicator */
.wizard-steps { display: flex; gap: .75rem; list-style: none; padding: 0; margin: 0 0 1.25rem; counter-reset: step; }
.wizard-steps li { flex: 1 1 0; display: flex; align-items: center; gap: .5rem; counter-increment: step; color: #495057; font-size: .9rem; }
.wizard-steps li::before {
    content: counter(step); flex: none; width: 2rem; height: 2rem; border-radius: 50%;
    display: grid; place-items: center; font-weight: 600; background: #fff; border: 2px solid #6c757d;
}
.wizard-steps li[aria-current="step"] { color: #212529; font-weight: 600; }
.wizard-steps li[aria-current="step"]::before { background: #0d6efd; border-color: #0d6efd; color: #fff; }
.wizard-steps li.is-done::before { content: "\2713"; background: #198754; border-color: #198754; color: #fff; }
@media (max-width: 575.98px) {
    .wizard-steps li:not([aria-current="step"]) .step-label {
        position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap;
    }
}

/* 2. Big tappable choice card (radio via Bootstrap's .btn-check) */
.choice-card {
    position: relative; display: block; height: 100%; min-height: 5.5rem;
    padding: 1rem 1rem 1rem 3.25rem; background: #fff; cursor: pointer;
    border: 2px solid #ced4da; border-radius: .5rem; transition: border-color .15s, background-color .15s;
}
.choice-card::before {
    content: ""; position: absolute; left: 1rem; top: 1.1rem; width: 1.5rem; height: 1.5rem;
    border: 2px solid #6c757d; border-radius: 50%; background: #fff;
}
.choice-card:hover { border-color: #0d6efd; }
.btn-check:checked + .choice-card { border-color: #0d6efd; background: #eef4ff; }
.btn-check:checked + .choice-card::before { border-color: #0d6efd; background: radial-gradient(#0d6efd 0 45%, #fff 50%); }
.btn-check:focus-visible + .choice-card { outline: 3px solid #0d6efd; outline-offset: 2px; }
.btn-check:disabled + .choice-card { cursor: not-allowed; background: #e9ecef; border-style: dashed; color: #495057; }
.btn-check:disabled + .choice-card:hover { border-color: #ced4da; }
.choice-card__title { display: block; font-weight: 600; font-size: 1.1rem; color: #212529; }
.choice-card__hint  { display: block; font-size: .875rem; color: #495057; }

/* 3. Live checklist (address validation) and customer list */
.check-list { list-style: none; padding: 0; margin: .5rem 0 0; font-size: .9rem; }
.check-list li { display: flex; gap: .5rem; align-items: baseline; padding: .15rem 0; color: #495057; }
.check-list li::before { content: "\25CB" / ""; flex: none; width: 1.25rem; text-align: center; }
.check-list li[data-state="ok"]  { color: #146c43; }
.check-list li[data-state="ok"]::before  { content: "\2713" / ""; font-weight: 700; }
.check-list li[data-state="bad"] { color: #b02a37; font-weight: 600; }
.check-list li[data-state="bad"]::before { content: "\2715" / ""; font-weight: 700; }
.customer-list { max-height: max(40vh, 16rem); overflow-y: auto; }

/* 4. Progress list */
.build-icon { flex: none; width: 1.75rem; height: 1.75rem; border-radius: 50%; display: grid; place-items: center;
              font-weight: 700; border: 2px solid #6c757d; color: #495057; background: #fff; }
.build-item[data-state="working"] .build-icon { border-color: #0d6efd #dee2e6 #dee2e6; animation: build-spin .8s linear infinite; }
.build-item[data-state="done"]    .build-icon { background: #198754; border-color: #198754; color: #fff; }
.build-item[data-state="done"]    .build-icon::before { content: "\2713"; }
.build-item[data-state="skipped"] .build-icon { background: #e9ecef; }
.build-item[data-state="skipped"] .build-icon::before { content: "\2013"; }
.build-item[data-state="warn"]    .build-icon { background: #ffc107; border-color: #997404; color: #000; }
.build-item[data-state="warn"]    .build-icon::before { content: "!"; }
.build-item[data-state="failed"]  .build-icon { background: #dc3545; border-color: #dc3545; color: #fff; }
.build-item[data-state="failed"]  .build-icon::before { content: "\2715"; }
.build-item[data-state="failed"]  { background: #fff5f5; }
.build-item[data-state="warn"]    { background: #fffbe6; }
@keyframes build-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
    .build-item[data-state="working"] .build-icon { animation: none; border-color: #0d6efd; }
    .choice-card { transition: none; }
}

/* 5. Mobile sticky action bar and Manage tabs */
@media (max-width: 575.98px) {
    .wizard-actions { position: sticky; bottom: 0; background: #f8f9fa; padding: .75rem 0; border-top: 1px solid #dee2e6; z-index: 5; }
}
.nav-tabs-scroll { flex-wrap: nowrap; overflow-x: auto; white-space: nowrap; }

/* 6. Welcome sheet + credential rows */
.credential { display: grid; grid-template-columns: 9rem 1fr; gap: .25rem 1rem; align-items: center; padding: .5rem 0; border-bottom: 1px solid #e9ecef; }
.credential dt { font-weight: 600; margin: 0; }
.credential dd { margin: 0; }
.credential .pw-print { display: none; font-family: ui-monospace, Menlo, Consolas, monospace; }
@media (max-width: 575.98px) { .credential { grid-template-columns: 1fr; } }

/* 7. Print: only the Welcome sheet */
@media print {
    body { background: #fff !important; }
    nav.navbar, footer, .wizard-actions, .no-print, .alert:not(.print-keep) { display: none !important; }
    .container { max-width: 100% !important; padding: 0 !important; }
    .welcome-sheet { border: 0 !important; box-shadow: none !important; }
    .credential .input-group { display: none !important; }
    .credential .pw-print { display: inline !important; font-size: 12pt; }
    .credential { break-inside: avoid; grid-template-columns: 10rem 1fr; }
    a[href^="http"]::after { content: none !important; }
}

/* ---------- accessibility follow-ups (Build 1.8.0 review) ---------- */
.text-danger, .invalid-feedback { color: #b02a37 !important; }
:focus-visible { outline: 3px solid #0d6efd; outline-offset: 2px; }
.btn:focus-visible, .form-control:focus, .nav-link:focus-visible, .form-select:focus { box-shadow: none; }
.blocker-line { min-height: 1.5rem; }
@media (max-width: 575.98px) { html { scroll-padding-bottom: 7rem; } }
@media (max-height: 480px) { .wizard-actions { position: static; } }
@media (forced-colors: active) {
    .btn-check:checked + .choice-card { border-color: Highlight; outline: 2px solid Highlight; }
    .build-icon { border: 2px solid CanvasText; }
}
@media print { .badge { color: #000 !important; background: none !important; border: 1px solid #000; } }

/* Email (Build 1.9.0) */
[hidden] { display: none !important; }
@media print { .email-page-break { break-before: page; } }

/* ---------- Mobile table affordances (Build 1.25, mobile audit) ---------- */
/*
 * A `.table-responsive` table genuinely too wide to fit a phone screen needs a visible cue that it
 * scrolls - otherwise it reads as "broken"/"cut off" rather than "swipe for more" (found live,
 * 2026-10-01, servers list). Opt in with `.table-scroll-hint` on the `.table-responsive` wrapper.
 */
.table-scroll-hint { position: relative; }
.table-scroll-hint::after {
    content: ""; position: absolute; top: 0; right: 0; bottom: 0; width: 1.5rem; pointer-events: none;
    background: linear-gradient(to right, rgba(255,255,255,0), rgba(0,0,0,.08));
}
.table-scroll-hint-text { display: none; }
@media (max-width: 767.98px) {
    .table-scroll-hint-text { display: block; }
}

/* A column kept in the DOM for a comparison table but hidden on narrow screens to reduce clutter -
   the data's still one tap/scroll away, this just isn't the default view. Pair with a "Show all
   columns" toggle where the hidden data matters enough to recover without resizing the window. */
@media (max-width: 767.98px) {
    .table-mobile-secondary { display: none; }
}

/* Keeps row identity (e.g. hostname) visible while scrolling a wide table horizontally. */
.table-sticky-col { position: sticky; left: 0; background: inherit; }

/* Bootstrap's default btn-sm/badge sizing in dense table rows is under the ~44px touch-target
   guideline - only widen on narrow screens, a dense desktop toolbar is fine as-is. */
@media (max-width: 767.98px) {
    .table-responsive .btn-sm { min-height: 2.25rem; padding-top: .5rem; padding-bottom: .5rem; }
}
