/* =============================================
   HH Lead Capture — Form Styles
   ============================================= */

/* Reset within our scope */
.hh-lead-form-wrap,
.hh-lead-form-wrap * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.hh-lead-form-wrap {
    max-width: 780px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    color: #222;
    line-height: 1.5;
}

/* ----- Hidden state ----- */
.hh-hidden {
    display: none !important;
}

/* =============================================
   Steps
   ============================================= */
.hh-step {
    margin-bottom: 32px;
    animation: hhFadeSlide 0.4s ease-out;
}

@keyframes hhFadeSlide {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

.hh-step-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.hh-step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: #c41230;
    color: #fff;
    border-radius: 50%;
    font-weight: 700;
    font-size: 15px;
    flex-shrink: 0;
}

.hh-step-header h3 {
    font-size: 20px;
    font-weight: 700;
    color: #111;
}

/* =============================================
   Cards — shared
   ============================================= */
.hh-card {
    position: relative;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    overflow: hidden;
}

.hh-card:hover {
    border-color: #999;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.hh-card.selected {
    border-color: #c41230;
    box-shadow: 0 0 0 3px rgba(196, 18, 48, 0.15), 0 6px 20px rgba(0, 0, 0, 0.08);
}

.hh-card-image {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    min-height: 100px;
    background: #fafafa;
}

.hh-card-image img {
    max-width: 100%;
    max-height: 140px;
    object-fit: contain;
}

.hh-card-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100px;
    font-size: 20px;
    font-weight: 700;
    color: #555;
    background: #f0f0f0;
    border-radius: 8px;
}

.hh-card-label {
    padding: 10px 16px;
    font-weight: 600;
    font-size: 15px;
    text-align: center;
    color: #333;
    background: #fff;
}

.hh-card-check {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 28px;
    height: 28px;
    background: #c41230;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.2s ease;
}

.hh-card.selected .hh-card-check {
    opacity: 1;
    transform: scale(1);
}

/* =============================================
   Brand cards — 2 columns
   ============================================= */
.hh-brand-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.hh-brand-card .hh-card-image {
    min-height: 120px;
    padding: 24px;
}

.hh-brand-card .hh-card-image img {
    max-height: 80px;
}

.hh-brand-card .hh-card-label {
    font-size: 18px;
    font-weight: 700;
    padding: 12px 16px;
}

/* =============================================
   Model cards — 3-col grid
   ============================================= */
.hh-model-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.hh-model-card .hh-card-image {
    min-height: 90px;
    padding: 12px;
}

.hh-model-card .hh-card-image img {
    max-height: 110px;
}

/* =============================================
   Contact form
   ============================================= */
.hh-form-row {
    margin-bottom: 16px;
}

.hh-form-row-2col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.hh-form-group {
    display: flex;
    flex-direction: column;
}

.hh-form-group label {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 6px;
    color: #333;
}

.hh-required {
    color: #c41230;
}

.hh-form-group input,
.hh-form-group select {
    padding: 12px 14px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    color: #222;
    background: #fff;
    transition: border-color 0.2s ease;
    width: 100%;
}

.hh-form-group input:focus,
.hh-form-group select:focus {
    outline: none;
    border-color: #c41230;
    box-shadow: 0 0 0 3px rgba(196, 18, 48, 0.1);
}

.hh-form-group input.hh-input-error,
.hh-form-group select.hh-input-error {
    border-color: #d32f2f;
}

.hh-error {
    font-size: 12px;
    color: #d32f2f;
    margin-top: 4px;
    min-height: 16px;
}

/* =============================================
   Submit button
   ============================================= */
.hh-submit-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 16px 32px;
    background: #c41230;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 18px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.1s ease;
    margin-top: 8px;
}

.hh-submit-btn:hover {
    background: #a60e28;
}

.hh-submit-btn:active {
    transform: scale(0.98);
}

.hh-submit-btn:disabled {
    background: #999;
    cursor: not-allowed;
    transform: none;
}

.hh-btn-loading svg {
    vertical-align: middle;
}

/* =============================================
   Success message
   ============================================= */
.hh-step-success {
    text-align: center;
    padding: 48px 24px;
    background: #f0faf0;
    border-radius: 16px;
    border: 2px solid #c8e6c9;
}

.hh-success-icon {
    width: 64px;
    height: 64px;
    background: #00a32a;
    color: #fff;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 16px;
}

.hh-step-success h3 {
    font-size: 24px;
    color: #1b5e20;
    margin-bottom: 8px;
}

.hh-step-success p {
    font-size: 16px;
    color: #555;
    max-width: 400px;
    margin: 0 auto 24px;
}

.hh-reset-btn {
    display: inline-block;
    padding: 10px 24px;
    background: #fff;
    color: #333;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
}

.hh-reset-btn:hover {
    border-color: #999;
    background: #fafafa;
}

/* =============================================
   Error banner
   ============================================= */
.hh-form-error {
    background: #fdeaea;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 16px;
}

.hh-form-error p {
    color: #c62828;
    font-size: 14px;
    font-weight: 500;
}

/* =============================================
   Responsive
   ============================================= */
@media (max-width: 640px) {
    .hh-lead-form-wrap {
        padding: 0 4px;
    }

    .hh-brand-cards {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .hh-model-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .hh-form-row-2col {
        grid-template-columns: 1fr;
    }

    .hh-step-header h3 {
        font-size: 17px;
    }

    .hh-submit-btn {
        font-size: 16px;
        padding: 14px 24px;
    }

    .hh-brand-card .hh-card-image {
        min-height: 80px;
        padding: 16px;
    }

    .hh-brand-card .hh-card-image img {
        max-height: 50px;
    }
}

@media (max-width: 400px) {
    .hh-model-grid {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .hh-card-label {
        font-size: 13px;
        padding: 8px 10px;
    }
}
