:root {
    --bg: #eef1f5;
    --card: #ffffff;
    --line: #d7dde6;
    --line-strong: #bfd1e6;
    --text: #132238;
    --muted: #64748b;
    --navy: #0d1730;
    --navy-2: #101a33;
    --blue: #0b67ff;
    --blue-soft: #eff5ff;
    --danger: #e5484d;
    --success: #0f9d58;
    --shadow: 0 8px 22px rgba(13, 23, 48, 0.06);
    --radius: 18px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Santander Text', Arial, Helvetica, sans-serif;
    line-height: 1.4;
}

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

.topbar {
    background: var(--navy);
    color: #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,.08);
}
.topbar-inner {
    max-width: 1060px;
    margin: 0 auto;
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 16px;
}
.brand-logo { width: 84px; height: auto; display: block; }
.brand-divider { width: 1px; height: 22px; background: rgba(255,255,255,.28); }
.topbar-title {
    font-family: 'Santander Headline', 'Santander Text', Arial, sans-serif;
    font-size: 14px;
    font-weight: 700;
}

.page { max-width: 1060px; margin: 0 auto; padding: 18px; }
.page.narrow { max-width: 760px; }
.page-form { max-width: 900px; padding-top: 14px; }

.brand-header {
    background: var(--navy);
    color: #fff;
    border-radius: 0 0 12px 12px;
    margin: -18px -18px 18px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
}
.brand-header.compact { margin-bottom: 18px; }
.brand-kicker { display: block; font-size: 12px; opacity: .8; margin-bottom: 2px; }
.brand-title { display: block; font-family: 'Santander Headline', 'Santander Text', sans-serif; font-size: 20px; }
.brand-subtitle { margin: 4px 0 0; color: rgba(255,255,255,.75); font-size: 14px; }

.quote-form { display: block; }
.card, .card-lite, .section-card, .form-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.card, .card-lite { padding: 20px; }

.intro-card {
    padding: 18px 22px;
    margin-bottom: 14px;
}
.pill {
    display: inline-flex;
    align-items: center;
    height: 22px;
    padding: 0 10px;
    border-radius: 999px;
    background: #eef3ff;
    color: #3562c4;
    font-size: 11px;
    font-weight: 700;
}
.intro-card h1 {
    margin: 8px 0 6px;
    font-family: 'Santander Headline', 'Santander Text', sans-serif;
    font-size: 32px;
    line-height: 1.1;
}
.intro-card p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    max-width: 720px;
}

.section-card {
    margin-bottom: 14px;
    padding: 14px 18px 18px;
}
.active-card {
    border-color: #9dc0e7;
    box-shadow: 0 0 0 2px rgba(11, 103, 255, .08), var(--shadow);
}
.section-head {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
}
.section-number {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--navy);
    color: #fff;
    display: inline-grid;
    place-items: center;
    font-size: 12px;
    font-weight: 700;
    flex: 0 0 auto;
    margin-top: 2px;
}
.section-head h2 {
    margin: 0;
    font-size: 18px;
    line-height: 1.1;
    font-family: 'Santander Headline', 'Santander Text', sans-serif;
}
.section-head p {
    margin: 3px 0 0;
    color: var(--muted);
    font-size: 12px;
}

.grid { display: grid; gap: 12px; }
.grid.one { grid-template-columns: minmax(0, 1fr); }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid.two-three { grid-template-columns: 1.1fr .9fr; }
.grid-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: end;
}
.full { grid-column: 1 / -1; }
.compact-grid { margin-top: 12px; }

.field {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: #24354f;
}
.field small {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 400;
}
input, select, textarea {
    width: 100%;
    margin-top: 6px;
    border: 1px solid #c7d0db;
    border-radius: 10px;
    background: #fff;
    color: var(--text);
    padding: 10px 12px;
    font-family: 'Santander Text', Arial, sans-serif;
    font-size: 14px;
    transition: border-color .15s ease, box-shadow .15s ease;
}
textarea { resize: vertical; min-height: 86px; }
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #6ea6ff;
    box-shadow: 0 0 0 3px rgba(11, 103, 255, .12);
}

.delivery-box {
    margin-top: 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 12px;
}
.delivery-title { font-size: 12px; font-weight: 700; margin-bottom: 10px; color: #24354f; }
.delivery-options { display: flex; gap: 10px; flex-wrap: wrap; }
.delivery-options.split-two > * { flex: 1 1 280px; }
.choice-card {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 46px;
    padding: 0 14px;
    border: 1px solid #c7d0db;
    border-radius: 10px;
    background: #fff;
    font-size: 13px;
    font-weight: 700;
    color: #24354f;
    cursor: pointer;
}
.choice-card input { width: auto; margin: 0; }
.choice-card:has(input:checked) {
    border-color: #9ec1ff;
    background: #f5f9ff;
}

.file-block { border: 0; padding: 0; margin: 0; }
.simple-upload {
    position: relative;
    border: 1.5px dashed #b8c4d3;
    border-radius: 12px;
    min-height: 132px;
    background: #fafbfc;
    text-align: center;
    display: grid;
    place-items: center;
    padding: 20px;
}
.simple-upload input[type='file'] {
    position: absolute;
    inset: 0;
    opacity: 0;
    margin: 0;
    cursor: pointer;
}
.simple-upload.is-dragover {
    border-color: #6ea6ff;
    background: #f3f8ff;
}
.upload-title {
    font-size: 15px;
    font-weight: 700;
    color: #24354f;
}
.upload-note {
    margin-top: 3px;
    color: var(--muted);
    font-size: 12px;
}
.upload-button-fake {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 30px;
    padding: 0 16px;
    border-radius: 999px;
    background: var(--navy);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    margin-top: 10px;
}
.selected-file {
    margin-top: 10px;
    color: var(--blue);
    font-size: 12px;
    font-weight: 700;
    word-break: break-all;
}
.file-actions {
    margin-top: 10px;
    display: flex;
    gap: 14px;
    align-items: center;
}

.hidden { display: none !important; }

.form-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 14px;
    padding-bottom: 10px;
}
.footer-note {
    margin: 0;
    font-size: 11px;
    color: #e25b62;
    text-align: center;
    flex: 1;
}

button, .as-link, .btn-primary, .btn-dark, .secondary, .primary {
    border: 0;
    border-radius: 999px;
    padding: 10px 18px;
    font-family: 'Santander Text', Arial, sans-serif;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform .14s ease, opacity .14s ease, background .14s ease;
}
button:hover, .as-link:hover, .btn-primary:hover, .btn-dark:hover, .secondary:hover, .primary:hover { transform: translateY(-1px); text-decoration: none; }
.btn-primary, .primary {
    background: var(--blue);
    color: #fff;
    min-width: 146px;
    box-shadow: 0 8px 18px rgba(11, 103, 255, .22);
}
.btn-primary:hover, .primary:hover { background: #0053db; }
.btn-dark {
    background: var(--navy);
    color: #fff;
    height: 40px;
    padding-inline: 18px;
}
.secondary {
    background: #ebeff4;
    color: #233651;
}
.btn-link, .link {
    background: transparent;
    color: var(--blue);
    padding: 0;
    border-radius: 0;
}
.danger { color: var(--danger); }
button:disabled { opacity: .6; cursor: not-allowed; transform: none; }

.alert {
    padding: 13px 16px;
    border-radius: 12px;
    border: 1px solid;
    margin-bottom: 14px;
    font-size: 14px;
}
.alert.error { background: #fff1f1; color: #9b1d20; border-color: #f5c2c7; }
.alert.success { background: #edfdf0; color: #166534; border-color: #bbf7d0; }
.alert.warning { background: #fffbeb; color: #92400e; border-color: #fde68a; }

.success-card { text-align: center; padding: 34px 26px; }
.check {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: #e9f9ee;
    color: var(--success);
    display: grid;
    place-items: center;
    font-size: 38px;
    font-weight: 700;
    margin: 0 auto 12px;
}
.success-card h1 { font-size: 30px; margin: 0 0 10px; font-family: 'Santander Headline', 'Santander Text', sans-serif; }
.success-card p { color: var(--muted); }
.folio-box {
    margin: 20px auto;
    max-width: 420px;
    border: 1px solid var(--line);
    background: #fafcff;
    border-radius: 14px;
    padding: 16px;
}
.folio-box span { display: block; color: var(--muted); font-size: 13px; margin-bottom: 7px; }
.folio-box strong { font-size: 28px; }

.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.status {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 12px;
    border-radius: 999px;
    background: #eef2f7;
    color: #364152;
    font-size: 12px;
    font-weight: 700;
}
.status.ok { background: #e9f9ee; color: #166534; }
.status.bad { background: #fff1f1; color: #9b1d20; }
.status.pending { background: #fff8e7; color: #8a6116; }

.table-wrap { overflow-x: auto; }
table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 14px;
}
thead th {
    text-align: left;
    background: #f8fafc;
    color: #475569;
    padding: 12px 10px;
    border-bottom: 1px solid var(--line);
}
tbody td {
    padding: 12px 10px;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
}

@media (max-width: 860px) {
    .grid.three, .grid.four, .grid.two, .grid.two-three { grid-template-columns: minmax(0,1fr); }
    .grid-search { grid-template-columns: minmax(0,1fr); }
    .form-actions { flex-direction: column; align-items: stretch; }
    .footer-note { order: 2; }
    .btn-primary, .primary { width: 100%; }
}

@media (max-width: 640px) {
    .topbar-inner { padding: 12px 14px; }
    .brand-logo { width: 72px; }
    .page, .page-form { padding: 12px; }
    .intro-card h1 { font-size: 26px; }
    .section-card { padding: 14px; }
}
