/* ========================================
   GLOBAL STYLES
   ======================================== */

html, body {
    background-color: #212121;
    color: white;
    overflow-x: hidden;
    width: 100%;
}

body.modal-open {
    padding-right: 0 !important;
    overflow: hidden;
}

/* ========================================
   LINKS
   ======================================== */

a {
    color: #1e90ff;
    text-decoration: none;
}

a:hover {
    color: #00bfff;
}

/* ========================================
   NAVBAR
   ======================================== */

.navbar,
.navbar-brand,
.nav-link {
    font-size: 1.2rem;
    background-color: #212121;
    color: white !important;
    z-index: 1050 !important;
}

.navbar-nav {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
}

.navbar-nav .nav-link {
    margin-right: 20px;
}

.navbar-nav .nav-link.active {
    font-size: 1.3rem;
    font-weight: bold;
}

/* Dropdown */
.dropdown-menu {
    background-color: #212121 !important;
    color: white;
    border: 1px solid #444;
}

.dropdown-item {
    font-size: 1.2rem;
    color: white !important;
}

.dropdown-item:hover,
.dropdown-item:focus {
    background-color: #2c2c2c !important;
    color: white !important;
}

/* ========================================
   FORMS & INPUTS
   ======================================== */

.form-control,
.form-select {
    background-color: #343a40 !important;
    color: white !important;
    border: 1px solid #495057 !important;
}

.form-control:focus,
.form-select:focus {
    background-color: #495057 !important;
    color: white !important;
    border-color: #0091EA !important;
    box-shadow: 0 0 0 0.2rem rgba(0, 145, 234, 0.25) !important;
}

.transparent-dark-bg {
    background-color: #343a40;
    color: white;
}

.js-search {
    height: 38px;
}

.input-group {
    display: flex;
    align-items: center;
}

.input-group-text {
    background-color: #343a40;
    color: white;
    border: 1px solid transparent !important;
    height: 38px;
}

.input-group-text i {
    font-size: 16px;
}

.js-search:focus,
.input-group-text:focus {
    background-color: #343a40 !important;
    color: white !important;
    box-shadow: none !important;
}

label {
    margin-bottom: 15px;
}

/* ========================================
   TABLES
   ======================================== */

.table {
    background-color: #2c2c2c !important;
    color: white !important;
}

.table thead th {
    background-color: #1a1a1a !important;
    color: white !important;
    border-color: #495057 !important;
    vertical-align: middle;
    padding: 8px;
    text-align: center;
}

.table thead th:nth-child(1),
.table thead th:nth-child(2) {
    text-align: left;
}

.table thead th:nth-child(4) {
    text-align: right;
}

.table thead th:nth-child(5) {
    text-align: center;
}

.table tbody td {
    background-color: #2c2c2c !important;
    color: white !important;
    border-color: #495057 !important;
    vertical-align: middle;
    padding: 6px 8px;
    text-align: center;
}

.table tbody td:nth-child(1),
.table tbody td:nth-child(2) {
    text-align: left;
}

.table tbody td:nth-child(4) {
    text-align: right;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: #343a40 !important;
}

.table tbody .btn {
    vertical-align: middle;
    margin-bottom: 0 !important;
    display: inline-block;
    padding: 4px 6px;
    line-height: 1.6;
}

/* ========================================
   ADMIN SIDEBAR
   ======================================== */

.list-group-item {
    background-color: #343a40 !important;
    color: white !important;
    border: 1px solid #495057 !important;
    transition: all 0.3s ease;
}

.list-group-item:hover {
    background-color: #495057 !important;
    color: white !important;
}

.list-group-item.active {
    background-color: #0091EA !important;
    color: white !important;
    border-color: #0091EA !important;
}

.list-group-item.active:hover {
    text-decoration: underline !important;
}

.list-group a:focus {
    outline: none !important;
    box-shadow: none !important;
}

.my-custom-div.border {
    border: 1px solid #dee2e6;
    border-left-color: transparent !important;
}

.bg-dark {
    background-color: #212121;
    color: white;
}

/* ========================================
   CATEGORY TABS
   ======================================== */


.category-tab {
    margin: 2px;
    background-color: #2d2d2d;
    color: #aaa;
    border: 1px solid #444;
    transition: all 0.2s ease;
    border-radius: 8px;

    /* ✅ Fixed size - prevents reshaping with long names */
    width: 150px;
    height: 80px;
    padding: 8px 4px;

    /* ✅ Stack icon on top, text below */
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;

    /* ✅ Prevent size shift on active */
    font-weight: bold;
    border-width: 1px;
    box-shadow: none !important;
}

.category-tab:hover,
.category-tab:focus,
.category-tab:active,
.category-tab:focus-visible {
    box-shadow: none !important;
    outline: none !important;
}

/* Icon styling */
.category-tab i {
    font-size: 1.5rem;
    display: block;
}

/* Label styling */
.category-tab-label {
    font-size: 1.2rem;
    text-align: center;
    line-height: 1.2;
    word-break: break-word;
    max-width: 120px;
    display: block;
    white-space: normal; /* ✅ allows wrapping on long names */
}

/* ✅ Food tabs - orange when active */
.category-tab.tab-food.active {
    color: #e67e22 !important;
    border-color: #e67e22 !important;
    background-color: #2d2d2d !important;
}

/* ✅ Drink tabs - blue when active */
.category-tab.tab-drink.active {
    color: #3498db !important;
    border-color: #3498db !important;
    background-color: #2d2d2d !important;
}

/* ✅ All tabs - white when active */
.category-tab.tab-all.active {
    color: #fff !important;
    border-color: #aaa !important;
    background-color: #2d2d2d !important;
}

/* Hover states */
.category-tab.tab-food:hover {
    color: #e67e22 !important;
    border-color: #e67e22 !important;
    background-color: #3d3d3d !important;
}

.category-tab.tab-drink:hover {
    color: #3498db !important;
    border-color: #3498db !important;
    background-color: #3d3d3d !important;
}


/*========================================
   FLOORPLAN
======================================== */

.floorplan-bg {
    background: #181818 !important;
    color: #fff !important;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

.table-btn {
    text-decoration: none;
    position: absolute;
    width: 100px;
    height: 100px;
    border-radius: 18px;
    background: #222;
    box-shadow: 0 2px 14px rgba(0, 0, 0, 0.25);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.table-btn-content {
    width: 100%;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* ========================================
   PRODUCTS
   ======================================== */

.product-btn,
.product-btn * {
    text-transform: none !important;
}

.out-of-stock {
    position: relative;
    overflow: hidden;
}

.out-of-stock::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

/* ========================================
   PAYMENT SELECT
   ======================================== */

#payment-type {
    background-color: #444;
    color: white;
    border: 2px solid #555;
    padding: 15px;
    font-size: 24px;
    border-radius: 4px;
    width: 100%;
    cursor: pointer;
    text-align: center;
}

#payment-type[data-value="efectivo"] {
    color: green;
    border-color: green;
}

#payment-type[data-value="tarjeta"] {
    color: orange;
    border-color: orange;
}

#payment-type::-ms-expand {
    display: none;
}

#payment-type:focus {
    outline: none;
    box-shadow: none;
    border-color: inherit;
}


 /*NUOVI CAMBI PROGRAMMA PIU´ORGANIZZATO


/* ========================================
   UTILITIES
   ======================================== */

.header-container {
    overflow: hidden;
}

/* Export buttons styling */
.export-buttons-separator {
    border-left: 2px solid #6c757d;
    height: 38px;
    margin: 0 15px;
}

.btn-group-export {
    display: flex;
    gap: 10px;
    align-items: center;
}

.btn-group-export .btn {
    min-width: 140px;
}

/* Animations */
@keyframes appear {
    0%   { opacity: 0; transform: translateY(-100px); }
    100% { opacity: 1; transform: translateY(0px); }
}

/* Utility */
.hide { display: none; }

/* ===== CHANGE MODAL ===== */
.change-modal-overlay {
    animation: appear .5s ease;
    background-color: #000000bb;
    width: 100%;
    height: 100%;
    position: fixed;
    left: 0;
    top: 0;
    z-index: 4;
}

.change-modal-box {
    width: 500px;
    min-height: 200px;
    background-color: white;
    padding: 10px;
    margin: 100px auto 0;
}

.change-amount-display {
    font-size: 60px;
}

/* ===== PAYMENT MODAL ===== */
.payment-modal-content {
    background-color: #2c2c2c;
    color: white;
    border: 1px solid #444;
}

.payment-modal-header {
    border-bottom: 1px solid #444;
}

.payment-modal-footer {
    border-top: 1px solid #444;
}

.payment-input-prefix {
    background-color: #444;
    color: white;
    border: 1px solid #555;
}

.payment-input {
    background-color: #444;
    color: white;
    border: 1px solid #555;
}

/* ===== PRODUCT CARDS ===== */
.product-card {
    height: 80px;
    width: 120px;
    background-color: #2d2d2d;
    border-radius: 8px;
    position: relative;
}

.product-card-inner {
    pointer-events: none;
    font-size: 0.9rem;
}

.product-name {
    text-transform: none;
}

.product-price {
    color: #4CAF50;
    font-weight: 500;
}

/* ===== CART QUANTITY CONTROL ===== */
.qty-control {
    width: 100px;
}

.qty-btn {
    cursor: pointer;
}

.qty-input {
    border: none;
}

/* ===== PAYMENT TYPE SELECT ===== */
.payment-cash {
    color: green !important;
    border-color: green !important;
}

.payment-card {
    color: orange !important;
    border-color: orange !important;
}

/* ===== CATEGORY TABS ===== */
.category-tab {
    margin: 2px;
}



/* ===== CHANGE AMOUNT DISPLAY ===== */
.change-amount-text {
    font-size: 1.3rem;
    font-weight: bold;
    color: #28a745;
}

/* ===== SAVE PAYMENT BUTTON STATES ===== */
.btn-save-payment.ready {
    border-color: #28a745;
    color: #28a745;
}

/* ===== TYPE TOGGLE BUTTONS ===== */
.type-toggle-btn {
    background-color: #2d2d2d;
    color: #aaa;
    border: 1px solid #444;
    padding: 6px 16px;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    border-radius: 6px;
}

.type-toggle-btn:hover {
    background-color: #3d3d3d;
    color: #fff;
    border-color: #666;
}

/* Food active - orange */
[data-type="food"].active {
    background-color: #2d2d2d;
    color: #e67e22;
    border-color: #e67e22;
    font-weight: bold;
}

/* Drink active - blue */
[data-type="drink"].active {
    background-color: #2d2d2d;
    color: #3498db;
    border-color: #3498db;
    font-weight: bold;
}

/* All active - white */
[data-type="all"].active {
    background-color: #2d2d2d;
    color: #fff;
    border-color: #aaa;
    font-weight: bold;
}

/* ===== CATEGORY TABS ===== */
.category-tab {
    margin: 2px;
    background-color: #2d2d2d;
    color: #aaa;
    border: 1px solid #444;
    transition: all 0.2s ease;
    border-radius: 6px;
}

.category-tab:hover {
    background-color: #3d3d3d;
    color: #fff;
    border-color: #666;
}

/* ✅ Food tabs - orange when active */
.category-tab.active.tab-food {
    background-color: #2d2d2d;
    color: #e67e22;
    border-color: #e67e22;
    font-weight: bold;
}

/* ✅ Drink tabs - blue when active */
.category-tab.active.tab-drink {
    background-color: #2d2d2d;
    color: #3498db;
    border-color: #3498db;
    font-weight: bold;
}

/* ✅ All tabs - white when active */
.category-tab.active.tab-all {
    background-color: #2d2d2d;
    color: #fff;
    border-color: #aaa;
    font-weight: bold;
}

/* ✅ Food tabs - orange when active */
.category-tab.tab-food.active {
    background-color: #2d2d2d !important;
    color: #e67e22 !important;
    border-color: #e67e22 !important;
    font-weight: bold;
}

/* ✅ Drink tabs - blue when active */
.category-tab.tab-drink.active {
    background-color: #2d2d2d !important;
    color: #3498db !important;
    border-color: #3498db !important;
    font-weight: bold;
}

/* ✅ All tabs - white when active */
.category-tab.tab-all.active {
    background-color: #2d2d2d !important;
    color: #fff !important;
    border-color: #aaa !important;
    font-weight: bold;
}

/* ✅ Also fix hover to match color */
.category-tab.tab-food:hover {
    color: #e67e22 !important;
    border-color: #e67e22 !important;
    background-color: #3d3d3d !important;
}

.category-tab.tab-drink:hover {
    color: #3498db !important;
    border-color: #3498db !important;
    background-color: #3d3d3d !important;
}

/* ===== PAYMENT TYPE BUTTONS ===== */
.payment-type-btn {
    border-radius: 10px;
    transition: all 0.2s ease;
    font-size: 0.95rem;
}

.payment-type-btn:hover {
    transform: translateY(-2px);
}

/* Cash selected */
.payment-type-btn[data-payment="efectivo"].selected {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.4);
}

/* Card selected */
.payment-type-btn[data-payment="tarjeta"].selected {
    background-color: #0d6efd !important;
    border-color: #0d6efd !important;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.4);
}

/* ===== PAYMENT INPUT ===== */
.payment-input-prefix {
    background-color: #444;
    color: white;
    border: 1px solid #555;
}

.payment-input {
    background-color: #444;
    color: white;
    border: 1px solid #555;
}

.payment-input:focus {
    background-color: #555;
    color: white;
    border-color: #888;
    box-shadow: none;
}

/* ===== PREVENT TOGGLE BUTTON SIZE SHIFT ===== */
.type-toggle-btn {
    background-color: #2d2d2d;
    color: #aaa;
    border: 1px solid #444;
    padding: 6px 16px;
    font-size: 0.9rem;
    transition: color 0.2s ease, border-color 0.2s ease;
    
    /* ✅ These three lines prevent size shift */
    font-weight: bold;        /* always bold - no shift when active adds it */
    border-width: 1px;        /* fixed border width */
    box-shadow: none !important; /* removes Bootstrap focus shadow */
}

.type-toggle-btn:hover,
.type-toggle-btn:focus,
.type-toggle-btn:active,
.type-toggle-btn:focus-visible {
    box-shadow: none !important;
    outline: none !important;
    border-width: 1px;        /* keeps border same size on all states */
}

/* Food active */
[data-type="food"].active {
    background-color: #2d2d2d;
    color: #e67e22;
    border-color: #e67e22;
}

/* Drink active */
[data-type="drink"].active {
    background-color: #2d2d2d;
    color: #3498db;
    border-color: #3498db;
}

/* All active */
[data-type="all"].active {
    background-color: #2d2d2d;
    color: #fff;
    border-color: #aaa;
}


