.capture-page { width: 100%; max-width: 1380px; min-width: 0; margin: 0 auto; }

.capture-header {
    display: flex;
    width: 100%;
    min-width: 0;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    margin-bottom: 20px;
    padding: clamp(24px, 3vw, 34px);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    background: var(--color-surface);
    box-shadow: var(--shadow-sm);
}

.capture-title { min-width: 0; }
.capture-title h1 { margin: 4px 0 6px; color: var(--color-text); font-size: clamp(26px, 3vw, 34px); font-weight: 730; letter-spacing: -.035em; line-height: 1.16; }
.capture-title p { margin: 0; color: var(--color-muted); font-size: 14px; }
.capture-label { color: var(--color-accent); font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }

.wizard { display: flex; flex: 0 1 auto; min-width: 0; align-items: center; }
.wizard-item { display: flex; min-width: 88px; flex-direction: column; align-items: center; gap: 6px; color: #8c9996; font-size: 11px; text-align: center; }
.wizard-number { display: grid; width: 36px; height: 36px; place-items: center; border: 1px solid var(--color-border); border-radius: 50%; background: var(--color-surface-soft); font-size: 12px; font-weight: 750; }
.wizard-item.active { color: var(--color-brand); font-weight: 700; }
.wizard-item.active .wizard-number { border-color: var(--color-brand); background: var(--color-brand); color: #fff; box-shadow: 0 5px 14px rgba(20, 63, 58, .18); }
.wizard-line { flex: 0 1 58px; width: 58px; min-width: 22px; height: 2px; margin-bottom: 18px; background: var(--color-border); }
.wizard-line.active { background: var(--color-brand); }

.capture-form { width: 100%; min-width: 0; }

.form-card {
    width: 100%;
    min-width: 0;
    margin-bottom: 18px;
    padding: clamp(22px, 3vw, 34px);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    background: var(--color-surface);
    box-shadow: var(--shadow-sm);
}

.section-header { width: 100%; margin-bottom: 24px; padding-bottom: 18px; border-bottom: 1px solid var(--color-border); }
.section-header > div { display: flex; min-width: 0; align-items: center; gap: 14px; }
.section-number { display: grid; flex: 0 0 40px; width: 40px; height: 40px; place-items: center; border-radius: 12px; background: #e8efed; color: var(--color-brand); font-size: 12px; font-weight: 800; }
.section-header h2 { margin: 0 0 2px; color: var(--color-text); font-size: 19px; font-weight: 720; letter-spacing: -.015em; }
.section-header p { margin: 0; color: var(--color-muted); font-size: 12px; line-height: 1.45; }

.form-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; width: 100%; min-width: 0; }
.form-grid.two-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-group { display: flex; min-width: 0; flex-direction: column; gap: 7px; }
.form-group label { color: #3f4e4b; font-size: 12px; font-weight: 700; }

.form-control,
.money-input {
    width: 100%;
    min-width: 0;
    height: 46px;
    border: 1px solid var(--color-border);
    border-radius: 11px;
    background: var(--color-surface-soft);
    transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}

.form-control { padding: 0 13px; outline: 0; color: var(--color-text); font-size: 13px; }
.form-control:hover, .money-input:hover { border-color: #bdcbc7; }
.form-control:focus, .money-input:focus-within { border-color: #789791; background: #fff; box-shadow: 0 0 0 3px rgba(20, 63, 58, .09); }
.form-control::placeholder, .money-input input::placeholder { color: #9aa5a2; }
select.form-control { cursor: pointer; }

.money-input { display: flex; align-items: center; overflow: hidden; }
.money-input span { display: grid; align-self: stretch; padding: 0 13px; place-items: center; border-right: 1px solid var(--color-border); background: #edf2f0; color: var(--color-muted); font-size: 13px; font-weight: 700; }
.money-input input { width: 100%; min-width: 0; height: 100%; padding: 0 12px; border: 0; outline: 0; background: transparent; font-size: 13px; }

.validation-message { min-height: 14px; color: var(--color-danger); font-size: 11px; }
.validation-summary { margin: 0 0 16px; padding: 0; color: var(--color-danger); font-size: 13px; }
.validation-summary:empty, .validation-summary-valid { display: none; }
.validation-summary ul { margin: 0; padding: 12px 18px 12px 34px; border: 1px solid #f0c9c5; border-radius: 11px; background: #fff5f4; }
.input-validation-error { border-color: #d77b72 !important; background: #fff9f8 !important; }

.form-actions { display: flex; width: 100%; align-items: center; justify-content: flex-end; gap: 10px; padding: 6px 0 24px; }
.cancel-button, .continue-button { display: inline-flex; min-width: 164px; min-height: 46px; align-items: center; justify-content: center; gap: 9px; padding: 10px 20px; border-radius: 12px; font-size: 13px; font-weight: 700; text-decoration: none; cursor: pointer; transition: border-color .18s ease, background .18s ease, color .18s ease, transform .18s ease, box-shadow .18s ease; }
.cancel-button { border: 1px solid var(--color-border); background: #fff; color: var(--color-muted); }
.cancel-button:hover { border-color: #b8c7c3; color: var(--color-text); }
.continue-button { border: 1px solid var(--color-brand); background: var(--color-brand); color: #fff; box-shadow: 0 6px 16px rgba(20, 63, 58, .16); }
.continue-button:hover { background: var(--color-brand-strong); color: #fff; transform: translateY(-1px); }
.continue-button span { font-size: 17px; line-height: 1; }

.pedimento-guardado-card { display: flex; width: 100%; min-width: 0; align-items: center; gap: 18px; margin-bottom: 18px; padding: 24px 28px; border: 1px solid #bed8d1; border-radius: var(--radius-lg); background: #f2f8f6; box-shadow: var(--shadow-sm); }
.pedimento-guardado-icon { display: grid; flex: 0 0 48px; width: 48px; height: 48px; place-items: center; border-radius: 50%; background: var(--color-brand); color: #fff; font-size: 20px; font-weight: 800; }
.pedimento-guardado-content { display: flex; flex: 1 1 auto; min-width: 0; flex-direction: column; gap: 5px; }
.pedimento-guardado-label { color: #52756e; font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.pedimento-guardado-content label { color: var(--color-muted); font-size: 11px; font-weight: 650; }
.pedimento-id-display { width: 100%; max-width: 430px; height: 42px; padding: 0 12px; border: 1px solid #cbded9; border-radius: 10px; background: #fff; color: var(--color-text); font-size: 14px; font-weight: 750; }

@media (max-width: 1160px) {
    .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
    .capture-header { align-items: flex-start; flex-direction: column; }
    .wizard { width: 100%; justify-content: center; }
}

@media (max-width: 680px) {
    .form-grid, .form-grid.two-columns { grid-template-columns: 1fr; }
    .wizard { justify-content: flex-start; overflow-x: auto; padding-bottom: 5px; }
    .wizard-item { min-width: 72px; font-size: 10px; }
    .wizard-line { flex-basis: 30px; width: 30px; }
    .form-actions { align-items: stretch; flex-direction: column-reverse; }
    .cancel-button, .continue-button { width: 100%; }
}

@media (max-width: 440px) {
    .capture-header, .form-card { padding: 19px; border-radius: 18px; }
    .section-header > div { align-items: flex-start; }
    .section-number { flex-basis: 36px; width: 36px; height: 36px; }
    .section-header h2 { font-size: 17px; }
    .pedimento-guardado-card { align-items: flex-start; flex-direction: column; padding: 20px; border-radius: 18px; }
}
