body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: white;
}

.container {
    display: flex;
    height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 220px;
    background: #f7f7f7;
    padding: 20px;
}

.logo {
    font-size: 18px;
    margin-bottom: 20px;
}

.sidebar-logo {
    display: block;
    width: 140px;
    margin: 0 auto 20px auto; /* center + spacing below */
}


.menu-item {
    font-size: 18px;
    padding: 10px 0;
    cursor: pointer;
    color: rgb(0, 0, 0);               /* match your sidebar text */
}

.menu-item:hover {
    color: #000000;             /* optional highlight effect */
}

/* Active state (when selected) */
.menu-item.active {
    color: #000000;
    font-weight: bold;
}


/* Main */
.main {
    flex: 1;
    padding: 30px;
    display: block;   /* FIX */
}

.top-bar {
    display: flex;
    justify-content: space-between;
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 20px;
}

.form-section {
    display: flex;
    gap: 40px;
}

/* Left Form */
.left-form {
    width: 50%;
}

.left-form input {
    width: 100%;
    padding: 12px;
    margin-bottom: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
}

.scan-row {
    display: flex;
    gap: 10px;
    width: 100%;
    align-items: center;   /* vertical alignment fix */
}


.scan-row input {
    flex: 1;                  /* input expands */
    height: 45px;
    padding: 0 12px;
    border-radius: 6px;
    border: 1px solid #ddd;
}

.scan-row .scan-btn {
    width: 140px;
    height: 45px;
    border-radius: 6px;
    border: 1px solid #ddd;
    background: black;
    color: white;
    cursor: pointer;
    white-space: nowrap;
    box-sizing: border-box;
    margin-bottom: 12px;   /* matches input spacing */
}


.services button {
    padding: 8px 12px;
    margin: 5px;
    border: 1px solid #000;
    background: white;
    cursor: pointer;
}

.add-btn {
    width: 100%;
    padding: 14px;
    margin-top: 10px;
    cursor: pointer;
}

/* Right Form */
.right-form {
    width: 50%;
}

.picture-btn {
    width: 100%;
    padding: 12px;
    margin-bottom: 10px;
    cursor: pointer;
}

.picture-box {
    width: 100%;
    height: 150px;
    background: #f0f0f0;
    border-radius: 6px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.payment-methods {
    margin-bottom: 10px;
}

.payment-methods label {
    margin-right: 20px;
}

.summary {
    margin: 20px 0;
    display: flex;
    justify-content: space-between;
}

.receipt-btn {
    width: 100%;
    height: 45px;
    border-radius: 6px;
    border: 1px solid #ddd;
    background: black;
    color: white;
    cursor: pointer;
    white-space: nowrap;
    box-sizing: border-box;
}

.active-service {
    background: #39ff67d8 !important;
    color: rgb(0, 0, 0) !important;
}

.active-addon {
    background: #39ff67d8 !important;
    color: rgb(0, 0, 0) !important;
}

.services button {
    transition: 0.2s ease;
}

.services button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.left-form input,
.scanShoes {
    width: 100%;
    height: 45px;
    border-radius: 6px;
    margin-bottom: 12px;
    padding: 0 12px;
    border: 1px solid #ddd;
    box-sizing: border-box;
}

.remove-shoe-btn {
    width: 100%;
    height: 45px;              /* SAME HEIGHT AS Scan Shoes */
    background: #ffffff;
    color: rgb(0, 0, 0);
    border-radius: 6px;
    border: 1px solid #000000;
    cursor: pointer;
    margin-top: 10px;
}

.shoe-block {
    margin-bottom: 20px;   /* Adjust 20px to match your desired gap */
}


.before-pic-btn {
    width: 100%;
    height: 45px;
    border-radius: 6px;
    border: 1px solid #ddd;
    background: black;
    color: white;
    cursor: pointer;
    white-space: nowrap;
    box-sizing: border-box;
    margin-bottom: 12px;
}

#beforePicPreview {
    width: 100%;
    height: 150px;          /* or your desired height */
    border: 1px solid #ddd;
    border-radius: 6px;
    overflow: hidden;       /* keeps image inside */
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;    /* optional */
}

#beforePicPreview img {
    width: 100%;
    height: 100%;
    object-fit: cover;      /* fills container without distortion */
    border-radius: 6px;
}

/* Make Amount Paid + Reference align perfectly with right form */
.right-form .payment-row,
.pickup-row {
    display: flex;
    gap: 10px;
    width: 100%;
    margin-bottom: 12px;
}

.right-form .payment-row input,
.pickup-row input {
    height: 45px;
    padding: 0 12px;
    border-radius: 6px;
    border: 1px solid #ddd;
    box-sizing: border-box;
    flex: 1;          /* both fields share the row equally */
    min-width: 0;     /* prevents overflow on small screens */
}


#referenceNumber:disabled {
    background: #f1f1f1;
    opacity: 0.6;
}

/* Remove arrows for Amount Paid (Chrome, Edge, Opera, Safari) */
#amountPaid::-webkit-inner-spin-button,
#amountPaid::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Remove arrows for Firefox */
#amountPaid {
    -moz-appearance: textfield;
}

.remove-pic-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0,0,0,0.6);
    color: white;
    border: none;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    line-height: 26px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

#beforePicPreview {
    position: relative; /* REQUIRED so X button stays inside preview box */
    overflow: hidden;
}


/* Toggle button (hidden on desktop) */
.sidebar-toggle {
    display: none;
    font-size: 24px;
    padding: 10px;
    cursor: pointer;
    color: white;
}

/* Mobile Sidebar (Folded) */
/* -------------------------------------------------
   PREMIUM MOBILE DRAWER SIDEBAR (GLASS, ANIMATED)
---------------------------------------------------*/

@media (max-width: 768px) {


    /* Drawer Overlay */
    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.35);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 900;
        backdrop-filter: blur(4px);
    }

    .sidebar-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    /* Drawer */
    .sidebar {
        position: fixed;
        top: 0;
        left: -260px; /* hidden by default */
        width: 240px;
        height: 100vh;
        padding: 20px;
        background: rgba(255, 255, 255, 0.25);
        backdrop-filter: blur(22px);
        -webkit-backdrop-filter: blur(22px);
        border-right: 1px solid rgba(255,255,255,0.35);
        box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
        border-radius: 0 18px 18px 0;
        transition: left 0.35s cubic-bezier(.25,.8,.25,1);
        z-index: 1000;
    }

    .sidebar.open {
        left: 0;
    }

    /* Menu items fade in smoothly */
    .menu-item {
        opacity: 0;
        transform: translateX(-12px);
        transition: 0.25s ease;
        color: white;
    }

    .sidebar.open .menu-item {
        opacity: 1;
        transform: translateX(0);
    }

    /* Main content shifts softly to right */
    .main {
        transition: 0.3s ease;
    }

    .main.shifted {
        transform: translateX(180px);
        filter: blur(2px);
    }
}


.main {
    opacity: 0;
    transform: translateX(20px);
    transition: 0.3s ease;
}

.main.show {
    opacity: 1;
    transform: translateX(0);
}

.dashboard-page {
    display: block;
}

/* ==============================================
   PREMIUM IPAD POS DASHBOARD
================================================*/

.dash-title {
    font-size: 26px;
    font-weight: 700;
    margin: 20px 0 15px;
    color: #111;
}

.dash-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 18px;
    margin-top: 10px;
}

.dash-card {
    background: rgba(255,255,255,0.72);
    backdrop-filter: blur(12px);
    border-radius: 18px;
    padding: 20px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.08);
    transition: 0.25s ease;
    border: 1px solid rgba(255,255,255,0.4);
}

.dash-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 22px rgba(0,0,0,0.12);
}

.dash-card h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.dash-number {
    font-size: 28px;
    font-weight: 700;
    margin: 8px 0;
    color: #000;
}

.dash-sub {
    font-size: 12px;
    color: #666;
}

/* Mobile grid */
@media(max-width:768px){
    .dash-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ============================
   DASHBOARD HEADER
============================ */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 10px 0 25px;
}

.dashboard-header h2 {
    font-size: 28px;
    font-weight: 700;
    margin: 0;
}

.dash-search {
    width: 240px;
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid #ddd;
    background: #fafafa;
    font-size: 14px;
}

/* ============================
   TOP METRIC CARDS
============================ */
.dash-metric-row {
    gap: 18px;
}

.metric-card {
    border-radius: 10px;
    background: rgb(0, 0, 0);
    padding: 20px;
    text-align: center;
    box-shadow: 0 4px 14px rgba(0,0,0,0.08);
    transition: 0.2s ease;
}

.metric-value {
    font-size: 50px;
    color: #ffffff;
    font-weight: 700;
    margin: 5px 0;
}

.metric-sub {
    font-size: 15px;
    color: #ffffff;
}

/* ============================
   MID GRID (GRAPH + CALENDAR)
============================ */
.dash-mid-grid {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 20px;
    margin-top: 25px;
}

.dash-card-lg {
    background: white;
    padding: 20px;
    border-radius: 16px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}

.fake-chart,
.fake-calendar {
    background: #ececec;
    border-radius: 12px;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* ============================
   TABLE
============================ */
.dash-table-card {
    background: white;
    margin-top: 30px;
    padding: 20px;
    border-radius: 16px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.08);
    width: 100%;              /* card takes full width of its column */
    box-sizing: border-box;   /* padding included in width */
}

/* Row at top of card: Transaction Number | Name | Status */
.dash-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 10px;
}

.dash-header-left {
    display: flex;
    align-items: baseline;  /* or 'center' if you want them perfectly level */
    gap: 8px;               /* space between Transaction # and Name */
}

/* Bottom row: Amount Paid | Value */
.dash-footer-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-top: 16px;
}

.dash-footer-row h5 {
    margin: 0;
    font-size: 14px;
    font-weight: 500;
    color: #444;
}


.dash-header-row h4 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #111;
}


.dash-header-row .paid-tag {
    white-space: nowrap; /* keep text on one line */

    /* shift pill 12px left so its right edge lines up with <th>Status</th> */
    margin-right: 12px;
}

.dash-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
    table-layout: fixed;      /* columns share width perfectly across the card */
}

.dash-table th,
.dash-table td {
    padding: 12px;
    border-bottom: 1px solid #eee;
    text-align: left;
    box-sizing: border-box;
}

/* Align Transaction # and Amount Paid with Shoe column text */
.dash-txn-number,
.dash-amount-label {
    padding-left: 12px;   /* same as .dash-table th/td padding */
}

.dash-amount-value{
    padding-right: 12px;   /* same as .dash-table th/td padding */
}

/* Master List pickup date footer value */
#pickupdate{
    padding-right: 12px;   /* match dash amount padding */
}

/* Slightly stronger line under header */
.dash-table thead th {
    background: #fafafa;
    border-bottom: 1px solid #ddd;
}

/* Optional: right-align the last column (Status/Amount) */
.dash-table th:last-child,
.dash-table td:last-child {
    text-align: right;
}

.paid-tag {
    background: #d1ffe0;
    padding: 6px 12px;
    border-radius: 14px;
    font-size: 12px;
    color: #0b7a27;
}

/* Make the status <select> look like the existing paid-tag pill */
.status-select {
    border: none;
    background: #d1ffe0;           /* same as .paid-tag */
    border-radius: 14px;
    padding: 4px 10px;
    font-size: 12px;
    color: #0b7a27;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;

     /* Center the status text inside the pill */
    display: inline-flex;
    align-items: center;      /* vertical center */
    justify-content: center;  /* horizontal center */
    text-align: center;

}

/* optional: small dropdown arrow via background-image if you want later */


/* ============================
   MOBILE RESPONSIVE
============================ */
@media (max-width: 900px) {
    .dash-metric-row {
        grid-template-columns: repeat(2, 1fr);
    }
    .dash-mid-grid {
        grid-template-columns: 1fr;
    }
    .dash-search {
        width: 150px;
    }
}

.page-section {
    display: none;
    width: 100%;
    height: auto;
}

.page-section.active {
    display: block;
    animation: fadeIn 0.25s ease;
}

/* Same animation Transaction already uses */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px);}
    to   { opacity: 1; transform: translateY(0);}
}

/* =====================================================
   MOBILE TOP BAR (HAMBURGER + TITLE)
===================================================== */

.mobile-header {
    display: none;                 /* hidden on desktop by default */
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 56px;
    padding: 0 16px;
    background: rgba(15, 15, 15, 0.92);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    color: #ffffff;
    z-index: 1200;
    display: flex;
    align-items: center;
    gap: 12px;
}

.mobile-menu-btn {
    border: none;
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
    font-size: 22px;
    width: 38px;
    height: 38px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.mobile-menu-btn:active {
    transform: scale(0.96);
}

.mobile-header-title {
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* Desktop – hide mobile header */
@media (min-width: 769px) {
    .mobile-header {
        display: none;
    }
}

/* Mobile – show header and push content down a bit */
@media (max-width: 768px) {
    .mobile-header {
        display: flex;
    }

    /* Make sure content doesn't go under the fixed header */
    .main {
        padding-top: 80px; /* 56px header + 24px breathing space */
    }

    .sidebar {
        position: fixed;
        top: 56px;                   /* just below the mobile header */
        left: 0;
        height: calc(100vh - 56px);
        width: 260px;                /* whatever your normal width is */
        transform: translateX(-100%);/* completely hidden off-screen */
        box-shadow: none;            /* no visible white strip + shadow */
        z-index: 1100;
    }

    .sidebar.open {
        transform: translateX(0);    /* slide in when open */
        box-shadow: 0 0 25px rgba(0,0,0,0.3); /* shadow only when visible */
    }
}

/* =========================================
   MOBILE: Stack left & right form vertically
   ========================================= */
@media (max-width: 768px) {

    /* Stack the two columns */
    .form-section {
        flex-direction: column;
        gap: 20px;           /* smaller gap between left & right */
    }

    /* Let each form take full width */
    .left-form,
    .right-form {
        width: 100%;
    }
}

/* =========================================
   CLICKABLE DASHBOARD TRANSACTION CARDS
========================================= */
.transaction-card {
    cursor: pointer;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.transaction-card:hover {
    box-shadow: 0 6px 18px rgba(0,0,0,0.14);
    transform: translateY(-1px);
}

/* =========================================
   TRANSACTION DETAIL MODAL
========================================= */
.txn-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.35);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.txn-modal.open {
    display: flex;
}

/* Modal header layout: title | status pill | close button */
.txn-modal-header {
    display: flex;
    align-items: center;          /* vertical center alignment */
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 10px;
}

.txn-modal-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    flex: 1;                      /* title takes up left side */
}

/* Status pill sits right before the X, aligned on same row */
.txn-modal-header .txn-status {
    margin-right: 4px;
}

/* Ensure title, status pill, and close button content are vertically centered */
.txn-modal-header h3,
.txn-modal-header .txn-status,
.txn-modal-header .txn-modal-close {
    display: flex;
    align-items: center;
}

/* We already position the close button absolutely, so it stays on the top-right.
   The grid still ensures the title + status line up nicely in width. */


.txn-modal-content {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    padding: 20px 24px;
    width: 90%;
    max-width: 480px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 16px 40px rgba(0,0,0,0.25);
    box-sizing: border-box;
}

.txn-modal-close {
    border: none;
    background: transparent;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
}

/* Only style direct h3 children of .txn-modal-content (none in your header),
   so modalTxnTitle keeps margin: 0 from .txn-modal-header h3 */
.txn-modal-content > h3 {
    margin-top: 0;
    margin-bottom: 10px;
}

.txn-modal-content p {
    margin: 4px 0;
    font-size: 14px;
}

/* Thin black line separating customer info from shoes/services in modal */
.modal-divider {
    border-top: 1px solid #c4c4c4;
    margin: 10px 0 10px;  /* spacing above and below the line */
}


.txn-modal-content ul {
    padding-left: 18px;
    margin: 6px 0 0;
}

/* Extra top gap before section labels in modal (e.g. Shoes & Services) */
.modal-section-title {
    margin-top: 14px;  /* matches gap between header and first line (10 + 4) */
}

.txn-modal-content li {
    font-size: 14px;
    margin-bottom: 2px;
}

/* Container for all items in the modal */
.modal-items {
    margin-top: 4px;
}

/* Each shoe block: header + detail row */
.modal-item-block {
    margin-bottom: 8px;
}

/* Line 1: Shoe model (full width) */
.modal-item-header {
    font-size: 14px;
    margin-bottom: 2px;
}

/* Line 2: Service | Total | Status */
.modal-item-row {
    display: flex;
    align-items: center;
    font-size: 13px;
    padding: 2px 0;
}

/* Service - left side */
.modal-item-service {
    flex: 1;
    text-align: left;
}

/* Total service price per shoe - right side, just before status */
.modal-item-total {
    text-align: right;
    margin-right: 8px;
}

/* Status - far right */
.modal-item-status {
    text-align: right;
}

/* =========================================
   MODAL TOTAL ROW (TOTAL label + amount)
========================================= */
.modal-total-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
    margin-bottom: 4px;
    font-size: 14px;
}

.modal-total-label {
    font-weight: 700;           /* TOTAL in bold */
}

.modal-total-value {
    font-weight: 700;
    text-align: right;
    flex: 1;                    /* allow it to push to the right edge */
}

/* Amount Paid row in modal: label left, value right */
.modal-amount-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
    font-size: 14px;
}

/* Claim payment history rows (match modal-amount-row style) */
.modal-claim-payment-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    font-size: 14px;

}

.modal-amount-label {
    margin-right: 8px;
}

.modal-amount-value {
    flex: 1;
    text-align: right;   /* <-- this makes the ₱... flush-right to modal width */
}

/* BALANCE row in modal: label left, value right */
.modal-balance-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
}

.modal-balance-label {
    margin-right: 8px;
}

.modal-balance-value {
    flex: 1;
    text-align: right;   /* right-align BALANCE amount to modal width */
}

.modal-claim-payment-item .modal-payment-label {
  margin: 0;
  flex: 1;
  min-width: 0;
}

.modal-claim-payment-item .modal-amount-value {
  flex: 0 0 auto;
  text-align: right;
  white-space: nowrap;
}

/* Payment method row in modal: label left, amount right */
.modal-payment-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    font-size: 14px;
    margin-top: -5px;            /* custom row spacing */

}

.modal-payment-label {
    margin: 0;                  /* reset */
    margin-right: 8px;          /* little gap before amount */
}

.modal-payment-row .modal-payment-label {
  flex: 1;
  min-width: 0;
}

.modal-payment-row > .modal-amount-value {
  flex: 0 0 auto;
  white-space: nowrap;
  align-self: flex-start;
}

.modal-payment-row .modal-amount-value {
    margin: 0;                  /* remove the 10px top margin from .modal-amount-value */
}

/* Small text used for date / attachments labels in modal */
.txn-modal-content p.modal-date-made {
    font-size: 10px;
    line-height: 1.2;
    color: #666;
    margin: 10px 0 6px;
}

/* Wrapper for attachments section in modal */
.modal-attachments-wrapper {
    margin-top: 4px;
    display: flex;           /* put Before & After in one row */
    gap: 10px;               /* small gap between them */
    flex-wrap: wrap;         /* if screen is small, they can wrap */
}

/* Square box for the image */
.modal-attachment-box {
    width: 120px;
    height: 120px;
    border-radius: 8px;
    background: #f0f0f0;
    border: 1px solid #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Inner wrapper for After image + X button */
.modal-attachment-inner {
    position: relative;
    width: 100%;
    height: 100%;
}

/* Image fits inside the square */
.modal-attachment-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
}

/* Delete / close button on After picture thumb */
.modal-attachment-remove {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: none;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Make the attachment clickable area full size */
.modal-attachment-box a {
    display: block;
    width: 100%;
    height: 100%;
}

/* Show hand cursor on hover to indicate click */
.modal-attachment-box img {
    cursor: pointer;
}

/* Optional style when no attachment */
.modal-attachment-empty span {
    font-size: 11px;
    color: #999;
}

/* Claim button under the row */
.modal-claim-btn {
    width: 100%;
    height: 40px;
    border-radius: 8px;
    border: none;
    background: #000;
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.1s ease;
}

.modal-claim-btn:hover {
    background: #222;
}

.modal-claim-btn:active {
    transform: scale(0.98);
}

.modal-claim-actions {
    display: flex;
    gap: 8px;
    margin-top: 6px;
}

.modal-claim-actions .modal-claim-btn {
    flex: 1;
    height: 40px;
}


/* Fullscreen image preview overlay */
.image-preview-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.image-preview-modal.open {
    opacity: 1;
    pointer-events: auto;
}

.image-preview-inner {
    border-radius: 12px;
    max-width: 90vw;
    max-height: 80vh;
    position: relative;
    box-shadow: 0 12px 30px rgba(0,0,0,0.5);
}

#imagePreviewImg {
    max-width: 100%;
    max-height: 70vh;
    display: block;
    border-radius: 8px;
}

/* Close button for image preview */
.image-preview-close {
    position: absolute;
    top: 6px;
    right: 6px;
    background: rgba(0,0,0,0.75);
    color: #fff;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

/* =========================================
   MODAL CLAIM ROW – PERFECT ALIGNMENT (MOBILE)
========================================= */

.modal-claim-row {
    display: flex;
    gap: 8px;
    width: 100%;
}

.modal-claim-amount,
.modal-claim-method,
.modal-claim-ref {
    flex: 1 1 0;
    width: 100%;
    min-width: 0;
    height: 38px;
    padding: 0 10px;
    border-radius: 6px;
    border: 1px solid #ddd;
    font-size: 13px;
    margin-top: 15px;
    background: #fff;
    color: #000;
    box-sizing: border-box;
}

.is-hidden{
    display:none !important;
}

/* Remove native select styling */
.modal-claim-method {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: none;
    cursor: pointer;
}

/* Placeholder color for select */
.modal-claim-method option[value=""] {
    color: #999;
}

/* When placeholder is selected */
.modal-claim-method:has(option[value=""]:checked) {
    color: #999;
}

.modal-claim-btn:disabled {
    background: #000000;
    cursor: not-allowed;
    opacity: 0.7;
}

.status-locked {
    pointer-events: none;
    cursor: default;
}

.modal-claim-payment-item {
  margin-top: 6px;
}

.modal-claim-payment-line {
  font-size: 12px;
  line-height: 1.2;
  opacity: 0.9;
}

/* Override the default modal-date-made margin for claim history */
.txn-modal-content p.modal-date-made.modal-claim-date {
  margin: 2px 0 0;
  font-size: 10px;
}

.modal-claim-payment-item { margin-top: 6px; }
.modal-claim-payment-line { font-size: 12px; color: #444; }

/* ================================
   ALIGN ALL MODAL AMOUNTS TO RIGHT
=================================== */

.modal-total-row,
.modal-amount-row,
.modal-payment-row,
.modal-balance-row,
.modal-claim-payment-item {
  display: grid;
  grid-template-columns: 1fr max-content; /* label | amount pinned right */
  column-gap: 10px;
  align-items: start;
  width: 100%;
}

/* make ALL amount/value texts pin to the SAME right edge */
.modal-total-value,
.modal-amount-value,
.modal-balance-value {
  justify-self: end;
  text-align: right;
  white-space: nowrap;
}

/* prevent long labels from breaking the grid */
.modal-total-label,
.modal-amount-label,
.modal-payment-label,
.modal-balance-label,
.modal-claim-payment-item .modal-payment-label {
  min-width: 0;
}

.modal-date-made.modal-claim-date{
  margin: 2px 0 0;
  padding-left: 0; /* keep it clean */
}

/* =====================================================
   INLINE RULES MOVED FROM index.html (keeps same behavior)
===================================================== */

.error {
    border: 2px solid red !important;
    background: #ffe6e6;
}

#printReceipt:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* ===== Claim history row (KEEP label + amount on ONE line) ===== */

.modal-claim-payment-item{
  display: grid !important;
  grid-template-columns: 1fr max-content; /* label | amount */
  column-gap: 10px;
  align-items: center;                   /* makes them align on same row */
  width: 100%;
  margin-top: 0px;                       /* adjust spacing ABOVE each row */
}

/* claim label (left) */
.modal-claim-payment-item .modal-payment-label{
  margin: 0 !important;                  /* IMPORTANT: remove the forced drop */
  min-width: 0;
  white-space: nowrap;                   /* keep it in one line */
  overflow: hidden;
  text-overflow: ellipsis;               /* if too long on small screens */
}

/* claim amount (right) */
.modal-claim-payment-item .modal-amount-value{
  margin: 0 !important;
  justify-self: end;
  text-align: right;
  white-space: nowrap;
}

/* spacing for the small date above each claim row */
.txn-modal-content p.modal-date-made.modal-claim-date{
  margin: 2px 0 0;
}

/* =========================================
   MODAL ITEM STATUS PILL COLORS
========================================= */
.status-select[data-status="Pending"]{
  background: #ffe5a0;
  color: #473821;
}

.status-select[data-status="Cleaning"]{
  background: #bfe1f6; /* your "#1e0ff" is not a valid hex; change this if you meant a different blue */
  color: #0a53a8;
}

.status-select[data-status="Ready"]{
  background: #d4edbc;
  color: #11734b;
}

.status-select[data-status="Cancelled"]{
  background: #ffd1d1;
  color: #925555;
}

.status-select[data-status="Claimed"]{
  background: #e6cff2;
  color: #5a3286;
}

/* ===== Shared status colors (modal select + dashboard pill) ===== */

.status-select[data-status="Pending"],
.paid-tag[data-status="Pending"]{
  background: #ffedd1;
  color: #7a4b00;
}

.status-select[data-status="Cleaning"],
.paid-tag[data-status="Cleaning"]{
  background: #d1e0ff; /* if you really meant #01e0ff, replace this */
  color: #003b7a;
}

.status-select[data-status="Ready"],
.paid-tag[data-status="Ready"]{
  background: #d1ffe0;
  color: #0b7a27;
}

.status-select[data-status="Cancelled"],
.paid-tag[data-status="Cancelled"]{
  background: #ffd1d1;
  color: #7a0000;
}

.status-select[data-status="Claimed"],
.paid-tag[data-status="Claimed"]{
  background: #e5d1ff;
  color: #4b007a;
}


/* Ref # pill beside the payment label (base payment + claim payments) */
.modal-payment-row .modal-payment-label,
.modal-claim-payment-item .modal-payment-label {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.modal-ref-number {
  font-size: 11px;
  line-height: 1;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid #e5e7eb;
  background: #f3f4f6;
  color: #555;
  white-space: nowrap;
}


/* ================================
   QR SCAN MODAL
================================ */
.qr-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.35);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2100;
}

.qr-modal.open {
    display: flex;
}

.qr-modal-content {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    width: min(520px, calc(100% - 24px));
    padding: 14px;
    box-shadow: 0 16px 40px rgba(0,0,0,0.15);
}

.qr-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 4px 4px 10px 4px;
    border-bottom: 1px solid #eee;
    margin-bottom: 10px;
}

.qr-modal-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.qr-modal-close {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    border: 1px solid #e5e5e5;
    background: #fff;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
}

.qr-scan-wrap {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.qr-video {
    width: 100%;
    border-radius: 14px;
    background: #000;
    aspect-ratio: 3 / 4;
    object-fit: cover;
}

.qr-scan-status {
    font-size: 13px;
    color: #333;
}

.qr-scan-actions {
    display: flex;
    gap: 10px;
}

.qr-scan-btn {
    flex: 1;
    height: 40px;
    border-radius: 10px;
    border: none;
    background: #000;
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
}

.qr-scan-note {
    font-size: 11px;
    color: #777;
    line-height: 1.35;
}
