/* settleBill.css — Settlement modal redesign styles
   Adapted from cart-page-1.html reference design */

/* ── Modal Header — design-system aligned, fluid typography ── */
.settle-header {
    background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 60%, #373C44 100%);
    padding: clamp(10px, 1vw, 14px) clamp(14px, 1.8vw, 24px);
    display: flex;
    align-items: center;
    gap: clamp(10px, 1vw, 14px);
    border-bottom: none;
    border-radius: 0;
    color: #fff;
}
.settle-header-icon-wrap {
    width: clamp(32px, 3vw, 40px);
    height: clamp(32px, 3vw, 40px);
    border-radius: 50%;
    background: rgba(16,180,143,0.20);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.settle-header-icon-wrap .fa { font-size: clamp(13px, 1.2vw, 16px); color: #10B48F; }

.settle-header-info {
    display: flex;
    flex-direction: row;
    align-items: baseline;
    flex-wrap: nowrap;
    gap: clamp(8px, 1vw, 14px);
    flex: 1;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
}
.settle-header-eyebrow {
    font-size: clamp(11px, 1vw, 14px);
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    flex-shrink: 0;
}
.settle-header-amount {
    font-size: clamp(13px, 1.2vw, 16px);
    font-weight: 800;
    color: #10B48F;
    letter-spacing: 0.2px;
    line-height: 1.2;
    flex-shrink: 0;
}
.settle-header-bill {
    font-size: clamp(10px, 0.85vw, 11px);
    font-weight: 500;
    color: rgba(255,255,255,0.65);
    flex-shrink: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-left: clamp(6px, 0.8vw, 12px);
    border-left: 1px solid rgba(255,255,255,0.18);
}
.settle-header-bill strong { color: #fff; font-weight: 700; }

.settle-header-actions {
    display: flex;
    align-items: center;
    gap: clamp(6px, 0.6vw, 8px);
    flex-shrink: 0;
}
.settle-currency-btn {
    padding: clamp(5px, 0.6vw, 7px) clamp(10px, 1vw, 14px);
    border: 1.5px solid rgba(16,180,143,0.4);
    border-radius: 8px;
    background: rgba(16,180,143,0.18);
    color: #fff;
    font-size: clamp(10px, 0.85vw, 11px);
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}
.settle-currency-btn .fa { color: #10B48F; }
.settle-currency-btn:hover { background: rgba(16,180,143,0.32); border-color: #10B48F; }
.settle-select {
    height: clamp(26px, 2.6vw, 32px);
    border: 1.5px solid rgba(255,255,255,0.18);
    border-radius: 8px;
    padding: 0 10px;
    font-size: clamp(10px, 0.85vw, 11px);
    font-weight: 600;
    color: #fff;
    background: rgba(255,255,255,0.08);
    outline: none;
    cursor: pointer;
}
.settle-select option { color: #373C44; background: #fff; }
.settle-header .settle-conversion {
    font-size: clamp(10px, 0.85vw, 11px);
    font-weight: 700;
    color: #FFC860;
    padding: 4px 8px;
    border-radius: 6px;
    background: rgba(255,200,96,0.12);
    white-space: nowrap;
}

/* ── Summary Row (Total / Tendered / Remaining / Return) ── */
.settle-summary-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(clamp(120px, 14vw, 160px), 1fr));
    gap: clamp(8px, 0.9vw, 14px);
    padding: clamp(10px, 1.1vw, 16px) clamp(14px, 1.6vw, 24px);
    background: transparent;
    border-bottom: 1px solid #e7eaee;
}
.settle-summary-card {
    border: 1.5px solid transparent;
    border-radius: 10px;
    padding: clamp(8px, 1.05vw, 15px) clamp(10px, 1.25vw, 19px);
    background: #fff;
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: flex-start;
    justify-content: center;
    min-height: clamp(58px, 6.3vw, 82px);
    transition: border-color 0.15s, box-shadow 0.15s;
}
.settle-summary-card:hover {
    box-shadow: 0 4px 14px rgba(55,60,68,0.06);
}
.settle-summary-card.sc-total { background: rgba(74,144,217,0.08); border-color: rgba(74,144,217,0.25); }
.settle-summary-card.sc-tendered { background: rgba(16,180,143,0.08); border-color: rgba(16,180,143,0.25); }
.settle-summary-card.sc-tip { background: rgba(255,200,96,0.10); border-color: rgba(255,200,96,0.35); }
.settle-summary-card.sc-remaining { background: rgba(255,111,146,0.08); border-color: rgba(255,111,146,0.25); }
.settle-summary-card.sc-return { background: rgba(55,60,68,0.06); border-color: rgba(55,60,68,0.15); }
.settle-summary-card.sc-payable { background: rgba(74,144,217,0.06); border-color: rgba(74,144,217,0.20); }
.settle-summary-card.sc-advance { background: rgba(16,180,143,0.06); border-color: rgba(16,180,143,0.22); }
.settle-summary-card .ss-amount {
    font-size: clamp(13px, 1.25vw, 18px);
    font-weight: 800;
    letter-spacing: 0.2px;
    line-height: 1.15;
}
.settle-summary-card.sc-total .ss-amount { color: #4A90D9; }
.settle-summary-card.sc-tendered .ss-amount { color: #10B48F; }
.settle-summary-card.sc-tip .ss-amount { color: #D4A017; }
.settle-summary-card.sc-remaining .ss-amount { color: #FF6F92; }
.settle-summary-card.sc-return .ss-amount { color: #373C44; }
.settle-summary-card.sc-payable .ss-amount { color: #4A90D9; }
.settle-summary-card.sc-advance .ss-amount { color: #10B48F; }
.settle-summary-card.sc-total .ss-amount { color: #4A90D9; }
.settle-summary-card.sc-tendered .ss-amount { color: #10B48F; }
.settle-summary-card.sc-tip .ss-amount { color: #D4A017; }
.settle-summary-card.sc-remaining .ss-amount { color: #FF6F92; }
.settle-summary-card.sc-return .ss-amount { color: #373C44; }
.settle-summary-card.sc-payable .ss-amount { color: #4A90D9; }
.settle-summary-card.sc-advance .ss-amount { color: #10B48F; }
.settle-summary-card .ss-label {
    display: inline-flex;
    align-items: center;
    margin: 0;
    font-size: clamp(8px, 0.7vw, 10px);
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 4px;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    line-height: 1.2;
}
.settle-summary-card.sc-total .ss-label { background: #4A90D9; color: #fff; }
.settle-summary-card.sc-tendered .ss-label { background: #10B48F; color: #fff; }
.settle-summary-card.sc-tip .ss-label { background: #D4A017; color: #fff; }
.settle-summary-card.sc-remaining .ss-label { background: #FF6F92; color: #fff; }
.settle-summary-card.sc-return .ss-label { background: #373C44; color: #fff; }
.settle-summary-card.sc-payable .ss-label { background: #4A90D9; color: #fff; }
.settle-summary-card.sc-advance .ss-label { background: #10B48F; color: #fff; }

/* ── Payment Mode Selection (big cards) ── */
.settle-mode-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 28px;
    padding: 48px 32px;
    background: #f3f5f7;
    min-height: 320px;
}
.settle-mode-card {
    background: #fff;
    border: 2px dashed #d0d7e0;
    border-radius: 16px;
    padding: 40px 32px;
    width: 280px;
    height: 220px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
}
.settle-mode-card:hover {
    border-color: #10B48F;
    border-style: solid;
    background: rgba(16,180,143,0.03);
    box-shadow: 0 6px 24px rgba(16,180,143,0.12);
    transform: translateY(-3px);
}
.settle-mode-card:active {
    transform: scale(0.97);
    box-shadow: 0 2px 8px rgba(16,180,143,0.1);
}
.settle-mode-card-label {
    font-size: 22px;
    font-weight: 700;
    color: #373C44;
}

/* ── Tab Styles (override Bootstrap tabset look) ── */
.settle-modal-body .nav-tabs {
    border-bottom: 1.5px solid #e7eaee;
    background: #f5f7fa;
    display: flex;
    padding: 0;
    margin: 0;
}
.settle-modal-body .nav-tabs > li {
    flex: 1;
    margin-bottom: 0;
}
.settle-modal-body .nav-tabs > li > a {
    text-align: center;
    padding: 12px 8px;
    font-size: 13px;
    font-weight: 600;
    color: #9DA2AA;
    background: #f5f7fa;
    border: none;
    border-bottom: 3px solid transparent;
    border-radius: 0;
    margin: 0;
    transition: all 0.2s;
}
.settle-modal-body .nav-tabs > li > a:hover {
    color: #6A6F77;
    background: #eef1f5;
    border-color: transparent;
}
.settle-modal-body .nav-tabs > li.active > a,
.settle-modal-body .nav-tabs > li.active > a:hover,
.settle-modal-body .nav-tabs > li.active > a:focus {
    color: #4A90D9;
    border: none;
    border-bottom: 3px solid #4A90D9;
    background: #fff;
}
.settle-modal-body .nav-tabs > li > a .badge {
    background: #10B48F;
    color: #fff;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 8px;
    margin-left: 4px;
}
.settle-modal-body .tab-content {
    padding: 0;
}

/* ── Two-Column Payment Layout ── */
.settle-pay-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    margin-top: 10px;
}
.settle-pay-left {
    padding: 20px 24px;
    background: #fff;
    overflow-y: auto;
}
.settle-pay-right {
    background: #fafbfc;
    overflow-y: auto;
    margin: 16px 20px 16px 0;
    border: 1.5px solid #e7eaee;
    border-radius: 10px;
}

/* ── Form Controls ── */
.settle-pay-input {
    width: 100%;
    height: 40px;
    border: 1.5px solid #d0d7e0;
    border-radius: 8px;
    padding: 0 12px;
    font-size: 13px;
    color: #373C44;
    background: #fff;
    outline: none;
    margin-bottom: 12px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.settle-pay-input:focus {
    border-color: #4A90D9;
    box-shadow: 0 0 0 3px rgba(74,144,217,0.1);
}
.settle-pay-input::placeholder { color: #BABFC8; }
/* Locked state for advance EDC confirm-first flow only (applied via ng-class, never globally). */
.settle-pay-input.sp-locked-input {
    background: #eceeef;
    color: #98a0ab;
    cursor: not-allowed;
    border-color: #d0d7e0;
    box-shadow: none;
}

.settle-pay-select {
    width: 100%;
    height: 40px;
    border: 1.5px solid #d0d7e0;
    border-radius: 8px;
    padding: 0 12px;
    font-size: 13px;
    color: #373C44;
    background: #fff;
    outline: none;
    margin-bottom: 12px;
    transition: border-color 0.15s;
}
.settle-pay-select:focus { border-color: #4A90D9; }

/* ── Radio Group (Card Types) ── */
.settle-radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 14px;
    padding: 12px;
    background: #f8fafb;
    border-radius: 10px;
    border: 1px solid #f0f2f5;
}
.settle-radio-group label {
    font-size: 12px;
    font-weight: 600;
    color: #6A6F77;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 6px;
    transition: all 0.15s;
    min-width: 80px;
}
.settle-radio-group label:hover {
    background: rgba(74,144,217,0.08);
    color: #4A90D9;
}
.settle-radio-group input[type="radio"] {
    accent-color: #4A90D9;
    width: 14px;
    height: 14px;
}

/* ── Buttons ── */
.settle-add-btn {
    padding: 8px 20px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #10B48F 0%, #0D9A7A 100%);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s;
    box-shadow: 0 2px 8px rgba(16,180,143,0.25);
}
.settle-add-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(16,180,143,0.35);
}
.settle-tip-btn {
    padding: 8px 20px;
    border: none;
    border-radius: 8px;
    background: #4A90D9;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s;
    margin-left: 8px;
}
.settle-tip-btn:hover { background: #3a7ec7; }
.settle-info-btn {
    padding: 8px 20px;
    border: none;
    border-radius: 8px;
    background: #5bc0de;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    margin-left: 8px;
}
.settle-clear-link {
    font-size: 12px;
    font-weight: 600;
    color: #4A90D9;
    cursor: pointer;
    background: rgba(74,144,217,0.1);
    border: 1.5px solid #4A90D9;
    border-radius: 20px;
    padding: 5px 14px;
    margin-bottom: 12px;
    display: inline-block;
    transition: all 0.15s;
}
.settle-clear-link:hover { background: rgba(74,144,217,0.18); text-decoration: none; }

/* ── Bank / Payment Table ── */
.settle-bank-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: #fff;
    border: 1.5px solid #e7eaee;
    border-radius: 10px;
    overflow: hidden;
}
.settle-bank-table th {
    text-align: left;
    padding: clamp(6px, 0.8vw, 10px) clamp(10px, 1vw, 14px);
    font-size: clamp(9px, 0.8vw, 11px);
    font-weight: 700;
    color: #6A6F77;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    border-bottom: 1.5px solid #e7eaee;
    background: #f5f7fa;
}
.settle-bank-table td {
    padding: clamp(6px, 0.8vw, 10px) clamp(10px, 1vw, 14px);
    font-size: clamp(10px, 0.95vw, 12px);
    font-weight: 600;
    color: #373C44;
    border-bottom: 1px solid #f0f2f5;
}
.settle-bank-table tr:last-child td { border-bottom: none; }
.settle-bank-table tbody tr:hover {
    background: rgba(74,144,217,0.04);
}
.settle-bank-table .settle-remove-btn {
    font-size: 11px;
    font-weight: 600;
    color: #FF6F92;
    cursor: pointer;
    background: rgba(255,111,146,0.08);
    border: 1px solid #FF6F92;
    border-radius: 4px;
    padding: 2px 8px;
}
.settle-bank-table .settle-remove-btn:hover {
    background: rgba(255,111,146,0.15);
    text-decoration: none;
}
.settle-bank-table .settle-status-btn {
    font-size: 11px;
    font-weight: 600;
    color: #fff;
    background: #4A90D9;
    border: none;
    border-radius: 4px;
    padding: 3px 10px;
    cursor: pointer;
}
.settle-bank-table .settle-cancel-icon {
    color: #FF6F92;
    cursor: pointer;
    font-size: 14px;
}

/* ── Cash Denomination Grid — pixel-perfect button tiles ── */
.settle-denom-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(6px, 0.6vw, 10px);
    margin-top: clamp(6px, 0.8vw, 10px);
    padding: clamp(6px, 0.8vw, 10px);
    background: #f5f7fa;
    border: 1.5px solid #e7eaee;
    border-radius: 10px;
}
.settle-denom-btn {
    padding: clamp(10px, 1.4vw, 18px) 6px;
    text-align: center;
    font-size: clamp(12px, 1.1vw, 15px);
    font-weight: 700;
    color: #1a2a45;
    background: #fff;
    border: 1.5px solid #e7eaee;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s;
    letter-spacing: 0.2px;
}
.settle-denom-btn:hover {
    background: rgba(16,180,143,0.08);
    color: #0D7D6C;
    border-color: #10B48F;
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(16,180,143,0.12);
}
.settle-denom-btn:active {
    background: rgba(16,180,143,0.16);
    transform: translateY(0);
    box-shadow: none;
}

/* ── Denomination Count Table ── */
.settle-denom-table-wrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(8px, 0.8vw, 14px);
    margin-top: clamp(6px, 0.8vw, 12px);
}
.settle-denom-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: #fff;
    border: 1.5px solid #e7eaee;
    border-radius: 10px;
    overflow: hidden;
}
.settle-denom-table th {
    text-align: left;
    padding: clamp(6px, 0.8vw, 10px) clamp(10px, 1vw, 14px);
    font-size: clamp(9px, 0.8vw, 11px);
    font-weight: 700;
    color: #6A6F77;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    border-bottom: 1.5px solid #e7eaee;
    background: #f5f7fa;
}
.settle-denom-table td {
    padding: clamp(5px, 0.7vw, 8px) clamp(10px, 1vw, 14px);
    font-size: clamp(10px, 0.95vw, 12px);
    font-weight: 600;
    color: #373C44;
    border-bottom: 1px solid #f0f2f5;
}
.settle-denom-table tr:last-child td { border-bottom: none; }
.settle-denom-table tr:hover td { background: rgba(74,144,217,0.04); }
.settle-denom-table input {
    width: 56px;
    height: clamp(24px, 2.4vw, 30px);
    border: 1.5px solid #d0d7e0;
    border-radius: 6px;
    text-align: center;
    font-size: clamp(10px, 0.95vw, 12px);
    font-weight: 700;
    color: #1a2a45;
    outline: none;
    background: #fafbfc;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.settle-denom-table input:focus {
    border-color: #4A90D9;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(74,144,217,0.12);
}

/* ── Numpad (calculator mode) ── */
.settle-numpad-container {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 32px;
    padding: 20px;
}
.settle-numpad-display {
    width: 100%;
    font-size: 22px;
    text-align: center;
    padding: 10px 14px;
    border: 1.5px solid #d0d7e0;
    border-radius: 8px;
    background: #fff;
    color: #373C44;
    outline: none;
}
.settle-numpad-display:focus { border-color: #4A90D9; }
.settle-numpad-grid {
    display: grid;
    grid-template-columns: repeat(3, 72px);
    gap: 8px;
}
.settle-numpad-btn {
    width: 72px;
    height: 72px;
    font-size: 20px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid #e7eaee;
    border-radius: 8px;
    cursor: pointer;
    background: #f9fafb;
    color: #373C44;
    user-select: none;
    transition: all 0.15s;
}
.settle-numpad-btn:hover { background: #eef1f5; border-color: #d0d7e0; }
.settle-numpad-btn:active { background: #e2e6eb; }
.settle-numpad-clear {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    background: #FF6F92;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}
.settle-numpad-clear:hover { background: #e65f82; }
.settle-numpad-enter {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #10B48F 0%, #0D9A7A 100%);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    margin-top: 16px;
}
.settle-numpad-enter:hover { box-shadow: 0 4px 14px rgba(16,180,143,0.35); }

/* ── Process Tab Label ── */
.settle-process-tab {
    display: inline-block;
    padding: 8px 16px;
    font-size: 12px;
    font-weight: 700;
    color: #373C44;
    border: 1.5px solid #e7eaee;
    border-bottom: none;
    border-radius: 8px 8px 0 0;
    background: #fff;
    margin-bottom: 0;
    position: relative;
    top: 1px;
}

/* ── Input Group Addon Override ── */
.settle-modal-body .input-group-addon {
    background: #f5f7fa;
    border: 1.5px solid #d0d7e0;
    border-radius: 0 8px 8px 0;
    font-size: 12px;
    font-weight: 600;
    color: #6A6F77;
    cursor: pointer;
}
.settle-modal-body .input-group .form-control {
    border: 1.5px solid #d0d7e0;
    border-radius: 8px 0 0 8px;
    height: 40px;
    font-size: 13px;
}
.settle-modal-body .input-group .form-control:focus {
    border-color: #4A90D9;
    box-shadow: none;
}

/* ── Checkbox Override ── */
.settle-checkbox-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}
.settle-checkbox-row input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #4A90D9;
    cursor: pointer;
}
.settle-checkbox-row label {
    font-size: 13px;
    font-weight: 500;
    color: #474747;
    margin: 0;
}
.settle-checkbox-row p {
    font-size: 12px;
    color: #9DA2AA;
    margin: 0 0 0 24px;
}

/* ── Modal Footer ── */
.settle-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 24px;
    border-top: 1.5px solid #e7eaee;
    background: #f5f7fa;
    flex-wrap: wrap;
    gap: 10px;
}
.settle-footer-left {
    display: flex;
    align-items: center;
    gap: 8px 12px;
    flex-wrap: wrap;
    flex: 1;
}
.settle-footer-left label {
    font-size: 12px;
    font-weight: 500;
    color: #6A6F77;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 4px;
}
.settle-footer-left input[type="checkbox"] {
    accent-color: #4A90D9;
    width: 15px;
    height: 15px;
}
.settle-settle-btn {
    padding: 10px 28px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    border: none;
    background: linear-gradient(135deg, #10B48F 0%, #0D9A7A 100%);
    color: #fff;
    cursor: pointer;
    transition: all 0.15s;
    box-shadow: 0 2px 8px rgba(16,180,143,0.3);
}
.settle-settle-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(16,180,143,0.4);
}
.settle-settle-btn:disabled,
.settle-settle-btn.disabledButton {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}
.settle-cancel-btn {
    padding: 10px 28px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    border: 1.5px solid #FF6F92;
    background: #fff;
    color: #FF6F92;
    cursor: pointer;
    transition: all 0.15s;
    margin-left: 8px;
}
.settle-cancel-btn:hover { background: rgba(255,111,146,0.08); }
.settle-back-btn {
    padding: 10px 28px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    border: 1.5px solid #d0d7e0;
    background: #fff;
    color: #373C44;
    cursor: pointer;
    transition: all 0.15s;
}
.settle-back-btn:hover {
    background: #f5f7fa;
    border-color: #BABFC8;
}

/* ── Advance Section ── */
.settle-advance-row {
    display: flex;
    gap: 12px;
    align-items: stretch;
    padding: 12px 24px;
    flex-wrap: wrap;
}
.settle-advance-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.settle-advance-field > div {
    flex: 1;
}
.settle-advance-field label {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}
.settle-advance-field .settle-pay-input {
    margin-bottom: 0;
}

/* ── Charity Row ── */
.settle-charity-row {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
}
.settle-charity-row label {
    font-size: 12px;
    font-weight: 600;
    color: #373C44;
    white-space: nowrap;
    margin: 0;
}
.settle-charity-amount {
    width: 100px;
    height: 34px;
    margin-bottom: 0;
    padding: 6px 10px;
    box-sizing: border-box;
}
.settle-charity-select {
    width: 140px;
    min-width: 140px;
}
.settle-charity-select .select2-container {
    width: 100% !important;
}
.settle-charity-select .select2-choice {
    height: 34px;
    line-height: 20px;
    padding: 6px 10px;
    box-sizing: border-box;
}

/* ── Spacing Utilities ── */
.settle-mt-16 { margin-top: 16px; }
.settle-mb-12 { margin-bottom: 12px; }
.settle-section-gap { margin-top: 16px; }

/* ── Cash Amount Header (right panel) ── */
.settle-cash-amount-header {
    padding: 12px 16px;
    font-size: 13px;
    font-weight: 700;
    color: #373C44;
    border-bottom: 1.5px solid #e7eaee;
    background: #f5f7fa;
}

/* ── Well Override (for nested tabsets that still use well) ── */
.settle-modal-body .well {
    background: #fff;
    border: 1.5px solid #e7eaee;
    border-radius: 10px;
    box-shadow: none;
    padding: 16px;
}

/* ── Form Group Spacing ── */
.settle-modal-body .form-group {
    margin-bottom: 12px;
}

/* ── Form Control Override ── */
.settle-modal-body .form-control {
    border: 1.5px solid #d0d7e0;
    border-radius: 8px;
    height: 40px;
    font-size: 13px;
    color: #373C44;
    transition: border-color 0.15s;
}
.settle-modal-body .form-control:focus {
    border-color: #4A90D9;
    box-shadow: 0 0 0 3px rgba(74,144,217,0.1);
}

/* Manual cash actions — Add Cash + Add Tip + Clear Manual Cash in one row */
.settle-pay-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.settle-clear-link.settle-clear-right {
    margin-left: auto;
    margin-bottom: 0;
}

/* ── Responsive — stack payment cols + summary row on smaller modal widths ── */
/* Payment mode tab headings — wrap the amount badge onto the next line when viewport is cramped */
@media (max-width: 1280px) and (max-height: 800px) {
    .settle-modal-body .nav-tabs > li > a {
        padding: 8px 6px;
        line-height: 1.2;
        font-size: 10px;
        font-weight: 500;
        color: black;
    }
    .settle-modal-body .nav-tabs > li > a .badge {
        display: block;
        margin: 4px auto 0;
        width: fit-content;
    }
}

/* Lock modal height so the footer (Settle / Cancel) is always on-screen.
   Body scrolls internally instead of the whole page scrolling. */
@media (max-height: 800px) {
    .combo-modal-window .modal-dialog {
        margin-top: 1vh !important;
        margin-bottom: 1vh !important;
    }
    .combo-modal-window .modal-content {
        max-height: 98vh;
        display: flex;
        flex-direction: column;
    }
    .settle-modal-body {
        flex: 1 1 auto;
        min-height: 0;
        max-height: none;
        overflow-y: auto;
    }
    .settle-footer {
        flex-shrink: 0;
        padding: 8px 16px;
    }
}

/* Compact header — only when height is short (so footer stays visible without scroll) */
@media (max-height: 800px) {
    .settle-header {
        padding: 8px 14px;
        gap: 10px;
        flex-wrap: nowrap;
        white-space: nowrap;
        overflow: hidden;
    }
    /* Header elements use clamp() so they scale fluidly — no per-size overrides needed */
    .settle-header-bill { font-size: 10px; }
}

@media (max-width: 1100px) {
    .settle-pay-cols {
        grid-template-columns: 1fr;
    }
    /* Denomination / data-entry side is the first div; flip it below the summary table */
    .settle-pay-cols > div:first-child { order: 2; }
    .settle-pay-cols > div:nth-child(2) { order: 1; }
    .settle-summary-row {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 900px) {
    .settle-mode-card {
        width: 220px;
        height: 180px;
        padding: 28px 20px;
    }
    .settle-mode-card-label { font-size: 18px; }
    .settle-mode-grid { gap: 18px; padding: 24px 16px; min-height: 240px; }
}

/* Short-height viewports — compact summary cards so Settle/Cancel stay visible without scroll */
@media (max-height: 800px) {
    .settle-summary-row {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 6px;
        padding: 6px 14px;
    }
    .settle-summary-card {
        padding: 4px 8px;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        justify-content: center;
        gap: 2px;
        min-width: 0;
        overflow: hidden;
    }
    .settle-summary-card .ss-amount {
        font-size: 13px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 100%;
    }
    .settle-summary-card .ss-label {
        margin-top: 0;
        font-size: 9px;
        padding: 2px 6px;
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    .settle-mode-grid { min-height: 180px; padding: 16px; gap: 14px; }
    .settle-mode-card { height: 140px; padding: 20px; }
    .settle-mode-card-label { font-size: 16px; }
}

@media (max-height: 700px) {
    .settle-summary-row { padding: 4px 12px; }
    .settle-summary-card { padding: 3px 6px; }
    .settle-summary-card .ss-amount { font-size: 12px; }
    .settle-mode-grid { min-height: 140px; padding: 12px; }
    .settle-mode-card { height: 110px; padding: 14px; }
    .settle-mode-card-label { font-size: 14px; }
}

@media (max-width: 600px) {
    .settle-summary-row {
        grid-template-columns: 1fr;
        gap: 8px;
        padding: 10px 14px;
    }
    .settle-summary-card { padding: 8px 12px; }
    .settle-summary-card .ss-amount { font-size: 14px; }
    .settle-mode-card {
        width: 100%;
        max-width: 280px;
        height: 140px;
        padding: 20px;
    }
    .settle-pay-actions .settle-clear-link.settle-clear-right {
        margin-left: 0;
        width: 100%;
    }
}
