/* ==========================================================================
   OsmoTools — Vérificateur de code HTTP (shortcode [osmova_code_http])
   ========================================================================== */

.ohc {
    --ohc-noir: #0A0A0A;
    --ohc-gris: #6B7280;
    --ohc-border: #E5E7EB;
    --ohc-blue: #0064FF;
    --ohc-ok: #028a5e;
    --ohc-warn: #B45309;
    --ohc-err: #B91C1C;
    --ohc-mono: 'JetBrains Mono', monospace;
    margin: 0 0 40px;
    padding: 28px;
    border: 1px solid var(--ohc-border);
    border-radius: 16px;
    background: #fff;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--ohc-noir);
}

.ohc__badge {
    display: inline-block;
    margin: 0 0 12px;
    padding: 4px 10px;
    border-radius: 4px;
    background: color-mix(in srgb, var(--ohc-blue) 10%, white);
    color: var(--ohc-blue);
    font: 700 11px/1.4 var(--ohc-mono);
    letter-spacing: .08em;
    text-transform: uppercase;
}

.ohc .ohc__title {
    margin: 0 0 8px;
    font-size: 1.5rem;
    line-height: 1.25;
}

.ohc__intro {
    margin: 0 0 18px;
    color: var(--ohc-gris);
}

.ohc__form {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.ohc__input {
    flex: 1 1 260px;
    min-width: 0;
    padding: 12px 14px;
    border: 1px solid var(--ohc-border);
    border-radius: 10px;
    font: 500 16px/1.3 var(--ohc-mono);
}

.ohc__input:focus {
    outline: 2px solid var(--ohc-blue);
    outline-offset: 1px;
}

.ohc__btn {
    padding: 12px 22px;
    border: 0;
    border-radius: 10px;
    background: var(--ohc-noir);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}

.ohc__btn:hover {
    background: var(--ohc-blue);
}

.ohc__btn:disabled {
    opacity: .6;
    cursor: wait;
}

.ohc__status {
    min-height: 1.3em;
    margin: 14px 0 0;
    font-weight: 600;
}

.ohc__status.is-err {
    color: var(--ohc-err);
}

.ohc__status.is-loading::before {
    content: '';
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 8px;
    border: 2px solid color-mix(in srgb, var(--ohc-blue) 25%, white);
    border-top-color: var(--ohc-blue);
    border-radius: 50%;
    vertical-align: -3px;
    animation: ohc-spin .8s linear infinite;
}

@keyframes ohc-spin {
    to { transform: rotate(360deg); }
}

.ohc__chain {
    margin: 12px 0 0;
    padding: 0;
    list-style: none;
}

.ohc__step {
    position: relative;
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 12px 14px;
    border: 1px solid var(--ohc-border);
    border-radius: 10px;
    margin-bottom: 18px;
}

.ohc__step + .ohc__step::before {
    content: '↓';
    position: absolute;
    top: -19px;
    left: 30px;
    color: var(--ohc-gris);
    font-size: 14px;
}

.ohc__code {
    flex: none;
    min-width: 52px;
    padding: 6px 8px;
    border-radius: 8px;
    color: #fff;
    font: 700 16px var(--ohc-mono);
    text-align: center;
}

.ohc__step.is-ok .ohc__code { background: var(--ohc-ok); }
.ohc__step.is-redir .ohc__code { background: var(--ohc-blue); }
.ohc__step.is-err .ohc__code { background: var(--ohc-err); }

.ohc__body {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.ohc__url {
    font: 13px var(--ohc-mono);
    color: var(--ohc-gris);
    overflow-wrap: anywhere;
}

.ohc__body em {
    font-style: normal;
    font-size: 12px;
    color: var(--ohc-gris);
}

.ohc__verdict {
    margin: 4px 0 0;
    padding: 12px 14px;
    border-radius: 10px;
    font-weight: 600;
}

.ohc__verdict.is-ok { background: color-mix(in srgb, var(--ohc-ok) 10%, white); color: var(--ohc-ok); }
.ohc__verdict.is-warn { background: color-mix(in srgb, var(--ohc-warn) 10%, white); color: var(--ohc-warn); }
.ohc__verdict.is-err { background: color-mix(in srgb, var(--ohc-err) 8%, white); color: var(--ohc-err); }

.ohc--hero {
    margin: 0;
    padding: 36px 40px;
    border-color: color-mix(in srgb, var(--ohc-blue) 18%, white);
    background: linear-gradient(180deg, color-mix(in srgb, var(--ohc-blue) 5%, white) 0, #fff 220px);
    box-shadow: 0 10px 30px rgba(10, 10, 10, .06);
}

.ohc--hero .ohc__title {
    font-size: 1.75rem;
}

@media (max-width: 640px) {
    .ohc,
    .ohc--hero {
        padding: 22px 16px;
    }
}
