.rx-page {
    width: 100%;
    max-width: none;
    padding: 20px 10px 46px;
    color: #101828;
}

body.rx-modal-open {
    overflow: hidden;
}

.rx-hero {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
}

.rx-kicker {
    margin: 0 0 6px;
    color: #2563eb;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.rx-title {
    margin: 0 0 8px;
    color: #111827;
    font-size: 34px;
    line-height: 1.1;
    font-weight: 900;
}

.rx-subtitle,
.rx-modal-subtitle {
    margin: 0;
    max-width: 920px;
    color: #667085;
    font-size: 14px;
    line-height: 1.55;
}

.rx-hero-actions,
.rx-form-actions,
.rx-modal-header-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.rx-btn {
    border: 0;
    border-radius: 14px;
    padding: 10px 14px;
    min-height: 40px;
    font-weight: 800;
    cursor: pointer;
    transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease;
}

.rx-btn:hover {
    transform: translateY(-1px);
}

.rx-btn:disabled {
    opacity: .45;
    cursor: not-allowed;
    transform: none;
}

.rx-btn-primary {
    color: #fff;
    background: linear-gradient(135deg, #2563eb, #38bdf8);
    box-shadow: 0 10px 22px rgba(37, 99, 235, .22);
}

.rx-btn-light {
    color: #344054;
    background: #f3f6fb;
    border: 1px solid #e4e7ec;
}

.rx-btn-danger {
    color: #b42318;
    background: #fff1f1;
    border: 1px solid #fecaca;
}

.rx-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 16px;
}

.rx-stat-card,
.rx-panel,
.rx-toolbar,
.rx-step-card,
.rx-summary-card,
.rx-inline-pane,
.rx-destino-info {
    background: #fff;
    border: 1px solid #e7edf5;
    box-shadow: 0 14px 30px rgba(16, 24, 40, .045);
}

.rx-stat-card {
    border-radius: 18px;
    padding: 16px;
}

.rx-stat-card span {
    display: block;
    color: #667085;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .05em;
    margin-bottom: 8px;
}

.rx-stat-card strong {
    display: block;
    color: #111827;
    font-size: 26px;
    font-weight: 900;
}

.rx-toolbar {
    display: grid;
    grid-template-columns: 260px minmax(340px, 1fr) 170px;
    gap: 12px;
    align-items: end;
    border-radius: 18px;
    padding: 14px;
    margin-bottom: 18px;
}

.rx-toolbar .form-group {
    margin-bottom: 0;
}

.rx-toolbar label,
.form-group label,
.rx-ingredient-inputs label {
    display: block;
    color: #475467;
    font-size: 12px;
    font-weight: 800;
    margin-bottom: 6px;
}

.rx-search-group input {
    min-width: 100%;
}

.rx-check {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 10px 14px;
    border: 1px solid #d7e1ec;
    border-radius: 14px;
    background: #fff;
    font-weight: 800;
    color: #344054;
}

.rx-check input {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: #2563eb;
}

.rx-only-active {
    margin-bottom: 0;
}

.rx-panel {
    width: 100%;
    border-radius: 24px;
    padding: 18px;
}

.rx-list-panel-full {
    min-height: 520px;
}

.rx-panel-head,
.rx-inline-pane-head,
.rx-modal-header,
.rx-destino-info-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.rx-panel-head {
    margin-bottom: 16px;
}

.rx-panel-head h3,
.rx-modal-header h3,
.rx-inline-pane-head h4 {
    margin: 0 0 4px;
    color: #111827;
    font-weight: 900;
}

.rx-panel-head h3,
.rx-modal-header h3 {
    font-size: 22px;
}

.rx-inline-pane-head h4 {
    font-size: 16px;
}

.rx-panel-head p,
.rx-inline-pane-head p,
.rx-modal-header p {
    margin: 0;
    color: #667085;
    font-size: 13px;
    line-height: 1.45;
}

.rx-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid #e4e7ec;
    border-radius: 18px;
    background: #fff;
}

.rx-table {
    width: 100%;
    min-width: 1050px;
    border-collapse: collapse;
}

.rx-table th,
.rx-table td {
    padding: 13px 14px;
    border-bottom: 1px solid #e4e7ec;
    vertical-align: middle;
    text-align: left;
    color: #344054;
    font-size: 13px;
}

.rx-table th {
    background: #f8fafc;
    color: #111827;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .05em;
    white-space: nowrap;
}

.rx-table tbody tr:nth-child(even) {
    background: #fbfdff;
}

.rx-table tbody tr:hover {
    background: #eff6ff;
}

.rx-table strong {
    color: #111827;
    font-weight: 900;
}

.rx-actions-cell {
    width: 115px;
    white-space: nowrap;
}

.rx-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin-right: 6px;
    border: 0;
    border-radius: 10px;
    background: #ff4438;
    color: #fff;
    cursor: pointer;
    font-size: 17px;
    box-shadow: 0 8px 16px rgba(255, 68, 56, .18);
}

.rx-icon-btn-primary {
    background: #2563eb;
    box-shadow: 0 8px 16px rgba(37, 99, 235, .18);
}

.rx-icon-btn-danger {
    background: #111827;
    box-shadow: none;
}

.rx-pill,
.rx-type-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 11px;
    font-weight: 900;
    white-space: nowrap;
    border: 1px solid transparent;
}

.rx-pill-ok,
.rx-type-badge.is-receta {
    background: #ecfdf3;
    color: #027a48;
    border-color: #abefc6;
}

.rx-pill-warn,
.rx-type-badge.is-extra {
    background: #fff7ed;
    color: #c2410c;
    border-color: #fed7aa;
}

.rx-pill-muted {
    background: #f2f4f7;
    color: #667085;
    border-color: #e4e7ec;
}

.rx-type-badge.is-producto {
    background: #eff6ff;
    color: #1d4ed8;
    border-color: #bfdbfe;
}

.rx-pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
    color: #667085;
    font-size: 13px;
    font-weight: 800;
}

.rx-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
}

.rx-modal.is-open {
    display: block;
}

.rx-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, .55);
    backdrop-filter: blur(3px);
}

.rx-modal-panel {
    position: relative;
    width: min(1480px, calc(100vw - 24px));
    max-height: calc(100vh - 22px);
    margin: 11px auto;
    background: #f8fbff;
    border: 1px solid #dbe4f0;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 26px 70px rgba(15, 23, 42, .28);
}

.rx-modal-header {
    padding: 18px 24px 14px;
    border-bottom: 1px solid #e7edf5;
    background: #fff;
}

.rx-modal-close {
    width: 40px;
    height: 40px;
    border: 1px solid #dbe4f0;
    border-radius: 12px;
    background: #f8fafc;
    color: #344054;
    font-size: 26px;
    font-weight: 400;
    line-height: 1;
    cursor: pointer;
}

.rx-modal-body {
    padding: 18px 24px 22px;
    max-height: calc(100vh - 118px);
    overflow: auto;
}

.rx-step-card {
    border-radius: 22px;
    padding: 16px;
    margin-bottom: 14px;
}

.rx-step-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    color: #111827;
    font-size: 15px;
    font-weight: 900;
}

.rx-step-title span {
    display: inline-flex;
    width: 30px;
    height: 30px;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: #2563eb;
    border-radius: 10px;
    font-weight: 900;
}

.rx-form-grid {
    display: grid;
    gap: 14px;
}

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

.rx-form-grid-3 {
    grid-template-columns: 220px minmax(260px, 1fr) minmax(260px, 1fr);
}

.rx-check-wrap {
    display: flex;
    align-items: flex-end;
}

.rx-destino-info {
    border-radius: 18px;
    padding: 14px;
    margin-top: 14px;
    background: linear-gradient(180deg, #fff 0%, #fbfdff 100%);
}

.rx-destino-info-head {
    align-items: center;
    margin-bottom: 12px;
}

.rx-destino-info-head span {
    display: block;
    color: #667085;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.rx-destino-info-head strong {
    display: block;
    color: #111827;
    font-size: 18px;
    font-weight: 900;
    margin-top: 2px;
}

.rx-update-cost {
    margin: 0;
}

.rx-info-content {
    display: grid;
    grid-template-columns: 170px minmax(0, 1fr);
    gap: 12px;
    align-items: stretch;
}

.rx-info-image-box {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 154px;
    border: 1px solid #e7edf5;
    background: #f8fafc;
    border-radius: 16px;
    overflow: hidden;
}

.rx-info-image {
    width: 100%;
    height: 100%;
    max-height: 168px;
    object-fit: contain;
    padding: 12px;
}

.rx-info-table {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.rx-info-table div {
    border: 1px solid #e7edf5;
    background: #f8fafc;
    border-radius: 14px;
    padding: 10px 12px;
}

.rx-info-table span {
    display: block;
    color: #667085;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .05em;
    margin-bottom: 4px;
}

.rx-info-table b {
    display: block;
    color: #111827;
    font-size: 14px;
    font-weight: 900;
}

.rx-info-note {
    margin: 12px 0 0;
    color: #1d4ed8;
    font-weight: 800;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 14px;
    padding: 10px 12px;
}

.rx-modal-ingredients-grid {
    display: grid;
    grid-template-columns: minmax(330px, 420px) minmax(0, 1fr);
    gap: 16px;
    align-items: start;
}

.rx-inline-pane {
    border-radius: 22px;
    padding: 16px;
    min-height: 220px;
}

.rx-inline-pane-head {
    margin-bottom: 12px;
}

.rx-library-list,
.rx-ingredient-rows {
    display: grid;
    gap: 12px;
}

.rx-library-list {
    max-height: 540px;
    overflow-y: auto;
    padding-right: 4px;
}

.rx-library-list::-webkit-scrollbar {
    width: 10px;
}

.rx-library-list::-webkit-scrollbar-thumb {
    background: #9ca3af;
    border-radius: 99px;
}

.rx-library-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 12px 0;
}

.rx-chip {
    border: 1px solid #cfd8e6;
    background: #fff;
    color: #344054;
    border-radius: 999px;
    padding: 8px 14px;
    font-size: 12px;
    font-weight: 900;
    cursor: pointer;
}

.rx-chip.active {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}

.rx-item-card {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 48px;
    gap: 12px;
    align-items: center;
    overflow: hidden;
    border: 1px solid #dbe4f0;
    border-radius: 18px;
    padding: 14px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    cursor: pointer;
}

.rx-item-card.is-added {
    border-color: #bfdbfe;
    background: linear-gradient(180deg, #eff6ff 0%, #f8fbff 100%);
}

.rx-item-card-content {
    position: relative;
    z-index: 2;
    display: grid;
    gap: 4px;
}

.rx-item-type {
    display: inline-flex;
    width: fit-content;
    border-radius: 999px;
    padding: 4px 8px;
    background: #f2f4f7;
    color: #475467;
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.rx-item-card strong {
    display: block;
    color: #111827;
    font-size: 16px;
    font-weight: 900;
}

.rx-item-card small {
    color: #667085;
    font-size: 12px;
}

.rx-item-card em {
    color: #047857;
    font-size: 14px;
    font-weight: 900;
    font-style: normal;
}

.rx-item-watermark {
    position: absolute;
    right: 58px;
    top: 50%;
    transform: translateY(-50%);
    width: 72px;
    opacity: .12;
    pointer-events: none;
}

.rx-item-add-btn {
    position: relative;
    z-index: 2;
    width: 42px;
    height: 42px;
    border-radius: 14px;
    border: 1px solid #cbd5e1;
    background: #fff;
    color: #2563eb;
    font-size: 26px;
    font-weight: 700;
    cursor: pointer;
}

.rx-item-add-btn:disabled {
    cursor: not-allowed;
    color: #0f766e;
    background: #ecfdf3;
    border-color: #abefc6;
}

.rx-dropzone {
    border: 2px dashed #c8d7ea;
    border-radius: 20px;
    background: #fafdff;
    min-height: 180px;
    padding: 12px;
    transition: border-color .18s ease, background .18s ease;
}

.rx-dropzone.is-dragging {
    border-color: #2563eb;
    background: #eef5ff;
}

.rx-drop-empty,
.rx-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 100px;
    border-radius: 16px;
    color: #667085;
    background: #f9fbfd;
    border: 1px dashed #dbe4f0;
    padding: 18px;
}

.rx-empty-small {
    min-height: 70px;
}

.rx-ingredient-row {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(360px, 1.25fr) 44px;
    gap: 12px;
    align-items: center;
    border: 1px solid #dde6f0;
    border-radius: 18px;
    background: #fff;
    padding: 12px;
}

.rx-ingredient-main {
    display: flex;
    align-items: center;
    gap: 12px;
}

.rx-ingredient-main img {
    width: 44px;
    opacity: .75;
}

.rx-ingredient-main strong {
    display: block;
    color: #111827;
    font-size: 15px;
    font-weight: 900;
}

.rx-ingredient-main small {
    display: block;
    color: #667085;
    font-size: 12px;
    margin-top: 2px;
}

.rx-ingredient-inputs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.rx-remove-btn {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    border: 1px solid #fecaca;
    background: #fff1f1;
    color: #b42318;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

.rx-summary-card {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    border-radius: 20px;
    padding: 14px;
    margin-top: 14px;
}

.rx-summary-card span {
    display: block;
    color: #667085;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .05em;
    margin-bottom: 6px;
}

.rx-summary-card strong {
    display: block;
    color: #111827;
    font-size: 20px;
    font-weight: 900;
}

.rx-modal-footer {
    justify-content: flex-end;
    padding-top: 2px;
    margin-top: 8px;
}

.field-error {
    display: block;
    margin-top: 5px;
    color: #dc2626;
    font-size: 12px;
    font-weight: 700;
}

.rx-alert {
    margin-bottom: 16px;
    border-radius: 16px;
    padding: 12px 14px;
    font-weight: 800;
}

.rx-alert-success {
    background: #ecfdf3;
    border: 1px solid #abefc6;
    color: #027a48;
}

.rx-alert-warning {
    background: #fffaeb;
    border: 1px solid #fedf89;
    color: #b54708;
}

.rx-alert-danger {
    background: #fef3f2;
    border: 1px solid #fecdca;
    color: #b42318;
}

@media (max-width: 1180px) {
    .rx-modal-panel {
        width: calc(100vw - 20px);
    }

    .rx-modal-ingredients-grid,
    .rx-info-table,
    .rx-info-content {
        grid-template-columns: 1fr;
    }

    .rx-info-image-box {
        min-height: 140px;
    }

    .rx-ingredient-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    .rx-stats,
    .rx-toolbar,
    .rx-form-grid-2,
    .rx-form-grid-3,
    .rx-summary-card,
    .rx-ingredient-inputs {
        grid-template-columns: 1fr;
    }

    .rx-hero,
    .rx-panel-head,
    .rx-modal-header,
    .rx-destino-info-head {
        flex-direction: column;
        align-items: stretch;
    }

    .rx-pagination {
        flex-direction: column;
    }
}

/* Parche rendimiento recetas */
.rx-muted-line {
    display: block;
    margin-top: 3px;
    font-size: 11px;
    font-weight: 700;
    color: #6b7280;
}


/* =========================================================
   Botones de acciones bonitos para Recetas v3
   Reemplaza los cubos rojos/negros sin ícono de Voyager.
   ========================================================= */
.rx-actions-cell {
    width: 170px;
    min-width: 170px;
    white-space: nowrap;
}

.rx-actions-wrap {
    display: flex;
    align-items: center;
    gap: 7px;
    flex-wrap: nowrap;
}

.rx-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: auto;
    min-width: 38px;
    height: 34px;
    padding: 0 11px;
    border-radius: 999px;
    border: 1px solid #d7ddff;
    background: linear-gradient(135deg, #eef2ff 0%, #ffffff 100%);
    color: #4338ca;
    cursor: pointer;
    font-size: 12px;
    font-weight: 900;
    line-height: 1;
    box-shadow: 0 8px 18px rgba(67, 56, 202, .10);
    transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease, background .16s ease;
}

.rx-icon-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(67, 56, 202, .16);
    border-color: #a5b4fc;
}

.rx-icon-btn:active {
    transform: translateY(0) scale(.98);
}

.rx-icon-btn-primary {
    border-color: #bbf7d0;
    background: linear-gradient(135deg, #ecfdf3 0%, #ffffff 100%);
    color: #047857;
    box-shadow: 0 8px 18px rgba(4, 120, 87, .10);
}

.rx-icon-btn-primary:hover {
    border-color: #86efac;
    box-shadow: 0 12px 24px rgba(4, 120, 87, .16);
}

.rx-icon-btn-danger {
    border-color: #fecdd3;
    background: linear-gradient(135deg, #fff1f2 0%, #ffffff 100%);
    color: #e11d48;
    box-shadow: 0 8px 18px rgba(225, 29, 72, .10);
}

.rx-icon-btn-danger:hover {
    border-color: #fda4af;
    box-shadow: 0 12px 24px rgba(225, 29, 72, .16);
}

.rx-action-glyph {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 900;
    background: rgba(255, 255, 255, .75);
}

.rx-action-text {
    letter-spacing: .01em;
}

@media (max-width: 980px) {
    .rx-actions-cell {
        width: 92px;
        min-width: 92px;
    }

    .rx-icon-btn {
        width: 34px;
        min-width: 34px;
        padding: 0;
    }

    .rx-action-text {
        display: none;
    }
}

/* Recetas: bodega, control de stock directo y detalle de costo */
.rx-destino-checks {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

.rx-cost-breakdown {
    margin-top: 10px;
    padding: 12px 14px;
    border: 1px solid #dbe4f0;
    border-radius: 14px;
    background: #fff;
    color: #475467;
    font-size: 13px;
    line-height: 1.5;
}

.rx-cost-breakdown .rx-cost-line {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 5px 0;
    border-bottom: 1px dashed #e7edf5;
}

.rx-cost-breakdown .rx-cost-line:last-child {
    border-bottom: 0;
}

.rx-cost-breakdown .rx-cost-total {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #dbe4f0;
    font-weight: 900;
    color: #111827;
}

@media (max-width: 900px) {
    .rx-destino-checks {
        justify-content: flex-start;
        width: 100%;
    }
}

/* =========================================================
   RECETAS · Confirmación de eliminación 2026-07-28
========================================================= */
body.rx-confirm-open {
    overflow: hidden;
}

.rx-confirm-modal {
    position: fixed;
    inset: 0;
    z-index: 2147483000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 18px;
}

.rx-confirm-modal.is-open {
    display: flex;
}

.rx-confirm-backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    background: rgba(15, 23, 42, .62);
    backdrop-filter: blur(3px);
    cursor: default;
}

.rx-confirm-card {
    position: relative;
    z-index: 1;
    width: min(510px, 100%);
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 17px;
    padding: 24px;
    border: 1px solid #e2e8f0;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 30px 80px rgba(15, 23, 42, .32);
    animation: rxConfirmIn .18s ease-out;
}

.rx-confirm-icon {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    background: #fff1f2;
    color: #be123c;
    font-size: 25px;
}

.rx-confirm-kicker {
    display: block;
    margin-bottom: 4px;
    color: #be123c;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.rx-confirm-card h3 {
    margin: 0 0 8px;
    color: #0f172a;
    font-size: 22px;
    font-weight: 950;
}

.rx-confirm-card p {
    margin: 0 0 9px;
    color: #334155;
    font-size: 15px;
    font-weight: 750;
}

.rx-confirm-card small {
    display: block;
    color: #64748b;
    line-height: 1.45;
}

.rx-confirm-actions {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 5px;
}

.rx-btn-danger {
    border-color: #dc2626 !important;
    background: #dc2626 !important;
    color: #fff !important;
}

.rx-btn-danger:hover {
    background: #b91c1c !important;
}

@keyframes rxConfirmIn {
    from { opacity: 0; transform: translateY(8px) scale(.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 560px) {
    .rx-confirm-card {
        grid-template-columns: 1fr;
        padding: 20px;
    }
    .rx-confirm-actions {
        grid-column: 1;
        flex-direction: column-reverse;
    }
    .rx-confirm-actions .rx-btn { width: 100%; }
}


/* RECETAS · Fondo neutro del modal de eliminación 2026-07-29 */
.rx-confirm-backdrop {
    appearance: none !important;
    -webkit-appearance: none !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    outline: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    background-image: none !important;
    backdrop-filter: none !important;
}

/* Bodega principal debajo del nombre del ingrediente */
.rx-ingredient-warehouse {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 7px;
    padding: 5px 8px;
    border: 1px solid #dbe4f0;
    border-radius: 8px;
    background: #f7f9fc;
    color: #475467;
    font-size: 11px;
    font-style: normal;
    font-weight: 700;
}

.rx-ingredient-warehouse b {
    color: #344054;
}

.rx-ingredient-warehouse em {
    color: #667085;
    font-style: normal;
    font-weight: 600;
}

.rx-ingredient-main > div {
    min-width: 0;
}


/* 2026-08-06 · Acciones alineadas al extremo derecho de las tablas */
.rx-actions-head,
.rx-actions-cell { text-align: right !important; }
.rx-actions-cell .rx-actions-wrap { justify-content: flex-end; }

/* 2026-08-22 · Recetas: menos columnas, menos cajas y sin acentos naranjas */
.rx-table-wrap {
    border: 0;
    border-radius: 0;
    background: transparent;
}
.rx-table {
    min-width: 820px;
}
.rx-table th,
.rx-table td {
    padding: 12px 10px;
    border-bottom-color: #eef2f6;
}
.rx-table th {
    border-bottom: 1px solid #dfe6ee;
    background: #fafbfc;
    color: #667085;
    font-size: 11px;
}
.rx-table tbody tr:nth-child(even) { background: transparent; }
.rx-table tbody tr:hover { background: #fafcff; }
.rx-pill,
.rx-type-badge {
    padding: 4px 7px;
    border: 0;
    border-radius: 7px;
    font-size: 10.5px;
}
.rx-pill-warn,
.rx-type-badge.is-extra {
    border: 0 !important;
    background: #f1f5f9 !important;
    color: #475569 !important;
}
.rx-cell-primary {
    display: block;
    color: #172033;
    font-weight: 850;
}
.rx-cell-meta {
    display: block;
    margin-top: 3px;
    max-width: 320px;
    overflow: hidden;
    color: #7b8794;
    font-size: 10.5px;
    font-weight: 650;
    line-height: 1.3;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.rx-value-stack { display: grid; gap: 2px; }
.rx-value-stack strong { font-size: 12.5px; }
.rx-value-stack small { color: #7b8794; font-size: 10.5px; }
.rx-icon-btn {
    width: auto;
    min-width: 31px;
    height: 31px;
    padding: 0 8px;
    border-radius: 7px;
    box-shadow: none !important;
    font-size: 13px;
}
.rx-icon-btn-edit { background: #eef5ff; color: #285d9c; }
.rx-icon-btn-danger { background: #fef2f2; color: #b42318; }
.rx-icon-btn-primary { background: #eef5ff; color: #285d9c; }
@media (max-width: 760px) {
    .rx-table { min-width: 760px; }
}

/* 2026-08-22 · Recetas: encabezados y estados de tabla completamente neutros */
.rx-table .vase-sort-btn.is-active {
    background: transparent !important;
    color: inherit !important;
    box-shadow: none !important;
}
.rx-table .rx-pill-warn,
.rx-table .rx-type-badge.is-extra {
    border: 0 !important;
    background: #f1f5f9 !important;
    color: #475569 !important;
}

/* 2026-08-24 · Filas seleccionables: abrir/crear receta desde cualquier zona libre. */
.rx-table tbody tr.rx-click-row { cursor: pointer; }
.rx-table tbody tr.rx-click-row:hover > td {
    background: color-mix(in srgb, var(--liud-accent, #7c3aed) 4%, #ffffff) !important;
}
.rx-table tbody tr.rx-click-row:focus-within > td {
    background: color-mix(in srgb, var(--liud-accent, #7c3aed) 5%, #ffffff) !important;
}


/* Preparación y explicación legible del rendimiento de ingredientes. */
.rx-preparation-field { margin-top: 14px; }
.rx-preparation-input {
    min-height: 118px;
    height: auto;
    resize: vertical;
    line-height: 1.5;
}
.rx-preparation-field > small { display: block; margin-top: 5px; }
.rx-optional { font-size: 12px; font-weight: 500; color: #667085; }
.rx-cost-breakdown .rx-yield-explanation { min-width: 0; overflow-wrap: anywhere; }
.rx-cost-breakdown .rx-cost-line > strong { flex-shrink: 0; white-space: nowrap; }
@media (max-width: 640px) {
    .rx-cost-breakdown .rx-cost-line { flex-direction: column; gap: 4px; }
}

/* 2026-10-13: Diseño de ingredientes sin desbordamiento horizontal. */
#recetaModal .rx-modal-panel.vase-standard-dialog--wide {
    box-sizing: border-box;
    width: min(1480px, calc(100vw - 24px));
    max-width: calc(100vw - 24px);
}
#recetaModal .rx-modal-body { min-width: 0; overflow-x: hidden; }
#recetaModal .rx-step-card,
#recetaModal .rx-modal-ingredients-grid,
#recetaModal .rx-inline-pane,
#recetaModal .rx-dropzone,
#recetaModal .rx-ingredient-rows,
#recetaModal .rx-ingredient-row,
#recetaModal .rx-ingredient-main,
#recetaModal .rx-ingredient-main > div,
#recetaModal .rx-ingredient-inputs,
#recetaModal .rx-ingredient-inputs > label {
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}
#recetaModal .rx-modal-ingredients-grid {
    grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
}
#recetaModal .rx-ingredient-row {
    grid-template-columns: minmax(0, 1fr) 42px;
    grid-template-areas: "nombre quitar" "campos campos";
    gap: 10px;
    width: 100%;
}
#recetaModal .rx-ingredient-main { grid-area: nombre; overflow: hidden; }
#recetaModal .rx-ingredient-main > div { overflow-wrap: anywhere; }
#recetaModal .rx-remove-btn { grid-area: quitar; }
#recetaModal .rx-ingredient-inputs {
    grid-area: campos;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: end;
}
#recetaModal .rx-ingredient-inputs .form-control {
    box-sizing: border-box;
    min-width: 0;
    max-width: 100%;
    width: 100%;
}
@media (max-width: 1000px) {
    #recetaModal .rx-modal-ingredients-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 520px) {
    #recetaModal .rx-ingredient-inputs { grid-template-columns: minmax(0, 1fr); }
    #recetaModal .rx-modal-header,
    #recetaModal .rx-modal-body { padding-left: 12px; padding-right: 12px; }
    #recetaModal .rx-step-card,
    #recetaModal .rx-inline-pane { padding: 12px; }
}
