* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
  }

  body {
    overflow: auto; /* Allow scrolling if needed */

    /* Hero-card style subtle background (no blobs) */
    background:
        radial-gradient(circle at 20% 30%, rgba(152, 60, 180, 0.10), transparent 55%),
        radial-gradient(circle at 80% 70%, rgba(90, 120, 255, 0.08), transparent 60%),
        linear-gradient(180deg, #0f0f14 0%, #14141c 100%);
    background-attachment: fixed;

    font-family: 'Figtree', sans-serif;
    font-weight: 300;
    color: #333;
}

/* Subtle grain overlay for depth */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image: radial-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 3px 3px;
    opacity: 0.15;
    z-index: 0;
}

  
  .sidebar {
    width: 250px;
    height: 100vh;
    background-color: #16182c;
    position: fixed; 
    overflow: auto; /* To handle overflow if the content exceeds the height */
    z-index: 100;
    }
    .adminLogo {
    color:#bdbdbd;
    justify-content: center;
    margin: 15px;
    padding: 15px;
    border-radius: 8px;
  }
  #adminText {
    margin: 0;
}
#split {
    border-bottom: 2px solid #bdbdbd;

}

#welcomeText {
    font-size: 1.5em; /* Adjust as needed */
    margin-bottom: 10px;

}

#businessText {
    font-size: 1.2em; /* Smaller than welcome text */
    margin-top: 10px;
}

  .sidebar ul {
    list-style-type: none;
  }

  

  .sidebar ul li a {
    text-decoration: none;
    font-size: larger;
    color: #983cb4;
    display: flex;
    align-items: center;
    padding: 30px 20px;
    transition: background-color 0.2s ease;
  }
  .sidebar ul li a:hover,
  .sidebar ul li a.active {
    background-color: #292936; /* Darker shade for hover */
  }
  .sidebar ul li a.active {
    background-color: #292936; /* Even darker shade for active */
  }

  .sidebar ul li a i {
    margin-right: 10px;
  }

  .content {
    margin-left: 250px;
    width: 85.5vw;
    box-sizing: border-box;
    position: relative;
    clear: both;
    z-index: 1; /* Ensure content is above background */

}

.content::before, .content::after {
    content: '';
    position: absolute;
    top: 0;
    height: 100%;
    background: #7a2294;
    transform: skewX(-50deg);
    transform-origin: left;
    z-index: 0; /* Ensure background is below content */

}

.content::before {
    left: 25%;
    width: 20%; /* Adjust width as needed */
}

.content::after {
    left: 47%;
    width: 10%; /* Adjust width as needed */
    background: #8d32a8; /* Different color to distinguish */
}

.extra-skew {
    position: absolute;
    top: 0;
    height: 100%;
    background: #a539c5;
    transform: skewX(-50deg);
    transform-origin: left;
    z-index: 0; /* Ensure background is below content */

}

.skew-3 {
    left: 59%;
    width: 5%; /* Adjust width as needed */
}

.skew-4 {
    left: 66%;
    width: 2%; /* Adjust width as needed */
    background: #bf45e4; /* Different color to distinguish */
}
.skew-5 {
    left: 70%;
    width: 1%; /* Adjust width as needed */
    background: #c64dea; /* Different color to distinguish */
}
.skew-6 {
    left: 73%;
    width: 0.5%; /* Adjust width as needed */
    background: #d75efc; /* Different color to distinguish */
}
.card {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    position: relative;
    z-index: 1; /* Ensure card is above background */
    flex-direction: column; /* Ensures content stacks vertically if needed */
}
.cardLabel {
    font-weight: lighter;
    font-size: 20px;
    color: #bdbdbd;
    max-height: 30px;
    padding-bottom: 50px;

}

.container {
    z-index: 1;
    display: flex;
    flex-direction: row;
    width: 100%;
    justify-content: center; /* Center the container horizontally */
    align-items: center; /* Center the container vertically */
}
.left-column {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.box {
  background-color: rgba(21, 26, 39, 0.92);
  color: #bdbdbd;
  padding: 20px;
  justify-content: start;
  border-radius: 12px;
  align-items: center;
  box-shadow: 0 25px 45px rgba(0, 0, 0, 0.35);
  margin: 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
}
.box.large {
    height: 750px; /* Adjust height as needed */
    width: 25vw;
    margin-left: 100px;
}
.box.small {
    display: flex;
    flex-direction: column; /* Align items in a column */
    justify-content: start; /* Center content vertically */
    align-items: center; /* Center content horizontally */
    text-align: center; /* Center text within the buttons */
    box-sizing: border-box; /* Ensure padding is included in width/height */
    height: 355px;
    width: 600px;
}
.boxButton {
        
    background-color: #00000000;
    color: #bdbdbd;
    border: 2px solid #bdbdbd;
    margin: 12px;
    padding: 20px;
    
    border-radius: 5px;
    cursor: pointer;
    font-size: 20pt; /* Adjusted font size if necessary */
    width: 95%; /* Increased width */
    transition: transform 0.2s ease;
    text-align: center;
    white-space: nowrap; /* Prevent line breaks */
    box-sizing: border-box; /* Include padding in the width calculation */
    display: inline-block;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);


}
.box.lifetime {
    height: 170px; /* Adjust height as needed */
    width: 818px;
}
.box.stats {
    height: 750px;
    width: 16.1vw;
}
.box.graph {
    height: 540px; /* Adjust height as needed */
    width: 818px;
    display: flex;
    flex-direction: column;
}

@media (max-width: 650px) {
    .content {
        margin-left: 0;
        width: 100%; /* Full width for smaller screens */
    }
    .card {
        height: 100%;
        width: 100%;
    }
    .container {
        flex-direction: column;
        align-items: left;
        
    }
    .left-column {
        width: 100%;
        flex-direction: column;
        order: 2;

    }
    .box.large {
        order: 1;
        height: 750px;
        width: 400px;
        margin-left: 0;
    }
    .box.small {
        order: 2;
        height: 350px;
        width: 100vw;
        margin-left: 0;
        padding-left: 0;
    }
    .box.small:last-child {
        order: 3;
    }
    .cardLabel {
        padding-bottom: 50px;
    }
    #logo {
        display: none;
        
    }
    .boxButton {
        width: 100%;
    }
    .sidebar {
        width: 100%;
        height: auto; /* Adjust the height for smaller screens */
        position: relative; /* Change to relative positioning */
    }
    
}
  
  #logo {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 100px; 
    cursor: pointer;
    

    }
   
   
    .quickStats h2 {
        font-weight: lighter;

        padding-top: 40px;
    }
    


    
    /* Adjust the positioning of skewed background elements */
    .content::before, .content::after, .extra-skew {
        display: none; /* Hide skewed backgrounds for simplicity */
    }
    
    /* Reintroduce skewed backgrounds for larger screens */
    @media (min-width: 650px) {
        .content::before, .content::after, .extra-skew {
            display: block;
        }
    }


#quickStatsLabel {
        border-bottom: 2px solid #bdbdbd;
        padding-bottom: 10px;
        margin-bottom: 10px;
    }
    #price {
        font-size: 25pt;
        color: rgb(0, 166, 0);
        border-bottom: 2px solid #bdbdbd;
        padding-bottom: 50px;
        padding-top: 40px;
        margin-bottom: 10px;


    }
    #numPurchases {
        font-size: 25pt;
        border-bottom: 2px solid #bdbdbd;
        padding-bottom: 50px;
        padding-top: 40px;
        margin-bottom: 10px;

    }
    #profit {

        font-size: 25pt;
        color: rgb(0, 166, 0);
        border-bottom: 2px solid #bdbdbd;

        padding-bottom: 50px;
        padding-top: 40px;
        margin-bottom: 10px;

    }
    #metricPurchases {
        font-size: 25pt;
        border-bottom: 2px solid #bdbdbd;
        padding-bottom: 50px;
        padding-top: 40px;
        margin-bottom: 10px;

    }
    #metricProfit {

        font-size: 25pt;
        color: rgb(0, 166, 0);
        border-bottom: 2px solid #bdbdbd;

        padding-bottom: 50px;
        padding-top: 40px;
        margin-bottom: 10px;

    }
   
    
    
    
    .boxButton:hover {
        transform: scale(1.04); /* Make the button 5% larger on hover */
    }
    
    #changePriceContainer {
        width: 100%;
    }
    .inputContainer {
        display: flex;
        justify-content: space-between;
        align-items: center;
        background-color: #00000000;
        color: #bdbdbd;
        margin: 12px;
        padding: 20px;
        border: 2px solid #bdbdbd;
        border-radius: 5px;
        font-size: 20pt;
        width: 95%;
        box-sizing: border-box;
        transition: transform 0.2s ease;
    }
    .inputContainer:hover {
        transform: scale(1.04); /* Make the button 5% larger on hover */
    }
    .inputButtonField {
        background-color: #00000000;
        color: #bdbdbd;
        border: none;
        outline: none;
        font-size: 20pt;
        text-align: center;
        width: 60%;
        box-sizing: border-box;
    }
    
    .submitButton {
        background-color: #00000000;
        color: #bdbdbd;
        border: none;
        cursor: pointer;
        font-size: 20pt;
        text-align: center;
    }
    .submitButton:hover {
        transform: scale(1.04); /* Make the button 5% larger on hover */
    }
    
    #qrCodeContainer {
        border: 2px solid rgba(224, 23, 211, 0.532);

    }
    #adminAppText {
        color: #bdbdbd;
        max-width: 280px;
        font-weight: lighter;
        font-size: 25pt;
    }

    .controls select {
        background-color: #00000000;
        color: #bdbdbd;
        border: 1px solid #bdbdbd;
        border-radius: 3px;
        box-shadow: 0 5px 5px rgba(0, 0, 0, 0.3);
        margin: 10px;
        padding: 3px;


    }

    .controls input {
        background-color: #00000000;
        color: #bdbdbd;
        border: 1px solid #bdbdbd;
        border-radius: 3px;
        box-shadow: 0 5px 5px rgba(0, 0, 0, 0.3);
        margin: 10px;
        padding: 4px;


    }
    .ui-datepicker-calendar .ui-state-default {
        background-color: #1c1f2e; /* Background color of the date cells */
        color: #bdbdbd; /* Text color of the date cells */
        border-radius: 2px; /* Optional: Add rounded corners */
        border: 1px solid #bdbdbd; /* Optional: Add a border to each cell */
        transition: background-color 0.3s ease, color 0.3s ease; /* Smooth transition on hover */
    }
    .ui-datepicker-calendar .ui-datepicker-today .ui-state-default {
        border: 2px solid #8d32a8; /* Purple border for the current day */
        box-sizing: border-box; /* Ensure border does not affect cell size */
        color: #bdbdbd; /* Text color for the current day */
    }
    /* Style the date picker container */
.ui-datepicker.ui-widget {
    background-color: #1c1f2e !important;
    border: 1px solid #bdbdbd !important;
    border-radius: 5px !important;
    padding: 10px !important;
    color: #bdbdbd !important;
    font-family: 'Figtree', sans-serif !important;
    box-shadow: 0 5px 5px rgba(0, 0, 0, 0.3);

}

/* Style the header (month and year) */
.ui-datepicker-header.ui-widget-header {
    background-color: #1c1f2e !important;
    color: #bdbdbd !important;
    border-bottom: 1px solid #bdbdbd !important;
}

/* Style the navigation icons */
.ui-datepicker-prev, .ui-datepicker-next {
    color: #bdbdbd !important;
}

/* Style the calendar cells (dates) */
.ui-datepicker-calendar td {
    border: 1px solid #1c1f2e !important;
}

/* Style the selected date */
.ui-datepicker-calendar .ui-state-active {
    background-color: #8d32a8 !important;
    color: #fff !important;
}

/* Style the hover state */
.ui-datepicker-calendar .ui-state-hover {
    background-color: #a539c5 !important;
    color: #fff !important;
}

/* Style the days of the week */
.ui-datepicker-calendar th {
    color: #bdbdbd !important;
}
    #metricBox2Label {
        border-bottom: 2px solid #bdbdbd;
        width: 100%;
        text-align: center;
        margin-bottom: 10px;
    }
    
    #metricBox2Content {
        display: flex;
        justify-content: space-between;
        width: 100%;
    }
    
    .metric {
        flex: 1;
        text-align: center;
        padding: 10px;
    }
    #totalProfit h1 {
        color: rgb(0, 166, 0);
    }
    .box.stats h3 {
        font-size: 22px;
    }
    .box.stats h2 {
        padding-top: 10px;

        font-size: 20px;
    }
    .box.stats h1 span {
        display: inline-block;
        font-size: 3vw; /* Use viewport width to make the font size responsive */
        max-width: 100%; /* Prevents the text from exceeding the box width */
        white-space: nowrap; /* Prevents line breaks within the text */
        overflow: hidden; /* Ensures text doesn't overflow the box */
        text-overflow: ellipsis; /* Adds ellipsis if the text overflows */
        padding-right: 10px;

    }
    #metricBoxLabel {
        border-bottom: 2px solid #bdbdbd;

        padding-bottom: 30px;
        padding-top: 10px;
        margin-bottom: 10px;
    }
    #myChart {
        color: #bdbdbd;

        width: 100% !important;
        height: 100% !important;
    }
    .controls {
        margin-bottom: 30px;
    }

  
  #settings-content .box.small:nth-child(2),
  #settings-content .box.large {
      visibility: hidden; 
  }
/* Styling specific to the scanner content */
#scanner-content .hidden-box {
    height: 110px;
    width: calc(720px + 25vw);
}
#scanner-content .scanner-box {
    display: flex;
    height: 600px; /* Adjust as needed */
    width: calc(720px + 25vw);  /* Adjust as needed */
    padding: 20px;
    box-sizing: border-box;
    flex-direction: row;
    gap: 50px;

}


.left-side {
    width: 48%; /* Allow some space for the vertical line */
    display: flex;
    flex-direction: column;
    justify-content: flex-start; /* Align content to the top */
    align-items: center; /* Center content horizontally */
}

#qrCodeContainer {
    width: 250px; /* Adjust the size of the QR code as needed */
    height: 250px;
    margin-bottom: 70px; /* Space between QR code and the text */
    border: solid black;

}

.vertical-line {
    width: 2px;
    background-color: #bdbdbd;
    height: 600px; /* Adjust height to fit within the box */
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

.right-side {
    width: 48%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start; /* Center content vertically */
}

#qrCodeText {
    color: #bdbdbd;
    font-size: 20px;
    padding-top: 70px;
    border-top: 2px solid #bdbdbd;

}

#scannerInfoText {
    color: #bdbdbd;
    font-size: 30px;


}
.right-side ul {
    font-size: 20px;
    padding: 20px;
}
.right-side ul li {
    padding: 20px;
}
/* Tutorial Modal Styles */
/* General modal styles */
.tutorial-modal, #activeHoursModal {
    display: none; /* Ensure modals are hidden by default */
    position: fixed; /* Fixed positioning ensures it stays above all other elements */
    z-index: 9999; /* Set high enough to appear above all other content */
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto; /* Allow scrolling if modal content overflows */
    background-color: rgba(0, 0, 0, 0.6); /* Semi-transparent background for darkening */
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px); /* Optional: Add blur effect for aesthetic */
}

/* Modal content container */
.tutorial-modal-content, #activeHoursModal .modal-content {
    position: relative;
    margin: 6vh auto; /* Center the modal vertically */
    padding: 20px;
    border: 1px solid rgba(199,169,109,0.45) !important;
    border-radius: 12px;
    background: #1a1a1f !important; /* More opaque for readability */
    color: #e0e0e0;
    width: min(92vw, 680px);
    max-width: 680px;
    max-height: 90dvh;
    overflow-y: auto;
    z-index: 10000; /* Ensure it remains above the overlay */
    box-shadow: 0 24px 54px rgba(0, 0, 0, 0.62), 0 0 0 1px rgba(0,0,0,0.28) !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
}

/* Close button adjustments */
.close, .close-tutorial {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 28px;
    cursor: pointer;
    color: #e0e0e0;
}

.close:hover, .close:focus,
.close-tutorial:hover, .close-tutorial:focus {
    color: #ffffff;
    text-decoration: none;
}

.tutorialButton {
    background-color: #8d32a8; /* Purple background */
    color: white;
    padding: 10px 20px;
    margin-top: 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.tutorialButton:hover {
    background-color: #a539c5; /* Lighter purple on hover */
}

.skipTutorialButton {
    background-color: #333; /* Dark gray */
    color: white;
    padding: 10px 20px;
    margin-top: 10px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    float: right;
}

.skipTutorialButton:hover {
    background-color: #555;
}
/* Progress Bar Styles */
.progress-container {
    width: 100%;
    background-color: #333; /* Dark gray background */
    border-radius: 5px;
    margin-top: 20px; /* Add some space above the progress bar */
}

.progress-bar {
    width: 0%; /* Start at 0% */
    height: 10px; /* Adjust the height as needed */
    background-color: #8d32a8; /* Purple color for the progress */
    border-radius: 5px; /* Rounded corners */
    transition: width 0.3s ease; /* Smooth transition for width */
}
#help-content h2 {
    padding: 20px;
}
#help-content .box.small:nth-child(2),
  #help-content .box.large {
      visibility: hidden; 
  }
  .help-form {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.help-form textarea {
    width: 90%;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
    border: 2px solid #bdbdbd;
    background-color: #1e1e2f;
    color: #e0e0e0;
    font-size: 16px;
    resize: none;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
    transition: border-color 0.3s ease;
}

.help-form textarea:focus {
    border-color: #8d32a8;
    outline: none;
}

#instructionText {
  padding: 12px !important;
  line-height: 1.45;
  border-radius: 8px;
  box-sizing: border-box;
}

.submit-help-button {
    background-color: #8d32a8; /* Purple background */
    color: white;
    padding: 10px 20px;
    margin-top: 10px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    width: 50%;
    font-size: 18px;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
}

.submit-help-button:hover {
    background-color: #a539c5; /* Lighter purple on hover */
}
#pricingAlgorithmContainer {
    display: flex;
    align-items: center;
    margin-top: 30px;
    gap: 10px;
    font-size: 25px;
    color: #bdbdbd;
}

#pricingAlgorithmMode {
    background-color: #151a27;
    color: #bdbdbd;
    border: 1px solid #983cb4;
    border-radius: 5px;
    padding: 5px 10px;
    font-size: 25px;
    outline: none;
    cursor: pointer;
}

#pricingAlgorithmMode:focus {
    border-color: #bdbdbd;
}
.help-icon {
    font-size: 18px;
    background-color: #151a27;
    color: #bdbdbd;
    border: 1px solid #983cb4;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    margin-left: 10px;
    transition: background-color 0.3s, color 0.3s;
}

.help-icon:hover {
    background-color: #292936;
    color: #ffffff;
}
#loadingOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.loadingSpinner {
    width: 50px;
    height: 50px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}
/* ====== New hamburger menu icon style ====== */
.hamburger {
    display: none;
    position: fixed;
    top: 10px;
    left: 10px;
    font-size: 30px;
    color: #bdbdbd;
    z-index: 1001;
    cursor: pointer;
}

/* Show hamburger on small screens */
@media (max-width: 650px) {
    .hamburger {
        display: block;
    }
    .sidebar {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        height: 100%;
        width: 250px;
        background-color: #16182c;
        z-index: 1001;
        overflow-y: auto;
        transition: transform 0.3s ease;
    }
    .sidebar.active {
        display: block;
    }
}
@media (max-width: 650px) {
    /* Ensure metrics container stacks cleanly */
    #metrics-content .container {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    /* Make each stats box fill width */
    #metrics-content .box.stats,
    #metrics-content .box.graph,
    #metrics-content .box.lifetime {
        width: 95vw;
        height: auto;
        padding: 10px;
        margin: 10px auto;
    }

    /* Ensure canvas inside graph resizes properly */
    #metrics-content canvas {
        width: 100% !important;
        height: auto !important;
    }

    /* Adjust text sizes for better mobile legibility */
    #metrics-content h1,
    #metrics-content h2,
    #metrics-content h3 {
        font-size: 18px;
    }

    /* Controls section mobile layout */
    #metrics-content .controls {
        flex-direction: column;
        align-items: stretch;
    }

    #metrics-content .controls select,
    #metrics-content .controls input {
        font-size: 16px;
        width: 100%;
    }
}
@media (max-width: 650px) {
    #settings-content .container {
      flex-direction: column;
      align-items: center;
    }
    #settings-content .left-column {
      width: 100%;
      order: 1;
    }
    #settings-content .box.small {
      width: 90%;
      margin: 20px auto;
    }
    #settings-content .box.large {
      display: none;
    }
  }
  .styled-textarea {
    width: 100%;
    max-width: 500px;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #ccc;
    font-size: 16px;
    resize: vertical;
    margin-bottom: 10px;
    background-color: #f8f8f8;
}

/* Layer real UI above the background */
.app-shell { 
  position: relative; 
  z-index: 1; 
}

/* ===== Translucent content boxes (match app content card) ===== */
.box,
.inputContainer,
.boxButton {
  background-color: rgba(21, 26, 39, 0.92) !important; /* #151a27 with translucency */
  -webkit-backdrop-filter: saturate(120%) blur(0.5px);
  backdrop-filter: saturate(120%) blur(0.5px);
  border-radius: 12px !important;
  box-shadow: 0 25px 45px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

/* Slightly lighter translucency on interactive surfaces */
.boxButton,
.inputContainer {
  background-color: rgba(21, 26, 39, 0.75) !important;
}

/* Retire the old skew bands behind content */
.content::before,
.content::after,
.extra-skew { 
  display: none !important; 
  content: none !important;
}

/* Typography accents to match the app */
.box h1, .box h2, .box h3,
#adminAppText, 
#quickStatsLabel,
#metricBoxLabel,
#metricBox2Label {
  color: #bdbdbd !important;
  font-weight: 600;
}

/* Chart container stays translucent */
.box.graph {
  background-color: rgba(21, 26, 39, 0.92) !important;
}

/* Sidebar harmonized with the theme */
.sidebar {
  background-color: rgba(22, 24, 44, 0.92);
  border-right: 1px solid rgba(255, 255, 255, 0.12);
  -webkit-backdrop-filter: saturate(120%) blur(0.5px);
  backdrop-filter: saturate(120%) blur(0.5px);
  box-shadow: 0 20px 35px rgba(0,0,0,0.45);
}

/* Loading overlay tuned to new look */
#loadingOverlay {
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
  border: 1px solid rgba(255,255,255,0.12);
  background-color: rgba(0, 0, 0, 0.55);
}

.dev-disabled { opacity: 0.45 !important; pointer-events: none !important; }

/* Darker green styling for revenue-related numbers */
#price span,
#profit span {
  color: rgba(30, 182, 73, 0.9);
}
.owner-table th, .owner-table td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  text-align: left;
  font-size: 13px;
  color: #bdbdbd;
  vertical-align: top;
  white-space: nowrap;
}
.owner-table th {
  color: #ffffff;
  font-weight: 700;
  position: sticky;
  top: 0;
  background: rgba(29, 29, 40, 0.96);
  z-index: 2;
}
.owner-table tr:hover td {
  background: rgba(152, 60, 180, 0.10);
}
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; }

.q-small-btn {
  background: rgba(152, 60, 180, 0.18);
  border: 1px solid rgba(152, 60, 180, 0.45);
  color: #ffffff;
  padding: 7px 10px;
  border-radius: 8px;
  font-size: 12px;
  cursor: pointer;
  white-space: nowrap;
}
.q-small-btn:hover { background: rgba(152, 60, 180, 0.26); }
.q-small-btn:disabled { opacity: 0.55; cursor: default; }
.owner-modal {
  position: fixed;
  inset: 0;
  z-index: 2147483647;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.owner-modal-card {
  width: min(720px, 96vw);
  background: #1d1d28;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.45);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  max-height: 90dvh;
}
.owner-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.owner-modal-close {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  padding: 6px;
  line-height: 1;
}
.owner-modal-body {
  padding: 14px 16px;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
.owner-modal-footer {
  padding: 12px 16px 16px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  justify-content: flex-end;
}
.owner-grid { display: grid; }
@media (max-width: 560px) {
  .owner-grid { grid-template-columns: 1fr !important; }
}
.owner-stat {
  background: #232331;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 12px;
}
.owner-stat-label {
  color: #9aa0a6;
  font-size: 12px;
  margin-bottom: 6px;
}
.owner-stat-value {
  color: #ffffff;
  font-weight: 800;
  font-size: 18px;
}
.owner-row-clickable { cursor: pointer; }

/* === Q champagne-gold admin palette === */
:root {
  --q-bg: #0E0E0E;
  --q-bg-soft: #171717;
  --q-panel: #1D1D1D;
  --q-panel-soft: #242424;
  --q-gold: #C7A96D;
  --q-gold-light: #D3BA84;
  --q-gold-dark: #B59659;
  --q-text: #F7F4EE;
  --q-text-muted: rgba(247, 244, 238, 0.72);
}

html,
body {
  background: var(--q-bg) !important;
  color: var(--q-text) !important;
}

.app-shell,
.content,
.card,
.sidebar {
  background-color: transparent !important;
}

.soft-bg {
  background:
    radial-gradient(circle at 14% 16%, rgba(199,169,109,0.16), transparent 34%),
    radial-gradient(circle at 84% 18%, rgba(211,186,132,0.10), transparent 30%),
    radial-gradient(circle at 58% 82%, rgba(181,150,89,0.08), transparent 36%),
    var(--q-bg) !important;
}

.blob-purple,
.blob-blue,
.blob-pink {
  background: var(--q-gold) !important;
  opacity: 0.08 !important;
}

.sidebar,
.box,
.owner-modal-card,
.owner-stat {
  background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.025)) !important;
  border-color: rgba(199,169,109,0.20) !important;
  box-shadow: 0 18px 48px rgba(0,0,0,0.42) !important;
}

.sidebar {
  border-right: 1px solid rgba(199,169,109,0.14) !important;
}

.adminLogo h2,
.adminLogo h3,
.cardLabel h1,
.box h1,
.box h2,
.box h3,
.tutorial-modal-content h2,
.modal-content h2,
.owner-modal-header,
.owner-stat-value,
.owner-table th {
  color: var(--q-text) !important;
}

.box p,
.tutorial-modal-content p,
.modal-content p,
.owner-stat-label,
#ownerStatus,
#ownerUserModalStatus,
#ownerUserModalSub {
  color: var(--q-text-muted) !important;
}

#split,
.progress-bar {
  background: var(--q-gold) !important;
}

.sidebar ul li a {
  color: var(--q-text-muted) !important;
  border-color: transparent !important;
}

.sidebar ul li a:hover,
.sidebar ul li a.active {
  color: var(--q-text) !important;
  background: rgba(199,169,109,0.12) !important;
  border-color: rgba(199,169,109,0.28) !important;
}

.sidebar ul li a i,
.cardLabel h1,
#quickStatsLabel h3,
#metricBoxLabel h3,
#metricBox2Label h3,
.close,
.close-tutorial,
.contact-item i {
  color: var(--q-gold) !important;
}

.cardLabel {
  width: 100%;
  text-align: center !important;
}

.cardLabel h1 {
  width: 100%;
  text-align: center !important;
  margin: 0 auto !important;
}

.boxButton,
.tutorialButton,
.submitButton,
.q-small-btn,
#activeHoursForm button,
#instructionsModal button,
.submit-help-button {
  background: var(--q-gold) !important;
  color: #111111 !important;
  border: 1px solid var(--q-gold-light) !important;
  box-shadow: none !important;
}

.boxButton:hover,
.tutorialButton:hover,
.submitButton:hover,
.q-small-btn:hover,
#activeHoursForm button:hover,
#instructionsModal button:hover,
.submit-help-button:hover {
  background: var(--q-gold-light) !important;
  border-color: var(--q-gold-light) !important;
  box-shadow: none !important;
}

input,
textarea,
select,
.inputButtonField,
#datepicker {
  background: #181818 !important;
  color: var(--q-text) !important;
  border-color: rgba(199,169,109,0.30) !important;
}

input:focus,
textarea:focus,
select:focus,
.inputButtonField:focus,
#datepicker:focus {
  border-color: var(--q-gold) !important;
  box-shadow: 0 0 0 3px rgba(199,169,109,0.12) !important;
  outline: none !important;
}

#price span,
#profit span,
#metricProfit span,
#totalProfit span {
  color: rgba(30, 182, 73, 0.9) !important;
}

.owner-table th {
  background: rgba(29,29,29,0.96) !important;
}

.owner-table th,
.owner-table td {
  border-bottom-color: rgba(199,169,109,0.10) !important;
}

.owner-table tr:hover td {
  background: rgba(199,169,109,0.10) !important;
}

.owner-modal-footer,
.owner-modal-header {
  border-color: rgba(199,169,109,0.12) !important;
}

::selection {
  background: rgba(199,169,109,0.32);
  color: #ffffff;
}

#changePriceContainer,
#groupDiscountContainer {
  width: 100%;
  display: block;
}

#changePriceContainer .boxButton,
#groupDiscountContainer .boxButton {
  width: 100%;
  max-width: 100%;
}

.inputContainer {
  width: 100% !important;
  max-width: 100%;
}

.groupDiscountInputContainer {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: stretch;
  text-align: left;
}

.groupDiscountInputInfo {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.groupDiscountInputTitle {
  color: var(--q-text);
  font-size: 16px;
  font-weight: 700;
}

.groupDiscountInputHint {
  color: var(--q-text-muted);
  font-size: 13px;
  line-height: 1.35;
  white-space: normal;
}

.groupDiscountInputRow {
  display: flex;
  gap: 10px;
  width: 100%;
  align-items: center;
}

.groupDiscountInputRow .inputButtonField {
  flex: 1;
  min-width: 0;
  width: auto;
  text-align: left;
}

.groupDiscountInputRow .submitButton {
  flex: 0 0 auto;
  white-space: nowrap;
  padding: 10px 14px;
}

@media (max-width: 650px) {
  .groupDiscountInputRow {
    flex-direction: column;
    align-items: stretch;
  }

  .groupDiscountInputRow .submitButton {
    width: 100%;
  }
}

/* ===== Final responsive/admin polish overrides ===== */
.content {
  width: calc(100% - 250px) !important;
  max-width: 100% !important;
  overflow-x: hidden !important;
  padding: 14px 16px 20px !important;
}

.card {
  min-height: calc(100vh - 20px);
  height: auto !important;
  padding: 8px 0;
  justify-content: flex-start !important;
  align-items: stretch !important;
}

.container {
  width: 100% !important;
  max-width: 1320px;
  margin: 0 auto;
  align-items: stretch !important;
  gap: 14px;
  flex-wrap: wrap;
}

.left-column {
  flex: 1 1 720px;
  min-width: 300px;
  gap: 12px;
}

.box {
  margin: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
}

.box.small,
.box.large,
.box.graph,
.box.stats,
.box.lifetime {
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
}

.box.small {
  padding: 14px !important;
  gap: 10px;
}

.box.large {
  padding: 16px !important;
}

#dashboard-content .box.small:first-child {
  order: 1;
}

#dashboard-content .box.small:last-child {
  order: 2;
}

#dashboard-content .box.large {
  order: 3;
}

/* Dashboard desktop/tablet 2x2 grid feel */
#dashboard-content .container {
  display: grid !important;
  grid-template-columns: minmax(320px, 1fr) minmax(320px, 1fr);
  grid-template-areas:
    "actions quick"
    "graph quick";
  gap: 14px !important;
  align-items: stretch !important;
}

#dashboard-content .left-column {
  display: contents !important;
}

#dashboard-content .left-column .box.small:first-child {
  grid-area: actions;
  min-height: 360px;
}

#dashboard-content .left-column .box.small:last-child {
  grid-area: graph;
  min-height: 300px;
}

#dashboard-content .box.large {
  grid-area: quick;
  min-height: 674px;
}

/* Action controls must always fit */
#changePriceContainer,
#groupDiscountContainer {
  width: 100% !important;
}

#changePriceContainer .boxButton,
#groupDiscountContainer .boxButton,
#activeHoursButton,
#dashboard-content .box.small .boxButton,
#settings-content .box.small .boxButton,
#help-content .submit-help-button {
  width: 100% !important;
  max-width: 100% !important;
  margin: 8px 0 !important;
  white-space: normal !important;
  line-height: 1.25;
  font-size: clamp(15px, 1.2vw, 18px) !important;
  padding: 14px 14px !important;
}

.inputContainer {
  padding: 12px !important;
  margin: 8px 0 !important;
  gap: 10px;
}

.inputButtonField {
  font-size: clamp(14px, 1.1vw, 17px) !important;
}

/* Metrics + graph/calendar polish */
#metrics-content .container {
  align-items: stretch !important;
}

#metrics-content .left-column {
  flex: 2 1 760px;
  min-width: 0;
}

#metrics-content .box.stats {
  flex: 1 1 320px;
  min-width: 280px;
}

#metrics-content .box.graph {
  min-height: 480px;
}

#dashboardChart,
#myChart {
  width: 100% !important;
  height: 100% !important;
  min-height: 280px;
}

#metrics-content .controls {
  display: flex !important;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px 12px;
  margin-bottom: 12px !important;
}

#metrics-content .controls label {
  font-size: 13px;
  color: var(--q-text-muted) !important;
  margin: 0 0 4px 0 !important;
  white-space: nowrap;
  line-height: 1.2;
}

#metrics-content .controls > label {
  min-width: 110px;
}

#metrics-content .controls > select,
#metrics-content .controls > input,
#datepicker {
  width: 150px !important;
  min-width: 0;
  margin: 0 !important;
  font-size: 14px !important;
  min-height: 40px;
  border-radius: 10px !important;
}

#metricBox2Content {
  gap: 10px;
  flex-wrap: wrap;
}

#metricBox2Content .metric {
  min-width: 220px;
}

/* Mobile/tablet focus */
body.sidebar-open .hamburger {
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 1100px) {
  #dashboard-content .container {
    display: flex !important;
    flex-direction: column !important;
  }

  #dashboard-content .left-column {
    display: flex !important;
    flex-direction: column !important;
    width: 100%;
  }

  #dashboard-content .left-column .box.small:first-child,
  #dashboard-content .left-column .box.small:last-child,
  #dashboard-content .box.large {
    min-height: 0;
  }
}

@media (max-width: 900px) {
  .content {
    margin-left: 0 !important;
    width: 100% !important;
    padding: 72px 10px 14px !important;
  }

  /* Force mobile-nav mode to prevent transparent fixed sidebar overlap */
  .sidebar {
    display: none !important;
    position: fixed !important;
    left: 0;
    top: 0;
    width: min(88vw, 300px) !important;
    height: 100vh !important;
    background: rgba(17, 17, 17, 0.98) !important;
    border-right: 1px solid rgba(199,169,109,0.26) !important;
    box-shadow: 0 18px 45px rgba(0,0,0,0.62) !important;
    z-index: 1100 !important;
    overflow-y: auto;
  }

  .sidebar.active {
    display: block !important;
  }

  .cardLabel h1 {
    font-size: 28px !important;
  }

  .container {
    gap: 10px !important;
  }

  #dashboard-content .container {
    display: flex !important;
    flex-direction: column !important;
  }

  #dashboard-content .container {
    gap: 8px !important;
    display: flex !important;
    flex-direction: column !important;
  }

  #dashboard-content .left-column {
    display: contents !important;
  }

  #dashboard-content .left-column > .box.small:first-of-type {
    order: 1 !important;
    margin: 0 !important;
    padding-bottom: 10px !important;
  }

  #dashboard-content > .container > .box.large {
    order: 2 !important;
    width: 100% !important;
    margin: 0 !important;
  }

  #dashboard-content .left-column > .box.small:last-of-type {
    order: 3 !important;
    margin: 0 !important;
    padding-top: 8px !important;
  }

  /* Metrics: force single-column stack to prevent overlap */
  #metrics-content .container {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 10px !important;
  }

  #metrics-content .left-column,
  #metrics-content .box.stats,
  #metrics-content .box.graph,
  #metrics-content .box.lifetime {
    width: 100% !important;
    flex: 1 1 auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }

  #metrics-content .box.stats {
    order: 1;
  }

  #metrics-content .left-column {
    order: 2;
  }

  #metrics-content .box.graph {
    min-height: 400px;
  }

  #metrics-content .controls {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px 8px;
    align-items: end;
    margin-bottom: 10px !important;
  }

  #metrics-content .controls > label {
    margin: 0 !important;
    font-size: 12px;
    min-width: 0;
  }

  #metrics-content .controls > select,
  #metrics-content .controls > input,
  #datepicker {
    width: 100% !important;
    min-width: 0 !important;
  }
}

@media (max-width: 650px) {
  .content {
    padding-top: 66px !important;
  }

  .card {
    min-height: auto;
  }

  .cardLabel {
    padding-bottom: 10px !important;
  }

  .cardLabel h1 {
    font-size: 24px !important;
  }

  .box {
    border-radius: 12px !important;
    padding: 12px !important;
  }

  #dashboard-content .container {
    gap: 8px !important;
    display: flex !important;
    flex-direction: column !important;
  }

  #dashboard-content .left-column {
    display: contents !important;
  }

  #dashboard-content .left-column > .box.small:first-of-type {
    order: 1 !important;
    padding: 10px !important;
    margin: 0 !important;
  }

  #dashboard-content > .container > .box.large {
    order: 2 !important;
    margin: 0 !important;
    width: 100% !important;
  }

  #dashboard-content .left-column > .box.small:last-of-type {
    order: 3 !important;
    margin: 0 !important;
    padding-top: 8px !important;
  }

  #metrics-content .controls {
    display: grid !important;
    grid-template-columns: 1fr;
    gap: 6px;
    margin-bottom: 12px !important;
    align-items: stretch;
    justify-items: stretch;
  }

  #metrics-content .controls > label {
    width: 100%;
    min-width: 0;
    margin: 0 !important;
    font-size: 12px;
    text-align: left;
  }

  #metrics-content .controls > select,
  #metrics-content .controls > input,
  #datepicker {
    width: 100% !important;
    min-height: 38px;
    font-size: 13px !important;
    max-width: none;
  }

  #metrics-content .box.graph {
    min-height: 360px;
  }

  #dashboardChart,
  #myChart {
    min-height: 230px;
  }

  #metricBox2Content .metric {
    min-width: 100%;
  }

  .sidebar.active {
    width: min(88vw, 300px) !important;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.55);
  }

  .hamburger {
    top: 10px;
    left: 10px;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    display: grid !important;
    place-items: center;
    background: rgba(17, 17, 17, 0.97);
    border: 1px solid rgba(199,169,109,0.34);
    color: var(--q-gold) !important;
    z-index: 1200;
  }

  .tutorial-modal-content,
  #activeHoursModal .modal-content {
    width: calc(100vw - 20px) !important;
    margin: 10px auto !important;
    padding: 14px !important;
    max-height: calc(100dvh - 20px);
    overflow-y: auto !important;
  }

  #activeHoursModal .modal-content {
    max-height: none !important;
    overflow-y: visible !important;
    margin: 6px auto 16px !important;
  }

  #activeHoursModal {
    align-items: flex-start;
    padding-top: 6px;
    padding-bottom: 10px;
    overflow-y: auto !important;
  }

  #activeHoursRows > div {
    grid-template-columns: 1fr !important;
    gap: 6px !important;
    margin-bottom: 12px !important;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(199,169,109,0.16);
  }

  #activeHoursRows > div label {
    text-align: left;
  }

  #activeHoursRows input[type="time"] {
    width: 100%;
  }

  #activeHoursForm button {
    width: 100%;
    margin-top: 8px;
  }
}

/* === Admin MFA gate === */
.app-shell.mfa-locked {
  pointer-events: none;
  -webkit-user-select: none;
  user-select: none;
  filter: blur(1px);
}

.admin-mfa-gate {
  position: fixed;
  inset: 0;
  z-index: 2147483647;
  background: rgba(0,0,0,0.68);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}

.admin-mfa-card {
  width: min(540px, 94vw);
  background: #1d1d1d;
  border: 1px solid rgba(199,169,109,0.28);
  border-radius: 14px;
  padding: 18px;
  color: #f7f4ee;
  box-shadow: 0 20px 60px rgba(0,0,0,0.52);
}

.admin-mfa-card h2 {
  margin: 0 0 8px 0;
  color: #f7f4ee;
}

.admin-mfa-card p {
  margin: 0 0 12px 0;
  color: rgba(247,244,238,0.74);
  line-height: 1.4;
}

.admin-mfa-card label {
  display: block;
  margin: 8px 0 6px;
  color: #f7f4ee;
}

.admin-mfa-card input {
  width: 100%;
  margin-bottom: 8px;
  background: #181818;
  color: #f7f4ee;
  border: 1px solid rgba(199,169,109,0.32);
  border-radius: 8px;
  padding: 10px 12px;
}

.admin-mfa-card button {
  width: 100%;
  margin-top: 8px;
  background: #c7a96d;
  color: #111;
  border: 1px solid #d3ba84;
  border-radius: 8px;
  padding: 10px 12px;
  cursor: pointer;
  font-weight: 700;
}
