/* ══════════════════════════════════════
   Clears & White — Custom overrides
   Bootstrap 5.3 handles the base.
   ══════════════════════════════════════ */

html { -webkit-text-size-adjust: 100%; }
body { -webkit-font-smoothing: antialiased; overflow-x: hidden; }

/* Brand buttons — dark theme */
.btn-primary { background-color: #1a1a1a; border-color: #1a1a1a; }
.btn-primary:hover, .btn-primary:focus { background-color: #333; border-color: #333; }
.btn-outline-primary { color: #1a1a1a; border-color: #1a1a1a; }
.btn-outline-primary:hover { background-color: #1a1a1a; color: #fff; }

/* Touch-friendly targets — only enforce on mobile */
.btn { min-height: auto; }
.form-control, .form-select { min-height: auto; }
.list-group-item-action { min-height: auto; }

@media (max-width: 768px) {
    .btn { min-height: 44px; }
    .form-control, .form-select { min-height: 44px; }
}

/* Nav link active state */
.navbar .nav-link {
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.5rem 0.5rem;
    border-bottom: 2px solid transparent;
    transition: border-color 0.15s;
}
.navbar .nav-link:hover,
.navbar .nav-link.active {
    border-bottom-color: #000;
}

/* Main content min-height and spacing */
.cw-main {
    min-height: calc(100vh - 140px);
    padding-bottom: 3rem;
    margin-bottom: 2rem;
}

/* Form validation */
.valid.modified:not([type=checkbox]) { outline: 1px solid #26b050; }
.invalid { outline: 1px solid red; }
.validation-message { color: red; }

/* Blazor error UI */
#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0,0,0,0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}
#blazor-error-ui .dismiss { cursor: pointer; position: absolute; right: 0.75rem; top: 0.5rem; }
.blazor-error-boundary { background: #b32121; padding: 1rem; color: white; }
.blazor-error-boundary::after { content: "An error has occurred."; }
