* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Hello Headline W00 Regular', 'Bubblegum Sans', 'Quicksand', 'Arial Rounded MT Bold', sans-serif;
    background: #72bfed !important;
    min-height: 100vh;
    overflow-x: hidden;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
    /* Theme variables - Cafe */
    --cafe-left-bg: #9daffa;   /* updated cafe left bg */
    --cafe-right-bg: #6C87F8;  /* updated theme */
    --cafe-accent: #6C87F8;    /* updated accent */
    --cafe-key-action: #ffdb6f; /* requested key action color */
}

/* Barcode Input (Hidden but functional) */
.barcode-input {
    position: absolute;
    top: -9999px;
    left: -9999px;
    opacity: 0;
}

/* Screen Management */
.screen {
    display: none;
    min-height: 100vh;
}

.screen.active {
    display: flex;
    flex-direction: column;
}

/* ===== GLOBAL ELEMENTS ===== */

/* Universal Game Home Button (Top Left) */
.game-home-btn {
    position: absolute;
    top: 20px;
    left: 20px;
    background: #F48B45;
    color: #ffffff;
    border: 4px solid #2d3748;
    border-radius: 18px;
    padding: 15px 25px;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    z-index: 100;
}

.game-home-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

/* Theme-specific home button colors */
#postie-setup-screen .game-home-btn,
#postie-collection-screen .game-home-btn,
#postie-route-screen .game-home-btn,
#postie-signature-screen .game-home-btn,
#postie-complete-screen .game-home-btn,
#postie-all-done-screen .game-home-btn {
    background: #C6424A;
}

.cafe-left-panel .game-home-btn,
.cafe-menu-header .home-btn,
.cafe-menu-header .nav-btn.home-btn {
    background: var(--cafe-key-action);
    color: #2d3748;
}

.smoothie-bar-left-panel .game-home-btn {
    background: #A3A84C;
    position: static;
    margin: 20px 20px 10px 20px;
    align-self: flex-start;
}

/* ===== COLOR THEMES ===== */
/* Each game has its own color palette */

/* Home Screen */
#home-screen {
    background: #ffffff;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.home-container {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 50px;
    max-width: 1200px;
    position: relative;
}

.home-title {
    font-size: 6rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 4px;
    text-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
    margin: 0;
}

/* Colorful Letters with Black Border */
.home-title span {
    -webkit-text-stroke: 8px #2d3748;
    text-stroke: 8px #2d3748;
    paint-order: stroke fill;
}

.home-title .letter-l1 { color: #FF7F6A; }
.home-title .letter-e1 { color: #FBB982; }
.home-title .letter-t { color: #F2C94C; }
.home-title .letter-apos { color: #FFD1A9; }
.home-title .letter-s1 { color: #DA7354; }
.home-title .letter-space { display: inline-block; width: 0.3em; }
.home-title .letter-p { color: #F48B45; }
.home-title .letter-l2 { color: #FFAEC9; }
.home-title .letter-a { color: #FBB982; }
.home-title .letter-y { color: #C6424A; }
.home-title .letter-exclaim { color: #E7A73E; }

.game-buttons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    width: 100%;
    max-width: 1000px;
}

.settings-btn {
    background: #ffffff;
    border: 4px solid #2d3748;
    border-radius: 18px;
    padding: 15px 30px;
    font-size: 1.2rem;
    font-weight: 700;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 20px;
    box-shadow: 0 6px 0 #1a202c, 0 8px 20px rgba(0, 0, 0, 0.25);
}

.settings-btn:hover {
    background: #f7fafc;
    transform: translateY(-2px);
    box-shadow: 0 8px 0 #1a202c, 0 12px 25px rgba(0, 0, 0, 0.3);
}

.settings-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.start-game-btn {
    background: #ffffff;
    border: 5px solid #2d3748;
    border-radius: 30px;
    padding: 50px 40px;
    font-size: 2.2rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 3px;
    box-shadow: 0 10px 0 #1a202c, 0 20px 40px rgba(0, 0, 0, 0.4);
    line-height: 1.5;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
}

.start-game-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 0 #1a202c, 0 25px 50px rgba(0, 0, 0, 0.5);
}

.start-game-btn:active {
    transform: translateY(8px);
    box-shadow: 0 2px 0 #1a202c, 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* Themed Game Buttons */
.start-game-btn.supermarket-btn {
    background: #72bfed;
    color: #ffffff;
}

.start-game-btn.cafe-btn {
    background: var(--cafe-right-bg);
    color: #2d3748;
}

.start-game-btn.smoothies-btn {
    background: #8EBE92;
    color: #ffffff;
}

.start-game-btn.postie-btn {
    background: #FF7F6A;
    color: #ffffff;
}

.start-game-btn.library-btn {
    background: #8B4513;
    color: #ffffff;
}

/* Main Scanning Screen - Split Layout */
#scanning-screen.active {
    background: transparent;
    display: flex;
    height: 100svh; /* small viewport on mobile/tablets */
    height: 100dvh; /* dynamic viewport */
    height: 100vh;  /* fallback */
    padding: 0;
    min-height: 0;
}

.split-container {
    display: flex;
    width: 100%;
    height: 100%;
    max-width: 2000px;
    margin: 0 auto;
}

/* ===== SUPERMARKET GAME (BLUE THEME) ===== */

/* Left Panel - Scanned Items */
.left-panel {
    flex: 2;
    display: flex;
    flex-direction: column;
    background: #C9D0D3;
    border-right: 3px solid #30598a;
    overflow: hidden;
}

/* Right Panel - Keypad */
.right-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #72bfed;
    max-height: 100vh;
    overflow: hidden;
    width: 450px;
    min-width: 400px;
}

/* Swap supermarket columns: move cart (left-panel) to the right side */
#scanning-screen .left-panel {
    order: 2;
    border-right: none;
    border-left: 3px solid #30598a;
    flex: 0 0 50%;
    height: 100%;
    max-height: 100svh;
}

#scanning-screen .right-panel {
    order: 1;
    flex: 0 0 50%;
    width: auto;
    min-width: 0;
    height: 100%;
    max-height: 100svh;
}

/* Left Panel Header - Home Button Only */
.panel-header {
    background: #C9D0D3;
    padding: 20px;
    text-align: left;
    border-bottom: none;
    flex-shrink: 0;
}

.nav-btn.home-btn {
    background: #30598a;
    color: #ffffff;
    border: 4px solid #2d3748;
    border-radius: 18px;
    padding: 18px 30px;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.3);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.nav-btn.home-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

/* Right Panel Header - Mode Toggle Buttons */
.right-panel-header {
    background: #72bfed;
    padding: 15px;
    flex-shrink: 0;
    border-bottom: 3px solid #2d3748;
    position: sticky;
    top: 0;
    z-index: 10;
}

.mode-toggle-buttons {
    display: grid;
    grid-template-columns: auto 1fr 1fr;
    gap: 12px;
    width: 100%;
}

.mode-toggle-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 14px;
    padding: 15px 12px;
    font-size: 1.2rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 3px 0 #1a202c, 0 5px 10px rgba(0, 0, 0, 0.2);
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mode-toggle-btn:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 #1a202c, 0 2px 5px rgba(0, 0, 0, 0.15);
}

.mode-toggle-btn.active {
    background: #e27a37;
    color: #ffffff;
    border-color: #2d3748;
    box-shadow: 0 3px 0 #1a202c, 0 5px 10px rgba(0, 0, 0, 0.3);
}

.mode-toggle-btn:not(.active) {
    background: #30598a;
    color: #ffffff;
    border-color: #2d3748;
    box-shadow: 0 3px 0 #1a202c, 0 5px 10px rgba(0, 0, 0, 0.3);
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    padding-bottom: 140px; /* prevent overlap under sticky payment bar */
    background: transparent;
}

.cart-items::-webkit-scrollbar {
    width: 12px;
}

.cart-items::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
}

.cart-items::-webkit-scrollbar-thumb {
    background: #94a3b8;
    border-radius: 10px;
}

.cart-items::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

.empty-cart {
    text-align: center;
    color: #30598a;
    font-size: 2.5rem;
    padding: 100px 30px;
    font-weight: 900;
    letter-spacing: 1px;
}

.cart-item {
    background: #ffffff;
    border: none;
    border-left: 6px solid #e27a37;
    border-radius: 18px;
    padding: 22px 28px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 12px rgba(48, 89, 138, 0.2), 0 2px 4px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    transition: all 0.2s ease;
}

.cart-item:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 16px rgba(48, 89, 138, 0.3), 0 3px 6px rgba(0, 0, 0, 0.1);
}

.cart-item:active {
    transform: translateX(3px);
}

.cart-item-left {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
}

.cart-item-emoji {
    font-size: 3.5rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.cart-item-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    letter-spacing: 0.5px;
}

.cart-item-price {
    font-size: 2rem;
    color: #30598a;
    font-weight: 800;
    background: #72bfed;
    padding: 10px 22px;
    border-radius: 14px;
    border: 2px solid #30598a;
    box-shadow: 0 2px 8px rgba(48, 89, 138, 0.2);
}

/* Input Mode Containers */
.input-mode {
    display: none;
    width: 100%;
    height: 100%;
    flex-direction: column;
}

.input-mode.active {
    display: flex;
}

/* Scanner Mode - Keypad Section */
.scanner-keypad-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 20px;
    overflow-y: auto;
}

.barcode-display {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    font-size: 2rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    margin-bottom: 20px;
    box-shadow: 0 3px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.15);
    min-height: 65px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.keypad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(4, 1fr);
    gap: 12px;
    flex: 1;
}

.key-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 14px;
    padding: 0;
    font-size: 2.5rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #30598a;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    text-transform: uppercase;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 70px;
}

.key-btn:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.key-btn.clear-btn {
    background: #e27a37;
    color: #ffffff;
    font-size: 1.3rem;
}

.key-btn.enter-btn {
    background: #30598a;
    color: #ffffff;
    font-size: 1.3rem;
}

/* Scanner Payment Section (Bottom) */
.scanner-payment-section {
    background: #f1b873;
    border-top: 3px solid #2d3748;
    padding: 20px;
    flex-shrink: 0;
    position: sticky;
    bottom: 0;
    z-index: 2;
}

.scanner-total-display {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 18px 25px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 3px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.15);
}

.scanner-total-label {
    font-size: 1.5rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.scanner-total-amount {
    font-size: 2rem;
    font-weight: 900;
    color: #30598a;
}

.scanner-payment-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.scanner-pay-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 20px;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scanner-pay-btn:active:not(:disabled) {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.scanner-pay-btn.cash-btn {
    background: #F48B45;
    color: #ffffff;
}

.scanner-pay-btn.card-btn {
    background: #8EBE92;
    color: #ffffff;
}

.scanner-pay-btn:disabled {
    background: #94a3b8;
    color: rgba(255, 255, 255, 0.5);
    cursor: not-allowed;
    border-color: #64748b;
    box-shadow: 0 5px 0 #475569, 0 8px 18px rgba(0, 0, 0, 0.15);
}

/* Catalogue Mode */
#catalogue-mode {
    overflow-y: auto;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    padding: 20px;
    flex: 1;
    overflow-y: auto;
}

.product-grid::-webkit-scrollbar {
    width: 12px;
}

.product-grid::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
}

.product-grid::-webkit-scrollbar-thumb {
    background: #94a3b8;
    border-radius: 10px;
}

.product-grid::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

.product-card {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 140px;
    justify-content: center;
}

.product-card:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.product-card-emoji {
    font-size: 3.5rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.product-card-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1e293b;
    text-align: center;
    letter-spacing: 0.5px;
}

.product-card-price {
    font-size: 1.6rem;
    font-weight: 900;
    color: #30598a;
    background: #72bfed;
    padding: 8px 18px;
    border-radius: 12px;
    border: 2px solid #30598a;
    box-shadow: 0 2px 6px rgba(48, 89, 138, 0.2);
}

/* Catalogue Payment Section (Bottom) - Matches Scanner Mode */
.catalogue-payment-section {
    background: #f1b873;
    border-top: 3px solid #2d3748;
    padding: 20px;
    flex-shrink: 0;
}

.catalogue-total-display {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 18px 25px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 3px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.15);
}

.catalogue-total-label {
    font-size: 1.5rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.catalogue-total-amount {
    font-size: 2rem;
    font-weight: 900;
    color: #30598a;
}

.catalogue-payment-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.catalogue-pay-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 20px;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.catalogue-pay-btn:active:not(:disabled) {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.catalogue-pay-btn.cash-btn {
    background: #F48B45;
    color: #ffffff;
}

.catalogue-pay-btn.card-btn {
    background: #8EBE92;
    color: #ffffff;
}

.catalogue-pay-btn:disabled {
    background: #94a3b8;
    color: rgba(255, 255, 255, 0.5);
    cursor: not-allowed;
    border-color: #64748b;
    box-shadow: 0 5px 0 #475569, 0 8px 18px rgba(0, 0, 0, 0.15);
}



/* Payment Summary Screen */
#payment-summary-screen.active {
    background: #72bfed;
    padding: 40px;
    align-items: center;
    justify-content: center;
    min-height: 800px;
}

.summary-content {
    background: transparent;
    padding: 30px 20px;
    max-width: 800px;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.summary-total-box {
    background: #f1b873;
    border: 3px solid #2d3748;
    border-radius: 22px;
    padding: 40px 45px;
    box-shadow: 0 6px 0 #1a202c, 0 12px 30px rgba(0, 0, 0, 0.25);
}

.summary-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.summary-total-label {
    font-size: 2.5rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    letter-spacing: 3px;
}

.summary-total-amount {
    font-size: 4rem;
    font-weight: 900;
    color: #2d3748;
}

.summary-payment-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.summary-payment-btn {
    background: #30598a;
    border: 3px solid #2d3748;
    border-radius: 22px;
    padding: 50px 30px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    box-shadow: 0 6px 0 #1a202c, 0 12px 30px rgba(0, 0, 0, 0.25);
    min-height: 200px;
    font-family: 'Hello Headline W00 Regular', sans-serif;
}

.summary-payment-btn:active {
    transform: translateY(5px);
    box-shadow: 0 1px 0 #1a202c, 0 5px 15px rgba(0, 0, 0, 0.2);
}

.summary-payment-btn.cash-btn {
    background: #f1b873;
}

.summary-payment-btn.card-btn {
    background: #72bfed;
}

.payment-emoji {
    font-size: 6rem;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.payment-label {
    font-size: 2.2rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.back-to-scan-btn {
    background: #e27a37;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 22px;
    padding: 28px;
    width: 100%;
    font-size: 2rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 2px;
    box-shadow: 0 6px 0 #1a202c, 0 12px 30px rgba(0, 0, 0, 0.25);
    min-height: 80px;
}

.back-to-scan-btn:active {
    transform: translateY(5px);
    box-shadow: 0 1px 0 #1a202c, 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* ===== PAYMENT SCREENS (DYNAMIC THEMING) ===== */

/* Payment Popup Overlays */
.payment-popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.75);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.payment-popup-overlay.active {
    display: flex;
}

/* Card Payment Screen - Base Styles */
.card-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.card-title {
    font-size: 2.5rem;
    color: #30598a;
    font-weight: 900;
    text-align: center;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Theme-specific card popup backgrounds */
.card-popup.theme-supermarket { background: #C9D0D3; }
.card-popup.theme-cafe { background: var(--cafe-left-bg); }
.card-popup.theme-smoothies { background: #E2F0C2; }
.card-popup.theme-postie { background: #FFD1A9; }

/* Theme-specific card titles */
.card-popup.theme-supermarket .card-title { color: #30598a; }
.card-popup.theme-cafe .card-title { color: #2d3748; }
.card-popup.theme-smoothies .card-title { color: #A3A84C; }
.card-popup.theme-postie .card-title { color: #C6424A; }

.card-display {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 30px;
    text-align: center;
    box-shadow: 0 4px 0 #1a202c, 0 8px 20px rgba(0, 0, 0, 0.2);
}

.card-icon {
    font-size: 6rem;
    margin-bottom: 20px;
}

.card-instruction {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 20px;
}

.card-amount {
    font-size: 2rem;
    font-weight: 900;
    color: #30598a;
}

/* Theme-specific card amounts */
.card-popup.theme-supermarket .card-amount { color: #30598a; }
.card-popup.theme-cafe .card-amount { color: #2d3748; }
.card-popup.theme-smoothies .card-amount { color: #A3A84C; }
.card-popup.theme-postie .card-amount { color: #C6424A; }

.card-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

/* Cafe: set Insert Card screen cancel button color */
.card-popup.theme-cafe .card-action-btn.cancel-btn {
    background: #6C87F8;
    color: #2d3748;
}

.card-action-btn {
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 20px;
    font-size: 1.5rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.card-action-btn.cancel-btn {
    background: var(--cafe-key-action);
    color: #2d3748;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.card-action-btn.cancel-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

.card-action-btn.confirm-btn {
    background: var(--cafe-key-action);
    color: #2d3748;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.card-action-btn.confirm-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Card Processing Screen */
.processing-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 50px;
    max-width: 450px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
    text-align: center;
}

.processing-title {
    font-size: 2.2rem;
    color: #30598a;
    font-weight: 900;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Theme-specific processing popup backgrounds */
.processing-popup.theme-supermarket { background: #C9D0D3; }
.processing-popup.theme-cafe { background: var(--cafe-left-bg); }
.processing-popup.theme-smoothies { background: #E2F0C2; }
.processing-popup.theme-postie { background: #FFD1A9; }

/* Theme-specific processing titles */
.processing-popup.theme-supermarket .processing-title { color: #30598a; }
.processing-popup.theme-cafe .processing-title { color: #2d3748; }
.processing-popup.theme-smoothies .processing-title { color: #A3A84C; }
.processing-popup.theme-postie .processing-title { color: #C6424A; }

.processing-animation {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 25px;
    height: 120px;
}

.spinner {
    width: 80px;
    height: 80px;
    border: 8px solid rgba(255, 255, 255, 0.3);
    border-top: 8px solid #30598a;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Theme-specific spinner colors */
.processing-popup.theme-supermarket .spinner { border-top-color: #72bfed; }
.processing-popup.theme-cafe .spinner { border-top-color: var(--cafe-right-bg); }
.processing-popup.theme-smoothies .spinner { border-top-color: #8EBE92; }
.processing-popup.theme-postie .spinner { border-top-color: #FF7F6A; }

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.processing-message {
    font-size: 1.6rem;
    font-weight: 700;
    color: #2d3748;
}

/* Card Success Screen */
.card-success-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 50px;
    max-width: 450px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
    text-align: center;
}

.card-success-title {
    font-size: 2.5rem;
    color: #30598a;
    font-weight: 900;
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.card-success-icon {
    font-size: 8rem;
    color: #30598a;
    margin-bottom: 20px;
    font-weight: 900;
}

/* Theme-specific success popup backgrounds */
.card-success-popup.theme-supermarket { background: #C9D0D3; }
.card-success-popup.theme-cafe { background: var(--cafe-left-bg); }
.card-success-popup.theme-smoothies { background: #E2F0C2; }
.card-success-popup.theme-postie { background: #FFD1A9; }

/* Theme-specific success titles and icons */
.card-success-popup.theme-supermarket .card-success-title,
.card-success-popup.theme-supermarket .card-success-icon { color: #30598a; }
.card-success-popup.theme-cafe .card-success-title,
.card-success-popup.theme-cafe .card-success-icon { color: #2d3748; }
.card-success-popup.theme-smoothies .card-success-title,
.card-success-popup.theme-smoothies .card-success-icon { color: #8EBE92; }
.card-success-popup.theme-postie .card-success-title,
.card-success-popup.theme-postie .card-success-icon { color: #C6424A; }

.card-success-message {
    font-size: 1.8rem;
    font-weight: 900;
    color: #2d3748;
}

/* Cash Payment Screen */
.cash-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 20px;
    padding: 25px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 6px 0 #1a202c, 0 12px 30px rgba(0, 0, 0, 0.3);
}

/* Theme-specific cash popup backgrounds */
.cash-popup.theme-supermarket { background: #C9D0D3; }
.cash-popup.theme-cafe { background: var(--cafe-left-bg); }
.cash-popup.theme-smoothies { background: #E2F0C2; }
.cash-popup.theme-postie { background: #FFD1A9; }

.cash-title {
    font-size: 2rem;
    color: #30598a;
    font-weight: 900;
    text-align: center;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.cash-display {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 3px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.15);
}

.cash-total-row, .cash-paid-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.cash-paid-row {
    margin-bottom: 0;
    padding-top: 10px;
    border-top: 2px solid #e4dcbd;
}

.cash-label {
    font-size: 1.3rem;
    font-weight: 700;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
}

.cash-value {
    font-size: 1.8rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #30598a;
}

.money-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.money-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 14px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 2rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    box-shadow: 0 4px 0 #1a202c, 0 8px 15px rgba(0, 0, 0, 0.15);
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.money-btn:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.1);
}

.money-btn-last {
    grid-column: span 2;
}

.cash-cancel-btn {
    background: #9DAFFA;
    color: #2d3748;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 18px;
    width: 100%;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.cash-cancel-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Change Screen */
.change-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 50px;
    max-width: 450px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
    text-align: center;
}

/* Theme-specific change popup backgrounds */
.change-popup.theme-supermarket { background: #C9D0D3; }
.change-popup.theme-cafe { background: #FBB982; }
.change-popup.theme-smoothies { background: #E2F0C2; }
.change-popup.theme-postie { background: #FFD1A9; }

.change-title {
    font-size: 2.2rem;
    color: #30598a;
    font-weight: 900;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.change-amount-display {
    font-size: 6rem;
    font-weight: 900;
    color: #30598a;
    margin-bottom: 25px;
}

/* Theme-specific change screen titles and amounts */
.change-popup.theme-supermarket .change-title,
.change-popup.theme-supermarket .change-amount-display { color: #30598a; }
.change-popup.theme-cafe .change-title,
.change-popup.theme-cafe .change-amount-display { color: #C87C5A; }
.change-popup.theme-smoothies .change-title,
.change-popup.theme-smoothies .change-amount-display { color: #8EBE92; }
.change-popup.theme-postie .change-title,
.change-popup.theme-postie .change-amount-display { color: #C6424A; }

.change-message {
    font-size: 2rem;
    font-weight: 900;
    color: #2d3748;
}

/* Barcode Choice Screen (Supermarket) */
.barcode-choice-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.barcode-choice-title {
    font-size: 2.2rem;
    color: #30598a;
    font-weight: 900;
    text-align: center;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.barcode-choice-message {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
    margin-bottom: 30px;
}

.barcode-choice-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 25px;
}

.barcode-choice-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 20px;
    padding: 35px 20px;
    font-size: 1.3rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 6px 0 #1a202c, 0 12px 25px rgba(0, 0, 0, 0.25);
    min-height: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    line-height: 1.3;
}

.barcode-choice-btn:active {
    transform: translateY(5px);
    box-shadow: 0 1px 0 #1a202c, 0 5px 12px rgba(0, 0, 0, 0.2);
}

.barcode-choice-btn.new-product-btn {
    background: #F48B45;
    color: #ffffff;
}

.barcode-choice-btn.select-existing-btn {
    background: #72bfed;
}

.barcode-choice-cancel-btn {
    background: #F48B45;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 18px;
    width: 100%;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.barcode-choice-cancel-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Product Selection Screen (for unknown barcodes - Supermarket) */
.select-product-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 30px;
    max-width: 700px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.select-product-title {
    font-size: 2.2rem;
    color: #30598a;
    font-weight: 900;
    text-align: center;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.select-product-message {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
    margin-bottom: 25px;
}

.select-product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 25px;
}

.select-product-card {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 140px;
    justify-content: center;
}

.select-product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 7px 0 #1a202c, 0 10px 22px rgba(0, 0, 0, 0.25);
}

.select-product-card:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.select-product-card-emoji {
    font-size: 3rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.select-product-card-name {
    font-size: 1rem;
    font-weight: 700;
    color: #1e293b;
    text-align: center;
    letter-spacing: 0.5px;
}

.select-product-card-price {
    font-size: 1.4rem;
    font-weight: 900;
    color: #30598a;
    background: #72bfed;
    padding: 6px 16px;
    border-radius: 12px;
    border: 2px solid #30598a;
    box-shadow: 0 2px 6px rgba(48, 89, 138, 0.2);
}

.select-product-cancel-btn {
    background: #F48B45;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 18px;
    width: 100%;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.select-product-cancel-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Edit Cart Item Screen (Supermarket) */
.edit-item-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.edit-item-title {
    font-size: 2.2rem;
    color: #30598a;
    font-weight: 900;
    text-align: center;
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.edit-item-form {
    margin-bottom: 25px;
}

.edit-item-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
}

.edit-item-btn {
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 18px 12px;
    font-size: 1.3rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.edit-item-btn.delete-btn {
    background: #F48B45;
    color: #ffffff;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.edit-item-btn.delete-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

.edit-item-btn.cancel-btn {
    background: #ffffff;
    color: #2d3748;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.edit-item-btn.cancel-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

.edit-item-btn.save-btn {
    background: #8EBE92;
    color: #ffffff;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.edit-item-btn.save-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Add New Product Screen (Supermarket) */
.add-product-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.add-product-title {
    font-size: 2.2rem;
    color: #30598a;
    font-weight: 900;
    text-align: center;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.add-product-barcode-display {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 15px 20px;
    text-align: center;
    font-size: 1.3rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 25px;
    box-shadow: 0 3px 0 #1a202c;
    font-family: 'Courier New', monospace;
}

.add-product-barcode-display span {
    color: #30598a;
    font-size: 1.5rem;
    font-weight: 900;
}

.add-product-form {
    margin-bottom: 25px;
}

.form-field {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 1.2rem;
    font-weight: 900;
    color: #2d3748;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.form-input {
    width: 100%;
    padding: 15px;
    font-size: 1.3rem;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    border: 3px solid #2d3748;
    border-radius: 12px;
    background: #ffffff;
    font-weight: 700;
    color: #2d3748;
    box-shadow: 0 2px 0 #1a202c;
}

.form-input:focus {
    outline: none;
    border-color: #30598a;
}

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

.add-product-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.add-product-btn {
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 18px;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.add-product-btn.cancel-btn {
    background: #F48B45;
    color: #ffffff;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.add-product-btn.cancel-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

.add-product-btn.save-btn {
    background: #8EBE92;
    color: #ffffff;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.add-product-btn.save-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Settings Screen (Supermarket) */
.settings-popup {
    background: #C9D0D3;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 550px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.settings-title {
    font-size: 2.5rem;
    color: #30598a;
    font-weight: 900;
    text-align: center;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.setting-item {
    margin-bottom: 25px;
    padding: 20px;
    background: #ffffff;
    border-radius: 18px;
    border: 3px solid #2d3748;
    box-shadow: 0 5px 0 #1a202c, 0 8px 15px rgba(0, 0, 0, 0.15);
}

.setting-label {
    display: block;
    font-size: 1.3rem;
    font-weight: 900;
    color: #2d3748;
    margin-bottom: 12px;
    text-transform: uppercase;
}

.setting-select {
    width: 100%;
    padding: 14px;
    font-size: 1.2rem;
    border: 3px solid #2d3748;
    border-radius: 12px;
    background: #f1b873;
    font-weight: 900;
    cursor: pointer;
    color: #2d3748;
    box-shadow: 0 3px 0 #1a202c;
}

.toggle-btn {
    background: #30598a;
    color: #fff;
    border: 3px solid #2d3748;
    border-radius: 20px;
    padding: 12px 35px;
    font-size: 1.3rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 5px 0 #1a202c, 0 8px 15px rgba(0, 0, 0, 0.2);
}

.toggle-btn.off {
    background: #e27a37;
    box-shadow: 0 5px 0 #1a202c, 0 8px 15px rgba(0, 0, 0, 0.2);
}

.toggle-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.toggle-btn.off:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.stats-info {
    text-align: center;
}

.stats-info p {
    font-size: 1.2rem;
    margin: 10px 0;
    font-weight: 900;
    color: #2d3748;
}

.reset-stats-btn {
    background: #e27a37;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 12px;
    padding: 12px 25px;
    margin-top: 15px;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.15);
    text-transform: uppercase;
}

.reset-stats-btn:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.1);
}

.settings-close-btn {
    background: #72bfed;
    color: #2d3748;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 20px;
    width: 100%;
    font-size: 1.5rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    margin-top: 25px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    box-shadow: 0 6px 0 #1a202c, 0 12px 25px rgba(0, 0, 0, 0.2);
}

.settings-close-btn:active {
    transform: translateY(5px);
    box-shadow: 0 1px 0 #1a202c, 0 5px 12px rgba(0, 0, 0, 0.15);
}


/* Theme Variations */
body.dark-theme {
    background: #2a2a2a !important;
}

body.dark-theme #scanning-screen,
body.dark-theme #payment-summary-screen,
body.dark-theme #success-screen {
    background: #2a2a2a !important;
}

body.dark-theme .main-title {
    color: #fff;
}

body.dark-theme .scanning-section,
body.dark-theme .cart-section {
    background: #333;
    border-color: #fff;
}

body.dark-theme .section-title {
    color: #fff;
}

/* ===== POSTIE GAME (CORAL/RED THEME) ===== */

/* Postie Setup Screen - Family Selection */
#postie-setup-screen {
    background: linear-gradient(135deg, #FF7F6A 0%, #C6424A 100%);
    padding: 30px;
    align-items: center;
    justify-content: center;
    position: relative;
}

.postie-setup-container {
    max-width: 1000px;
    width: 90%;
}

.postie-setup-header {
    text-align: center;
    margin-bottom: 25px;
}

.postie-setup-title {
    font-size: 3rem;
    font-weight: 900;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
    margin: 0;
}

.postie-setup-content {
    background: #FFD1A9;
    border: 4px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.postie-setup-instruction {
    font-size: 1.6rem;
    font-weight: 900;
    color: #C6424A;
    text-align: center;
    margin-bottom: 25px;
}

.family-selection-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-bottom: 30px;
}

.family-card {
    background: #ffffff;
    border: 4px solid #2d3748;
    border-radius: 20px;
    padding: 30px 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 5px 0 #1a202c, 0 8px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    min-height: 100px;
}

.family-card:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 2px 5px rgba(0, 0, 0, 0.15);
}

.family-card.selected {
    background: #FF7F6A;
    border-color: #C6424A;
    box-shadow: 0 6px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.3);
}

.family-card-check {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #C6424A;
    color: #ffffff;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 900;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.family-card.selected .family-card-check {
    display: flex;
}

.family-card-name {
    font-size: 1.8rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.postie-setup-footer {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.selected-count {
    font-size: 1.6rem;
    font-weight: 900;
    color: #C6424A;
}

.start-route-btn {
    background: #C6424A;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 20px;
    padding: 25px 60px;
    font-size: 1.8rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 2px;
    transition: all 0.3s ease;
    box-shadow: 0 6px 0 #1a202c, 0 12px 25px rgba(0, 0, 0, 0.3);
}

.start-route-btn:active:not(:disabled) {
    transform: translateY(5px);
    box-shadow: 0 1px 0 #1a202c, 0 5px 12px rgba(0, 0, 0, 0.2);
}

.start-route-btn:disabled {
    background: #94a3b8;
    color: rgba(255, 255, 255, 0.5);
    cursor: not-allowed;
    border-color: #64748b;
}

/* Postie Collection Screen */
#postie-collection-screen {
    background: linear-gradient(135deg, #F5A7A1 0%, #FF7F6A 100%);
    padding: 40px;
    align-items: center;
    justify-content: center;
    position: relative;
}

.postie-collection-container {
    background: #FFD1A9;
    border: 4px solid #2d3748;
    border-radius: 25px;
    padding: 40px;
    max-width: 700px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.postie-collection-title {
    font-size: 2.8rem;
    color: #C6424A;
    font-weight: 900;
    text-align: center;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.postie-collection-message {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
    margin-bottom: 30px;
}

.collection-items-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 35px;
}

.collection-item-card {
    background: #ffffff;
    border: 3px solid #C6424A;
    border-radius: 15px;
    padding: 20px 15px;
    font-size: 1.4rem;
    font-weight: 900;
    color: #2d3748;
    text-align: center;
    box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ready-to-go-btn {
    background: #C6424A;
    color: #ffffff;
    border: 4px solid #2d3748;
    border-radius: 20px;
    padding: 25px 50px;
    width: 100%;
    font-size: 2rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 2px;
    transition: all 0.3s ease;
    box-shadow: 0 6px 0 #1a202c, 0 12px 25px rgba(0, 0, 0, 0.3);
}

.ready-to-go-btn:active {
    transform: translateY(5px);
    box-shadow: 0 1px 0 #1a202c, 0 5px 12px rgba(0, 0, 0, 0.2);
}

/* Postie Route Screen */
#postie-route-screen {
    background: linear-gradient(135deg, #FF7F6A 0%, #C6424A 100%);
    padding: 40px;
    align-items: center;
    justify-content: center;
    position: relative;
}

.postie-route-container {
    max-width: 600px;
    width: 90%;
}

.postie-route-header {
    text-align: center;
    margin-bottom: 30px;
}

.postie-route-title {
    font-size: 3rem;
    font-weight: 900;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
    margin-bottom: 15px;
}

.route-progress {
    font-size: 1.6rem;
    font-weight: 900;
    color: #FFD1A9;
}

.postie-route-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.next-delivery-card {
    background: #FFD1A9;
    border: 4px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
    text-align: center;
}

.next-delivery-emoji {
    font-size: 6rem;
    margin-bottom: 15px;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.next-delivery-name {
    font-size: 2.5rem;
    font-weight: 900;
    color: #C6424A;
    margin-bottom: 25px;
    text-transform: uppercase;
}

.next-delivery-items {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 20px;
    box-shadow: 0 3px 0 #1a202c;
}

.items-label {
    font-size: 1.3rem;
    font-weight: 900;
    color: #C6424A;
    margin-bottom: 12px;
    text-transform: uppercase;
}

.next-delivery-items-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.route-item {
    background: #FF7F6A;
    border: 2px solid #C6424A;
    border-radius: 12px;
    padding: 12px;
    font-size: 1.3rem;
    font-weight: 700;
    color: #ffffff;
}

.deliver-now-btn {
    background: #C6424A;
    color: #ffffff;
    border: 5px solid #2d3748;
    border-radius: 25px;
    padding: 30px;
    width: 100%;
    font-size: 2rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 2px;
    transition: all 0.3s ease;
    box-shadow: 0 8px 0 #1a202c, 0 15px 35px rgba(0, 0, 0, 0.4);
}

.deliver-now-btn:active {
    transform: translateY(6px);
    box-shadow: 0 2px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.3);
}

/* Postie Signature Screen */
#postie-signature-screen {
    background: linear-gradient(135deg, #F5A7A1 0%, #FF7F6A 100%);
    padding: 30px;
    align-items: center;
    justify-content: center;
    position: relative;
}

.postie-signature-container {
    background: #FFD1A9;
    border: 4px solid #2d3748;
    border-radius: 25px;
    padding: 40px;
    max-width: 800px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.postie-signature-title {
    font-size: 2.5rem;
    font-weight: 900;
    color: #C6424A;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-align: center;
    margin-bottom: 20px;
}

.postie-delivery-info {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
    margin-bottom: 25px;
}

.postie-signature-canvas {
    width: 100%;
    border: 3px solid #2d3748;
    border-radius: 15px;
    background: #ffffff;
    box-shadow: 0 4px 0 #1a202c, 0 8px 20px rgba(0, 0, 0, 0.2);
    cursor: crosshair;
    margin-bottom: 25px;
}

.postie-signature-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.postie-sig-btn {
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 22px;
    font-size: 1.5rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.postie-sig-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

.postie-sig-btn.clear-btn {
    background: #F48B45;
    color: #ffffff;
}

.postie-sig-btn.confirm-btn {
    background: #C6424A;
    color: #ffffff;
}

/* Postie Delivery Complete Screen */
#postie-complete-screen {
    background: linear-gradient(135deg, #FF7F6A 0%, #C6424A 100%);
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.postie-complete-container {
    text-align: center;
    max-width: 600px;
}

.postie-complete-title {
    font-size: 4rem;
    font-weight: 900;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 3px;
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    margin-bottom: 30px;
}

.postie-complete-message {
    font-size: 2rem;
    font-weight: 900;
    color: #FFD1A9;
    margin-bottom: 40px;
}

.postie-complete-btn {
    background: #FFD1A9;
    border: 5px solid #2d3748;
    border-radius: 25px;
    padding: 30px 60px;
    font-size: 2rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 2px;
    box-shadow: 0 8px 0 #1a202c, 0 15px 35px rgba(0, 0, 0, 0.4);
}

.postie-complete-btn:active {
    transform: translateY(6px);
    box-shadow: 0 2px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.3);
}

/* All Postie Deliveries Done Screen */
#postie-all-done-screen {
    background: linear-gradient(135deg, #FF7F6A 0%, #C6424A 100%);
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.postie-all-done-container {
    text-align: center;
    max-width: 700px;
}

.postie-all-done-title {
    font-size: 4.5rem;
    font-weight: 900;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 4px;
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    margin-bottom: 30px;
}

.postie-all-done-message {
    font-size: 2.2rem;
    font-weight: 900;
    color: #FFD1A9;
    margin-bottom: 50px;
}

.postie-all-done-btn {
    background: #30598a;
    border: 5px solid #2d3748;
    border-radius: 25px;
    padding: 35px 70px;
    font-size: 2rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 2px;
    box-shadow: 0 8px 0 #1a202c, 0 15px 35px rgba(0, 0, 0, 0.4);
}

.postie-all-done-btn:active {
    transform: translateY(6px);
    box-shadow: 0 2px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.3);
}

/* ===== CAFE GAME (TERRACOTTA THEME) ===== */

/* Cafe Game - Split Layout (like till game) */
#cafe-game-screen.active {
    background: transparent;
    display: flex;
    height: 100svh;
    height: 100dvh;
    height: 100vh;
    padding: 0;
    min-height: 0;
}

.cafe-split-container {
    display: flex;
    width: 100%;
    height: 100%;
    max-width: 2000px;
    margin: 0 auto;
    position: relative;
}

/* Cafe Left Panel - Order List */
.cafe-left-panel {
    order: 2;
    flex: 0 0 50%;
    display: flex;
    flex-direction: column;
    background: var(--cafe-left-bg);
    border-left: 3px solid #2d3748;
    overflow: hidden;
    height: 100%;
    max-height: 100svh;
}

.cafe-panel-header { display: none; }

.cafe-order-items {
    flex: 1;
    overflow-y: auto;
    padding: 20px 20px 20px 20px;
    padding-bottom: 140px;
}

.cafe-order-items::-webkit-scrollbar {
    width: 12px;
}

.cafe-order-items::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
}

.cafe-order-items::-webkit-scrollbar-thumb {
    background: #94a3b8;
    border-radius: 10px;
}

.empty-order {
    text-align: center;
    color: #000000;
    font-size: 2.5rem;
    padding: 100px 30px;
    font-weight: 900;
    letter-spacing: 1px;
}

.cafe-order-item {
    background: #ffffff;
    border: none;
    border-left: 6px solid var(--cafe-right-bg);
    border-radius: 18px;
    padding: 22px 28px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 12px rgba(200, 124, 90, 0.2), 0 2px 4px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    transition: all 0.2s ease;
}

.cafe-order-item:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 16px rgba(48, 89, 138, 0.3), 0 3px 6px rgba(0, 0, 0, 0.1);
}

.cafe-order-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.cafe-order-emoji {
    font-size: 3.5rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.cafe-order-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    letter-spacing: 0.5px;
}

.cafe-order-price {
    font-size: 2rem;
    color: #ffffff;
    font-weight: 800;
    background: var(--cafe-accent);
    padding: 10px 22px;
    border-radius: 14px;
    border: 2px solid #2d3748;
    box-shadow: 0 2px 8px rgba(200, 124, 90, 0.3);
}

/* Cafe Right Panel - Menu & Payment */
.cafe-right-panel {
    order: 1;
    flex: 0 0 50%;
    display: flex;
    flex-direction: column;
    background: var(--cafe-right-bg);
    overflow: hidden;
    height: 100%;
    max-height: 100svh;
}

.cafe-menu-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 20px;
    overflow-y: auto;
}

.cafe-menu-header {
    position: sticky;
    top: 0;
    background: var(--cafe-right-bg);
    z-index: 2;
    margin: -20px -20px 12px -20px; /* pull up to flush with top (counter parent padding) */
    padding: 10px 20px;
    border-bottom: 3px solid #2d3748;
    margin-top: 0; /* ensure no extra top gap */
}

.cafe-menu-header .mode-toggle-buttons { margin: 0; }

.cafe-menu-title {
    font-size: 2rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    margin-bottom: 15px;
    text-align: center;
}

.cafe-menu-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    flex: 1;
}

.cafe-menu-card {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 15px;
    padding: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
    min-height: 110px;
    justify-content: center;
}

.cafe-menu-card:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #1a202c, 0 2px 5px rgba(0, 0, 0, 0.15);
}

.cafe-menu-emoji {
    font-size: 3rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.cafe-menu-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
}

.cafe-menu-price {
    font-size: 1.3rem;
    font-weight: 900;
    color: #9daffa;
}

/* Cafe Payment Section */
.cafe-payment-section {
    background: var(--cafe-right-bg);
    border-top: 3px solid #2d3748;
    padding: 20px;
    flex-shrink: 0;
    position: sticky;
    bottom: 0;
    z-index: 2;
}

.cafe-total-display {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 18px 25px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 3px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.15);
}

.cafe-total-label {
    font-size: 1.5rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.cafe-total-amount {
    font-size: 2rem;
    font-weight: 900;
    color: #C87C5A;
}

.cafe-payment-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.cafe-pay-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 20px;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cafe-pay-btn:active:not(:disabled) {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.cafe-pay-btn.cash-btn { background: #9DAFFA; color: #2d3748; }

.cafe-pay-btn.card-btn { background: var(--cafe-key-action); color: #2d3748; }

.cafe-pay-btn:disabled {
    background: #94a3b8;
    color: rgba(255, 255, 255, 0.5);
    cursor: not-allowed;
    border-color: #64748b;
    box-shadow: 0 5px 0 #475569, 0 8px 18px rgba(0, 0, 0, 0.15);
}

/* Smoothie Bar Size Selection Popup */
.smoothie-bar-size-popup {
    background: #E2F0C2;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.smoothie-bar-size-title {
    font-size: 2.2rem;
    color: #A3A84C;
    font-weight: 900;
    text-align: center;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.smoothie-bar-size-item {
    font-size: 5rem;
    text-align: center;
    margin-bottom: 15px;
    filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.2));
}

.smoothie-bar-size-name {
    font-size: 1.5rem;
    font-weight: 900;
    color: #2d3748;
    text-align: center;
    margin-bottom: 25px;
}

.smoothie-bar-size-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 25px;
}

.smoothie-bar-size-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 25px 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 120px;
    justify-content: center;
}

.smoothie-bar-size-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.smoothie-bar-size-label {
    font-size: 1.4rem;
    font-weight: 900;
    color: #2d3748;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    text-transform: uppercase;
}

.smoothie-bar-size-price {
    font-size: 1.8rem;
    font-weight: 900;
    color: #A3A84C;
    font-family: 'Hello Headline W00 Regular', sans-serif;
}

.smoothie-bar-size-cancel {
    background: #F48B45;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 18px;
    width: 100%;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.smoothie-bar-size-cancel:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Smoothie Recipe Popup */
.recipe-popup {
    background: #E2F0C2;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
    text-align: center;
}

.recipe-popup-title {
    font-size: 2.2rem;
    color: #A3A84C;
    font-weight: 900;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.recipe-popup-emoji {
    font-size: 5rem;
    margin-bottom: 15px;
    filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.2));
}

.recipe-popup-name {
    font-size: 1.6rem;
    font-weight: 900;
    color: #2d3748;
    margin-bottom: 25px;
}

.recipe-popup-ingredients {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
    text-align: left;
}

.recipe-popup-subtitle {
    font-size: 1.4rem;
    font-weight: 900;
    color: #30598a;
    margin-bottom: 15px;
    text-transform: uppercase;
}

.recipe-popup-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.recipe-popup-item {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2d3748;
    padding: 10px 15px;
    background: #CDEBB0;
    border-radius: 12px;
}

.recipe-popup-close {
    background: #8EBE92;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 18px 40px;
    width: 100%;
    font-size: 1.5rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.recipe-popup-close:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Drink Size Selection Popup (Cafe) */
.drink-size-popup {
    background: var(--cafe-left-bg);
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.drink-size-title {
    font-size: 2.2rem;
    color: #2d3748;
    font-weight: 900;
    text-align: center;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.drink-size-item {
    font-size: 5rem;
    text-align: center;
    margin-bottom: 25px;
    filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.2));
}

.size-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 25px;
}

.size-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 25px 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 150px;
    justify-content: center;
}

.size-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.size-emoji {
    font-size: 2.5rem;
}

.size-name {
    font-size: 1.4rem;
    font-weight: 900;
    color: #2d3748;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    text-transform: uppercase;
}

.size-price {
    font-size: 1.6rem;
    font-weight: 900;
    color: #C87C5A;
    font-family: 'Hello Headline W00 Regular', sans-serif;
}

.drink-size-cancel {
    background: #6C87F8;
    color: #2d3748;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 18px;
    width: 100%;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.drink-size-cancel:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* ===== SMOOTHIE BAR GAME ===== */

/* Smoothie Bar - Split Layout (like Cafe) */
#smoothie-bar-screen.active {
    background: transparent;
    display: flex;
    height: 100vh;
    padding: 0;
    min-height: 800px;
}

.smoothie-bar-split-container {
    display: flex;
    width: 100%;
    height: 100%;
    max-width: 2000px;
    margin: 0 auto;
}

/* Smoothie Bar Left Panel */
.smoothie-bar-left-panel {
    flex: 2;
    display: flex;
    flex-direction: column;
    background: #e4dcbd;
    border-right: 3px solid #30598a;
    overflow: hidden;
}

.smoothie-bar-panel-header {
    background: #e4dcbd;
    padding: 20px;
    text-align: center;
    flex-shrink: 0;
}

.smoothie-bar-home-btn {
    background: #e27a37;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 15px 25px;
    font-size: 1.3rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
}

.smoothie-bar-home-btn:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #1a202c, 0 2px 5px rgba(0, 0, 0, 0.15);
}

/* ===== SMOOTHIE BAR GAME (GREEN/MINT THEME) ===== */

/* Smoothie Bar - Split Layout (like Cafe) */
#smoothie-bar-screen.active {
    background: transparent;
    display: flex;
    height: 100vh;
    padding: 0;
    min-height: 800px;
}

.smoothie-bar-split-container {
    display: flex;
    width: 100%;
    height: 100%;
    max-width: 2000px;
    margin: 0 auto;
}

/* Smoothie Bar Left Panel - Order List */
.smoothie-bar-left-panel {
    flex: 2;
    display: flex;
    flex-direction: column;
    background: #E2F0C2;
    border-right: 3px solid #2d3748;
    overflow: hidden;
}

.smoothie-bar-panel-header {
    background: #E2F0C2;
    padding: 0;
    text-align: center;
    flex-shrink: 0;
    min-height: 0;
}

.smoothie-bar-order-items {
    flex: 1;
    overflow-y: auto;
    padding: 0 20px 20px 20px;
}

.smoothie-bar-order-items::-webkit-scrollbar {
    width: 12px;
}

.smoothie-bar-order-items::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
}

.smoothie-bar-order-items::-webkit-scrollbar-thumb {
    background: #94a3b8;
    border-radius: 10px;
}

.smoothie-bar-order-item {
    background: #ffffff;
    border: none;
    border-left: 6px solid #8EBE92;
    border-radius: 18px;
    padding: 22px 28px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 12px rgba(142, 190, 146, 0.2), 0 2px 4px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    transition: all 0.2s ease;
}

.smoothie-bar-order-item:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 16px rgba(48, 89, 138, 0.3), 0 3px 6px rgba(0, 0, 0, 0.1);
}

.smoothie-bar-order-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.smoothie-bar-order-emoji {
    font-size: 3.5rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.smoothie-bar-order-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    letter-spacing: 0.5px;
}

.smoothie-bar-order-price {
    font-size: 2rem;
    color: #ffffff;
    font-weight: 800;
    background: #A3A84C;
    padding: 10px 22px;
    border-radius: 14px;
    border: 2px solid #2d3748;
    box-shadow: 0 2px 8px rgba(163, 168, 76, 0.3);
}

/* Smoothie Bar Right Panel */
.smoothie-bar-right-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #8EBE92;
    max-height: 100vh;
    overflow: hidden;
    width: 450px;
    min-width: 400px;
}

.smoothie-bar-menu-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 20px;
    overflow-y: auto;
}

.smoothie-bar-menu-title {
    font-size: 2rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    margin-bottom: 15px;
    text-align: center;
}

.smoothie-bar-menu-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    flex: 1;
}

.smoothie-bar-menu-card {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 15px;
    padding: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
    min-height: 110px;
    justify-content: center;
}

.smoothie-bar-menu-card:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #1a202c, 0 2px 5px rgba(0, 0, 0, 0.15);
}

.smoothie-bar-menu-emoji {
    font-size: 3rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.smoothie-bar-menu-name {
    font-size: 1rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
}

/* Smoothie Bar Payment Section */
.smoothie-bar-payment-section {
    background: #f1b873;
    border-top: 3px solid #2d3748;
    padding: 20px;
    flex-shrink: 0;
}

.smoothie-bar-total-display {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 18px 25px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 3px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.15);
}

.smoothie-bar-total-label {
    font-size: 1.5rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.smoothie-bar-total-amount {
    font-size: 2rem;
    font-weight: 900;
    color: #30598a;
}

.smoothie-bar-payment-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.smoothie-bar-pay-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 20px;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.smoothie-bar-pay-btn:active:not(:disabled) {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.smoothie-bar-pay-btn.cash-btn {
    background: #F48B45;
    color: #ffffff;
}

.smoothie-bar-pay-btn.card-btn {
    background: #CDEBB0;
    color: #2d3748;
}

.smoothie-bar-pay-btn:disabled {
    background: #94a3b8;
    color: rgba(255, 255, 255, 0.5);
    cursor: not-allowed;
    border-color: #64748b;
    box-shadow: 0 5px 0 #475569, 0 8px 18px rgba(0, 0, 0, 0.15);
}

/* Smoothie Size Selection Popup */
.smoothie-size-popup {
    background: #e4dcbd;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.smoothie-size-title {
    font-size: 2.2rem;
    color: #30598a;
    font-weight: 900;
    text-align: center;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.smoothie-size-display {
    font-size: 5rem;
    text-align: center;
    margin-bottom: 25px;
    filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.2));
}

.smoothie-size-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 25px;
}

.smoothie-size-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 25px 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 120px;
    justify-content: center;
}

.smoothie-size-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.smoothie-size-label {
    font-size: 1.4rem;
    font-weight: 900;
    color: #2d3748;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    text-transform: uppercase;
}

.smoothie-size-price {
    font-size: 1.8rem;
    font-weight: 900;
    color: #30598a;
    font-family: 'Hello Headline W00 Regular', sans-serif;
}

.smoothie-size-cancel {
    background: #e27a37;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 18px;
    width: 100%;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.smoothie-size-cancel:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Smoothie Complete Popup */
.smoothie-complete-popup {
    background: #e4dcbd;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
    text-align: center;
}

.smoothie-complete-title {
    font-size: 2.5rem;
    color: #30598a;
    font-weight: 900;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.smoothie-complete-display {
    font-size: 6rem;
    margin-bottom: 20px;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.smoothie-complete-details {
    margin-bottom: 30px;
}

.smoothie-detail-name {
    font-size: 1.6rem;
    font-weight: 900;
    color: #2d3748;
    margin-bottom: 10px;
}

.smoothie-detail-price {
    font-size: 2rem;
    font-weight: 900;
    color: #30598a;
}

.smoothie-complete-btn {
    background: #30598a;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 20px 40px;
    width: 100%;
    font-size: 1.5rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    box-shadow: 0 6px 0 #1a202c, 0 12px 25px rgba(0, 0, 0, 0.3);
}

.smoothie-complete-btn:active {
    transform: translateY(5px);
    box-shadow: 0 1px 0 #1a202c, 0 5px 12px rgba(0, 0, 0, 0.2);
}

/* Smoothie Payment Screen */
#smoothie-payment-screen {
    background: linear-gradient(135deg, #72bfed 0%, #30598a 100%);
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.smoothie-payment-container {
    max-width: 700px;
    width: 90%;
}

.smoothie-order-summary {
    background: #e4dcbd;
    border: 4px solid #2d3748;
    border-radius: 25px;
    padding: 40px;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.summary-title {
    font-size: 2.5rem;
    color: #30598a;
    font-weight: 900;
    text-align: center;
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.order-summary-items {
    margin-bottom: 25px;
}

.summary-item {
    background: #ffffff;
    border: 2px solid #30598a;
    border-radius: 15px;
    padding: 18px 22px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1);
}

.summary-item-emoji {
    font-size: 2.5rem;
}

.summary-item-name {
    flex: 1;
    font-size: 1.2rem;
    font-weight: 700;
    color: #2d3748;
}

.summary-item-price {
    font-size: 1.5rem;
    font-weight: 900;
    color: #30598a;
}

.summary-total {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 20px 25px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 0 #1a202c, 0 8px 15px rgba(0, 0, 0, 0.2);
}

.summary-total-label {
    font-size: 1.8rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
}

.summary-total-amount {
    font-size: 2.5rem;
    font-weight: 900;
    color: #30598a;
}

.summary-payment-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.summary-pay-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 18px;
    padding: 25px;
    font-size: 1.5rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 90px;
}

.summary-pay-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.summary-pay-btn.cash-btn {
    background: #f1b873;
}

.summary-pay-btn.card-btn {
    background: #72bfed;
}

/* Large Screens - Extra sizing for very large displays */
@media (min-width: 1600px) {
    .cart-item {
        padding: 25px 32px;
        margin-bottom: 18px;
    }
    
    .cart-item-emoji {
        font-size: 4rem;
    }
    
    .cart-item-name {
        font-size: 1.6rem;
    }
    
    .cart-item-price {
        font-size: 2.2rem;
        padding: 12px 26px;
    }
    
    .barcode-display {
        font-size: 2.3rem;
        padding: 25px;
        min-height: 75px;
    }
    
    .key-btn {
        font-size: 3rem;
        min-height: 85px;
    }
    
    .key-btn.clear-btn,
    .key-btn.enter-btn {
        font-size: 1.5rem;
    }
    
    .scanner-total-label {
        font-size: 1.8rem;
    }
    
    .scanner-total-amount {
        font-size: 2.3rem;
    }
    
    .scanner-pay-btn {
        font-size: 1.6rem;
        min-height: 90px;
    }
    
    .catalogue-total-label {
        font-size: 1.8rem;
    }
    
    .catalogue-total-amount {
        font-size: 2.3rem;
    }
    
    .catalogue-pay-btn {
        font-size: 1.6rem;
        min-height: 90px;
    }
}

/* Responsive - Mobile */
@media (max-width: 900px) {
    /* Global Home Button Mobile */
    .game-home-btn {
        padding: 15px 22px;
        font-size: 1.1rem;
        gap: 5px;
        margin: 15px;
    }
    
    #postie-setup-screen .game-home-btn,
    #postie-collection-screen .game-home-btn,
    #postie-route-screen .game-home-btn,
    #postie-signature-screen .game-home-btn {
        margin: 15px 15px 8px 15px;
    }
    
    .cafe-left-panel .game-home-btn,
    .smoothie-bar-left-panel .game-home-btn {
        margin: 15px 15px 8px 15px;
    }
    
    .cafe-order-items,
    .smoothie-bar-order-items {
        padding: 0 15px 15px 15px;
    }
    
    .home-title {
        font-size: 3.5rem;
        letter-spacing: 2px;
    }
    
    .home-container {
        gap: 30px;
    }
    
    .game-buttons {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .start-game-btn {
        padding: 35px 20px;
        font-size: 1.4rem;
        letter-spacing: 2px;
        gap: 12px;
        min-height: 160px;
    }
    
    /* Supermarket Mobile - Smaller Keypad */
    .right-panel {
        width: 100%;
        min-width: 100%;
    }
    
    .mode-toggle-btn {
        padding: 12px 8px;
        font-size: 1rem;
        min-height: 50px;
    }
    
    .barcode-display {
        padding: 15px;
        margin: 12px;
        font-size: 2rem;
    }
    
    .keypad {
        gap: 8px;
        padding: 12px;
    }
    
    .key-btn {
        padding: 12px;
        font-size: 1.4rem;
        min-height: 55px;
    }
    
    .scanner-payment-section {
        padding: 12px;
    }
    
    .scanner-total-display {
        padding: 12px 18px;
    }
    
    .scanner-total-label {
        font-size: 1rem;
    }
    
    .scanner-total-amount {
        font-size: 1.4rem;
    }
    
    .scanner-pay-btn {
        padding: 15px;
        font-size: 1.1rem;
        min-height: 60px;
    }
    
    .product-grid {
        gap: 10px;
        padding: 12px;
    }
    
    .product-card {
        padding: 15px;
    }
    
    .product-emoji {
        font-size: 2.5rem;
    }
    
    .product-name {
        font-size: 1rem;
    }
    
    .product-price {
        font-size: 1.2rem;
        padding: 6px 12px;
    }
    
    .catalogue-payment-section {
        padding: 12px;
    }
    
    .catalogue-total-display {
        padding: 12px 18px;
    }
    
    .catalogue-total-label {
        font-size: 1rem;
    }
    
    .catalogue-total-amount {
        font-size: 1.4rem;
    }
    
    .catalogue-pay-btn {
        padding: 15px;
        font-size: 1.1rem;
        min-height: 60px;
    }
    
    /* Postie Game Mobile */
    
    .postie-setup-title {
        font-size: 2rem;
    }
    
    .postie-setup-content {
        padding: 25px;
    }
    
    .postie-setup-instruction {
        font-size: 1.3rem;
    }
    
    .family-selection-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .family-card {
        padding: 25px 15px;
        min-height: 80px;
    }
    
    .family-card-name {
        font-size: 1.3rem;
    }
    
    .family-card-check {
        width: 28px;
        height: 28px;
        font-size: 1.1rem;
    }
    
    .selected-count {
        font-size: 1.4rem;
    }
    
    .start-route-btn {
        padding: 20px 40px;
        font-size: 1.5rem;
    }
    
    .postie-collection-container {
        padding: 30px;
    }
    
    .postie-collection-title {
        font-size: 2.2rem;
    }
    
    .postie-collection-message {
        font-size: 1.3rem;
    }
    
    .collection-items-list {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .collection-item-card {
        font-size: 1.2rem;
        padding: 18px 12px;
        min-height: 70px;
    }
    
    .ready-to-go-btn {
        padding: 20px 40px;
        font-size: 1.6rem;
    }
    
    .postie-route-title {
        font-size: 2.2rem;
    }
    
    .route-progress {
        font-size: 1.3rem;
    }
    
    .next-delivery-card {
        padding: 25px;
    }
    
    .next-delivery-emoji {
        font-size: 4.5rem;
    }
    
    .next-delivery-name {
        font-size: 2rem;
        margin-bottom: 20px;
    }
    
    .items-label {
        font-size: 1.1rem;
    }
    
    .route-item {
        font-size: 1.1rem;
        padding: 10px;
    }
    
    .deliver-now-btn {
        padding: 22px;
        font-size: 1.6rem;
    }
    
    .postie-signature-container {
        padding: 25px;
    }
    
    .postie-signature-title {
        font-size: 1.8rem;
    }
    
    .postie-delivery-info {
        font-size: 1.2rem;
    }
    
    .postie-sig-btn {
        padding: 18px;
        font-size: 1.3rem;
    }
    
    .postie-complete-title {
        font-size: 2.5rem;
    }
    
    .postie-complete-message {
        font-size: 1.5rem;
    }
    
    .postie-complete-btn {
        padding: 25px 40px;
        font-size: 1.5rem;
    }
    
    .postie-all-done-title {
        font-size: 3rem;
    }
    
    .postie-all-done-message {
        font-size: 1.6rem;
    }
    
    .postie-all-done-btn {
        padding: 25px 45px;
        font-size: 1.5rem;
    }
    
    /* Cafe Game Mobile */
    #cafe-game-screen.active {
        min-height: 600px;
    }
    
    .cafe-split-container {
        flex-direction: column;
    }
    
    .cafe-left-panel {
        flex: 1;
        border-right: none;
        border-bottom: 3px solid #30598a;
    }
    
    .cafe-right-panel {
        flex: 1;
        width: 100%;
        min-width: 100%;
        max-width: 100%;
    }
    
    .cafe-panel-header {
        padding: 15px;
    }
    
    .cafe-home-btn {
        padding: 12px 20px;
        font-size: 1.1rem;
    }
    
    .empty-order {
        font-size: 1.8rem;
        padding: 50px 20px;
    }
    
    .cafe-order-item {
        padding: 15px 18px;
    }
    
    .cafe-order-emoji {
        font-size: 2.5rem;
    }
    
    .cafe-order-name {
        font-size: 1rem;
    }
    
    .cafe-order-price {
        font-size: 1.4rem;
        padding: 6px 14px;
    }
    
    .cafe-menu-section {
        padding: 15px;
    }
    
    .cafe-menu-title {
        font-size: 1.6rem;
    }
    
    .cafe-menu-card {
        padding: 15px;
        min-height: 95px;
    }
    
    .cafe-menu-emoji {
        font-size: 2.5rem;
    }
    
    .cafe-menu-name {
        font-size: 1rem;
    }
    
    .cafe-menu-price {
        font-size: 1.2rem;
    }
    
    .cafe-payment-section {
        padding: 15px;
    }
    
    .cafe-total-display {
        padding: 15px 20px;
    }
    
    .cafe-total-label {
        font-size: 1.2rem;
    }
    
    .cafe-total-amount {
        font-size: 1.6rem;
    }
    
    .cafe-pay-btn {
        padding: 15px;
        font-size: 1.1rem;
        min-height: 65px;
    }
    
    .drink-size-popup {
        padding: 25px;
    }
    
    .drink-size-title {
        font-size: 1.8rem;
    }
    
    .drink-size-item {
        font-size: 4rem;
    }
    
    .size-buttons {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .size-btn {
        padding: 20px;
        min-height: 120px;
    }
    
    .size-emoji {
        font-size: 2rem;
    }
    
    .size-name {
        font-size: 1.2rem;
    }
    
    .size-price {
        font-size: 1.4rem;
    }
    
    .drink-size-cancel {
        padding: 15px;
        font-size: 1.2rem;
    }
    
    /* Smoothie Bar Game Mobile */
    #smoothie-bar-screen.active {
        min-height: 600px;
    }
    
    .smoothie-bar-split-container {
        flex-direction: column;
    }
    
    .smoothie-bar-left-panel {
        flex: 1;
        border-right: none;
        border-bottom: 3px solid #30598a;
    }
    
    .smoothie-bar-right-panel {
        flex: 1;
        width: 100%;
        min-width: 100%;
        max-width: 100%;
    }
    
    .smoothie-bar-home-btn {
        padding: 12px 20px;
        font-size: 1.1rem;
    }
    
    .smoothie-bar-order-item {
        padding: 15px 18px;
    }
    
    .smoothie-bar-order-emoji {
        font-size: 2.5rem;
    }
    
    .smoothie-bar-order-name {
        font-size: 1rem;
    }
    
    .smoothie-bar-order-price {
        font-size: 1.4rem;
        padding: 6px 14px;
    }
    
    .smoothie-bar-menu-section {
        padding: 15px;
    }
    
    .smoothie-bar-menu-title {
        font-size: 1.6rem;
    }
    
    .smoothie-bar-menu-card {
        padding: 15px;
        min-height: 95px;
    }
    
    .smoothie-bar-menu-emoji {
        font-size: 2.5rem;
    }
    
    .smoothie-bar-menu-name {
        font-size: 0.9rem;
    }
    
    .smoothie-bar-payment-section {
        padding: 15px;
    }
    
    .smoothie-bar-total-display {
        padding: 15px 20px;
    }
    
    .smoothie-bar-total-label {
        font-size: 1.2rem;
    }
    
    .smoothie-bar-total-amount {
        font-size: 1.6rem;
    }
    
    .smoothie-bar-pay-btn {
        padding: 15px;
        font-size: 1.1rem;
        min-height: 65px;
    }
    
    .smoothie-bar-size-popup {
        padding: 25px;
    }
    
    .smoothie-bar-size-title {
        font-size: 1.8rem;
    }
    
    .smoothie-bar-size-item {
        font-size: 4rem;
    }
    
    .smoothie-bar-size-name {
        font-size: 1.3rem;
    }
    
    .smoothie-bar-size-buttons {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .smoothie-bar-size-btn {
        padding: 20px;
        min-height: 100px;
    }
    
    .smoothie-bar-size-label {
        font-size: 1.2rem;
    }
    
    .smoothie-bar-size-price {
        font-size: 1.5rem;
    }
    
    .recipe-popup {
        padding: 25px;
    }
    
    .recipe-popup-title {
        font-size: 1.8rem;
    }
    
    .recipe-popup-emoji {
        font-size: 4rem;
    }
    
    .recipe-popup-name {
        font-size: 1.3rem;
    }
    
    .recipe-popup-ingredients {
        padding: 20px;
    }
    
    .recipe-popup-subtitle {
        font-size: 1.2rem;
    }
    
    .recipe-popup-item {
        font-size: 1.1rem;
        padding: 8px 12px;
    }
    
    .recipe-popup-close {
        padding: 15px;
        font-size: 1.3rem;
    }
    
    #scanning-screen.active {
        min-height: 600px;
    }
    
    .split-container {
        flex-direction: column;
    }
    
    .left-panel {
        flex: 1;
        border-right: none;
        border-bottom: 3px solid #30598a;
    }
    
    .right-panel {
        flex: 1;
        width: 100%;
        min-width: 100%;
        max-width: 100%;
    }
    
    .panel-header {
        padding: 15px;
    }
    
    .top-nav-buttons {
        gap: 10px;
    }
    
    .nav-btn {
        font-size: 1rem;
        padding: 15px 10px;
        min-height: 60px;
        letter-spacing: 0.5px;
    }
    
    .cart-item {
        padding: 15px 18px;
    }
    
    .cart-item-emoji {
        font-size: 2.5rem;
    }
    
    .cart-item-name {
        font-size: 1rem;
    }
    
    .cart-item-price {
        font-size: 1.4rem;
        padding: 6px 14px;
    }
    
    .empty-cart {
        font-size: 1.8rem;
        padding: 50px 20px;
    }
    
    .summary-total-box {
        padding: 25px 20px;
    }
    
    .summary-total-label {
        font-size: 1.5rem;
    }
    
    .summary-total-amount {
        font-size: 2.5rem;
    }
    
    .summary-payment-btn {
        padding: 35px 20px;
    }
    
    .payment-emoji {
        font-size: 4rem;
    }
    
    .payment-label {
        font-size: 1.6rem;
    }
    
    .back-to-scan-btn {
        font-size: 1.5rem;
        padding: 20px;
    }
    
    .cash-popup {
        padding: 20px;
        max-width: 350px;
    }
    
    .cash-title {
        font-size: 1.6rem;
    }
    
    .money-btn {
        padding: 15px;
        min-height: 65px;
        font-size: 1.6rem;
    }
    
    .cash-cancel-btn {
        padding: 15px;
        font-size: 1.2rem;
    }
    
    .change-popup {
        padding: 35px;
    }
    
    .change-title {
        font-size: 1.8rem;
    }
    
    .change-amount-display {
        font-size: 4.5rem;
    }
    
    .change-message {
        font-size: 1.6rem;
    }
    
    .add-product-popup {
        padding: 25px;
        max-width: 400px;
    }
    
    .add-product-title {
        font-size: 1.8rem;
    }
    
    .add-product-barcode-display {
        font-size: 1.1rem;
        padding: 12px 15px;
    }
    
    .add-product-barcode-display span {
        font-size: 1.3rem;
    }
    
    .form-label {
        font-size: 1rem;
    }
    
    .form-input {
        padding: 12px;
        font-size: 1.1rem;
    }
    
    .add-product-btn {
        padding: 15px;
        font-size: 1.2rem;
    }
    
    .barcode-choice-popup {
        padding: 25px;
        max-width: 95%;
    }
    
    .barcode-choice-title {
        font-size: 1.6rem;
        margin-bottom: 10px;
    }
    
    .barcode-choice-message {
        font-size: 1.1rem;
        margin-bottom: 20px;
    }
    
    .barcode-choice-buttons {
        gap: 15px;
        margin-bottom: 20px;
    }
    
    .barcode-choice-btn {
        padding: 25px 15px;
        font-size: 1.1rem;
        min-height: 120px;
    }
    
    .barcode-choice-cancel-btn {
        font-size: 1.2rem;
        padding: 15px;
    }
    
    .select-product-popup {
        padding: 20px;
        max-width: 95%;
    }
    
    .select-product-title {
        font-size: 1.6rem;
        margin-bottom: 10px;
    }
    
    .select-product-message {
        font-size: 1.1rem;
        margin-bottom: 20px;
    }
    
    .select-product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        margin-bottom: 20px;
    }
    
    .select-product-card {
        padding: 15px;
        min-height: 120px;
    }
    
    .select-product-card-emoji {
        font-size: 2.5rem;
    }
    
    .select-product-card-name {
        font-size: 0.9rem;
    }
    
    .select-product-card-price {
        font-size: 1.2rem;
        padding: 5px 14px;
    }
    
    .select-product-cancel-btn {
        font-size: 1.2rem;
        padding: 15px;
    }
    
    .edit-item-popup {
        padding: 25px;
        max-width: 400px;
    }
    
    .edit-item-title {
        font-size: 1.8rem;
    }
    
    .edit-item-btn {
        padding: 14px 10px;
        font-size: 1.1rem;
    }
    
    
    .scanner-keypad-section {
        padding: 15px;
    }
    
    .barcode-display {
        font-size: 1.6rem;
        padding: 15px;
        min-height: 55px;
        margin-bottom: 15px;
    }
    
    .keypad {
        gap: 10px;
    }
    
    .key-btn {
        font-size: 2rem;
        min-height: 60px;
    }
    
    .key-btn.clear-btn,
    .key-btn.enter-btn {
        font-size: 1.1rem;
    }
    
    .scanner-payment-section {
        padding: 15px;
    }
    
    .scanner-total-display {
        padding: 15px 20px;
        margin-bottom: 12px;
    }
    
    .scanner-total-label {
        font-size: 1.2rem;
    }
    
    .scanner-total-amount {
        font-size: 1.6rem;
    }
    
    .scanner-payment-buttons {
        gap: 12px;
    }
    
    .scanner-pay-btn {
        padding: 15px;
        font-size: 1.1rem;
        min-height: 65px;
    }
    
    .product-grid {
        padding: 15px;
        gap: 12px;
    }
    
    .product-card {
        padding: 15px;
        min-height: 120px;
    }
    
    .product-card-emoji {
        font-size: 2.5rem;
    }
    
    .product-card-name {
        font-size: 0.9rem;
    }
    
    .product-card-price {
        font-size: 1.3rem;
        padding: 6px 14px;
    }
    
    .catalogue-payment-section {
        padding: 15px;
    }
    
    .catalogue-total-display {
        padding: 15px 20px;
        margin-bottom: 12px;
    }
    
    .catalogue-total-label {
        font-size: 1.2rem;
    }
    
    .catalogue-total-amount {
        font-size: 1.6rem;
    }
    
    .catalogue-payment-buttons {
        gap: 12px;
    }
    
    .catalogue-pay-btn {
        padding: 15px;
        font-size: 1.1rem;
        min-height: 65px;
    }
}

/* ===== EMOJI PICKER ===== */
.emoji-picker-popup {
    background: #ffffff;
    border: 4px solid #2d3748;
    border-radius: 20px;
    padding: 30px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.emoji-picker-title {
    font-size: 2rem;
    font-weight: 900;
    color: #2d3748;
    text-align: center;
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.emoji-picker-grid {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 12px;
    margin-bottom: 25px;
    max-height: 400px;
    overflow-y: auto;
}

.emoji-picker-item {
    background: #f7fafc;
    border: 3px solid #2d3748;
    border-radius: 12px;
    padding: 15px;
    font-size: 1.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 3px 0 #1a202c, 0 4px 8px rgba(0, 0, 0, 0.15);
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.emoji-picker-item:hover {
    background: #e2e8f0;
    transform: translateY(-2px);
    box-shadow: 0 5px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
}

.emoji-picker-item:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 #1a202c, 0 2px 4px rgba(0, 0, 0, 0.15);
}

.emoji-picker-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.emoji-picker-btn {
    background: #F48B45;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 12px;
    padding: 12px 24px;
    font-size: 1.1rem;
    font-weight: 700;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
}

.emoji-picker-btn:hover {
    background: #e67e22;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #1a202c, 0 8px 16px rgba(0, 0, 0, 0.25);
}

        .emoji-picker-btn:active {
            transform: translateY(3px);
            box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
        }

        /* ===== MANAGEMENT MODAL ===== */
        .management-popup {
            background: #ffffff;
            border: 4px solid #2d3748;
            border-radius: 20px;
            padding: 30px;
            max-width: 800px;
            width: 90%;
            max-height: 80vh;
            overflow-y: auto;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
        }

        .management-title {
            font-size: 2rem;
            font-weight: 900;
            color: #2d3748;
            text-align: center;
            margin-bottom: 25px;
            text-transform: uppercase;
            letter-spacing: 1px;
        }

        .management-tabs {
            display: flex;
            gap: 10px;
            margin-bottom: 25px;
            border-bottom: 2px solid #e2e8f0;
        }

        .management-tab {
            background: #f7fafc;
            border: 3px solid #2d3748;
            border-radius: 12px 12px 0 0;
            padding: 12px 24px;
            font-size: 1.1rem;
            font-weight: 700;
            font-family: 'Hello Headline W00 Regular', sans-serif;
            cursor: pointer;
            transition: all 0.2s ease;
            text-transform: uppercase;
            letter-spacing: 1px;
            box-shadow: 0 3px 0 #1a202c, 0 4px 8px rgba(0, 0, 0, 0.15);
        }

        .management-tab:hover {
            background: #e2e8f0;
            transform: translateY(-2px);
            box-shadow: 0 5px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
        }

        .management-tab.active {
            background: #F48B45;
            color: #ffffff;
            transform: translateY(-2px);
            box-shadow: 0 5px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
        }

        .management-tab:active {
            transform: translateY(2px);
            box-shadow: 0 1px 0 #1a202c, 0 2px 4px rgba(0, 0, 0, 0.15);
        }

        .management-content {
            margin-bottom: 25px;
        }

        .management-section {
            display: none;
        }

        .management-section.active {
            display: block;
        }

        .management-section-title {
            font-size: 1.5rem;
            font-weight: 700;
            color: #2d3748;
            margin-bottom: 20px;
            text-transform: uppercase;
            letter-spacing: 1px;
        }

        .management-list {
            max-height: 400px;
            overflow-y: auto;
            border: 2px solid #e2e8f0;
            border-radius: 12px;
            padding: 15px;
        }

        .management-item {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 15px;
            margin-bottom: 10px;
            background: #f7fafc;
            border: 2px solid #e2e8f0;
            border-radius: 12px;
            transition: all 0.2s ease;
        }

        .management-item:hover {
            background: #e2e8f0;
            border-color: #cbd5e0;
        }

        .management-item:last-child {
            margin-bottom: 0;
        }

        .management-item-info {
            display: flex;
            align-items: center;
            gap: 15px;
            flex: 1;
        }

        .management-item-emoji {
            font-size: 2rem;
        }

        .management-item-details {
            flex: 1;
        }

        .management-item-name {
            font-size: 1.2rem;
            font-weight: 700;
            color: #2d3748;
            margin-bottom: 5px;
        }

        .management-item-meta {
            font-size: 0.9rem;
            color: #718096;
        }

        .management-item-actions {
            display: flex;
            gap: 10px;
        }

        .management-delete-btn {
            background: #e53e3e;
            color: #ffffff;
            border: 2px solid #2d3748;
            border-radius: 8px;
            padding: 8px 16px;
            font-size: 0.9rem;
            font-weight: 700;
            font-family: 'Hello Headline W00 Regular', sans-serif;
            cursor: pointer;
            transition: all 0.2s ease;
            text-transform: uppercase;
            letter-spacing: 1px;
            box-shadow: 0 2px 0 #1a202c, 0 3px 6px rgba(0, 0, 0, 0.15);
        }

        .management-delete-btn:hover {
            background: #c53030;
            transform: translateY(-1px);
            box-shadow: 0 3px 0 #1a202c, 0 4px 8px rgba(0, 0, 0, 0.2);
        }

        .management-delete-btn:active {
            transform: translateY(1px);
            box-shadow: 0 1px 0 #1a202c, 0 2px 4px rgba(0, 0, 0, 0.15);
        }

        .management-buttons {
            display: flex;
            justify-content: center;
            gap: 15px;
        }

        .management-btn {
            background: #F48B45;
            color: #ffffff;
            border: 3px solid #2d3748;
            border-radius: 12px;
            padding: 12px 24px;
            font-size: 1.1rem;
            font-weight: 700;
            font-family: 'Hello Headline W00 Regular', sans-serif;
            cursor: pointer;
            transition: all 0.2s ease;
            text-transform: uppercase;
            letter-spacing: 1px;
            box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
        }

        .management-btn:hover {
            background: #e67e22;
            transform: translateY(-2px);
            box-shadow: 0 6px 0 #1a202c, 0 8px 16px rgba(0, 0, 0, 0.25);
        }

        .management-btn:active {
            transform: translateY(3px);
            box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
        }

        .management-empty {
            text-align: center;
            padding: 40px 20px;
            color: #718096;
            font-size: 1.1rem;
            font-style: italic;
        }

/* ===== LIBRARY GAME (BROWN/TAN THEME) ===== */

/* Library Game - Split Layout (like Supermarket) */
#library-game-screen.active {
    background: transparent;
    display: flex;
    height: 100vh;
    max-height: 100vh;
    padding: 0;
}

.library-split-container {
    display: flex;
    width: 100%;
    height: 100%;
    max-width: 2000px;
    margin: 0 auto;
}

/* Library Left Panel - Navigation and Content */
.library-left-panel {
    flex: 1;
    background: #D2B48C;
    border-right: 4px solid #2d3748;
    display: flex;
    flex-direction: column;
    padding: 0;
    overflow: hidden;
    height: 100vh;
    max-height: 100vh;
}

/* Library Navigation Section */
.library-nav-section {
    background: #8B4513;
    padding: 20px;
    border-bottom: 3px solid #2d3748;
}

.library-mode-toggle-buttons {
    display: grid;
    grid-template-columns: auto 1fr 1fr;
    gap: 12px;
    width: 100%;
}

.library-mode-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 14px;
    padding: 12px 20px;
    font-size: 1.2rem;
    font-weight: 800;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.2);
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.library-mode-btn:hover {
    background: #f7fafc;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #1a202c, 0 8px 20px rgba(0, 0, 0, 0.25);
}

.library-mode-btn:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.library-mode-btn:focus {
    outline: 3px solid #F48B45;
    outline-offset: 2px;
}

.library-mode-btn.active {
    background: #F48B45;
    color: #ffffff;
    transform: translateY(2px);
    box-shadow: 0 2px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Library Content Section */
.library-content-section {
    flex: 1;
    overflow-y: auto;
    background: #F5E6D3;
}

/* Library Menu Header */
.library-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.library-add-btn {
    background: #10B981;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 12px;
    padding: 10px 20px;
    font-size: 1.1rem;
    font-weight: 700;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 3px 0 #065F46, 0 4px 10px rgba(0, 0, 0, 0.2);
}

.library-add-btn:hover {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: 0 4px 0 #065F46, 0 6px 12px rgba(0, 0, 0, 0.25);
}

.library-add-btn:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 #065F46, 0 2px 6px rgba(0, 0, 0, 0.15);
}

.library-add-btn:focus {
    outline: 3px solid #F48B45;
    outline-offset: 2px;
}

/* Library Scan Toggle */
.library-scan-section {
    margin-bottom: 20px;
    text-align: center;
}

.library-scan-btn {
    background: #30598a;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 12px;
    padding: 12px 24px;
    font-size: 1.1rem;
    font-weight: 700;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 3px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 200px;
}

.library-scan-btn:hover { transform: translateY(-1px); }
.library-scan-btn:active { transform: translateY(2px); }
.library-scan-btn:focus { outline: 3px solid #F48B45; outline-offset: 2px; }
.library-scan-btn.active { background: #10B981; box-shadow: 0 3px 0 #065F46; }

/* Library Borrow Trigger */
.library-borrow-trigger {
    position: absolute;
    top: -9999px;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

/* Library Add Book Popup */
.library-add-book-popup {
    background: #D2B48C;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.library-add-book-title {
    font-size: 2rem;
    font-weight: 900;
    color: #2d3748;
    text-align: center;
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.library-add-book-form {
    margin-bottom: 25px;
}

.library-add-book-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.library-add-book-btn {
    padding: 12px 25px;
    border: 3px solid #2d3748;
    border-radius: 15px;
    font-size: 1.1rem;
    font-weight: 700;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    min-width: 120px;
}

.library-add-book-btn.cancel-btn {
    background: #ffffff;
    color: #2d3748;
    box-shadow: 0 3px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.2);
}

.library-add-book-btn.cancel-btn:hover {
    background: #f7fafc;
    transform: translateY(-1px);
    box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.25);
}

.library-add-book-btn.confirm-btn {
    background: #10B981;
    color: #ffffff;
    box-shadow: 0 3px 0 #065F46, 0 4px 10px rgba(0, 0, 0, 0.2);
}

.library-add-book-btn.confirm-btn:hover {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: 0 4px 0 #065F46, 0 6px 12px rgba(0, 0, 0, 0.25);
}

.library-add-book-btn:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 #1a202c, 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* Library Add Books Form */
.library-add-section {
    padding: 20px;
}

.library-add-form {
    background: #ffffff;
    border: 3px solid #8B4513;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 4px 0 #654321, 0 8px 20px rgba(0, 0, 0, 0.15);
}

.library-form-group {
    margin-bottom: 20px;
}

.library-form-label {
    display: block;
    font-size: 1.1rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.library-form-input {
    width: 100%;
    padding: 15px;
    border: 3px solid #2d3748;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    background: #ffffff;
    box-shadow: 0 2px 0 #1a202c, 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
}

.library-form-input:focus {
    outline: none;
    border-color: #F48B45;
    box-shadow: 0 2px 0 #F48B45, 0 6px 12px rgba(244, 139, 69, 0.3);
}

.library-form-buttons {
    margin-top: 25px;
    text-align: center;
}

.library-add-book-btn {
    background: #10B981;
    color: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 15px;
    padding: 15px 30px;
    font-size: 1.3rem;
    font-weight: 800;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 0 #065F46, 0 6px 15px rgba(0, 0, 0, 0.2);
}

.library-add-book-btn:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #065F46, 0 8px 20px rgba(0, 0, 0, 0.25);
}

.library-add-book-btn:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #065F46, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.library-panel-header {
    background: #D2B48C;
    padding: 0;
    text-align: center;
    flex-shrink: 0;
    min-height: 0;
}

.library-checked-out-items {
    flex: 1;
    overflow-y: auto;
    padding: 0 20px 20px 20px;
}

.library-checked-out-items::-webkit-scrollbar {
    width: 12px;
}

.library-checked-out-items::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
}

.library-checked-out-items::-webkit-scrollbar-thumb {
    background: #94a3b8;
    border-radius: 10px;
}

.library-checked-out-item {
    background: #ffffff;
    border: none;
    border-left: 6px solid #8B4513;
    border-radius: 18px;
    padding: 22px 28px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 12px rgba(139, 69, 19, 0.2), 0 2px 4px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    transition: all 0.2s ease;
}

.library-checked-out-item:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 16px rgba(48, 89, 138, 0.3), 0 3px 6px rgba(0, 0, 0, 0.1);
}

.library-checked-out-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.library-checked-out-emoji {
    font-size: 3.5rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.library-checked-out-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1e293b;
    letter-spacing: 0.5px;
}

.library-checked-out-author {
    font-size: 1.2rem;
    color: #8B4513;
    font-weight: 600;
    background: #F5DEB3;
    padding: 8px 16px;
    border-radius: 12px;
    border: 2px solid #8B4513;
    box-shadow: 0 2px 6px rgba(139, 69, 19, 0.2);
}

/* Library Right Panel */
.library-right-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #DEB887;
    max-height: 100vh;
    overflow: hidden;
    width: 450px;
    min-width: 400px;
}

.library-menu-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 20px;
    overflow-y: auto;
}

.library-menu-title {
    font-size: 2rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    margin-bottom: 15px;
    text-align: center;
}

.library-book-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    flex: 1;
}

.library-book-card {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 15px;
    padding: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 0 #1a202c, 0 6px 12px rgba(0, 0, 0, 0.2);
    min-height: 140px;
    justify-content: center;
}

.library-book-card:active {
    transform: translateY(3px);
    box-shadow: 0 1px 0 #1a202c, 0 2px 5px rgba(0, 0, 0, 0.15);
}

.library-book-card:focus {
    outline: 3px solid #F48B45;
    outline-offset: 2px;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #1a202c, 0 12px 25px rgba(0, 0, 0, 0.2);
}

.library-book-card.checked-out {
    background: #E5E7EB;
    color: #9CA3AF;
    cursor: not-allowed;
    box-shadow: 0 2px 0 #9CA3AF;
    opacity: 0.6;
}

.library-book-card.checked-out:hover {
    transform: none;
    background: #E5E7EB;
    box-shadow: 0 2px 0 #9CA3AF;
    opacity: 0.6;
}

.library-book-emoji {
    font-size: 3rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.library-book-name {
    font-size: 1rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
    line-height: 1.2;
}

.library-book-author {
    font-size: 0.9rem;
    font-weight: 600;
    color: #8B4513;
    text-align: center;
}

/* Library Payment Section */
.library-payment-section {
    background: #F5DEB3;
    border-top: 3px solid #2d3748;
    padding: 20px;
    flex-shrink: 0;
    position: sticky;
    bottom: 0;
    z-index: 2;
}

.library-total-display {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 18px 25px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 3px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.15);
}

.library-total-label {
    font-size: 1.5rem;
    font-weight: 900;
    color: #2d3748;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.library-total-amount {
    font-size: 2rem;
    font-weight: 900;
    color: #8B4513;
}

.library-payment-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.library-pay-btn {
    background: #ffffff;
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 20px;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 8px 18px rgba(0, 0, 0, 0.2);
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.library-pay-btn:active:not(:disabled) {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 3px 8px rgba(0, 0, 0, 0.15);
}

.library-pay-btn.return-btn {
    background: #F48B45;
    color: #ffffff;
}

.library-pay-btn.checkout-btn {
    background: #8B4513;
    color: #ffffff;
}

.library-pay-btn:disabled {
    background: #94a3b8;
    color: rgba(255, 255, 255, 0.5);
    cursor: not-allowed;
    border-color: #64748b;
    box-shadow: 0 5px 0 #475569, 0 8px 18px rgba(0, 0, 0, 0.15);
}

/* Library Game Mobile Responsive */
@media (max-width: 900px) {
    #library-game-screen.active {
        max-height: 100vh;
    }
    
    .library-split-container {
        flex-direction: column;
    }
    
    .library-left-panel {
        flex: 1;
        border-right: none;
        border-bottom: 3px solid #2d3748;
    }
    
    .library-right-panel {
        flex: 1;
        width: 100%;
        min-width: 100%;
        max-width: 100%;
    }
    
    /* Stack books in a single column on smaller screens */
    .library-book-grid {
        grid-template-columns: 1fr;
    }
    
    .library-checked-out-items {
        padding: 0 15px 15px 15px;
    }
    
    .library-checked-out-item {
        padding: 15px 18px;
    }
    
    .library-checked-out-emoji {
        font-size: 2.5rem;
    }
    
    .library-checked-out-name {
        font-size: 1rem;
    }
    
    .library-checked-out-author {
        font-size: 0.9rem;
        padding: 6px 12px;
    }
    
    .library-menu-section {
        padding: 15px;
    }
    
    .library-menu-title {
        font-size: 1.6rem;
    }
    
    .library-book-card {
        padding: 15px;
        min-height: 120px;
    }
    
    .library-book-emoji {
        font-size: 2.5rem;
    }
    
    .library-book-name {
        font-size: 0.9rem;
    }
    
    .library-book-author {
        font-size: 0.8rem;
    }
    
    .library-payment-section {
        padding: 15px;
    }
    
    .library-total-display {
        padding: 15px 20px;
    }
    
    .library-total-label {
        font-size: 1.2rem;
    }
    
    .library-total-amount {
        font-size: 1.6rem;
    }
    
    .library-pay-btn {
        padding: 15px;
        font-size: 1.1rem;
        min-height: 65px;
    }
    
    .library-mode-buttons {
        flex-direction: column;
    }
    
    .library-mode-btn {
        padding: 15px 22px;
        font-size: 1.1rem;
        gap: 5px;
        margin: 5px 0;
    }
}

/* Library Right Panel - Current Transaction */
.library-right-panel {
    flex: 1;
    background: #F5E6D3;
    display: flex;
    flex-direction: column;
    padding: 0;
    overflow: hidden;
    height: 100vh;
    max-height: 100vh;
}

.library-transaction-section {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.library-transaction-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: #8B4513;
    margin-bottom: 20px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.library-current-items {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.library-current-item {
    background: #ffffff;
    border: 2px solid #8B4513;
    border-radius: 12px;
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.2s ease;
    box-shadow: 0 2px 0 #654321;
}

.library-current-emoji {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.library-current-details {
    flex: 1;
}

.library-current-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #8B4513;
    margin-bottom: 5px;
}

.library-current-author {
    font-size: 0.9rem;
    font-weight: 500;
    color: #4a5568;
}

.library-remove-btn {
    background: #EF4444;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 0 #991B1B;
}

.library-remove-btn:hover {
    background: #DC2626;
    transform: translateY(-1px);
    box-shadow: 0 3px 0 #991B1B;
}

/* Library Action Section */
.library-action-section {
    background: #8B4513;
    padding: 20px;
    border-top: 3px solid #2d3748;
}

.library-total-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    background: #ffffff;
    padding: 15px;
    border-radius: 12px;
    box-shadow: 0 3px 0 #654321;
}

.library-total-label {
    font-size: 1.3rem;
    font-weight: 700;
    color: #8B4513;
}

.library-total-amount {
    font-size: 1.8rem;
    font-weight: 900;
    color: #8B4513;
}

.library-action-btn {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 12px;
    font-size: 1.2rem;
    font-weight: 800;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 0 #654321;
    background: #10B981;
    color: #ffffff;
}

.library-action-btn:hover:not(:disabled) {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #065F46;
}

.library-action-btn:disabled {
    background: #9CA3AF;
    color: #6B7280;
    cursor: not-allowed;
    box-shadow: 0 2px 0 #4B5563;
}

/* Library Customers Section */
.library-customers-section {
    padding: 20px;
}

.library-customers-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.library-customer-item {
    background: #ffffff;
    border: 2px solid #8B4513;
    border-radius: 15px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 0 #654321;
}

.library-customer-item:hover {
    background: #F5E6D3;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #654321;
}

.library-customer-item:focus {
    outline: 3px solid #F48B45;
    outline-offset: 2px;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #654321, 0 8px 20px rgba(0, 0, 0, 0.2);
}

.library-customer-info {
    text-align: left;
}

.library-customer-name {
    font-size: 1.4rem;
    font-weight: 800;
    color: #8B4513;
    margin-bottom: 8px;
}

.library-customer-books {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 5px;
}

.library-customer-date {
    font-size: 1rem;
    font-weight: 500;
    color: #4a5568;
}

/* Library Return Book Items */
.library-return-book-item {
    background: #ffffff;
    border: 2px solid #8B4513;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 0 #654321;
}

.library-return-book-item:hover {
    background: #F5E6D3;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #654321;
}

.library-return-book-item.selected-for-return {
    background: #10B981;
    color: #ffffff;
    border-color: #059669;
    box-shadow: 0 4px 0 #065F46;
}

.library-return-book-item.selected-for-return:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #065F46;
}

.library-return-book-emoji {
    font-size: 2rem;
    flex-shrink: 0;
}

.library-return-book-details {
    flex: 1;
}

.library-return-book-name {
    font-size: 1.3rem;
    font-weight: 700;
    color: #8B4513;
    margin-bottom: 5px;
}

.library-return-book-item.selected-for-return .library-return-book-name {
    color: #ffffff;
}

.library-return-book-author {
    font-size: 1rem;
    font-weight: 500;
    color: #4a5568;
}

.library-return-book-item.selected-for-return .library-return-book-author {
    color: #D1FAE5;
}

.library-return-book-status {
    font-size: 0.9rem;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 8px;
    background: #F3F4F6;
    color: #6B7280;
    text-align: center;
    min-width: 120px;
}

.library-return-book-item.selected-for-return .library-return-book-status {
    background: #ffffff;
    color: #10B981;
}

/* Library Success Modal */
.library-success-popup {
    background: #D2B48C;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.library-success-title {
    font-size: 2.2rem;
    color: #10B981;
    font-weight: 900;
    text-align: center;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.library-success-message {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
    margin-bottom: 25px;
    line-height: 1.4;
}

.library-success-buttons {
    display: flex;
    justify-content: center;
}

.library-success-btn {
    background: #10B981;
    color: #ffffff;
    border: none;
    border-radius: 15px;
    padding: 15px 30px;
    font-size: 1.2rem;
    font-weight: 800;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 0 #065F46;
}

.library-success-btn:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #065F46;
}

.library-success-btn:active {
    transform: translateY(2px);
    box-shadow: 0 2px 0 #065F46;
}

/* Library Name Input Popup */
.library-name-popup {
    background: #D2B48C;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.library-name-title {
    font-size: 2.2rem;
    color: #8B4513;
    font-weight: 900;
    text-align: center;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.library-name-message {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
    margin-bottom: 25px;
}

.library-name-form {
    margin-bottom: 25px;
}

.library-name-input {
    width: 100%;
    padding: 18px;
    font-size: 1.4rem;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    border: 3px solid #2d3748;
    border-radius: 16px;
    background: #ffffff;
    font-weight: 700;
    color: #2d3748;
    box-shadow: 0 3px 0 #1a202c, 0 6px 15px rgba(0, 0, 0, 0.15);
    text-align: center;
}

.library-name-input:focus {
    outline: none;
    border-color: #8B4513;
    box-shadow: 0 3px 0 #1a202c, 0 6px 15px rgba(139, 69, 19, 0.3);
}

.library-name-input::placeholder {
    color: #94a3b8;
    font-weight: 600;
}

.library-name-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.library-name-btn {
    border: 3px solid #2d3748;
    border-radius: 16px;
    padding: 18px;
    font-size: 1.4rem;
    font-weight: 900;
    font-family: 'Hello Headline W00 Regular', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 0 #1a202c, 0 10px 20px rgba(0, 0, 0, 0.2);
}

.library-name-btn:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #1a202c, 0 4px 10px rgba(0, 0, 0, 0.15);
}

.library-name-btn.cancel-btn {
    background: #F48B45;
    color: #ffffff;
}

.library-name-btn.confirm-btn {
    background: #8B4513;
    color: #ffffff;
}

/* Library Name Input Mobile Responsive */
@media (max-width: 900px) {
    .library-name-popup {
        padding: 25px;
        max-width: 400px;
    }
    
    .library-name-title {
        font-size: 1.8rem;
    }
    
    .library-name-message {
        font-size: 1.1rem;
        margin-bottom: 20px;
    }
    
    .library-name-input {
        padding: 15px;
        font-size: 1.2rem;
    }
    
    .library-name-btn {
        padding: 15px;
        font-size: 1.2rem;
    }
}

/* Library Returns Screens */
.library-returns-customers-popup,
.library-returns-books-popup {
    background: #D2B48C;
    border: 3px solid #2d3748;
    border-radius: 25px;
    padding: 35px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 8px 0 #1a202c, 0 15px 40px rgba(0, 0, 0, 0.35);
}

.library-returns-title {
    font-size: 2.2rem;
    color: #8B4513;
    font-weight: 900;
    text-align: center;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.library-returns-message {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2d3748;
    text-align: center;
    margin-bottom: 25px;
}

/* Customer List */
.library-customers-list {
    margin-bottom: 25px;
    max-height: 400px;
    overflow-y: auto;
}

.library-customer-item {
    background: #ffffff;
    border: 2px solid #8B4513;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 0 #654321;
}

.library-customer-item:hover {
    background: #E6D7C3;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #654321;
}

.library-customer-info {
    text-align: left;
}

.library-customer-name {
    font-size: 1.4rem;
    font-weight: 800;
    color: #8B4513;
    margin-bottom: 8px;
}

.library-customer-books {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 5px;
}

.library-customer-date {
    font-size: 1rem;
    font-weight: 500;
    color: #4a5568;
}

/* Book Return List */
.library-return-books-list {
    margin-bottom: 25px;
    max-height: 400px;
    overflow-y: auto;
}

.library-return-book-item {
    background: #F5E6D3;
    border: 2px solid #8B4513;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.2s ease;
}

.library-return-book-checkbox {
    flex-shrink: 0;
}

.library-return-book-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: #8B4513;
    cursor: pointer;
}

.library-return-book-info {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
}

.library-return-book-emoji {
    font-size: 2rem;
    flex-shrink: 0;
}

.library-return-book-details {
    flex: 1;
}

.library-return-book-name {
    font-size: 1.3rem;
    font-weight: 700;
    color: #8B4513;
    margin-bottom: 5px;
}

.library-return-book-author {
    font-size: 1rem;
    font-weight: 500;
    color: #4a5568;
}

/* Returns Buttons */
.library-returns-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.library-returns-confirm-btn,
.library-returns-cancel-btn {
    padding: 15px 30px;
    border: none;
    border-radius: 15px;
    font-size: 1.2rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    min-width: 150px;
}

.library-returns-confirm-btn {
    background: #8B4513;
    color: #ffffff;
    box-shadow: 0 4px 0 #654321;
}

.library-returns-confirm-btn:hover {
    background: #A0522D;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #654321;
}

.library-returns-cancel-btn {
    background: #6B7280;
    color: #ffffff;
    box-shadow: 0 4px 0 #4B5563;
}

.library-returns-cancel-btn:hover {
    background: #9CA3AF;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #4B5563;
}

/* Library Actions Section */
.library-actions-section {
    margin-top: 20px;
    text-align: center;
}

.library-returns-btn {
    background: #8B4513;
    color: #ffffff;
    border: none;
    border-radius: 15px;
    padding: 12px 20px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 0 #654321;
}

.library-returns-btn:hover {
    background: #A0522D;
    transform: translateY(-2px);
    box-shadow: 0 6px 0 #654321;
}

.library-returns-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 0 #654321;
}

/* Responsive Design for Returns */
@media (max-width: 768px) {
    .library-returns-customers-popup,
    .library-returns-books-popup {
        padding: 25px;
        max-width: 95%;
    }
    
    .library-returns-title {
        font-size: 1.8rem;
    }
    
    .library-returns-message {
        font-size: 1.1rem;
    }
    
    .library-customer-item,
    .library-return-book-item {
        padding: 15px;
    }
    
    .library-return-book-info {
        gap: 10px;
    }
    
    .library-return-book-emoji {
        font-size: 1.5rem;
    }
    
    .library-returns-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .library-returns-confirm-btn,
    .library-returns-cancel-btn {
        width: 100%;
        max-width: 200px;
    }
}

@font-face {
    font-family: "Hello Headline W00 Regular";
    src: url("Hello_Headline_W00_Regular.eot?") format("eot"),
         url("Hello_Headline_W00_Regular.woff") format("woff"),
         url("Hello_Headline_W00_Regular.ttf") format("truetype"),
         url("Hello_Headline_W00_Regular.svg#HelloHeadlineW00-Regular") format("svg");
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}
