/* =====================================================================
   Listing Wizard Styles
   ===================================================================== */

/* Radio Cards */
.radio-card {
    display: block;
    border: 2px solid #dee2e6;
    border-radius: 0.5rem;
    padding: 0.875rem 1rem;
    cursor: pointer;
    transition: border-color 0.2s ease, background-color 0.2s ease;
    height: 100%;
}

.radio-card:hover {
    border-color: var(--rule-strong);
    background-color: var(--paper-tint);
}

.radio-card.selected {
    border-color: var(--state-current);
    background-color: var(--paper-tint);
}

.radio-card-sm {
    padding: 0.625rem 0.875rem;
    font-size: 0.9rem;
}

/* Multi-select sibling of .radio-card, for questions where more than one answer
   can be true (the signup interest picker). Two differences from the radio
   version, both deliberate:
     - the checkbox stays visible, because a tinted card alone doesn't tell you
       whether you may pick more than one;
     - the selected state comes from :has() instead of listing-wizard.js, so the
       component works on pages that don't load that script. Without :has()
       support the checkbox still reads as checked; only the tint is lost. */
.check-card {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin: 0;
}

.check-card .form-check-input {
    flex: 0 0 auto;
    margin: 0.2rem 0 0;
}

.check-card__body {
    display: flex;
    align-items: flex-start;
}

.check-card:has(.form-check-input:checked) {
    border-color: var(--state-current);
    background-color: var(--paper-tint);
}

.check-card:has(.form-check-input:focus-visible) {
    border-color: var(--state-current);
    box-shadow: var(--focus-ring);
}

/* Progress Bar Step Dots */
.wizard-step-dot {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    border: 2px solid #dee2e6;
    color: #6c757d;
    background: #fff;
    transition: all 0.3s ease;
}

.wizard-step-dot.active {
    border-color: var(--state-current);
    color: var(--state-current);
    background: var(--paper-sunken);
}

.wizard-step-dot.completed {
    border-color: var(--state-current);
    color: #fff;
    background: var(--state-current);
}

.wizard-step-label {
    flex: 1;
    min-width: 0;
}

/* Entry Choice Cards */
.wizard-entry-card {
    border: 2px solid #dee2e6 !important;
    background: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

.wizard-entry-card:hover {
    border-color: var(--rule-strong) !important;
    box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.08);
}

button.wizard-entry-card {
    appearance: none;
    -webkit-appearance: none;
}

/* Recommendation Card (Phase 2) */
.recommendation-card {
    animation: wizardFadeIn 0.5s ease;
}

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

/* Live Summary Card (Phase 4) — sticky on desktop */
.wizard-summary-card {
    position: sticky;
    top: 1rem;
}

/* Seller Snapshot (Phase 4) — donut + legend */
.wizard-donut {
    position: relative;
    width: 180px;
    height: 180px;
    margin: 1rem auto 1.25rem;
}

.wizard-donut .donut-ring {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: conic-gradient(
        var(--series-2, #a8801f) 0 var(--cfPct, 0%),
        var(--series-1, #3b4fa0) var(--cfPct, 0%) 100%
    );
    transition: background 0.4s ease;
    position: relative;
}

.wizard-donut .donut-ring::after {
    content: '';
    position: absolute;
    inset: 22%;
    background: #fff;
    border-radius: 50%;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.04);
}

.donut-legend {
    font-size: 0.875rem;
}

.donut-legend .sq {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 2px;
    margin-right: 0.4rem;
    vertical-align: -1px;
}

.donut-legend .sq.cf { background: var(--series-2, #a8801f); }
.donut-legend .sq.bo { background: var(--series-1, #3b4fa0); }

/* Snapshot empty state */
#wizSnapEmpty {
    min-height: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Photo Preview */
.wizard-photo-preview {
    display: inline-block;
}

.wizard-photo-thumb {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    border-radius: 0.375rem;
    background: #e9ecef;
    font-size: 0.7rem;
    overflow: hidden;
    text-align: center;
    padding: 0.25rem;
}

/* Carrying Costs Conditional Block — slide animation */
#carryingCostsBlock {
    overflow: hidden;
    transition: max-height 0.4s ease, opacity 0.3s ease;
}

/* Acknowledgment checkbox (larger) */
.form-check-lg .form-check-input {
    width: 1.5em;
    height: 1.5em;
    margin-top: 0.15em;
}

.form-check-lg .form-check-label {
    padding-left: 0.5em;
    line-height: 1.5;
}

/* Renewal/Incentive fields slide */
#renewalFields,
#incentiveFields {
    overflow: hidden;
    transition: max-height 0.3s ease;
}

/* Responsive adjustments */
@media (max-width: 767.98px) {
    .wizard-summary-card {
        position: static;
    }

    .wizard-step-dot {
        width: 24px;
        height: 24px;
        font-size: 0.65rem;
    }
}
