/**
 * RUNTPRO Vehicle Check — runtpro.css v9.0.2
 * Loaded ONLY on pages using [runtcheck] shortcode.
 * BEM-style class naming to avoid theme conflicts.
 */

/* ═══════════════════════════════════════
   TRIGGER BUTTON
═══════════════════════════════════════ */
.runtpro-trigger-wrap {
    max-width: 860px;
    margin: 0 auto;
}

.runtpro-trigger-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: fit-content;
    max-width: 100%;
    min-height: 44px;
    box-sizing: border-box;
    margin: 0 auto;
    padding: 11px 22px;
    background: var(--runtpro-trigger-bg, linear-gradient(90deg, #ffd700, #f6c90e));
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 15px;
    line-height: 1.4;
    text-align: center;
    font-weight: 700;
    color: var(--runtpro-trigger-text, #1a202c);
    box-shadow: 0 2px 8px var(--runtpro-trigger-shadow, rgba(246, 201, 14, 0.5));
    transition: transform 0.2s, box-shadow 0.2s;
    letter-spacing: 0.01em;
}

.runtpro-trigger-btn:hover,
.runtpro-trigger-btn:focus-visible {
    background: var(--runtpro-trigger-hover, linear-gradient(90deg, #ffd700, #f6c90e));
    color: var(--runtpro-trigger-text, #1a202c);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px var(--runtpro-trigger-shadow-hover, rgba(246, 201, 14, 0.65));
    outline: none;
}

.runtpro-trigger-btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* ═══════════════════════════════════════
   SHELL (browser frame)
═══════════════════════════════════════ */
.runtpro-wrap {
    max-width: 860px;
    margin: 0 auto;
}

.runtpro-shell {
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.18);
    font-family: 'Inter', system-ui, sans-serif;
    animation: runtpro-open 0.35s ease both;
}

@keyframes runtpro-open {
    from { opacity: 0; transform: translateY(-10px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ═══════════════════════════════════════
   URL BAR
═══════════════════════════════════════ */
.runtpro-urlbar {
    background: #f0f2f5;
    border-bottom: 1px solid #dde1e8;
    padding: 8px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.runtpro-urlbar__lock {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    color: #34a853;
    font-size: 11px;
    font-weight: 600;
}

.runtpro-urlbar__lock svg {
    width: 14px;
    height: 14px;
    fill: #34a853;
}

.runtpro-urlbar__url {
    flex: 1;
    background: #fff;
    border: 1px solid #dde1e8;
    border-radius: 20px;
    padding: 5px 14px;
    font-size: 12px;
    color: #444;
    font-family: 'Roboto Mono', 'Courier New', monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.runtpro-urlbar__url:hover {
    border-color: #1a3a8c;
    background: #f0f4ff;
}

.runtpro-urlbar__hint {
    font-size: 10px;
    color: #888;
    white-space: nowrap;
    flex-shrink: 0;
}

/* URL responsive: show short on mobile, full on desktop */
.runtpro-urlbar__url .url-short { display: none; }
.runtpro-urlbar__url .url-full  { display: inline; }

@media (max-width: 480px) {
    .runtpro-urlbar__url .url-short { display: inline; }
    .runtpro-urlbar__url .url-full  { display: none; }
    .runtpro-urlbar__hint           { display: none; }
}

.runtpro-urlbar__url.is-expanded .url-short { display: none; }
.runtpro-urlbar__url.is-expanded .url-full  { display: inline; }

/* ═══════════════════════════════════════
   WIDGET
═══════════════════════════════════════ */
.runtpro-widget {
    background: #fff;
    color: #1a1a2e;
}

/* Header */
.runtpro-hdr {
    background: #1a3a8c;
    padding: 16px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.runtpro-logo {
    font-size: 26px;
    font-weight: 900;
    color: #fff;
    letter-spacing: -0.5px;
}

.runtpro-logo em {
    color: #e8006e;
    font-style: normal;
}

.runtpro-hdr__badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    opacity: 0.8;
}

.runtpro-hdr__badge svg  { width: 24px; height: 24px; fill: #fff; }
.runtpro-hdr__badge span { font-size: 9px; color: rgba(255,255,255,0.7); letter-spacing: 0.5px; }

/* Title */
.runtpro-title {
    padding: 20px 22px 16px;
    border-bottom: 2px solid #b0004e;
}

.runtpro-title p {
    font-size: 22px;
    font-weight: 700;
    color: #1a3a8c;
    margin: 0;
    text-align: left;
}

.runtpro-title p strong {
    font-weight: 700;
}

/* Body layout */
.runtpro-body {
    display: flex;
    flex-direction: column;
}

.runtpro-col-info { order: 2; padding: 0 22px 24px; }
.runtpro-col-form { order: 1; }

@media (min-width: 640px) {
    .runtpro-body {
        flex-direction: row;
        align-items: flex-start;
    }
    .runtpro-col-info {
        order: 1;
        width: 38%;
        min-width: 190px;
        padding: 24px 20px 24px 22px;
        flex-shrink: 0;
    }
    .runtpro-col-form {
        order: 2;
        flex: 1;
        min-width: 0;
        border-left: 1px solid #eaecf0;
    }
    .runtpro-col-form .runtpro-card {
        margin: 16px 18px;
    }
}

/* Info + Banner */
.runtpro-col-info p {
    font-size: 14px;
    color: #444;
    line-height: 1.7;
    margin: 0 0 20px;
}

.runtpro-banner {
    border-radius: 14px;
    overflow: hidden;
    background: #e8e8e8;
    display: flex;
    align-items: stretch;
    min-height: 160px;
    box-shadow: 0 4px 20px rgba(176,0,78,0.18);
}

.runtpro-banner__graphic {
    flex: 1.1;
    display: flex;
    align-items: flex-end;
    padding: 0 0 0 10px;
    overflow: hidden;
    position: relative;
}

.runtpro-banner__graphic::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #c0392b 0%, #8b0000 60%, transparent 100%);
    border-radius: 0 40% 40% 0;
    z-index: 0;
}

.runtpro-banner__graphic svg {
    width: 130px;
    height: 80px;
    fill: rgba(255,255,255,0.22);
    position: relative;
    z-index: 1;
}

.runtpro-banner__text {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 18px 16px 18px 12px;
}

.runtpro-banner__text .banner-sub  { font-size: 13px; color: #555; margin-bottom: 2px; }
.runtpro-banner__text .banner-main { font-size: 19px; font-weight: 800; color: #1a1a2e; line-height: 1.2; margin-bottom: 14px; }
.runtpro-banner__text .banner-btn  {
    display: inline-block;
    background: #fff;
    color: #b0004e;
    font-size: 17px;
    font-weight: 700;
    font-style: italic;
    padding: 7px 28px;
    border-radius: 50px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}

/* Card */
.runtpro-card {
    background: #fff;
    border: 1.5px solid #e8eaf0;
    border-radius: 10px;
    padding: 20px 18px;
    margin: 18px 22px;
}

/* Form fields */
.runtpro-field        { margin-bottom: 18px; }
.runtpro-field:last-child { margin-bottom: 0; }

.runtpro-label {
    display: block;
    font-size: 13.5px;
    font-weight: 600;
    color: #222;
    margin-bottom: 7px;
}

.runtpro-label .req { color: #e8006e; margin-left: 2px; }

.runtpro-widget input[type="text"],
.runtpro-widget select {
    display: block;
    width: 100%;
    height: 52px;
    border: 1.5px solid #cdd1da;
    border-radius: 8px;
    padding: 0 20px;
    font-size: 15px;
    font-family: 'Inter', system-ui, sans-serif;
    color: #1a1a2e;
    background: #fff;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    -webkit-appearance: none;
    appearance: none;
    box-sizing: border-box;
}

.runtpro-widget select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23555' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 16px;
    padding-right: 44px;
    cursor: pointer;
}

.runtpro-widget input:focus,
.runtpro-widget select:focus {
    border-color: #1a3a8c;
    box-shadow: 0 0 0 3px rgba(26, 58, 140, 0.12);
}

.runtpro-widget input.is-error {
    border-color: #e8006e;
    box-shadow: 0 0 0 3px rgba(232, 0, 110, 0.1);
}

.runtpro-widget input::placeholder { color: #bbb; font-weight: 300; }

.runtpro-hint {
    font-size: 12px;
    color: #888;
    margin: 6px 0 0 2px;
}

/* Captcha */
.runtpro-captcha {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.runtpro-captcha__img {
    flex: 1;
    height: 72px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    background: #f9f9f9;
    display: block;
    max-width: 100%;
    object-fit: contain;
}

.runtpro-captcha__refresh {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    background: #f3f4f6;
    border: 1.5px solid #e0e3ea;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    padding: 0;
}

.runtpro-captcha__refresh:hover,
.runtpro-captcha__refresh:focus-visible {
    background: #e0e7ff;
    color: #1a3a8c;
    border-color: #1a3a8c;
    outline: none;
}

.runtpro-captcha__refresh svg         { width: 18px; height: 18px; fill: currentColor; }
.runtpro-captcha__refresh.is-loading svg { animation: runtpro-spin 1s linear infinite; }

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

/* Submit button */
.runtpro-btnrow {
    display: flex;
    justify-content: flex-end;
    margin-top: 20px;
}

.runtpro-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 50px;
    padding: 0 32px;
    background: #b0004e;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    font-family: 'Inter', system-ui, sans-serif;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(176, 0, 78, 0.35);
    transition: background 0.2s, box-shadow 0.2s, transform 0.1s;
}

.runtpro-btn:hover,
.runtpro-btn:focus-visible {
    background: #920040;
    box-shadow: 0 6px 18px rgba(176, 0, 78, 0.45);
    outline: none;
}

.runtpro-btn:active { transform: scale(0.98); }
.runtpro-btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* Footer */
.runtpro-footer {
    background: #1a3a8c;
    padding: 11px 22px;
    font-size: 11px;
    color: rgba(255,255,255,0.55);
    text-align: center;
}

.runtpro-footer strong { color: rgba(255,255,255,0.85); }

/* ═══════════════════════════════════════
   TOAST NOTIFICATION
═══════════════════════════════════════ */
.runtpro-toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    max-width: 360px;
    padding: 14px 20px;
    border-radius: 10px;
    background: #1f2937;
    color: #fff;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 999999;
    pointer-events: none;
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.runtpro-toast.is-visible  { opacity: 1; transform: translateY(0); }
.runtpro-toast.is-error    { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; border-left: 4px solid #ef4444; }
.runtpro-toast.is-success  { background: #f0fdf4; color: #166534; border: 1px solid #bbf7d0; border-left: 4px solid #22c55e; }

.runtpro-toast__icon       { flex-shrink: 0; width: 20px; height: 20px; display: flex; }
.runtpro-toast__icon svg   { width: 20px; height: 20px; }
.runtpro-toast.is-error   .runtpro-toast__icon svg { fill: #ef4444; }
.runtpro-toast.is-success .runtpro-toast__icon svg { fill: #22c55e; }

/* ═══════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════ */
@media (max-width: 639px) {
    .runtpro-shell  { border-radius: 6px; }
    .runtpro-hdr    { padding: 12px 16px; }
    .runtpro-logo   { font-size: 20px; }
    .runtpro-title  { padding: 14px 16px 12px; }
    .runtpro-title p { font-size: 19px; text-align: center; }
    .runtpro-card   { margin: 14px 16px; }
    .runtpro-btnrow { justify-content: stretch; margin-top: 20px; }
    .runtpro-btn    { width: 100%; justify-content: center; }
    .runtpro-captcha { flex-direction: column; align-items: stretch; }
    .runtpro-captcha__refresh { align-self: center; }
    .runtpro-toast  { left: 16px; right: 16px; bottom: 16px; max-width: none; border-radius: 8px; }
}
