/* ============================================================================
   Seller pages — /sell, /sell/register, /sell/dashboard
   Loaded alongside account.css (which supplies .form-field / .field-hint /
   .btn-block) and the global tokens in style.css.
   ============================================================================ */

.sell-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 2.5rem 1.25rem 4rem;
}
.sell-page--narrow { max-width: 620px; }

/* .btn-lg is defined here — the seller CTAs are the only oversized buttons
   on the site, so it doesn't belong in the global sheet. */
.btn-lg {
    padding: 0.85rem 2rem;
    font-size: 1.05rem;
}

/* --- Landing hero -------------------------------------------------------- */
.sell-hero {
    text-align: center;
    padding: 1rem 0 2.5rem;
    border-bottom: 1px solid var(--color-border);
    margin-bottom: 2.5rem;
}
.sell-eyebrow {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--color-brand-orange);
    margin: 0 0 0.75rem;
}
.sell-hero__title {
    font-size: clamp(1.75rem, 5vw, 2.5rem);
    font-weight: 800;
    line-height: 1.15;
    margin: 0 0 0.75rem;
    text-wrap: balance;
}
.sell-hero__subtitle {
    color: var(--color-text-muted);
    max-width: 46ch;
    margin: 0 auto 1.75rem;
    font-size: 1.02rem;
}
.sell-hero__note {
    font-size: 0.85rem;
    color: var(--color-text-light);
    margin: 0.85rem 0 0;
}

/* --- Sections ------------------------------------------------------------ */
.sell-section-title {
    font-size: 1.3rem;
    font-weight: 800;
    margin: 0 0 1.5rem;
}
.sell-steps, .sell-terms { margin-bottom: 3rem; }

.sell-steps__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 1.5rem;
}
@media (min-width: 700px) {
    .sell-steps__list { grid-template-columns: 1fr 1fr; gap: 1.75rem 2.5rem; }
}
.sell-step { display: flex; gap: 1rem; align-items: flex-start; }
.sell-step__num {
    flex: none;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: var(--color-brand-orange);
    color: var(--color-primary-light);
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}
.sell-step h3 { font-size: 1.02rem; font-weight: 700; margin: 0.25rem 0 0.35rem; }
.sell-step p { margin: 0; color: var(--color-text-muted); font-size: 0.94rem; }

/* --- Terms --------------------------------------------------------------- */
.sell-terms__list { margin: 0; display: grid; gap: 1px; background: var(--color-border); border: 1px solid var(--color-border); border-radius: var(--radius-lg); overflow: hidden; }
.sell-term { background: var(--color-primary-light); padding: 1rem 1.15rem; }
.sell-term dt { font-weight: 700; margin-bottom: 0.3rem; font-size: 0.95rem; }
.sell-term dd { margin: 0; color: var(--color-text-muted); font-size: 0.93rem; }

.sell-closing {
    text-align: center;
    background: var(--color-paper);
    border-radius: var(--radius-lg);
    padding: 2rem 1.5rem;
}
.sell-closing p { margin: 0 0 1.25rem; color: var(--color-text); }

/* --- Application form ---------------------------------------------------- */
.sell-form {
    background: var(--color-primary-light);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 1.75rem 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.sell-form__title { font-size: 1.5rem; font-weight: 800; margin: 0; }
.sell-form__subtitle { color: var(--color-text-muted); margin: 0 0 0.5rem; font-size: 0.95rem; }
.sell-form__foot {
    font-size: 0.85rem;
    color: var(--color-text-light);
    text-align: center;
    margin: 0;
}

.sell-fieldset {
    border: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.sell-fieldset legend {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    padding: 0;
    margin-bottom: 0.25rem;
}
.sell-fieldset__note {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    background: var(--color-bg-alt);
    border-radius: var(--radius-md);
    padding: 0.6rem 0.8rem;
    margin: 0;
}

.sell-consent {
    display: flex;
    gap: 0.6rem;
    align-items: flex-start;
    font-size: 0.9rem;
    color: var(--color-text-muted);
    cursor: pointer;
}
.sell-consent input { margin-top: 0.2rem; flex: none; }

.sell-error {
    display: none;
    background: #fdecea;
    border: 1px solid #f5b5ae;
    color: #8a1c12;
    border-radius: var(--radius-md);
    padding: 0.6rem 0.8rem;
    font-size: 0.9rem;
}
.sell-error.is-visible { display: block; }
.sell-form .is-invalid { border-color: var(--palette-badge-red); }

/* --- Dashboard ----------------------------------------------------------- */
.sell-dash__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
}
.sell-dash__shop { font-size: 1.5rem; font-weight: 800; margin: 0; }
.sell-dash__foot { margin-top: 2rem; font-size: 0.9rem; }

/* Status is encoded in colour AND text, never colour alone. */
.sell-badge, .sell-status {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 0.3rem 0.75rem;
    border-radius: var(--radius-full);
    border: 1px solid transparent;
}
.sell-badge--pending, .sell-status--pending {
    background: #fdf3e0; color: #8a5a12; border-color: #e8cfa1;
}
.sell-badge--active, .sell-status--active {
    background: #e8f6ed; color: var(--color-positive); border-color: #a9dcbd;
}
.sell-badge--rejected, .sell-status--rejected,
.sell-badge--suspended, .sell-status--suspended {
    background: #fdecea; color: #8a1c12; border-color: #f5b5ae;
}
.sell-status { margin-bottom: 1.25rem; }

.sell-panel {
    background: var(--color-primary-light);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 1.25rem;
}
.sell-panel h2 { font-size: 1.1rem; font-weight: 700; margin: 0 0 0.6rem; }
.sell-panel p { margin: 0 0 0.5rem; color: var(--color-text-muted); font-size: 0.94rem; }
.sell-panel p:last-child { margin-bottom: 0; }
.sell-panel--wait { border-left: 4px solid var(--color-brand-orange); }
.sell-panel--stop { border-left: 4px solid #c0392b; }
.sell-reason {
    background: var(--color-bg-alt);
    border-radius: var(--radius-md);
    padding: 0.6rem 0.8rem;
    color: var(--color-text) !important;
}
.sell-soon { font-size: 0.85rem; color: var(--color-text-light) !important; }

.sell-stats { display: flex; gap: 1rem; margin-bottom: 1.25rem; flex-wrap: wrap; }
.sell-stat {
    flex: 1 1 140px;
    background: var(--color-primary-light);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 1rem 1.15rem;
}
.sell-stat__num {
    display: block;
    font-size: 1.5rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}
.sell-stat__label { font-size: 0.82rem; color: var(--color-text-muted); }

/* --- Two-column rows in the listing form -------------------------------- */
.sell-row { display: grid; gap: 1rem; }
@media (min-width: 520px) { .sell-row { grid-template-columns: 1fr 1fr; } }

/* --- Photo upload preview ------------------------------------------------ */
.listing-photo-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.6rem;
}
.listing-photo-thumb {
    width: 72px;
    height: 72px;
    object-fit: cover;
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
}

/* --- Dashboard listing list --------------------------------------------- */
.sell-panel__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}
.sell-panel__head h2 { margin: 0; }

.listing-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.75rem; }
.listing-row {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.6rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
}
.listing-row__thumb {
    flex: none;
    width: 56px;
    height: 56px;
    border-radius: var(--radius-sm);
    background: var(--color-bg-alt);
    overflow: hidden;
}
.listing-row__thumb img { width: 100%; height: 100%; object-fit: cover; }
.listing-row__body { flex: 1; display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; }
.listing-row__title { font-weight: 600; font-size: 0.95rem; }
.listing-row__price { font-size: 0.9rem; color: var(--color-text-muted); font-variant-numeric: tabular-nums; }
.listing-row__reason { font-size: 0.82rem; color: #8a1c12; }

.listing-badge {
    flex: none;
    font-size: 0.74rem;
    font-weight: 700;
    padding: 0.25rem 0.6rem;
    border-radius: var(--radius-full);
    border: 1px solid transparent;
    white-space: nowrap;
}
.listing-badge--draft    { background: var(--color-bg-alt); color: var(--color-text-muted); border-color: var(--color-border); }
.listing-badge--pending  { background: #fdf3e0; color: #8a5a12; border-color: #e8cfa1; }
.listing-badge--live     { background: #e8f6ed; color: var(--color-positive); border-color: #a9dcbd; }
.listing-badge--sold     { background: #eef1fb; color: #3651a3; border-color: #b9c5ec; }
.listing-badge--rejected,
.listing-badge--removed  { background: #fdecea; color: #8a1c12; border-color: #f5b5ae; }

/* --- Dashboard: sales ------------------------------------------------------ */
.sale-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--spacing-md); }
.sale-row { padding: var(--spacing-md); border: 1px solid var(--color-border); border-radius: var(--radius-md); }
.sale-row__head { display: flex; justify-content: space-between; gap: var(--spacing-sm); font-weight: 700; }
.sale-row__order { font-size: 0.8rem; color: var(--color-text-muted); }
.sale-row__note { margin: var(--spacing-sm) 0 0; color: var(--color-text-muted); }
.sale-row__ship { margin-top: var(--spacing-sm); padding: var(--spacing-sm); background: var(--color-bg-alt); border-radius: var(--radius-sm); font-size: 0.95rem; }
.sale-ship-form { margin-top: var(--spacing-sm); display: grid; gap: var(--spacing-sm); }
.sale-row__payout { margin: var(--spacing-sm) 0 0; font-size: 0.9rem; font-weight: 600; }
.sale-row__payout--paid { color: var(--color-positive); }
.listing-row__withdraw { font-size: 0.8rem; }
