:root {
    --page: #f5f7f8;
    --surface: #ffffff;
    --ink: #17202a;
    --muted: #687384;
    --line: #dfe6ea;
    --green: #11a860;
    --green-dark: #087744;
    --orange: #ffb84d;
    --red: #d64545;
    --shadow: 0 18px 45px rgba(31, 41, 55, 0.12);
}

* {
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    margin: 0;
    background:
        radial-gradient(circle at top left, rgba(17, 168, 96, 0.12), transparent 34rem),
        linear-gradient(180deg, #f9fbfb 0%, var(--page) 100%);
    color: var(--ink);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    letter-spacing: 0;
}

button,
input,
select {
    font: inherit;
}

.shipping-page,
.app-shell {
    min-height: 100vh;
}

.shipping-page {
    padding: 32px 16px;
}

.app-shell {
    width: min(100%, 460px);
    margin: 0 auto;
    padding: 22px 16px 32px;
}

.shipping-header,
.app-header {
    display: flex;
    align-items: center;
    gap: 14px;
}

.shipping-header {
    max-width: 980px;
    margin: 0 auto 16px;
}

.public-form-header {
    width: 100%;
    max-width: 760px;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
    margin-bottom: 18px;
}

.public-form-title {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.public-form-title h1,
.public-form-title .page-title {
    margin: 0;
}

.public-channel-inline {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #0f172a;
    font-size: 14px;
}

.public-channel-inline i {
    color: #16a34a;
    font-size: 16px;
}

.public-channel-inline strong {
    font-weight: 900;
}

.app-header {
    width: min(100%, 430px);
    padding: 18px 4px 16px;
}

.brand-mark,
.result-icon {
    display: grid;
    flex: 0 0 auto;
    place-items: center;
    border-radius: 8px;
}

.brand-mark {
    width: 48px;
    height: 48px;
    background: var(--ink);
    color: #ffffff;
    font-size: 1.45rem;
}

.brand-name {
    margin: 0 0 3px;
    color: var(--green-dark);
    font-size: 0.83rem;
    font-weight: 800;
    text-transform: uppercase;
}

h1 {
    margin: 0;
    font-size: 1.45rem;
    line-height: 1.15;
}

.result-panel p,
.field-help,
.config-note {
    margin: 0;
    color: var(--muted);
    font-size: 0.91rem;
    line-height: 1.45;
}

.form-panel,
.shipping-card,
.result-panel {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.form-panel {
    display: grid;
    gap: 15px;
    padding: 18px;
}

.shipping-card {
    display: grid;
    gap: 15px;
    width: 100%;
    padding: 24px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

.shalom-fields,
.delivery-fields {
    display: grid;
    gap: 15px;
    padding-top: 2px;
}

.shipping-card.is-agency-mode .shalom-fields {
    display: contents;
}

.shipping-card.is-agency-mode #receiverDocumentField {
    order: 3;
}

.shipping-card.is-agency-mode #receiverNameField {
    order: 4;
}

.shipping-card.is-agency-mode #agencyBlock {
    order: 5;
}

.shipping-card.is-agency-mode .primary-button {
    order: 6;
}

.manual-agency-fields {
    display: grid;
    gap: 15px;
}

.shipping-warning {
    margin-top: 0;
    padding: 10px 12px;
    border: 1px solid #facc15;
    border-radius: 10px;
    background: #fffbeb;
    color: #92400e;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
}

.shipping-layout {
    width: 100%;
    max-width: 980px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 430px;
    justify-content: center;
    gap: 24px;
    align-items: start;
}

.shipping-layout.has-map {
    grid-template-columns: 430px minmax(480px, 1fr);
    justify-content: stretch;
}

.shipping-map-panel {
    position: sticky;
    top: 24px;
}

.map-card {
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

.map-title {
    margin-bottom: 10px;
    color: var(--ink);
    font-size: 0.94rem;
    font-weight: 800;
}

.map-card iframe {
    width: 100%;
    height: 430px;
    border: 0;
    border-radius: 12px;
}

.manual-page {
    width: 100%;
    max-width: 1100px;
    min-height: 100vh;
    margin: 0 auto;
    padding: 32px 16px;
}

.manual-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.manual-header-main {
    display: flex;
    align-items: center;
    gap: 14px;
}

.manual-form-card {
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
    padding: 24px;
}

.manual-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 28px;
    align-items: start;
}

.manual-section {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}

.manual-section h3 {
    margin: 0 0 4px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e5e7eb;
    color: #0f172a;
    font-size: 1rem;
    font-weight: 900;
    line-height: 1.2;
}

.manual-inline-fields {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 12px;
}

.manual-map-panel {
    margin-top: 2px;
}

.manual-map-panel .map-card iframe {
    height: 300px;
}

.manual-empty-state {
    padding: 18px;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
    background: #f8fafc;
    color: #64748b;
    font-size: 0.92rem;
    line-height: 1.45;
}

.manual-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
    padding-top: 18px;
    border-top: 1px solid #e5e7eb;
}

.manual-actions .btn {
    min-width: 180px;
}

.is-hidden {
    display: none !important;
}

.d-none {
    display: none !important;
}

.field {
    display: grid;
    gap: 7px;
}

.manual-document-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: stretch;
}

.manual-search-button {
    width: auto;
    min-height: 48px;
    padding-right: 14px;
    padding-left: 14px;
    white-space: nowrap;
}

.shalom-person-card {
    display: grid;
    gap: 10px;
    padding: 12px;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    background: #f8fbff;
}

.shalom-person-title {
    color: #0f172a;
    font-size: 0.92rem;
}

.shalom-person-rows {
    display: grid;
    gap: 6px;
}

.shalom-person-row {
    display: grid;
    grid-template-columns: 130px minmax(0, 1fr);
    gap: 8px;
    color: #475569;
    font-size: 0.86rem;
}

.shalom-person-row strong {
    min-width: 0;
    color: #0f172a;
    overflow-wrap: anywhere;
}

.shalom-person-message {
    font-size: 0.88rem;
    font-weight: 750;
}

.shalom-person-message.success {
    color: var(--green-dark);
}

.shalom-person-message.error {
    color: #9f1d1d;
}

.shalom-person-message.warning,
.shalom-person-message.info {
    color: #475569;
}

.shalom-person-technical {
    color: #64748b;
    font-size: 0.76rem;
    font-weight: 700;
    line-height: 1.35;
}

.admin-filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 12px;
    align-items: end;
}

.admin-filter-card:not(.admin-toolbar) {
    display: block;
    margin: 0 0 14px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.admin-filter-grid label {
    display: grid;
    gap: 5px;
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 850;
}

.admin-filter-grid input,
.admin-filter-grid select {
    min-height: 36px;
    padding: 7px 9px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    color: var(--ink);
    font: inherit;
}

.api-log-filter-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: flex-start;
    min-width: 0;
}

.api-log-filter-actions .btn {
    min-height: 36px;
    white-space: nowrap;
}

.api-log-sort {
    color: inherit;
    font-weight: 900;
    text-decoration: none;
}

.api-log-sort:hover,
.api-log-sort:focus-visible {
    color: var(--green-dark);
    outline: 0;
}

.api-log-payload-cell {
    max-width: 220px;
    color: #475569;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.76rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
}

.detail-grid div {
    min-width: 0;
}

.detail-grid dt {
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
}

.detail-grid dd {
    margin: 3px 0 0;
    color: var(--ink);
    font-size: 0.9rem;
    font-weight: 750;
    overflow-wrap: anywhere;
}

.api-logs-shell {
    width: min(1500px, calc(100% - 32px));
}

.api-page-header {
    align-items: center;
    padding: 16px 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 14px 34px rgba(31, 41, 55, 0.08);
}

.api-total-badge,
.api-card-heading span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 9px;
    border: 1px solid rgba(17, 168, 96, 0.22);
    border-radius: 999px;
    background: #eefbf4;
    color: var(--green-dark);
    font-size: 0.76rem;
    font-weight: 900;
}

.api-log-filter-card,
.api-detail-card {
    display: grid;
    gap: 14px;
    margin-bottom: 14px;
    padding: 16px;
    box-shadow: 0 12px 30px rgba(31, 41, 55, 0.07);
}

.api-card-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-width: 0;
}

.api-card-heading h2 {
    margin: 0;
    color: var(--ink);
    font-size: 1rem;
    font-weight: 900;
}

.api-log-filter-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(170px, 1fr));
    gap: 12px;
    align-items: end;
}

.api-log-filter-grid label {
    display: grid;
    min-width: 0;
    gap: 6px;
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 900;
}

.api-log-filter-grid label span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.api-log-filter-grid input,
.api-log-filter-grid select {
    width: 100%;
    min-width: 0;
    min-height: 38px;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: var(--ink);
    font: inherit;
    outline: 0;
}

.api-log-filter-grid input:focus,
.api-log-filter-grid select:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.api-log-filter-actions {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.api-log-filter-actions .btn {
    min-height: 38px;
    padding: 8px 12px;
    white-space: nowrap;
}

.api-log-table-wrap {
    border: 1px solid var(--line);
    background: #ffffff;
    box-shadow: 0 12px 30px rgba(31, 41, 55, 0.07);
}

.api-log-table {
    min-width: 1420px;
}

.api-log-table th:last-child,
.api-log-table td:last-child {
    position: static;
    min-width: 150px;
    width: 150px;
    background: inherit;
    box-shadow: none;
}

.api-log-table td {
    vertical-align: top;
}

.api-log-endpoint,
.api-log-code,
.api-log-request-id {
    max-width: 190px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.api-log-payload-cell,
.api-log-message {
    display: -webkit-box;
    max-width: 240px;
    overflow: hidden;
    color: #475569;
    line-height: 1.35;
    overflow-wrap: anywhere;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.api-log-payload-cell {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.76rem;
}

.api-log-message {
    color: var(--ink);
    font-weight: 750;
}

.api-http-badge,
.api-method-badge,
.api-service-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    max-width: 100%;
    min-height: 24px;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 900;
    line-height: 1;
    white-space: nowrap;
}

.api-http-badge {
    border: 1px solid rgba(148, 163, 184, 0.34);
    background: #f8fafc;
    color: #475569;
}

.api-http-danger {
    border-color: rgba(220, 38, 38, 0.26);
    background: #fff1f2;
    color: #b91c1c;
}

.api-http-warning {
    border-color: rgba(245, 158, 11, 0.34);
    background: #fffbeb;
    color: #92400e;
}

.api-http-muted {
    border-color: rgba(100, 116, 139, 0.22);
    background: #f1f5f9;
    color: #475569;
}

.api-method-badge {
    border: 1px solid rgba(37, 99, 235, 0.22);
    background: #eff6ff;
    color: #1d4ed8;
}

.api-service-badge {
    justify-content: flex-start;
    border: 1px solid rgba(17, 168, 96, 0.18);
    background: #f0fdf4;
    color: var(--green-dark);
    overflow: hidden;
    text-overflow: ellipsis;
}

.api-detail-button,
.api-copy-button {
    min-height: 30px;
    padding: 6px 9px;
    font-size: 0.76rem;
    white-space: nowrap;
}

.api-copy-button.is-copied {
    border-color: rgba(17, 168, 96, 0.28);
    background: #eefbf4;
    color: var(--green-dark);
}

.api-log-pagination {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 12px;
}

.api-log-pagination span {
    color: var(--muted);
    font-size: 0.8rem;
    font-weight: 850;
}

.api-detail-grid {
    grid-template-columns: repeat(4, minmax(180px, 1fr));
}

.api-detail-wide {
    grid-column: span 2;
}

.api-log-json {
    max-height: 520px;
    margin: 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fafc;
}

@media (max-width: 1100px) {
    .api-log-filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .api-detail-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .api-logs-shell {
        width: min(100%, calc(100% - 20px));
        padding-top: 12px;
    }

    .api-page-header {
        display: grid;
        gap: 12px;
        padding: 13px;
    }

    .api-page-header .admin-header-actions {
        justify-content: stretch;
    }

    .api-page-header .admin-header-actions > * {
        width: 100%;
    }

    .api-log-filter-card,
    .api-detail-card {
        padding: 12px;
    }

    .api-card-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
    }

    .api-log-filter-grid,
    .api-detail-grid {
        grid-template-columns: 1fr;
    }

    .api-detail-wide {
        grid-column: auto;
    }

    .api-log-filter-actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .api-log-filter-actions .btn {
        width: 100%;
    }

    .api-log-table-wrap {
        overflow: visible;
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .api-log-table {
        display: block;
        min-width: 0;
        border-collapse: separate;
        border-spacing: 0;
    }

    .api-log-table thead {
        display: none;
    }

    .api-log-table tbody {
        display: grid;
        gap: 10px;
    }

    .api-log-table tr {
        display: grid;
        gap: 8px;
        padding: 12px;
        border: 1px solid var(--line);
        border-radius: 8px;
        background: #ffffff;
        box-shadow: 0 8px 22px rgba(31, 41, 55, 0.06);
    }

    .api-log-table td,
    .api-log-table td:last-child {
        display: grid;
        grid-template-columns: 96px minmax(0, 1fr);
        gap: 8px;
        min-width: 0;
        width: auto;
        max-width: none;
        padding: 0;
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .api-log-table td::before {
        content: attr(data-label);
        color: var(--muted);
        font-size: 0.68rem;
        font-weight: 900;
        text-transform: uppercase;
    }

    .api-log-endpoint,
    .api-log-code,
    .api-log-request-id,
    .api-log-payload-cell,
    .api-log-message {
        max-width: none;
    }

    .api-detail-button {
        width: 100%;
    }

    .api-log-pagination {
        justify-content: stretch;
    }

    .api-log-pagination .admin-filter,
    .api-log-pagination span {
        flex: 1 1 auto;
        justify-content: center;
        text-align: center;
    }
}

@media (max-width: 720px) {
    .admin-filter-grid {
        grid-template-columns: 1fr;
    }

    .api-log-filter-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .api-log-filter-actions .btn {
        width: 100%;
    }

    .api-log-payload-cell {
        max-width: none;
    }
}

.field label {
    font-size: 0.9rem;
    font-weight: 750;
}

.control {
    display: grid;
    grid-template-columns: 22px 1fr;
    align-items: center;
    min-height: 48px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fbfcfd;
    color: var(--muted);
    transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.control:focus-within {
    border-color: var(--green);
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.13);
}

.control i {
    padding-left: 13px;
    font-size: 1rem;
}

.control input,
.control select {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--ink);
    padding: 12px 13px 12px 10px;
}

.phone-input-group {
    display: flex;
    align-items: center;
    width: 100%;
    height: 48px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #ffffff;
    overflow: hidden;
    transition: border-color 160ms ease, box-shadow 160ms ease;
}

.phone-input-group:focus-within {
    border-color: #22c55e;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.12);
}

.phone-input-group.has-error {
    border-color: var(--red);
}

.phone-input-group.has-error:focus-within {
    box-shadow: 0 0 0 3px rgba(214, 69, 69, 0.12);
}

.phone-prefix {
    display: flex;
    align-items: center;
    gap: 6px;
    height: 100%;
    min-width: 82px;
    padding: 0 12px;
    border-right: 1px solid var(--line);
    background: #f8fafc;
    color: #64748b;
    font-weight: 700;
}

.phone-prefix i {
    color: #25d366;
    font-size: 1rem;
}

.phone-input {
    flex: 1;
    min-width: 0;
    height: 100%;
    border: 0;
    outline: 0;
    padding: 0 14px;
    background: #ffffff;
    color: #0f172a;
    font-size: 0.94rem;
}

.phone-input::placeholder {
    color: #94a3b8;
}

.phone-input:-webkit-autofill,
.phone-input:-webkit-autofill:hover,
.phone-input:-webkit-autofill:focus {
    -webkit-text-fill-color: #0f172a;
    box-shadow: 0 0 0 1000px #ffffff inset;
    transition: background-color 5000s ease-in-out 0s;
}

.control select {
    appearance: none;
    cursor: pointer;
}

.select-control {
    position: relative;
}

.select-control::after {
    content: "\F282";
    position: absolute;
    right: 13px;
    color: var(--muted);
    font-family: "bootstrap-icons";
    font-size: 0.85rem;
    pointer-events: none;
}

.select-control select {
    padding-right: 34px;
}

.has-error {
    color: var(--red) !important;
}

.has-error:is(input, select) {
    color: var(--ink) !important;
}

.field-error {
    min-height: 1.08rem;
    margin: 0;
    color: var(--red);
    font-size: 0.79rem;
    line-height: 1.35;
}

.field-help {
    min-height: 1.25rem;
}

.agency-field {
    position: relative;
}

.agency-results {
    display: grid;
    gap: 7px;
    max-height: 300px;
    margin: 0;
    padding: 0;
    overflow: auto;
    list-style: none;
}

.agency-option {
    display: grid;
    width: 100%;
    gap: 2px;
    padding: 11px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: var(--ink);
    text-align: left;
    cursor: pointer;
}

.agency-option:hover,
.agency-option:focus-visible {
    border-color: var(--green);
    outline: 0;
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.agency-more-button {
    width: 100%;
    min-height: 40px;
    border: 1px dashed rgba(17, 168, 96, 0.45);
    border-radius: 8px;
    background: #f3fbf7;
    color: var(--green-dark);
    font-size: 0.84rem;
    font-weight: 800;
    cursor: pointer;
}

.agency-more-button:hover,
.agency-more-button:focus-visible {
    border-style: solid;
    outline: 0;
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.agency-title {
    color: #111827;
    font-size: 0.88rem;
    font-weight: 800;
}

.agency-location {
    margin-top: 2px;
    color: #64748b;
    font-size: 0.76rem;
}

.agency-address {
    margin-top: 2px;
    color: #9ca3af;
    font-size: 0.75rem;
    line-height: 1.35;
}

.selected-agency {
    display: grid;
    gap: 2px;
    margin-top: 3px;
    padding: 12px;
    border: 1px solid rgba(17, 168, 96, 0.28);
    border-radius: 8px;
    background: #f3fbf7;
}

.delivery-location-box {
    display: grid;
    gap: 8px;
}

.location-button {
    width: 100%;
}

.location-button:disabled {
    opacity: 0.72;
    cursor: wait;
}

.map-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    width: fit-content;
    min-height: 34px;
    margin-top: 8px;
    padding: 7px 11px;
    border: 1px solid rgba(17, 168, 96, 0.28);
    border-radius: 8px;
    background: #ffffff;
    color: var(--green-dark);
    font-size: 0.82rem;
    font-weight: 800;
    text-decoration: none;
}

.map-link:hover,
.map-link:focus-visible {
    border-color: var(--green);
    outline: 0;
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.primary-button,
.secondary-button,
.whatsapp-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 48px;
    width: 100%;
    border-radius: 8px;
    border: 0;
    color: #ffffff;
    font-weight: 800;
    text-decoration: none;
    cursor: pointer;
}

.primary-button {
    margin-top: 2px;
    background: var(--ink);
}

.primary-button:hover,
.primary-button:focus-visible {
    background: #0f1720;
}

.secondary-button {
    background: var(--ink);
}

.whatsapp-button {
    background: var(--green);
}

.whatsapp-button:hover,
.whatsapp-button:focus-visible {
    background: var(--green-dark);
}

.whatsapp-button.is-disabled {
    background: #9ab7a8;
    cursor: not-allowed;
}

.result-panel {
    display: grid;
    justify-items: center;
    gap: 15px;
    max-width: 460px;
    margin-top: 38px;
    margin-right: auto;
    margin-left: auto;
    padding: 26px 18px 20px;
    text-align: center;
}

.result-icon {
    width: 62px;
    height: 62px;
    font-size: 2rem;
}

.success-icon {
    background: #e8f8ef;
    color: var(--green);
}

.error-icon {
    background: #fff0f0;
    color: var(--red);
}

.summary-box {
    width: 100%;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fbfcfd;
    text-align: left;
}

.summary-box p {
    margin: 0 0 7px;
    color: var(--ink);
    font-size: 0.93rem;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.summary-box p:first-child {
    font-weight: 850;
}

.error-list {
    width: 100%;
    margin: 0;
    padding: 12px 14px 12px 30px;
    border-radius: 8px;
    background: #fff8f8;
    color: #8f1d1d;
    text-align: left;
}

.error-list li + li {
    margin-top: 6px;
}

.config-note {
    font-size: 0.82rem;
}

@media (min-width: 700px) {
    body {
        display: grid;
        place-items: start center;
    }

    .app-shell {
        min-height: auto;
        padding-top: 36px;
    }
}

@media (max-width: 900px) {
    .manual-page {
        max-width: 430px;
        padding: 22px 16px 32px;
    }

    .manual-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .manual-header-main {
        align-items: flex-start;
    }

    .manual-form-card {
        padding: 18px;
    }

    .manual-grid,
    .manual-inline-fields {
        grid-template-columns: 1fr;
    }

    .manual-actions {
        flex-direction: column-reverse;
    }

    .manual-actions .btn {
        width: 100%;
    }

    .manual-map-panel .map-card iframe {
        height: 260px;
    }

    .shipping-header,
    .shipping-layout {
        max-width: 430px;
    }

    .public-form-header {
        flex-direction: column;
        align-items: stretch;
    }

    .public-form-title {
        justify-content: flex-start;
    }

    .public-channel-inline {
        align-self: flex-start;
    }

    .shipping-layout {
        display: block;
    }

    .shipping-map-panel {
        position: static;
        margin-top: 12px;
    }

    .map-card iframe {
        height: 260px;
    }
}

.admin-shell {
    width: min(100%, 1180px);
    min-height: 100vh;
    margin: 0 auto;
    padding: 28px 16px 36px;
}

.admin-login {
    display: grid;
    justify-items: center;
    gap: 16px;
    width: min(100%, 420px);
    margin: 8vh auto 0;
    padding: 26px 18px 20px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
    text-align: center;
}

.admin-login-form {
    display: grid;
    gap: 15px;
    width: 100%;
}

.admin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.admin-header-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
    align-items: center;
}

.admin-title-block {
    display: grid;
    gap: 6px;
    min-width: 220px;
}

.admin-title-block h1 {
    margin-bottom: 0;
}

.admin-module-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}

.admin-module-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 5px 9px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: #475569;
    font-size: 0.76rem;
    font-weight: 850;
    text-decoration: none;
}

.admin-module-nav a:hover,
.admin-module-nav a:focus-visible {
    border-color: var(--green);
    color: var(--green-dark);
    outline: 0;
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.admin-module-nav a.is-active {
    border-color: rgba(17, 168, 96, 0.28);
    background: #eefbf4;
    color: var(--green-dark);
}

.admin-kicker {
    margin: 0 0 4px;
    color: var(--green-dark);
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-logout,
.admin-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 34px;
    padding: 7px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: var(--ink);
    font-size: 0.8rem;
    font-weight: 800;
    text-decoration: none;
}

.admin-logout:hover,
.admin-action:hover,
.admin-logout:focus-visible,
.admin-action:focus-visible {
    border-color: var(--green);
    outline: 0;
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.admin-config-menu {
    position: relative;
}

.admin-config-menu summary {
    cursor: pointer;
    list-style: none;
}

.admin-config-menu summary::-webkit-details-marker {
    display: none;
}

.admin-config-menu-list {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 30;
    display: grid;
    gap: 4px;
    min-width: 210px;
    padding: 7px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.14);
}

.admin-config-menu-list a {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    padding: 8px 9px;
    border-radius: 7px;
    color: var(--ink);
    font-size: 0.84rem;
    font-weight: 800;
    text-decoration: none;
}

.admin-config-menu-list a:hover,
.admin-config-menu-list a:focus-visible {
    outline: 0;
    background: #eefbf4;
    color: var(--green-dark);
}

.admin-config-menu-section {
    margin: 4px 2px 2px;
    padding: 7px 7px 4px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 0;
    text-transform: uppercase;
}

.admin-action-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin: 0 0 18px;
    flex-wrap: wrap;
}

.admin-action-left,
.admin-action-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.inline-form {
    margin: 0;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 42px;
    padding: 10px 16px;
    border: 1px solid transparent;
    border-radius: 9px;
    font-size: 0.9rem;
    font-weight: 800;
    line-height: 1.1;
    text-decoration: none;
    cursor: pointer;
}

.btn-success-action {
    background: #16a34a;
    border-color: #16a34a;
    color: #ffffff;
}

.btn-success-action:hover,
.btn-success-action:focus-visible {
    background: #15803d;
    border-color: #15803d;
    color: #ffffff;
    outline: 0;
}

.btn-danger-action {
    background: #dc2626;
    border-color: #dc2626;
    color: #ffffff;
}

.btn-danger-action:hover,
.btn-danger-action:focus-visible {
    background: #b91c1c;
    border-color: #b91c1c;
    color: #ffffff;
    outline: 0;
}

.btn-dark-action {
    background: #111827;
    border-color: #111827;
    color: #ffffff;
}

.btn-dark-action:hover,
.btn-dark-action:focus-visible {
    background: #0f172a;
    border-color: #0f172a;
    color: #ffffff;
    outline: 0;
}

.btn-secondary-action {
    background: #ffffff;
    border-color: var(--line);
    color: var(--ink);
}

.btn-secondary-action:hover,
.btn-secondary-action:focus-visible {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: var(--ink);
    outline: 0;
}

.whatsapp-action {
    color: var(--green-dark);
}

.danger-action {
    border-color: rgba(214, 69, 69, 0.28);
    color: #9f1d1d;
}

.danger-action:hover,
.danger-action:focus-visible {
    border-color: var(--red);
    box-shadow: 0 0 0 3px rgba(214, 69, 69, 0.12);
}

.cancel-selected-button {
    background: #dc2626;
}

.cancel-selected-button:hover,
.cancel-selected-button:focus-visible {
    background: #b91c1c;
}

.admin-empty,
.admin-toolbar,
.dispatch-summary-card,
.dispatch-batch-card,
.admin-table-wrap,
.admin-detail-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.dispatch-summary-card,
.dispatch-batch-card {
    margin-bottom: 14px;
    padding: 14px;
}

.dispatch-summary-card {
    display: grid;
    grid-template-columns: minmax(190px, 0.8fr) minmax(0, 2.2fr);
    gap: 16px;
    align-items: stretch;
}

.dispatch-summary-card h2 {
    margin: 0 0 5px;
    font-size: 1.1rem;
}

.section-heading h2 {
    margin: 0;
    font-size: 1rem;
}

.dispatch-origin {
    margin: 0;
    color: var(--muted);
    font-size: 0.86rem;
    font-weight: 750;
}

.dispatch-summary-metrics,
.dispatch-batch-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.dispatch-summary-metrics span {
    display: grid;
    gap: 5px;
    min-width: 136px;
    padding: 11px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fbfcfd;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 750;
}

.dispatch-summary-metrics small {
    color: var(--muted);
    font-size: 0.74rem;
    font-weight: 850;
    line-height: 1.15;
}

.dispatch-summary-metrics strong {
    color: var(--ink);
    font-size: 1.35rem;
    line-height: 1;
}

.orders-summary-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(150px, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.orders-summary-card,
.orders-filter-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.orders-summary-card {
    display: grid;
    gap: 6px;
    padding: 14px;
}

.orders-summary-card span {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 800;
}

.orders-summary-card strong {
    color: var(--ink);
    font-size: 1.35rem;
    line-height: 1;
}

.orders-summary-card small,
.muted-line {
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 750;
}

.orders-admin-shell {
    width: min(100%, 1360px);
}

.orders-tracking-panel {
    display: grid;
    gap: 14px;
    margin-bottom: 14px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.orders-tracking-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.orders-tracking-head h2 {
    margin: 2px 0 0;
    color: var(--ink);
    font-size: 1.15rem;
    line-height: 1.2;
}

.orders-eyebrow {
    color: var(--green-dark);
    font-size: 0.76rem;
    font-weight: 900;
    text-transform: uppercase;
}

.orders-cache-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 7px;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 750;
}

.orders-cache-meta span {
    padding: 6px 8px;
    border: 1px solid #edf2f7;
    border-radius: 999px;
    background: #f8fafc;
}

.orders-cache-meta strong {
    color: var(--ink);
}

.orders-status-tabs {
    display: grid;
    grid-template-columns: repeat(5, minmax(150px, 1fr));
    gap: 10px;
}

.orders-status-tab {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-height: 50px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #f8fafc;
    color: var(--ink);
    font-size: 0.86rem;
    font-weight: 850;
    text-decoration: none;
    transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.orders-status-tab strong {
    min-width: 38px;
    padding: 5px 8px;
    border-radius: 999px;
    background: #ffffff;
    color: var(--ink);
    text-align: center;
}

.orders-status-tab:hover,
.orders-status-tab:focus-visible,
.orders-status-tab.is-active {
    border-color: rgba(17, 168, 96, 0.35);
    background: #eefbf4;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
    outline: 0;
    transform: translateY(-1px);
}

.orders-filter-card {
    display: grid;
    gap: 12px;
    margin-bottom: 14px;
    padding: 14px;
}

.orders-action-card {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.btn-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    min-height: 22px;
    padding: 2px 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.2);
    color: inherit;
    font-size: 0.75rem;
    font-weight: 900;
}

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

.orders-inline-action-form,
.orders-visible-action-form {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.orders-visible-action-form {
    padding-left: 8px;
    border-left: 1px solid var(--line);
}

.orders-diagnostic-card {
    margin-bottom: 14px;
}

.orders-error-details {
    margin: -4px 0 14px;
    border: 1px solid rgba(220, 38, 38, 0.22);
    border-radius: 8px;
    background: #fff8f8;
}

.orders-error-details summary {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    padding: 9px 12px;
    color: #991b1b;
    font-size: 0.86rem;
    font-weight: 850;
    cursor: pointer;
    list-style: none;
}

.orders-error-details summary::-webkit-details-marker {
    display: none;
}

.orders-error-details summary span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    min-height: 22px;
    margin-left: auto;
    padding: 2px 7px;
    border-radius: 999px;
    background: #fee2e2;
    color: #991b1b;
    font-size: 0.75rem;
}

.orders-error-detail-list {
    display: grid;
    gap: 8px;
    padding: 0 12px 12px;
}

.orders-error-detail-list article {
    display: grid;
    gap: 4px;
    padding: 9px;
    border: 1px solid rgba(220, 38, 38, 0.16);
    border-radius: 8px;
    background: #ffffff;
    color: #7f1d1d;
}

.orders-error-detail-list strong,
.orders-error-detail-list p,
.orders-error-detail-list small {
    margin: 0;
    overflow-wrap: anywhere;
}

.orders-error-detail-list strong {
    font-size: 0.78rem;
}

.orders-error-detail-list p {
    font-size: 0.76rem;
    font-weight: 750;
}

.orders-error-detail-list small {
    color: #9f1d1d;
    font-size: 0.72rem;
    line-height: 1.35;
}

.orders-filter-form {
    display: grid;
    gap: 12px;
}

.orders-search {
    position: relative;
}

.orders-search-status {
    position: absolute;
    right: 12px;
    top: 50%;
    display: none;
    transform: translateY(-50%);
    color: var(--muted);
    font-size: 0.74rem;
    font-weight: 850;
    pointer-events: none;
}

.orders-filter-form.is-searching .orders-search-status {
    display: inline-flex;
}

.orders-filter-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(140px, 1fr));
    gap: 10px;
}

.orders-filter-grid label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 850;
}

.admin-filter-input {
    min-height: 42px;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: var(--ink);
    padding: 9px 11px;
    outline: 0;
}

.admin-filter-input:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.orders-filter-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.orders-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.orders-table {
    width: 100%;
    min-width: 1080px;
    border-collapse: collapse;
}

.orders-table th,
.orders-table td {
    padding: 11px 10px;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

.orders-table th.select-col,
.orders-table td.select-col,
.orders-select-column {
    width: 42px;
    min-width: 42px;
    max-width: 42px;
    padding-right: 8px;
    padding-left: 8px;
    text-align: center !important;
    vertical-align: middle !important;
}

.orders-table .row-check,
.orders-table #checkAll,
.orders-select-column input {
    display: block;
    width: 16px;
    height: 16px;
    margin: 0 auto;
    accent-color: var(--green);
    cursor: pointer;
}

.orders-table tbody tr {
    transition: background 160ms ease;
}

.orders-table tbody tr:hover {
    background: #fbfdfc;
}

.orders-table tbody tr.has-tracking-error {
    background: #fff8f8;
    box-shadow: inset 4px 0 0 #dc2626;
}

.orders-table tbody tr.has-tracking-error:hover {
    background: #fff3f3;
}

.orders-table tbody tr.has-tracking-error .orders-actions-cell {
    background: #fff8f8;
}

.orders-table tbody tr.has-tracking-error:hover .orders-actions-cell {
    background: #fff3f3;
}

.orders-table th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f8fafc;
    color: #4b5563;
    font-size: 0.72rem;
    font-weight: 850;
    text-transform: uppercase;
}

.table-compact td {
    color: var(--ink);
    font-size: 0.8rem;
    line-height: 1.35;
}

.cell-truncate {
    display: -webkit-box;
    max-width: 190px;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-height: 1.35;
}

.destination-cell {
    max-width: 220px;
}

.destination-cell strong {
    display: block;
    color: var(--ink);
    font-size: 0.84rem;
    line-height: 1.25;
}

.shalom-orders-table {
    min-width: 1360px;
}

.order-status {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    width: max-content;
    max-width: 100%;
    padding: 4px 9px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 850;
    white-space: nowrap;
}

.order-status-pendiente {
    border: 1px solid rgba(245, 158, 11, 0.32);
    background: #fff7e6;
    color: #9a5b00;
}

.order-status-transito {
    border: 1px solid rgba(59, 130, 246, 0.28);
    background: #eff6ff;
    color: #1d4ed8;
}

.order-status-demora {
    border: 1px solid rgba(245, 158, 11, 0.34);
    background: #fffbeb;
    color: #92400e;
}

.order-status-entregado {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #e8f8ef;
    color: var(--green-dark);
}

.order-status-anulado {
    border: 1px solid rgba(214, 69, 69, 0.28);
    background: #fff3f3;
    color: #9f1d1d;
}

.order-status-desconocido {
    border: 1px solid rgba(107, 114, 128, 0.28);
    background: #f3f4f6;
    color: #4b5563;
}

.order-status-error {
    border: 1px solid rgba(220, 38, 38, 0.55);
    background: #fee2e2;
    color: #b91c1c;
}

.order-status-error i {
    color: #dc2626;
}

.payment-badge {
    display: inline-flex;
    align-items: center;
    width: max-content;
    margin-top: 5px;
    padding: 3px 8px;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 850;
}

.payment-paid {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #e8f8ef;
    color: var(--green-dark);
}

.payment-unpaid {
    border: 1px solid rgba(245, 158, 11, 0.32);
    background: #fff7e6;
    color: #9a5b00;
}

.orders-tracking-table {
    min-width: 980px;
    table-layout: fixed;
}

.orders-tracking-table th:first-child,
.orders-tracking-table td:first-child {
    width: 150px;
    max-width: 150px;
}

.tracking-status-cell {
    position: relative;
    overflow: visible;
    white-space: normal;
}

.tracking-state-time {
    display: block;
    max-width: 100%;
    margin-top: 5px;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 800;
    line-height: 1.25;
    white-space: nowrap;
}

.tracking-error-cell {
    color: #dc2626;
}

.tracking-error-cell .tracking-error-label,
.tracking-error-cell .tracking-error-link,
.tracking-error-cell a,
.tracking-error-cell button,
.tracking-error-cell i {
    color: #dc2626 !important;
}

.tracking-error-cell .tracking-error-label {
    font-weight: 700;
}

.tracking-error-cell .tracking-error-link {
    font-size: 12px;
    text-decoration: none;
}

.tracking-error-cell .tracking-error-link:hover {
    text-decoration: underline;
}

.tracking-error-detail {
    width: 100%;
    max-width: 100%;
    margin-top: 6px;
}

.tracking-error-detail summary,
.tracking-warning-detail summary {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    width: max-content;
    max-width: 100%;
    min-height: 28px;
    padding: 4px 7px;
    border: 1px solid rgba(220, 38, 38, 0.35);
    border-radius: 8px;
    background: #fff5f5;
    color: #991b1b;
    font-size: 0.72rem;
    font-weight: 850;
    line-height: 1;
    cursor: pointer;
    list-style: none;
    white-space: nowrap;
}

.tracking-warning-detail {
    width: 100%;
    max-width: 100%;
    margin-top: 6px;
}

.tracking-warning-detail summary {
    border-color: rgba(245, 158, 11, 0.32);
    background: #fffbeb;
    color: #92400e;
}

.tracking-warning-detail summary i {
    color: #d97706;
}

.tracking-error-detail summary i {
    color: #dc2626;
}

.tracking-error-detail summary::-webkit-details-marker,
.tracking-warning-detail summary::-webkit-details-marker {
    display: none;
}

.tracking-error-detail summary:hover,
.tracking-error-detail summary:focus-visible {
    border-color: rgba(220, 38, 38, 0.55);
    background: #fee2e2;
    color: #7f1d1d;
    outline: 0;
}

.tracking-warning-detail summary:hover,
.tracking-warning-detail summary:focus-visible {
    border-color: rgba(245, 158, 11, 0.5);
    background: #fef3c7;
    color: #78350f;
    outline: 0;
}

.tracking-error-panel {
    position: relative;
    z-index: 4;
    display: grid;
    gap: 5px;
    width: min(420px, calc(100vw - 48px));
    max-width: 420px;
    margin-top: 7px;
    padding: 9px;
    border: 1px solid rgba(214, 69, 69, 0.22);
    border-radius: 8px;
    background: #fff8f8;
    color: #7f1d1d;
    overflow-wrap: anywhere;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
}

.tracking-error-panel p {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 750;
    line-height: 1.35;
}

.order-main-code {
    display: block;
    color: #0f172a;
    font-size: 0.88rem;
}

.order-date-cell {
    display: inline-block;
    max-width: 100%;
    color: var(--ink);
    font-size: 0.8rem;
    font-weight: 800;
    white-space: nowrap;
}

.date-stack {
    display: inline-grid;
    gap: 2px;
    color: var(--ink);
    font-weight: 850;
    line-height: 1.15;
    white-space: nowrap;
}

.date-stack small {
    color: var(--muted);
    font-size: 0.74rem;
    font-weight: 800;
    line-height: 1.15;
}

.order-code-stack,
.order-person-cell,
.product-cell {
    display: grid;
    gap: 4px;
}

.order-code-stack span,
.order-person-cell span,
.product-cell span {
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 750;
    line-height: 1.25;
}

.route-cell strong,
.order-person-cell strong,
.product-cell strong {
    color: var(--ink);
    font-size: 0.84rem;
    line-height: 1.25;
}

.order-product-cell {
    line-height: 1.35;
}

.order-product-cell + .order-product-cell {
    margin-top: 7px;
    padding-top: 7px;
    border-top: 1px solid #edf2f7;
}

.order-product-cell .product-name {
    color: #0f172a;
    font-weight: 800;
}

.order-product-cell .product-qty,
.order-product-cell .product-detail {
    margin-top: 2px;
    color: #64748b;
    font-size: 12px;
}

.delivery-mode-pill {
    display: inline-flex;
    width: max-content;
    max-width: 100%;
    padding: 4px 7px;
    border: 1px solid rgba(17, 168, 96, 0.22);
    border-radius: 999px;
    background: #eefbf4;
    color: var(--green-dark) !important;
    font-weight: 850 !important;
}

.orders-actions-cell,
.orders-table th:last-child {
    position: sticky;
    right: 0;
    z-index: 2;
    background: #ffffff;
    box-shadow: -8px 0 14px rgba(15, 23, 42, 0.05);
}

.orders-table th:last-child {
    z-index: 3;
    background: #f8fafc;
}

.orders-row-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-width: 120px;
}

.order-icon-action {
    display: inline-grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: #334155;
    font-size: 0.95rem;
    text-decoration: none;
    cursor: pointer;
    transition: background 160ms ease, border-color 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.order-icon-action:hover,
.order-icon-action:focus-visible {
    border-color: var(--green);
    color: var(--green-dark);
    background: #f3fbf7;
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
    outline: 0;
}

.order-icon-action.is-copied {
    border-color: rgba(17, 168, 96, 0.35);
    background: #e8f8ef;
    color: var(--green-dark);
}

.order-quick-row td {
    padding: 0;
    background: #fbfdff;
}

.order-quick-detail {
    padding: 10px 12px;
}

.order-quick-detail summary {
    cursor: pointer;
    color: var(--green-dark);
    font-size: 0.8rem;
    font-weight: 900;
}

.order-quick-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(150px, 1fr));
    gap: 8px;
    margin-top: 10px;
}

.order-quick-grid div {
    display: grid;
    gap: 4px;
    padding: 9px;
    border: 1px solid #edf2f7;
    border-radius: 8px;
    background: #ffffff;
}

.order-quick-grid span {
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 850;
    text-transform: uppercase;
}

.order-quick-grid strong {
    color: var(--ink);
    font-size: 0.82rem;
    line-height: 1.25;
}

.orders-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 14px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.orders-page-summary,
.orders-page-current {
    color: var(--muted);
    font-size: 0.84rem;
    font-weight: 800;
}

.orders-page-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 7px;
}

.orders-page-button {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 7px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: var(--ink);
    font-size: 0.8rem;
    font-weight: 850;
    text-decoration: none;
}

.orders-page-button.is-disabled {
    opacity: 0.48;
    pointer-events: none;
}

.order-json-card {
    margin-top: 14px;
}

.order-json {
    max-height: 620px;
    margin: 0;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #0f172a;
    color: #e5e7eb;
    padding: 14px;
    font-size: 0.78rem;
    line-height: 1.55;
    white-space: pre-wrap;
}

.order-json-small {
    max-height: 280px;
    font-size: 0.74rem;
}

.order-extra-grid {
    margin-top: 14px;
}

.order-detail-section + .order-detail-section {
    margin-top: 12px;
}

.order-detail-section summary {
    cursor: pointer;
    color: var(--ink);
    font-size: 0.9rem;
    font-weight: 900;
    margin-bottom: 10px;
}

.tracking-hero-card {
    display: grid;
    gap: 12px;
}

.tracking-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(150px, 1fr));
    gap: 10px;
}

.tracking-summary-inline {
    margin-bottom: 14px;
}

.tracking-summary-grid div {
    display: grid;
    gap: 5px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #f8fafc;
}

.tracking-summary-grid span,
.tracking-event-card span,
.tracking-carrier-card span,
.tracking-meta {
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 850;
}

.tracking-summary-grid strong {
    color: var(--ink);
    font-size: 0.98rem;
    line-height: 1.25;
}

.tracking-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tracking-meta span {
    padding: 6px 8px;
    border: 1px solid #edf2f7;
    border-radius: 999px;
    background: #ffffff;
}

.tracking-meta strong {
    color: var(--ink);
}

.tracking-event-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    gap: 10px;
}

.tracking-event-card {
    display: grid;
    gap: 6px;
    min-height: 108px;
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #ffffff;
}

.tracking-event-card.has-data {
    border-color: rgba(17, 168, 96, 0.22);
    background: #fbfffd;
}

.tracking-event-card.is-empty {
    background: #f8fafc;
}

.tracking-event-card strong {
    color: var(--ink);
    font-size: 0.94rem;
    line-height: 1.35;
}

.tracking-event-card small,
.tracking-carrier-card small {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 750;
}

.tracking-section-head,
.tracking-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}

.tracking-actions {
    justify-content: flex-start;
}

.tracking-section-head h2,
.tracking-section-head h3 {
    margin: 0;
    color: var(--ink);
    font-size: 1rem;
}

.tracking-section-head p {
    margin: 3px 0 0;
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 750;
}

.tracking-detail-head {
    margin-top: 16px;
}

.tracking-carrier-list {
    display: grid;
    gap: 10px;
}

.tracking-carrier-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #ffffff;
}

.tracking-carrier-card > div {
    display: grid;
    gap: 4px;
}

.tracking-carrier-card strong {
    color: var(--ink);
    font-size: 0.94rem;
}

.tracking-raw-json {
    margin-top: 16px;
}

.tracking-provider-card {
    display: grid;
    gap: 10px;
    margin-bottom: 14px;
    border-color: rgba(245, 158, 11, 0.34);
    background: #fffdf7;
}

.tracking-provider-card h2 {
    margin: 0;
    color: #92400e;
    font-size: 1rem;
}

.tracking-provider-card p {
    margin: 0;
    color: #334155;
    font-size: 0.88rem;
    font-weight: 750;
    line-height: 1.45;
}

.tracking-fallback-data {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tracking-fallback-data span {
    padding: 6px 9px;
    border: 1px solid rgba(245, 158, 11, 0.28);
    border-radius: 999px;
    background: #ffffff;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 850;
}

.tracking-fallback-data strong {
    color: var(--ink);
}

.dispatch-batch-card form {
    display: grid;
    gap: 10px;
}

.dispatch-batch-card label {
    font-size: 0.88rem;
    font-weight: 850;
}

.dispatch-batch-card {
    border-left: 4px solid var(--green);
}

.dispatch-batch-row input {
    flex: 1 1 230px;
    min-height: 42px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 9px 11px;
    outline: 0;
}

.dispatch-batch-row input:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.use-batch-button,
.batch-submit-button {
    width: auto;
    min-height: 42px;
    padding-right: 13px;
    padding-left: 13px;
}

.admin-alert {
    margin-bottom: 14px;
    padding: 11px 13px;
    border-radius: 8px;
    font-size: 0.88rem;
    font-weight: 750;
}

.admin-alert.success {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #eefbf4;
    color: var(--green-dark);
}

.admin-alert.error {
    border: 1px solid rgba(214, 69, 69, 0.28);
    background: #fff3f3;
    color: #9f1d1d;
}

.shalom-register-detail {
    display: block;
}

.shalom-register-detail summary {
    cursor: pointer;
    font-weight: 900;
}

.shalom-register-detail ul {
    display: grid;
    gap: 6px;
    margin: 10px 0 0;
    padding-left: 18px;
}

.admin-empty {
    padding: 22px;
    color: var(--muted);
    text-align: center;
}

.admin-toolbar {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    align-items: center;
    margin-bottom: 14px;
    padding: 14px;
}

.admin-filter-controls {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(210px, 260px);
    gap: 10px;
    align-items: center;
}

.admin-bulk-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    padding-top: 12px;
    border-top: 1px solid var(--line);
}

.admin-selection-tools {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    max-width: 100%;
}

.admin-select-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 34px;
    padding: 7px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: var(--ink);
    font-size: 0.78rem;
    font-weight: 850;
    cursor: pointer;
}

.admin-select-button:hover,
.admin-select-button:focus-visible {
    border-color: var(--green);
    outline: 0;
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.admin-select-button:disabled {
    background: #f3f4f6;
    color: #94a3b8;
    cursor: not-allowed;
    box-shadow: none;
}

.admin-selected-count {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 8px;
    border-radius: 999px;
    background: #f8fafc;
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 900;
}

.admin-search {
    display: grid;
    grid-template-columns: 22px 1fr;
    align-items: center;
    min-height: 42px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: var(--muted);
}

.admin-search:focus-within {
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.admin-search i {
    padding-left: 11px;
}

.admin-search input {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    padding: 10px 12px 10px 8px;
    background: transparent;
    color: var(--ink);
}

.admin-filter-group {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    justify-content: flex-end;
}

.admin-view-tabs {
    display: grid;
    grid-template-columns: minmax(320px, 1.4fr) minmax(260px, 1fr) minmax(170px, 0.6fr);
    gap: 10px;
    margin-bottom: 14px;
}

.admin-tab-group {
    display: grid;
    gap: 8px;
    align-content: start;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.admin-tab-group h2 {
    margin: 0;
    color: var(--muted);
    font-size: 0.74rem;
    font-weight: 900;
    text-transform: uppercase;
}

.admin-tab-group > div {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.admin-filter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 7px 11px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: var(--ink);
    font-size: 0.8rem;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
}

.admin-print-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 8px 13px;
    border: 0;
    border-radius: 8px;
    background: var(--ink);
    color: #ffffff;
    font-size: 0.84rem;
    font-weight: 850;
    cursor: pointer;
}

.admin-print-button:hover,
.admin-print-button:focus-visible {
    background: #0f1720;
    outline: 0;
}

.admin-print-button:disabled {
    background: #e5e7eb;
    color: #6b7280;
    cursor: not-allowed;
}

.bulk-action-button.is-disabled,
.bulk-action-button:disabled {
    border-color: #e5e7eb !important;
    background: #e5e7eb !important;
    color: #6b7280 !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
    opacity: 1;
}

.admin-filter.is-active {
    border-color: var(--green);
    background: #eefbf4;
    color: var(--green-dark);
}

.admin-counts {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    grid-column: 1 / -1;
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 750;
}

.admin-counts span {
    padding: 5px 8px;
    border-radius: 8px;
    background: #f8fafb;
}

.admin-table-wrap {
    overflow: auto;
    background: #ffffff;
}

.admin-table {
    width: 100%;
    min-width: 1220px;
    border-collapse: collapse;
}

.delivery-admin-table {
    min-width: 1080px;
}

.shalom-admin-table {
    min-width: 1080px;
}

.admin-table th,
.admin-table td {
    padding: 13px 12px;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

.select-column {
    width: 42px;
    min-width: 42px;
    max-width: 42px;
    text-align: center !important;
    padding-left: 8px !important;
    padding-right: 8px !important;
    white-space: nowrap;
    position: sticky;
    left: 0;
    z-index: 2;
    background: #ffffff;
}

.select-column input {
    width: 16px;
    height: 16px;
    accent-color: var(--green);
}

.admin-table th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f8fafc;
    color: #4b5563;
    font-size: 0.72rem;
    font-weight: 850;
    letter-spacing: 0;
    text-transform: uppercase;
}

.admin-table th.select-column {
    z-index: 3;
    background: #f8fafc;
}

.admin-table td {
    color: var(--ink);
    font-size: 0.84rem;
    line-height: 1.42;
}

.admin-table tbody tr:hover {
    background: #fbfcfd;
}

.admin-table tr:last-child td {
    border-bottom: 0;
}

.admin-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, max-content));
    gap: 6px;
    align-items: start;
}

.admin-actions .admin-action {
    min-height: 30px;
    padding: 6px 8px;
    border-radius: 7px;
    font-size: 0.76rem;
}

.shalom-admin-table th,
.shalom-admin-table td {
    padding: 10px 10px;
}

.shalom-admin-table th:nth-child(2),
.shalom-admin-table td:nth-child(2) {
    width: 120px;
}

.shalom-admin-table th:nth-child(3),
.shalom-admin-table td:nth-child(3) {
    min-width: 170px;
}

.shalom-admin-table th:nth-child(6),
.shalom-admin-table td:nth-child(6) {
    min-width: 190px;
}

.shalom-admin-table th:nth-child(7),
.shalom-admin-table td:nth-child(7) {
    min-width: 180px;
}

.table-stack {
    display: grid;
    gap: 3px;
    align-content: start;
}

.table-stack strong {
    font-size: 0.84rem;
    line-height: 1.22;
}

.table-stack small,
.tracking-cell span {
    color: var(--muted);
    font-size: 0.74rem;
    line-height: 1.22;
}

.agency-cell span {
    font-weight: 800;
}

.method-badge,
.quote-badge {
    border-radius: 6px;
    white-space: nowrap;
}

.quote-badge {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 4px 8px;
    border: 1px solid rgba(17, 168, 96, 0.24);
    background: #eefbf4;
    color: var(--green-dark);
    font-size: 0.76rem;
    font-weight: 900;
}

.compact-actions {
    grid-template-columns: repeat(2, minmax(0, max-content));
    gap: 5px;
}

.compact-actions .admin-action {
    min-height: 28px;
    padding: 5px 7px;
    white-space: nowrap;
}

.compact-actions .action-primary {
    font-weight: 900;
}

.inline-status-form,
.detail-status-form,
.package-form {
    margin: 0;
}

.package-form {
    display: grid;
    gap: 6px;
    min-width: 170px;
}

.package-size-select {
    width: 100%;
    min-width: 140px;
    min-height: 34px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    color: var(--ink);
    font-size: 0.8rem;
    outline: 0;
}

.package-form small {
    color: var(--muted);
    font-size: 0.7rem;
    line-height: 1.15;
    white-space: nowrap;
}

.package-product-empty {
    display: grid;
    gap: 6px;
    min-width: 190px;
    color: var(--muted);
    font-size: 0.73rem;
    line-height: 1.25;
}

.package-product-empty .admin-action {
    width: max-content;
    max-width: 100%;
}

.shalom-dimensions-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
}

.shalom-dimensions-fields.is-hidden {
    display: none;
}

.shalom-dimensions-fields input {
    min-width: 0;
    min-height: 30px;
    padding: 5px 6px;
    border: 1px solid var(--line);
    border-radius: 7px;
    font-size: 0.74rem;
}

.status-submit {
    cursor: pointer;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 9px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 850;
}

.status-pendiente {
    border: 1px solid rgba(245, 158, 11, 0.32);
    background: #fff7e6;
    color: #9a5b00;
}

.status-enviado {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #e8f8ef;
    color: var(--green-dark);
}

.status-registrado_shalom {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #e8f8ef;
    color: var(--green-dark);
}

.status-cancelado {
    border: 1px solid rgba(107, 114, 128, 0.28);
    background: #f3f4f6;
    color: #4b5563;
}

.channel-badge {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 9px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #f8fafc;
    color: #475569;
    font-size: 0.75rem;
    font-weight: 850;
}

.source-badge {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 22px;
    margin-top: 5px;
    padding: 3px 7px;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 850;
}

.source-manual {
    border: 1px solid rgba(59, 130, 246, 0.28);
    background: #eff6ff;
    color: #1d4ed8;
}

.source-public {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #e8f8ef;
    color: var(--green-dark);
}

.dispatch-badge {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 9px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 850;
}

.dispatch-pendiente {
    border: 1px solid rgba(245, 158, 11, 0.32);
    background: #fff7e6;
    color: #9a5b00;
}

.dispatch-preparado {
    border: 1px solid rgba(59, 130, 246, 0.28);
    background: #eff6ff;
    color: #1d4ed8;
}

.dispatch-registrado_shalom,
.dispatch-enviado {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #e8f8ef;
    color: var(--green-dark);
}

.dispatch-cancelado {
    border: 1px solid rgba(214, 69, 69, 0.28);
    background: #fff3f3;
    color: #9f1d1d;
}

.delivery-pendiente {
    border: 1px solid rgba(245, 158, 11, 0.32);
    background: #fff7e6;
    color: #9a5b00;
}

.delivery-en_ruta {
    border: 1px solid rgba(59, 130, 246, 0.28);
    background: #eff6ff;
    color: #1d4ed8;
}

.delivery-entregado {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #e8f8ef;
    color: var(--green-dark);
}

.delivery-cancelado {
    border: 1px solid rgba(214, 69, 69, 0.28);
    background: #fff3f3;
    color: #9f1d1d;
}

.map-cell {
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: flex-start;
}

.money-stack {
    display: grid;
    gap: 4px;
    color: #475569;
    font-size: 0.78rem;
    font-weight: 800;
    white-space: nowrap;
}

.location-badge {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    padding: 3px 7px;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 850;
    white-space: nowrap;
}

.location-exact {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #e8f8ef;
    color: var(--green-dark);
}

.location-missing {
    border: 1px solid rgba(100, 116, 139, 0.24);
    background: #f8fafc;
    color: #64748b;
}

.mc-sync-no_aplica {
    border: 1px solid rgba(100, 116, 139, 0.26);
    background: #f8fafc;
    color: #475569;
}

.mc-sync-pendiente {
    border: 1px solid rgba(245, 158, 11, 0.32);
    background: #fff7e6;
    color: #9a5b00;
}

.mc-sync-sincronizado {
    border: 1px solid rgba(17, 168, 96, 0.28);
    background: #e8f8ef;
    color: var(--green-dark);
}

.mc-sync-error {
    border: 1px solid rgba(214, 69, 69, 0.28);
    background: #fff3f3;
    color: #9f1d1d;
}

.table-empty {
    margin: 0;
    border-top: 1px solid var(--line);
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 0;
    box-shadow: none;
}

.admin-detail-grid {
    display: grid;
    grid-template-columns: minmax(320px, 460px) minmax(360px, 1fr);
    gap: 20px;
    align-items: start;
}

.admin-summary-panel {
    margin-top: 0;
}

.admin-detail-card {
    padding: 18px;
}

.admin-detail-card h2 {
    margin: 0 0 14px;
    font-size: 1.05rem;
}

.shalom-pro-card {
    margin-bottom: 16px;
}

.shalom-pro-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(180px, 1fr));
    gap: 10px;
    margin-top: 16px;
}

.shalom-pro-session-actions {
    grid-template-columns: minmax(180px, 240px);
}

.shalom-products-wrap {
    margin-top: 16px;
}

.shalom-products-table {
    min-width: 760px;
}

.admin-detail-list {
    display: grid;
    gap: 0;
    margin: 0;
}

.admin-detail-list div {
    display: grid;
    grid-template-columns: minmax(150px, 220px) 1fr;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--line);
}

.admin-detail-list div:last-child {
    border-bottom: 0;
}

.admin-detail-list dt {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 800;
}

.admin-detail-list dd {
    min-width: 0;
    margin: 0;
    color: var(--ink);
    font-size: 0.88rem;
    overflow-wrap: anywhere;
}

.detail-actions {
    display: grid;
    gap: 9px;
    width: 100%;
}

.dispatch-detail-list {
    margin-bottom: 16px;
}

.dispatch-edit-form {
    display: grid;
    gap: 13px;
    margin-bottom: 22px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--line);
}

.field-optional {
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

.admin-textarea {
    width: 100%;
    resize: vertical;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 10px 12px;
    color: var(--ink);
    font: inherit;
    outline: 0;
}

.admin-textarea:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.shalom-json-card {
    border-left: 4px solid #2563eb;
}

.json-card-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.json-card-heading h2 {
    margin: 0;
}

.json-header-line {
    display: block;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.82rem;
    line-height: 1.45;
}

.copy-json-button.is-copied {
    border-color: rgba(17, 168, 96, 0.28);
    background: #eefbf4;
    color: var(--green-dark);
}

.admin-map-button {
    width: 100%;
}

.labels-page {
    width: 100%;
    max-width: none;
    min-height: 100vh;
    margin: 0 auto;
    padding: 20px;
    background: #f8fafc;
}

.labels-toolbar {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.labels-button {
    width: auto;
    min-width: 120px;
}

.labels-pdf-form {
    margin: 0;
}

.labels-grid,
.labels-list {
    display: flex;
    flex-direction: column;
    gap: 6mm;
}

.shipping-label {
    display: flex;
    flex-direction: column;
    width: 100%;
    min-height: 93mm;
    max-height: 93mm;
    box-sizing: border-box;
    padding: 7mm 9mm;
    border: 2px solid #111827;
    border-radius: 8px;
    background: #ffffff;
    overflow: hidden;
    page-break-inside: avoid;
    break-inside: avoid;
}

.shipping-label-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}

.shipping-label-type,
.shipping-label-badge {
    display: inline-block;
    width: max-content;
    max-width: 100%;
    margin-bottom: 2.4mm;
    padding: 0;
    border: 0;
    border-radius: 0;
    color: #111827;
    background: transparent;
    font-size: 11px;
    font-weight: 950;
    letter-spacing: 0;
    line-height: 1.15;
    text-transform: uppercase;
}

.shipping-label-section {
    margin-top: 2.5mm;
    padding-top: 2.5mm;
    border-top: 1px solid #111827;
}

.shipping-label-section-with-qr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 28mm;
    gap: 6mm;
    align-items: start;
}

.shipping-label-section-content {
    min-width: 0;
}

.shipping-label-section h2,
.shipping-label-section-title {
    margin: 0 0 1.5mm;
    color: #111827;
    font-size: 10.5px;
    font-weight: 950;
    letter-spacing: 0;
    text-transform: uppercase;
}

.shipping-label-main {
    margin-bottom: 1.2mm;
    color: #111827;
    font-size: 15px;
    font-weight: 950;
    line-height: 1.18;
}

.shipping-label-line {
    margin-bottom: 1mm;
    color: #111827;
    font-size: 13px;
    font-weight: 800;
    line-height: 1.18;
}

.shipping-label-line strong {
    font-weight: 900;
}

.shipping-label-agency {
    color: #111827;
    font-size: 1.22rem;
    font-weight: 900;
    line-height: 1.2;
}

.shipping-label-address {
    display: -webkit-box;
    margin-bottom: 1mm;
    color: #111827;
    overflow: hidden;
    font-size: 13px;
    font-weight: 800;
    line-height: 1.18;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.shipping-label-charge {
    margin-top: 1.2mm;
    margin-bottom: 1mm;
    color: #dc2626;
    font-size: 14px;
    font-weight: 950;
    line-height: 1.18;
}

.delivery-label-layout,
.delivery-address-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 28mm;
    gap: 6mm;
    align-items: start;
}

.delivery-label-info,
.delivery-address-info {
    min-width: 0;
}

.delivery-label-qr {
    text-align: center;
}

.delivery-label-qr img {
    display: block;
    width: 25mm;
    height: 25mm;
    margin: 0 auto;
    object-fit: contain;
}

.delivery-label-qr-caption,
.delivery-label-no-gps {
    margin-top: 1mm;
    color: #111827;
    font-size: 8px;
    font-weight: 900;
    line-height: 1.1;
}

@media screen {
    .delivery-label-qr img {
        width: 96px;
        height: 96px;
    }
}

.shipping-label-batch {
    color: #111827;
    font-size: 0.95rem;
    font-weight: 800;
}

.shipping-label-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    flex: 0 0 auto;
    margin-top: 3mm;
    padding-top: 2mm;
    border-top: 1px solid #111827;
    color: #111827;
    font-size: 11px;
    font-weight: 900;
    line-height: 1.2;
}

.shipping-label-channel {
    color: #111827;
    font-size: 11px;
    font-weight: 900;
}

.labels-page {
    max-width: none;
}

.labels-grid {
    display: grid;
    gap: 16px;
    justify-items: center;
}

.print-sheet {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(3, minmax(0, 1fr));
    gap: 5mm;
    width: 210mm;
    min-height: 297mm;
    max-width: 100%;
    aspect-ratio: 210 / 297;
    box-sizing: border-box;
    padding: 8mm;
    border: 1px solid #d1d5db;
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.1);
    page-break-after: always;
    break-after: page;
}

.print-sheet:last-child {
    page-break-after: auto;
    break-after: auto;
}

.print-sheet .shipping-label {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 0;
    max-height: none;
    box-sizing: border-box;
    padding: 5mm;
    border: 1.25px solid #111827;
    border-radius: 5px;
    box-shadow: none;
    page-break-inside: avoid;
    break-inside: avoid;
}

.print-sheet .shipping-label-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-height: 0;
    padding-bottom: 7mm;
}

.print-sheet .shipping-label-badge {
    margin-bottom: 2mm;
    padding: 0;
    border: 0;
    font-size: 14px;
    font-weight: 900;
    line-height: 1.12;
}

.print-sheet .shipping-label-section {
    margin-top: 2.1mm;
    padding-top: 2mm;
    border-top-color: rgba(17, 24, 39, 0.62);
}

.print-sheet .shipping-label-section-title {
    margin-bottom: 1mm;
    color: #4b5563;
    font-size: 9px;
    font-weight: 900;
    line-height: 1.12;
}

.print-sheet .shipping-label-main,
.print-sheet .shipping-label-agency {
    display: -webkit-box;
    margin-bottom: 0.8mm;
    overflow: hidden;
    font-size: 16px;
    font-weight: 900;
    line-height: 1.13;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.print-sheet .shipping-label-agency {
    font-size: 16px;
    font-weight: 950;
}

.print-sheet .shipping-label-line,
.print-sheet .shipping-label-address {
    display: -webkit-box;
    margin-bottom: 0.7mm;
    overflow: hidden;
    font-size: 11px;
    font-weight: 750;
    line-height: 1.18;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.print-sheet .shipping-label-address {
    font-size: 10.5px;
    line-height: 1.18;
    -webkit-line-clamp: 3;
}

.print-sheet .shipping-label-charge {
    margin-top: 0.6mm;
    margin-bottom: 0.4mm;
    font-size: 11px;
    font-weight: 950;
    line-height: 1.12;
}

.print-sheet .shipping-label-section:last-of-type .shipping-label-line {
    font-size: 11px;
    font-weight: 800;
}

.print-sheet .shipping-label-section-with-qr,
.print-sheet .delivery-address-layout {
    grid-template-columns: minmax(0, 1fr) 18mm;
    gap: 3mm;
}

.print-sheet .delivery-label-qr img {
    width: 17mm;
    height: 17mm;
}

.print-sheet .delivery-label-qr-caption,
.print-sheet .delivery-label-no-gps {
    font-size: 7px;
}

.print-sheet .shipping-label-footer {
    position: absolute;
    right: 5mm;
    bottom: 3.8mm;
    left: 5mm;
    display: flex;
    justify-content: flex-end;
    align-items: flex-end;
    margin: 0;
    margin-top: auto;
    padding-top: 1.2mm;
    border-top: 1px solid rgba(17, 24, 39, 0.58);
    font-size: 9px;
    font-weight: 800;
    line-height: 1.15;
    text-align: right;
}

.print-sheet .shipping-label-channel {
    max-width: 100%;
    overflow: hidden;
    font-size: 9px;
    font-weight: 750;
    line-height: 1.15;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.admin-shell {
    padding-top: 18px;
}

.admin-header {
    position: relative;
    z-index: 20;
    margin-bottom: 10px;
}

.admin-header h1 {
    font-size: 1.25rem;
}

.admin-title-block {
    gap: 5px;
}

.admin-module-nav a {
    min-height: 28px;
    padding: 4px 8px;
    font-size: 0.74rem;
}

.admin-header-actions {
    flex-wrap: wrap;
    gap: 6px;
}

.admin-logout,
.admin-action {
    min-height: 32px;
    padding: 6px 9px;
}

.admin-config-toggle {
    cursor: pointer;
}

.admin-config-toggle[aria-expanded="true"] {
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(17, 168, 96, 0.1);
}

.admin-config-menu-list[hidden] {
    display: none;
}

.dispatch-summary-compact {
    display: block;
    margin-bottom: 8px;
    padding: 8px 10px;
    box-shadow: 0 10px 24px rgba(31, 41, 55, 0.07);
}

.dispatch-summary-compact > div:first-child:not(.dispatch-summary-metrics) {
    display: none;
}

.dispatch-summary-compact .dispatch-summary-metrics {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
}

.dispatch-summary-compact .dispatch-summary-metrics span {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-width: 0;
    gap: 8px;
    padding: 6px 8px;
}

.dispatch-summary-compact .dispatch-summary-metrics small {
    font-size: 0.7rem;
}

.dispatch-summary-compact .dispatch-summary-metrics strong {
    font-size: 1rem;
}

.admin-view-tabs {
    gap: 8px;
    margin-bottom: 8px;
}

.admin-tab-group {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    box-shadow: 0 10px 24px rgba(31, 41, 55, 0.07);
}

.admin-tab-group h2 {
    flex: 0 0 auto;
    min-width: 72px;
    font-size: 0.68rem;
}

.admin-tab-group > div {
    gap: 5px;
}

.admin-filter {
    min-height: 30px;
    padding: 5px 8px;
    font-size: 0.76rem;
}

.dispatch-batch-card {
    margin-bottom: 8px;
    padding: 8px 10px;
    border-left-width: 3px;
    box-shadow: 0 10px 24px rgba(31, 41, 55, 0.07);
}

.dispatch-batch-card form {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.dispatch-batch-card .section-heading {
    display: none;
}

.dispatch-batch-card label,
.dispatch-compact-label {
    flex: 0 0 auto;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 900;
    text-transform: uppercase;
}

.dispatch-batch-row {
    flex: 1 1 auto;
    gap: 6px;
}

.dispatch-batch-row input {
    flex: 0 0 96px;
    min-height: 34px;
    padding: 6px 9px;
}

.use-batch-button,
.batch-submit-button {
    min-height: 34px;
    padding: 6px 10px;
}

.admin-toolbar {
    grid-template-columns: minmax(360px, 1fr) auto;
    gap: 8px;
    margin-bottom: 8px;
    padding: 8px 10px;
    box-shadow: 0 10px 24px rgba(31, 41, 55, 0.07);
}

.admin-toolbar .section-heading {
    display: none;
}

.admin-filter-controls {
    grid-template-columns: minmax(260px, 1fr) minmax(170px, 210px);
    gap: 8px;
}

.admin-search {
    min-height: 34px;
}

.admin-search input {
    padding-top: 7px;
    padding-bottom: 7px;
}

.admin-bulk-actions {
    flex-wrap: nowrap;
    gap: 6px;
    padding-top: 0;
    border-top: 0;
}

.admin-print-button {
    min-height: 34px;
    padding: 6px 10px;
    font-size: 0.78rem;
    white-space: nowrap;
}

.admin-counts {
    grid-column: 1 / -1;
    gap: 6px;
    font-size: 0.76rem;
}

.admin-counts span {
    padding: 3px 7px;
}

.admin-toolbar.admin-filter-card {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
}

.admin-filter-card .admin-filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.admin-filter-card .filter-search {
    flex: 1 1 280px;
    min-width: 260px;
}

.admin-filter-card .filter-channel,
.admin-filter-card .filter-select {
    flex: 0 1 220px;
    min-width: 180px;
}

.admin-filter-card .admin-actions-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    justify-content: flex-start;
    padding-top: 10px;
    border-top: 1px solid var(--line);
}

.admin-filter-card .admin-actions-row .btn,
.admin-filter-card .admin-actions-row button,
.admin-filter-card .admin-actions-row a {
    flex: 0 0 auto;
    max-width: 100%;
    white-space: nowrap;
}

.admin-filter-card .admin-filter-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.admin-table th,
.admin-table td {
    padding: 8px 9px;
}

.admin-table th {
    font-size: 0.68rem;
}

.admin-table td {
    font-size: 0.8rem;
    line-height: 1.32;
}

.admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    min-width: 150px;
    max-width: 220px;
}

.admin-actions .admin-action {
    min-height: 26px;
    padding: 4px 7px;
    font-size: 0.71rem;
}

.package-form {
    gap: 4px;
    min-width: 132px;
}

.package-size-select {
    min-height: 30px;
    font-size: 0.76rem;
}

.shalom-admin-table .package-form {
    min-width: 170px;
}

.shalom-admin-table .package-size-select {
    min-width: 140px;
}

.admin-actions.compact-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, max-content));
    gap: 5px;
    min-width: 0;
    max-width: none;
}

.admin-actions.compact-actions .admin-action {
    min-height: 28px;
    padding: 5px 7px;
    white-space: nowrap;
}

/* Wide admin layout refresh */
.admin-shell {
    width: min(1600px, calc(100% - 32px));
    padding: 24px 0 42px;
}

.admin-header {
    align-items: stretch;
    gap: 20px;
    margin-bottom: 16px;
    padding: 16px 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 14px 34px rgba(31, 41, 55, 0.08);
}

.admin-title-block {
    min-width: 280px;
}

.admin-header h1 {
    font-size: 1.45rem;
    line-height: 1.15;
}

.admin-header-actions {
    align-content: center;
}

.admin-header-actions .admin-logout,
.admin-config-toggle {
    min-height: 38px;
    padding: 8px 12px;
}

.dispatch-summary-compact {
    margin-bottom: 12px;
    padding: 12px;
}

.dispatch-summary-compact .dispatch-summary-metrics {
    grid-template-columns: repeat(6, minmax(120px, 1fr));
    gap: 8px;
}

.dispatch-summary-compact .dispatch-summary-metrics span {
    min-height: 54px;
    padding: 8px 10px;
}

.admin-view-tabs {
    grid-template-columns: minmax(420px, 1.15fr) minmax(520px, 1.35fr) minmax(210px, 0.5fr);
    gap: 12px;
    margin-bottom: 12px;
}

.admin-tab-group {
    min-width: 0;
    padding: 10px;
}

.admin-filter {
    min-height: 34px;
    padding: 6px 10px;
    font-size: 0.8rem;
}

.admin-operation-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: stretch;
    margin-bottom: 12px;
}

.admin-operation-strip .dispatch-batch-card {
    flex: 1 1 300px;
    min-width: 280px;
    margin-bottom: 0;
}

.admin-operation-strip .dispatch-batch-card:first-child {
    flex-basis: 520px;
}

.admin-toolbar.admin-filter-card {
    gap: 10px;
    margin-bottom: 12px;
    padding: 12px;
}

.admin-filter-card .admin-filter-row {
    gap: 12px;
}

.admin-filter-card .filter-search {
    flex-basis: 520px;
}

.admin-filter-card .admin-actions-row {
    gap: 8px;
    padding-top: 8px;
}

.admin-print-button {
    min-height: 36px;
    padding: 7px 11px;
    font-size: 0.8rem;
}

.admin-table-wrap {
    width: 100%;
    overflow-x: auto;
    overflow-y: visible;
    border-radius: 8px;
}

.admin-table {
    min-width: 1380px;
}

.delivery-admin-table {
    min-width: 1180px;
}

.shalom-admin-table {
    min-width: 1720px;
}

.admin-table th,
.admin-table td,
.shalom-admin-table th,
.shalom-admin-table td {
    padding: 12px 12px;
}

.admin-table th {
    font-size: 0.74rem;
}

.admin-table td {
    font-size: 0.875rem;
    line-height: 1.38;
}

.table-stack {
    gap: 4px;
}

.table-stack strong {
    font-size: 0.9rem;
}

.table-stack small,
.tracking-cell span {
    font-size: 0.78rem;
}

.shalom-admin-table th:nth-child(2),
.shalom-admin-table td:nth-child(2) {
    width: 145px;
    min-width: 145px;
}

.shalom-admin-table th:nth-child(3),
.shalom-admin-table td:nth-child(3) {
    min-width: 210px;
}

.shalom-admin-table th:nth-child(4),
.shalom-admin-table td:nth-child(4) {
    min-width: 120px;
}

.shalom-admin-table th:nth-child(5),
.shalom-admin-table td:nth-child(5) {
    min-width: 96px;
}

.shalom-admin-table th:nth-child(6),
.shalom-admin-table td:nth-child(6) {
    min-width: 230px;
}

.shalom-admin-table th:nth-child(7),
.shalom-admin-table td:nth-child(7) {
    min-width: 170px;
    width: 180px;
    max-width: 190px;
}

.shalom-admin-table th:nth-child(8),
.shalom-admin-table td:nth-child(8) {
    min-width: 92px;
}

.shalom-admin-table th:nth-child(9),
.shalom-admin-table td:nth-child(9) {
    min-width: 140px;
}

.shalom-admin-table th:nth-child(10),
.shalom-admin-table td:nth-child(10) {
    min-width: 155px;
}

.shalom-admin-table th:last-child,
.shalom-admin-table td:last-child,
.delivery-admin-table th:last-child,
.delivery-admin-table td:last-child {
    min-width: 220px;
    width: 220px;
}

.actions-cell {
    min-width: 220px;
    width: 220px;
    overflow: visible;
}

.table-actions-sticky {
    position: sticky;
    right: 0;
    z-index: 5;
    background: #ffffff;
    box-shadow: -1px 0 0 var(--line), -8px 0 16px rgba(15, 23, 42, 0.06);
}

.admin-table th:last-child,
.admin-table td:last-child {
    position: sticky;
    right: 0;
    z-index: 2;
    background: #ffffff;
    box-shadow: -1px 0 0 var(--line), -8px 0 16px rgba(15, 23, 42, 0.06);
}

.admin-table th:last-child {
    z-index: 4;
    background: #f8fafc;
}

.admin-table tbody tr:hover td:last-child {
    background: #fbfcfd;
}

.paquete-cell {
    min-width: 150px;
    width: 180px;
    max-width: 190px;
}

.shalom-admin-table .package-form,
.package-form-compact {
    min-width: 0;
    width: 100%;
}

.package-form-compact {
    display: grid;
    gap: 5px;
}

.package-quick-row {
    display: flex;
    gap: 5px;
    align-items: stretch;
}

.shalom-admin-table .package-size-select,
.package-select {
    width: 100%;
    min-width: 110px;
    max-width: 140px;
    min-height: 32px;
    font-size: 0.8rem;
}

.package-save-button {
    min-width: 0;
    padding-inline: 7px;
    font-size: 0.72rem;
}

.js-enabled .package-form-compact .package-save-button {
    display: none;
}

.package-autosave-status {
    display: block;
    min-height: 14px;
    color: var(--muted);
    font-size: 0.7rem;
    font-weight: 850;
    line-height: 1.15;
    white-space: normal;
}

.package-autosave-status[data-state="saving"] {
    color: #1d4ed8;
}

.package-autosave-status[data-state="success"] {
    color: var(--green-dark);
}

.package-autosave-status[data-state="warning"] {
    color: #9a5b00;
}

.package-autosave-status[data-state="error"] {
    color: #b91c1c;
}

.registration-warning-list {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 6px;
}

.registration-warning-list span {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    padding: 3px 7px;
    border: 1px solid #fde68a;
    border-radius: 999px;
    background: #fffbeb;
    color: #92400e;
    font-size: 0.68rem;
    font-weight: 850;
    line-height: 1.1;
}

.package-measures-toggle {
    width: max-content;
    min-height: 26px;
    padding: 4px 7px;
    font-size: 0.72rem;
}

.package-measures-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
    padding: 6px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #f8fafc;
}

.package-measures-panel small {
    grid-column: 1 / -1;
    white-space: normal;
}

.quote-badge {
    min-height: 26px;
    font-size: 0.82rem;
}

.method-badge,
.dispatch-badge,
.source-badge,
.channel-badge {
    border-radius: 6px;
}

.admin-actions.compact-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: stretch;
    min-width: 190px;
    max-width: 220px;
}

.actions-stack {
    flex-direction: row;
}

.actions-stack > .admin-action {
    flex: 1 1 calc(50% - 3px);
}

.actions-stack > .inline-status-form {
    flex: 1 0 100%;
    width: 100%;
}

.actions-stack > .inline-status-form .admin-action,
.actions-stack > .inline-status-form button.admin-action {
    width: 100%;
}

.admin-actions.compact-actions .admin-action {
    min-height: 30px;
    padding: 6px 8px;
    font-size: 0.74rem;
    line-height: 1.15;
    text-align: center;
    white-space: normal;
}

.admin-actions.compact-actions .action-primary {
    border-color: rgba(17, 168, 96, 0.24);
    background: #f3fbf7;
    color: var(--green-dark);
}

.admin-actions.compact-actions .status-submit:not(.danger-action) {
    border-color: rgba(37, 99, 235, 0.22);
    background: #eff6ff;
    color: #1d4ed8;
    font-weight: 850;
}

.admin-actions.compact-actions .danger-action {
    border-color: rgba(220, 38, 38, 0.35);
    background: #fff7f7;
    color: #b91c1c;
    font-weight: 900;
}

@media (max-width: 1200px) {
    .admin-shell {
        width: min(100% - 24px, 1600px);
    }

    .admin-header {
        flex-direction: column;
    }

    .admin-header-actions {
        justify-content: flex-start;
    }

    .dispatch-summary-compact .dispatch-summary-metrics {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .admin-view-tabs {
        grid-template-columns: 1fr;
    }

    .admin-operation-strip .dispatch-batch-card,
    .admin-operation-strip .dispatch-batch-card:first-child {
        flex-basis: 100%;
    }
}

@media (max-width: 780px) {
    .admin-shell {
        width: min(100% - 20px, 1600px);
        padding-top: 14px;
        padding-bottom: 28px;
    }

    .manual-document-search {
        grid-template-columns: 1fr;
    }

    .manual-search-button {
        width: 100%;
    }

    .shalom-person-row {
        grid-template-columns: 1fr;
        gap: 2px;
    }

    .admin-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .admin-title-block,
    .admin-module-nav {
        width: 100%;
    }

    .admin-module-nav a {
        flex: 1 1 150px;
    }

    .admin-header-actions,
    .shalom-pro-actions {
        width: 100%;
        grid-template-columns: 1fr;
    }

    .admin-header-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .admin-header-actions .admin-logout,
    .admin-config-menu,
    .admin-config-toggle {
        width: 100%;
    }

    .admin-config-menu-list {
        position: absolute;
        right: 0;
        left: 0;
        margin-top: 6px;
        box-shadow: 0 18px 40px rgba(15, 23, 42, 0.14);
    }

    .admin-action-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .admin-action-left,
    .admin-action-right,
    .admin-action-left .inline-form,
    .admin-action-left .btn,
    .admin-action-right .btn {
        width: 100%;
    }

    .admin-toolbar {
        grid-template-columns: 1fr;
    }

    .admin-filter-controls,
    .admin-view-tabs {
        grid-template-columns: 1fr;
    }

    .admin-filter-card .admin-filter-row,
    .admin-filter-card .admin-actions-row {
        flex-direction: column;
        align-items: stretch;
    }

    .admin-filter-card .filter-search,
    .admin-filter-card .filter-channel,
    .admin-filter-card .filter-select,
    .admin-filter-card .admin-actions-row .btn,
    .admin-filter-card .admin-actions-row button,
    .admin-filter-card .admin-actions-row a {
        width: 100%;
        min-width: 0;
    }

    .admin-bulk-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .orders-summary-grid,
    .orders-filter-grid,
    .orders-status-tabs,
    .tracking-summary-grid,
    .tracking-event-grid {
        grid-template-columns: 1fr;
    }

    .orders-tracking-head,
    .orders-action-card,
    .orders-inline-action-form,
    .orders-visible-action-form,
    .orders-filter-actions,
    .orders-pagination,
    .tracking-carrier-card {
        align-items: stretch;
        flex-direction: column;
    }

    .orders-inline-action-form,
    .orders-visible-action-form {
        width: 100%;
    }

    .orders-visible-action-form {
        padding-top: 8px;
        padding-left: 0;
        border-top: 1px solid var(--line);
        border-left: 0;
    }

    .orders-cache-meta {
        justify-content: flex-start;
    }

    .orders-action-card .btn,
    .orders-filter-actions .btn,
    .orders-page-button,
    .orders-page-controls {
        width: 100%;
    }

    .orders-page-controls {
        justify-content: stretch;
    }

    .dispatch-summary-card {
        grid-template-columns: 1fr;
    }

    .dispatch-summary-compact .dispatch-summary-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dispatch-summary-metrics span {
        min-width: 0;
        flex: 1 1 140px;
    }

    .dispatch-batch-row,
    .use-batch-button,
    .batch-submit-button {
        width: 100%;
    }

    .admin-filter-group {
        justify-content: flex-start;
    }

    .admin-print-button {
        width: 100%;
    }

    .admin-table {
        min-width: 0;
    }

    .admin-table thead {
        display: none;
    }

    .admin-table,
    .admin-table tbody,
    .admin-table tr,
    .admin-table td {
        display: block;
        width: 100%;
    }

    .admin-table tr {
        padding: 12px;
        border-bottom: 1px solid var(--line);
    }

    .admin-actions {
        grid-template-columns: 1fr;
    }

    .admin-table td {
        display: grid;
        grid-template-columns: 116px 1fr;
        gap: 10px;
        padding: 7px 0;
        border-bottom: 0;
    }

    .admin-table th:last-child,
    .admin-table td:last-child {
        position: static;
        min-width: 0;
        width: 100%;
        box-shadow: none;
    }

    .actions-cell {
        min-width: 0;
        width: 100%;
    }

    .admin-actions.compact-actions {
        max-width: none;
        width: 100%;
    }

    .admin-table td::before {
        content: attr(data-label);
        color: var(--muted);
        font-size: 0.72rem;
        font-weight: 850;
        text-transform: uppercase;
    }

    .orders-table {
        min-width: 0;
    }

    .orders-table thead {
        display: none;
    }

    .orders-table,
    .orders-table tbody,
    .orders-table tr,
    .orders-table td {
        display: block;
        width: 100%;
    }

    .orders-table tr {
        padding: 12px;
        border-bottom: 1px solid var(--line);
    }

    .orders-table td {
        display: grid;
        grid-template-columns: 118px 1fr;
        gap: 10px;
        padding: 7px 0;
        border-bottom: 0;
    }

    .orders-tracking-table th:first-child,
    .orders-tracking-table td:first-child {
        width: 100%;
        max-width: 100%;
    }

    .orders-select-column {
        width: 100%;
        max-width: 100%;
        text-align: left !important;
    }

    .orders-table td::before {
        content: attr(data-label);
        color: var(--muted);
        font-size: 0.72rem;
        font-weight: 850;
        text-transform: uppercase;
    }

    .orders-actions-cell,
    .orders-table th:last-child {
        position: static;
        box-shadow: none;
    }

    .order-quick-row {
        padding-top: 0 !important;
    }

    .order-quick-row td {
        display: block;
    }

    .order-quick-row td::before {
        content: none;
    }

    .order-quick-grid {
        grid-template-columns: 1fr;
    }

    .admin-detail-grid,
    .admin-detail-list div {
        grid-template-columns: 1fr;
    }

    .admin-detail-list div {
        gap: 4px;
    }

}

@media (max-width: 768px) {
    body {
        background: #f5f7f8;
    }

    .admin-index-shell {
        width: 100%;
        min-height: 0;
        padding: 12px 12px 90px;
    }

    .admin-index-shell .admin-header {
        gap: 10px;
        margin-bottom: 10px;
        padding: 12px;
        border-radius: 8px;
        box-shadow: 0 8px 22px rgba(31, 41, 55, 0.07);
    }

    .admin-index-shell .admin-kicker {
        margin-bottom: 2px;
        font-size: 0.72rem;
    }

    .admin-index-shell .admin-header h1 {
        font-size: 1.18rem;
    }

    .admin-index-shell .admin-title-block {
        gap: 5px;
        min-width: 0;
    }

    .admin-index-shell .admin-module-nav {
        gap: 6px;
    }

    .admin-index-shell .admin-module-nav a {
        flex: 1 1 calc(50% - 3px);
        min-height: 30px;
        padding: 5px 7px;
        font-size: 0.72rem;
    }

    .admin-index-shell .admin-header-actions {
        gap: 6px;
    }

    .admin-index-shell .admin-header-actions .admin-logout,
    .admin-index-shell .admin-config-toggle {
        min-height: 34px;
        padding: 7px 9px;
        font-size: 0.78rem;
    }

    .admin-index-shell .admin-config-menu-list {
        min-width: 0;
    }

    .admin-index-shell .admin-alert {
        margin-bottom: 8px;
        padding: 9px 10px;
        font-size: 0.8rem;
    }

    .admin-index-shell .dispatch-summary-compact {
        margin-bottom: 8px;
        padding: 9px;
        border-radius: 8px;
        box-shadow: 0 8px 22px rgba(31, 41, 55, 0.06);
    }

    .admin-index-shell .dispatch-summary-compact > div:first-child {
        display: none;
    }

    .admin-index-shell .dispatch-summary-compact .dispatch-summary-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
    }

    .admin-index-shell .dispatch-summary-compact .dispatch-summary-metrics span {
        min-height: 0;
        padding: 8px;
        border-radius: 8px;
    }

    .admin-index-shell .dispatch-summary-compact .dispatch-summary-metrics small {
        font-size: 0.68rem;
        line-height: 1.15;
    }

    .admin-index-shell .dispatch-summary-compact .dispatch-summary-metrics strong {
        font-size: 1rem;
        line-height: 1.1;
    }

    .admin-index-shell .admin-view-tabs {
        display: grid;
        gap: 7px;
        margin-bottom: 8px;
    }

    .admin-index-shell .admin-tab-group {
        gap: 6px;
        padding: 0;
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .admin-index-shell .admin-tab-group h2 {
        display: none;
    }

    .admin-index-shell .admin-tab-group > div {
        gap: 6px;
    }

    .admin-index-shell .admin-filter {
        min-height: 30px;
        padding: 6px 8px;
        border-radius: 999px;
        font-size: 0.72rem;
        line-height: 1.1;
    }

    .admin-index-shell .admin-operation-strip {
        gap: 8px;
        margin-bottom: 8px;
    }

    .admin-index-shell .dispatch-batch-card {
        padding: 9px;
        border-left-width: 3px;
        border-radius: 8px;
        box-shadow: 0 8px 22px rgba(31, 41, 55, 0.06);
    }

    .admin-index-shell .dispatch-batch-card form {
        gap: 7px;
    }

    .admin-index-shell .dispatch-batch-card label {
        font-size: 0.76rem;
    }

    .admin-index-shell .dispatch-batch-row {
        display: grid;
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .admin-index-shell .dispatch-batch-row input {
        flex: 0 0 auto;
        min-height: 36px;
        padding: 7px 9px;
    }

    .admin-index-shell .use-batch-button,
    .admin-index-shell .batch-submit-button,
    .admin-index-shell .primary-button,
    .admin-index-shell .secondary-button {
        min-height: 36px;
        padding: 7px 10px;
        font-size: 0.8rem;
    }

    .admin-index-shell .admin-toolbar.admin-filter-card {
        gap: 8px;
        margin-bottom: 10px;
        padding: 9px;
        border-radius: 8px;
        box-shadow: 0 8px 22px rgba(31, 41, 55, 0.06);
    }

    .admin-index-shell .admin-toolbar .section-heading {
        display: none;
    }

    .admin-index-shell .admin-filter-card .admin-filter-row {
        display: grid;
        grid-template-columns: 1fr;
        gap: 7px;
    }

    .admin-index-shell .admin-search,
    .admin-index-shell .filter-channel.control {
        min-height: 38px;
        border-radius: 8px;
    }

    .admin-index-shell .admin-search input,
    .admin-index-shell .filter-channel select {
        padding-top: 8px;
        padding-bottom: 8px;
        font-size: 0.86rem;
    }

    .admin-index-shell .admin-filter-card .admin-actions-row {
        display: grid;
        grid-template-columns: 1fr;
        gap: 6px;
        padding-top: 7px;
    }

    .admin-index-shell .admin-selection-tools {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px;
    }

    .admin-index-shell .admin-select-button {
        min-height: 34px;
        padding: 6px 8px;
        font-size: 0.74rem;
    }

    .admin-index-shell .admin-selected-count {
        grid-column: 1 / -1;
        justify-content: center;
        min-height: 26px;
        padding: 3px 8px;
        font-size: 0.72rem;
    }

    .admin-index-shell .admin-print-button {
        width: 100%;
        min-height: 36px;
        padding: 7px 9px;
        border-radius: 8px;
        font-size: 0.78rem;
    }

    .admin-index-shell .admin-counts {
        gap: 6px;
        font-size: 0.72rem;
    }

    .admin-index-shell .admin-counts span {
        padding: 4px 7px;
    }

    .admin-index-shell .admin-table-wrap {
        overflow: visible;
        background: transparent;
        border-radius: 0;
    }

    .admin-index-shell .admin-table {
        min-width: 0;
        border-collapse: separate;
        border-spacing: 0;
    }

    .admin-index-shell .admin-table thead {
        display: none;
    }

    .admin-index-shell .admin-table,
    .admin-index-shell .admin-table tbody {
        display: block;
        width: 100%;
    }

    .admin-index-shell .admin-table tbody {
        display: grid;
        gap: 10px;
    }

    .admin-index-shell .admin-table tr {
        display: grid;
        grid-template-columns: 24px minmax(0, 1fr);
        gap: 4px 9px;
        width: 100%;
        padding: 11px;
        border: 1px solid var(--line);
        border-radius: 8px;
        background: #ffffff;
        box-shadow: 0 8px 22px rgba(31, 41, 55, 0.06);
    }

    .admin-index-shell .admin-table tr.is-hidden {
        display: none !important;
    }

    .admin-index-shell .admin-table td,
    .admin-index-shell .shalom-admin-table td {
        display: block;
        min-width: 0;
        width: auto;
        max-width: none;
        padding: 0;
        border: 0;
        color: var(--ink);
        font-size: 0.82rem;
        line-height: 1.28;
    }

    .admin-index-shell .admin-table td::before {
        content: none;
    }

    .admin-index-shell .select-column,
    .admin-index-shell .admin-table th:last-child,
    .admin-index-shell .admin-table td:last-child,
    .admin-index-shell .table-actions-sticky {
        position: static;
        min-width: 0;
        width: auto;
        max-width: none;
        padding: 0 !important;
        background: transparent;
        box-shadow: none;
    }

    .admin-index-shell .select-cell {
        grid-column: 1;
        grid-row: 1 / span 2;
        padding-top: 2px !important;
        text-align: left !important;
    }

    .admin-index-shell .select-cell input {
        width: 18px;
        height: 18px;
    }

    .admin-index-shell .date-cell {
        display: none !important;
    }

    .admin-index-shell .client-info-cell {
        grid-column: 2;
        grid-row: 1;
    }

    .admin-index-shell .client-cell {
        gap: 2px;
    }

    .admin-index-shell .client-cell strong {
        font-size: 0.92rem;
        line-height: 1.2;
        overflow-wrap: anywhere;
    }

    .admin-index-shell .client-cell small,
    .admin-index-shell .tracking-cell span {
        font-size: 0.75rem;
    }

    .admin-index-shell .source-badge {
        min-height: 20px;
        margin-top: 3px;
        padding: 2px 6px;
        font-size: 0.66rem;
    }

    .admin-index-shell .whatsapp-cell,
    .admin-index-shell .method-cell {
        grid-column: 2;
        color: var(--muted);
        font-size: 0.78rem;
        font-weight: 800;
    }

    .admin-index-shell .whatsapp-cell::before {
        content: "WhatsApp: " !important;
        color: #334155;
    }

    .admin-index-shell .method-cell {
        padding-top: 1px;
    }

    .admin-index-shell .method-cell::before {
        content: "Metodo: " !important;
        color: #334155;
    }

    .admin-index-shell .method-cell .channel-badge {
        margin-left: 3px;
    }

    .admin-index-shell .agency-info-cell,
    .admin-index-shell .package-cell,
    .admin-index-shell .key-cell,
    .admin-index-shell .quote-cell,
    .admin-index-shell .tracking-info-cell,
    .admin-index-shell .status-cell,
    .admin-index-shell .sync-cell,
    .admin-index-shell .actions-cell {
        grid-column: 1 / -1;
    }

    .admin-index-shell .agency-info-cell {
        margin-top: 6px;
        padding-top: 8px;
        border-top: 1px solid #eef2f5;
    }

    .admin-index-shell .agency-info-cell::before,
    .admin-index-shell .package-cell::before {
        display: block;
        margin-bottom: 4px;
        color: var(--muted);
        font-size: 0.68rem;
        font-weight: 900;
        text-transform: uppercase;
    }

    .admin-index-shell .agency-info-cell::before {
        content: "Agencia / sede" !important;
    }

    .admin-index-shell .package-cell::before {
        content: "Paquete" !important;
    }

    .admin-index-shell .agency-cell {
        gap: 2px;
    }

    .admin-index-shell .agency-cell strong,
    .admin-index-shell .agency-cell span {
        font-size: 0.82rem;
        line-height: 1.22;
        overflow-wrap: anywhere;
    }

    .admin-index-shell .agency-cell small {
        font-size: 0.73rem;
        line-height: 1.22;
    }

    .admin-index-shell .package-cell {
        margin-top: 6px;
        padding-top: 8px;
        border-top: 1px solid #eef2f5;
    }

    .admin-index-shell .package-form,
    .admin-index-shell .package-form-compact {
        width: 100%;
        min-width: 0;
        gap: 5px;
    }

    .admin-index-shell .package-quick-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 6px;
    }

    .admin-index-shell .package-size-select,
    .admin-index-shell .package-select {
        width: 100%;
        min-width: 0;
        max-width: none;
        min-height: 34px;
        font-size: 0.78rem;
    }

    .admin-index-shell .package-save-button {
        min-height: 34px;
        padding: 6px 9px;
        font-size: 0.72rem;
    }

    .admin-index-shell .package-form small {
        font-size: 0.68rem;
        white-space: normal;
    }

    .admin-index-shell .package-measures-toggle {
        min-height: 30px;
        padding: 5px 8px;
    }

    .admin-index-shell .package-measures-panel {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-index-shell .money-stack {
        gap: 3px;
        font-size: 0.76rem;
        white-space: normal;
    }

    .admin-index-shell .key-cell,
    .admin-index-shell .quote-cell,
    .admin-index-shell .tracking-info-cell,
    .admin-index-shell .status-cell,
    .admin-index-shell .sync-cell {
        display: flex;
        flex-wrap: wrap;
        gap: 5px;
        align-items: center;
        color: #475569;
        font-size: 0.76rem;
        font-weight: 800;
    }

    .admin-index-shell .key-cell::before {
        content: "Clave:" !important;
    }

    .admin-index-shell .quote-cell::before {
        content: "Cotizacion:" !important;
    }

    .admin-index-shell .tracking-info-cell::before {
        content: "Guia/Codigo:" !important;
    }

    .admin-index-shell .status-cell::before {
        content: "Estado:" !important;
    }

    .admin-index-shell .sync-cell::before {
        content: "Sync MC:" !important;
    }

    .admin-index-shell .quote-cell .inline-status-form {
        margin-left: auto;
    }

    .admin-index-shell .quote-cell .admin-action {
        min-height: 28px;
        padding: 5px 8px;
        font-size: 0.72rem;
    }

    .admin-index-shell .channel-badge,
    .admin-index-shell .dispatch-badge,
    .admin-index-shell .quote-badge,
    .admin-index-shell .location-badge {
        min-height: 22px;
        padding: 3px 7px;
        border-radius: 999px;
        font-size: 0.7rem;
        white-space: normal;
    }

    .admin-index-shell .actions-cell {
        margin-top: 8px;
        padding-top: 8px !important;
        border-top: 1px solid #eef2f5;
    }

    .admin-index-shell .admin-actions.compact-actions,
    .admin-index-shell .actions-stack {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px;
        width: 100%;
        min-width: 0;
        max-width: none;
    }

    .admin-index-shell .actions-stack > .admin-action,
    .admin-index-shell .actions-stack > .inline-status-form,
    .admin-index-shell .actions-stack > .inline-status-form .admin-action,
    .admin-index-shell .actions-stack > .inline-status-form button.admin-action {
        width: 100%;
        min-width: 0;
    }

    .admin-index-shell .actions-stack > .admin-action:nth-child(n+3),
    .admin-index-shell .actions-stack > .inline-status-form {
        grid-column: 1 / -1;
    }

    .admin-index-shell .admin-actions.compact-actions .admin-action {
        min-height: 34px;
        padding: 7px 8px;
        border-radius: 8px;
        font-size: 0.76rem;
        line-height: 1.15;
    }

    .admin-index-shell .table-empty {
        margin-top: 10px;
        border: 1px solid var(--line);
        border-radius: 8px;
        background: #ffffff;
    }
}

@page {
    size: A4 portrait;
    margin: 8mm;
}

/* Integrated admin dashboard refresh */
.admin-index-shell .admin-header,
.admin-index-shell .dispatch-summary-compact,
.admin-index-shell .admin-tab-group,
.admin-index-shell .admin-toolbar.admin-filter-card,
.admin-index-shell .admin-table-wrap {
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.055);
}

.admin-index-shell .admin-header {
    margin-bottom: 12px;
    padding: 13px 16px;
}

.admin-index-shell .dispatch-summary-compact {
    margin-bottom: 10px;
    border-radius: 8px;
}

.admin-index-shell .admin-technical-diagnostics {
    opacity: 0.86;
}

.admin-index-shell .admin-view-tabs {
    margin-bottom: 0;
}

.admin-index-shell .admin-tab-group {
    padding: 9px;
    border-color: #e7edf2;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: none;
}

.admin-index-shell .admin-tab-group h2 {
    font-size: 0.68rem;
}

.admin-index-shell .admin-filter {
    min-height: 31px;
    padding: 6px 9px;
    border-color: #e3e9ee;
    border-radius: 999px;
    background: #ffffff;
    font-size: 0.76rem;
}

.admin-index-shell .admin-filter.is-active {
    border-color: rgba(17, 168, 96, 0.35);
    background: #eefbf4;
}

.admin-index-shell .admin-toolbar.admin-filter-card {
    margin-top: 10px;
    margin-bottom: 0;
    padding: 11px;
    border: 1px solid #e3e9ee;
    border-bottom: 0;
    border-radius: 8px 8px 0 0;
    background: #ffffff;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.045);
}

.admin-index-shell .admin-filter-card .admin-filter-row {
    gap: 8px;
}

.admin-index-shell .admin-search,
.admin-index-shell .admin-filter-card .filter-channel {
    min-height: 38px;
}

.admin-index-shell .admin-bulk-actions {
    flex-wrap: wrap;
    gap: 7px;
    padding-top: 9px;
    border-top: 1px solid #edf2f5;
}

.admin-index-shell .admin-selection-tools {
    flex: 0 1 auto;
}

.admin-index-shell .admin-operation-strip.is-inline-actions {
    display: contents;
}

.admin-index-shell .admin-bulk-actions .dispatch-batch-card {
    flex: 0 1 auto;
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}

.admin-index-shell .admin-bulk-actions .dispatch-batch-card form,
.admin-index-shell .admin-bulk-actions .dispatch-batch-row {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    margin: 0;
}

.admin-index-shell .admin-bulk-actions .dispatch-batch-card .section-heading {
    display: none;
}

.admin-index-shell .admin-bulk-actions .dispatch-batch-card label {
    color: var(--muted);
    font-size: 0.74rem;
    font-weight: 900;
    text-transform: uppercase;
}

.admin-index-shell .admin-bulk-actions .dispatch-batch-row input {
    flex: 0 0 78px;
    width: 78px;
    min-height: 34px;
    padding: 6px 8px;
    font-size: 0.82rem;
}

.admin-index-shell .admin-bulk-actions .admin-select-button,
.admin-index-shell .admin-bulk-actions .admin-print-button,
.admin-index-shell .admin-bulk-actions .use-batch-button,
.admin-index-shell .admin-bulk-actions .batch-submit-button {
    width: auto;
    min-height: 34px;
    padding: 7px 10px;
    border-radius: 8px;
    font-size: 0.76rem;
    line-height: 1.1;
}

.admin-index-shell .admin-selected-count {
    min-height: 26px;
    padding: 4px 8px;
    background: #f4f7f9;
}

.admin-index-shell .admin-table-wrap {
    border: 1px solid #e3e9ee;
    border-top: 0;
    border-radius: 0 0 8px 8px;
    background: #ffffff;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.055);
}

.admin-index-shell .admin-table th {
    background: #f8fafc;
    color: #64748b;
}

.admin-index-shell .admin-table td {
    border-bottom-color: #edf2f5;
}

.admin-index-shell .admin-table tbody tr:hover {
    background: #f9fbfb;
}

@media (max-width: 768px) {
    .admin-index-shell .admin-toolbar.admin-filter-card {
        margin-top: 8px;
        border: 1px solid #e3e9ee;
        border-radius: 8px;
    }

    .admin-index-shell .admin-bulk-actions .dispatch-batch-card,
    .admin-index-shell .admin-bulk-actions .dispatch-batch-card form,
    .admin-index-shell .admin-bulk-actions .dispatch-batch-row {
        width: 100%;
    }

    .admin-index-shell .admin-bulk-actions .dispatch-batch-card form,
    .admin-index-shell .admin-bulk-actions .dispatch-batch-row {
        display: grid;
        grid-template-columns: 1fr;
    }

    .admin-index-shell .admin-bulk-actions .dispatch-batch-row input,
    .admin-index-shell .admin-bulk-actions .admin-select-button,
    .admin-index-shell .admin-bulk-actions .admin-print-button,
    .admin-index-shell .admin-bulk-actions .use-batch-button,
    .admin-index-shell .admin-bulk-actions .batch-submit-button {
        width: 100%;
    }

    .admin-index-shell .admin-table-wrap {
        border: 0;
        background: transparent;
        box-shadow: none;
    }
}

@media (max-width: 768px) {
    .admin-index-shell {
        padding-bottom: 90px;
    }

    .admin-index-shell .admin-toolbar.admin-filter-card {
        gap: 8px;
        min-height: 0;
        height: auto;
        margin: 8px 0 10px;
        padding: 10px;
    }

    .admin-index-shell .admin-filter-card .admin-filter-row,
    .admin-index-shell .admin-filter-controls {
        display: grid;
        grid-template-columns: 1fr;
        gap: 9px;
        align-items: center;
        min-height: 0;
    }

    .admin-index-shell .admin-filter-card .filter-search,
    .admin-index-shell .admin-filter-card .filter-channel,
    .admin-index-shell .admin-filter-card .filter-select,
    .admin-index-shell .admin-search,
    .admin-index-shell .filter-channel.control {
        width: 100%;
        min-width: 0;
        max-width: none;
        min-height: 44px;
        height: 44px;
        flex: 0 0 auto;
        align-self: stretch;
        padding: 0;
    }

    .admin-index-shell .admin-search,
    .admin-index-shell .filter-channel.control {
        display: grid;
        grid-template-columns: 34px minmax(0, 1fr);
        align-items: center;
        overflow: hidden;
    }

    .admin-index-shell .admin-search i,
    .admin-index-shell .filter-channel.control i {
        padding-left: 11px;
        font-size: 0.95rem;
        line-height: 1;
    }

    .admin-index-shell .admin-search input,
    .admin-index-shell .filter-channel select {
        width: 100%;
        height: 100%;
        min-height: 0;
        margin: 0;
        padding: 0 12px 0 0;
        border: 0;
        font-size: 0.86rem;
        line-height: 1.2;
        -webkit-appearance: none;
        appearance: none;
    }

    .admin-index-shell .filter-channel select {
        padding-right: 34px;
    }

    .admin-index-shell .filter-channel.select-control::after {
        top: 50%;
        right: 12px;
        transform: translateY(-50%);
    }

    .admin-index-shell .admin-filter-card .admin-actions-row,
    .admin-index-shell .admin-bulk-actions {
        display: grid;
        grid-template-columns: 1fr;
        gap: 7px;
        min-height: 0;
        padding-top: 8px;
    }

    .admin-index-shell .admin-selection-tools {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
        width: 100%;
        min-height: 0;
    }

    .admin-index-shell .admin-bulk-actions .admin-select-button,
    .admin-index-shell .admin-bulk-actions .admin-print-button,
    .admin-index-shell .admin-bulk-actions .use-batch-button,
    .admin-index-shell .admin-bulk-actions .batch-submit-button,
    .admin-index-shell .admin-print-button,
    .admin-index-shell .admin-select-button {
        width: 100%;
        min-height: 44px;
        height: auto;
        padding: 8px 10px;
        border-radius: 8px;
        font-size: 0.78rem;
        line-height: 1.15;
    }

    .admin-index-shell .admin-selected-count {
        grid-column: 1 / -1;
        justify-content: center;
        min-height: 28px;
        padding: 4px 8px;
        font-size: 0.74rem;
    }
}

.api-logs-shell .api-log-table th:last-child,
.api-logs-shell .api-log-table td:last-child {
    position: static;
    min-width: 150px;
    width: 150px;
    background: inherit;
    box-shadow: none;
}

.api-logs-shell .api-log-table tbody tr:hover td:last-child {
    background: inherit;
}

.api-logs-shell .api-log-table {
    min-width: 1420px;
}

.api-logs-shell .api-log-table-wrap {
    overflow-x: auto;
    overflow-y: visible;
}

@media (max-width: 720px) {
    .api-logs-shell .api-log-table-wrap {
        overflow: visible;
    }

    .api-logs-shell .api-log-table {
        min-width: 0;
    }

    .api-logs-shell .api-log-table th:last-child,
    .api-logs-shell .api-log-table td:last-child {
        position: static;
        min-width: 0;
        width: auto;
        background: transparent;
        box-shadow: none;
    }
}

@media print {
    body {
        background: #ffffff;
    }

    .no-print,
    .labels-toolbar {
        display: none !important;
    }

    .labels-page {
        width: auto;
        max-width: none;
        min-height: 0;
        padding: 0;
        background: #ffffff;
    }

    .labels-grid {
        display: block;
        gap: 0;
    }

    .print-sheet {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-template-rows: repeat(3, minmax(0, 1fr));
        gap: 5mm;
        width: 194mm;
        height: 281mm;
        min-height: 281mm;
        max-width: none;
        aspect-ratio: auto;
        margin: 0;
        padding: 0;
        border: 0;
        background: #ffffff;
        box-shadow: none;
        page-break-after: always;
        break-after: page;
    }

    .print-sheet:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .shipping-label {
        height: 100%;
        min-height: 0;
        max-height: none;
        margin-bottom: 0;
        border-radius: 5px;
        box-shadow: none;
        page-break-inside: avoid;
        break-inside: avoid;
    }
}
