:root {
    --orange: #ed6a24;
    --orange-dark: #d95513;
    --ink: #222b3a;
    --muted: #7c8798;
    --canvas: #f4f6f9;
    --line: #e8ebf0;
    --green: #1d9b67;
    --red: #df4b50;
    --radius: 17px
}

* {
    box-sizing: border-box
}

body {
    margin: 0;
    background: var(--canvas);
    color: var(--ink);
    font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
    font-size: 14px
}

.app-navbar {
    background: #202735;
    box-shadow: 0 4px 18px #17203316
}

.navbar-brand {
    color: #fff !important;
    letter-spacing: .6px;
    font-size: 19px
}

.brand-icon {
    display: inline-grid;
    place-items: center;
    background: var(--orange);
    border-radius: 10px;
    width: 35px;
    height: 35px;
    margin-right: 8px
}

.brand-accent {
    color: #ff985d
}

.online-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #39ce8b;
    box-shadow: 0 0 0 4px #39ce8b22
}

.avatar {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #3c4658;
    font-weight: 700
}

.page-title {
    font-size: 27px;
    font-weight: 800;
    letter-spacing: -.7px
}

.date-label {
    color: #657084;
    background: #fff;
    border: 1px solid var(--line);
    padding: 10px 13px;
    border-radius: 10px;
    font-size: 12px
}

.stat-card {
    height: 100%;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 13px
}

.stat-icon {
    width: 43px;
    height: 43px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    font-size: 18px
}

.stat-label {
    font-size: 12px;
    color: var(--muted)
}

.stat-value {
    font-size: 23px;
    font-weight: 800;
    line-height: 1.3
}

.surface-card {
    background: #fff;
    border: 1px solid #e9edf2;
    border-radius: var(--radius);
    padding: 21px;
    box-shadow: 0 5px 24px #25334b06
}

.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 19px
}

.section-heading h2 {
    font-size: 17px;
    font-weight: 800;
    margin: 0 0 5px
}

.section-heading p {
    font-size: 12px;
    color: var(--muted);
    margin: 0
}

.section-icon {
    color: var(--orange);
    margin-right: 9px
}

.soft-badge {
    background: #fff2e9;
    color: #bd4a10;
    border-radius: 20px;
    padding: 7px 11px;
    font-size: 11px;
    font-weight: 700
}

.table-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 11px
}

.table-card {
    position: relative;
    border: 1px solid var(--line);
    background: #fff;
    border-radius: 12px;
    padding: 14px 5px 12px;
    text-align: center;
    cursor: pointer;
    transition: .18s;
    min-width: 0
}

.table-card:hover {
    border-color: #f4a477;
    transform: translateY(-2px)
}

.table-card.active {
    border: 1.5px solid var(--orange);
    background: #fff6f0;
    box-shadow: 0 0 0 3px #ed6a2410
}

.table-card.occupied:not(.active) {
    background: #fffafa
}

.table-symbol {
    display: grid;
    place-items: center;
    margin: 0 auto 8px;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: #edf9f3;
    color: var(--green);
    font-size: 15px
}

.table-card.occupied .table-symbol {
    background: #fff0f0;
    color: var(--red)
}

.table-card.active .table-symbol {
    background: #ffe5d4;
    color: var(--orange-dark)
}

.table-name {
    font-size: 12px;
    font-weight: 800
}

.table-status {
    font-size: 10px;
    color: var(--green);
    margin-top: 4px
}

.table-card.occupied .table-status {
    color: var(--red)
}

.legend {
    display: flex;
    gap: 17px;
    flex-wrap: wrap;
    color: #7c8798;
    font-size: 11px
}

.legend-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    margin-right: 5px
}

.available {
    background: var(--green)
}

.occupied {
    background: var(--red)
}

.selected {
    background: var(--orange)
}

.search-wrap {
    position: relative;
    width: min(240px, 100%)
}

.search-wrap>i {
    position: absolute;
    left: 12px;
    top: 12px;
    color: #9aa3b1;
    font-size: 12px
}

.search-wrap input {
    padding-left: 32px;
    font-size: 12px;
    border-color: var(--line);
    border-radius: 9px
}

.category-scroll {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 1px 1px 9px;
    scrollbar-width: thin
}

.category-btn {
    white-space: nowrap;
    border: 1px solid var(--line);
    background: white;
    border-radius: 25px;
    padding: 8px 14px;
    font-size: 12px;
    font-weight: 650;
    color: #697386;
    transition: .15s
}

.category-btn:hover,
.category-btn.active {
    background: var(--orange);
    border-color: var(--orange);
    color: #fff
}

.food-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    height: 100%;
    border: 1px solid #edf0f4;
    border-radius: 13px;
    padding: 10px;
    background: #fff;
    transition: .18s;
    cursor: pointer;
}

.food-card:hover {
    border-color: #f2a779;
    transform: translateY(-2px);
    box-shadow: 0 7px 18px #ed6a2410;
}

/* 1. The Peach Background Block */
.food-icon-wrap {
    width: 100%;
    min-height: 110px; 
    border-radius: 9px;
    background: #fff1e8; 
    display: flex;
    flex-direction: column; 
    align-items: center;
    justify-content: center;
    padding: 14px 8px;
    margin-bottom: 12px;
}

/* 2. The Orange Icon Box inside the Peach Block */
.food-icon-inner {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--white);
    color: #fff;
    font-size: 18px;
    display: grid;
    place-items: center;
    margin-bottom: 10px;
}

/* Item Name Styling */
.food-name {
    font-size: 12px;
    font-weight: 800;
    line-height: 1.3;
    text-align: center;
    color: var(--ink);
    margin-bottom: 0;
}

/* Item Description Styling */
.food-desc {
    font-size: 10px;
    color: var(--muted);
    line-height: 1.3;
    margin-bottom: 10px;
    text-align: center;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.food-price {
    font-weight: 800;
    color: var(--orange-dark);
    font-size: 13px;
}

.add-btn {
    border: 0;
    border-radius: 8px;
    width: 28px;
    height: 28px;
    background: #fff0e6;
    color: var(--orange-dark);
    flex-shrink: 0;
}

.add-btn:hover {
    background: var(--orange);
    color: #fff;
}

/* Hide the old default <img> tag completely */
.food-image, .food-card::before, .food-card::after {
    display: none !important;
}


/* =========================================
   STICKY CURRENT ORDER PANEL
========================================= */

.order-panel {
    position: sticky;
    top: 80px;
    /* Space below the fixed navbar */
    height: calc(100vh - 96px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-height: 0;
    border-radius: 14px;
}

/* Current Order heading */
.order-panel>.section-heading {
    flex-shrink: 0;
    margin-bottom: 12px;
}

/* Selected table information */
.order-panel .order-meta {
    flex-shrink: 0;
    margin-bottom: 12px;
}

/* Cart items scroll independently */
.order-panel .cart-items {
    flex: 1 1 auto;
    min-height: 80px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    padding-right: 4px;
}

/* Keep form fields and billing information visible */
.order-panel>.form-block,
.order-panel>div[style*="display: flex"],
.order-panel .bill-lines,
.order-panel .grand-total,
.order-panel .payment-block,
.order-panel>.d-grid {
    flex-shrink: 0;
}

/* Keep order form fields compact */
.order-panel .form-block {
    margin-top: 10px;
}

/* Responsive layout */
@media (max-width: 1199.98px) {
    .order-panel {
        position: static;
        height: auto;
        overflow: visible;
    }

    .order-panel .cart-items {
        flex: initial;
        max-height: 350px;
        min-height: 100px;
        overflow-y: auto;
    }
}

.order-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f7f8fa;
    border-radius: 10px;
    padding: 12px;
    margin-bottom: 9px
}

.meta-label {
    display: block;
    color: var(--muted);
    font-size: 10px;
    margin-bottom: 3px
}

.order-meta strong {
    font-size: 13px
}

.item-count {
    font-size: 11px;
    font-weight: 750;
    color: var(--orange-dark);
    background: #ffeadc;
    padding: 6px 9px;
    border-radius: 7px
}

.cart-items {
    max-height: 260px;
    overflow: auto
}

.empty-cart {
    text-align: center;
    padding: 25px 8px;
    color: #9aa3b1
}

.empty-cart i {
    font-size: 28px;
    color: #c8ced8;
    margin-bottom: 10px
}

.cart-line {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 2px;
    border-bottom: 1px solid #eff1f4
}

.cart-item-name {
    font-size: 12px;
    font-weight: 750
}

.cart-item-price {
    font-size: 11px;
    color: var(--muted);
    margin-top: 3px
}

.cart-line-total {
    font-size: 12px;
    font-weight: 800;
    text-align: right
}

.qty-controls {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-top: 7px;
    justify-content: flex-end
}

.qty-btn {
    width: 24px;
    height: 24px;
    border: 1px solid #e4e7ed;
    background: white;
    border-radius: 6px;
    line-height: 1
}

.qty-btn:hover {
    border-color: var(--orange);
    color: var(--orange)
}

.qty-number {
    font-size: 11px;
    font-weight: 700;
    min-width: 10px;
    text-align: center
}

.form-block {
    margin-top: 13px
}

.form-label {
    font-size: 11px;
    font-weight: 750;
    margin-bottom: 5px
}

.optional {
    color: #a0a7b3;
    font-weight: 400
}

.form-control,
.form-select {
    font-size: 12px;
    border-color: #e4e8ef;
    border-radius: 9px;
    padding: 9px 11px
}

.form-control:focus,
.form-select:focus {
    border-color: #f3a276;
    box-shadow: 0 0 0 .2rem #ed6a2415
}

.bill-lines {
    border-top: 1px solid var(--line);
    margin-top: 16px;
    padding-top: 12px
}

.bill-lines>div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    color: #778193;
    font-size: 12px
}

.bill-lines strong {
    color: var(--ink)
}

.bill-lines input {
    width: 95px;
    text-align: right
}

.grand-total {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fff2e9;
    padding: 14px;
    border-radius: 11px
}

.grand-total span {
    font-size: 13px;
    font-weight: 750
}

.grand-total strong {
    font-size: 23px;
    font-weight: 850;
    color: var(--orange-dark)
}

/* 1. Add a container to align them perfectly side-by-side */
.action-buttons {
    display: flex;
    gap: 12px;
    /* Space between the buttons */
    align-items: center;
}

/* 2. Common Button Styles */
.btn-kot,
.btn-print_bill,
.btn-checkout {
    flex: 1;
    /* This forces all buttons to be the exact same width */
    display: flex;
    /* Centers the text perfectly inside the button */
    justify-content: center;
    align-items: center;
    border-radius: 10px;
    padding: 12px;
    font-size: 12px;
    font-weight: 750;
    cursor: pointer;
    box-sizing: border-box;
    /* Ensures padding and borders don't break sizing */
    text-align: center;
}

/* KOT Button */
.btn-kot {
    background: white;
    border: 1px solid #f1b18a;
    color: var(--orange-dark);
}

.btn-kot:hover {
    background: #fff3eb;
    color: var(--orange-dark);
}

/* Print Bill Button - Added missing background, border, and color */
.btn-print_bill {
    background: white;
    border: 1px solid #f1b18a;
    /* Must have a border to match the height of others */
    color: var(--orange-dark);
}

.btn-print_bill:hover {
    background: #fff3eb;
    color: var(--orange-dark);
}

/* Checkout Button */
.btn-checkout {
    background: var(--orange);
    color: #fff;
    border: 1px solid var(--orange);
    /* The 1px border keeps it the exact same height as the others */
}

.btn-checkout:hover {
    background: var(--orange-dark);
    color: #fff;
}

.demo-note {
    font-size: 10px;
    text-align: center;
    color: #9aa3b1
}

.no-results {
    grid-column: 1/-1;
    padding: 30px;
    text-align: center;
    color: #8b95a5
}

.toast {
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 10px 30px #0002
}

.toast-body {
    font-size: 13px
}

/* Footer branding */
.login-copyright {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 18px 12px;
    text-align: center;
    color: #7b8494;
    font-size: 12px;
}

.powered-by {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    flex-wrap: wrap;
    color: #667085;
}

.speedwave-brand {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #f47721;
    text-decoration: none;
    font-weight: 800;
    letter-spacing: 1px;
    transition: all 0.25s ease;
}

.speedwave-logo {
    width: 40px;
    /* Logo width */
    height: 40px;
    /* Logo height */
    object-fit: contain;
    display: block;
}

.speedwave-brand:hover {
    color: #c6530a;
    transform: translateY(-1px);
}

@media (max-width:1199px) {
    .order-panel {
        position: static
    }

    .table-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr))
    }

}

@media(max-width:575px) {
    .surface-card {
        padding: 15px;
        border-radius: 14px
    }

    .page-title {
        font-size: 23px
    }

    .section-heading {
        align-items: flex-start;
        flex-wrap: wrap
    }

    .search-wrap {
        width: 100%
    }

    .table-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px
    }

    .table-card {
        padding: 11px 3px
    }

    .food-image {
        height: 78px
    }

    .grand-total strong {
        font-size: 21px
    }

}

.payment-options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px
}

.payment-option {
    cursor: pointer;
    min-width: 0
}

.payment-option input {
    position: absolute;
    opacity: 0
}

.payment-option span {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 11px 5px;
    border: 1px solid #dfe3eb;
    border-radius: 10px;
    background: #fff;
    font-size: 12px;
    font-weight: 800;
    transition: .15s
}

.payment-option input:checked+span {
    border: 2px solid var(--primary);
    background: #fff2e8;
    color: var(--primary)
}

.payment-option:focus-within span {
    outline: 2px solid #fbbf24;
    outline-offset: 2px
}

/* Fixed top navigation header */
.app-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1030;
    min-height: 64px
}

body {
    padding-top: 64px
}

@media(max-width:575px) {
    .app-navbar {
        min-height: 58px;
        padding-top: 10px !important;
        padding-bottom: 10px !important
    }

    body {
        padding-top: 58px
    }
}

/* ---------------- Login page ---------------- */
.login-page {
    min-height: 100vh;
    padding: 28px;
    background: #f3f5f9;
    display: grid;
    place-items: center
}

.login-shell {
    width: min(1080px, 100%);
    min-height: 650px;
    background: #fff;
    border-radius: 24px;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr 1fr;
    box-shadow: 0 25px 80px #1d2b4518
}

.login-brand-panel {
    position: relative;
    overflow: hidden;
    padding: 42px 46px;
    color: #fff;
    background: radial-gradient(circle at 10% 90%, #ff985d30 0, transparent 36%), linear-gradient(145deg, #202735 0%, #303d53 100%);
    display: flex;
    flex-direction: column
}

.login-brand {
    font-size: 21px;
    font-weight: 850;
    letter-spacing: .7px;
    display: flex;
    align-items: center
}

.login-brand .brand-icon,
.login-mobile-brand .brand-icon {
    display: inline-grid;
    place-items: center;
    background: var(--orange);
    border-radius: 10px;
    width: 39px;
    height: 39px;
    margin-right: 10px;
    color: #fff
}

.login-brand-copy {
    margin-top: auto;
    margin-bottom: 36px;
    position: relative;
    z-index: 1
}

.login-eyebrow {
    font-size: 10px;
    letter-spacing: 2.2px;
    color: #ffb38a;
    font-weight: 800
}

.login-brand-copy h1 {
    font-size: clamp(29px, 3vw, 40px);
    line-height: 1.18;
    letter-spacing: -1px;
    font-weight: 850;
    margin: 17px 0
}

.login-brand-copy p {
    max-width: 360px;
    color: #c5ccda;
    line-height: 1.8;
    font-size: 13px
}

.login-feature-list {
    display: grid;
    gap: 17px;
    position: relative;
    z-index: 1
}

.login-feature-list>div {
    display: flex;
    align-items: center;
    gap: 13px;
    color: #e6eaf1;
    font-size: 12px
}

.login-feature-list i {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: #ffffff12;
    color: #ffab7d
}

.login-brand-footer {
    margin-top: 42px;
    padding-top: 19px;
    border-top: 1px solid #ffffff20;
    color: #b6c0d0;
    font-size: 11px
}

.login-brand-footer i {
    color: #6fe0ae
}

.login-form-panel {
    padding: 54px 56px 25px;
    display: flex;
    flex-direction: column;
    justify-content: center
}

.login-form-wrap {
    width: 100%;
    max-width: 365px;
    margin: auto
}

.login-welcome-icon {
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    background: #fff0e6;
    color: var(--orange-dark);
    font-size: 19px;
    margin-bottom: 25px
}

.login-kicker {
    font-size: 10px;
    font-weight: 850;
    letter-spacing: 2px;
    color: var(--orange-dark)
}

.login-form-wrap h2 {
    font-size: 27px;
    font-weight: 850;
    letter-spacing: -.7px;
    margin-bottom: 8px
}

.login-subtitle {
    font-size: 12px;
    color: #8791a1;
    margin-bottom: 27px
}

.login-form-wrap .form-label {
    font-size: 12px;
    color: #394355;
    margin-bottom: 8px
}

.login-input-wrap {
    position: relative
}

.login-input-wrap>i {
    position: absolute;
    z-index: 2;
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
    color: #9ba4b2;
    font-size: 13px
}

.login-input-wrap .form-control {
    height: 47px;
    padding-left: 40px;
    padding-right: 42px;
    border-radius: 10px;
    font-size: 12px;
    background: #fbfcfe
}

.login-input-wrap .form-control:focus {
    background: #fff
}

.password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    color: #8c96a6;
    padding: 7px
}

.login-submit {
    background: var(--orange);
    color: #fff;
    border: 0;
    border-radius: 10px;
    height: 48px;
    font-size: 13px;
    font-weight: 800;
    box-shadow: 0 8px 18px #ed6a2428
}

.login-submit:hover {
    background: var(--orange-dark);
    color: #fff;
    transform: translateY(-1px)
}

.login-security {
    text-align: center;
    color: #8d97a6;
    font-size: 10px;
    margin-top: 27px
}

.login-security i {
    color: #36a978
}

.login-copyright {
    text-align: center;
    color: #9aa3b1;
    font-size: 10px;
    padding-top: 24px
}

.login-mobile-brand {
    display: none
}

.login-form-wrap .alert {
    border-radius: 10px
}

@media(max-width:767px) {
    .login-page {
        padding: 14px
    }

    .login-shell {
        min-height: 0;
        grid-template-columns: 1fr;
        border-radius: 18px
    }

    .login-brand-panel {
        display: none
    }

    .login-form-panel {
        padding: 28px 24px 20px;
        min-height: calc(100vh - 28px)
    }

    .login-form-wrap {
        max-width: 410px
    }

    .login-mobile-brand {
        display: flex;
        align-items: center;
        font-weight: 850;
        letter-spacing: .7px;
        margin-bottom: 40px;
        font-size: 19px
    }

    .login-welcome-icon {
        margin-bottom: 19px
    }

    .login-form-wrap h2 {
        font-size: 25px
    }

    .login-copyright {
        padding-top: 32px
    }
}