/* ===========================================================================
   EasyQuotes — folha de estilos única.
   Ordem preservada do original: (1) base/design-system legado — ainda usado
   por elementos renderizados via JS (ex.: opções do dropdown de portos);
   (2) redesign da branch new-face, que sobrescreve a base onde há conflito.
   Caminhos de url() relativos a assets/css/.
   =========================================================================== */

/* ----- (1) Base / design-system legado ----- */
:root {
    --primary: #0f2b49;
    --accent: #bf0811;
    --neutral: #919191;
    --text: #14263a;
    --muted: #66788d;
    --bg: #eef1f5;
    --bg-soft: #f9fbfd;
    --card: #ffffff;
    --border: rgba(15, 43, 73, 0.16);
    --success: #16a34a;
    --danger: #bf0811;
    --shadow-md: 0 12px 24px rgba(15, 43, 73, 0.1);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

body {
    font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
    color: var(--text, #122033);
    background: radial-gradient(circle at 92% 10%, rgba(15, 43, 73, 0.2), transparent 36%), radial-gradient(circle at 8% 92%, rgba(191, 8, 17, 0.13), transparent 34%), linear-gradient(130deg, #eff3f8 0%, #e7edf3 45%, #edf2f7 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4 {
    margin: 0;
}

.stepper {
    display: flex;
    gap: 10px;
}

.step-item {
    position: relative;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.step-item.locked {
    cursor: not-allowed;
    opacity: 0.6;
}

.step-circle {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    transition: all 0.25s ease;
}

.step-label {
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.card-section {
    background: var(--card, #ffffff);
    border: 1px solid var(--border, rgba(15, 43, 73, 0.12));
    border-radius: 18px;
    box-shadow: var(--shadow-md, 0 12px 28px rgba(15, 43, 73, 0.08));
    padding: 28px;
    margin-bottom: 18px;
}

.section-title {
    font-size: 0.98rem;
    font-weight: 800;
    color: var(--primary, #0f2b49);
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(15, 43, 73, 0.12);
}

.section-title i {
    color: var(--accent, #bf0811);
}

.form-label {
    font-weight: 700;
    font-size: 0.86rem;
    color: var(--text, #122033);
    margin-bottom: 6px;
}

.form-control,
.form-select {
    border: 1.5px solid var(--border, rgba(15, 43, 73, 0.12));
    border-radius: 11px;
    padding: 10px 13px;
    font-size: 0.95rem;
    background: var(--bg-soft, #fbfbfb);
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.form-control:focus,
.form-select:focus {
    border-color: rgba(15, 43, 73, 0.35);
    box-shadow: 0 0 0 4px rgba(191, 8, 17, 0.12);
    outline: none;
}

.form-control.is-valid {
    border-color: var(--success, #16a34a);
}

.form-control.is-invalid {
    border-color: var(--danger, #bf0811);
}

.email-tags-input {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    border: 1.5px solid var(--border, rgba(15, 43, 73, 0.12));
    border-radius: 11px;
    padding: 6px 8px;
    background: var(--bg-soft, #fbfbfb);
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.email-tags-input:focus-within {
    border-color: rgba(15, 43, 73, 0.35);
    box-shadow: 0 0 0 4px rgba(191, 8, 17, 0.12);
}

.email-tags-input.is-invalid {
    border-color: var(--danger, #bf0811);
}

.email-tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.email-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(15, 43, 73, 0.08);
    color: var(--text, #122033);
    border-radius: 20px;
    padding: 4px 6px 4px 12px;
    font-size: 0.83rem;
    line-height: 1.4;
    white-space: nowrap;
}

.email-tag .email-tag-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: none;
    background: rgba(15, 43, 73, 0.12);
    color: var(--text, #122033);
    font-size: 0.75rem;
    line-height: 1;
    cursor: pointer;
    padding: 0;
}

.email-tag .email-tag-remove:hover {
    background: var(--danger, #bf0811);
    color: #fff;
}

.email-tags-field {
    flex: 1 1 160px;
    min-width: 140px;
    border: none;
    background: transparent;
    outline: none;
    font-size: 0.95rem;
    padding: 6px 4px;
}

.form-check-input:checked {
    background-color: var(--primary, #0f2b49);
    border-color: var(--primary, #0f2b49);
}

.toggle-group {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.toggle-card {
    flex: 1;
    min-width: 170px;
    border: 1.5px solid var(--border, rgba(15, 43, 73, 0.12));
    border-radius: 16px;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
    background: #fff;
    transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.toggle-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(15, 43, 73, 0.08);
}

.toggle-card.selected {
    border-color: rgba(191, 8, 17, 0.3);
    background: linear-gradient(135deg, rgba(15, 43, 73, 0.04), rgba(191, 8, 17, 0.07));
}

.toggle-card i {
    font-size: 1.3rem;
    color: var(--neutral, #919191);
}

.toggle-card .tc-label {
    font-weight: 800;
    font-size: 0.88rem;
}

.toggle-card .tc-desc {
    font-size: 0.78rem;
    color: var(--muted, #6f7884);
}

.email-status {
    font-size: 0.83rem;
    margin-top: 6px;
    display: none;
    align-items: center;
    gap: 6px;
}

.email-status.show {
    display: flex;
}

.email-status.ok {
    color: var(--success, #16a34a);
}

.email-status.fail {
    color: var(--danger, #bf0811);
}

.email-status.checking {
    color: var(--muted, #6f7884);
}

.btn-cotar {
    border: none;
    background: linear-gradient(135deg, #132f50 0%, #0f2b49 60%, #bf0811 100%);
    color: #fff;
    border-radius: 12px;
    padding: 12px 26px;
    font-weight: 800;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: transform 0.15s ease, box-shadow 0.2s ease, opacity 0.2s ease;
    box-shadow: 0 12px 22px rgba(15, 43, 73, 0.16);
}

.btn-cotar:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 16px 28px rgba(15, 43, 73, 0.2);
}

.btn-cotar:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

#result-section {
    display: none;
}

.result-card {
    background: linear-gradient(145deg, #0d223b 0%, #0f2b49 55%, #173c64 100%);
    border-radius: 20px;
    padding: 26px;
    color: #fff;
    box-shadow: 0 24px 48px rgba(15, 43, 73, 0.22);
}

.result-card .label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    opacity: 0.78;
    font-weight: 700;
}

.result-card .value {
    font-size: 1.7rem;
    font-weight: 800;
}

.result-card .value-sm {
    font-size: 1.08rem;
    font-weight: 700;
}

.result-divider {
    border-color: rgba(255, 255, 255, 0.2);
    margin: 16px 0;
}

.badge-port {
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 7px;
    padding: 3px 8px;
    font-size: 0.76rem;
    font-weight: 700;
}

.tag-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 11px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.24);
    font-size: 0.78rem;
    font-weight: 700;
}

.taxas-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 4px;
    font-size: 0.86rem;
}

.taxas-table th {
    font-size: 0.74rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--muted, #6f7884);
    font-weight: 700;
    padding: 4px 8px;
}

.taxas-table td {
    background: #fff;
    border-top: 1px solid rgba(15, 43, 73, 0.06);
    border-bottom: 1px solid rgba(15, 43, 73, 0.06);
    padding: 8px 10px;
}

.taxas-table td:first-child {
    border-radius: 7px 0 0 7px;
}

.taxas-table td:last-child {
    border-radius: 0 7px 7px 0;
    text-align: right;
    font-weight: 700;
}

.rules-log {
    background: #fbfcff;
    border: 1px solid var(--border, rgba(15, 43, 73, 0.12));
    border-radius: 14px;
    padding: 12px 14px;
    max-height: 180px;
    overflow-y: auto;
    color: var(--muted, #6f7884);
    font-family: "Courier New", monospace;
    font-size: 0.77rem;
}

.rules-log li {
    list-style: none;
    padding: 2px 0;
}

.rules-log li::before {
    content: "▸ ";
    color: var(--accent, #bf0811);
}

.alert-cotacao {
    border-radius: 10px;
    display: none;
}

.spinner-border-sm {
    width: 1rem;
    height: 1rem;
}

#url-preview-box {
    background: linear-gradient(135deg, #0a192a 0%, #0f2b49 100%);
    color: #f3f4f6;
    border-radius: 14px;
    padding: 11px 14px;
    font-family: "Courier New", monospace;
    font-size: 0.78rem;
    margin-top: 10px;
    display: none;
    word-break: break-all;
}

#url-preview-box .url-method {
    color: #fca5a5;
    font-weight: 700;
    margin-right: 8px;
}

#url-preview-box .url-param {
    color: #fecdd3;
}

.porto-wrap {
    position: relative;
}

.porto-input {
    width: 100%;
    border: 1.5px solid var(--border, rgba(15, 43, 73, 0.12));
    border-radius: 12px;
    padding: 10px 14px 10px 40px;
    background: #fff;
}

.porto-input:focus {
    border-color: rgba(15, 43, 73, 0.35);
    box-shadow: 0 0 0 4px rgba(191, 8, 17, 0.12);
    outline: none;
}

.porto-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted, #6f7884);
    pointer-events: none;
}

.porto-clear {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: none;
    color: var(--muted, #6f7884);
    cursor: pointer;
    display: none;
}

.porto-clear:hover {
    color: var(--danger, #bf0811);
}

.porto-dropdown {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    z-index: 1000;
    background: #fff;
    border: 1.5px solid var(--border, rgba(15, 43, 73, 0.12));
    border-radius: 14px;
    box-shadow: 0 16px 30px rgba(15, 43, 73, 0.14);
    max-height: 250px;
    overflow-y: auto;
    display: none;
}

.porto-dropdown.open {
    display: block;
}

.porto-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border-bottom: 1px solid #eef1f5;
    cursor: pointer;
}

.porto-option:last-child {
    border-bottom: none;
}

.porto-option:hover,
.porto-option.focused {
    background: rgba(15, 43, 73, 0.06);
}

.porto-option .opt-code {
    font-family: monospace;
    font-size: 0.81rem;
    font-weight: 700;
    background: rgba(15, 43, 73, 0.08);
    color: #0f2b49;
    border-radius: 5px;
    padding: 2px 6px;
}

.porto-option .opt-name {
    font-size: 0.86rem;
    color: var(--text, #122033);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.porto-option .opt-tipo {
    margin-left: auto;
    font-size: 0.72rem;
    color: var(--muted, #6f7884);
}

.porto-empty {
    padding: 12px;
    text-align: center;
    color: var(--muted, #6f7884);
    font-size: 0.84rem;
}

.porto-selected-badge {
    display: none;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    border: 1px solid var(--border, rgba(15, 43, 73, 0.12));
    border-radius: 11px;
    background: rgba(15, 43, 73, 0.04);
    padding: 8px 10px;
    font-size: 0.85rem;
}

.porto-selected-badge.show {
    display: flex;
}

.porto-selected-badge .badge-code {
    font-family: monospace;
    font-weight: 700;
    color: #0f2b49;
}

.route-status {
    border-radius: 10px;
    padding: 11px 14px;
    font-size: 0.87rem;
    margin-top: 14px;
    display: none;
    align-items: center;
    gap: 9px;
}

.route-status.checking {
    border: 1px solid var(--border, rgba(15, 43, 73, 0.12));
    color: var(--muted, #6f7884);
    background: #fff;
    display: flex;
}

.route-status.ok {
    border: 1px solid rgba(22, 163, 74, 0.2);
    color: var(--success, #16a34a);
    background: rgba(22, 163, 74, 0.08);
    display: flex;
}

.route-status.fail {
    border: 1px solid rgba(191, 8, 17, 0.25);
    color: var(--danger, #bf0811);
    background: rgba(191, 8, 17, 0.08);
    display: flex;
}

.route-status .rs-detail {
    font-size: 0.77rem;
    color: var(--muted, #6f7884);
    margin-top: 2px;
}

.a-shell {
    max-width: 1380px;
    margin: 0 auto;
    min-height: 100vh;
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 24px;
    padding: 24px;
}

.a-sidebar {
    position: sticky;
    top: 18px;
    align-self: start;
    background: linear-gradient(165deg, #0a213a 0%, #0f2b49 70%, #123253 100%);
    border-radius: 24px;
    padding: 26px 22px;
    color: #f5f9ff;
    box-shadow: 0 24px 45px rgba(15, 43, 73, 0.28);
    border: 1px solid rgba(255, 255, 255, 0.08);
    overflow: hidden;
}

.a-sidebar::after {
    content: "";
    position: absolute;
    inset: auto -70px -70px auto;
    width: 180px;
    height: 180px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(191, 8, 17, 0.3), transparent 70%);
}

.a-brand {
    font-family: "Sora", "Segoe UI", sans-serif;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-size: 1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
}

.a-brand i {
    color: #ffd7d9;
    font-size: 1.2rem;
}

.a-brand strong {
    color: #ffffff;
}

.a-brand span {
    color: #ffb7bb;
}

.a-intro {
    margin-top: 14px;
    margin-bottom: 18px;
    color: #d8e5f2;
    font-size: 0.88rem;
    line-height: 1.5;
}

.a-kpis {
    display: grid;
    gap: 10px;
    margin-bottom: 20px;
}

.a-kpi {
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 11px 12px;
}

.a-kpi .label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #cbd9e8;
    font-weight: 700;
}

.a-kpi .value {
    font-family: "Sora", "Segoe UI", sans-serif;
    margin-top: 2px;
    font-size: 0.94rem;
    font-weight: 700;
    color: #fff;
}

.a-nav-label {
    font-size: 0.74rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #acc2d9;
    margin-bottom: 10px;
    font-weight: 700;
}

.a-stepper {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 18px;
    position: relative;
    z-index: 1;
}

.a-stepper::before {
    content: "";
    position: absolute;
    left: 18px;
    top: 18px;
    bottom: 18px;
    width: 2px;
    background: rgba(255, 255, 255, 0.25);
}

.a-stepper .step-item {
    display: flex;
    align-items: center;
    gap: 10px;
    border-radius: 13px;
    padding: 8px 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid transparent;
}

.a-stepper .step-circle {
    width: 34px;
    height: 34px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #cfe0f1;
    z-index: 1;
}

.a-stepper .step-label {
    color: #d8e5f2;
    font-size: 0.7rem;
    margin: 0;
    letter-spacing: 0.08em;
}

.a-stepper .step-note {
    color: #9eb4ca;
    font-size: 0.74rem;
    font-weight: 500;
    margin-top: 2px;
}

.a-stepper .step-item.active {
    border-color: rgba(255, 255, 255, 0.34);
    background: rgba(255, 255, 255, 0.13);
    transform: translateX(2px);
}

.a-stepper .step-item.active .step-circle {
    background: #ffffff;
    color: #0f2b49;
}

.a-stepper .step-item.done .step-circle {
    background: #bf0811;
    color: #ffffff;
    border-color: rgba(191, 8, 17, 0.8);
}

.a-stepper .step-item.done .step-label {
    color: #ffffff;
}

.a-help {
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 14px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.08);
    font-size: 0.82rem;
    color: #e2ebf5;
    line-height: 1.5;
    position: relative;
    z-index: 1;
}

.a-main {
    min-width: 0;
    padding-bottom: 36px;
}

.a-hero {
    border-radius: 24px;
    padding: 26px 28px;
    background: linear-gradient(130deg, rgba(15, 43, 73, 0.92) 0%, rgba(15, 43, 73, 0.72) 62%, rgba(191, 8, 17, 0.78) 100%);
    color: #ffffff;
    box-shadow: 0 24px 40px rgba(15, 43, 73, 0.26);
    margin-bottom: 18px;
}

.a-hero h1 {
    font-family: "Sora", "Segoe UI", sans-serif;
    font-size: 2rem;
    letter-spacing: -0.02em;
    font-weight: 700;
    margin-bottom: 6px;
}

.a-hero p {
    margin: 0;
    font-size: 0.95rem;
    color: #e3ecf5;
    max-width: 720px;
}

.a-stage {
    border-radius: 22px;
    border: 1px solid rgba(15, 43, 73, 0.12);
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 20px 34px rgba(15, 43, 73, 0.1);
    backdrop-filter: blur(6px);
    padding: 22px;
}

#step-2 {
    display: grid;
    gap: 14px;
}

#result-section[style*="display: block"] {
    grid-template-columns: 1.2fr 0.8fr;
    gap: 14px;
}

#result-section>div:first-child {
    grid-column: 1 / -1;
    margin-bottom: 0 !important;
    border-radius: 16px !important;
    box-shadow: var(--shadow-md);
}

#result-section>.result-card {
    grid-column: 1 / -1;
    margin-bottom: 0;
}

#taxas-section {
    grid-column: 1 / 2;
    margin-top: 0 !important;
}

#subsidio-section {
    grid-column: 2 / 3;
    margin-top: 0 !important;
}

#result-section>.card-section.mt-0:not(#subsidio-section) {
    grid-column: 1 / -1;
}

@media (max-width: 1120px) {
    .a-shell {
        grid-template-columns: 1fr;
    }

    .a-sidebar {
        position: relative;
        top: 0;
    }

    .a-stepper {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 6px;
    }

    .a-stepper::before {
        display: none;
    }

    .a-stepper .step-item {
        min-width: 220px;
    }
}

@media (max-width: 991px) {
    .card-section {
        padding: 22px;
    }
}

@media (max-width: 760px) {
    .a-shell {
        padding: 12px;
        gap: 14px;
    }

    .a-hero {
        padding: 20px;
    }

    .a-hero h1 {
        font-size: 1.5rem;
    }

    .a-stage {
        padding: 12px;
    }

    #result-section[style*="display: block"] {
        grid-template-columns: 1fr;
    }

    #taxas-section,
    #subsidio-section {
        grid-column: 1 / -1;
    }
}

@media (max-width: 576px) {
    .card-section {
        padding: 18px 14px;
        border-radius: 14px;
    }

    .result-card {
        padding: 18px;
    }

    .result-card .value {
        font-size: 1.4rem;
    }
}


/* ----- (2) Redesign EasyQuotes (branch new-face) ----- */
        :root {
            --bg-color: #eef1f5;
            --primary-blue: #101c3d;
            --primary-red: #d9232d;
            --text-dark: #333;
            --text-light: #fff;
            --text-muted: #888;
            --step-active: #82b29a;
            --step-inactive: #f4f6f8;
            --border-color: #d1d5db;
        }

        html, body {
            height: 100%;
            margin: 0;
        }

        body {
            background-color: var(--bg-color);
            display: flex;
            flex-direction: column;
            min-height: 100vh;
            font-family: 'Exo 2', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            overflow-x: hidden;
        }

        /* === Tela inicial (Landing Page) === */

        @font-face {
            font-family: 'Exo 2';
            font-style: normal;
            font-weight: 300 800;
            font-display: swap;
            src: url('../fonts/exo2-latin-ext.woff2') format('woff2');
            unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
        }
        @font-face {
            font-family: 'Exo 2';
            font-style: normal;
            font-weight: 300 800;
            font-display: swap;
            src: url('../fonts/exo2-latin.woff2') format('woff2');
            unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
        }

        .intro-screen {
            position: fixed;
            inset: 0;
            overflow-y: auto;
            z-index: 5;
            background: #0f2047;
        }

        .lp-page {
            min-height: 100%;
            width: 100%;
            flex: 1 0 auto;
            display: flex;
            flex-direction: column;
            background: #0f2047;
            font-family: 'Exo 2', 'Segoe UI', sans-serif;
        }

        /* ── Header ─────────────────────────────────── */
        .lp-topbar {
            position: relative;
            z-index: 10;
            flex-shrink: 0;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 20px;
            padding: 18px clamp(20px, 2.08vw, 40px);
            background: linear-gradient(90deg, #0f2047 24.3%, #0a8bc4 100%);
        }

        .lp-logo {
            display: flex;
            align-items: center;
            text-decoration: none;
        }

        .lp-logo-img {
            height: 34px;
            width: auto;
            display: block;
        }

        .lp-logo-bars { display: none; }
        .lp-logo-text { display: none; }

        .lp-site-link {
            display: inline-flex;
            align-items: center;
            gap: 10px;
            padding: 6px 8px;
            border-bottom: 1px solid rgba(255, 255, 255, 0.9);
            color: #ffffff;
            text-decoration: none;
            font-family: 'Exo 2', sans-serif;
            font-weight: 700;
            font-size: clamp(0.7rem, 0.83vw, 1rem);
            letter-spacing: -0.01em;
            text-transform: uppercase;
            transition: opacity 0.2s ease;
        }

        .lp-site-link:hover { color: #ffffff; opacity: 0.82; }

        /* ── Hero ──────────────────────────────────────
           Reproduz a "seção 1" do Figma (frame 1920×862): o painel visual é
           posicionado de forma absoluta cobrindo todo o hero, e o conteúdo de
           texto fica por cima, à esquerda. Coordenadas em % derivam direto das
           coordenadas do Figma. */
        .lp-hero {
            position: relative;
            flex: 1 0 auto;
            min-height: min(862px, 46vw);
            overflow: hidden;
            background: #0f2047;
        }

        /* ── Left content ────────────────────────────── */
        .lp-copy {
            position: relative;
            z-index: 4;
            display: flex;
            flex-direction: column;
            justify-content: flex-start;
            max-width: 52%;
            /* padding-top ≈118px e padding-left ≈120px (coordenadas do Figma). */
            padding: clamp(54px, 7vw, 120px) clamp(20px, 2.2vw, 42px) clamp(40px, 4vw, 70px) clamp(24px, 6.25vw, 120px);
        }

        /* Largura ≈844px (do Figma) — transborda a coluna sobre o visual,
           reproduzindo a sobreposição texto/imagem do design. */
        .lp-headline { width: 844px; max-width: 500px; }

        .lp-headline h1 {
            margin: 0;
            color: #ffffff;
            font-family: 'Exo 2', sans-serif;
            font-size: clamp(1.9rem, 3.02vw, 3.625rem);
            font-weight: 700;
            line-height: 1.1;
            letter-spacing: -0.005em;
        }

        .lp-headline p {
            margin: 24px 0 0;
            max-width: 686px;
            color: rgba(255, 255, 255, 0.92);
            font-family: 'Exo 2', sans-serif;
            font-size: clamp(0.9rem, 1.04vw, 1.25rem);
            font-weight: 500;
            line-height: 1.3;
        }

        /* Figma node 383:2196 — gap de 74px entre os grupos (texto principal,
           lista e CTA). */
        .lp-features {
            list-style: none;
            padding: 0;
            margin: clamp(30px, 3.85vw, 74px) 0 0;
            /* Figma node 383:2200 — gap de 14px entre os itens da lista. */
            display: flex;
            flex-direction: column;
            gap: 14px;
            max-width: 660px;
        }

        .lp-features li {
            display: flex;
            align-items: center;
            gap: 15px;
            padding-bottom: 20px;
            color: #ffffff;
            font-family: 'Exo 2', sans-serif;
            font-weight: 300;
            font-size: clamp(0.95rem, 1.25vw, 1.5rem);
            letter-spacing: 0.0015em;
            line-height: normal;
            border-bottom: 1px solid #0a8bc4;
        }

        .lp-feat-icon { flex-shrink: 0; width: 22px; height: 22px; }

        /* Figma node 383:2196 — gap de 74px entre a lista e o bloco de CTA;
           gap interno de 22px entre botão e nota (node 383:2219). */
        .lp-cta-block {
            margin-top: clamp(30px, 3.85vw, 74px);
            display: flex;
            flex-direction: column;
            gap: 22px;
        }

        .lp-cta-btn {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            width: clamp(200px, 14.5vw, 279px);
            height: 52px;
            padding: 0 39px;
            border: none;
            border-radius: 11px;
            background: #7cb89f;
            color: #ffffff;
            font-family: 'Exo 2', sans-serif;
            font-weight: 700;
            font-size: clamp(0.85rem, 1.04vw, 1.25rem);
            letter-spacing: -0.011em;
            text-transform: uppercase;
            white-space: nowrap;
            cursor: pointer;
            transition: transform 0.2s ease, box-shadow 0.2s ease;
        }

        .lp-cta-btn:hover {
            transform: translateY(-1px);
            box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28);
        }

        .lp-note {
            margin: 0;
            color: #ffffff;
            font-family: 'Exo 2', sans-serif;
            font-size: clamp(0.78rem, 0.83vw, 1rem);
            line-height: 1.4;
        }

        .lp-note strong { font-weight: 700; }

        .lp-note a {
            color: #7cb89f;
            text-decoration: underline;
            text-underline-offset: 2px;
        }

        /* ── Painel visual (composição absoluta do Figma) ── */
        .lp-visual {
            position: absolute;
            inset: 0;
            z-index: 1;
            overflow: hidden;
            pointer-events: none;
        }

        /* Céu + oceano  (Figma: left 731 / top -55 / w 1301 / h 930) */
        .lp-sky {
            position: absolute;
            left: 38.07%;
            top: -6.4%;
            width: 67.76%;
            height: 108%;
            object-fit: cover;
            object-position: center top;
            z-index: 1;
        }

        /* Formas geométricas  (Figma: left 727 / top 355 / w 1434 / h 764) */
        .lp-geo-shapes {
            position: absolute;
            left: 37.86%;
            top: 41.2%;
            width: 74.69%;
            height: 88.6%;
            z-index: 2;
            opacity: 0.55;
            pointer-events: none;
        }

        /* Mulher  (Figma node 383:2228 — figura inteira com braços cruzados) */
        .lp-scene-woman {
            position: absolute;
            left: -8.9%;
            top: -35%;
            z-index: 3;
            width: 135.6%;
            height: auto;
            max-width: none;
        }

        /* Tagline  (Figma: left 1441 / top 434) */
        .lp-tagline {
            position: absolute;
            z-index: 5;
            left: 75.05%;
            top: 50.3%;
            margin: 0;
            color: #ffffff;
            font-family: 'Exo 2', sans-serif;
            font-weight: 800;
            font-size: clamp(1.1rem, 1.67vw, 2rem);
            text-transform: uppercase;
            letter-spacing: 0.04em;
            line-height: 1.44;
        }

        /* Barras vermelhas  (Figma: left 1319 / top 594 / w 244 / h 152) */
        .lp-red-bars {
            position: absolute;
            z-index: 4;
            left: 68.7%;
            top: 68.9%;
            width: 12.7%;
            height: auto;
        }

        /* ── Footer ─────────────────────────────────── */
        .lp-footer {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 20px;
            padding: 32px clamp(24px, 6.77vw, 130px);
            background: #0f2047;
            color: #ffffff;
            flex-shrink: 0;
        }

        .lp-footer-left {
            display: flex;
            align-items: center;
            gap: clamp(20px, 2.86vw, 55px);
        }

        .lp-footer-brand strong {
            display: block;
            font-family: 'Exo 2', sans-serif;
            font-size: clamp(0.9rem, 1.15vw, 1.375rem);
            font-weight: 500;
        }

        .lp-footer-brand small {
            display: block;
            margin-top: 4px;
            font-family: 'Exo 2', sans-serif;
            font-size: clamp(0.7rem, 0.73vw, 0.875rem);
            color: rgba(255, 255, 255, 0.72);
            font-weight: 500;
        }

        .lp-socials { display: flex; align-items: center; gap: 8px; }

        .lp-socials a {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            width: 27px;
            height: 27px;
            border-radius: 50%;
            color: #ffffff;
            background: #c73436;
            text-decoration: none;
            font-size: 0.65rem;
            transition: background 0.2s ease, transform 0.2s ease;
        }

        .lp-socials a:hover {
            background: rgba(255, 255, 255, 0.24);
            transform: translateY(-1px);
            color: #ffffff;
        }

        .lp-footer-right {
            display: flex;
            align-items: center;
            gap: clamp(16px, 2.6vw, 50px);
            font-family: 'Exo 2', sans-serif;
            font-size: clamp(0.66rem, 0.63vw, 0.75rem);
            color: rgba(255, 255, 255, 0.9);
        }

        /* "Desenvolvido por" + logo LAYER (Figma node 80:12/80:14, gap 10px). */
        .lp-dev-by {
            display: inline-flex;
            align-items: center;
            gap: 10px;
            white-space: nowrap;
        }

        .lp-layer-logo {
            height: 16px;
            width: auto;
            display: block;
        }

        /* ── Telas baixas (pouca altura): reduz espaçamento vertical
           para minimizar rolagem e garantir o CTA acessível ── */
        @media (max-height: 700px) {
            .lp-copy {
                justify-content: flex-start;
                padding-top: clamp(24px, 4vh, 50px);
                padding-bottom: clamp(20px, 3vh, 40px);
            }
            .lp-headline p { margin-top: 16px; }
            .lp-features { margin-top: 20px; }
            .lp-features li { padding-bottom: 12px; }
            .lp-cta-block { margin-top: 20px; gap: 14px; }
        }

        /* ── Responsive ──────────────────────────────── */
        @media (max-width: 1200px) {
            /* Em telas menores o título volta a caber na coluna (sem transbordar). */
            .lp-headline { width: auto; max-width: 100%; }
        }

        /* ===== Layout MOBILE — 100% fiel ao Figma (node 542:715, frame 390px)
           Banner visual no topo, conteúdo no meio, footer centralizado. ===== */
        @media (max-width: 1024px) {
            .lp-hero {
                display: flex;
                flex-direction: column;
                min-height: 0;
            }

            /* Header compacto (Figma menu: px-20, logo h-26, link 14px) */
            .lp-topbar { padding: 18px 20px 16px; }
            .lp-logo-img { height: 26px; }
            .lp-site-link { font-size: 0.8rem; padding: 4px 8px 8px; gap: 8px; }

            /* ── Banner visual no topo (Figma 390×224 ≈ 57.4vw de altura) ── */
            .lp-visual {
                position: relative;
                inset: auto;
                order: 1;
                width: 100%;
                height: 57.4vw;
                min-height: 200px;
                max-height: 300px;
                overflow: hidden;
            }

            /* Céu (Figma: left -42 / top -46 / w455 h325) */
            .lp-sky {
                left: -10.8%;
                top: -20.5%;
                width: 116.7%;
                height: 145%;
            }

            /* Formas (Figma: left -42 / top 88 / w518 h275) */
            .lp-geo-shapes {
                display: block;
                left: -10.8%;
                top: 39.3%;
                width: 132.8%;
                height: 122.8%;
                opacity: 0.55;
            }

            /* Mulher à esquerda do banner (Figma: frame left 11 / w215 + crop) */
            .lp-scene-woman {
                display: block;
                left: -75.6%;
                top: -55.4%;
                width: 202.8%;
                height: auto;
            }

            /* Tagline à direita do banner (Figma: left 219 / top 110, 14px) */
            .lp-tagline {
                left: 56.2%;
                right: auto;
                top: 47%;
                transform: none;
                text-align: left;
                font-size: clamp(0.8rem, 3.6vw, 0.95rem);
                line-height: 1.16;
                letter-spacing: 0.04em;
                text-shadow: 0 2px 10px rgba(8, 22, 54, 0.45);
            }

            /* Barras vermelhas (Figma: left 339 / top 203 / w74 — saem pela direita) */
            .lp-red-bars {
                left: 86.9%;
                right: auto;
                top: 86%;
                bottom: auto;
                width: 19%;
                max-width: 74px;
            }

            /* ── Conteúdo ── */
            .lp-copy {
                order: 2;
                max-width: 100%;
                padding: clamp(28px, 6.4vw, 40px) 20px 36px;
            }

            .lp-headline { width: auto; max-width: 100%; }
            .lp-headline h1 {
                font-size: clamp(1.7rem, 8.2vw, 2rem);   /* 32px @390 */
                line-height: 1.19;
            }
            .lp-headline p {
                margin-top: 24px;
                max-width: 100%;
                font-weight: 400;
                font-size: 1rem;                          /* 16px Regular */
                line-height: 1.5;
            }

            /* Espaçamentos mobile (Figma: 33px entre grupos, 14px entre itens) */
            .lp-features { margin-top: 33px; gap: 14px; max-width: 100%; }
            .lp-features li { font-size: 1rem; padding-bottom: 20px; }  /* 16px */
            .lp-feat-icon { width: 15px; height: 15px; }               /* 15px */
            .lp-cta-block { margin-top: 33px; gap: 32px; }
            .lp-cta-btn { width: 100%; min-width: 0; }
            .lp-note { text-align: center; font-size: 0.875rem; line-height: 1.57; } /* 14px */

            /* ── Footer centralizado (Figma node 575:855) ── */
            .lp-footer {
                flex-direction: column;
                align-items: center;
                gap: 25px;
                text-align: center;
                padding: 32px 15px 33px;
            }
            .lp-footer-left {
                flex-direction: column;
                align-items: center;
                gap: 15px;
            }
            .lp-footer-brand { text-align: center; }
            .lp-footer-brand strong { font-size: 18px; }
            .lp-footer-brand small { font-size: 12px; color: rgba(255, 255, 255, 0.8); }
            .lp-socials { gap: 8px; }
            .lp-footer-right {
                flex-direction: column;
                align-items: center;
                gap: 8px;
                font-size: 10px;
            }
            .lp-dev-by { font-size: 12px; }
        }

        @media (max-width: 400px) {
            .lp-topbar { gap: 10px; }
            .lp-site-link { padding: 4px 6px 6px; gap: 6px; font-size: 0.72rem; }
        }

        /* --- Header --- */
        .site-header {
            background-color: var(--primary-blue);
            color: var(--text-light);
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 15px 40px;
        }
        .site-header .logo { font-size: 24px; font-weight: bold; font-style: italic; color: var(--text-light); text-decoration: none; }
        .site-header .logo span { color: var(--primary-red); }
        .site-header nav { display: flex; gap: 20px; font-size: 14px; }
        .site-header nav span { cursor: pointer; color: var(--text-light); }
        .header-actions { display: flex; align-items: center; gap: 20px; }
        .btn-red { background-color: var(--primary-red); color: white; padding: 10px 20px; border: none; border-radius: 12px; cursor: pointer; font-weight: bold; text-decoration: none; }

        /* --- Main Layout --- */
        .main-container {
            display: flex;
            flex: 1;
            padding: 40px;
            gap: 40px;
            max-width: 1400px;
            margin: 0 auto;
            width: 100%;
        }

        /* --- Sidebar (Steps) --- */
        .sidebar { width: 300px; background: transparent; }
        .sidebar h2 { font-size: 20px; color: var(--primary-blue); margin-bottom: 20px; font-weight: normal;}
        
        .step {
            display: flex;
            align-items: center;
            padding: 15px;
            background-color: var(--step-inactive);
            margin-bottom: 15px;
            border-radius: 8px;
            color: var(--text-muted);
            transition: all 0.3s ease;
        }
        .step .step-circle {
            width: 30px; height: 30px; border-radius: 50%; background-color: #ccc;
            color: white; display: flex; align-items: center; justify-content: center;
            margin-right: 15px; font-weight: bold;
        }
        
        /* Interação do JS antigo com a sidebar */
        .step.active, .step-item.active { background-color: var(--step-active) !important; color: white !important; }
        .step.active .step-circle, .step-item.active .step-circle { background-color: var(--primary-blue) !important; }
        
        .step-info strong { display: block; font-size: 14px; }
        .step-info span { font-size: 12px; }

        /* --- Main Content Area --- */
        .main-content { flex: 1; }
        
        @media (max-width: 1024px) {
            .main-container {
                flex-direction: column;
                gap: 20px;
                padding: 20px;
            }
            .sidebar {
                width: 100%;
                margin: 0;
                display: flex;
                flex-wrap: wrap;
                gap: 12px;
                align-items: stretch;
                padding: 0 8px;
            }
            .sidebar h2 {
                width: 100%;
                margin-bottom: 12px;
            }
            .step {
                flex: 1 1 calc(33.333% - 12px);
                min-width: 180px;
                margin-bottom: 0;
            }
            .step .step-circle {
                margin-right: 10px;
            }
            .step-info strong {
                display: inline;
                font-size: 13px;
            }
            .step-info span {
                display: inline;
                font-size: 11px;
                color: rgba(0, 0, 0, 0.7);
            }
            .header-box {
                flex-direction: column;
                align-items: stretch;
                gap: 16px;
            }
            .header-box h1 { font-size: 28px; }
            .btn-container { flex-direction: column; gap: 12px; }
            .btn-container.right { justify-content: flex-start; }
        }

        /* Refinamentos das telas do formulário em celulares */
        @media (max-width: 640px) {
            .main-container { padding: 16px; gap: 16px; }

            .header-box {
                padding: 20px;
            }
            .header-box h1 { font-size: 24px; }
            .header-box p { font-size: 14px; }
            /* O seletor de idioma não deve esticar na largura toda */
            .header-box .language-toggle { align-self: flex-end; }

            .content-box { padding: 18px; }
            .content-box h3 { font-size: 1.1rem; }

            .form-label { font-size: 17px; }

            .success-box { padding: 24px 18px; }
            .success-box h2 { font-size: 22px; }

            .modal-custom { padding: 28px 20px; }
            .modal-custom h2 { font-size: 22px; }

            /* Botões em coluna ocupam a largura toda para facilitar o toque */
            .btn-container .btn-custom { width: 100%; text-align: center; }

            /* Tabelas de resultado roláveis horizontalmente em vez de estourar o layout */
            #result-section .table { font-size: 13px; }
        }

        /* Tabelas do resultado nunca devem estourar a largura da tela */
        @media (max-width: 768px) {
            #taxas-section .table,
            #result-summary table {
                display: block;
                width: 100%;
                overflow-x: auto;
                -webkit-overflow-scrolling: touch;
                white-space: nowrap;
            }
        }

        /* Etapas (sidebar) mais compactas em celulares pequenos */
        @media (max-width: 560px) {
            .sidebar {
                flex-direction: column;
                flex-wrap: nowrap;
            }
            .step {
                flex: 1 1 100%;
                min-width: 0;
                padding: 12px;
            }
        }

        .header-box {
            background-color: var(--primary-blue);
            color: white;
            padding: 30px;
            border-radius: 8px;
            margin-bottom: 20px;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        .header-box h1 { font-size: 32px; margin-bottom: 5px; color: white; }

        .content-box {
            background-color: var(--step-inactive);
            padding: 30px;
            border-radius: 8px;
            border: 1px solid var(--border-color);
            margin-bottom: 20px;
        }
        .content-box h3 { color: var(--primary-blue); font-size: 1.25rem; font-weight: bold; margin-bottom: 15px; }

        /* Componentes de Formulário */
        .form-label { font-size: 21px; font-weight: bold; color: var(--primary-blue); margin-bottom: 8px; display: block; }
        .form-control { width: 100%; padding: 12px; border: 1px solid var(--border-color); border-radius: 12px; font-size: 14px; background: white; }
        .input-group, .input-group .form-control, .input-group-text {
            border-radius: 12px;
            border: 1px solid var(--border-color);
        }
        .input-group { display: flex; align-items: stretch; }
        .input-group .form-control {
            margin: 0;
            border-right: none;
            border-top-right-radius: 0;
            border-bottom-right-radius: 0;
            border-top-left-radius: 12px;
            border-bottom-left-radius: 12px;
        }
        .input-group-text {
            background: white;
            border-left: none;
            border-top-right-radius: 12px;
            border-bottom-right-radius: 12px;
            border-top-left-radius: 0;
            border-bottom-left-radius: 0;
        }
        
        /* Ajustes específicos para selects do JS antigo */
        .porto-wrap { position: relative; }
        .porto-dropdown { position: absolute; z-index: 1000; width: 100%; background: white; border: 1px solid var(--border-color); border-top: none; max-height: 200px; overflow-y: auto; }
        .porto-selected-badge { display: none; margin-top: 10px; padding: 10px; background: #e8f5e9; border: 1px solid #c8e6c9; border-radius: 4px; }

        /* Componentes Especiais Tela 2 */
        .toggle-box {
            display: flex; align-items: center; justify-content: space-between;
            background: white; padding: 15px; border: 1px solid var(--border-color); border-radius: 25px;
            margin-bottom: 10px;
        }
        .radio-box {
            display: flex; align-items: center; gap: 10px;
            background: white; padding: 15px; border: 1px solid var(--border-color); border-radius: 25px; cursor: pointer;
            width: 100%; margin-bottom: 10px;
        }
        .radio-box:has(input:checked) { border-color: var(--step-active); background-color: #f0f7f4; }
        .radio-box input[type="radio"] { display: none; }
        .radio-circle { width: 20px; height: 20px; border-radius: 50%; border: 2px solid #ccc; display: inline-block; flex-shrink: 0; }
        .radio-box:has(input:checked) .radio-circle { border-color: var(--step-active); border-width: 6px; }

        /* Modalidade indisponível para a rota (ex.: Collect bloqueado por aceita_frete_cc = 'N') */
        .radio-box.disabled { opacity: 0.5; cursor: not-allowed; background-color: var(--step-inactive); }
        .radio-box.disabled .radio-circle { border-color: #ccc; border-width: 2px; }
        .freight-cc-note { margin-top: 14px; font-size: 0.9rem; font-weight: 600; color: var(--primary-red); }

        /* Segmented SIM/NÃO toggle (Características especiais) */
        .seg-toggle { display: inline-flex; gap: 4px; background: var(--bg, #eef1f5); padding: 4px; border-radius: 12px; flex-shrink: 0; }
        .seg-btn {
            border: none; background: transparent; padding: 8px 18px; border-radius: 9px;
            font-weight: 700; font-size: 13px; letter-spacing: 0.02em; color: var(--text-muted, #888);
            cursor: pointer; transition: background-color 0.15s ease, color 0.15s ease; min-width: 56px;
        }
        .seg-btn:hover { color: var(--primary-blue, #101c3d); }
        .seg-toggle-input:checked ~ .seg-yes { background: var(--success, #16a34a); color: #fff; }
        .seg-toggle-input:checked ~ .seg-yes:hover { color: #fff; }
        .seg-toggle-input:not(:checked) ~ .seg-no { background: var(--primary-blue, #101c3d); color: #fff; }
        .seg-toggle-input:not(:checked) ~ .seg-no:hover { color: #fff; }
        .seg-toggle[data-unset] .seg-toggle-input:not(:checked) ~ .seg-no { background: transparent; color: inherit; }
        .seg-toggle[data-unset] .seg-toggle-input:not(:checked) ~ .seg-no:hover { color: var(--primary-blue, #101c3d); }

        /* Buttons */
        .btn-container { display: flex; justify-content: space-between; margin-top: 20px; }
        .btn-container.right { justify-content: flex-end; }
        .btn-custom { padding: 12px 24px; border: none; border-radius: 12px; font-weight: bold; cursor: pointer; font-size: 14px; text-decoration: none; display: inline-block; }
        .btn-primary-custom { background-color: var(--primary-blue); color: white; border-radius: 12px; }
        .btn-primary-custom:disabled { background-color: #a0a5b1; cursor: not-allowed; }
        .btn-secondary-custom { background-color: #d1d5db; color: #333; border-radius: 12px; }
        button, .btn, .btn-custom, .btn-red, .btn-primary-custom, .btn-secondary-custom, .modal-custom .btn-understand { border-radius: 12px !important; }
        input[type="text"], input[type="email"], input[type="number"], textarea, select, .form-control { border-radius: 12px !important; }

        /* --- Tela 3 (Sucesso) --- */
        .success-box { background-color: #f0fdf4; border: 1px solid #bbf7d0; padding: 40px; border-radius: 8px; color: var(--primary-blue); width: 100%; max-width: 100%; box-sizing: border-box; }
        .success-box h2 { font-size: 28px; color: #4ade80; margin-bottom: 15px; }
        .processing-status { display: block; width: 100%; }
        .btn-cotar-icon { display: inline-flex; align-items: center; justify-content: center; margin-right: 10px; }
        .quote-loading-overlay {
            position: fixed;
            inset: 0;
            background: rgba(16, 28, 61, 0.82);
            z-index: 2050;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 20px;
        }
        .quote-loading-card {
            background: #101c3d;
            color: #ffffff;
            padding: 28px 30px;
            border-radius: 18px;
            box-shadow: 0 24px 48px rgba(0, 0, 0, 0.32);
            text-align: center;
            max-width: 420px;
            width: 100%;
        }
        .quote-loading-card p { margin: 0; line-height: 1.5; font-size: 1rem; }

        /* --- Modal Aviso Inicial --- */
        .modal-overlay {
            position: fixed; top: 0; left: 0; width: 100%; height: 100%;
            background: rgba(0,0,0,0.5); display: flex; align-items: flex-start; justify-content: center; z-index: 1050;
            padding: 20px;
            overflow-y: auto;
        }
        /* margin auto centraliza verticalmente quando o modal cabe na tela, mas mantém o
           topo acessível para rolagem quando o conteúdo é mais alto que a viewport
           (evita que o cabeçalho e o botão do modal de aviso fiquem cortados no celular) */
        .modal-overlay > .modal-custom { margin: auto; }
        .modal-custom {
            background-color: var(--primary-red); color: white;
            padding: 40px; border-radius: 12px; max-width: 500px; text-align: center; position: relative;
            width: 100%;
        }
        .modal-custom h2 { font-size: 28px; margin-bottom: 20px; color: white; }
        .modal-custom ul { text-align: left; margin: 20px 0; padding-left: 20px; list-style: none; }
        .modal-custom ul li { margin-bottom: 10px; display: flex; align-items: center; gap: 10px; }
        .modal-custom ul li::before { content: '➔'; }
        .modal-custom .close-btn { position: absolute; top: 15px; right: 20px; cursor: pointer; font-size: 20px; color: white; }
        .modal-custom .btn-understand { background-color: var(--primary-blue); color: white; padding: 12px 30px; border: none; border-radius: 4px; cursor: pointer; font-weight: bold; margin-top: 20px; }

        /* Estilo específico do modal inicial e do modal de erro, seguindo a arte azul */
        #avisoModal .modal-custom,
        #errorModal .modal-custom {
            background: #112255;
            color: #edf3ff;
            border-radius: 16px;
            max-width: 640px;
            width: min(92vw, 640px);
            padding: 24px 20px 20px;
            overflow: visible;
            box-shadow: 0 18px 46px rgba(6, 15, 38, 0.30);
        }
        #avisoModal .modal-custom::before,
        #avisoModal .modal-custom::after,
        #errorModal .modal-custom::before,
        #errorModal .modal-custom::after {
            content: '';
            position: absolute;
            top: 66px;
            width: 130px;
            height: calc(100% - 145px);
            opacity: 0.20;
            pointer-events: none;
            background: repeating-linear-gradient(
                to bottom,
                transparent 0,
                transparent 22px,
                #8ea6d8 22px,
                #8ea6d8 44px,
                transparent 44px,
                transparent 66px
            );
            z-index: 0;
        }
        #avisoModal .modal-custom::before,
        #errorModal .modal-custom::before { left: -34px; transform: skewX(-22deg); }
        #avisoModal .modal-custom::after,
        #errorModal .modal-custom::after { right: -34px; transform: skewX(-22deg); }
        #avisoModal .modal-custom > *,
        #errorModal .modal-custom > * { position: relative; z-index: 1; }
        #avisoModal .modal-custom h2,
        #errorModal .modal-custom h2 {
            margin-bottom: 18px;
            font-size: clamp(2.3rem, 5.2vw, 3.35rem);
            font-weight: 800;
            letter-spacing: 0.06em;
            color: #ffffff;
        }
        #avisoModal .modal-custom .close-btn,
        #errorModal .modal-custom .close-btn {
            top: 18px;
            right: 22px;
            font-size: 34px;
            font-weight: 300;
            line-height: 1;
            color: #f5f8ff;
        }
        #avisoModal .modal-intro,
        #errorModal .modal-intro {
            margin: 0 auto;
            max-width: 620px;
            font-size: 1.75rem;
            line-height: 1.35;
        }
        #avisoModal .modal-custom ul,
        #errorModal .modal-custom ul {
            list-style: none;
            margin: 18px auto;
            padding: 0;
            max-width: 620px;
            text-align: left;
        }
        #avisoModal .modal-custom ul li,
        #errorModal .modal-custom ul li {
            margin-bottom: 10px;
            gap: 12px;
            align-items: center;
            color: #dce6fb;
            font-size: 1.65rem;
        }
        #avisoModal .modal-custom ul li::before,
        #errorModal .modal-custom ul li::before {
            content: '➜';
            width: 18px;
            height: 18px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            border: 1px solid #58c8df;
            border-radius: 50%;
            color: #58c8df;
            font-size: 11px;
            flex-shrink: 0;
            line-height: 1;
        }
        #avisoModal .modal-contact,
        #errorModal .modal-contact {
            margin: 6px 0 0;
            font-size: 1.5rem;
            line-height: 1.3;
            color: #ffffff;
        }
        #avisoModal .modal-contact strong,
        #errorModal .modal-contact strong {
            text-decoration: underline;
            font-weight: 700;
        }
        #avisoModal .modal-divider,
        #errorModal .modal-divider {
            border: 0;
            border-top: 1px solid rgba(211, 225, 255, 0.32);
            margin: 18px auto 14px;
            max-width: 610px;
        }
        #avisoModal .modal-disclaimer,
        #errorModal .modal-disclaimer {
            margin: 8px auto;
            max-width: 680px;
            font-size: 1.25rem;
            line-height: 1.45;
            color: rgba(223, 234, 255, 0.62);
        }
        #avisoModal .modal-custom .btn-understand,
        #errorModal .modal-custom .btn-understand {
            margin-top: 16px;
            min-width: 174px;
            padding: 12px 34px;
            border-radius: 10px;
            border: none;
            background: linear-gradient(180deg, #23ace0 0%, #1388c8 100%);
            color: #ffffff;
            font-size: 1.7rem;
            font-weight: 700;
            letter-spacing: 0.02em;
            box-shadow: 0 12px 28px rgba(10, 53, 98, 0.35);
        }

        #avisoModal .modal-custom {
            zoom: 0.8;
        }

        #freight-modality-box.invalid {
            border: 1px solid #dc3545;
            border-radius: 16px;
            box-shadow: inset 0 0 0 1px rgba(220, 53, 69, 0.20);
            padding: 20px;
        }

        #error-alert {
            margin-top: 20px;
            padding: 18px 16px;
            line-height: 1.5;
        }

        #error-alert .inline-error-item {
            display: flex;
            align-items: flex-start;
            gap: 10px;
            margin-bottom: 10px;
            color: #842029;
            font-size: 0.95rem;
        }

        #error-alert .inline-error-item:last-child {
            margin-bottom: 0;
        }

        #error-alert .inline-error-item i {
            margin-top: 3px;
            flex-shrink: 0;
        }

        /* Pontos de Atenção: avisos comerciais dinâmicos (ex.: BL direto em origem
           EUA), centralizados aqui em vez de espalhados pelo formulário. */
        .attention-box {
            border-color: var(--primary-red);
            background-color: #fdf2f2;
        }
        .attention-box h3 {
            color: var(--primary-red);
        }
        .attention-item {
            display: flex;
            align-items: flex-start;
            gap: 10px;
            padding: 12px 14px;
            background: white;
            border-left: 4px solid var(--primary-red);
            border-radius: 6px;
            margin-bottom: 10px;
            color: #7a1a1a;
            font-size: 0.95rem;
            line-height: 1.5;
        }
        .attention-item:last-child {
            margin-bottom: 0;
        }
        .attention-item i {
            color: var(--primary-red);
            margin-top: 2px;
            flex-shrink: 0;
        }
        .attention-ack {
            display: flex;
            align-items: flex-start;
            gap: 10px;
            margin-top: 16px;
            cursor: pointer;
            font-size: 0.9rem;
            color: var(--text, #333);
        }
        .attention-ack input[type="checkbox"] {
            margin-top: 3px;
            width: 18px;
            height: 18px;
            flex-shrink: 0;
            accent-color: var(--primary-red);
            cursor: pointer;
        }

        /* Serviços adicionais (accordion): Pickup e Door Delivery */
        .additional-services-box { padding: 0; overflow: hidden; }
        .accordion-toggle {
            display: flex; align-items: center; justify-content: space-between; gap: 12px;
            width: 100%; padding: 30px; border: none; background: transparent; text-align: left;
            cursor: pointer; border-radius: 8px !important; color: var(--primary-blue);
        }
        .accordion-toggle h3 { margin-bottom: 0; }
        .accordion-toggle:hover { background: rgba(15, 32, 71, 0.03); }
        .accordion-toggle:focus-visible { outline: 2px solid var(--step-active, #7CB89F); outline-offset: -2px; }
        .accordion-toggle-hint { display: inline-flex; align-items: center; gap: 10px; color: var(--text-muted, #888); font-size: 13px; font-weight: 600; flex-shrink: 0; }
        .accordion-caret { font-size: 1.1rem; color: var(--primary-blue); transition: transform 0.2s ease; }
        .accordion-toggle[aria-expanded="true"] .accordion-caret { transform: rotate(180deg); }
        .accordion-panel { padding: 0 30px 30px; border-top: 1px solid var(--border-color); padding-top: 22px; }
        .accordion-panel .toggle-box { margin-bottom: 0; }
        .road-service-separator { height: 1px; background: var(--border-color); margin: 22px 0; }
        .road-panel { margin-top: 18px; }
        .road-note {
            border-radius: 10px; padding: 11px 14px; font-size: 0.87rem; margin-bottom: 16px;
            border: 1px solid rgba(15, 43, 73, 0.12); background: #fff; color: var(--muted, #6f7884);
            display: flex; align-items: center; gap: 9px;
        }
        .road-note i { color: var(--primary-blue); }
        .road-terminal {
            display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 12px;
            border: 1px dashed var(--border-color); border-radius: 12px; background: #fff;
            font-weight: 600; color: var(--primary-blue); font-size: 14px;
        }
        .road-terminal i { color: var(--primary-blue); }
        .road-results {
            margin-top: 20px; background: white; padding: 20px; border: 1px solid var(--border-color); border-radius: 8px;
        }
        .road-carrier {
            display: flex; align-items: flex-start; gap: 12px; margin-bottom: 12px; padding: 12px 14px;
            background: var(--bg, #eef1f5); border-radius: 8px; border-left: 4px solid var(--accent, #0A8BC4); cursor: pointer;
        }
        .road-carrier:last-child { margin-bottom: 0; }
        .road-carrier:has(input:checked) { background: #f0f7f4; border-left-color: var(--step-active, #7CB89F); }
        .road-carrier input[type="radio"] { margin-top: 4px; flex-shrink: 0; accent-color: var(--primary-blue); }
        .road-carrier-body { display: flex; flex-direction: column; gap: 6px; flex: 1; min-width: 0; }
        .road-carrier-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
        .road-carrier-name { font-weight: 600; color: var(--text, #333); }
        .road-carrier-price { font-weight: 700; color: var(--primary-blue); font-size: 1.05rem; white-space: nowrap; }
        .road-carrier-meta { font-size: 0.9rem; color: var(--muted, #6f7884); }
        .road-carrier-tag {
            display: inline-flex; align-items: center; gap: 4px; font-size: 0.72rem; font-weight: 700; color: #fff;
            background: #7CB89F; padding: 2px 8px; border-radius: 999px;
        }
        .road-carrier-obs { font-size: 0.82rem; color: var(--muted, #6f7884); line-height: 1.4; }
        .road-carrier-obs summary { cursor: pointer; color: var(--primary-blue); font-weight: 600; font-size: 0.82rem; }
        .road-carrier-obs pre { white-space: pre-wrap; font-family: inherit; margin: 6px 0 0; font-size: 0.8rem; }
        .road-carrier-warning { font-size: 0.8rem; color: #8a6d1d; }
        @media (max-width: 768px) {
            .accordion-toggle { padding: 18px; }
            .accordion-panel { padding: 18px 18px 18px; }
        }

        @media (max-width: 768px) {
            #avisoModal .modal-custom,
            #errorModal .modal-custom {
                width: 100%;
                padding: 30px 20px 24px;
            }
            #avisoModal .modal-custom::before,
            #avisoModal .modal-custom::after,
            #errorModal .modal-custom::before,
            #errorModal .modal-custom::after {
                width: 95px;
                top: 88px;
                opacity: 0.16;
            }
            #avisoModal .modal-custom::before,
            #errorModal .modal-custom::before { left: -28px; }
            #avisoModal .modal-custom::after,
            #errorModal .modal-custom::after { right: -28px; }
            #avisoModal .modal-custom h2,
            #errorModal .modal-custom h2 {
                font-size: clamp(2.1rem, 11vw, 2.8rem);
                margin-bottom: 12px;
            }
            #avisoModal .modal-intro,
            #errorModal .modal-intro {
                font-size: 1.45rem;
            }
            #avisoModal .modal-custom ul,
            #errorModal .modal-custom ul {
                margin: 20px auto;
            }
            #avisoModal .modal-custom ul li,
            #errorModal .modal-custom ul li {
                font-size: 1.3rem;
            }
            #errorModal #errorModalList {
                font-size: 1.2rem !important;
            }
            #avisoModal .modal-contact,
            #errorModal .modal-contact {
                font-size: 1.4rem;
            }
            #avisoModal .modal-disclaimer,
            #errorModal .modal-disclaimer {
                font-size: 1.05rem;
            }
            #avisoModal .modal-custom .btn-understand,
            #errorModal .modal-custom .btn-understand {
                width: min(100%, 210px);
                font-size: 1.45rem;
            }
        }

        /* Telas de modal muito estreitas (celulares pequenos) */
        @media (max-width: 420px) {
            #avisoModal .modal-custom,
            #errorModal .modal-custom {
                padding: 26px 16px 20px;
            }
            /* As barras diagonais decorativas competem por espaço em telas estreitas */
            #avisoModal .modal-custom::before,
            #avisoModal .modal-custom::after,
            #errorModal .modal-custom::before,
            #errorModal .modal-custom::after {
                display: none;
            }
            #avisoModal .modal-custom h2,
            #errorModal .modal-custom h2 {
                font-size: clamp(1.8rem, 12vw, 2.3rem);
            }
            #avisoModal .modal-intro,
            #errorModal .modal-intro { font-size: 1.2rem; }
            #avisoModal .modal-custom ul li,
            #errorModal .modal-custom ul li { font-size: 1.1rem; }
            #errorModal #errorModalList { font-size: 1.05rem !important; }
            #avisoModal .modal-contact,
            #errorModal .modal-contact { font-size: 1.15rem; }
            #avisoModal .modal-custom .btn-understand,
            #errorModal .modal-custom .btn-understand { font-size: 1.25rem; }
        }
        
        /* Botão de idioma */
        .language-toggle {
            display: inline-flex; align-items: center; gap: .5rem; padding: .55rem .85rem;
            background: rgba(255,255,255,.2); border: 1px solid rgba(255,255,255,.3); border-radius: 999px;
            color: white; font-weight: 600; cursor: pointer; transition: all .2s ease;
        }
        .language-toggle:hover { background: rgba(255,255,255,.3); }
        .language-toggle-icon { display: inline-flex; width: 24px; height: 24px; align-items: center; justify-content: center; border-radius: 50%; background: #fff; color: var(--primary-blue); font-size: 0.9rem; }
        
        /* Ocultar as seções antigas de layout que não usaremos mais */
        .a-shell, .site-topbar { display: none !important; }

        /* ============================================================
           Facelift 2026 — Segunda página (Formulário + Instruções)
           Fidelidade ao Figma node 105:1593. Somente ajustes visuais
           (cores, fontes, tipos e elementos gráficos), sem mexer nos textos.
           ============================================================ */

        /* App shell empilhado: topo (lp-topbar) + conteúdo + rodapé (lp-footer) */
        #appShell.app-shell {
            flex-direction: column;
            min-height: 100vh;
            max-width: none;
            margin: 0;
            padding: 0;
            gap: 0;
            background: var(--bg-color);
        }
        #appShell .main-container { flex: 1 0 auto; }

        /* ── Header (easyquotes) — Figma 82:916 ── */
        .header-box {
            background-color: #0f2047;
            border: 1px solid rgba(185, 185, 185, 0.82);
            border-radius: 10px;
            padding: 30px clamp(24px, 3.1vw, 60px);
            gap: 24px;
        }
        .header-box h1 {
            font-family: 'Exo 2', sans-serif;
            font-weight: 700;
            font-size: clamp(26px, 3.1vw, 49px);
            line-height: 1.2;
        }
        .header-box p {
            font-family: 'Exo 2', sans-serif;
            font-weight: 400;
            font-size: clamp(14px, 1.1vw, 18px);
            margin-top: 14px;
            color: #ffffff;
        }
        .header-actions {
            display: flex;
            align-items: center;
            gap: clamp(14px, 1.8vw, 35px);
        }

        /* Botão de idioma — Figma 105:2672 (retângulo com borda branca) */
        .header-box .language-toggle {
            height: 52px;
            gap: 10px;
            padding: 0 14px;
            background: transparent;
            border: 1px solid #ffffff;
            border-radius: 11px;
            color: #ffffff;
            font-family: 'Exo 2', sans-serif;
            font-weight: 500;
            text-transform: uppercase;
        }
        .header-box .language-toggle:hover { background: rgba(255, 255, 255, 0.12); }
        .language-toggle-icon {
            width: 24px;
            height: 24px;
            background: none;
            color: #ffffff;
            border-radius: 0;
            flex-shrink: 0;
        }
        .language-toggle-text { font-size: clamp(16px, 1.2vw, 20px); letter-spacing: -0.011em; }
        .language-toggle-caret { width: 20px; height: 20px; color: #ffffff; flex-shrink: 0; }

        /* Botão de ajuda "?" — Figma 105:1548 (círculo azul) */
        .header-help {
            width: 52px;
            height: 52px;
            flex-shrink: 0;
            border: none;
            border-radius: 50%;
            background: #0a8bc4;
            color: #ffffff;
            font-family: 'Exo 2', sans-serif;
            font-weight: 700;
            font-size: 26px;
            line-height: 1;
            cursor: pointer;
            transition: background 0.2s ease, transform 0.2s ease;
        }
        .header-help:hover { background: #0977a8; transform: translateY(-1px); }

        /* ── Sidebar / etapas — Figma 82:817 ── */
        .sidebar h2 {
            font-family: 'Exo 2', sans-serif;
            font-weight: 400;
            font-size: clamp(24px, 2.4vw, 34px);
            line-height: 1.12;
            color: #0f2047;
            margin-bottom: 26px;
        }
        .step {
            background-color: #ffffff;
            border-radius: 8px;
            padding: 15px;
        }
        .step .step-circle {
            width: 38px;
            height: 38px;
            margin-right: 16px;
            background-color: #cccccc;
            font-size: 20px;
            font-weight: 700;
            flex-shrink: 0;
        }
        .step .step-info strong {
            font-family: 'Exo 2', sans-serif;
            font-weight: 700;
            font-size: clamp(16px, 1.3vw, 20px);
            text-transform: uppercase;
            color: #bfbfbf;
            letter-spacing: 0.0025em;
        }
        .step .step-info span { color: #a6a6a6; font-size: 12px; }

        /* Etapa ativa: AZUL (#0A8BC4) com círculo azul-escuro — Figma 82:798 */
        .step.active, .step-item.active {
            background-color: #0a8bc4 !important;
            color: #ffffff !important;
        }
        .step.active .step-circle, .step-item.active .step-circle {
            background-color: #0f2047 !important;
            color: #ffffff !important;
        }
        .step.active .step-info strong, .step-item.active .step-info strong,
        .step.active .step-info span, .step-item.active .step-info span {
            color: #ffffff !important;
        }

        /* Botão primário (AVANÇAR / GERAR COTAÇÃO) — Verde Água do design system */
        .btn-primary-custom { background-color: #7cb89f; color: #ffffff; }
        .btn-primary-custom:hover:not(:disabled) { background-color: #6fae93; }
        .btn-primary-custom:disabled { background-color: #a0a5b1; }

        /* ── Modal ATENÇÃO — Figma 385:4009 ── */
        #avisoModal .modal-custom,
        #errorModal .modal-custom {
            background: #0f2047;
            border-radius: 20px;
            box-shadow: 0 4px 15.3px rgba(0, 0, 0, 0.26);
        }
        #avisoModal .modal-custom .btn-understand,
        #errorModal .modal-custom .btn-understand {
            background: #0a8bc4;
            border-radius: 11px;
            box-shadow: none;
        }
        #avisoModal .modal-custom .btn-understand:hover,
        #errorModal .modal-custom .btn-understand:hover { background: #0977a8; }
        #avisoModal .modal-custom ul li::before,
        #errorModal .modal-custom ul li::before {
            border-color: #6f9fd0;
            color: #6f9fd0;
        }
        /* Barras decorativas em diagonal (Modo_de_isolamento) recoloridas para o azul-escuro */
        #avisoModal .modal-custom::before, #avisoModal .modal-custom::after,
        #errorModal .modal-custom::before, #errorModal .modal-custom::after {
            opacity: 0.55;
            background: repeating-linear-gradient(
                to bottom,
                transparent 0, transparent 20px,
                #1c2e57 20px, #1c2e57 40px,
                transparent 40px, transparent 60px);
        }

        /* Sidebar mais larga apenas no desktop (não quebrar o empilhado mobile) */
        @media (min-width: 1025px) {
            .sidebar { width: 340px; }
        }
