/* AdisGo Panel — modern SaaS design system */
:root {
    --font-family: 'Inter', 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --primary: #F26522;
    --primary-dark: #D9561A;
    --primary-light: #FFF4ED;
    --navy: #1A2940;
    --navy-light: #2A4563;
    --sidebar-bg: #152238;
    --sidebar-width-expanded: 248px;
    --sidebar-width-collapsed: 72px;
    --sidebar-width: var(--sidebar-width-expanded);
    --header-height: 68px;
    --body-bg: #F4F6FA;
    --card-bg: #ffffff;
    --surface-muted: #F8FAFC;
    --surface-elevated: #ffffff;
    --text-primary: #1A2940;
    --text-secondary: #5C6B7F;
    --text-muted: #8B97A8;
    --border-color: #E4E9F0;
    --shadow-sm: 0 1px 3px rgba(26, 41, 64, 0.06);
    --shadow-md: 0 4px 24px rgba(26, 41, 64, 0.08);
    --shadow-lg: 0 12px 40px rgba(26, 41, 64, 0.12);
    --radius: 14px;
    --radius-lg: 18px;
    --brand: var(--primary);
    --bs-primary: #F26522;
    --bs-primary-rgb: 242, 101, 34;
    --bs-body-font-family: var(--font-family);
    --kitchen-pending: #2563EB;
    --kitchen-pending-dark: #1D4ED8;
    --kitchen-pending-light: #DBEAFE;
}

*, *::before, *::after {
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    color: var(--text-primary);
    background: var(--body-bg);
    -webkit-font-smoothing: antialiased;
}

/* Bootstrap overrides */
.btn-primary {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--primary);
    --bs-btn-border-color: var(--primary);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--primary-dark);
    --bs-btn-hover-border-color: var(--primary-dark);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--primary-dark);
    --bs-btn-active-border-color: var(--primary-dark);
    color: #fff;
    background-color: var(--primary);
    border-color: var(--primary);
    font-weight: 500;
    border-radius: 10px;
    padding: 0.5rem 1.25rem;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    color: #fff !important;
    background-color: var(--primary-dark) !important;
    border-color: var(--primary-dark) !important;
}

.btn-outline-primary {
    --bs-btn-color: var(--primary);
    --bs-btn-border-color: var(--primary);
    --bs-btn-hover-bg: var(--primary);
    --bs-btn-hover-border-color: var(--primary);
    font-weight: 500;
    border-radius: 10px;
}

.btn-secondary, .btn-outline-secondary {
    border-radius: 10px;
    font-weight: 500;
}

.form-control, .form-select {
    font-family: var(--font-family);
    border-radius: 10px;
    border-color: var(--border-color);
    padding: 0.625rem 0.875rem;
    font-size: 0.9rem;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent);
}

.form-label {
    font-weight: 500;
    font-size: 0.875rem;
    color: var(--text-primary);
    margin-bottom: 0.375rem;
}

/* App shell */
.app-shell {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    max-height: 100vh;
    background-color: var(--sidebar-bg);
    background-image:
        radial-gradient(ellipse at 0% 100%, rgba(255, 255, 255, 0.04) 0%, transparent 55%),
        radial-gradient(ellipse at 100% 0%, rgba(240, 90, 40, 0.06) 0%, transparent 45%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.02) 0%, transparent 30%);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1040;
    transition: width 0.22s ease, transform 0.3s ease;
}

.sidebar-brand {
    padding: 1.5rem 1.25rem 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
}

.sidebar-brand .brand-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.sidebar-brand .brand-icon {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, var(--primary) 0%, #FF8A5C 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.sidebar-brand .brand-text {
    color: #fff;
    font-weight: 700;
    font-size: 1.15rem;
    line-height: 1.2;
    margin: 0;
}

.sidebar-brand .brand-sub {
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.7rem;
    font-weight: 400;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.sidebar-nav {
    padding: 0.5rem 0 1rem;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
    display: flex;
    flex-direction: column;
}

.sidebar-nav::-webkit-scrollbar {
    width: 5px;
}

.sidebar-nav::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 4px;
}

.sidebar-nav::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.25);
}

.sidebar-nav .nav-section {
    color: rgba(255, 255, 255, 0.38);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 1rem 1.25rem 0.4rem;
    margin-top: 0.25rem;
}

.sidebar-nav .nav-section:first-child {
    margin-top: 0;
    padding-top: 0.75rem;
}

.nav-accordion {
    margin: 0 0.35rem 0.2rem;
    border-radius: 10px;
}

.nav-accordion-toggle {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    width: 100%;
    padding: 0.55rem 0.7rem;
    border-radius: 10px;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
    cursor: pointer;
    list-style: none;
    user-select: none;
}

.nav-accordion-toggle::-webkit-details-marker {
    display: none;
}

.nav-accordion-toggle:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.nav-accordion-toggle > i:first-child {
    width: 1.25rem;
    text-align: center;
    font-size: 1.05rem;
    opacity: 0.9;
    flex-shrink: 0;
}

.nav-accordion-toggle > span {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nav-accordion-chevron {
    margin-left: auto;
    font-size: 0.78rem;
    opacity: 0.7;
    transition: transform 0.18s ease;
    flex-shrink: 0;
}

.nav-accordion[open] .nav-accordion-toggle {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.nav-accordion[open] .nav-accordion-chevron {
    transform: rotate(180deg);
}

.sidebar-nav .nav-group {
    margin-bottom: 0.25rem;
    padding: 0.1rem 0.15rem 0.35rem 0.7rem;
}

.sidebar .nav-link {
    position: relative;
    color: rgba(255, 255, 255, 0.72);
    border-radius: 0 22px 22px 0;
    padding: 0.55rem 0.875rem;
    margin-bottom: 1px;
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: all 0.18s ease;
    margin-right: 0.5rem;
}

.sidebar .nav-link span {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar .nav-link i {
    font-size: 1.05rem;
    width: 1.25rem;
    text-align: center;
    opacity: 0.9;
    flex-shrink: 0;
}

.sidebar .nav-link:hover:not(.soon) {
    color: #fff;
    background: rgba(255, 255, 255, 0.07);
}

.sidebar .nav-link.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.14);
    box-shadow: none;
    font-weight: 600;
}

.sidebar .nav-link.soon {
    opacity: 0.42;
    cursor: default;
    pointer-events: none;
}

.sidebar .nav-link.disabled {
    opacity: 0.4;
    pointer-events: none;
}

.sidebar .nav-link .badge-soon {
    margin-left: auto;
    font-size: 0.6rem;
    background: rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.6);
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
    font-weight: 500;
}

.nav-logout-form {
    margin: 0;
    padding: 0;
    width: 100%;
}

.sidebar .nav-link-logout {
    width: 100%;
    border: none;
    background: transparent;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
}

.sidebar .nav-link-logout:hover {
    color: #fff;
    background: rgba(239, 68, 68, 0.12);
}

/* Main content */
.main-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-width: 0;
    max-width: 100%;
    transition: margin-left 0.22s ease;
}

.top-header {
    height: var(--header-height);
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.75rem;
    position: sticky;
    top: 0;
    z-index: 1030;
    box-shadow: var(--shadow-sm);
}

.top-header .page-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.top-header-start {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 0.75rem;
    flex: 1 1 auto;
    min-width: 0;
}

.btn-branch-selector {
    background: var(--primary-light);
    color: var(--primary);
    border: 1px solid rgba(240, 90, 40, 0.25);
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.4rem 0.875rem;
}

.btn-branch-selector:hover,
.btn-branch-selector:focus {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.branch-selector .dropdown-item.active {
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 600;
}

.branch-selector .dropdown-item {
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
}

.top-header .user-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.top-header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.header-theme-btn {
    width: 2.4rem;
    height: 2.4rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--card-bg);
    color: var(--text-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
}

.header-theme-btn:hover {
    border-color: color-mix(in srgb, var(--primary) 40%, var(--border-color));
    color: var(--primary);
}

.header-theme-icon-sun {
    display: none;
}

html.theme-dark .header-theme-icon-moon {
    display: none;
}

html.theme-dark .header-theme-icon-sun {
    display: inline-block;
}

.logistics-credit-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    border: 1px solid rgba(245, 158, 11, 0.35);
    background: linear-gradient(180deg, #fffbeb 0%, #fef3c7 100%);
    color: #92400e;
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    box-shadow: 0 1px 2px rgba(146, 64, 14, 0.08);
}

.logistics-credit-badge:hover,
.logistics-credit-badge:focus {
    color: #78350f;
    border-color: rgba(245, 158, 11, 0.55);
    background: linear-gradient(180deg, #fef3c7 0%, #fde68a 100%);
}

.logistics-credit-badge i {
    font-size: 1rem;
    color: #d97706;
}

.logistics-credit-badge .logistics-credit-value {
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.logistics-credit-badge.is-low {
    border-color: rgba(220, 38, 38, 0.35);
    background: linear-gradient(180deg, #fef2f2 0%, #fee2e2 100%);
    color: #991b1b;
}

.logistics-credit-badge.is-low i {
    color: #dc2626;
}

.logistics-credit-badge.is-unlimited {
    border-color: rgba(22, 163, 74, 0.35);
    background: linear-gradient(180deg, #f0fdf4 0%, #dcfce7 100%);
    color: #166534;
}

.logistics-credit-badge.is-unlimited i {
    color: #16a34a;
}

@media (max-width: 575.98px) {
    .logistics-credit-badge .logistics-credit-label {
        display: none;
    }
}

.sidebar-toggle-btn {
    width: 40px;
    height: 40px;
    border: 1px solid var(--border-color);
    background: #fff;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    color: var(--text-primary);
    padding: 0;
    line-height: 1;
    box-shadow: var(--shadow-sm);
}

.sidebar-toggle-btn:hover,
.sidebar-toggle-btn:focus {
    background: #f8fafc;
    border-color: #d5dbe3;
    color: var(--text-primary);
}

.sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 1035;
}

.app-shell.sidebar-open .sidebar-backdrop {
    display: block;
}

.top-header .user-avatar {
    width: 36px;
    height: 36px;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
}

.main-content {
    padding: 1.75rem;
    flex: 1;
}

/* Cards */
.panel-card {
    background: var(--card-bg);
    border: 1px solid #D0D7E3;
    border-radius: var(--radius-lg);
    box-shadow:
        0 1px 2px rgba(26, 41, 64, 0.04),
        0 10px 28px rgba(26, 41, 64, 0.1);
}

.panel-card:has(.table-panel) {
    padding: 0.55rem;
    overflow: hidden;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    box-shadow:
        0 2px 4px rgba(26, 41, 64, 0.05),
        0 14px 32px rgba(26, 41, 64, 0.12);
}

.panel-card:has(.table-panel) > .card-header-custom {
    margin: 0 0.15rem 0.5rem;
    padding: 0.7rem 0.75rem 0.8rem;
    background: transparent;
    border-bottom: 1px solid #D8E0EA;
}

.panel-card:has(.table-panel) > .table-responsive {
    border-radius: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 0;
    box-shadow: none;
    max-height: none;
}

.orders-browse-page .orders-source-panel {
    scroll-margin-top: calc(var(--header-height, 64px) + 0.75rem);
}

.orders-browse-page a.order-source-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: inherit;
    text-decoration: none;
    cursor: pointer;
}

.orders-toolbar {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 18px;
    padding: 1rem 1.1rem 0.95rem;
    box-shadow:
        0 2px 4px rgba(26, 41, 64, 0.04),
        0 10px 24px rgba(26, 41, 64, 0.07);
}

.orders-toolbar-head {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.75rem 1rem;
    padding-bottom: 0.9rem;
    margin-bottom: 0.9rem;
    border-bottom: 1px solid var(--border-color);
}

.orders-toolbar-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.orders-filter-toggle {
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.orders-filter-toggle.is-open {
    background: #FFF4ED;
    border-color: #FDBA74;
    color: #C2410C;
}

.orders-filter-chevron {
    font-size: 0.72rem;
    transition: transform 0.18s ease;
}

.orders-filter-toggle.is-open .orders-filter-chevron {
    transform: rotate(180deg);
}

.orders-toolbar.is-collapsed .orders-filter-bar {
    display: none;
}

.orders-filter-bar {
    margin-bottom: 0.9rem;
    padding-bottom: 0.9rem;
    border-bottom: 1px solid #E8EEF5;
}

.orders-toolbar .orders-overview-kpis {
    margin-bottom: 0;
}

.orders-filter-summary {
    display: flex;
    align-items: center;
    margin-top: 0.7rem;
    padding: 0.45rem 0.7rem;
    border-radius: 10px;
    background: var(--surface-muted);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.82rem;
}

.orders-toolbar:not(.is-collapsed) .orders-filter-summary {
    display: none;
}

.orders-filter-main {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.75rem 1rem;
    align-items: end;
}

.orders-filter-cluster {
    display: grid;
    grid-template-columns: minmax(18rem, 22rem) minmax(0, 1fr);
    gap: 0.75rem 0.85rem;
    align-items: end;
    min-width: 0;
}

.orders-filter-dates {
    min-width: 0;
}

.orders-filter-section-label {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #64748B;
    margin-bottom: 0.4rem;
}

.orders-filter-dates-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.orders-filter-fields {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.5rem 0.55rem;
    align-items: end;
    min-width: 0;
}

.orders-filter-fields .cash-filter-field,
.orders-filter-dates .cash-filter-field {
    min-width: 0;
    width: 100%;
}

.orders-filter-fields .cash-filter-field .form-control,
.orders-filter-fields .cash-filter-field .form-select,
.orders-filter-dates .cash-filter-field .form-control,
.orders-filter-dates .cash-filter-field .form-select {
    min-width: 0;
    width: 100%;
}

.orders-filter-bar input[type="datetime-local"] {
    font-size: 0.78rem;
    padding-left: 0.4rem;
    padding-right: 0.25rem;
}

.orders-filter-actions {
    display: grid;
    grid-template-columns: auto auto;
    gap: 0.4rem;
}

.orders-filter-actions .cash-filter-btn {
    padding: 0.38rem 0.7rem;
    font-size: 0.78rem;
    min-height: 31px;
    white-space: nowrap;
}

.orders-filter-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1rem;
    margin-top: 0.9rem;
    padding-top: 0.85rem;
    border-top: 1px solid #E8EEF5;
}

.orders-filter-footer .order-exclude-filter {
    flex: 1 1 22rem;
    width: auto;
    margin: 0;
    padding: 0;
    border: none;
    align-self: center;
}

.orders-filter-period {
    display: flex;
    align-items: center;
    margin-top: 0.8rem;
    padding: 0.55rem 0.75rem;
    border-radius: 10px;
    background: var(--surface-muted);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.82rem;
}

@media (max-width: 1199.98px) {
    .orders-filter-main {
        grid-template-columns: 1fr;
    }

    .orders-filter-cluster {
        grid-template-columns: 1fr;
    }

    .orders-filter-fields {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .orders-filter-search {
        grid-column: span 2;
    }

    .orders-filter-actions {
        justify-content: start;
        width: max-content;
    }
}

@media (max-width: 767.98px) {
    .orders-toolbar {
        padding: 0.85rem 0.8rem;
        border-radius: 14px;
    }

    .orders-filter-fields {
        grid-template-columns: 1fr 1fr;
    }

    .orders-filter-search {
        grid-column: 1 / -1;
    }

    .orders-filter-actions {
        width: 100%;
        grid-template-columns: 1fr 1fr;
    }
}

.orders-overview {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 18px;
    padding: 1rem 1.1rem 1.15rem;
    box-shadow:
        0 2px 4px rgba(26, 41, 64, 0.04),
        0 10px 24px rgba(26, 41, 64, 0.07);
}

.orders-overview-kpis {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.7rem;
    margin-bottom: 0.9rem;
}

.orders-kpi {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-height: 76px;
    padding: 0.8rem 0.95rem;
    background: var(--surface-muted);
    border: 1px solid var(--border-color);
    border-radius: 14px;
}

.orders-kpi-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    flex-shrink: 0;
}

.orders-kpi-body {
    min-width: 0;
}

.orders-kpi .label {
    display: block;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.12rem;
}

.orders-kpi strong {
    display: block;
    font-size: 1.12rem;
    font-weight: 800;
    line-height: 1.2;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.orders-overview-kpis.is-five {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.orders-kpi.is-count .orders-kpi-icon { background: #EEF2FF; color: #4F46E5; }
.orders-kpi.is-total .orders-kpi-icon { background: #FFF4ED; color: #EA580C; }
.orders-kpi.is-discount .orders-kpi-icon { background: #F5F3FF; color: #7C3AED; }
.orders-kpi.is-paid .orders-kpi-icon { background: #ECFDF5; color: #16A34A; }
.orders-kpi.is-expense .orders-kpi-icon { background: #FEF2F2; color: #DC2626; }
.orders-kpi.is-discount strong { color: #7C3AED; }
.orders-kpi.is-paid strong { color: #16A34A; }
.orders-kpi.is-expense strong { color: #DC2626; }

.orders-overview-sources {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(156px, 1fr));
    gap: 0.7rem;
}

.orders-overview .order-source-card {
    background: var(--surface-muted);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 0.95rem 0.7rem 0.85rem;
    box-shadow: none;
    min-height: 148px;
    color: var(--text-primary);
}

.orders-overview .order-source-card.has-orders {
    border-color: var(--border-color);
    background: var(--surface-muted);
}

.orders-overview .order-source-card.source-qr {
    background: var(--surface-muted);
    color: inherit;
}

.panel-card.orders-source-panel.source-qr {
    background: var(--card-bg);
    color: inherit;
}

@media (max-width: 1199.98px) {
    .orders-overview-kpis.is-five {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 991.98px) {
    .orders-overview-kpis,
    .orders-overview-kpis.is-five {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .orders-overview {
        padding: 0.8rem;
        border-radius: 14px;
    }

    .orders-overview-kpis,
    .orders-overview-sources {
        gap: 0.55rem;
    }

    .orders-kpi {
        min-height: 68px;
        padding: 0.7rem 0.75rem;
        gap: 0.55rem;
    }

    .orders-kpi strong {
        font-size: 0.98rem;
    }
}

/* Standalone grid wrappers (no panel-card) */
.table-responsive:has(> .table-panel) {
    background: #fff;
    border: 1px solid #C5CEDB;
    border-radius: 14px;
    padding: 0.4rem;
    box-shadow:
        0 2px 4px rgba(26, 41, 64, 0.05),
        0 12px 28px rgba(26, 41, 64, 0.1);
}

.panel-card .card-header-custom {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.panel-card .card-body-custom {
    padding: 1.5rem;
}

/* Stat cards */
.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1.375rem 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
    height: 100%;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.stat-card .stat-label {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 0.5rem;
}

.stat-card .stat-value {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1;
    color: var(--text-primary);
}

.stat-card .stat-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.stat-card .stat-icon.primary { background: var(--primary-light); color: var(--primary); }
.stat-card .stat-icon.success { background: #ECFDF5; color: #10B981; }
.stat-card .stat-icon.danger { background: #FEF2F2; color: #EF4444; }
.stat-card .stat-icon.warning { background: #FFFBEB; color: #F59E0B; }

/* Module cards */
.module-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1.5rem 1rem;
    text-align: center;
    transition: all 0.2s;
    height: 100%;
}

a.module-card {
    display: block;
    text-decoration: none;
    color: inherit;
}

.module-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}

.module-card.disabled {
    opacity: 0.55;
}

.module-card .module-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 0.875rem;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.module-card.disabled .module-icon {
    background: #F1F5F9;
    color: var(--text-muted);
}

.module-card .module-title {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.module-card .module-status {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Tables — distinct bordered grid (POS product grids are separate; do not couple) */
.table-panel {
    margin: 0;
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: #fff;
    border: none;
    border-radius: 12px;
    overflow: hidden;
}

.table-panel thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: linear-gradient(180deg, #ffffff 0%, #eef2f6 46%, #d9e0e8 100%);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
    color: #111;
    border-bottom: 1px solid #c5ced8;
    border-right: 1px solid #c5ced8;
    padding: 0.72rem 0.8rem;
    white-space: nowrap;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.7);
    box-shadow:
        inset 0 1px 0 #fff,
        inset 0 -1px 0 #c5ced8,
        0 2px 3px rgba(15, 23, 42, 0.12);
}

.table-panel thead th:first-child {
    border-top-left-radius: 12px;
}

.table-panel thead th:last-child {
    border-right: none;
    border-top-right-radius: 12px;
}

.table-panel tbody tr {
    transition: background 0.12s ease;
}

.table-panel tbody td {
    padding: 0.55rem 0.7rem;
    vertical-align: middle;
    font-size: 0.9rem;
    font-weight: 500;
    color: #000;
    border-bottom: 1px dashed #c5ced8;
    border-right: 1px solid #c5ced8;
    background: #fff;
    border-top: none;
    border-left: none;
    border-radius: 0;
}

.table-panel tbody td:last-child {
    border-right: none;
}

.table-panel tbody td:first-child {
    border-left: 1px solid #c5ced8;
}

.table-panel tbody td:last-child {
    border-right: 1px solid #c5ced8;
}

.table-panel tbody tr:nth-child(odd) td {
    background: #fff;
}

.table-panel tbody tr:nth-child(even) td {
    background: #e8eef4;
}

.table-panel tbody tr:hover,
.table-panel tbody tr:hover td {
    background: #fff7f2;
    box-shadow: none;
}

.table-panel tbody tr:last-child td {
    border-bottom: none;
}

.table-panel tbody tr:last-child td:first-child {
    border-bottom-left-radius: 12px;
}

.table-panel tbody tr:last-child td:last-child {
    border-bottom-right-radius: 12px;
}

/* Customers */
.customers-page-header {
    margin-bottom: 1rem;
}

.customers-page-title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.customers-page-title {
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--text-primary);
}

.customers-count {
    font-weight: 500;
    color: var(--text-secondary);
}

.customers-page-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.customers-page-actions .badge {
    color: #fff !important;
    background: #64748b !important;
}

.customers-panel {
    padding: 0;
    overflow: hidden;
}

.customers-search-form {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
    background: #fff;
}

.customers-search-wrap {
    position: relative;
    max-width: 100%;
}

.customers-search-input {
    padding-right: 2.75rem;
    border-radius: 8px;
    border-color: var(--border-color);
    font-size: 0.9rem;
}

.customers-search-input:focus {
    border-color: var(--brand);
    box-shadow: 0 0 0 0.15rem rgba(240, 90, 40, 0.15);
}

.customers-search-btn {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    color: var(--text-muted);
    padding: 0.25rem 0.5rem;
    line-height: 1;
}

.customers-table .col-status {
    width: 36px;
    padding-left: 1.25rem !important;
    padding-right: 0 !important;
}

.customers-table .col-actions {
    width: 40px;
    padding-right: 1rem !important;
}

.customer-status-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #CBD5E1;
}

.customer-status-dot.active {
    background: #10B981;
}

.customer-status-dot.inactive {
    background: #E11D48;
}

.customer-row {
    cursor: pointer;
}

.customer-name {
    font-weight: 500;
}

.customer-balance-negative {
    color: #DC2626;
}

.customer-balance-positive {
    color: var(--text-primary);
}

/* Customer form */
.customer-form-page {
    max-width: 860px;
}

.customer-form-page-header {
    padding-top: 0.25rem;
}

.customer-form-back {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.8125rem;
    color: var(--text-muted);
    text-decoration: none;
    margin-bottom: 0.75rem;
}

.customer-form-back:hover {
    color: var(--brand);
}

.customer-form-card .card-body-custom {
    padding: 0;
}

.customer-form-card form {
    padding: 1.5rem;
}

.customer-form-section {
    padding-bottom: 1.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.customer-form-section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.customer-form-section-title {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.customer-form-actions {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border-color);
}

.customer-active-switch {
    padding: 0.75rem 1rem;
    background: #F8FAFC;
    border: 1px solid var(--border-color);
    border-radius: 10px;
}

.input-icon-wrap {
    position: relative;
}

.input-icon-wrap .input-icon {
    position: absolute;
    left: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.9rem;
    pointer-events: none;
    z-index: 2;
}

.input-icon-wrap .input-with-icon {
    padding-left: 2.5rem;
}

.customer-form-card .input-group-text {
    background: #F8FAFC;
    border-color: var(--border-color);
    color: var(--text-secondary);
}

.customer-form-card .form-text {
    font-size: 0.75rem;
    margin-top: 0.35rem;
}

.customer-addresses-list {
    display: flex;
    flex-direction: column;
    gap: 0.875rem;
}

.customer-address-item {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0.875rem 1rem;
    background: #F8FAFC;
}

.customer-address-item-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.customer-address-item-head .list-sort-handle {
    flex: 0 0 auto;
}

.customer-address-item-label {
    flex: 1;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-primary);
}

.customer-address-default {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.85rem;
    margin-bottom: 0;
    cursor: pointer;
}

.customer-address-default input[type="radio"] {
    margin: 0;
}

/* Current accounts */
.current-accounts-page {
    max-width: 100%;
}

.current-accounts-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.current-accounts-title {
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
}

.current-accounts-count {
    font-weight: 500;
    color: var(--text-secondary);
}

.current-accounts-add-btn {
    border-radius: 8px;
    font-weight: 500;
}

.current-accounts-summary {
    padding: 0;
    overflow: hidden;
}

.current-accounts-summary-title {
    padding: 1rem 1.25rem;
    font-weight: 600;
    font-size: 0.95rem;
    border-bottom: 1px solid var(--border-color);
    background: #fff;
}

.current-accounts-summary-table td {
    padding: 0.75rem 1.25rem;
    font-size: 0.875rem;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.current-accounts-summary-table tr:last-child td {
    border-bottom: none;
}

.current-accounts-summary-table .summary-total-row td {
    background: #F8FAFC;
}

.current-accounts-panel {
    padding: 0;
    overflow: hidden;
}

.current-accounts-table tbody tr:nth-child(even) {
    background: #FAFBFC;
}

.current-account-row {
    cursor: pointer;
}

.current-account-title {
    font-weight: 600;
}

.current-account-balance {
    color: #991B1B;
}

/* Customer account payment & manual debt */
.customer-account-payment-page,
.current-accounts-page {
    color: var(--text-primary);
}

.customer-account-payment-page .form-control,
.customer-account-payment-page .form-select,
.current-accounts-page .form-control,
.current-accounts-page .form-select,
#addDebtModal .form-control,
#addDebtModal .form-select,
#addDebtModal textarea {
    color: var(--text-primary);
    background-color: #fff;
}

.customer-account-payment-page .btn-primary,
.current-accounts-page .btn-primary,
#addDebtModal .btn-primary {
    color: #fff !important;
    background-color: var(--primary) !important;
    border-color: var(--primary) !important;
}

.customer-account-payment-page .btn-primary:hover,
.current-accounts-page .btn-primary:hover,
#addDebtModal .btn-primary:hover {
    color: #fff !important;
    background-color: var(--primary-dark) !important;
    border-color: var(--primary-dark) !important;
}

.cari-pay-btn {
    color: #fff !important;
    background-color: var(--primary) !important;
    border-color: var(--primary) !important;
    font-weight: 600;
}

.cari-submit-btn {
    color: #fff !important;
    background: linear-gradient(145deg, #22C55E, #16A34A) !important;
    border-color: #16A34A !important;
    font-weight: 700;
    padding: 0.75rem 1rem;
    border-radius: 10px;
}

.cari-submit-btn:hover {
    color: #fff !important;
    background: linear-gradient(145deg, #16A34A, #15803D) !important;
    border-color: #15803D !important;
}

.cari-manual-debt-row {
    background: #FFFBEB !important;
}

.cari-manual-debt-row td {
    color: var(--text-primary) !important;
}

.badge-cari-manual {
    background: #FEF3C7;
    color: #92400E !important;
    border: 1px solid #FCD34D;
    font-weight: 600;
}

#addDebtModal .customer-search-wrap {
    position: relative;
}

#addDebtModal .customer-search-results {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    z-index: 1056;
}

#addDebtModal .customer-search-item strong {
    color: var(--text-primary);
}

#addDebtModal .customer-search-item span {
    color: var(--text-muted);
}

/* Alerts */
.alert {
    border-radius: 10px;
    font-size: 0.875rem;
    border: none;
}

.alert-success {
    background: #ECFDF5;
    color: #065F46;
}

/* Badges */
.badge {
    font-weight: 500;
    font-size: 0.75rem;
    padding: 0.35em 0.65em;
    border-radius: 6px;
}

/* Login page */
.login-page {
    min-height: 100vh;
    display: flex;
    background: var(--body-bg);
}

.login-brand-panel {
    flex: 1;
    background: linear-gradient(145deg, var(--sidebar-bg) 0%, var(--navy-light) 50%, #0D1520 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3rem 4rem;
    position: relative;
    overflow: hidden;
}

.login-brand-panel::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, color-mix(in srgb, var(--primary) 22%, transparent) 0%, transparent 70%);
    border-radius: 50%;
}

.login-brand-panel::after {
    content: '';
    position: absolute;
    bottom: -15%;
    left: -5%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, color-mix(in srgb, var(--primary) 14%, transparent) 0%, transparent 70%);
    border-radius: 50%;
}

.login-brand-content {
    position: relative;
    z-index: 1;
    max-width: 480px;
}

.login-brand-content .brand-logo-lg {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.login-brand-content .brand-icon-lg {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary) 0%, #FF8A5C 100%);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.5rem;
}

.login-brand-content h1 {
    color: #fff;
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 1rem;
}

.login-brand-content h1 span {
    color: var(--primary);
}

.login-brand-content .lead-text {
    color: rgba(255, 255, 255, 0.65);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 2.5rem;
}

.login-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.login-features li {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    padding: 0.5rem 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.login-features li i {
    color: var(--primary);
    font-size: 1rem;
}

.login-stats {
    display: flex;
    gap: 2rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.login-stats .stat-item strong {
    display: block;
    color: #fff;
    font-size: 1.5rem;
    font-weight: 700;
}

.login-stats .stat-item span {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
}

.login-form-panel {
    width: 480px;
    min-width: 480px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: #fff;
}

.login-card {
    width: 100%;
    max-width: 380px;
    border: none;
    background: transparent;
}

.login-card .login-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.375rem;
}

.login-card .login-subtitle {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 2rem;
}

.login-home-link a {
    color: var(--text-secondary);
    font-size: 0.875rem;
    text-decoration: none;
    font-weight: 500;
}

.login-home-link a:hover {
    color: var(--primary);
}

.role-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
    margin-bottom: 1.75rem;
}

.role-badges .role-badge {
    font-size: 0.7rem;
    font-weight: 500;
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    background: #F1F5F9;
    color: var(--text-secondary);
}

.login-demo-hint {
    margin-top: 1.5rem;
    padding: 0.875rem 1rem;
    background: #F8FAFC;
    border-radius: 10px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-align: center;
    border: 1px solid var(--border-color);
}

.login-demo-hint strong {
    color: var(--text-primary);
}

/* Page header actions */
.page-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* License plan cards */
.plan-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    height: 100%;
    transition: all 0.2s;
}

.plan-card:hover {
    box-shadow: var(--shadow-md);
    border-color: rgba(240, 90, 40, 0.3);
}

.plan-card.inactive {
    opacity: 0.6;
}

.plan-card .plan-header {
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.plan-card .plan-price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.plan-card .plan-price small {
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--text-muted);
}

.plan-card .plan-features {
    list-style: none;
    padding: 1.25rem 1.5rem;
    margin: 0;
}

.plan-card .plan-features li {
    padding: 0.375rem 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.plan-card .plan-features li i {
    color: #10B981;
}

.plan-card .plan-footer {
    padding: 1rem 1.5rem 1.5rem;
    border-top: 1px solid var(--border-color);
}

/* Responsive */
/* KPI cards — dashboard homepage */
.kpi-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1.25rem 1rem 1.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    height: 100%;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}

.kpi-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.kpi-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40px;
    background: linear-gradient(180deg, transparent 0%, rgba(240, 90, 40, 0.06) 100%);
    pointer-events: none;
}

.kpi-card .kpi-icon {
    width: 44px;
    height: 44px;
    margin: 0 auto 0.75rem;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    position: relative;
    z-index: 1;
}

.kpi-card .kpi-value {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
    position: relative;
    z-index: 1;
}

.kpi-card .kpi-label {
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-top: 0.35rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    position: relative;
    z-index: 1;
}

.chart-container {
    position: relative;
    min-height: 320px;
}

.chart-year-select {
    width: 100px;
    border-radius: 8px;
    font-size: 0.875rem;
}

.chart-legend .legend-item {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.chart-legend .legend-dot {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 3px;
    margin-right: 6px;
    vertical-align: middle;
}

.chart-legend .legend-dot.income { background: rgba(16, 185, 129, 0.85); }
.chart-legend .legend-dot.expense { background: rgba(239, 68, 68, 0.9); }

.dashboard-year-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 1.5rem;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    background: var(--bg-secondary, #f8fafc);
    border: 1px solid var(--border-color, #e2e8f0);
}

.dashboard-year-summary-item {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    min-width: 120px;
}

.dashboard-year-summary-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.dashboard-net-positive {
    color: #059669;
}

.dashboard-net-negative {
    color: #dc2626;
}

.dashboard-monthly-table td,
.dashboard-monthly-table th {
    white-space: nowrap;
}

/* Menu management */
.menu-thumb {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.menu-thumb-placeholder {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    background: #F1F5F9;
    color: #94A3B8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.media-name-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: 100%;
    height: 100%;
    padding: 0.3rem;
    text-align: center;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1.15;
    color: #334155;
    background: #F1F5F9;
    overflow: hidden;
    word-break: break-word;
}

.menu-thumb.media-name-fallback {
    width: 48px;
    height: 48px;
    font-size: 0.58rem;
    object-fit: unset;
}

.menu-sort-col {
    width: 36px;
}

.menu-sort-handle {
    text-align: center;
    vertical-align: middle;
}

.menu-sort-handle.menu-sort-disabled {
    cursor: not-allowed;
}

tr.menu-sort-dragging {
    background: #f8fafc;
}

.image-upload-box .menu-thumb {
    width: 100%;
    max-width: 220px;
    height: 160px;
}

.branch-check-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.5rem 1rem;
    padding: 0.75rem 1rem;
    background: #F8FAFC;
    border-radius: 10px;
    border: 1px solid var(--border-color);
}

.branch-scope-options {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 0.5rem;
}

/* Day operations */
.day-status-card {
    display: block;
    border-radius: var(--radius);
    padding: 1.75rem;
    box-shadow: var(--shadow-md);
}

.day-status-card.active {
    background: linear-gradient(135deg, #1B2537 0%, #2D3E56 55%, #F05A28 160%);
    color: #fff;
}

.day-status-card.closed {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
}

.day-status-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.day-status-badge.open {
    background: rgba(16, 185, 129, 0.2);
    color: #6EE7B7;
}

.day-status-badge.closed {
    background: #F1F5F9;
    color: #64748B;
}

.day-pulse-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #10B981;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6);
    animation: dayPulse 2s infinite;
}

@keyframes dayPulse {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.5); }
    70% { box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.day-live-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.65rem;
}

.day-live-stat {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 0.875rem 1rem;
    text-align: center;
}

.day-live-stat.highlight {
    background: rgba(240, 90, 40, 0.2);
    border-color: rgba(240, 90, 40, 0.35);
}

.day-live-stat.is-discount .value {
    color: #FECACA;
}

.day-live-stat .label {
    display: block;
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.65);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0.25rem;
}

.day-live-stat .value {
    display: block;
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
}

.day-action-btn {
    border: none;
    border-radius: var(--radius);
    padding: 1.5rem 1.25rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    min-height: 130px;
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: pointer;
    text-align: center;
}

.day-action-btn i {
    font-size: 2rem;
}

.day-action-btn span {
    font-size: 1.05rem;
    font-weight: 700;
}

.day-action-btn small {
    font-size: 0.78rem;
    opacity: 0.85;
}

.day-action-btn.start {
    background: linear-gradient(145deg, #F8FAFC, #E2E8F0);
    color: #334155;
    border: 1px solid var(--border-color);
}

.day-action-btn.start:not(.disabled):hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    background: linear-gradient(145deg, #fff, #F1F5F9);
}

.day-action-btn.end {
    background: linear-gradient(145deg, #EF4444, #DC2626);
    color: #fff;
    box-shadow: 0 8px 24px rgba(239, 68, 68, 0.25);
}

.day-action-btn.end:not(.disabled):hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(239, 68, 68, 0.35);
}

.day-action-btn.disabled {
    opacity: 0.45;
    cursor: not-allowed;
    box-shadow: none;
}

.day-history-table .day-row-active {
    background: rgba(240, 90, 40, 0.04);
}

.day-history-row {
    cursor: pointer;
    transition: background 0.12s;
}

.day-history-row:hover {
    background: rgba(37, 99, 235, 0.05);
}

.day-clickable {
    cursor: pointer;
    transition: transform 0.12s, box-shadow 0.12s;
}

.day-clickable:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.day-view-orders-btn {
    display: inline-flex;
    align-items: center;
    font-size: 0.78rem;
    font-weight: 600;
    color: #fff !important;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.22);
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    transition: background 0.12s, border-color 0.12s;
    white-space: nowrap;
}

.day-view-orders-btn:hover {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.35);
}

.day-view-orders-hint {
    margin-left: auto;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.75);
    background: rgba(255, 255, 255, 0.12);
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
}

.day-ops-loading,
.day-ops-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 3rem 1.5rem;
    color: var(--text-muted);
    text-align: center;
}

.day-ops-empty i {
    font-size: 2.5rem;
    opacity: 0.45;
}

.day-orders-table tbody tr.day-order-row,
.day-orders-table tbody tr.day-order-row-link {
    cursor: pointer;
}

.day-orders-table tbody tr.day-order-row:hover,
.day-orders-table tbody tr.day-order-row-link:hover {
    background: rgba(37, 99, 235, 0.05);
}

.day-orders-total-row {
    background: #F8FAFC;
    font-size: 0.9rem;
}

.day-orders-total-row td {
    border-top: 2px solid var(--border-color);
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

.text-purple {
    color: #9333EA !important;
}

.day-order-status,
.order-status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.28rem 0.7rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
    border: none;
    color: #fff;
}

.day-order-status.is-wrap,
.order-status-badge.is-wrap,
.order-status-pill.is-wrap {
    display: inline-block;
    white-space: pre-line;
    height: auto;
    min-height: 30px;
    padding: 0.32rem 0.55rem;
    border-radius: 12px;
    text-align: center;
}

.day-order-status.waiting,
.order-status-pill.waiting { background: var(--status-waiting, #D97706); color: #fff; }
.day-order-status.preparing,
.order-status-pill.preparing { background: var(--status-preparing, #F97316); color: #fff; }
.day-order-status.ready,
.order-status-pill.ready { background: var(--status-ready, #7C3AED); color: #fff; }
.day-order-status.ontheway,
.order-status-pill.ontheway { background: var(--status-ontheway, #2563EB); color: #fff; }
.day-order-status.completed,
.order-status-pill.completed { background: var(--status-completed, #15803D); color: #fff; }
.day-order-status.cancelled,
.order-status-pill.cancelled { background: var(--status-cancelled, #DC2626); color: #fff; }

.order-status-select,
.order-status-select.form-select {
    min-width: 8.5rem;
    max-width: 12rem;
    border: none !important;
    box-shadow: none !important;
    font-weight: 800;
    font-size: 0.86rem;
    line-height: 1.25;
    padding: 0.4rem 1.9rem 0.4rem 0.7rem !important;
    cursor: pointer;
    color: #fff !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23ffffff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e") !important;
    background-repeat: no-repeat !important;
    background-position: right 0.55rem center !important;
    background-size: 12px 10px !important;
}

.order-status-select.day-order-status.waiting { background-color: var(--status-waiting, #D97706) !important; }
.order-status-select.day-order-status.preparing { background-color: var(--status-preparing, #F97316) !important; }
.order-status-select.day-order-status.ready { background-color: var(--status-ready, #7C3AED) !important; }
.order-status-select.day-order-status.ontheway { background-color: var(--status-ontheway, #2563EB) !important; }
.order-status-select.day-order-status.completed { background-color: var(--status-completed, #15803D) !important; }
.order-status-select.day-order-status.cancelled { background-color: var(--status-cancelled, #DC2626) !important; }

.order-status-select:disabled {
    opacity: 0.7;
    cursor: wait;
}

.order-status-cell {
    min-width: 11rem;
    vertical-align: middle;
    padding: 5px !important;
    background: transparent !important;
}

.table-panel tbody tr td.order-status-cell,
.table-panel tbody tr:nth-child(even) td.order-status-cell,
.table-panel tbody tr:nth-child(odd) td.order-status-cell,
.table-panel tbody tr:hover td.order-status-cell,
.table-panel tbody tr.all-orders-row:hover td.order-status-cell {
    background: transparent !important;
}

.order-status-panel {
    --status-panel-bg: #64748b;
    --status-panel-fg: #fff;
    display: block;
    margin: 0;
    padding: 0.5rem 0.55rem;
    border-radius: 10px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
    background: var(--status-panel-bg);
    color: var(--status-panel-fg);
    min-height: 100%;
}

.order-status-panel.is-status-waiting {
    --status-panel-bg: var(--status-waiting, #D97706);
    --status-panel-font: var(--status-font-waiting, 0.9rem);
}
.order-status-panel.is-status-preparing {
    --status-panel-bg: var(--status-preparing, #F97316);
    --status-panel-font: var(--status-font-preparing, 0.9rem);
}
.order-status-panel.is-status-ready {
    --status-panel-bg: var(--status-ready, #7C3AED);
    --status-panel-font: var(--status-font-ready, 0.9rem);
}
.order-status-panel.is-status-ontheway {
    --status-panel-bg: var(--status-ontheway, #2563EB);
    --status-panel-font: var(--status-font-ontheway, 0.9rem);
}
.order-status-panel.is-status-completed {
    --status-panel-bg: var(--status-completed, #15803D);
    --status-panel-font: var(--status-font-completed, 0.9rem);
}
.order-status-panel.is-status-cancelled {
    --status-panel-bg: var(--status-cancelled, #DC2626);
    --status-panel-font: var(--status-font-cancelled, 0.9rem);
}

.order-status-panel .status-stack {
    gap: 0.4rem;
}

.order-status-panel .all-orders-status {
    min-width: 0;
    width: 100%;
}

.order-status-panel .day-order-status,
.order-status-panel .order-status-badge,
.order-status-panel .order-status-select.day-order-status,
.order-status-panel .order-status-select.form-select.day-order-status {
    background-color: rgba(0, 0, 0, 0.22) !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23ffffff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e") !important;
    background-repeat: no-repeat !important;
    background-position: right 0.55rem center !important;
    background-size: 12px 10px !important;
    color: #fff !important;
    border: 1px solid rgba(255, 255, 255, 0.35) !important;
    box-shadow: none !important;
    font-size: var(--status-panel-font, 0.9rem) !important;
    font-weight: 800 !important;
    letter-spacing: 0.01em;
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.25);
    -webkit-appearance: none !important;
    appearance: none !important;
}

.day-order-status.waiting,
.order-status-pill.waiting { font-size: var(--status-font-waiting, 0.9rem); }
.day-order-status.preparing,
.order-status-pill.preparing { font-size: var(--status-font-preparing, 0.9rem); }
.day-order-status.ready,
.order-status-pill.ready { font-size: var(--status-font-ready, 0.9rem); }
.day-order-status.ontheway,
.order-status-pill.ontheway { font-size: var(--status-font-ontheway, 0.9rem); }
.day-order-status.completed,
.order-status-pill.completed { font-size: var(--status-font-completed, 0.9rem); }
.day-order-status.cancelled,
.order-status-pill.cancelled { font-size: var(--status-font-cancelled, 0.9rem); }

.order-status-panel .order-status-badge,
.order-status-panel span.day-order-status {
    background-image: none !important;
    padding-right: 0.75rem !important;
}

.order-status-panel .order-status-select.day-order-status {
    flex: 1 1 auto;
    min-width: 0;
    width: auto;
    max-width: none;
}

.order-status-panel .order-status-select.day-order-status.waiting,
.order-status-panel .order-status-select.day-order-status.preparing,
.order-status-panel .order-status-select.day-order-status.ready,
.order-status-panel .order-status-select.day-order-status.ontheway,
.order-status-panel .order-status-select.day-order-status.completed,
.order-status-panel .order-status-select.day-order-status.cancelled {
    background-color: rgba(0, 0, 0, 0.22) !important;
}

.order-status-panel .order-status-select.day-order-status option {
    color: #111827;
    background: #fff;
}

.order-status-panel .order-timing,
.order-status-panel .order-age,
.order-status-panel .dispatch-note {
    background: rgba(255, 255, 255, 0.2) !important;
    color: #fff !important;
    border: 1px solid rgba(255, 255, 255, 0.35) !important;
    font-weight: 700;
    font-size: 0.78rem;
}

.order-status-panel .all-orders-source {
    background: rgba(0, 0, 0, 0.28) !important;
    color: #fff !important;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.order-status-panel .all-orders-source.tone-phone,
.order-status-panel .all-orders-source.tone-web,
.order-status-panel .all-orders-source.tone-ys,
.order-status-panel .all-orders-source.tone-getir,
.order-status-panel .all-orders-source.tone-trendyol,
.order-status-panel .all-orders-source.tone-migros,
.order-status-panel .all-orders-source.tone-tikla,
.order-status-panel .all-orders-source.tone-other {
    background: rgba(0, 0, 0, 0.28) !important;
    color: #fff !important;
}

.order-status-actions .order-status-btn {
    min-width: 6.5rem;
}

.order-detail-status-block {
    flex: 1 1 auto;
}

.day-order-detail-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
}

.day-order-stat {
    background: #F8FAFC;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 0.75rem;
    text-align: center;
}

.day-order-stat .label {
    display: block;
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
}

.day-order-stat strong {
    font-size: 1.05rem;
}

.day-order-stat.discount strong { color: #9333EA; }
.day-order-stat.paid strong { color: #16A34A; }
.day-order-stat.remaining strong { color: #DC2626; }
.day-order-stat.expense strong { color: #DC2626; }

.day-order-section-title {
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.day-order-timeline {
    list-style: none;
    margin: 0;
    padding: 0;
}

.day-order-timeline-item {
    display: flex;
    gap: 0.75rem;
    padding: 0.65rem 0;
    border-bottom: 1px solid #F1F5F9;
}

.day-order-timeline-item:last-child {
    border-bottom: none;
}

.day-order-timeline-icon {
    width: 28px;
    flex-shrink: 0;
    text-align: center;
    padding-top: 0.1rem;
}

.day-order-timeline-text {
    font-size: 0.88rem;
    font-weight: 600;
}

.day-order-timeline-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.15rem;
}

.day-order-detail-info {
    background: #F8FAFC;
    border-radius: 10px;
    padding: 0.875rem 1rem;
    font-size: 0.88rem;
}

@media (max-width: 767.98px) {
    .day-order-detail-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.day-ops-icon-lg {
    width: 72px;
    height: 72px;
    margin: 0 auto;
    border-radius: 18px;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
}

.day-ops-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: #F1F5F9;
    color: #64748B;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.branch-pick-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1.25rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    text-decoration: none;
    color: var(--text-primary);
    background: var(--card-bg);
    transition: all 0.2s;
    height: 100%;
}

.branch-pick-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    color: var(--primary);
    transform: translateY(-2px);
}

.branch-pick-card i {
    font-size: 1.5rem;
    color: var(--primary);
}

@media (max-width: 767.98px) {
    .day-live-stats {
        grid-template-columns: 1fr 1fr;
    }
}

/* Orders list */
.orders-page-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
}

.orders-page-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text-primary);
}

.orders-page-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.orders-filter-bar .cash-filter-field .form-control[type="date"] {
    min-width: 10.5rem;
}

.orders-quick-filter {
    font-weight: 600;
}

.data-grid-pagination-wrap {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-top: 1px solid var(--border-color);
    background: var(--surface-muted);
}

.data-grid-pagination-info {
    font-size: 0.78rem;
    color: var(--text-secondary);
}

.data-grid-pagination .page-link {
    min-width: 2rem;
    text-align: center;
    color: var(--text-primary);
    border-color: var(--border-color);
    background-color: var(--card-bg);
}

.data-grid-pagination .page-item.active .page-link {
    background-color: var(--primary);
    border-color: var(--primary);
    color: #fff;
    font-weight: 600;
    z-index: 2;
}

.data-grid-pagination .page-item.active .page-link:hover,
.data-grid-pagination .page-item.active .page-link:focus {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
    color: #fff;
}

.order-source-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1rem 0.875rem;
    text-align: center;
    height: 100%;
    position: relative;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}

.order-source-card:not(.soon):hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.order-source-card.soon {
    opacity: 0.72;
}

.integration-soon-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 0.58rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    background: #F1F5F9;
    color: #64748B;
    padding: 0.15rem 0.4rem;
    border-radius: 999px;
}

.source-card-icon {
    width: 42px;
    height: 42px;
    margin: 0 auto 0.5rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: #fff;
}

.source-card-icon.has-logo {
    background: #fff !important;
    border: 1px solid #E2E8F0;
    padding: 5px;
}

.source-card-icon .platform-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.platform-logo-inline {
    width: 22px;
    height: 22px;
    object-fit: contain;
    vertical-align: middle;
}

.marketplace-config-logo {
    width: 32px;
    height: 32px;
    object-fit: contain;
    flex-shrink: 0;
}

.platform-col-header {
    white-space: nowrap;
    vertical-align: middle;
}

.platform-col-logo {
    width: 20px;
    height: 20px;
    object-fit: contain;
    margin-right: 0.35rem;
    vertical-align: middle;
}

.order-source-badge.has-logo {
    background: #fff !important;
    border: 1px solid #E2E8F0;
    padding: 2px 4px;
}

.order-source-badge .platform-logo {
    width: 16px;
    height: 16px;
    object-fit: contain;
    display: block;
}

.source-card-name {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    min-height: 2.2em;
    line-height: 1.2;
}

.source-card-meta {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    font-size: 0.72rem;
    color: var(--text-secondary);
}

.source-card-amount {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-primary);
}

.order-source-card.source-table .source-card-icon { background: linear-gradient(135deg, #FF8C42, var(--primary)); }
.order-source-card.source-website .source-card-icon { background: linear-gradient(135deg, #F59E0B, #D97706); }

.order-channel-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1.125rem 1.25rem;
    height: 100%;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.order-channel-card.channel-table {
    border-left: 4px solid #FF8C42;
}

.order-channel-card.channel-webapp {
    border-left: 4px solid #F59E0B;
}

.order-channel-card-head {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    min-width: 0;
}

.order-channel-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.order-channel-card.channel-table .order-channel-card-icon {
    background: linear-gradient(135deg, #FF8C42, var(--primary));
}

.order-channel-card.channel-webapp .order-channel-card-icon {
    background: linear-gradient(135deg, #F59E0B, #D97706);
}

.order-channel-card-title {
    font-weight: 700;
    font-size: 1rem;
    line-height: 1.2;
}

.order-channel-card-subtitle {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.25rem;
    color: var(--text-muted);
    font-size: 0.875rem;
}

.order-channel-active-badge {
    background: rgba(59, 130, 246, 0.12);
    color: var(--primary);
    border-radius: 999px;
    padding: 0.125rem 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
}

.order-channel-badge {
    display: inline-block;
    border-radius: 999px;
    padding: 0.2rem 0.65rem;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.order-channel-badge.channel-table {
    background: rgba(59, 130, 246, 0.12);
    color: var(--primary);
}

.order-channel-badge.channel-webapp {
    background: rgba(245, 158, 11, 0.14);
    color: #D97706;
}

.order-channel-badge.channel-website {
    background: rgba(245, 158, 11, 0.14);
    color: #D97706;
}

.order-channel-badge.channel-marketplace {
    background: rgba(240, 90, 40, 0.12);
    color: #C2410C;
    border-color: rgba(240, 90, 40, 0.35);
}

.order-channel-card-amount {
    font-size: 1.25rem;
    font-weight: 700;
    white-space: nowrap;
}

.orders-channel-panel.channel-table {
    border-top: 3px solid #FF8C42;
}

.orders-channel-panel.channel-webapp {
    border-top: 3px solid #F59E0B;
}

.order-source-card.source-phone .source-card-icon { background: linear-gradient(135deg, #10B981, #059669); }
.order-source-card.source-yemeksepeti .source-card-icon { background: linear-gradient(135deg, #EC4899, #DB2777); }
.order-source-card.source-getir .source-card-icon { background: linear-gradient(135deg, #8B5CF6, #7C3AED); }
.order-source-card.source-trendyol .source-card-icon { background: linear-gradient(135deg, #F97316, #EA580C); }
.order-source-card.source-migros .source-card-icon { background: linear-gradient(135deg, #F05A28, #EA580C); }
.order-source-card.source-tiklagelsin .source-card-icon { background: linear-gradient(135deg, #E31C23, #B91C1C); }

.payment-matrix-table thead th {
    background: #F8FAFC;
    font-size: 0.75rem;
    white-space: nowrap;
}

.payment-matrix-table td {
    font-size: 0.8rem;
    white-space: nowrap;
}

.payment-matrix-table .matrix-grand-total {
    background: rgba(240, 90, 40, 0.05);
}

.order-list-table .order-source-cell {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.order-actions-col {
    width: 11.5rem;
    min-width: 11.5rem;
}

.order-actions-cell {
    vertical-align: middle;
    white-space: nowrap;
}

.order-table-actions {
    display: inline-flex;
    align-items: stretch;
    justify-content: flex-end;
    gap: 0.35rem;
}

.order-table-actions--phone {
    flex-wrap: wrap;
}

.order-table-actions .order-action-btn {
    min-width: 5.25rem;
    padding-left: 0.55rem;
    padding-right: 0.55rem;
    font-weight: 600;
    line-height: 1.25;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    white-space: nowrap;
}

.order-table-actions form {
    display: inline-flex;
    margin: 0;
}

.order-type-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: #F1F5F9;
    color: #64748B;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
}

.order-source-badge {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.8rem;
}

.order-source-badge.source-phone { background: #10B981; }
.order-source-badge.source-table { background: #EF4444; }
.order-source-badge.source-website { background: #F59E0B; }
.order-source-badge.source-yemeksepeti { background: #EC4899; }
.order-source-badge.source-getir { background: #8B5CF6; }
.order-source-badge.source-trendyol { background: #F97316; }
.order-source-badge.source-migros { background: #F05A28; }
.order-source-badge.source-tiklagelsin { background: #E31C23; }
.order-source-badge.source-quicksale { background: #0EA5E9; }
.order-source-card.source-quicksale .source-card-icon { background: linear-gradient(135deg, #0EA5E9, #0284C7); }
.order-source-card.source-qr .source-card-icon { background: linear-gradient(135deg, #FBBF24, #D97706); }
.order-source-badge.source-qr { background: #D97706; }
.order-channel-badge.channel-quicksale { background: rgba(14, 165, 233, 0.12); color: #0284C7; border-color: rgba(14, 165, 233, 0.35); }
.quick-sale-page .table-pos-pay-btn { font-weight: 700; }

.pos-weigh-modal {
    width: min(420px, 96vw);
}

.pos-weigh-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.pos-weigh-input {
    font-size: 1.35rem;
    font-weight: 800;
    text-align: right;
    height: 3.1rem;
}

.pos-weigh-total {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    background: #F8FAFC;
    border: 1px solid #E5E7EB;
}

.pos-weigh-total span {
    color: #6B7280;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.78rem;
    letter-spacing: 0.04em;
}

.pos-weigh-total strong {
    font-size: 1.45rem;
    font-weight: 800;
    color: var(--brand, #F26522);
}

/* ── Market POS (Hızlı Satış) ── */
.market-pos-page {
    --market-accent: #059669;
    --market-accent-dark: #047857;
    --market-accent-soft: #ecfdf5;
    --market-surface: #f8fafc;
    background: var(--market-surface);
    flex: 1;
    min-height: 0;
    gap: 0.55rem;
}

.market-pos-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: linear-gradient(135deg, #0f766e 0%, #059669 55%, #10b981 100%);
    border-radius: 14px;
    color: #fff;
    box-shadow: 0 10px 28px rgba(5, 150, 105, 0.22);
}

.market-pos-header-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex: 1;
    min-width: 0;
}

.market-pos-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.market-pos-brand-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.16);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.market-pos-title {
    display: block;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 0.01em;
}

.market-pos-subtitle {
    display: block;
    font-size: 0.78rem;
    opacity: 0.88;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.market-pos-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.market-pos-receipt {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-end;
    padding: 0.35rem 0.7rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.14);
    line-height: 1.1;
}

.market-pos-receipt-label {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    opacity: 0.85;
}

.market-pos-receipt strong {
    font-size: 1rem;
    font-variant-numeric: tabular-nums;
}

.market-pos-clock {
    font-size: 0.78rem;
    opacity: 0.92;
    white-space: nowrap;
}

.market-pos-back-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.55rem 0.85rem;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
    transition: background 0.15s, border-color 0.15s;
    flex-shrink: 0;
}

.market-pos-back-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.45);
}

.market-pos-layout {
    grid-template-columns: minmax(0, 1fr) clamp(300px, 30vw, 400px);
    grid-template-rows: 1fr;
    gap: 0.65rem;
    flex: 1;
    min-height: 0;
    height: 100%;
    width: 100%;
}

.market-pos-categories {
    flex-direction: row;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    max-height: none;
    padding: 0.45rem;
    gap: 0.4rem;
    border-radius: 12px;
    scrollbar-width: thin;
    flex-shrink: 0;
    border: none;
    background: transparent;
}

.market-pos-category {
    flex: 0 0 auto;
    min-height: 42px;
    padding: 0.55rem 0.95rem;
    border-radius: 999px;
    border: 1px solid var(--border-color);
    border-left: 1px solid var(--border-color) !important;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
    white-space: nowrap;
    background: #fff;
}

.market-pos-category.active {
    background: var(--market-accent);
    border-color: var(--market-accent-dark);
    color: #fff;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.25);
}

.market-pos-category.active i {
    color: #fff;
}

.market-pos-main {
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
    height: 100%;
    gap: 0.55rem;
    overflow: hidden;
}

.market-pos-products {
    flex: 1;
    min-height: 0;
    max-height: none;
    background: #fff;
    border-radius: 14px;
    padding: 0.85rem;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.market-pos-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.85rem;
    flex-wrap: wrap;
}

.market-pos-search {
    flex: 1;
    min-width: 220px;
    margin-bottom: 0;
}

.market-pos-search input {
    min-height: 46px;
    border-radius: 12px;
    border-color: #dbeafe;
    background: #f8fbff;
    font-size: 0.92rem;
}

.market-pos-search input:focus {
    border-color: var(--market-accent);
    box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.12);
}

.market-pos-print-bar {
    position: fixed;
    left: 50%;
    bottom: 1.25rem;
    transform: translateX(-50%);
    z-index: 1080;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: min(560px, calc(100vw - 1.5rem));
    padding: 0.85rem 1rem;
    border-radius: 14px;
    background: #fff;
    border: 1px solid #bbf7d0;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.18);
}

.market-pos-print-bar-text {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    font-size: 0.9rem;
    color: #14532d;
    min-width: 0;
}

.market-pos-print-bar-text i {
    font-size: 1.15rem;
    color: var(--market-accent, #059669);
    flex-shrink: 0;
}

.market-pos-print-bar-actions {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-shrink: 0;
}

.market-pos-toolbar-hint {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.76rem;
    color: #64748b;
    white-space: nowrap;
}

.market-pos-product-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
    gap: 0.65rem;
    align-content: start;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
}

.market-pos-tile {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.45rem;
    min-height: 148px;
    padding: 0.65rem;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #fff;
    text-align: left;
    cursor: pointer;
    transition: transform 0.12s, box-shadow 0.12s, border-color 0.12s;
    touch-action: manipulation;
}

.market-pos-tile:hover {
    border-color: #86efac;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
    transform: translateY(-1px);
}

.market-pos-tile:active {
    transform: scale(0.98);
}

.market-pos-tile-media {
    width: 100%;
    aspect-ratio: 1.15;
    border-radius: 10px;
    background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: #94a3b8;
    font-size: 1.5rem;
}

.market-pos-tile-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.market-pos-tile-name {
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1.25;
    color: #0f172a;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.5em;
}

.market-pos-tile-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
}

.market-pos-badge {
    display: inline-block;
    padding: 0.08rem 0.4rem;
    border-radius: 999px;
    font-size: 0.62rem;
    font-weight: 700;
}

.market-pos-badge.menu { background: #fef3c7; color: #b45309; }
.market-pos-badge.option { background: #dbeafe; color: #1d4ed8; }
.market-pos-badge.content { background: #dcfce7; color: #15803d; }

.market-pos-tile-price {
    margin-top: auto;
    font-size: 0.92rem;
    font-weight: 800;
    color: var(--market-accent-dark);
    font-variant-numeric: tabular-nums;
}

.market-pos-empty {
    min-height: 220px;
}

.market-pos-cart {
    height: 100%;
    min-height: 0;
    max-height: none;
    border-radius: 14px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
    border: 1px solid #e2e8f0;
    background: #fff;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.market-pos-cart-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.85rem 0.95rem 0.65rem;
    border-bottom: 1px solid #eef2f7;
}

.market-pos-cart-title {
    display: block;
    font-size: 0.95rem;
    font-weight: 800;
    color: #0f172a;
}

.market-pos-cart-count {
    display: block;
    font-size: 0.74rem;
    color: #64748b;
    margin-top: 0.1rem;
}

.market-pos-cart-clear {
    width: 38px;
    height: 38px;
    border: 1px solid #fee2e2;
    border-radius: 10px;
    background: #fef2f2;
    color: #dc2626;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.12s;
}

.market-pos-cart-clear:hover:not(:disabled) {
    background: #fee2e2;
}

.market-pos-cart-clear:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.market-pos-cart-body {
    min-height: 160px;
}

.market-pos-cart-table thead {
    display: none;
}

.market-pos-cart-table tbody tr {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 0.35rem 0.5rem;
    align-items: center;
    padding: 0.55rem 0;
    border-bottom: 1px solid #f1f5f9;
}

.market-pos-cart-table tbody td:nth-child(2) {
    font-size: 0.78rem;
    font-weight: 700;
    color: #64748b;
    background: #f8fafc;
    border-radius: 8px;
    padding: 0.15rem 0.45rem;
}

.market-pos-cart-table tbody td:nth-child(4) .btn-remove {
    border: none;
    background: transparent;
    color: #94a3b8;
    padding: 0.15rem;
}

.market-pos-cart-empty {
    padding: 2rem 1rem;
}

.market-pos-cart-empty small {
    display: block;
    margin-top: 0.25rem;
    color: #94a3b8;
}

.market-pos-checkout {
    padding: 0.85rem 0.95rem calc(0.85rem + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid #eef2f7;
    background: linear-gradient(180deg, #fff 0%, #f8fafc 100%);
}

.market-pos-checkout-total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.market-pos-checkout-total span {
    font-size: 0.82rem;
    color: #64748b;
    font-weight: 600;
}

.market-pos-checkout-total strong {
    font-size: 1.65rem;
    font-weight: 900;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.market-pos-pay-btn {
    width: 100%;
    min-height: 52px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
    color: #fff;
    font-size: 1rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    box-shadow: 0 10px 24px rgba(5, 150, 105, 0.28);
    transition: transform 0.12s, box-shadow 0.12s, opacity 0.12s;
    cursor: pointer;
}

.market-pos-pay-btn:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 12px 28px rgba(5, 150, 105, 0.34);
}

.market-pos-pay-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    box-shadow: none;
}

.market-pos-payment-modal .payment-modal-title {
    font-weight: 800;
}

@media (max-width: 991.98px) {
    .market-pos-header-main {
        flex-direction: column;
        align-items: flex-start;
    }

    .market-pos-meta {
        width: 100%;
        justify-content: space-between;
    }

    .market-pos-toolbar-hint {
        display: none;
    }
}

@container table-pos (min-width: 992px) {
    .market-pos-page .table-pos-mobile-bar {
        display: none !important;
    }
}

.quick-sale-receipt-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-left: 0.5rem;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.12);
    border: 1px solid rgba(245, 158, 11, 0.35);
    font-size: 0.82rem;
    line-height: 1.2;
}

.quick-sale-receipt-label {
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-size: 0.72rem;
}

.quick-sale-receipt-badge strong {
    color: #b45309;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.quick-sale-page .table-pos-summary {
    grid-template-columns: 1fr 1fr;
}

.table-pos-page.quick-sale-page .table-pos-category:hover {
    border-color: #059669;
    box-shadow: 0 4px 10px rgba(5, 150, 105, 0.16);
}

.table-pos-page.quick-sale-page .table-pos-category.active {
    background: linear-gradient(135deg, #0f766e 0%, #059669 55%, #10b981 100%) !important;
    color: #fff !important;
    border-color: #047857 !important;
    border-left-color: #0f766e !important;
    border-bottom-color: #047857 !important;
    box-shadow: 0 5px 14px rgba(5, 150, 105, 0.34);
}

.table-pos-page.quick-sale-page .table-pos-category.active i {
    color: #fff !important;
}

.order-address {
    max-width: 280px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.order-customer-cell {
    min-width: 200px;
    max-width: 320px;
}

.order-meta-line {
    font-size: 0.72rem;
    color: #64748B;
    margin-top: 0.15rem;
}

.order-activity-log {
    display: flex;
    flex-direction: column;
    gap: 0.12rem;
    margin-top: 0.25rem;
}

.order-log-entry {
    display: block;
    font-size: 0.68rem;
    line-height: 1.35;
    color: #64748B;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.order-log-entry.order-log-payment {
    color: #059669;
}

.order-log-entry.order-log-remove {
    color: #DC2626;
}

.order-log-more {
    font-size: 0.65rem;
    color: #94A3B8;
    font-style: italic;
}

.order-cashier-cell {
    min-width: 130px;
    font-size: 0.78rem;
}

.order-cashier-line {
    line-height: 1.4;
    color: #334155;
}

.order-cashier-line i {
    color: #059669;
    margin-right: 0.15rem;
}

.cashier-daily-table .cashier-daily-total {
    background: rgba(16, 185, 129, 0.06);
    border-top: 2px solid rgba(16, 185, 129, 0.2);
}

/* Order create */
.order-create-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.order-create-title {
    font-size: 1.2rem;
    font-weight: 700;
}

.order-create-layout {
    display: grid;
    grid-template-columns: 180px minmax(220px, 28%) minmax(420px, 1fr);
    gap: 1rem;
    min-height: calc(100vh - 200px);
}

.order-create-categories {
    padding: 0;
    overflow: hidden;
}

.category-list {
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 180px);
    overflow-y: auto;
}

.category-item {
    border: none;
    background: transparent;
    text-align: left;
    padding: 0.75rem 1rem;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-left: 3px solid transparent;
    transition: all 0.15s;
}

.category-item:hover {
    background: #F8FAFC;
    color: var(--text-primary);
}

.category-item.active {
    background: rgba(240, 90, 40, 0.08);
    color: var(--primary);
    border-left-color: var(--primary);
    font-weight: 600;
}

.order-create-products {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.product-search-wrap {
    position: relative;
    margin-bottom: 1rem;
}

.product-search-wrap i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #94A3B8;
}

.product-search-wrap input {
    padding-left: 2.25rem;
    border-radius: 10px;
    font-size: 0.85rem;
}

.product-grid {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    overflow-y: auto;
    max-height: calc(100vh - 260px);
    padding-right: 4px;
}

.product-pick-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 0.5rem 0.75rem;
    background: #fff;
    text-align: left;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.product-pick-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.product-pick-thumb {
    width: 52px;
    height: 52px;
    border-radius: 8px;
    background: #F1F5F9;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94A3B8;
    flex-shrink: 0;
    overflow: hidden;
}

.product-pick-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-pick-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
}

.product-pick-price {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.order-cart-panel {
    padding: 0;
    overflow: hidden;
}

.cart-table-wrap {
    max-height: 240px;
    overflow-y: auto;
}

.order-cart-table th {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--text-secondary);
    background: #F8FAFC;
    position: sticky;
    top: 0;
    z-index: 1;
}

.order-cart-table td {
    font-size: 0.8rem;
    vertical-align: middle;
}

.cart-total-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.875rem 1rem;
    border-top: 1px solid var(--border-color);
    background: #F8FAFC;
    font-size: 0.95rem;
}

.cart-total-bar strong {
    font-size: 1.15rem;
    color: var(--primary);
}

.order-info-panel {
    padding: 1rem;
}

.order-info-title {
    font-weight: 600;
    font-size: 0.9rem;
}

.order-type-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    background: #F1F5F9;
    padding: 0.35rem;
    border-radius: 10px;
}

.order-type-tab {
    border: none;
    background: transparent;
    border-radius: 8px;
    padding: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
}

.order-type-tab.active {
    background: #fff;
    color: var(--primary);
    box-shadow: var(--shadow-sm);
}

@media (max-width: 1199.98px) {
    .order-create-layout {
        grid-template-columns: 1fr;
    }
    .category-list {
        flex-direction: row;
        flex-wrap: nowrap;
        overflow-x: auto;
        max-height: none;
    }
    .category-item {
        white-space: nowrap;
        border-left: none;
        border-bottom: 3px solid transparent;
    }
    .category-item.active {
        border-bottom-color: var(--primary);
    }
    .kpi-card .kpi-value { font-size: 1.15rem; }
}

/* Tables floor */
.tables-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.tables-page-title {
    font-size: 1.25rem;
    font-weight: 700;
}

.table-zone-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.zone-filter-btn {
    display: inline-flex;
    align-items: center;
    padding: 0.45rem 1rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid var(--border-color);
    background: #fff;
    color: var(--text-secondary);
    transition: all 0.15s;
}

.zone-filter-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.zone-filter-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
    box-shadow: 0 4px 12px rgba(240, 90, 40, 0.25);
}

.table-zone-section {
    padding: 1.25rem;
}

.table-zone-heading {
    text-align: center;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.table-floor-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.75rem;
}

.table-floor-card {
    border-radius: var(--radius);
    min-height: 100px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.15s, box-shadow 0.15s;
}

.table-floor-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.table-floor-card.wide {
    grid-column: span 2;
}

.table-floor-card.empty {
    background: linear-gradient(145deg, #10B981, #059669);
}

.table-floor-card.occupied {
    background: linear-gradient(145deg, #EF4444, #DC2626);
}

.table-card-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 1rem 0.75rem;
    min-height: 100px;
    color: #fff;
    text-decoration: none;
    height: 100%;
}

.table-card-name {
    font-weight: 700;
    font-size: 0.95rem;
    margin-bottom: 0.35rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.table-card-status {
    font-size: 0.8rem;
    font-weight: 600;
    opacity: 0.9;
}

.table-card-amount {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.table-card-time {
    font-size: 0.72rem;
    opacity: 0.9;
    line-height: 1.3;
}

@media (max-width: 575.98px) {
    .table-floor-card.wide {
        grid-column: span 1;
    }
    .table-floor-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Table payment */
.table-payment-page {
    max-width: 1100px;
}

.table-payment-table-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 88px;
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    background: linear-gradient(145deg, #EF4444, #DC2626);
    color: #fff;
    box-shadow: 0 8px 20px rgba(220, 38, 38, 0.25);
}

.table-payment-table-badge .label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    opacity: 0.9;
}

.table-payment-table-badge strong {
    font-size: 1.35rem;
    line-height: 1.2;
}

.table-payment-meta {
    background: #FAFBFC;
}

.table-payment-total-row td {
    background: #FFF7ED;
    border-top: 2px solid rgba(240, 90, 40, 0.2);
}

.table-payment-amount-box {
    text-align: center;
    padding: 1.25rem;
    border-radius: 12px;
    background: linear-gradient(145deg, #FFF7ED, #FFEDD5);
    border: 1px solid rgba(240, 90, 40, 0.15);
}

.table-payment-amount-box .label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0.35rem;
}

.table-payment-amount-box .amount {
    font-size: 2rem;
    font-weight: 800;
    color: var(--brand);
    line-height: 1.1;
}

.table-payment-type-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.payment-type-option {
    margin: 0;
    cursor: pointer;
}

.payment-type-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.payment-type-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    background: #fff;
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-secondary);
    transition: all 0.15s;
}

.payment-type-card i {
    font-size: 1.35rem;
}

.payment-type-option input:checked + .payment-type-card {
    border-color: var(--brand);
    background: #FFF7ED;
    color: var(--brand);
    box-shadow: 0 0 0 3px rgba(240, 90, 40, 0.12);
}

.table-payment-submit {
    font-weight: 700;
    border-radius: 12px;
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}

.table-payment-summary-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
}

.payment-summary-card {
    padding: 1rem 1.25rem;
    border-radius: 14px;
    background: #fff;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

.payment-summary-label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-secondary);
    margin-bottom: 0.35rem;
}

.payment-summary-value {
    font-size: 1.5rem;
    font-weight: 800;
    line-height: 1.1;
}

.payment-summary-card.is-paid {
    background: linear-gradient(145deg, #F0FDF4, #DCFCE7);
    border-color: rgba(22, 163, 74, 0.2);
}

.payment-summary-card.is-remaining {
    background: linear-gradient(145deg, #FFF7ED, #FFEDD5);
    border-color: rgba(240, 90, 40, 0.15);
}

.payment-item-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 0.75rem;
}

.payment-item-card {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
    text-align: left;
    padding: 1rem;
    border: 2px solid var(--border-color);
    border-radius: 14px;
    background: #fff;
    cursor: pointer;
    transition: all 0.15s ease;
}

.payment-item-card:hover:not(:disabled) {
    border-color: var(--brand);
    box-shadow: 0 8px 24px rgba(240, 90, 40, 0.12);
    transform: translateY(-1px);
}

.payment-item-card.is-paid {
    opacity: 0.72;
    cursor: default;
    background: #F8FAFC;
}

.payment-item-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem;
}

.payment-item-name {
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.3;
}

.payment-item-badge {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.2rem 0.5rem;
    border-radius: 999px;
    white-space: nowrap;
}

.payment-item-badge.paid {
    background: #DCFCE7;
    color: #15803D;
}

.payment-item-badge.partial {
    background: #FEF3C7;
    color: #B45309;
}

.payment-item-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.payment-item-meta strong {
    color: var(--text-primary);
    font-size: 1rem;
}

.payment-item-progress {
    height: 6px;
    border-radius: 999px;
    background: #E5E7EB;
    overflow: hidden;
}

.payment-item-progress-bar {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #22C55E, #16A34A);
}

.payment-item-remaining,
.payment-item-tap-hint {
    font-size: 0.78rem;
    color: var(--text-secondary);
}

.payment-item-remaining.is-highlight {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-top: 0.35rem;
    padding: 0.28rem 0.55rem;
    border-radius: 8px;
    background: #FFEDD5;
    border: 1px solid #FDBA74;
    color: #C2410C;
    font-weight: 700;
}

.payment-item-remaining.is-highlight strong {
    color: #9A3412;
    font-size: 0.9rem;
}

.payment-item-tap-hint {
    color: var(--brand);
    font-weight: 600;
}

.payment-history-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 520px;
    overflow-y: auto;
}

.payment-history-empty {
    text-align: center;
    padding: 2.5rem 1rem;
    color: var(--text-secondary);
}

.payment-history-empty i {
    font-size: 2rem;
    opacity: 0.35;
    display: block;
    margin-bottom: 0.75rem;
}

.payment-history-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 12px;
    background: #FAFBFC;
    border: 1px solid var(--border-color);
}

.payment-history-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.1rem;
}

.payment-history-icon.is-cash {
    background: #DCFCE7;
    color: #15803D;
}

.payment-history-icon.is-card {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.payment-history-icon.is-wire {
    background: #F3E8FF;
    color: #7C3AED;
}

.payment-history-body {
    flex: 1;
    min-width: 0;
}

.payment-history-title {
    font-weight: 600;
    font-size: 0.9rem;
    line-height: 1.3;
}

.payment-history-meta {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.15rem;
}

.payment-history-amount {
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
    text-align: right;
}

.payment-history-reverse {
    flex-shrink: 0;
    padding: 0.25rem 0.45rem;
    line-height: 1;
}

.table-payment-type-grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.table-payment-type-grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

.table-payment-type-grid-many {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
}

.payment-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1080;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.payment-modal-backdrop[hidden] {
    display: none !important;
}

body.payment-modal-open {
    overflow: hidden;
}

.payment-modal {
    width: min(100%, 440px);
    max-height: min(90dvh, calc(100dvh - 2rem));
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 24px 48px rgba(15, 23, 42, 0.2);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: paymentModalIn 0.2s ease;
}

.table-pos-payment-modal {
    width: min(100%, 520px);
    max-height: min(96dvh, calc(100dvh - 0.75rem));
}

.table-pos-payment-modal .payment-modal-body {
    padding: 1rem 1.25rem 1.25rem;
}

.payment-collect-modal {
    width: min(96vw, 980px);
    height: min(92dvh, 760px);
    max-height: min(92dvh, calc(100dvh - 0.75rem));
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-modal-body {
    flex: 1;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: 0.45rem 0.9rem 0.5rem;
}

.payment-collect-modal .payment-modal-header {
    padding: 0.55rem 1.1rem 0.35rem;
}

.payment-collect-modal .payment-modal-footer {
    padding: 0.35rem 1.1rem 0.7rem;
}

.payment-collect-modal .payment-modal-amounts,
.payment-collect-modal .payment-main-tabs,
.payment-collect-modal .payment-mode-tabs {
    margin-bottom: 0.5rem;
}

.payment-collect-modal .form-label {
    margin-bottom: 0.25rem;
    font-size: 0.78rem;
    font-weight: 700;
    color: #64748b;
}

.payment-collect-modal .form-label.mt-3 {
    margin-top: 0.55rem !important;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-collect-hero .payment-modal-amounts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: center;
    text-align: center;
    gap: 0.35rem 0.75rem;
    margin-bottom: 0.45rem;
    padding: 0.45rem 0.75rem;
    background: linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
    border: 1px solid #334155;
    border-radius: 14px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-modal-amounts .label {
    margin-bottom: 0.05rem;
    color: #FDBA74;
    letter-spacing: 0.14em;
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-modal-amounts strong {
    font-size: 1.45rem;
    letter-spacing: -0.03em;
    color: #fff;
    font-variant-numeric: tabular-nums;
    line-height: 1.15;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-cash-due.is-change .label {
    color: #86EFAC;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-cash-due.is-change strong {
    color: #CBD5E1;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-cash-due.is-change.is-visible strong {
    color: #4ADE80;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-cash-unit {
    grid-column: 1 / -1;
    border-top: 1px solid rgba(253, 186, 116, 0.22);
    padding-top: 0.25rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-cash-unit .label {
    color: #94A3B8;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-cash-unit strong {
    font-size: 1rem;
    color: #E2E8F0;
}

.payment-cash-pad {
    margin-top: 0.45rem;
    flex: 1;
    min-height: 0;
    display: flex;
}

.payment-cash-register {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
    flex: 1;
}

.payment-cash-quick {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.3rem;
    margin-bottom: 0.35rem;
    flex-shrink: 0;
}

.payment-cash-quick button {
    min-height: 32px;
    border-radius: 9px;
    border: 1px solid #CBD5E1;
    background: #fff;
    font-weight: 800;
    color: #1E293B;
    font-size: 0.85rem;
}

.payment-cash-quick button[data-cash-quick="all"] {
    background: #059669;
    border-color: #047857;
    color: #fff;
}

.payment-cash-numpad {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: repeat(4, minmax(0, 1fr));
    gap: 0.3rem;
    flex: 1;
    min-height: 0;
}

.payment-cash-numpad .pos-numpad-key {
    min-height: 0;
    height: 100%;
    font-size: 1.05rem;
}

.payment-cash-numpad .pos-numpad-key.is-muted {
    background: #F8FAFC;
    color: #64748B;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-collect-hero,
.payment-collect-modal:not(.phone-checkout-modal) .payment-main-tabs {
    flex-shrink: 0;
}

.payment-collect-modal:not(.phone-checkout-modal) #paymentQuickPanel {
    flex: 1;
    min-height: 0;
    overflow: auto;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-main-tabs {
    padding: 0.2rem;
    background: #F1F5F9;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-main-tab {
    padding: 0.45rem 0.65rem;
    font-size: 0.8rem;
}

.payment-collect-card {
    background: #fff;
    border: 2px solid #CBD5E1;
    border-radius: 14px;
    padding: 0.85rem 0.95rem;
}

.payment-collect-card + .payment-collect-card,
.payment-fit-main > .payment-collect-card + .payment-discount-preview,
.payment-fit-main > .payment-collect-card.is-extra {
    margin-top: 0.65rem;
}

.payment-collect-card-title {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 0.55rem;
}

.payment-collect-card.is-extra {
    background: #F8FAFC;
}

.payment-amount-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.5rem;
    align-items: stretch;
}

.payment-pay-all-btn {
    white-space: nowrap;
    font-weight: 800;
    border-radius: 12px;
    padding: 0 0.95rem;
    min-height: 48px;
}

.payment-fit-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
    gap: 0.75rem 0.9rem;
    align-items: stretch;
}

.payment-collect-modal:not(.phone-checkout-modal) #paymentStandardPanel.payment-fit-layout {
    flex: 1;
    min-height: 0;
    grid-template-columns: minmax(260px, 0.92fr) minmax(0, 1.08fr);
    grid-template-rows: minmax(0, 1fr) auto;
    grid-template-areas:
        "main methods"
        "discount discount";
    gap: 0.45rem 0.7rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-main {
    grid-area: main;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-main > .payment-collect-card {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding: 0.55rem 0.7rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-mode-panel#paymentModeAmount {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-methods {
    grid-area: methods;
    min-height: 0;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-discount {
    grid-area: discount;
    margin-top: 0 !important;
    padding: 0.5rem 0.7rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-discount .payment-discount-panel {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.75rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-discount .payment-collect-card-title {
    margin: 0;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-discount .payment-discount-preview {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.9rem;
    margin: 0;
    padding: 0;
    background: transparent;
    border: none;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-discount .payment-loyalty-panel {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    width: 100%;
}

.payment-fit-methods .payment-collect-card {
    height: 100%;
}

.payment-fit-methods .table-payment-type-grid {
    max-height: min(56vh, 460px);
    overflow-y: auto;
    padding-right: 0.15rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-methods .payment-collect-card {
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
    padding: 0.55rem 0.7rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-methods .table-payment-type-grid {
    max-height: none;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-methods .payment-type-card {
    min-height: 48px;
    padding: 0.45rem 0.7rem;
    font-size: 0.88rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-amount-input {
    height: 44px;
    font-size: 1.15rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-pay-all-btn {
    min-height: 44px;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-mode-tabs {
    margin-bottom: 0.4rem;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-collect-card-title {
    margin-bottom: 0.4rem;
}

.payment-fit-methods .table-payment-type-grid,
.payment-fit-methods .table-payment-type-grid-3,
.payment-fit-methods .table-payment-type-grid-4,
.payment-fit-methods .table-payment-type-grid-many {
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem;
}

.payment-fit-methods .payment-type-card {
    flex-direction: row;
    justify-content: flex-start;
    min-height: 64px;
    padding: 0.7rem 0.9rem;
    gap: 0.7rem;
    font-size: 0.95rem;
    font-weight: 700;
    background: #fff;
    border: 2px solid #94A3B8;
    border-radius: 12px;
    color: #1E293B;
}

.payment-fit-methods .payment-type-card i {
    font-size: 1.45rem;
    flex-shrink: 0;
}

.payment-collect-modal:not(.phone-checkout-modal) .payment-fit-methods .payment-type-option input:checked + .payment-type-card {
    background: var(--brand, #F26522);
    border-color: var(--brand, #F26522);
    color: #fff;
    box-shadow: 0 0 0 3px rgba(242, 101, 34, 0.25);
}

.payment-collect-modal .payment-amount-input {
    font-size: 1.28rem;
    padding: 0.5rem 0.8rem;
    height: 52px;
    text-align: left;
    border: 2px solid #94A3B8;
}

.payment-collect-modal .payment-loyalty-panel {
    margin-top: 0.75rem;
    padding-top: 0.7rem;
    border-top: 1px dashed #E2E8F0;
}

.payment-collect-modal .payment-discount-preview {
    margin-top: 0.7rem;
    background: #fff;
    border: 2px solid #CBD5E1;
}

.payment-collect-modal .payment-discount-mode-option {
    border: 2px solid #94A3B8;
    padding: 0.45rem 0.8rem;
    font-weight: 700;
}

.payment-collect-modal .payment-pay-all-btn {
    border: 2px solid transparent;
}

.payment-collect-modal .payment-qty-btn {
    width: 40px;
    height: 40px;
}

.payment-collect-modal .payment-preview-amount {
    margin-top: 0.45rem;
    padding: 0.5rem 0.65rem;
}

.phone-checkout-modal.payment-collect-modal {
    width: min(96vw, 920px);
}

@keyframes paymentModalIn {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.payment-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.25rem 1.25rem 0.75rem;
    border-bottom: 1px solid var(--border-color);
    flex-shrink: 0;
}

.payment-modal-title {
    font-size: 1.15rem;
    font-weight: 800;
    margin: 0;
}

.payment-modal-subtitle {
    margin: 0.25rem 0 0;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.payment-modal-close {
    border: none;
    background: #F1F5F9;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-secondary);
}

.payment-modal-body {
    padding: 1.25rem;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.payment-modal-amounts {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.payment-modal-amounts .label {
    display: block;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-secondary);
    margin-bottom: 0.2rem;
}

.payment-modal-amounts strong {
    font-size: 1.1rem;
    color: var(--brand);
}

.payment-mode-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding: 0.25rem;
    background: #F1F5F9;
    border-radius: 12px;
}

.payment-mode-tab {
    flex: 1;
    border: none;
    background: transparent;
    padding: 0.55rem 0.75rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.82rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.payment-mode-tab.active {
    background: #fff;
    color: var(--brand);
    box-shadow: var(--shadow-sm);
}

.payment-main-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding: 0.25rem;
    background: #E2E8F0;
    border-radius: 12px;
}

.payment-main-tab {
    flex: 1;
    border: none;
    background: transparent;
    padding: 0.6rem 0.75rem;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.payment-main-tab.active {
    background: #fff;
    color: var(--brand);
    box-shadow: var(--shadow-sm);
}

.quick-payment-panel {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.quick-payment-hint {
    margin: 0;
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.45;
}

.quick-payment-rows {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.quick-payment-row {
    display: grid;
    grid-template-columns: 1fr minmax(110px, 140px) 40px;
    gap: 0.5rem;
    align-items: center;
}

.quick-payment-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.quick-payment-summary {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    padding: 0.75rem;
    border-radius: 12px;
    background: #F8FAFC;
    border: 1px solid var(--border-color);
}

.quick-payment-summary > div {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    text-align: center;
}

.quick-payment-summary span {
    font-size: 0.72rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.quick-payment-summary strong {
    font-size: 0.95rem;
    color: var(--text-primary);
}

.payment-qty-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.payment-qty-btn {
    width: 44px;
    height: 44px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    background: #fff;
    font-size: 1.25rem;
    font-weight: 700;
    cursor: pointer;
    color: var(--text-primary);
}

.payment-qty-input {
    text-align: center;
    font-weight: 700;
    font-size: 1.1rem;
    border-radius: 12px;
}

.payment-qty-hint {
    font-size: 0.78rem;
    color: var(--text-secondary);
    margin-top: 0.35rem;
}

.payment-preview-amount {
    margin-top: 0.75rem;
    padding: 0.75rem;
    border-radius: 10px;
    background: #FFF7ED;
    font-size: 0.9rem;
    text-align: center;
}

.payment-amount-input {
    font-size: 1.25rem;
    font-weight: 700;
    text-align: center;
    border-radius: 12px;
    padding: 0.75rem;
}

.payment-modal-footer {
    display: flex;
    gap: 0.75rem;
    padding: 0 1.25rem 1.25rem;
    flex-shrink: 0;
}

.payment-modal-footer .btn {
    flex: 1;
    border-radius: 12px;
    font-weight: 700;
}

.payment-modal-submit {
    flex: 1.4 !important;
}

@media (max-width: 767.98px) {
    .table-payment-summary-strip {
        grid-template-columns: 1fr;
    }

    .table-payment-type-grid-3 {
        grid-template-columns: 1fr;
    }

    .payment-item-grid {
        grid-template-columns: 1fr;
    }

    /* POS / ödeme popup'ları — mobil tam ekran, üstten açılır */
    .payment-modal-backdrop {
        align-items: stretch;
        justify-content: flex-start;
        padding: 0;
        overflow: hidden;
    }

    .payment-modal {
        width: 100%;
        max-width: 100%;
        height: 100dvh;
        max-height: 100dvh;
        min-height: 0;
        border-radius: 0;
        margin: 0;
        box-sizing: border-box;
        padding-bottom: env(safe-area-inset-bottom, 0px);
        animation: paymentModalSlideDown 0.2s ease;
    }

    @keyframes paymentModalSlideDown {
        from {
            opacity: 0;
            transform: translateY(-12px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .table-pos-move-modal,
    .table-pos-payment-modal,
    .payment-collect-modal,
    .pos-add-product-modal,
    .table-pos-remove-modal {
        max-width: 100%;
    }

    .payment-fit-layout {
        grid-template-columns: 1fr;
        gap: 0.65rem;
    }

    .payment-collect-modal:not(.phone-checkout-modal) #paymentStandardPanel.payment-fit-layout {
        grid-template-columns: 1fr;
        grid-template-rows: none;
        grid-template-areas:
            "main"
            "methods"
            "discount";
    }

    .payment-collect-modal:not(.phone-checkout-modal) .payment-modal-body {
        overflow-y: auto;
    }

    .payment-collect-modal {
        height: auto;
        max-height: none;
    }

    .payment-modal-header {
        padding: calc(0.75rem + env(safe-area-inset-top, 0px)) 1rem 0.65rem;
        position: sticky;
        top: 0;
        z-index: 2;
        background: #fff;
    }

    .payment-modal-title {
        font-size: 1.05rem;
        line-height: 1.3;
        padding-right: 0.25rem;
    }

    .payment-modal-subtitle {
        font-size: 0.82rem;
    }

    .payment-modal-body {
        padding: 0.85rem 1rem 1rem;
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
    }

    .payment-modal-footer {
        flex-direction: column-reverse;
        gap: 0.5rem;
        padding: 0.65rem 1rem calc(0.65rem + env(safe-area-inset-bottom, 0px));
        border-top: 1px solid var(--border-color);
        background: #fff;
        box-shadow: 0 -4px 16px rgba(15, 23, 42, 0.08);
        flex-shrink: 0;
        position: sticky;
        bottom: 0;
        z-index: 2;
    }

    .payment-modal-footer .btn {
        width: 100%;
        min-height: 44px;
        flex: none !important;
    }

    .payment-modal-amounts {
        grid-template-columns: 1fr;
    }

    .payment-mode-tabs {
        flex-wrap: wrap;
    }

    .payment-mode-tab {
        min-height: 40px;
    }

    .table-payment-type-grid,
    .table-payment-type-grid-many {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Ürün ekleme popup — kompakt */
    .pos-qty-display {
        font-size: 2rem;
        padding: 0.25rem 0;
    }

    .pos-numpad {
        gap: 0.4rem;
    }

    .pos-numpad-key {
        min-height: 42px;
        font-size: 1.05rem;
    }

    .pos-variation-row {
        flex-wrap: wrap;
        gap: 0.5rem;
        padding: 0.65rem 0.75rem;
    }

    .pos-variation-qty {
        margin-left: auto;
    }

    .pos-variation-summary {
        padding: 0.5rem;
        font-size: 0.88rem;
    }

    .pos-content-list {
        gap: 0.4rem;
    }

    .pos-content-chip {
        font-size: 0.78rem;
        padding: 0.4rem 0.65rem;
    }

    .table-move-list {
        max-height: none;
        overflow: visible;
        grid-template-columns: 1fr;
    }

    .table-move-item {
        min-height: 44px;
    }

    /* Bootstrap modal'lar — üstten tam ekran */
    .modal {
        padding: 0 !important;
    }

    .modal-dialog {
        margin: 0;
        max-width: 100%;
        width: 100%;
        height: 100dvh;
        max-height: 100dvh;
        display: flex;
        align-items: stretch;
    }

    .modal-dialog-centered {
        align-items: stretch;
        min-height: 100dvh;
    }

    .modal-content {
        height: 100dvh;
        max-height: 100dvh;
        display: flex;
        flex-direction: column;
        border-radius: 0;
        width: 100%;
        border: none;
    }

    .modal-header {
        flex-shrink: 0;
        padding-top: calc(1rem + env(safe-area-inset-top, 0px));
    }

    .modal-footer {
        flex-shrink: 0;
        flex-direction: column-reverse;
        gap: 0.5rem;
        padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
        border-top: 1px solid var(--border-color);
        background: #fff;
    }

    .modal-body {
        overflow-y: auto;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
        flex: 1 1 auto;
        min-height: 0;
    }

    .modal-footer .btn {
        width: 100%;
        min-height: 44px;
        margin: 0;
    }
}

/* Table POS (touch) */
.main-content-compact {
    padding: 0.75rem 1rem 1rem;
}

.table-pos-page {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 2rem);
    container-type: inline-size;
    container-name: table-pos;
}

.table-pos-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 0.75rem;
    box-shadow: var(--shadow-sm);
}

.table-pos-header-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-primary);
}

.table-pos-header-left i {
    font-size: 1.35rem;
    color: var(--brand);
}

.table-pos-header-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.table-pos-back-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.55rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: #fff;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.15s;
}

.table-pos-back-btn:hover {
    border-color: var(--brand);
    color: var(--brand);
    background: #FFF7ED;
}

.table-pos-action-btn {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    min-width: 72px;
    min-height: 56px;
    padding: 0.5rem 0.65rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: #fff;
    color: var(--text-secondary);
    font-size: 0.65rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.15s;
    cursor: pointer;
}

.table-pos-action-btn i {
    font-size: 1.15rem;
}

.table-pos-action-btn:hover:not(:disabled) {
    border-color: var(--brand);
    color: var(--brand);
    background: #FFF7ED;
}

.table-pos-action-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.table-pos-action-primary {
    border-color: #FECACA;
    background: #FEF2F2;
    color: #DC2626;
}

.table-pos-action-primary:hover {
    background: #FEE2E2 !important;
    border-color: #DC2626 !important;
    color: #DC2626 !important;
}

.table-pos-layout {
    display: grid;
    grid-template-columns: 172px minmax(0, 1fr) minmax(360px, 36%);
    grid-template-areas: "cats products cart";
    gap: 0.65rem;
    flex: 1;
    min-height: 0;
}

.table-pos-page:not(.market-pos-page) .table-pos-layout > .table-pos-categories {
    grid-area: cats;
}

.table-pos-page:not(.market-pos-page) .table-pos-category {
    min-height: 54px;
    padding: 0.72rem 0.7rem;
    font-size: 0.84rem;
    font-weight: 800;
    color: #111;
    line-height: 1.25;
}

.table-pos-page:not(.market-pos-page) .table-pos-layout > .table-pos-products {
    grid-area: products;
}

.table-pos-page:not(.market-pos-page) .table-pos-layout > .table-pos-cart {
    grid-area: cart;
}

/* Market POS overrides (must follow base table-pos rules) */
.main-content-compact:has(.market-pos-page) {
    padding: 0.45rem;
    overflow: hidden;
    height: calc(100dvh - 0.25rem);
    display: flex;
    flex-direction: column;
}

.main-content-compact:has(.market-pos-page) > #restaurant-notifications-mount:not([hidden]) {
    flex: 0 0 auto;
    max-height: 22vh;
    overflow: auto;
    margin-bottom: 0.45rem;
}

.market-pos-page.table-pos-page {
    flex: 1;
    min-height: 0;
    height: 100%;
    width: 100%;
    max-width: none;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.market-pos-page .table-pos-layout {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) clamp(300px, 30vw, 400px) !important;
    grid-template-rows: 1fr !important;
    gap: 0.65rem;
    flex: 1;
    min-height: 0;
    height: 100%;
    width: 100%;
}

.market-pos-page .table-pos-categories {
    flex-direction: row !important;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    max-height: none !important;
    border: none !important;
    background: #fff !important;
    border-radius: 12px !important;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.market-pos-page .table-pos-category {
    border-left: none !important;
    min-height: 40px;
    padding: 0.5rem 0.95rem;
    border-radius: 999px;
    white-space: nowrap;
    flex: 0 0 auto;
    font-size: 0.78rem;
    letter-spacing: 0;
    text-transform: none;
}

.market-pos-page .table-pos-category.active {
    background: #059669 !important;
    color: #fff !important;
    border-left-color: transparent !important;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.25);
}

.market-pos-page .table-pos-category.active i {
    color: #fff !important;
}

.market-pos-page .table-pos-products {
    max-height: none !important;
    min-height: 0;
    flex: 1;
    overflow: hidden;
}

.market-pos-page .table-pos-product-list.market-pos-product-grid {
    display: grid !important;
    flex-direction: unset !important;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0.5rem;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    align-content: start;
}

.market-pos-page .table-pos-product-row .thumb {
    width: 46px;
    height: 46px;
}

.market-pos-page .table-pos-product-row .thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.market-pos-page .table-pos-cart {
    max-height: none !important;
    height: 100%;
    min-height: 0;
}

@media (max-width: 991.98px) {
    .main-content-compact:has(.market-pos-page) {
        padding: 0.35rem;
        height: calc(100dvh - 0.25rem);
    }

    .market-pos-page .table-pos-layout {
        display: flex !important;
        flex-direction: column !important;
        grid-template-columns: unset !important;
        grid-template-rows: unset !important;
        gap: 0.5rem !important;
        width: 100% !important;
    }

    .market-pos-page .market-pos-main {
        display: none !important;
    }

    .market-pos-page .table-pos-cart,
    .market-pos-page .market-pos-cart {
        width: 100% !important;
        max-width: none !important;
        flex: 1 1 auto !important;
        min-height: 0 !important;
        height: auto !important;
    }

    .market-pos-page .market-pos-cart-body {
        flex: 1;
        min-height: 120px;
    }

    .market-pos-page .market-pos-cart-table tbody tr {
        grid-template-columns: minmax(0, 1fr) auto auto auto;
    }

    .market-pos-page .market-pos-header {
        flex-wrap: nowrap;
        padding: 0.65rem 0.75rem;
        gap: 0.5rem;
    }

    .market-pos-page .market-pos-header-main {
        flex: 1;
        min-width: 0;
        flex-direction: row;
        align-items: center;
    }

    .market-pos-page .market-pos-back-btn {
        width: auto;
        flex-shrink: 0;
    }

    .market-pos-page .market-pos-back-btn span {
        display: none;
    }

    .market-pos-page .table-pos-mobile-bar {
        display: flex !important;
        margin-bottom: 0.45rem;
    }

    .market-pos-page .table-pos-mobile-add-btn {
        background: linear-gradient(135deg, #059669 0%, #10b981 100%) !important;
        box-shadow: 0 4px 14px rgba(5, 150, 105, 0.28) !important;
    }

    .market-pos-page .table-pos-mobile-total {
        color: #059669 !important;
    }

    .market-pos-page .market-pos-checkout {
        position: sticky;
        bottom: 0;
        z-index: 5;
        padding-bottom: calc(0.85rem + env(safe-area-inset-bottom, 0px));
    }

    .market-pos-page .market-pos-checkout-total strong {
        font-size: 1.5rem;
    }

    .market-pos-page .market-pos-pay-btn {
        min-height: 52px;
        font-size: 1.05rem;
    }
}

@container table-pos (max-width: 991px) {
    .market-pos-page .table-pos-layout {
        display: flex !important;
        flex-direction: column !important;
        grid-template-columns: unset !important;
        grid-template-rows: unset !important;
    }

    .market-pos-page .market-pos-main {
        display: none !important;
    }

    .market-pos-page .table-pos-cart {
        width: 100% !important;
        max-width: none !important;
        flex: 1 !important;
    }

    .market-pos-page .table-pos-mobile-bar {
        display: flex !important;
    }
}

.table-pos-categories {
    background: #FFF3EB;
    border: 1px solid #F8C9AE;
    border-radius: 12px;
    overflow-x: hidden;
    overflow-y: auto;
    max-height: calc(100vh - 120px);
    display: flex;
    flex-direction: column;
    padding: 5px;
    gap: 5px;
}

.table-pos-category {
    border: 1px solid #F0D4C4;
    background: #fff;
    text-align: left;
    padding: 0.55rem 0.5rem;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.01em;
    color: #334155;
    border-left: 4px solid #FDBA74;
    min-height: 44px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    line-height: 1.2;
    box-shadow: 0 2px 6px rgba(21, 34, 56, 0.08);
    transition: all 0.12s;
}

.table-pos-category:hover {
    border-color: #FB923C;
    box-shadow: 0 4px 10px rgba(242, 101, 34, 0.14);
}

.table-pos-category.active {
    background: var(--primary) !important;
    color: #fff !important;
    border-color: var(--primary-dark) !important;
    border-left-color: var(--primary-dark) !important;
    box-shadow: 0 5px 14px rgba(242, 101, 34, 0.34);
}

.table-pos-category.active i {
    color: #fff !important;
}

.table-pos-products {
    background: #e7edf5;
    border: 1px solid #c5d0e0;
    border-radius: 12px;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    min-height: 0;
    max-height: calc(100vh - 120px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.pos-products-toolbar,
.market-pos-toolbar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 5px;
}

.pos-products-toolbar .table-pos-search,
.market-pos-toolbar .table-pos-search {
    flex: 1;
    margin-bottom: 0;
}

.pos-view-toggle {
    display: inline-flex;
    flex-shrink: 0;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    margin-bottom: 0.75rem;
}

.pos-products-toolbar .pos-view-toggle,
.market-pos-toolbar .pos-view-toggle {
    margin-bottom: 0;
}

.pos-view-toggle button {
    border: 0;
    background: transparent;
    padding: 0.45rem 0.7rem;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-secondary);
}

.pos-view-toggle button.is-active {
    background: var(--navy);
    color: #fff;
}

.table-pos-product-list.is-list,
.table-pos-page:not(.market-pos-page) .table-pos-product-list.is-list,
.market-pos-page .table-pos-product-list.is-list {
    display: flex !important;
    flex-direction: column !important;
    grid-template-columns: none !important;
}

.table-pos-product-list.is-list .table-pos-product-row {
    width: 100%;
}

.table-pos-search {
    position: relative;
    margin-bottom: 0.75rem;
    flex-shrink: 0;
}

.table-pos-search i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #94A3B8;
    font-size: 1.1rem;
}

.table-pos-search input {
    width: 100%;
    padding: 0.875rem 1rem 0.875rem 2.75rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    font-size: 0.95rem;
    min-height: 48px;
}

.table-pos-product-list {
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 1;
    min-height: 200px;
}

.table-pos-product-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.5rem 0.65rem;
    border: 1px solid #c9d4e3;
    border-radius: 10px;
    background: linear-gradient(180deg, #ffffff 0%, #f3f6fb 100%);
    text-align: left;
    min-height: 58px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.95),
        0 6px 14px rgba(21, 34, 56, 0.12);
    transition: all 0.12s;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.table-pos-product-row:active {
    transform: scale(0.98);
    background: #FFF7ED;
    border-color: var(--brand);
}

.table-pos-product-row .thumb {
    width: 46px;
    height: 46px;
    border-radius: 8px;
    background: #F1F5F9;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
    color: #94A3B8;
    font-size: 1.25rem;
}

.table-pos-product-row .thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.table-pos-product-row .name {
    font-weight: 600;
    font-size: 0.84rem;
    color: var(--text-primary);
}

.table-pos-product-row .price {
    font-size: 0.76rem;
    color: var(--text-secondary);
    margin-top: 0.15rem;
}

.table-pos-product-row .info {
    flex: 1;
    min-width: 0;
}

.pos-favorite-btn {
    margin-left: auto;
    border: none;
    background: transparent;
    color: #cbd5e1;
    font-size: 1.05rem;
    line-height: 1;
    padding: 0.2rem;
    flex-shrink: 0;
    cursor: pointer;
}

.pos-favorite-btn.is-on {
    color: #f59e0b;
}

.pos-product-variation-badge {
    display: inline-block;
    margin-left: 0.35rem;
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    background: rgba(59, 130, 246, 0.12);
    color: var(--primary);
    font-size: 0.65rem;
    font-weight: 700;
    vertical-align: middle;
}

.pos-product-content-badge {
    display: inline-block;
    margin-left: 0.35rem;
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    background: rgba(16, 185, 129, 0.12);
    color: #059669;
    font-size: 0.65rem;
    font-weight: 700;
    vertical-align: middle;
}

.pos-product-menu-badge {
    display: inline-block;
    margin-left: 0.35rem;
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.15);
    color: #D97706;
    font-size: 0.65rem;
    font-weight: 700;
    vertical-align: middle;
}

.line-menu-summary {
    font-size: 0.72rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
    line-height: 1.35;
}

.line-menu-summary i {
    color: #D97706;
    margin-right: 0.2rem;
}

.pos-menu-step-indicator {
    font-size: 0.9rem;
}

.pos-options-section-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0.75rem 0 0.5rem;
}

.pos-options-section-title:first-child {
    margin-top: 0;
}

.pos-options-hint {
    font-weight: 500;
    color: var(--text-muted);
    font-size: 0.75rem;
}

.pos-content-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.pos-content-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: #fff;
    cursor: pointer;
    user-select: none;
    font-size: 0.82rem;
    font-weight: 600;
    transition: all 0.12s;
}

.pos-content-chip:has(input:checked) {
    border-color: #059669;
    background: rgba(16, 185, 129, 0.1);
    color: #047857;
}

.pos-content-chip input {
    accent-color: #059669;
}

.pos-add-product-modal {
    width: min(1380px, 98vw);
    max-width: min(1380px, 98vw);
    max-height: min(98dvh, 1100px);
    display: flex;
    flex-direction: column;
}

.table-pos-page .pos-add-product-modal {
    width: min(1460px, calc(100vw - 0.75rem));
    max-width: min(1460px, calc(100vw - 0.75rem));
    max-height: min(98dvh, 1120px);
}

.pos-add-product-modal .payment-modal-header {
    padding: 0.7rem 1rem;
}

.pos-add-product-modal .payment-modal-footer {
    padding: 0.65rem 1rem;
}

.pos-add-product-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.65rem;
}

.pos-add-product-footer-total {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.3;
}

.pos-add-product-footer-total strong {
    color: var(--brand);
    font-size: 1.15rem;
    font-weight: 800;
}

.pos-add-product-footer-qty {
    margin-left: 0.45rem;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.pos-add-product-footer-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-left: auto;
}

.pos-add-product-modal .payment-modal-body {
    overflow-y: auto;
    max-height: min(88dvh, 920px);
    padding: 0.7rem 0.85rem 0.85rem;
}

.table-pos-page .pos-add-product-modal .payment-modal-body {
    max-height: min(90dvh, 960px);
}

.pos-menu-layout {
    display: grid;
    grid-template-columns: minmax(200px, 230px) minmax(0, 1fr);
    gap: 0.7rem;
    align-items: stretch;
    min-height: min(68dvh, 620px);
}

.pos-options-single-col {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

.pos-menu-pane {
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    background: #F8FAFC;
    padding: 0.6rem 0.65rem;
    min-height: 0;
}

.pos-menu-pane-qty {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    background: linear-gradient(180deg, #FFF7F2 0%, #F8FAFC 42%);
    border-color: #FDDCC8;
}

.pos-menu-pane-options {
    background: #fff;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    overflow: hidden;
}

.pos-menu-pane-label {
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #64748B;
}

.pos-menu-pane-qty .pos-menu-pane-label {
    color: var(--brand, #F26522);
}

.pos-menu-pane-qty .pos-qty-display-wrap {
    margin-bottom: 0.15rem;
}

.pos-menu-pane-qty .pos-qty-display {
    font-size: 2rem;
    padding: 0.2rem 0;
}

.pos-menu-pane-qty .pos-qty-label {
    font-size: 0.72rem;
}

.pos-menu-pane-qty .pos-numpad {
    gap: 0.28rem;
}

.pos-menu-pane-qty .pos-numpad-key {
    min-height: 36px;
    font-size: 0.92rem;
    border-radius: 8px;
}

.pos-menu-pane-qty .pos-line-note,
.pos-menu-pane-qty textarea,
.pos-menu-pane-qty .form-control {
    font-size: 0.82rem;
    min-height: 2.1rem;
    padding: 0.35rem 0.5rem;
}

.pos-menu-price-preview {
    margin-top: 0;
    padding: 0.45rem 0.55rem;
    border-radius: 10px;
    background: #fff;
    border: 1px solid #E2E8F0;
}

.pos-menu-price-unit {
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--brand, #F26522);
    line-height: 1.15;
}

.pos-menu-price-unit span {
    font-size: 0.72rem;
    font-weight: 600;
    color: #94A3B8;
}

.pos-menu-price-total {
    margin-top: 0.15rem;
    font-size: 0.78rem;
    color: #64748B;
}

.pos-menu-price-total strong {
    color: #0F172A;
    font-weight: 800;
}

.pos-menu-price-breakdown {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    margin-top: 0.35rem;
    padding-top: 0.35rem;
    border-top: 1px dashed #E2E8F0;
}

.pos-menu-price-breakdown span {
    font-size: 0.72rem;
    font-weight: 600;
    color: #475569;
    line-height: 1.25;
}

.pos-variation-check-list {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.pos-menu-options-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.5rem;
    overflow-y: auto;
    flex: 1;
    min-height: 0;
    padding-right: 0.1rem;
    align-content: start;
}

.pos-menu-step-card {
    border: 1px solid #E2E8F0;
    border-radius: 10px;
    background: #F8FAFC;
    padding: 0.5rem 0.55rem;
    min-width: 0;
}

.pos-menu-step-card-title {
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #64748B;
    margin-bottom: 0.3rem;
}

.pos-menu-step-card .pos-options-section-title {
    margin-top: 0.3rem;
    margin-bottom: 0.25rem;
    font-size: 0.72rem;
}

.pos-menu-step-card .pos-variation-radio-option {
    padding: 0.35rem 0.45rem;
}

.pos-menu-step-card .pos-variation-radio-label strong {
    font-size: 0.8rem;
}

.pos-menu-step-card .pos-content-chip {
    padding: 0.3rem 0.55rem;
    font-size: 0.74rem;
}

@media (max-width: 1100px) {
    .pos-menu-options-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .pos-menu-layout {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .pos-menu-options-grid,
    .pos-options-single-col {
        grid-template-columns: 1fr !important;
        max-height: min(42dvh, 360px);
    }
}

/* Masa ürün seçici — tek büyük popup */
.table-pos-page.pos-picker-mode .table-pos-layout > .table-pos-categories,
.table-pos-page.pos-picker-mode .table-pos-layout > .table-pos-products {
    display: none !important;
}

.table-pos-page.pos-picker-mode .table-pos-layout {
    grid-template-columns: 1fr !important;
    grid-template-areas: "cart" !important;
}

.table-pos-page.pos-picker-mode .table-pos-layout > .table-pos-cart {
    grid-area: cart !important;
}

.table-pos-add-products-btn {
    background: linear-gradient(135deg, var(--brand) 0%, var(--primary-dark) 100%) !important;
    color: #fff !important;
    border-color: transparent !important;
    box-shadow: 0 6px 16px rgba(242, 101, 34, 0.28);
}

.table-pos-add-products-btn:hover {
    filter: brightness(1.05);
    color: #fff !important;
}

.table-pos-page.pos-picker-mode .table-pos-drawer-backdrop {
    display: block;
    position: absolute;
    inset: 0;
    z-index: 40;
    background: rgba(15, 23, 42, 0.42);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.18s ease;
}

.table-pos-page.pos-picker-mode.is-products-open .table-pos-drawer-backdrop {
    opacity: 1;
    pointer-events: auto;
}

.table-pos-page.pos-picker-mode {
    position: relative;
}

.table-pos-page.pos-picker-mode .table-pos-products-drawer {
    display: flex;
    position: absolute;
    inset: 0.35rem;
    z-index: 50;
    width: auto;
    height: auto;
    max-height: none;
    border-radius: 16px;
    background: #F4F6FA;
    box-shadow: 0 22px 60px rgba(15, 23, 42, 0.28);
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transform: scale(0.985);
    transition: opacity 0.16s ease, transform 0.16s ease;
}

.table-pos-page.pos-picker-mode.is-products-open .table-pos-products-drawer {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.table-pos-page.pos-picker-mode .table-pos-drawer-header {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.8rem 1rem;
    background: #0F172A;
    color: #fff;
    flex-shrink: 0;
}

.table-pos-page.pos-picker-mode .table-pos-drawer-title {
    font-size: 1.05rem;
    font-weight: 700;
}

.table-pos-page.pos-picker-mode .table-pos-drawer-close {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.table-pos-page.pos-picker-mode .table-pos-drawer-spacer {
    margin-left: auto;
}

.table-pos-page.pos-picker-mode .table-pos-drawer-body {
    flex: 1;
    min-height: 0;
    display: grid;
    grid-template-columns: 132px minmax(0, 1fr);
    gap: 0;
    overflow: hidden;
}

.table-pos-page.pos-picker-mode .table-pos-products-drawer .table-pos-categories {
    display: flex !important;
    flex-direction: column !important;
    max-height: none !important;
    height: 100%;
    border: none;
    border-radius: 0;
    border-right: 1px solid #D5DEEA;
    overflow-y: auto;
}

.table-pos-page.pos-picker-mode .table-pos-products-drawer .table-pos-products {
    display: flex !important;
    flex-direction: column;
    max-height: none !important;
    height: 100%;
    border: none;
    border-radius: 0;
    background: #fff;
    box-shadow: none;
}

.table-pos-page.pos-picker-mode .table-pos-products-drawer .table-pos-product-list:not(.is-list) {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
    gap: 0.65rem;
    overflow: auto;
    flex: 1;
    min-height: 0;
}

body.pos-drawer-open {
    overflow: hidden;
}


.pos-qty-display-wrap {
    text-align: center;
    margin-bottom: 1rem;
}

.pos-qty-display {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
    color: var(--text-primary);
    padding: 0.5rem 0;
}

.pos-qty-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.pos-numpad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
}

.pos-numpad-key {
    border: 1px solid var(--border-color);
    background: #fff;
    border-radius: 12px;
    min-height: 52px;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    transition: background 0.12s, transform 0.08s;
    touch-action: manipulation;
}

.pos-numpad-key:active {
    transform: scale(0.96);
    background: #FFF7ED;
    border-color: var(--brand);
}

.pos-variation-list {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
    margin-bottom: 1rem;
}

.pos-variation-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.75rem 0.875rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.pos-variation-row.is-selected {
    border-color: var(--brand);
    box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.15);
    background: #FFFBEB;
}

.pos-variation-name {
    font-weight: 700;
    font-size: 0.95rem;
}

.pos-variation-price {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 0.15rem;
}

.pos-variation-qty {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-shrink: 0;
}

.pos-variation-qty-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: #fff;
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1;
    touch-action: manipulation;
}

.pos-variation-qty-btn:active {
    background: #FFF7ED;
    border-color: var(--brand);
}

.pos-variation-qty-value {
    min-width: 1.75rem;
    text-align: center;
    font-weight: 800;
    font-size: 1rem;
}

.pos-variation-summary {
    text-align: center;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-primary);
    padding: 0.75rem;
    border-radius: 10px;
    background: #F8FAFC;
}

.table-pos-cart {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 120px);
    overflow: hidden;
}

.table-pos-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.5rem;
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.table-pos-summary-box {
    text-align: center;
    padding: 0.75rem 0.5rem;
    border-radius: 8px;
    background: #F8FAFC;
}

.table-pos-summary-box .label {
    display: block;
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.table-pos-summary-box strong {
    font-size: 1.1rem;
    font-weight: 800;
}

.table-pos-summary-box.total strong { color: var(--primary); }
.table-pos-summary-box.discount strong { color: #9333EA; }
.table-pos-summary-box.paid strong { color: #16A34A; }
.table-pos-summary-box.remaining strong { color: #DC2626; }

.table-pos-selection-bar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.5rem;
    background: #F0FDF4;
    border: 1px solid #BBF7D0;
    border-radius: 10px;
    font-size: 0.875rem;
}

.table-payment-selection-bar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    padding: 0.5rem 0.75rem;
    background: #F0FDF4;
    border: 1px solid #BBF7D0;
    border-radius: 10px;
    font-size: 0.875rem;
}

.text-purple { color: #9333EA !important; }

.table-pos-cart-table tr.is-line-selected {
    background: #F0FDF4;
}

.payment-discount-modes {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.payment-discount-mode-option {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.65rem;
    border: 1px solid #E5E7EB;
    border-radius: 999px;
    font-size: 0.8125rem;
    cursor: pointer;
}

.payment-discount-mode-option.is-selected {
    border-color: var(--primary);
    background: var(--primary-light);
    color: var(--primary-dark);
}

.payment-discount-preview {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.5rem;
    padding: 0.65rem 0.75rem;
    background: #F9FAFB;
    border-radius: 10px;
    font-size: 0.8125rem;
}

.payment-discount-preview span {
    display: block;
    color: #6B7280;
    margin-bottom: 0.15rem;
}

.payment-item-card.is-selected {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.table-pos-cart-table-wrap {
    flex: 1;
    overflow-y: auto;
    position: relative;
    min-height: 180px;
}

.table-pos-payment-history {
    border-top: 1px solid var(--border-color);
    background: #F8FAFC;
}

.table-pos-payment-history-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.55rem 0.75rem;
    border: 0;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    cursor: pointer;
}

.table-pos-payment-history-toggle:hover {
    background: #F1F5F9;
    color: var(--text-primary);
}

.table-pos-payment-history-toggle-label {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.table-pos-payment-history-count {
    font-weight: 600;
    color: var(--text-muted);
    text-transform: none;
}

.table-pos-payment-history-chevron {
    transition: transform 0.15s ease;
    font-size: 0.85rem;
}

.table-pos-payment-history.is-open .table-pos-payment-history-chevron {
    transform: rotate(180deg);
}

.table-pos-payment-history-list {
    max-height: 180px;
    overflow-y: auto;
    padding: 0 0.65rem 0.55rem;
}

.table-pos-payment-history-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.45rem;
    border-radius: 8px;
    background: #fff;
    border: 1px solid var(--border-color);
    margin-bottom: 0.35rem;
}

.table-pos-payment-history-item:last-child {
    margin-bottom: 0;
}

.table-pos-payment-history-body {
    flex: 1;
    min-width: 0;
}

.table-pos-payment-history-main {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
    font-size: 0.86rem;
}

.table-pos-payment-history-meta {
    font-size: 0.72rem;
    color: var(--text-secondary);
    margin-top: 0.1rem;
}

.table-pos-payment-reverse {
    flex-shrink: 0;
    padding: 0.2rem 0.4rem;
    line-height: 1;
}

.table-pos-cart-table {
    width: 100%;
    font-size: 0.92rem;
}

.table-pos-cart-table thead th {
    position: sticky;
    top: 0;
    background: #F8FAFC;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 0.7rem 0.55rem;
    z-index: 1;
    border-bottom: 1px solid var(--border-color);
}

.table-pos-cart-table tbody td {
    padding: 0.625rem 0.55rem;
    vertical-align: middle;
    border-bottom: 1px solid #F1F5F9;
}

.table-pos-cart-table .qty {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.remove-item-modal-hint {
    color: #64748B;
    font-size: 0.88rem;
    margin-bottom: 0.75rem;
}

#removeItemReasonWrap {
    margin-top: 0.75rem;
}

#removeItemReasonInput {
    resize: vertical;
    min-height: 72px;
    border-radius: 12px;
    font-size: 0.92rem;
}

.table-pos-remove-modal .payment-modal-footer .btn-danger {
    min-width: 7rem;
}

.table-pos-cart-table .btn-remove {
    border: none;
    background: transparent;
    color: #DC2626;
    padding: 0.25rem;
    font-size: 1rem;
    min-width: 32px;
    min-height: 32px;
}

.table-pos-cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 1rem;
    color: var(--text-muted);
    text-align: center;
}

.table-pos-cart-empty i {
    font-size: 2.5rem;
    opacity: 0.35;
    margin-bottom: 0.75rem;
}

.table-pos-save-form {
    margin: 0;
    padding: 0.75rem 0.75rem 0;
}

.table-pos-cart-footer {
    border-top: 1px solid var(--border-color);
    background: #FAFBFC;
    margin-top: auto;
}

.table-pos-footer-actions {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    padding: 0.75rem;
}

.table-pos-footer-actions .table-pos-action-btn {
    min-width: 0;
    min-height: 62px;
    font-size: 0.62rem;
}

.table-pos-pay-btn {
    background: linear-gradient(145deg, #22C55E, #16A34A) !important;
    border-color: #16A34A !important;
    color: #fff !important;
    box-shadow: 0 6px 16px rgba(22, 163, 74, 0.35);
    font-weight: 700;
}

.table-pos-pay-btn:hover:not(:disabled) {
    background: linear-gradient(145deg, #16A34A, #15803D) !important;
    border-color: #15803D !important;
    color: #fff !important;
    transform: translateY(-1px);
}

.table-pos-pay-btn:disabled {
    opacity: 0.45;
    box-shadow: none;
}

.table-pos-cart-table tbody tr.is-payable {
    cursor: pointer;
}

.table-pos-cart-table tbody tr.is-payable:hover {
    background: #F0FDF4;
}

.table-pos-cart-table tbody tr.is-line-cancelled {
    opacity: 0.55;
    background: #F9FAFB !important;
    color: #9CA3AF !important;
}

.table-pos-cart-table tbody tr.is-line-cancelled td {
    background: transparent !important;
    color: #9CA3AF !important;
}

.table-pos-cart-table tbody tr.is-line-cancelled:hover {
    background: #F3F4F6 !important;
}

.table-pos-cart-table tbody tr.is-line-cancelled strong {
    text-decoration: line-through;
    color: #9CA3AF !important;
}

.table-pos-cart-table tbody tr.is-line-cancelled .line-menu-summary,
.table-pos-cart-table tbody tr.is-line-cancelled .line-removed-content,
.table-pos-cart-table tbody tr.is-line-cancelled .line-item-note,
.table-pos-cart-table tbody tr.is-line-cancelled .qty {
    color: #9CA3AF !important;
}

.line-cancelled-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.68rem;
    font-weight: 700;
    margin-top: 0.25rem;
    padding: 0.12rem 0.5rem;
    border-radius: 999px;
    background: #DC2626;
    color: #FFFFFF;
}

.line-cancelled-reason {
    font-size: 0.68rem;
    margin-top: 0.15rem;
    color: #6B7280;
    font-style: italic;
}

.table-pos-cart-table tbody tr.is-line-paid {
    opacity: 0.65;
}

.table-pos-cart-table tbody tr.is-line-partial {
    background: linear-gradient(90deg, #FFF7ED 0%, #FFFBEB 100%);
    box-shadow: inset 4px 0 0 #EA580C;
}

.table-pos-cart-table tbody tr.is-line-partial:hover {
    background: linear-gradient(90deg, #FFEDD5 0%, #FEF3C7 100%);
}

.line-pay-status {
    font-size: 0.72rem;
    margin-top: 0.2rem;
    font-weight: 600;
}

.line-pay-status.paid { color: #16A34A; }

.line-pay-status.partial {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-top: 0.35rem;
    padding: 0.3rem 0.6rem;
    border-radius: 8px;
    background: #FFEDD5;
    border: 1px solid #FDBA74;
    color: #C2410C;
    font-size: 0.8rem;
    font-weight: 700;
    box-shadow: 0 1px 4px rgba(234, 88, 12, 0.15);
}

.line-pay-status.partial strong {
    color: #9A3412;
    font-size: 0.92rem;
    letter-spacing: 0.01em;
}

.line-pay-status.tap { color: #16A34A; }

.table-pos-cart-table tr.is-line-editable {
    cursor: pointer;
}

.table-pos-cart-table tr.is-line-editable:hover td {
    background: rgba(37, 99, 235, 0.04);
}

.table-pos-line-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.25rem;
    white-space: nowrap;
}

.btn-line-pay {
    border: none;
    background: rgba(22, 163, 74, 0.12);
    color: #16A34A;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.btn-line-pay:hover {
    background: rgba(22, 163, 74, 0.22);
}

.pos-variation-radio-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.pos-variation-radio-option {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.75rem 0.85rem;
    border: 1px solid var(--border-color, #E2E8F0);
    border-radius: 12px;
    cursor: pointer;
    margin: 0;
}

.pos-variation-radio-option.is-selected {
    border-color: var(--primary);
    background: rgba(37, 99, 235, 0.06);
}

.pos-variation-radio-option input {
    flex-shrink: 0;
}

.pos-variation-radio-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 0.75rem;
}

.pos-variation-radio-label em {
    font-style: normal;
    font-weight: 700;
    color: #16A34A;
}

.pos-qty-min-hint {
    font-size: 0.75rem;
    color: #D97706;
    margin-top: 0.35rem;
}

.pos-kitchen-send-choice {
    margin-top: 0.85rem;
}

.pos-kitchen-send-option {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    padding: 0.7rem 0.85rem;
    border: 1px solid var(--border-color, #E2E8F0);
    border-radius: 12px;
    margin-bottom: 0.45rem;
    cursor: pointer;
}

.pos-kitchen-send-option.is-selected {
    border-color: var(--primary);
    background: rgba(37, 99, 235, 0.06);
}

.pos-kitchen-send-option input {
    margin-top: 0.2rem;
    flex-shrink: 0;
}

.pos-kitchen-send-option span {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.pos-kitchen-send-option strong {
    font-size: 0.9rem;
    color: #0F172A;
}

.pos-kitchen-send-option small {
    font-size: 0.72rem;
    color: #64748B;
}

.table-pos-cart-table tr.is-line-actionable {
    cursor: pointer;
}

.table-pos-cart-table tr.is-line-actionable:hover td {
    background: rgba(37, 99, 235, 0.04);
}

.table-pos-line-action-body {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.table-pos-line-action-btn {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    width: 100%;
    padding: 0.85rem 1rem;
    border: 1px solid var(--border-color, #E2E8F0);
    border-radius: 12px;
    background: #fff;
    text-align: left;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.table-pos-line-action-btn i {
    font-size: 1.1rem;
    color: var(--primary);
    margin-bottom: 0.15rem;
}

.table-pos-line-action-btn span {
    font-weight: 700;
    font-size: 0.95rem;
    color: #0F172A;
}

.table-pos-line-action-btn small {
    font-size: 0.75rem;
    color: #64748B;
}

.table-pos-line-action-btn.is-pay i {
    color: #16A34A;
}

.table-pos-line-action-btn:hover:not(:disabled) {
    border-color: #93C5FD;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.08);
}

.table-pos-line-action-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    box-shadow: none;
}

.table-pos-line-action-btn.is-kitchen i {
    color: #EA580C;
}

.table-move-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    max-height: 360px;
    overflow-y: auto;
}

.table-move-legend {
    display: flex;
    gap: 1rem;
    margin-bottom: 0.75rem;
    font-size: 0.8rem;
    font-weight: 600;
}

.table-move-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.table-move-legend-item.is-empty { color: #16A34A; }
.table-move-legend-item.is-occupied { color: #DC2626; }

.table-move-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    padding: 0.85rem;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    text-align: left;
    transition: all 0.15s;
}

.table-move-item.is-empty {
    border-color: #86EFAC;
    background: linear-gradient(145deg, #F0FDF4, #DCFCE7);
}

.table-move-item.is-empty:hover:not(:disabled) {
    border-color: #16A34A;
    box-shadow: 0 4px 14px rgba(22, 163, 74, 0.2);
    transform: translateY(-1px);
}

.table-move-item.is-occupied {
    border-color: #FECACA;
    background: linear-gradient(145deg, #FEF2F2, #FEE2E2);
    color: #991B1B;
    cursor: pointer;
    opacity: 1;
}

.table-move-item.is-occupied:hover:not(:disabled) {
    border-color: #DC2626;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.22);
    transform: translateY(-1px);
}

.table-move-status {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.table-move-item.is-empty .table-move-status { color: #15803D; }
.table-move-item.is-occupied .table-move-status { color: #DC2626; }

.table-move-zone {
    font-size: 0.7rem;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.table-pos-print-area {
    padding: 1.5rem;
    font-family: monospace;
}

.print-header { text-align: center; margin-bottom: 1rem; }
.print-header h2 { font-size: 1.1rem; margin: 0; }
.print-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
.print-table th, .print-table td { padding: 0.35rem 0; border-bottom: 1px dashed #ccc; }
.print-note { margin-top: 1rem; font-style: italic; }

.tile-badge.pending {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
}

.tile-kitchen-hint {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    opacity: 0.9;
    margin-top: 0.2rem;
}

.tables-kitchen-alert {
    border-left: 4px solid #F59E0B;
}

.table-pos-kitchen-btn.has-unsent-kitchen {
    background: var(--kitchen-pending) !important;
    color: #fff !important;
    border-color: var(--kitchen-pending-dark) !important;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.25);
}

.table-pos-kitchen-btn.has-unsent-kitchen:hover:not(:disabled) {
    background: var(--kitchen-pending-dark) !important;
    color: #fff !important;
    border-color: var(--kitchen-pending-dark) !important;
}

.table-pos-kitchen-btn.has-unsent-kitchen i {
    color: #fff !important;
}

.table-pos-kitchen-print-btn {
    border-color: #86efac;
    background: #f0fdf4;
    color: #166534;
}

.table-pos-kitchen-print-btn:hover:not(:disabled) {
    background: #dcfce7;
    border-color: #4ade80;
    color: #14532d;
}

.line-kitchen-status.unsent {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin-top: 0.3rem;
    padding: 0.22rem 0.5rem;
    border-radius: 6px;
    background: var(--kitchen-pending-light);
    border: 1px solid #93C5FD;
    color: var(--kitchen-pending-dark);
    font-size: 0.72rem;
    font-weight: 700;
}

.kitchen-print-label {
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: 0.08em;
    margin: 0.25rem 0;
}

.kitchen-print-table {
    font-size: 1rem;
}

.kitchen-print-table td {
    padding: 0.5rem 0;
    vertical-align: top;
}

.kitchen-line-by {
    font-size: 0.75rem;
    color: #666;
    font-weight: normal;
    margin-top: 0.15rem;
}

.line-removed-content,
.kitchen-line-removed {
    font-size: 0.78rem;
    color: #DC2626;
    font-weight: 600;
    margin-top: 0.2rem;
}

.line-item-note,
.kitchen-line-note,
.print-line-note {
    font-size: 0.78rem;
    color: var(--primary);
    font-weight: 600;
    margin-top: 0.2rem;
}

.print-line-removed {
    font-size: 0.78rem;
    color: #666;
    margin-top: 0.15rem;
}

.pos-line-note-field {
    margin-top: 0.85rem;
}

.pos-line-note-input {
    font-size: 0.9rem;
    resize: vertical;
    min-height: 2.75rem;
}

.line-removed-content i,
.kitchen-line-removed {
    font-weight: 700;
}

.kitchen-line-removed {
    font-size: 0.85rem;
}

.line-price-cell {
    text-align: right;
    line-height: 1.25;
}

.line-price-main {
    font-weight: 700;
}

.line-price-meta {
    margin-top: 0.15rem;
    font-size: 0.72rem;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.1rem;
}

.line-list-price {
    color: #94A3B8;
    text-decoration: line-through;
    font-weight: 500;
}

.line-discount-badge {
    color: #9333EA;
    font-weight: 700;
    white-space: nowrap;
}

.table-pos-cart-table td.is-price-editable {
    cursor: pointer;
}

.table-pos-cart-table td.is-price-editable:hover .line-price-main {
    color: var(--brand, var(--primary));
}

.line-price-discount-preview {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.65rem 0.75rem;
    border-radius: 10px;
    background: #F5F3FF;
    border: 1px solid #DDD6FE;
    font-size: 0.9rem;
}

.table-pos-save-btn {
    width: 100%;
    min-height: 52px;
    border: none;
    border-radius: 10px;
    background: var(--brand);
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    transition: opacity 0.15s;
}

.table-pos-save-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.pos-toast {
    position: fixed;
    left: 50%;
    bottom: 1.25rem;
    transform: translateX(-50%);
    background: #166534;
    color: #fff;
    padding: 0.75rem 1.25rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: var(--shadow-md);
    z-index: 2000;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    pointer-events: none;
    display: none;
    opacity: 0;
    visibility: hidden;
}

.pos-toast.show {
    display: block;
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.pos-toast.is-error {
    background: #DC2626;
}

/* Phone order — table-pos layout (masa siparişi ile aynı mobil yerleşim) */
.phone-order-page.table-pos-page {
    height: calc(100vh - 1rem);
    min-height: 0;
    overflow: hidden;
}

.phone-order-cart {
    display: flex;
    flex-direction: column;
    min-height: 0;
    flex: 1;
}

.phone-order-cart-main {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.phone-order-form {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.phone-order-page .table-pos-cart-table-wrap,
.phone-order-cart-table-wrap {
    flex: 1 1 auto;
    min-height: 300px;
    max-height: none;
}

.phone-order-details-panels {
    flex: 0 0 auto;
    max-height: 34vh;
    overflow-y: auto;
    border-top: 1px solid var(--border-color, #e5e7eb);
}

.phone-order-actions {
    display: flex;
    gap: 0.5rem;
    padding: 0.65rem 0.85rem;
    border-top: 1px solid var(--border-color, #e5e7eb);
    background: #fff;
    flex-shrink: 0;
}

.phone-order-page .phone-order-actions.table-pos-footer-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.phone-checkout-modal {
    width: min(96vw, 920px);
}

.phone-checkout-total-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    margin-bottom: 1rem;
    border: 1px solid #FED7AA;
    border-radius: 12px;
    background: #FFF7ED;
}

.phone-checkout-total-card span,
.phone-checkout-footer-total span {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.phone-checkout-total-card strong,
.phone-checkout-footer-total strong {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--brand, #EA580C);
}

.phone-checkout-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.phone-checkout-footer-total {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 7rem;
}

.phone-checkout-footer-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-left: auto;
}

.table-pos-cart-table tr.is-new-line-editable {
    cursor: pointer;
}

.table-pos-cart-table tr.is-new-line-editable:hover {
    background: #FFF7ED;
}

.table-pos-cart-table .line-edit-hint {
    font-size: 0.68rem;
    font-weight: 600;
    color: var(--brand);
    margin-top: 0.15rem;
}

.phone-checkout-modal .phone-order-fields {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.phone-order-kitchen-btn {
    flex: 1;
    min-height: 48px;
    border: 1px solid #d97706;
    border-radius: 10px;
    background: #fff7ed;
    color: #c2410c;
    font-weight: 700;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
}

.phone-order-kitchen-btn:hover:not(:disabled) {
    background: #ffedd5;
}

.phone-order-kitchen-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.phone-order-kitchen-btn.has-unsent-kitchen {
    background: #f26522;
    border-color: #f26522;
    color: #fff;
    animation: phone-kitchen-pulse 1.6s ease-in-out infinite;
}

.phone-order-actions .phone-order-save-btn {
    flex: 1;
    margin: 0;
}

@keyframes phone-kitchen-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(242, 101, 34, 0.35); }
    50% { box-shadow: 0 0 0 6px rgba(242, 101, 34, 0); }
}

.phone-order-summary {
    grid-template-columns: 1fr;
    flex-shrink: 0;
}

.phone-order-panel {
    padding: 0.75rem 0.85rem;
    border-top: 1px solid var(--border-color, #e5e7eb);
    flex-shrink: 0;
}

.phone-order-panel-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: #374151;
    margin-bottom: 0.65rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.phone-order-panel-title i {
    color: var(--brand, #F26522);
}

.phone-order-field-full {
    grid-column: 1 / -1;
}

.phone-order-field-name {
    grid-column: 1 / -1;
    position: relative;
}

.phone-order-input-row {
    display: flex;
    gap: 0.35rem;
}

.phone-order-input-row .phone-order-input {
    flex: 1;
    min-width: 0;
}

.phone-order-search-btn {
    width: 44px;
    min-height: 44px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: #f9fafb;
    color: #374151;
    flex-shrink: 0;
}

.phone-order-search-btn:hover {
    background: #f3f4f6;
}

.phone-order-textarea {
    resize: vertical;
    min-height: 72px;
}

.phone-order-customer-results {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    z-index: 25;
}

.phone-checkout-modal .phone-order-customer-results {
    position: static;
    top: auto;
    margin-top: 0.65rem;
    z-index: 30;
}

.phone-order-save-btn {
    width: 100%;
    min-height: 48px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    box-shadow: 0 4px 14px rgba(22, 163, 74, 0.28);
}

.phone-order-save-btn:hover {
    filter: brightness(1.03);
}

.phone-order-save-btn:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    box-shadow: none;
}

.phone-order-payment-grid,
.ny-order-payment-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.45rem;
}

.phone-order-payment-grid.phone-order-payment-grid-2,
.ny-order-payment-grid.phone-order-payment-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.phone-order-payment-grid .payment-type-card,
.ny-order-payment-grid .payment-type-card {
    min-height: 58px;
    padding: 0.45rem 0.35rem;
    font-size: 0.68rem;
    line-height: 1.2;
    text-align: center;
}

.phone-order-payment-grid .payment-type-card i,
.ny-order-payment-grid .payment-type-card i {
    font-size: 1rem;
    margin-bottom: 0.15rem;
}

.phone-order-cart-footer {
    max-height: min(52vh, 460px);
    overflow-y: auto;
}

.phone-order-footer-form {
    margin: 0;
}

.phone-order-footer-section {
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.phone-order-footer-section:last-of-type {
    border-bottom: none;
}

.phone-order-save-wrap {
    padding: 0.75rem;
    background: #fff;
    position: sticky;
    bottom: 0;
    border-top: 1px solid var(--border-color);
}

.phone-order-save-hint {
    line-height: 1.35;
}

.phone-address-picker-wrap {
    margin-top: 0.35rem;
}

.phone-address-picker {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.phone-address-picker-hint {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.15rem;
}

.phone-address-option-other .phone-address-card {
    border-style: dashed;
}

.phone-address-option {
    margin: 0;
    cursor: pointer;
}

.phone-address-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.phone-address-card {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    padding: 0.65rem 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    background: #fff;
    min-height: 52px;
    transition: border-color 0.12s, background 0.12s;
}

.phone-address-card strong {
    font-size: 0.78rem;
    color: var(--text-primary);
}

.phone-address-card span {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.35;
}

.phone-address-option input:checked + .phone-address-card {
    border-color: var(--brand);
    background: #FFF7ED;
}

.phone-address-manual-wrap textarea {
    min-height: 72px;
    resize: vertical;
}

/* Phone order customer search */

.phone-order-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.customer-search-wrap {
    position: relative;
}

.customer-search-wrap > i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #94A3B8;
    z-index: 2;
}

.customer-search-input {
    width: 100%;
    padding: 0.75rem 0.75rem 0.75rem 2.5rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    font-size: 0.9rem;
    min-height: 48px;
    background: #fff;
}

.customer-search-results {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    box-shadow: var(--shadow-md);
    max-height: 220px;
    overflow-y: auto;
    z-index: 20;
}

.customer-search-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    width: 100%;
    padding: 0.75rem 1rem;
    border: none;
    border-bottom: 1px solid #F1F5F9;
    background: #fff;
    text-align: left;
    cursor: pointer;
    min-height: 52px;
}

.customer-search-item:hover,
.customer-search-item:active {
    background: #FFF7ED;
}

.customer-search-item strong {
    font-size: 0.875rem;
    color: var(--text-primary);
}

.customer-search-item span {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.customer-search-empty {
    padding: 1rem;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.selected-customer-chip {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: #ECFDF5;
    border: 1px solid #A7F3D0;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #065F46;
}

.btn-clear-customer {
    margin-left: auto;
    border: none;
    background: transparent;
    color: #065F46;
    padding: 0.25rem;
    font-size: 1rem;
    min-width: 32px;
    min-height: 32px;
}

.phone-order-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.phone-order-field label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
    display: block;
}

.phone-order-input {
    width: 100%;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.9rem;
    min-height: 44px;
}

.table-pos-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: var(--text-muted);
}

/* Tables floor redesign — salon plan */
.main-content:has(.tables-floor-page) {
    padding: 0.55rem 0.6rem 0.7rem;
}

.tables-floor-page {
    --floor-empty: #0D9488;
    --floor-empty-soft: #F0FDFA;
    --floor-empty-line: #5EEAD4;
    --floor-occupied: #E11D48;
    --floor-occupied-soft: #FFF1F2;
    --floor-occupied-line: #FDA4AF;
    --floor-kitchen: #2563EB;
    --floor-kitchen-soft: #F8FAFF;
    --floor-kitchen-line: #93C5FD;
    --floor-alert: #D97706;
    --floor-alert-soft: #FFFBEB;
    --floor-alert-line: #FCD34D;
    max-width: none;
    width: 100%;
    margin: 0;
    min-height: calc(100vh - var(--header-height) - 1.25rem);
    padding: 1.15rem 1.2rem 1.4rem;
    border-radius: 20px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(248, 250, 252, 0.96)),
        repeating-linear-gradient(
            90deg,
            transparent,
            transparent 23px,
            rgba(26, 41, 64, 0.018) 23px,
            rgba(26, 41, 64, 0.018) 24px
        ),
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 23px,
            rgba(26, 41, 64, 0.018) 23px,
            rgba(26, 41, 64, 0.018) 24px
        );
    border: 1px solid #E2E8F0;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.95) inset,
        0 18px 40px rgba(26, 41, 64, 0.06);
}

.tables-floor-hero {
    margin-bottom: 1.2rem;
    padding: 1rem 1.1rem 1.05rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid #E8EEF5;
    box-shadow: 0 8px 20px rgba(26, 41, 64, 0.03);
}

.tables-floor-top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.95rem;
}

.tables-floor-top-left {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.tables-floor-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: #111827;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: 0 8px 18px rgba(17, 24, 39, 0.18);
}

.tables-floor-title {
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    margin: 0;
    color: #0F172A;
}

.tables-floor-subtitle {
    margin: 0.15rem 0 0;
    color: #64748B;
    font-size: 0.82rem;
    font-weight: 500;
}

.tables-floor-manage-btn {
    border: 1px solid #E2E8F0;
    background: #fff;
    color: #0F172A;
    border-radius: 11px;
    font-weight: 600;
    padding: 0.5rem 0.95rem;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.tables-floor-manage-btn:hover {
    border-color: #CBD5E1;
    color: var(--primary);
    background: #FFF7F2;
}

.tables-floor-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
    gap: 0.6rem;
    margin-bottom: 0.85rem;
}

.tables-stat-card {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    background: #F8FAFC;
    border: 1px solid #EEF2F7;
    border-radius: 12px;
    padding: 0.7rem 0.85rem;
}

.tables-stat-card .stat-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #475569;
    font-size: 0.92rem;
    flex-shrink: 0;
    border: 1px solid #E2E8F0;
}

.tables-stat-card .stat-label {
    display: block;
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #94A3B8;
    margin-bottom: 0.05rem;
}

.tables-stat-card .stat-value {
    display: block;
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.1;
    color: #0F172A;
    letter-spacing: -0.02em;
}

.tables-stat-card.stat-empty .stat-icon { color: var(--floor-empty); border-color: var(--floor-empty-line); background: var(--floor-empty-soft); }
.tables-stat-card.stat-empty .stat-value { color: var(--floor-empty); }
.tables-stat-card.stat-pending-kitchen .stat-icon { color: var(--floor-kitchen); border-color: var(--floor-kitchen-line); background: var(--floor-kitchen-soft); }
.tables-stat-card.stat-pending-kitchen .stat-value { color: var(--floor-kitchen); }
.tables-stat-card.stat-occupied .stat-icon { color: var(--floor-occupied); border-color: var(--floor-occupied-line); background: var(--floor-occupied-soft); }
.tables-stat-card.stat-occupied .stat-value { color: var(--floor-occupied); }
.tables-stat-card.stat-revenue .stat-icon { color: var(--brand); border-color: #FED7AA; background: var(--primary-light); }
.tables-stat-card.stat-revenue .stat-value { color: var(--brand); font-size: 1rem; }

.tables-floor-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.tables-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    font-weight: 600;
    color: #64748B;
    background: #fff;
    border: 1px solid #E8EEF5;
    border-radius: 999px;
    padding: 0.28rem 0.65rem;
}

.tables-legend-item i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

.tables-legend-item.is-empty i { background: var(--floor-empty); }
.tables-legend-item.is-occupied i { background: var(--floor-occupied); }
.tables-legend-item.is-pending-kitchen i { background: var(--floor-kitchen); }
.tables-legend-item.is-pending-qr i { background: var(--floor-alert); }

.tables-floor-filters {
    margin-bottom: 1.15rem;
    padding: 0.28rem;
    background: #fff;
    border: 1px solid #E8EEF5;
    border-radius: 12px;
    width: fit-content;
    max-width: 100%;
    box-shadow: 0 4px 12px rgba(26, 41, 64, 0.03);
}

.tables-floor-filters .zone-filter-btn {
    border: none;
    background: transparent;
    box-shadow: none;
    padding: 0.45rem 0.95rem;
    border-radius: 9px;
    color: #64748B;
    font-weight: 600;
}

.tables-floor-filters .zone-filter-btn:hover {
    background: #F8FAFC;
    color: #0F172A;
    border-color: transparent;
}

.tables-floor-filters .zone-filter-btn.active {
    background: #0F172A;
    color: #fff;
    box-shadow: none;
}

.tables-floor-empty-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    border-radius: 18px;
    display: grid;
    place-items: center;
    background: #F1F5F9;
    color: var(--text-muted);
    font-size: 1.75rem;
}

.tables-zone-block {
    margin-bottom: 1.15rem;
    padding: 1rem 1.05rem 1.15rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid #E8EEF5;
    box-shadow: 0 10px 24px rgba(26, 41, 64, 0.03);
}

.tables-zone-block:last-child {
    margin-bottom: 0;
}

.tables-zone-label {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    font-weight: 700;
    font-size: 0.88rem;
    margin-bottom: 0.9rem;
    padding-bottom: 0.7rem;
    border-bottom: 1px solid #F1F5F9;
    color: #0F172A;
}

.tables-zone-mark {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 0 3px rgba(242, 101, 34, 0.14);
    flex-shrink: 0;
}

.tables-zone-name {
    font-weight: 700;
    letter-spacing: -0.02em;
}

.tables-zone-count {
    margin-left: auto;
    font-size: 0.7rem;
    font-weight: 600;
    color: #94A3B8;
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
}

.tables-floor-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(164px, 1fr));
    gap: 0.8rem;
}

.tables-floor-tile-wrap {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.tables-floor-tile-wrap.is-wide {
    grid-column: span 2;
}

.tables-tile-action-form,
.tables-tile-qr-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.tables-tile-action-btn {
    font-size: 0.72rem;
    padding: 0.28rem 0.55rem;
    border-radius: 8px;
    font-weight: 700;
}

.tables-floor-tile {
    --tile-accent: #94A3B8;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    min-height: 128px;
    padding: 1rem 1rem 0.95rem 1.15rem;
    border-radius: 14px;
    text-decoration: none;
    overflow: hidden;
    border: 1px solid transparent;
    color: #0F172A;
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.07);
}

.tables-floor-tile::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 5px;
    background: var(--tile-accent);
}

.tables-floor-tile::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(165deg, rgba(255, 255, 255, 0.45), transparent 48%);
    pointer-events: none;
}

.tables-floor-tile:hover {
    transform: translateY(-3px);
    color: inherit;
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.12);
}

.tables-floor-tile.is-empty {
    --tile-accent: #0F766E;
    background: linear-gradient(145deg, #99F6E4 0%, #5EEAD4 48%, #2DD4BF 100%);
    border-color: #14B8A6;
    color: #115E59;
}

.tables-tile-waiter-btn {
    color: #92400E !important;
    background: #FEF3C7 !important;
    border: 1px solid #F59E0B !important;
    font-weight: 700;
}

.tables-tile-waiter-btn:hover {
    color: #78350F !important;
    background: #FDE68A !important;
}

@keyframes table-waiter-blink {
    0%, 100% {
        box-shadow: 0 8px 18px rgba(217, 119, 6, 0.14);
    }
    50% {
        box-shadow: 0 0 0 2px rgba(251, 191, 36, 0.4), 0 12px 24px rgba(245, 158, 11, 0.2);
    }
}

.tables-floor-tile.is-occupied {
    --tile-accent: #BE123C;
    background: linear-gradient(145deg, #FECDD3 0%, #FDA4AF 48%, #FB7185 100%);
    border-color: #FB7185;
    color: #9F1239;
}

.tables-floor-tile.is-waiter-call {
    --tile-accent: #B45309;
    background: linear-gradient(145deg, #FDE68A 0%, #FCD34D 50%, #FBBF24 100%);
    border-color: #F59E0B;
    color: #92400E;
    animation: table-waiter-blink 1.35s ease-in-out infinite;
}

.tables-floor-tile.is-waiter-call:hover,
.tables-floor-tile.is-pending-qr:hover,
.tables-floor-tile.is-pending-kitchen:hover,
.tables-floor-tile.is-empty:hover,
.tables-floor-tile.is-occupied:hover {
    color: inherit;
}

.tables-floor-tile.is-pending-qr {
    --tile-accent: #B45309;
    background: linear-gradient(145deg, #FDE68A 0%, #FCD34D 50%, #F59E0B 100%);
    border-color: #D97706;
    color: #78350F;
    box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.22), 0 10px 20px rgba(217, 119, 6, 0.14);
}

.tables-floor-tile.is-pending-kitchen {
    --tile-accent: #1D4ED8;
    background: linear-gradient(145deg, #BFDBFE 0%, #93C5FD 48%, #60A5FA 100%);
    border-color: #3B82F6;
    color: #1E3A8A;
}

.tables-floor-tile.is-wide {
    grid-column: span 2;
}

.tile-top {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 0.4rem;
}

.tile-name {
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.tile-badge {
    font-size: 0.62rem;
    font-weight: 700;
    padding: 0.2rem 0.48rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    flex-shrink: 0;
    color: inherit;
}

.tables-floor-tile.is-empty .tile-badge,
.tables-floor-tile.is-occupied .tile-badge,
.tables-floor-tile.is-pending-kitchen .tile-badge,
.tables-floor-tile.is-waiter-call .tile-badge,
.tables-floor-tile.is-pending-qr .tile-badge {
    background: rgba(255, 255, 255, 0.55);
    border-color: rgba(255, 255, 255, 0.72);
}

.tile-capacity {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.7rem;
    font-weight: 600;
    opacity: 0.65;
    margin-bottom: 0.4rem;
}

.tile-amount {
    position: relative;
    z-index: 1;
    font-size: 1.18rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-top: auto;
}

.tile-time {
    position: relative;
    z-index: 1;
    font-size: 0.72rem;
    font-weight: 600;
    opacity: 0.68;
    margin-top: 0.18rem;
}

.tile-hint {
    position: relative;
    z-index: 1;
    margin-top: auto;
    font-size: 0.78rem;
    font-weight: 600;
    opacity: 0.72;
}

.tile-kitchen-hint {
    position: relative;
    z-index: 1;
    font-weight: 600;
}

/* Table floor skins — selectable from Settings / Tables */
.tables-skin-preview {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 5px;
    height: 56px;
    padding: 8px;
    border-radius: 10px;
    margin-bottom: 0.15rem;
    background: #F8FAFC;
    border: 1px solid #E8EEF5;
}

.tables-skin-preview span {
    display: block;
    min-width: 0;
}

.tables-skin-preview-classic {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.8), #F8FAFC),
        repeating-linear-gradient(90deg, transparent, transparent 7px, rgba(15, 23, 42, 0.04) 7px, rgba(15, 23, 42, 0.04) 8px);
}

.tables-skin-preview-classic span {
    border-radius: 6px;
}

.tables-skin-preview-classic span:nth-child(1) { background: #5EEAD4; }
.tables-skin-preview-classic span:nth-child(2) { background: #FDA4AF; }
.tables-skin-preview-classic span:nth-child(3) { background: #93C5FD; }
.tables-skin-preview-classic span:nth-child(4) { background: #FCD34D; }

.tables-skin-preview-round {
    background: #ECFEFF;
    align-items: center;
}

.tables-skin-preview-round span {
    width: 28px;
    height: 28px;
    justify-self: center;
    align-self: center;
    border-radius: 50%;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.7) inset;
}

.tables-skin-preview-round span:nth-child(1) { background: #14B8A6; }
.tables-skin-preview-round span:nth-child(2) { background: #FB7185; }
.tables-skin-preview-round span:nth-child(3) { background: #60A5FA; }
.tables-skin-preview-round span:nth-child(4) { background: #F59E0B; }

.tables-skin-preview-compact {
    gap: 3px;
    padding: 6px;
    background: #FFF7F2;
}

.tables-skin-preview-compact span {
    border-radius: 4px;
}

.tables-skin-preview-compact span:nth-child(1) { background: #99F6E4; }
.tables-skin-preview-compact span:nth-child(2) { background: #FECDD3; }
.tables-skin-preview-compact span:nth-child(3) { background: #BFDBFE; }
.tables-skin-preview-compact span:nth-child(4) { background: #FDE68A; }

.tables-skin-preview-night {
    background: #0F172A;
    border-color: #1E293B;
}

.tables-skin-preview-night span {
    border-radius: 7px;
}

.tables-skin-preview-night span:nth-child(1) { background: #2DD4BF; box-shadow: 0 0 8px rgba(45, 212, 191, 0.45); }
.tables-skin-preview-night span:nth-child(2) { background: #FB7185; box-shadow: 0 0 8px rgba(251, 113, 133, 0.45); }
.tables-skin-preview-night span:nth-child(3) { background: #60A5FA; box-shadow: 0 0 8px rgba(96, 165, 250, 0.45); }
.tables-skin-preview-night span:nth-child(4) { background: #FBBF24; box-shadow: 0 0 8px rgba(251, 191, 36, 0.45); }

.tables-floor-page.tables-skin-round .tables-floor-grid {
    grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
    justify-items: center;
    gap: 1.15rem 0.85rem;
}

.tables-floor-page.tables-skin-round .tables-floor-tile-wrap {
    width: 100%;
    max-width: 176px;
    align-items: center;
    container-type: inline-size;
    container-name: round-table;
}

.tables-floor-page.tables-skin-round .tables-floor-tile-wrap.is-wide {
    grid-column: span 1;
    max-width: 188px;
}

.tables-floor-page.tables-skin-round .tables-floor-tile {
    width: min(100%, 168px);
    aspect-ratio: 1;
    height: auto;
    min-height: 0;
    border-radius: 50%;
    padding: 18% 16%;
    box-sizing: border-box;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    gap: 0.12rem;
    box-shadow:
        0 10px 22px rgba(15, 23, 42, 0.12),
        inset 0 0 0 6px rgba(255, 255, 255, 0.28);
}

.tables-floor-page.tables-skin-round .tables-floor-tile-wrap.is-wide .tables-floor-tile {
    width: min(100%, 180px);
}

.tables-floor-page.tables-skin-round .tables-floor-tile::before {
    display: none;
}

.tables-floor-page.tables-skin-round .tables-floor-tile::after {
    background: radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.55), transparent 52%);
}

.tables-floor-page.tables-skin-round .tile-top {
    width: 100%;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.12rem;
    margin-bottom: 0;
    flex: 0 0 auto;
}

.tables-floor-page.tables-skin-round .tile-name {
    width: 100%;
    max-width: 100%;
    font-size: clamp(0.62rem, 11cqi, 0.86rem);
    font-weight: 800;
    line-height: 1.15;
    text-align: center;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
}

.tables-floor-page.tables-skin-round .tile-badge {
    margin: 0 auto;
    font-size: 0.54rem;
    padding: 0.12rem 0.38rem;
    max-width: 92%;
}

.tables-floor-page.tables-skin-round .tile-capacity,
.tables-floor-page.tables-skin-round .tile-amount,
.tables-floor-page.tables-skin-round .tile-time,
.tables-floor-page.tables-skin-round .tile-hint,
.tables-floor-page.tables-skin-round .tile-kitchen-hint {
    width: 100%;
    max-width: 100%;
    margin: 0;
    text-align: center;
    justify-content: center;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tables-floor-page.tables-skin-round .tile-capacity {
    font-size: clamp(0.55rem, 8cqi, 0.68rem);
    margin-bottom: 0;
    opacity: 0.8;
}

.tables-floor-page.tables-skin-round .tile-amount {
    font-size: clamp(0.72rem, 12cqi, 1.02rem);
    line-height: 1.1;
    margin-top: 0.05rem;
}

.tables-floor-page.tables-skin-round .tile-hint,
.tables-floor-page.tables-skin-round .tile-kitchen-hint,
.tables-floor-page.tables-skin-round .tile-time {
    font-size: clamp(0.52rem, 7.5cqi, 0.68rem);
    line-height: 1.15;
    white-space: nowrap;
}

.tables-floor-page.tables-skin-round .tables-floor-tile.is-occupied .tile-name,
.tables-floor-page.tables-skin-round .tables-floor-tile.is-pending-kitchen .tile-name,
.tables-floor-page.tables-skin-round .tables-floor-tile.is-pending-qr .tile-name,
.tables-floor-page.tables-skin-round .tables-floor-tile.is-waiter-call .tile-name {
    -webkit-line-clamp: 1;
    line-clamp: 1;
    font-size: clamp(0.58rem, 10cqi, 0.78rem);
}

.tables-floor-page.tables-skin-round .tables-tile-action-form,
.tables-floor-page.tables-skin-round .tables-tile-qr-actions {
    justify-content: center;
}

.tables-floor-page.tables-skin-compact .tables-floor-grid {
    grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
    gap: 0.5rem;
}

.tables-floor-page.tables-skin-compact .tables-floor-tile-wrap.is-wide {
    grid-column: span 1;
}

.tables-floor-page.tables-skin-compact .tables-floor-tile {
    min-height: 92px;
    padding: 0.65rem 0.7rem 0.6rem 0.8rem;
    border-radius: 10px;
}

.tables-floor-page.tables-skin-compact .tables-floor-tile::before {
    width: 3px;
}

.tables-floor-page.tables-skin-compact .tile-name {
    font-size: 0.88rem;
}

.tables-floor-page.tables-skin-compact .tile-amount {
    font-size: 0.98rem;
}

.tables-floor-page.tables-skin-compact .tile-capacity,
.tables-floor-page.tables-skin-compact .tile-time,
.tables-floor-page.tables-skin-compact .tile-hint {
    font-size: 0.64rem;
    margin-bottom: 0.15rem;
}

.tables-floor-page.tables-skin-night {
    background:
        radial-gradient(1200px 420px at 8% -10%, rgba(14, 165, 233, 0.16), transparent 55%),
        radial-gradient(900px 380px at 100% 0%, rgba(245, 158, 11, 0.1), transparent 50%),
        linear-gradient(180deg, #0B1220 0%, #111827 100%);
    border-color: #1F2A3D;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
    color: #E2E8F0;
}

.tables-floor-page.tables-skin-night .tables-floor-hero,
.tables-floor-page.tables-skin-night .tables-zone-block {
    background: rgba(15, 23, 42, 0.72);
    border-color: #243044;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

.tables-floor-page.tables-skin-night .tables-floor-title,
.tables-floor-page.tables-skin-night .tables-zone-label,
.tables-floor-page.tables-skin-night .tables-zone-name {
    color: #F8FAFC;
}

.tables-floor-page.tables-skin-night .tables-floor-subtitle,
.tables-floor-page.tables-skin-night .tables-zone-count {
    color: #94A3B8;
}

.tables-floor-page.tables-skin-night .tables-floor-icon {
    background: #F59E0B;
    color: #111827;
    box-shadow: 0 8px 18px rgba(245, 158, 11, 0.28);
}

.tables-floor-page.tables-skin-night .tables-floor-manage-btn {
    background: #1E293B;
    border-color: #334155;
    color: #E2E8F0;
}

.tables-floor-page.tables-skin-night .tables-floor-manage-btn:hover {
    background: #334155;
    color: #F8FAFC;
    border-color: #475569;
}

.tables-floor-page.tables-skin-night .tables-stat-card {
    background: #0F172A;
    border-color: #1E293B;
}

.tables-floor-page.tables-skin-night .tables-stat-card .stat-icon {
    background: #1E293B;
    border-color: #334155;
    color: #CBD5E1;
}

.tables-floor-page.tables-skin-night .tables-stat-card .stat-value {
    color: #F8FAFC;
}

.tables-floor-page.tables-skin-night .tables-zone-label {
    border-bottom-color: #1E293B;
}

.tables-floor-page.tables-skin-night .tables-floor-tile {
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.28);
}

.tables-floor-page.tables-skin-night .tables-floor-tile.is-empty {
    background: linear-gradient(145deg, #134E4A 0%, #0F766E 55%, #14B8A6 100%);
    border-color: #2DD4BF;
    color: #CCFBF1;
}

.tables-floor-page.tables-skin-night .tables-floor-tile.is-occupied {
    background: linear-gradient(145deg, #881337 0%, #BE123C 55%, #FB7185 100%);
    border-color: #FB7185;
    color: #FFE4E6;
}

.tables-floor-page.tables-skin-night .tables-floor-tile.is-pending-kitchen {
    background: linear-gradient(145deg, #1E3A8A 0%, #2563EB 55%, #60A5FA 100%);
    border-color: #93C5FD;
    color: #DBEAFE;
}

.tables-floor-page.tables-skin-night .tables-floor-tile.is-waiter-call,
.tables-floor-page.tables-skin-night .tables-floor-tile.is-pending-qr {
    background: linear-gradient(145deg, #92400E 0%, #D97706 55%, #FBBF24 100%);
    border-color: #F59E0B;
    color: #FFFBEB;
}

.tables-floor-page.tables-skin-night .tile-badge {
    background: rgba(15, 23, 42, 0.28);
    border-color: rgba(255, 255, 255, 0.18);
}

@media (max-width: 1200px) {
    .table-pos-layout {
        grid-template-columns: 120px minmax(0, 1fr) minmax(320px, 38%);
        grid-template-areas: "cats products cart";
    }
    .tables-floor-stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 991.98px) {
    .table-pos-layout {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto 1fr;
    }
    .table-pos-categories {
        flex-direction: row;
        overflow-x: auto;
        max-height: none;
    }
    .table-pos-category {
        white-space: nowrap;
        min-width: 120px;
        border-left: none;
        border-bottom: 4px solid transparent;
    }
    .table-pos-category.active {
        border-bottom-color: var(--primary-dark);
    }
    .tables-floor-tile.is-wide {
        grid-column: span 1;
    }
}

@media (max-width: 991.98px) {
    .login-brand-panel {
        display: none;
    }

    .login-form-panel {
        width: 100%;
        min-width: unset;
    }

    .sidebar {
        transform: translateX(-100%);
    }

    .app-shell.sidebar-open .sidebar {
        transform: translateX(0);
    }

    .main-wrapper {
        margin-left: 0;
    }

    .top-header {
        padding: 0 1rem;
    }
}

/* Cash register */
.cash-register-page {
    --cash-report-border: #e8ecf1;
    --cash-report-stripe: #f8fafc;
}

.cash-register-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text-primary);
}

.cash-toolbar-btn {
    border: 1px solid var(--border-color);
    background: #fff;
    font-weight: 500;
    font-size: 0.875rem;
    padding: 0.45rem 0.9rem;
    box-shadow: var(--shadow-sm);
}

.cash-toolbar-btn:hover {
    background: #f8fafc;
    border-color: #d5dbe3;
}

.cash-filter-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.65rem 0.75rem;
}

.cash-filter-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.cash-filter-btn {
    font-weight: 600;
    padding: 0.375rem 0.9rem;
    min-height: 31px;
    line-height: 1.25;
    box-shadow: var(--shadow-sm);
    white-space: nowrap;
}

.cash-register-period-bar {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 0.75rem 1.25rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    box-shadow: var(--shadow-sm);
}

.cash-register-filter-bar {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 0.85rem 1.25rem;
    box-shadow: var(--shadow-sm);
}

.cash-filter-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    padding-bottom: 0.35rem;
}

.cash-filter-sublabel {
    display: block;
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.15rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.cash-filter-field .form-control {
    min-width: 11.5rem;
}

.cash-filter-separator {
    color: var(--text-secondary);
    padding-bottom: 0.5rem;
    line-height: 1;
}

.cash-report-card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.cash-report-card-header {
    padding: 0.85rem 1rem;
    font-weight: 600;
    font-size: 0.95rem;
    border-bottom: 1px solid var(--cash-report-border);
    background: #fff;
}

.cash-report-table {
    font-size: 0.875rem;
}

.cash-report-table thead th {
    background: #f1f5f9;
    border-bottom: 1px solid var(--cash-report-border);
    font-weight: 600;
    color: var(--text-secondary);
    white-space: nowrap;
    padding: 0.55rem 0.75rem;
}

.cash-report-table tbody td {
    border-color: var(--cash-report-border);
    padding: 0.5rem 0.75rem;
    vertical-align: middle;
}

.cash-report-table tbody tr:nth-child(even):not(.cash-report-total-row) {
    background: var(--cash-report-stripe);
}

.cash-report-total-row {
    background: #f8fafc;
}

.cash-report-total-row td {
    border-top: 2px solid #dbe3ec;
}

.cash-report-balance-cell {
    background: #22c55e !important;
    color: #fff !important;
}

.cash-report-scroll {
    max-height: 420px;
    overflow-y: auto;
}

.cash-report-row-link {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.cash-report-row-link:hover {
    background: #eef4ff !important;
}

.cash-row-chevron {
    font-size: 0.75rem;
    color: #94a3b8;
    margin-left: 0.25rem;
    vertical-align: middle;
}

.cash-detail-stat {
    background: #fff;
    border: 1px solid var(--cash-report-border);
    border-radius: 14px;
    padding: 1rem 1.1rem;
}

.cash-detail-stat .label {
    display: block;
    font-size: 0.78rem;
    color: #64748b;
    margin-bottom: 0.25rem;
}

.cash-detail-stat strong {
    font-size: 1.25rem;
}

.cash-detail-stat.income strong { color: #059669; }
.cash-detail-stat.expense strong { color: #dc2626; }
.cash-detail-stat.net strong { color: var(--primary, #FF8C42); }

.cash-detail-row-link {
    cursor: pointer;
}

.cash-detail-row-link:hover {
    background: #f8fafc;
}

.cash-detail-total-row {
    background: #f1f5f9;
}

.cash-detail-total-row td {
    border-top: 2px solid #cbd5e1;
}

/* Staff / User management */
.staff-user-form-page {
    max-width: 880px;
}

.staff-user-form-page--wide {
    max-width: 1100px;
}

.staff-user-form-header {
    padding-top: 0.25rem;
}

.staff-user-form-back {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.8125rem;
    color: var(--text-muted);
    text-decoration: none;
    margin-bottom: 0.75rem;
}

.staff-user-form-back:hover {
    color: var(--brand);
}

.staff-user-form-card .card-body-custom {
    padding: 1.25rem 1.5rem 1.5rem;
}

.staff-form-section {
    padding-bottom: 0;
}

.staff-form-section--last {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.staff-form-section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.staff-form-section-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.staff-form-section-hint {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.staff-active-switch {
    padding: 0.75rem 1rem;
    background: #F8FAFC;
    border: 1px solid var(--border-color);
    border-radius: 10px;
}

/* Bootstrap form-switch negative margin fix (panel forms) */
.panel-card .form-check.form-switch,
.customer-form-card .form-check.form-switch,
.staff-active-switch.form-check.form-switch,
.customer-active-switch.form-check.form-switch {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding-left: 0 !important;
    min-height: auto;
}

.panel-card .form-check.form-switch .form-check-input,
.customer-form-card .form-check.form-switch .form-check-input,
.staff-active-switch .form-check-input,
.customer-active-switch .form-check-input {
    float: none !important;
    margin-left: 0 !important;
    margin-top: 0 !important;
    flex-shrink: 0;
    position: relative;
}

.panel-card .form-check.form-switch .form-check-label,
.customer-form-card .form-check.form-switch .form-check-label,
.staff-active-switch .form-check-label,
.customer-active-switch .form-check-label {
    padding-left: 0 !important;
    margin-left: 0;
    line-height: 1.3;
}

.staff-branch-all-toggle .staff-form-section-hint {
    padding-left: 3.25rem;
}

.staff-user-form-card .form-check:not(.form-switch) {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-left: 0 !important;
    min-height: auto;
}

.staff-user-form-card .form-check:not(.form-switch) .form-check-input {
    float: none !important;
    margin-left: 0 !important;
    margin-top: 0 !important;
    flex-shrink: 0;
}

.staff-user-form-card .form-check:not(.form-switch) .form-check-label {
    padding-left: 0 !important;
}

.staff-user-form-actions {
    margin-top: 0.25rem;
    padding-top: 0;
    border-top: none;
}

.permission-sections-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 0.875rem;
}

.permission-section-card {
    background: #F8FAFC;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0.875rem;
    height: 100%;
}

.permission-section-label {
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    margin-bottom: 0.65rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.permission-tiles {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.permission-tile,
.branch-tile {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.75rem;
    margin: 0;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
    user-select: none;
    width: 100%;
}

.permission-tile:hover,
.branch-tile:hover {
    border-color: #CBD5E1;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.permission-tile.is-checked,
.branch-tile.is-checked {
    background: var(--primary-light);
    border-color: var(--primary);
}

.permission-tile-input,
.branch-tile-input {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0 !important;
    opacity: 0;
}

.permission-tile-icon,
.branch-tile-icon {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: #F1F5F9;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.permission-tile.is-checked .permission-tile-icon,
.branch-tile.is-checked .branch-tile-icon {
    background: #fff;
    color: var(--primary);
}

.permission-tile-label {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-primary);
    flex: 1;
    line-height: 1.2;
}

.permission-tile-check {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 1.5px solid #CBD5E1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    color: transparent;
    flex-shrink: 0;
    margin-left: auto;
    transition: all 0.15s;
}

.permission-tile.is-checked .permission-tile-check,
.branch-tile.is-checked .permission-tile-check {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

.permission-tile.permission-tile--locked {
    background: #F8FAFC;
    border-color: #E2E8F0;
    cursor: default;
    opacity: 0.92;
}

.permission-tile.permission-tile--locked .permission-tile-icon {
    background: #E2E8F0;
    color: #64748B;
}

.permission-tile.permission-tile--locked .permission-tile-check {
    background: #94A3B8;
    border-color: #94A3B8;
    color: #fff;
}

.permission-accordion {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.permission-accordion-item {
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: #fff;
    overflow: hidden;
}

.permission-accordion-item.is-page-enabled {
    border-color: #CBD5E1;
}

.permission-accordion-item.is-expanded .permission-accordion-toggle i {
    transform: rotate(180deg);
}

.permission-accordion-header {
    display: flex;
    align-items: stretch;
    gap: 0;
}

.permission-accordion-page {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.75rem;
    margin: 0;
    cursor: pointer;
    user-select: none;
}

.permission-accordion-page.is-checked {
    background: var(--primary-light);
}

.permission-accordion-page-label {
    flex: 1;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-primary);
}

.permission-accordion-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    border: 0;
    border-left: 1px solid var(--border-color);
    background: #F8FAFC;
    color: var(--text-secondary);
    cursor: pointer;
    transition: background 0.15s;
}

.permission-accordion-toggle:hover {
    background: #F1F5F9;
    color: var(--primary);
}

.permission-accordion-toggle i {
    transition: transform 0.2s;
}

.permission-accordion-item:not(.is-page-enabled) .permission-accordion-toggle {
    opacity: 0.35;
    pointer-events: none;
}

.permission-accordion-body {
    padding: 0.5rem 0.75rem 0.75rem;
    border-top: 1px solid var(--border-color);
    background: #FAFBFC;
}

.permission-accordion-ops-hint {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-secondary);
    margin-bottom: 0.45rem;
}

.permission-tiles--nested {
    gap: 0.3rem;
}

.permission-tiles--nested .permission-tile {
    background: #fff;
}

.branch-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 0.5rem;
}

.branch-tile-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.branch-tile-name {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-primary);
}

.branch-tile-meta {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.staff-permission-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.2rem 0.5rem;
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-secondary);
    background: #F1F5F9;
    border: 1px solid var(--border-color);
    border-radius: 6px;
}

.staff-permission-badge--more {
    background: #E2E8F0;
    color: var(--text-primary);
}

.staff-list-panel {
    padding: 0;
    overflow: hidden;
}

.staff-role-pill {
    display: inline-block;
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 0.15rem;
}

/* Reports */
.reports-page {
    display: flex;
    flex-direction: column;
    height: calc(100vh - var(--header-height, 56px) - 1.75rem);
    min-height: 0;
    overflow: hidden;
}

.reports-page-header {
    flex-shrink: 0;
    margin-bottom: 0.75rem;
}

.reports-kpi-block {
    margin-bottom: 1rem;
}

.reports-kpi-title {
    margin: 0 0 0.45rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #64748b;
}

.reports-kpi-grid {
    display: grid;
    gap: 0.55rem;
}

.reports-kpi-grid.cols-6 {
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.reports-kpi-grid.cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.reports-kpi {
    min-width: 0;
    background: #fff;
    border: 1px solid #e6ebf2;
    border-radius: 12px;
    padding: 0.7rem 0.8rem 0.75rem;
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.03);
}

.reports-kpi-label {
    display: block;
    margin-bottom: 0.28rem;
    font-size: 0.68rem;
    font-weight: 600;
    line-height: 1.25;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #94a3b8;
}

.reports-kpi-value {
    display: block;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reports-kpi.tone-brand .reports-kpi-value { color: #ea580c; }
.reports-kpi.tone-ok .reports-kpi-value { color: #15803d; }
.reports-kpi.tone-warn .reports-kpi-value { color: #b45309; }

@media (max-width: 1200px) {
    .reports-kpi-grid.cols-6 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .reports-kpi-grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
    .reports-kpi-grid.cols-6,
    .reports-kpi-grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .reports-kpi-value { font-size: 0.95rem; }
}

.reports-page-header-compact {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.35rem 1rem;
    margin-bottom: 0.5rem;
}

.reports-page-header-compact .reports-page-title {
    font-size: 1.15rem;
}

.reports-quick-toolbar {
    flex-shrink: 0;
    margin-bottom: 0.5rem;
    border: 1px solid #dbeafe;
    border-radius: 12px;
    background: linear-gradient(180deg, #f8fbff 0%, #fff 100%);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.reports-quick-toolbar-inner {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 0.75rem;
    padding: 0.5rem 0.75rem;
}

.reports-quick-block {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.45rem 0.6rem;
}

.reports-quick-form {
    flex: 1 1 320px;
    min-width: 0;
}

.reports-quick-icon {
    width: 1.85rem;
    height: 1.85rem;
    border-radius: 8px;
    background: var(--primary-light, #eff6ff);
    color: var(--primary, #3b82f6);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.95rem;
}

.reports-quick-icon-summary {
    background: #fff7f2;
    color: #F26522;
}

.reports-quick-label {
    font-weight: 600;
    font-size: 0.8125rem;
    white-space: nowrap;
    color: var(--text-dark, #1e293b);
}

.reports-quick-divider {
    width: 1px;
    height: 1.75rem;
    background: #e2e8f0;
    flex-shrink: 0;
    align-self: center;
}

.reports-quick-dates {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: nowrap;
}

.reports-quick-dates .form-control-sm {
    width: 8.75rem;
    min-height: 2rem;
    padding-top: 0.2rem;
    padding-bottom: 0.2rem;
}

.reports-quick-date-sep {
    color: #94a3b8;
    font-size: 0.75rem;
    user-select: none;
}

.reports-quick-actions {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.reports-quick-actions .btn,
.reports-quick-btn {
    white-space: nowrap;
    min-height: 2rem;
    padding-top: 0.2rem;
    padding-bottom: 0.2rem;
}

.reports-hub-scroll,
.reports-content-scroll {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 0.25rem;
}

.reports-page-title {
    font-size: 1.35rem;
    font-weight: 700;
}

.reports-back-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
}

.reports-back-link:hover {
    color: var(--primary);
}

.reports-hub-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0.45rem;
}

.reports-hub-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.55rem 0.75rem;
    background: #fff;
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 12px;
    color: inherit;
    text-decoration: none;
    transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}

.reports-hub-item:hover {
    border-color: rgba(59, 130, 246, 0.35);
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
    transform: translateY(-1px);
    color: inherit;
}

.reports-hub-icon {
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 8px;
    background: var(--primary-light, var(--primary-light));
    color: var(--primary, var(--primary));
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.reports-hub-label {
    flex: 1;
    font-weight: 600;
    font-size: 0.875rem;
}

.reports-hub-arrow {
    color: #94a3b8;
    font-size: 0.85rem;
}

.report-summary-hub {
    border: 1px solid #dbeafe;
    background: linear-gradient(180deg, #f8fbff 0%, #fff 100%);
}

.reports-hub-item-featured {
    border-color: #F26522;
    background: linear-gradient(135deg, #fff7f2 0%, #fff 100%);
}

.reports-hub-item-featured .reports-hub-icon {
    background: linear-gradient(135deg, #F26522, #ff8c42);
    color: #fff;
}

.report-summary-kpi {
    background: #fff;
    border: 1px solid #e8ecf1;
    border-radius: 14px;
    padding: 1rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.report-summary-kpi-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.report-summary-kpi-label {
    font-size: 0.78rem;
    color: #64748b;
}

.report-summary-kpi-value {
    font-size: 1.15rem;
    color: #1e293b;
}

.report-summary-kpi.kpi-orange .report-summary-kpi-icon { background: #fff4ed; color: #F26522; }
.report-summary-kpi.kpi-green .report-summary-kpi-icon { background: #ecfdf5; color: #059669; }
.report-summary-kpi.kpi-blue .report-summary-kpi-icon { background: #eff6ff; color: #2563eb; }
.report-summary-kpi.kpi-purple .report-summary-kpi-icon { background: #f5f3ff; color: #7c3aed; }

.reports-summary-sections {
    display: flex;
    flex-direction: column;
}

.reports-summary-section-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid #e8ecf1;
    text-decoration: none;
    color: inherit;
    transition: background 0.15s ease;
}

.reports-summary-section-item:last-child {
    border-bottom: none;
}

.reports-summary-section-item:hover {
    background: #f8fafc;
}

.reports-summary-section-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: #f1f5f9;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #F26522;
    flex-shrink: 0;
}

.reports-summary-section-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.reports-user-filter,
.reports-extra-filter {
    min-width: 160px;
}

.reports-data-table thead th {
    background: #F8FAFC;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.reports-data-row {
    cursor: pointer;
}

.reports-data-row:hover {
    background: #F8FAFC;
}

.report-detail-fields {
    display: grid;
    grid-template-columns: minmax(120px, 38%) 1fr;
    gap: 0.35rem 1rem;
    margin-bottom: 1rem;
}

.report-detail-fields dt {
    margin: 0;
    font-size: 0.78rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.report-detail-fields dd {
    margin: 0;
    font-size: 0.9rem;
}

.report-detail-lines {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 360px;
    overflow-y: auto;
}

.report-detail-line {
    padding: 0.55rem 0.7rem;
    border-radius: 8px;
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
}

.report-detail-line-text {
    font-size: 0.88rem;
    font-weight: 600;
}

.report-detail-line-sub {
    font-size: 0.76rem;
    color: var(--text-secondary);
    margin-top: 0.15rem;
}

.reports-table-footer {
    background: #FAFAFA;
}

.reports-table-tfoot .reports-total-row td {
    background: #FFF4ED;
    border-top: 2px solid var(--primary, #F26522);
    font-weight: 700;
    color: var(--sidebar-bg, #1A2940);
}

.reports-table-tfoot .reports-total-row td.text-end {
    font-variant-numeric: tabular-nums;
}

/* Settings */
.settings-page {
    display: flex;
    flex-direction: column;
    height: calc(100dvh - var(--header-height, 56px) - 1.5rem);
    min-height: 0;
    max-height: calc(100dvh - var(--header-height, 56px) - 1.5rem);
    overflow: hidden;
}

.settings-layout {
    display: flex;
    gap: 0.85rem;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.settings-nav {
    width: 210px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    min-height: 0;
    padding: 0;
    overflow: hidden;
    border-radius: 12px;
    border: 1px solid var(--border-color, #E5E7EB);
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.settings-nav-head {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 0.75rem;
    font-weight: 700;
    font-size: 0.82rem;
    border-bottom: 1px solid var(--border-color, #E5E7EB);
    color: var(--text-primary, #1E293B);
    flex-shrink: 0;
    background: linear-gradient(180deg, #fafbfc 0%, #fff 100%);
}

.settings-nav-head i {
    color: var(--primary);
    font-size: 1.05rem;
}

.settings-nav-list {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    padding: 0.25rem 0.35rem 0.35rem 0.5rem;
}

.settings-nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.42rem 0.55rem;
    border-radius: 8px;
    color: var(--text-muted, #64748B);
    text-decoration: none;
    font-size: 0.8125rem;
    font-weight: 500;
    line-height: 1.25;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    border-left: 3px solid transparent;
}

.settings-nav-link i {
    font-size: 0.9rem;
    flex-shrink: 0;
    width: 1rem;
    text-align: center;
    opacity: 0.85;
}

.settings-nav-link span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.settings-nav-link:hover {
    background: #FFF7ED;
    color: var(--primary);
}

.settings-nav-link.active {
    background: linear-gradient(90deg, #FFF7ED 0%, rgba(255, 247, 237, 0.35) 100%);
    color: var(--primary);
    font-weight: 600;
    border-left-color: var(--primary, #F26522);
}

.settings-nav-link.active i {
    opacity: 1;
}

.settings-nav-groups {
    display: flex;
    flex-direction: column;
    gap: 0.05rem;
    padding: 0.25rem 0.35rem 0.4rem;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}

.settings-nav-groups::-webkit-scrollbar {
    width: 5px;
}

.settings-nav-groups::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 999px;
}

.settings-nav-group {
    border-radius: 8px;
    flex-shrink: 0;
}

.settings-nav-group-title {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.32rem 0.45rem;
    font-size: 0.66rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    cursor: pointer;
    list-style: none;
    color: var(--text-muted, #64748B);
    border-radius: 8px;
    user-select: none;
}

.settings-nav-group-title span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.settings-nav-group-title::-webkit-details-marker { display: none; }

.settings-nav-group-title:hover {
    background: #f8fafc;
    color: var(--text-primary);
}

.settings-nav-group[open] .settings-nav-group-title {
    color: var(--primary, #F05A28);
    background: #FFF7ED;
}

.settings-nav-group-chevron {
    margin-left: auto;
    font-size: 0.7rem;
    transition: transform 0.15s;
    flex-shrink: 0;
}

.settings-nav-group[open] .settings-nav-group-chevron {
    transform: rotate(180deg);
}

.settings-nav-group .settings-nav-list {
    padding: 0.1rem 0 0.25rem 0.35rem;
    margin-left: 0.55rem;
    border-left: 1px solid #e2e8f0;
}

.settings-nav-group .settings-nav-link {
    font-size: 0.78rem;
    padding: 0.28rem 0.42rem;
}

.settings-main {
    flex: 1;
    min-width: 0;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 0.35rem;
    scrollbar-width: thin;
}

.settings-shell {
    flex-shrink: 0;
    margin-bottom: 0.85rem;
    background: #fff;
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 14px;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.settings-shell-bar {
    display: flex;
    align-items: stretch;
    gap: 0.35rem;
    padding: 0.35rem 0.45rem 0;
    border-bottom: 1px solid #eef2f6;
}

.settings-groups,
.settings-pages {
    display: flex;
    gap: 0.2rem;
    overflow-x: auto;
    scrollbar-width: thin;
}

.settings-groups {
    flex: 1;
    min-width: 0;
    align-items: flex-end;
}

.settings-group,
.settings-page-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    text-decoration: none;
    white-space: nowrap;
    flex: 0 0 auto;
}

.settings-group {
    padding: 0.62rem 0.9rem 0.7rem;
    border-radius: 10px 10px 0 0;
    color: #64748b;
    font-size: 0.86rem;
    font-weight: 600;
    border: 1px solid transparent;
}

.settings-group i {
    font-size: 0.95rem;
    opacity: 0.75;
}

.settings-group:hover {
    color: var(--text-primary, #1e293b);
    background: #f8fafc;
}

.settings-group.active {
    color: var(--text-primary, #1e293b);
    background: #fff7ed;
    box-shadow: inset 0 -2px 0 var(--primary, #F26522);
}

.settings-group.active i {
    color: var(--primary, #F26522);
    opacity: 1;
}

.settings-pages {
    padding: 0.45rem 0.55rem;
    background: #f8fafc;
}

.settings-page-link {
    padding: 0.38rem 0.72rem;
    border-radius: 8px;
    color: #64748b;
    font-size: 0.8rem;
    font-weight: 600;
}

.settings-page-link i {
    font-size: 0.85rem;
}

.settings-page-link:hover {
    color: var(--text-primary, #1e293b);
    background: #fff;
}

.settings-page-link.active {
    color: var(--primary, #F26522);
    background: #fff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.settings-nav-toggle {
    display: none;
}

@media (min-width: 992px) {
    .settings-nav,
    .settings-nav-backdrop {
        display: none !important;
    }
}

.settings-form .panel-card {
    margin-bottom: 0.75rem !important;
}

.settings-form .panel-card:last-of-type {
    margin-bottom: 0 !important;
}

.settings-save-btn {
    font-weight: 600;
    padding: 0.65rem 1rem;
    margin-top: 0.75rem;
    position: sticky;
    bottom: 0;
    z-index: 2;
}

.settings-toggle-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 10px;
    background: #FAFAFA;
    margin: 0;
    cursor: pointer;
}

.settings-module-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.settings-module-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 12px;
    background: #fff;
}

.settings-module-copy strong {
    display: block;
    margin-bottom: 0.2rem;
}

.settings-module-toggle {
    min-width: 140px;
    background: #FAFAFA;
}

.settings-toggle-label {
    font-size: 0.875rem;
    line-height: 1.35;
}

.settings-switch {
    position: relative;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.settings-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.settings-switch-slider {
    position: absolute;
    inset: 0;
    background: #CBD5E1;
    border-radius: 999px;
    transition: background 0.2s;
}

.settings-switch-slider:before {
    content: "";
    position: absolute;
    width: 18px;
    height: 18px;
    left: 3px;
    top: 3px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.2s;
}

.settings-switch input[type="checkbox"]:checked + .settings-switch-slider,
.settings-switch input[type="checkbox"]:checked ~ .settings-switch-slider {
    background: var(--primary, var(--primary));
}

.settings-switch input[type="checkbox"]:checked + .settings-switch-slider:before,
.settings-switch input[type="checkbox"]:checked ~ .settings-switch-slider:before {
    transform: translateX(20px);
}

.settings-summary-list {
    display: grid;
    gap: 0.85rem;
}

.settings-summary-list dt {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.15rem;
}

.settings-summary-list dd {
    margin: 0;
    font-weight: 600;
    word-break: break-word;
}

.settings-api-key code {
    display: block;
    font-size: 0.75rem;
    padding: 0.5rem;
    background: #F8FAFC;
    border-radius: 6px;
}

.settings-mini-card {
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 10px;
    padding: 0.75rem;
    background: #fff;
}

@media (max-width: 991.98px) {
    .settings-layout {
        flex-direction: column;
    }

    /* Mobil ayar menüsü panel-mobile.css içinde yönetilir */
}

/* Utility */
.text-brand { color: var(--primary) !important; }
.bg-brand { background: var(--primary) !important; }

/* Settings QR list */
.settings-qr-panel .card-body-custom {
    padding: 1rem;
}

.settings-qr-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
}

.settings-qr-card {
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 12px;
    background: #fff;
    padding: 0.85rem;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.settings-qr-card-head {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.settings-qr-card-head strong {
    font-size: 1rem;
}

.settings-qr-zone {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.settings-qr-image-wrap {
    display: flex;
    justify-content: center;
    padding: 0.5rem;
    background: #FAFAFA;
    border-radius: 10px;
    border: 1px dashed var(--border-color, #E5E7EB);
}

.settings-qr-image {
    width: 160px;
    height: 160px;
    object-fit: contain;
}

.settings-qr-url {
    font-size: 0.68rem;
    color: var(--text-muted);
    word-break: break-all;
    line-height: 1.35;
    max-height: 2.7em;
    overflow: hidden;
}

.settings-qr-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.settings-qr-print-area {
    display: none;
}

@media print {
    body * { visibility: hidden; }
    .settings-qr-print-area, .settings-qr-print-area *,
    #handoverPrintArea, #handoverPrintArea * { visibility: visible; }
    .settings-qr-print-area {
        display: block !important;
        position: fixed;
        inset: 0;
        padding: 2rem;
        text-align: center;
    }
    #handoverPrintArea {
        display: block !important;
        position: fixed;
        inset: 0;
        padding: 0;
        background: #fff;
    }
    .settings-qr-print-sheet img {
        width: 220px;
        height: 220px;
    }
}

.settings-tables-panel .table-panel th,
.settings-tables-panel .table-panel td {
    vertical-align: middle;
}

.settings-delivery-zones-list {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.delivery-district-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.delivery-district-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin: 0;
    padding: 0.35rem 0.7rem;
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 999px;
    background: #fff;
    cursor: pointer;
    font-size: 0.9rem;
}

.delivery-district-chip:has(input:checked) {
    border-color: var(--brand, #c45c26);
    background: rgba(196, 92, 38, 0.08);
}

.delivery-mahalle-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1rem;
}

.delivery-mahalle-search {
    flex: 1 1 240px;
    max-width: 360px;
}

.delivery-mahalle-list {
    max-height: 560px;
    overflow: auto;
}

.delivery-mahalle-group-title {
    position: sticky;
    top: 0;
    z-index: 1;
    padding: 0.55rem 1rem;
    font-weight: 600;
    font-size: 0.85rem;
    background: #f8f6f3;
    border-bottom: 1px solid var(--border-color, #E5E7EB);
}

.delivery-mahalle-row {
    display: grid;
    grid-template-columns: auto 1fr minmax(108px, 128px) minmax(108px, 128px);
    gap: 0.65rem;
    align-items: center;
    margin: 0;
    padding: 0.55rem 1rem;
    border-bottom: 1px solid var(--border-color, #E5E7EB);
    cursor: pointer;
}

.delivery-mahalle-row.is-selected {
    background: rgba(196, 92, 38, 0.05);
}

.delivery-mahalle-name {
    font-weight: 500;
}

.delivery-mahalle-fee,
.delivery-mahalle-money {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.delivery-mahalle-money small {
    font-size: 0.68rem;
    font-weight: 700;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    white-space: nowrap;
}

.delivery-mahalle-money input {
    width: 4.4rem;
    text-align: right;
}

.delivery-custom-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 1rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color, #E5E7EB);
}

.settings-delivery-zone-row {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color, #E5E7EB);
}

.settings-delivery-zone-row:last-child {
    border-bottom: none;
}

.settings-inline-row .form-label {
    font-size: 0.85rem;
    margin-bottom: 0.35rem;
}

.settings-printers-list {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.settings-printer-row {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color, #E5E7EB);
}

.settings-printer-row:last-child {
    border-bottom: none;
}

.settings-printer-roles {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.settings-printer-role-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.65rem;
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 999px;
    background: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    user-select: none;
    margin: 0;
    transition: border-color 0.15s, background 0.15s;
}

.settings-printer-role-chip.is-selected {
    border-color: var(--brand, #F97316);
    background: #FFF7ED;
    color: #C2410C;
}

.settings-printer-role-chip input {
    accent-color: var(--brand, #F97316);
    margin: 0;
}

.settings-category-list .settings-category-row .form-control[readonly] {
    background: #F8FAFC;
    color: #64748B;
}

.list-sort-handle,
.settings-category-handle,
.menu-sort-handle {
    cursor: grab;
    color: #94A3B8;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}

span.list-sort-handle,
span.settings-category-handle,
span.menu-sort-handle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.4rem;
    min-height: 2.25rem;
    font-size: 1.1rem;
}

td.list-sort-handle,
td.menu-sort-handle {
    text-align: center;
    vertical-align: middle;
    width: 2.4rem;
}

.list-sort-handle:active,
.settings-category-handle:active,
.menu-sort-handle:active,
html.list-sorting,
html.list-sorting * {
    cursor: grabbing !important;
}

html.list-sorting {
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}

tbody[data-list-sortable] tr[data-id] {
    cursor: grab;
}

tbody[data-list-sortable] tr[data-id] img,
tbody[data-list-sortable] tr[data-id] .menu-thumb,
tbody[data-list-sortable] tr[data-id] .menu-thumb-placeholder {
    -webkit-user-drag: none;
    user-select: none;
    pointer-events: none;
}

.list-sort-handle.is-locked,
.settings-category-handle.is-locked,
.menu-sort-handle.menu-sort-disabled {
    cursor: default !important;
    opacity: 0.55;
}

.is-dragging,
.settings-category-row.is-dragging,
tr.menu-sort-dragging {
    opacity: 0.55;
    user-select: none;
}

.settings-category-row.is-dragging .form-control {
    background: #F8FAFC;
}

.grid-search-wrap {
    position: relative;
    padding: 0.85rem 1rem 0.7rem;
}

.card-body-custom:not(.p-0) > .grid-search-wrap {
    padding-left: 0;
    padding-right: 0;
    padding-top: 0;
}

.card-body-custom.p-0 > .grid-search-wrap,
.panel-card > .grid-search-wrap {
    border-bottom: 1px solid var(--border-color, #E5E7EB);
    background: var(--card-bg);
}

.grid-search-icon {
    position: absolute;
    left: 1.55rem;
    top: 50%;
    transform: translateY(-50%);
    color: #94A3B8;
    pointer-events: none;
    font-size: 0.95rem;
}

.card-body-custom:not(.p-0) > .grid-search-wrap .grid-search-icon {
    left: 0.85rem;
}

.grid-search-input {
    padding-left: 2.35rem;
    padding-right: 2.35rem;
    border-radius: 8px;
    border-color: var(--border-color, #E5E7EB);
    font-size: 0.9rem;
}

.grid-search-input:focus {
    border-color: var(--brand, #F97316);
    box-shadow: 0 0 0 0.15rem rgba(249, 115, 22, 0.15);
}

.grid-search-clear {
    position: absolute;
    right: 1.35rem;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    color: #94A3B8;
    font-size: 1.25rem;
    line-height: 1;
    padding: 0.15rem 0.35rem;
    cursor: pointer;
}

.grid-search-clear:hover {
    color: #475569;
}

.grid-search-hidden,
tr.grid-search-empty[hidden] {
    display: none !important;
}

.grid-search-empty {
    color: #64748B;
}

.settings-banner-upload .settings-banner-thumb {
    width: 100%;
    max-width: 520px;
    max-height: 200px;
    object-fit: contain;
    border-radius: 10px;
    border: 1px solid var(--border-color, #E5E7EB);
    background: #F8FAFC;
}

.settings-banner-preview {
    padding: 0.5rem;
    border-radius: 10px;
    background: #F8FAFC;
    border: 1px dashed var(--border-color, #E5E7EB);
}

/* Public QR menu */
.qr-menu-body {
    font-family: 'Inter', 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--qr-bg, #F9FAFB);
    margin: 0;
    color: var(--qr-text, #111827);
    -webkit-font-smoothing: antialiased;
}

.qr-menu-body[data-theme="ocean"] { --qr-bg: #F0F9FF; --qr-text: #0F172A; }
.qr-menu-body[data-theme="forest"] { --qr-bg: #F0FDF4; --qr-text: #0F172A; }
.qr-menu-body[data-theme="dark"] { --qr-bg: #0F172A; --qr-text: #F8FAFC; }

.qr-menu-page {
    --qr-primary: #C2410C;
    --qr-primary-dark: #9A3412;
    --qr-primary-light: #FFF7ED;
    --qr-success: #15803D;
    --qr-success-dark: #166534;
    --qr-bg: #F3F4F6;
    --qr-card: #FFFFFF;
    --qr-card-alt: #F9FAFB;
    --qr-text: #111827;
    --qr-text-muted: #6B7280;
    --qr-border: #E5E7EB;
    --qr-shadow: rgba(17, 24, 39, 0.06);
    --qr-radius: 16px;
    --qr-radius-sm: 12px;

    max-width: 480px;
    margin: 0 auto;
    padding: 0.75rem 0.85rem 3rem;
}

.qr-menu-page {
    --qr-primary-light: color-mix(in srgb, var(--qr-primary) 10%, white);
    --qr-primary-dark: color-mix(in srgb, var(--qr-primary) 85%, black);
    --qr-success: color-mix(in srgb, var(--qr-primary) 25%, #16A34A);
    --qr-success-dark: color-mix(in srgb, var(--qr-primary) 35%, #15803D);
}

.qr-menu-page[data-theme="ocean"] {
    --qr-primary: #0EA5E9;
    --qr-bg: #F0F9FF;
}

.qr-menu-page[data-theme="forest"] {
    --qr-primary: #16A34A;
    --qr-bg: #F0FDF4;
}

.qr-menu-page[data-theme="dark"] {
    --qr-primary: #F59E0B;
    --qr-primary-light: #422006;
    --qr-bg: #0F172A;
    --qr-card: #1E293B;
    --qr-card-alt: #334155;
    --qr-text: #F8FAFC;
    --qr-text-muted: #94A3B8;
    --qr-border: #334155;
    --qr-shadow: rgba(0, 0, 0, 0.35);
}

.qr-menu-top-banner {
    border-radius: var(--qr-radius);
    overflow: hidden;
    margin-bottom: 0.85rem;
    box-shadow: 0 4px 20px var(--qr-shadow);
    border: 1px solid var(--qr-border);
}

.qr-menu-top-banner-img {
    width: 100%;
    aspect-ratio: 3 / 1;
    object-fit: cover;
    display: block;
}

.qr-menu-header {
    position: relative;
    background: var(--qr-card);
    border-radius: var(--qr-radius);
    padding: 0;
    margin-bottom: 1.15rem;
    border: 1px solid var(--qr-border);
    box-shadow: 0 2px 8px var(--qr-shadow);
    overflow: hidden;
}

.qr-menu-brand-block {
    padding: 1.25rem 1.2rem 1rem;
    text-align: center;
}

.qr-menu-custom-html {
    margin: 0 1rem 0.85rem;
    font-size: 0.88rem;
}

.qr-menu-custom-html .alert {
    margin-bottom: 0;
    border-radius: var(--qr-radius-sm);
}

/* Harmonized buttons */
.qr-menu-page .qr-menu-btn-primary,
.qr-menu-page .btn-primary.qr-menu-add-btn,
.qr-menu-page .qr-menu-product-add-btn {
    background: var(--qr-primary);
    border: none;
    color: #fff;
    font-weight: 600;
    border-radius: var(--qr-radius-sm);
    padding: 0.65rem 1rem;
    box-shadow: 0 2px 8px color-mix(in srgb, var(--qr-primary) 35%, transparent);
    transition: background 0.15s ease, transform 0.1s ease;
}

.qr-menu-page .qr-menu-btn-primary:hover,
.qr-menu-page .btn-primary.qr-menu-add-btn:hover,
.qr-menu-page .qr-menu-product-add-btn:hover {
    background: var(--qr-primary-dark);
    color: #fff;
}

.qr-menu-page .qr-menu-btn-success,
.qr-menu-page .qr-menu-submit-btn {
    background: var(--qr-success);
    border: none;
    color: #fff;
    font-weight: 600;
    border-radius: var(--qr-radius-sm);
    padding: 0.7rem 1.1rem;
    box-shadow: 0 2px 8px color-mix(in srgb, var(--qr-success) 35%, transparent);
}

.qr-menu-page .qr-menu-btn-success:hover:not(:disabled),
.qr-menu-page .qr-menu-submit-btn:hover:not(:disabled) {
    background: var(--qr-success-dark);
    color: #fff;
}

.qr-menu-page .qr-menu-btn-outline,
.qr-menu-page .qr-menu-waiter-btn {
    background: transparent;
    border: 1.5px solid var(--qr-primary);
    color: var(--qr-primary);
    font-weight: 600;
    border-radius: var(--qr-radius-sm);
    padding: 0.55rem 1rem;
}

.qr-menu-page .qr-menu-btn-outline:hover,
.qr-menu-page .qr-menu-waiter-btn:hover {
    background: var(--qr-primary-light);
    color: var(--qr-primary-dark);
}

.qr-menu-page .btn-primary {
    background: var(--qr-primary);
    border-color: var(--qr-primary);
}

.qr-menu-page .btn-success {
    background: var(--qr-success);
    border-color: var(--qr-success);
}

.qr-code-editor {
    font-family: ui-monospace, 'Cascadia Code', 'Consolas', monospace;
    font-size: 0.82rem;
    line-height: 1.5;
    background: #0F172A;
    color: #E2E8F0;
    border: 1px solid #334155;
    border-radius: 10px;
    padding: 0.85rem 1rem;
    resize: vertical;
}

.qr-code-editor:focus {
    background: #0F172A;
    color: #F8FAFC;
    border-color: var(--primary, #F05A28);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent);
}

.qr-code-editor-hint {
    font-size: 0.78rem;
    color: var(--text-muted);
    padding: 0.65rem 0.75rem;
    background: #F8FAFC;
    border-radius: 8px;
    border: 1px dashed var(--border-color, #E5E7EB);
}

.qr-code-editor-hint code {
    font-size: 0.76rem;
    color: var(--primary, #F05A28);
    background: #FFF7ED;
    padding: 0.1rem 0.35rem;
    border-radius: 4px;
}

.qr-menu-header-accent {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--qr-primary), color-mix(in srgb, var(--qr-primary) 60%, var(--qr-success)));
}

.qr-menu-logo-wrap {
    display: flex;
    justify-content: center;
    margin-bottom: 0.85rem;
}

.qr-menu-logo {
    max-height: 64px;
    max-width: 200px;
    object-fit: contain;
}

.qr-menu-inline-banner {
    margin: 0 -0.25rem 0.85rem;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--qr-border);
}

.qr-menu-inline-banner-img {
    width: 100%;
    aspect-ratio: 3 / 1;
    object-fit: cover;
    display: block;
}

.qr-menu-welcome-text {
    margin: 0 0 1rem;
    padding: 0 0.25rem;
    font-size: 0.88rem;
    line-height: 1.55;
    color: var(--qr-text-muted);
    font-weight: 400;
}

.qr-menu-header-meta {
    padding-top: 0.15rem;
}

.qr-menu-header .qr-menu-wifi,
.qr-menu-header .qr-menu-waiter-btn {
    margin-left: 1rem;
    margin-right: 1rem;
}

.qr-menu-header .qr-menu-wifi {
    margin-top: 0;
    margin-bottom: 0;
    border-radius: 0;
    border-left: none;
    border-right: none;
    border-bottom: none;
    border-top: 1px solid var(--qr-border);
    background: var(--qr-card-alt);
}

.qr-menu-header .qr-menu-actions {
    display: flex;
    gap: 0.6rem;
    padding: 0.85rem 1rem 1rem;
}

.qr-menu-header .qr-menu-actions .qr-menu-waiter-btn,
.qr-menu-header .qr-menu-actions .qr-menu-pay-btn {
    margin: 0;
    width: auto;
    flex: 1;
}

.qr-menu-page .qr-menu-pay-btn {
    background: var(--qr-primary);
    border: 1.5px solid var(--qr-primary);
    color: #fff;
    font-weight: 700;
    border-radius: var(--qr-radius-sm);
    padding: 0.55rem 1rem;
    text-align: center;
    text-decoration: none;
}

.qr-menu-page .qr-menu-pay-btn:hover {
    background: var(--qr-primary-dark, var(--qr-primary));
    color: #fff;
}

.qr-pay-card {
    background: var(--qr-card, #fff);
    border: 1px solid var(--qr-border);
    border-radius: var(--qr-radius-sm);
    padding: 1rem;
    margin-bottom: 0.85rem;
}

.qr-pay-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.45rem 0;
    margin: 0;
}

.qr-pay-line.is-pending {
    opacity: 0.7;
}

.qr-pay-check {
    width: 1.1rem;
    height: 1.1rem;
    accent-color: var(--qr-primary);
    flex: 0 0 auto;
}

.qr-pay-modes {
    display: flex;
    gap: 0.4rem;
    margin: 0.75rem 0;
}

.qr-pay-mode {
    flex: 1;
    border: 1.5px solid var(--qr-border);
    background: transparent;
    color: var(--qr-text, inherit);
    border-radius: var(--qr-radius-sm);
    padding: 0.45rem 0.35rem;
    font-size: 0.78rem;
    font-weight: 700;
}

.qr-pay-mode.is-active {
    border-color: var(--qr-primary);
    background: var(--qr-primary);
    color: #fff;
}

.qr-pay-total {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    border-top: 1px solid var(--qr-border);
    margin-top: 0.4rem;
    padding-top: 0.7rem;
    font-weight: 700;
}

.qr-pay-note {
    color: var(--qr-text-muted);
    font-size: 0.82rem;
}

.qr-pay-alert {
    border-radius: var(--qr-radius-sm);
    padding: 0.75rem 0.9rem;
    margin-bottom: 0.85rem;
    background: var(--qr-primary-light);
    color: var(--qr-primary-dark, var(--qr-primary));
}

.qr-pay-card-form {
    margin: 0.85rem 0 1rem;
}

.qr-pay-field-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 700;
    margin-bottom: 0.4rem;
    color: var(--qr-text, inherit);
}

.qr-pay-pan {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.45rem;
    margin-bottom: 0.85rem;
}

.qr-pay-pan-part {
    text-align: center;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.12em;
    font-weight: 700;
    font-size: 1.05rem;
    padding-left: 0.25rem;
    padding-right: 0.25rem;
}

.qr-pay-meta {
    display: grid;
    grid-template-columns: 1.4fr 0.8fr;
    gap: 0.75rem;
    align-items: end;
}

.qr-pay-exp {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.qr-pay-exp .form-control {
    text-align: center;
    font-variant-numeric: tabular-nums;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.qr-pay-exp-sep {
    font-weight: 800;
    opacity: 0.45;
}

.qr-pay-meta-cvv .form-control {
    text-align: center;
    font-weight: 700;
    letter-spacing: 0.18em;
}

.qr-pay-error {
    color: #b42318;
    font-size: 0.84rem;
    font-weight: 600;
}

@media (max-width: 380px) {
    .qr-pay-pan {
        gap: 0.3rem;
    }

    .qr-pay-pan-part {
        font-size: 0.92rem;
        letter-spacing: 0.06em;
    }
}

.qr-menu-badge {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--qr-primary);
    background: var(--qr-primary-light);
    padding: 0.25rem 0.6rem;
    border-radius: 6px;
    margin-bottom: 0.4rem;
}

.qr-menu-title {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0;
    color: var(--qr-text);
}

.qr-menu-subtitle {
    margin: 0.2rem 0 0;
    font-size: 0.82rem;
    color: var(--qr-text-muted);
}

.qr-menu-wifi {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-top: 0.85rem;
    padding: 0.65rem 0.75rem;
    background: var(--qr-primary-light);
    border-radius: 12px;
    border: 1px solid color-mix(in srgb, var(--qr-primary) 25%, transparent);
}

.qr-menu-wifi-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--qr-card);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--qr-primary);
    font-size: 1.1rem;
    flex-shrink: 0;
}

.qr-menu-wifi-info {
    flex: 1;
    min-width: 0;
}

.qr-menu-wifi-label {
    display: block;
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--qr-text-muted);
    font-weight: 600;
}

.qr-menu-wifi-ssid {
    display: block;
    font-size: 0.95rem;
    color: var(--qr-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.qr-menu-wifi-copy {
    border: none;
    background: var(--qr-primary);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.4rem 0.65rem;
    border-radius: 8px;
    white-space: nowrap;
    cursor: pointer;
}

.qr-menu-wifi-copy:active {
    opacity: 0.85;
}

.qr-menu-note {
    margin: 0.75rem 0 0;
    font-size: 0.82rem;
    color: var(--qr-text-muted);
}

.qr-menu-section {
    background: transparent;
    border: none;
    margin-bottom: 1.25rem;
    overflow: visible;
    box-shadow: none;
}

.qr-menu-section-title {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin: 0 0 0.65rem 0.25rem;
    padding: 0;
    background: transparent;
    border: none;
    color: var(--qr-text-muted);
}

.qr-menu-items {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.qr-menu-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.8rem 0.9rem;
    background: var(--qr-card);
    border: 1px solid var(--qr-border);
    border-radius: 14px;
    box-shadow: 0 2px 10px var(--qr-shadow);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    color: var(--qr-text);
}

.qr-menu-item.is-clickable:active {
    transform: scale(0.99);
}

.qr-menu-item-thumb {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    overflow: hidden;
    flex-shrink: 0;
    background: var(--qr-card-alt);
}

.qr-menu-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.qr-menu-item-main {
    flex: 1;
    min-width: 0;
}

.qr-menu-item-name {
    display: block;
    font-size: 0.95rem;
    line-height: 1.3;
}

.qr-menu-item-desc {
    margin: 0.2rem 0 0;
    font-size: 0.78rem;
    line-height: 1.4;
    color: var(--qr-text-muted);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.qr-menu-item-meta {
    display: block;
    margin-top: 0.15rem;
    font-size: 0.72rem;
    color: var(--qr-text-muted);
}

.qr-menu-item-chevron {
    color: var(--qr-text-muted);
    font-size: 0.9rem;
}

.qr-menu-item-price {
    font-weight: 700;
    white-space: nowrap;
    color: var(--qr-primary);
}

.qr-menu-empty {
    text-align: center;
    color: var(--qr-text-muted);
    padding: 2rem 1rem;
}

.qr-menu-waiter-btn {
    margin-top: 0.75rem;
    border-color: var(--qr-primary) !important;
    color: var(--qr-primary) !important;
}

.qr-menu-page .btn-primary {
    background: var(--qr-primary);
    border-color: var(--qr-primary);
}

.qr-menu-page .btn-primary:hover,
.qr-menu-page .btn-primary:focus {
    background: var(--qr-primary-dark);
    border-color: var(--qr-primary-dark);
}

.qr-menu-item.is-orderable {
    cursor: pointer;
}

.qr-menu-item.is-clickable {
    cursor: pointer;
}

.qr-menu-add-btn {
    width: 34px;
    height: 34px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
}

.qr-menu-item-side {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.qr-menu-cart-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem calc(0.75rem + env(safe-area-inset-bottom));
    background: var(--qr-card);
    border-top: 1px solid var(--qr-border);
    box-shadow: 0 -4px 20px var(--qr-shadow);
}

.qr-menu-cart-summary {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border: none;
    background: var(--qr-card-alt);
    border-radius: 10px;
    padding: 0.65rem 0.85rem;
    text-align: left;
    color: var(--qr-text);
}

.qr-menu-submit-btn {
    white-space: nowrap;
}

.qr-menu-cart-sheet {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1001;
    max-height: 60vh;
    background: var(--qr-card);
    border-radius: 16px 16px 0 0;
    box-shadow: 0 -8px 30px var(--qr-shadow);
    display: flex;
    flex-direction: column;
    color: var(--qr-text);
}

.qr-menu-cart-sheet-head,
.qr-menu-modal-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--qr-border);
}

.qr-menu-cart-lines {
    overflow: auto;
    padding: 0.75rem 1rem 1rem;
}

.qr-menu-cart-line {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.55rem 0;
    border-bottom: 1px solid color-mix(in srgb, var(--qr-border) 50%, transparent);
}

.qr-menu-cart-line-actions {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.qr-menu-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1002;
    background: rgba(15, 23, 42, 0.45);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 1rem;
}

.qr-menu-modal {
    width: 100%;
    max-width: 420px;
    background: var(--qr-card);
    border-radius: 16px;
    overflow: hidden;
    color: var(--qr-text);
}

.qr-menu-modal-body {
    padding: 1rem;
    max-height: 50vh;
    overflow: auto;
}

.qr-menu-modal-foot {
    padding: 0.75rem 1rem 1rem;
}

.qr-menu-toast {
    position: fixed;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1100;
    padding: 0.65rem 1rem;
    border-radius: 999px;
    font-size: 0.85rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.qr-menu-toast.is-success { background: #DCFCE7; color: #166534; }
.qr-menu-toast.is-error { background: #FEE2E2; color: #991B1B; }

.qr-menu-body.qr-menu-modal-open {
    overflow: hidden;
}

.qr-menu-detail-modal {
    position: relative;
    max-height: 90vh;
    overflow: auto;
}

.qr-menu-detail-close {
    position: absolute;
    top: 0.65rem;
    right: 0.65rem;
    z-index: 2;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    color: #334155;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    cursor: pointer;
}

.qr-menu-detail-image-wrap {
    width: 100%;
    max-height: 220px;
    overflow: hidden;
    background: var(--qr-card-alt);
}

.qr-menu-detail-image {
    width: 100%;
    max-height: 220px;
    object-fit: cover;
    display: block;
}

.qr-menu-detail-body {
    padding: 1.1rem 1.15rem 0.5rem;
}

.qr-menu-detail-title {
    font-size: 1.2rem;
    margin: 0 0 0.5rem;
    color: var(--qr-text);
    padding-right: 2rem;
}

.qr-menu-detail-desc {
    margin: 0;
    font-size: 0.88rem;
    line-height: 1.55;
    color: var(--qr-text-muted);
}

.qr-menu-detail-price {
    margin-top: 0.75rem;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--qr-primary);
}

.qr-menu-detail-foot {
    padding: 0.75rem 1.15rem 1.15rem;
}

.qr-menu-modal-product-image .qr-menu-detail-image {
    border-radius: 12px;
    max-height: 160px;
}

.qr-menu-modal-desc {
    margin: 0;
}

/* QR appearance settings — theme picker */
.qr-theme-picker {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.85rem;
}

.qr-theme-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding: 0.85rem;
    border: 2px solid var(--border-color, #E5E7EB);
    border-radius: 14px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.qr-theme-card:hover {
    border-color: var(--theme-accent, var(--primary));
}

.qr-theme-card.is-selected {
    border-color: var(--theme-accent, var(--primary));
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--theme-accent, var(--primary)) 20%, transparent);
}

.qr-theme-radio {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.qr-theme-card-preview {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    height: 48px;
    padding: 0.5rem 0.65rem;
    border-radius: 10px;
    background: var(--theme-bg, #F8FAFC);
    margin-bottom: 0.25rem;
}

.qr-theme-card-bar {
    flex: 1;
    height: 8px;
    border-radius: 4px;
    background: var(--theme-accent, var(--primary));
}

.qr-theme-card-dot {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--theme-light, #FFF4F0);
    border: 2px solid var(--theme-accent, var(--primary));
}

.qr-theme-card-title {
    font-weight: 600;
    font-size: 0.92rem;
}

.qr-theme-card-desc {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.35;
}

.qr-custom-preview {
    padding: 0.85rem;
    border-radius: 12px;
    background: #F8FAFC;
    border: 1px dashed var(--border-color, #E5E7EB);
}

.qr-custom-preview-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.qr-custom-preview-card {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.75rem 0.85rem;
    border-radius: 10px;
    border: 1px solid var(--border-color, #E5E7EB);
}

.qr-custom-preview-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: color-mix(in srgb, var(--theme-accent, #E85D3B) 20%, white);
    border: 2px solid var(--theme-accent, #E85D3B);
}

.qr-custom-preview-bar {
    flex: 1;
    height: 10px;
    border-radius: 5px;
    background: var(--theme-accent, #E85D3B);
}

.form-control-color.qr-color-picker {
    width: 3rem;
    padding: 0.2rem;
}

/* QR menu — multi-page navigation */
.qr-menu-back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--qr-primary);
    text-decoration: none;
    margin-bottom: 0.85rem;
}

.qr-menu-hero-banner {
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 1rem;
    border: 1px solid var(--qr-border);
    box-shadow: 0 4px 20px var(--qr-shadow);
}

.qr-menu-hero-banner-img {
    width: 100%;
    max-height: 180px;
    object-fit: cover;
    display: block;
}

.qr-menu-hero-banner-caption {
    padding: 0.65rem 0.85rem;
    font-size: 0.82rem;
    background: var(--qr-card);
    color: var(--qr-text-muted);
    border-top: 1px solid var(--qr-border);
}

.qr-menu-category-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

@media (min-width: 480px) {
    .qr-menu-category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.qr-menu-category-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    background: var(--qr-card);
    border: 1px solid var(--qr-border);
    border-radius: var(--qr-radius-sm);
    overflow: hidden;
    box-shadow: 0 1px 2px var(--qr-shadow);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.qr-menu-category-card:hover {
    border-color: color-mix(in srgb, var(--qr-primary) 35%, var(--qr-border));
    box-shadow: 0 4px 12px var(--qr-shadow);
}

.qr-menu-category-card-img {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: var(--qr-card-alt);
}

.qr-menu-category-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.qr-menu-category-card-img--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--qr-text-muted);
    font-size: 1.75rem;
}

.qr-menu-category-card-body {
    padding: 0.75rem 0.85rem 0.9rem;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.qr-menu-category-card-body strong {
    font-size: 0.92rem;
    color: var(--qr-text);
}

.qr-menu-category-card-desc {
    font-size: 0.72rem;
    color: var(--qr-text-muted);
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.qr-menu-category-card-count {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--qr-primary);
    margin-top: 0.15rem;
}

.qr-menu-category-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.qr-menu-category-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.8rem 0.9rem;
    background: var(--qr-card);
    border: 1px solid var(--qr-border);
    border-radius: 14px;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 2px 10px var(--qr-shadow);
}

.qr-menu-category-row-thumb {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    overflow: hidden;
    flex-shrink: 0;
}

.qr-menu-category-row-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.qr-menu-category-row-main {
    flex: 1;
    min-width: 0;
}

.qr-menu-category-row-main strong {
    display: block;
    font-size: 0.95rem;
}

.qr-menu-category-row-desc {
    display: block;
    font-size: 0.75rem;
    color: var(--qr-text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.qr-menu-category-row-meta {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--qr-text-muted);
    font-size: 0.82rem;
}

.qr-menu-item-link {
    text-decoration: none;
    color: inherit;
}

.qr-menu-section--plain {
    background: transparent;
    border: none;
    box-shadow: none;
}

.qr-menu-section-desc {
    margin: -0.35rem 0 0.85rem 0.25rem;
    font-size: 0.82rem;
    color: var(--qr-text-muted);
}

.qr-menu-product-page {
    background: var(--qr-card);
    border-radius: 20px;
    border: 1px solid var(--qr-border);
    overflow: hidden;
    box-shadow: 0 4px 24px var(--qr-shadow);
}

.qr-menu-product-hero {
    width: 100%;
    max-height: 260px;
    overflow: hidden;
    background: var(--qr-card-alt);
}

.qr-menu-product-hero-img {
    width: 100%;
    max-height: 260px;
    object-fit: cover;
    display: block;
}

.qr-menu-product-hero-img.media-name-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 140px;
    font-size: 1.15rem;
}

.qr-menu-product-content {
    padding: 1.15rem 1.1rem 1.25rem;
}

.qr-menu-product-title {
    font-size: 1.35rem;
    margin: 0 0 0.5rem;
    color: var(--qr-text);
}

.qr-menu-product-desc {
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--qr-text-muted);
    margin: 0 0 0.85rem;
}

.qr-menu-product-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--qr-primary);
    margin-bottom: 1rem;
}

.qr-menu-product-block {
    margin-bottom: 1rem;
}

.qr-menu-product-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--qr-text-muted);
    margin-bottom: 0.4rem;
}

.qr-menu-qty-control {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    background: var(--qr-card-alt);
    border-radius: 10px;
    padding: 0.35rem 0.65rem;
}

.qr-menu-qty-control span {
    min-width: 1.5rem;
    text-align: center;
    font-weight: 700;
}

.qr-menu-product-add-btn {
    margin-top: 0.5rem;
    padding: 0.75rem;
    border-radius: 12px;
    font-weight: 600;
}

.qr-menu-option-list {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.qr-menu-option {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    border: 1px solid var(--qr-border);
    background: var(--qr-card);
    border-radius: 12px;
    padding: 0.65rem 0.75rem;
    margin: 0;
    cursor: pointer;
}

.qr-menu-option.is-selected {
    border-color: var(--qr-primary);
    background: var(--qr-card-alt);
}

.qr-menu-option span {
    font-weight: 600;
    color: var(--qr-text);
}

.qr-menu-option em {
    margin-left: auto;
    font-style: normal;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--qr-primary);
    white-space: nowrap;
}

.qr-menu-group {
    padding-bottom: 0.35rem;
    border-bottom: 1px solid var(--qr-border);
}

.qr-menu-fixed-name {
    font-weight: 700;
    margin-bottom: 0.45rem;
    color: var(--qr-text);
}

.qr-menu-nested-label {
    margin-top: 0.7rem;
}

.qr-approval-panel .qr-pending-order-card {
    border: 1px solid #FDE68A;
    background: #FFFBEB;
    border-radius: 12px;
    padding: 0.85rem;
    margin-bottom: 0.75rem;
}

.qr-pending-order-head {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.35rem;
}

.qr-pending-order-lines {
    margin: 0;
    padding-left: 1.1rem;
}

.qr-waiter-call-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    padding: 0.55rem 0;
    border-bottom: 1px solid #F1F5F9;
}

.table-pos-qr-alert {
    font-size: 0.85rem;
}

.order-source-badge.source-qr,
.pm-brand.source-qr:not(.has-logo) { background: #FEF3C7; color: #92400E; }
.bg-brand-light { background: var(--primary-light) !important; }

/* ===== Mobile & tablet responsive ===== */
@media (max-width: 991.98px) {
    .top-header {
        height: auto;
        min-height: var(--header-height);
        padding: 0.65rem 1rem;
        gap: 0.5rem;
        flex-wrap: nowrap;
    }

    .top-header-start {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.35rem;
    }

    .top-header .page-title {
        font-size: 1rem;
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .branch-selector,
    .btn-branch-selector {
        max-width: 100%;
    }

    .main-content {
        padding: 1rem 0.85rem 1.25rem;
    }

    .main-content:has(.tables-floor-page) {
        padding: 0.45rem 0.45rem 0.65rem;
    }

    .main-content-compact {
        padding: 0.5rem 0.75rem 0.85rem;
    }

    .panel-card .card-header-custom,
    .panel-card .card-body-custom {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .page-actions {
        flex-direction: column;
        width: 100%;
    }

    .page-actions .btn {
        width: 100%;
        justify-content: center;
    }

    .table-responsive {
        -webkit-overflow-scrolling: touch;
    }

    .table-panel {
        min-width: 640px;
    }

    .order-list-table {
        min-width: 720px;
    }

    .payment-matrix-table {
        min-width: 680px;
    }

    .cashier-daily-table {
        min-width: 420px;
    }

    .data-grid-pagination-wrap {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }

    .data-grid-pagination {
        justify-content: center;
    }

    .orders-page-header,
    .tables-floor-top,
    .customers-page-header,
    .cash-register-header,
    .reports-page-header {
        flex-direction: column;
        align-items: stretch;
    }

    .orders-page-actions,
    .customers-page-actions {
        width: 100%;
    }

    .orders-page-actions .btn,
    .customers-page-actions .btn {
        flex: 1 1 auto;
    }

    .cash-filter-row {
        flex-direction: column;
        align-items: stretch;
    }

    .cash-filter-field,
    .cash-filter-field .form-control {
        width: 100%;
        min-width: 0 !important;
    }

    .cash-filter-actions {
        width: 100%;
        flex-wrap: wrap;
    }

    .cash-filter-actions .btn {
        flex: 1 1 calc(50% - 0.25rem);
        min-width: 0;
    }

    .order-table-actions {
        flex-wrap: wrap;
        justify-content: flex-end;
        gap: 0.35rem;
    }

    .order-table-actions .order-action-btn {
        font-size: 0.72rem;
        padding: 0.3rem 0.5rem;
    }

    .tables-floor-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tables-floor-filters {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.25rem;
        -webkit-overflow-scrolling: touch;
    }

    .tables-floor-filters .zone-filter-btn {
        flex-shrink: 0;
    }

    .tables-floor-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.5rem;
    }

    .table-pos-header {
        flex-direction: column;
        align-items: stretch;
    }

    .table-pos-header-actions {
        width: 100%;
    }

    .table-pos-header-actions .btn,
    .table-pos-header-actions .table-pos-back-btn {
        flex: 1 1 auto;
        justify-content: center;
    }

    .chart-container {
        min-height: 240px;
    }

    .settings-nav {
        max-height: none;
    }

    .settings-nav-list {
        flex-wrap: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 0.25rem;
    }

    .settings-nav-link {
        flex: 0 0 auto;
        min-width: max-content;
        white-space: nowrap;
    }

    .settings-qr-grid {
        grid-template-columns: 1fr;
    }

    .sidebar .nav-link {
        min-height: 44px;
    }
}

@media (max-width: 575.98px) {
    .top-header .page-title {
        font-size: 0.92rem;
    }

    .main-content {
        padding: 0.85rem 0.65rem 1rem;
    }

    .main-content:has(.tables-floor-page) {
        padding: 0.35rem 0.35rem 0.55rem;
    }

    .kpi-card .kpi-value {
        font-size: 1.05rem;
    }

    .kpi-card .kpi-label {
        font-size: 0.65rem;
    }

    .order-channel-card-amount {
        font-size: 1.05rem;
    }

    .tables-floor-stats {
        grid-template-columns: 1fr;
    }

    .tables-floor-title {
        font-size: 1.15rem;
    }

    .table-payment-amount-box .amount {
        font-size: 1.5rem;
    }

    .table-payment-type-grid {
        grid-template-columns: 1fr;
    }

    .order-source-card {
        padding: 0.75rem 0.5rem;
    }

    .card-header-custom {
        font-size: 0.9rem;
    }

    .btn,
    .btn-sm {
        min-height: 40px;
    }

    .sidebar-toggle-btn {
        width: 44px;
        height: 44px;
    }
}

/* Restaurant live notifications (garson çağrısı, QR onay) */
.restaurant-notif-bar {
    border: 1px solid #FCD34D;
    border-left: 4px solid #F59E0B;
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.15);
}

.restaurant-notif-bar.is-waiter-active {
    animation: restaurant-notif-pulse 2s ease-in-out infinite;
}

@keyframes restaurant-notif-pulse {
    0%, 100% { box-shadow: 0 4px 14px rgba(245, 158, 11, 0.15); }
    50% { box-shadow: 0 4px 22px rgba(245, 158, 11, 0.35); }
}

.restaurant-notifications-root.is-flash .restaurant-notif-bar {
    animation: restaurant-notif-flash 1.2s ease;
}

@keyframes restaurant-notif-flash {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.01); background-color: #FEF3C7; }
}

.restaurant-notif-bar-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.restaurant-notif-bar-icon {
    font-size: 1.25rem;
    color: #D97706;
}

.restaurant-notif-bar-summary {
    flex: 1 1 auto;
    font-size: 0.92rem;
}

.restaurant-notif-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.restaurant-notif-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.45rem 0.55rem;
    background: rgba(255, 255, 255, 0.55);
    border-radius: 0.5rem;
}

.restaurant-notif-item-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.nav-notif-badge {
    position: absolute;
    top: 0.35rem;
    right: 0.5rem;
    min-width: 1.15rem;
    height: 1.15rem;
    padding: 0 0.3rem;
    border-radius: 999px;
    background: #DC2626;
    color: #fff;
    font-size: 0.62rem;
    font-weight: 700;
    line-height: 1.15rem;
    text-align: center;
    box-shadow: 0 0 0 2px var(--sidebar-bg, #111827);
}

/* Yeni Sipariş Oluştur — referans yerleşim */
.ny-order-page {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 1rem);
    min-height: 0;
    background: #eceff3;
    overflow: hidden;
}

.main-content-compact:has(.ny-order-page),
.main-content-compact:has(.phone-order-page) {
    padding: 0.5rem;
    overflow: hidden;
    height: calc(100vh - 0.5rem);
    display: flex;
    flex-direction: column;
}

.ny-order-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.65rem 1rem;
    background: #fff;
    border: 1px solid #dde3ea;
    border-radius: 6px;
    margin-bottom: 0.5rem;
    flex-shrink: 0;
}

.ny-order-title {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    color: #1f2937;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ny-order-title i {
    color: #4b5563;
    font-size: 1.1rem;
}

.ny-order-back {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: #374151;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 0.35rem 0.5rem;
    border-radius: 6px;
}

.ny-order-back:hover {
    color: #111827;
    background: #f3f4f6;
}

.ny-order-alert {
    flex-shrink: 0;
    margin-bottom: 0.5rem !important;
}

.ny-order-layout {
    display: grid;
    grid-template-columns: 168px minmax(200px, 28%) minmax(560px, 1fr);
    gap: 0.5rem;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.ny-order-categories {
    background: #fff;
    border: 1px solid #dde3ea;
    border-radius: 6px;
    overflow-y: auto;
    max-height: none !important;
    height: 100%;
}

.ny-order-products {
    background: #fff;
    border: 1px solid #dde3ea;
    border-radius: 6px;
    height: 100%;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.ny-order-products .table-pos-product-list {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
}

.ny-order-right {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
    background: #fff;
    border: 1px solid #dde3ea;
    border-radius: 6px;
    overflow: hidden;
}

.ny-order-right-scroll {
    flex: 1 1 auto;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
}

.ny-order-panel {
    border-bottom: 1px solid #e5e7eb;
}

.ny-order-panel-cart {
    display: flex;
    flex-direction: column;
    min-height: 300px;
}

.ny-order-cart-table-wrap {
    flex: 1;
    min-height: 200px;
    overflow-y: auto;
    position: relative;
}

.ny-order-cart-table {
    width: 100%;
    font-size: 0.88rem;
}

.ny-order-cart-table thead th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f8fafc;
    font-size: 0.78rem;
    font-weight: 700;
    color: #374151;
    padding: 0.65rem 0.75rem;
    border-bottom: 1px solid #e5e7eb;
}

.ny-order-cart-table tbody td {
    padding: 0.55rem 0.75rem;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}

.ny-order-col-hide {
    width: 0 !important;
    padding: 0 !important;
    border: none !important;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.ny-order-cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 1rem;
    color: #9ca3af;
    text-align: center;
}

.ny-order-cart-empty i {
    font-size: 3.5rem;
    margin-bottom: 0.75rem;
    opacity: 0.45;
}

.ny-order-cart-empty p {
    margin: 0;
    font-size: 0.95rem;
}

.ny-order-cart-total {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0.55rem 0.85rem;
    border-top: 1px solid #e5e7eb;
    background: #fff;
    flex-shrink: 0;
}

.ny-order-cart-total strong {
    font-size: 1.05rem;
    font-weight: 800;
    color: #111827;
}

.ny-order-panel-title {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem 0.85rem;
    font-size: 0.88rem;
    font-weight: 700;
    color: #1f2937;
    border-bottom: 1px solid #e5e7eb;
    background: #fafbfc;
}

.ny-order-panel-title i {
    color: #6b7280;
}

.ny-order-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.55rem 0.75rem;
    padding: 0.65rem 0.85rem 0.75rem;
}

.ny-order-field-full {
    grid-column: 1 / -1;
}

.ny-order-field-name {
    grid-column: 1 / -1;
    position: relative;
}

.ny-order-field label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: #4b5563;
    margin-bottom: 0.3rem;
}

.ny-order-input-row {
    display: flex;
    gap: 0.4rem;
}

.ny-order-input-row .ny-order-input {
    flex: 1;
    min-width: 0;
}

.ny-order-search-btn {
    width: 42px;
    flex-shrink: 0;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    background: #f9fafb;
    color: #374151;
    cursor: pointer;
}

.ny-order-search-btn:hover {
    background: #f3f4f6;
}

.ny-order-input,
.ny-order-textarea {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 0.55rem 0.7rem;
    font-size: 0.9rem;
    background: #fff;
}

.ny-order-textarea {
    resize: vertical;
    min-height: 72px;
}

.ny-order-customer-results {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    z-index: 30;
}

.ny-order-customer-chip {
    margin: 0 0.85rem 0.65rem;
}

.ny-order-payment-wrap {
    padding: 0.65rem 0.85rem 0.75rem;
}

.ny-order-payment-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.45rem;
}

.ny-order-payment-grid.phone-order-payment-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ny-order-payment-grid .payment-type-card {
    min-height: 58px;
    padding: 0.45rem 0.35rem;
    font-size: 0.68rem;
    line-height: 1.2;
    text-align: center;
}

.ny-order-payment-grid .payment-type-card i {
    font-size: 1rem;
    margin-bottom: 0.15rem;
}

.ny-order-save-wrap {
    flex: 0 0 auto;
    flex-shrink: 0;
    padding: 0.65rem 0.85rem;
    background: #fff;
    border-top: 1px solid #d1d5db;
}

.ny-order-save-btn {
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    width: 100%;
    min-height: 50px;
    border: none;
    border-radius: 6px;
    background: linear-gradient(180deg, #22c55e 0%, #16a34a 100%);
    color: #fff !important;
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(22, 163, 74, 0.35);
}

.ny-order-save-btn:hover {
    background: linear-gradient(180deg, #16a34a 0%, #15803d 100%);
}

.ny-order-save-btn:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    box-shadow: none;
}

@media (max-width: 1400px) {
    .ny-order-layout {
        grid-template-columns: 155px minmax(190px, 30%) minmax(480px, 1fr);
    }
}

@media (max-width: 1199.98px) {
    .ny-order-page {
        height: auto;
        min-height: calc(100vh - 1rem);
        overflow: visible;
    }

    .ny-order-layout {
        grid-template-columns: 150px 1fr;
        grid-template-rows: minmax(300px, 45vh) minmax(480px, 1fr);
        height: auto;
    }

    .ny-order-right {
        grid-column: 1 / -1;
        min-height: 520px;
        height: auto;
    }
}

.store-feature-list li {
    margin-bottom: 0.55rem;
    line-height: 1.55;
}

.store-feature-list li:last-child {
    margin-bottom: 0;
}

.store-setup-steps li {
    line-height: 1.5;
}

@media (max-width: 1199.98px) {
    .phone-order-fields {
        grid-template-columns: 1fr;
    }
}

/* —— Hızlı Erişim sayfası —— */
.quick-access-page {
    min-height: calc(100vh - 2rem);
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    padding: 0.25rem 0 1.5rem;
}

.quick-access-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.25rem 0.25rem 0.5rem;
}

.quick-access-brand {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.quick-access-logo {
    width: 52px;
    height: 52px;
    object-fit: contain;
    border-radius: 12px;
    background: #fff;
    padding: 4px;
    box-shadow: 0 4px 14px rgba(26, 41, 64, 0.12);
}

.quick-access-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--sidebar-bg, #1A2940);
    margin: 0 0 0.15rem;
}

.quick-access-subtitle {
    font-size: 0.85rem;
    color: var(--text-secondary, #64748b);
}

.quick-access-day-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.85rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 600;
    background: #ECFDF5;
    color: #047857;
    border: 1px solid #A7F3D0;
}

.quick-access-day-badge.is-closed {
    background: #FFF7ED;
    color: #C2410C;
    border-color: #FDBA74;
}

.qa-pulse {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10B981;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.5);
    animation: qa-pulse 1.8s infinite;
}

@keyframes qa-pulse {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.45); }
    70% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.quick-access-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.85rem;
    flex: 1;
    align-content: start;
}

.quick-access-tile {
    aspect-ratio: 1;
    min-height: 108px;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    text-decoration: none;
    color: #fff;
    padding: 0.85rem;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.14);
    transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.quick-access-tile:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.2);
    color: #fff;
    filter: brightness(1.05);
}

.quick-access-tile:active {
    transform: translateY(0) scale(0.98);
}

.quick-access-tile-icon {
    font-size: clamp(1.75rem, 3vw, 2.35rem);
    line-height: 1;
    opacity: 0.95;
}

.quick-access-tile-label {
    font-size: 0.78rem;
    font-weight: 700;
    text-align: center;
    line-height: 1.2;
    letter-spacing: 0.01em;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}

.quick-access-tile.qa-navy { background: linear-gradient(145deg, #1A2940 0%, #243552 100%); }
.quick-access-tile.qa-navy-soft { background: linear-gradient(145deg, #2A3F5F 0%, #1A2940 100%); }
.quick-access-tile.qa-orange { background: linear-gradient(145deg, #F26522 0%, #FF8A5C 100%); }
.quick-access-tile.qa-orange-soft { background: linear-gradient(145deg, #FF8A5C 0%, #F26522 100%); }
.quick-access-tile.qa-green { background: linear-gradient(145deg, #16A34A 0%, #22C55E 100%); }
.quick-access-tile.qa-green-soft { background: linear-gradient(145deg, #059669 0%, #10B981 100%); }
.quick-access-tile.qa-blue { background: linear-gradient(145deg, #2563EB 0%, #3B82F6 100%); }
.quick-access-tile.qa-teal { background: linear-gradient(145deg, #0D9488 0%, #14B8A6 100%); }
.quick-access-tile.qa-gray { background: linear-gradient(145deg, #64748B 0%, #94A3B8 100%); }
.quick-access-tile.qa-red { background: linear-gradient(145deg, #DC2626 0%, #EF4444 100%); }

@media (max-width: 1199.98px) {
    .quick-access-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 767.98px) {
    .quick-access-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 0.65rem;
    }

    .quick-access-tile {
        min-height: 96px;
        border-radius: 14px;
    }

    .quick-access-tile-label {
        font-size: 0.72rem;
    }
}

@media (max-width: 479.98px) {
    .quick-access-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* —— Sidebar daralt / genişlet —— */
html.sidebar-collapsed-boot {
    --sidebar-width: var(--sidebar-width-collapsed);
}

.sidebar-collapse-bar {
    flex-shrink: 0;
    padding: 0.5rem 0.625rem 0.875rem;
    margin-top: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-collapse-btn {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.65rem;
    width: 100%;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.82);
    border-radius: 10px;
    padding: 0.55rem 0.75rem;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.sidebar-collapse-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.sidebar-collapse-btn i {
    font-size: 0.95rem;
    flex-shrink: 0;
}

.sidebar-collapse-btn-header {
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin-right: 0.35rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: #fff;
    color: var(--navy);
    cursor: pointer;
    transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.sidebar-collapse-btn-header:hover {
    background: var(--primary-light);
    border-color: color-mix(in srgb, var(--primary) 35%, var(--border-color));
    color: var(--primary-dark);
}

@media (min-width: 992px) {
    html.sidebar-collapsed-boot .main-wrapper,
    .app-shell.sidebar-collapsed {
        --sidebar-width: var(--sidebar-width-collapsed);
    }

    .app-shell.sidebar-collapsed .sidebar-brand {
        padding: 0.875rem 0.5rem 0.75rem;
    }

    .app-shell.sidebar-collapsed .brand-logo-box {
        padding: 0.45rem;
        border-radius: 10px;
    }

    .app-shell.sidebar-collapsed .brand-logo-img {
        max-width: 36px;
        margin: 0 auto;
    }

    .app-shell.sidebar-collapsed .sidebar-nav {
        padding-left: 0.375rem;
        padding-right: 0.375rem;
    }

    .app-shell.sidebar-collapsed .sidebar-nav .nav-section,
    .app-shell.sidebar-collapsed .nav-accordion-toggle,
    .app-shell.sidebar-collapsed .sidebar-collapse-label {
        display: none;
    }

    .app-shell.sidebar-collapsed .nav-accordion {
        margin: 0;
    }

    .app-shell.sidebar-collapsed .sidebar-nav .nav-group {
        padding: 0;
        margin-bottom: 0;
    }

    .app-shell.sidebar-collapsed .sidebar .nav-link {
        justify-content: center;
        padding-left: 0.5rem;
        padding-right: 0.5rem;
        gap: 0;
        margin-right: 0;
    }

    .app-shell.sidebar-collapsed .sidebar .nav-link span {
        display: none;
    }

    .app-shell.sidebar-collapsed .sidebar .nav-link i {
        margin: 0;
    }

    .app-shell.sidebar-collapsed .nav-notif-badge {
        position: absolute;
        top: 6px;
        right: 10px;
        min-width: 8px;
        width: 8px;
        height: 8px;
        padding: 0;
        font-size: 0;
        border-radius: 50%;
    }

    .app-shell.sidebar-collapsed .sidebar-collapse-btn {
        justify-content: center;
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }

    .app-shell.sidebar-collapsed .sidebar-collapse-bar {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }
}

/* Caller ID popup */
.caller-id-stack {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    z-index: 1080;
    display: flex;
    flex-direction: column-reverse;
    gap: 0.75rem;
    max-width: min(360px, calc(100vw - 2rem));
    pointer-events: none;
}

.caller-id-card {
    pointer-events: auto;
    background: var(--panel-card-bg, #fff);
    border: 1px solid rgba(34, 197, 94, 0.35);
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(15, 23, 42, 0.18);
    padding: 0.85rem 1rem;
    animation: caller-id-slide-in 0.28s ease-out;
}

.caller-id-card.is-closing {
    opacity: 0;
    transform: translateX(12px);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

@keyframes caller-id-slide-in {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.caller-id-card-head {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    margin-bottom: 0.75rem;
}

.caller-id-icon {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 50%;
    background: rgba(34, 197, 94, 0.12);
    color: #16a34a;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.1rem;
}

.caller-id-card-titles {
    flex: 1;
    min-width: 0;
}

.caller-id-card-titles strong,
.caller-id-name {
    display: block;
    font-size: 0.95rem;
    line-height: 1.3;
    font-weight: 800;
    color: #0f172a;
}

.caller-id-phone {
    display: block;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--brand-primary, #2563eb);
    margin-top: 0.15rem;
}

.caller-id-line {
    display: block;
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 0.1rem;
}

.caller-id-close {
    border: 0;
    background: transparent;
    color: #94a3b8;
    padding: 0.15rem;
    line-height: 1;
    cursor: pointer;
}

.caller-id-close:hover {
    color: #475569;
}

.caller-id-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.loyalty-check-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 0.35rem 0.75rem;
    max-height: 220px;
    overflow: auto;
    padding: 0.5rem;
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-radius: 8px;
    background: rgba(248, 250, 252, 0.6);
}

.loyalty-check-item {
    display: flex;
    align-items: flex-start;
    gap: 0.4rem;
    font-size: 0.85rem;
    margin: 0;
}

.loyalty-rule-card {
    border: 1px dashed rgba(148, 163, 184, 0.45);
}

.loyalty-status-banner {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    padding: 0.55rem 0.85rem;
    border-radius: 10px;
    background: linear-gradient(90deg, rgba(245, 158, 11, 0.12), rgba(234, 179, 8, 0.08));
    border: 1px solid rgba(245, 158, 11, 0.35);
    color: #92400e;
    font-size: 0.9rem;
}

.payment-loyalty-panel .input-group {
    flex-wrap: nowrap;
}

.loyalty-payment-result {
    margin-top: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    background: var(--bs-light, #f8f9fa);
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.loyalty-payment-result.is-success {
    background: rgba(25, 135, 84, 0.08);
    border-color: rgba(25, 135, 84, 0.25);
}

.loyalty-payment-result.is-error {
    background: rgba(220, 53, 69, 0.08);
    border-color: rgba(220, 53, 69, 0.25);
    color: #842029;
}

.table-pos-loyalty-bar {
    width: 100%;
    margin-top: 0.5rem;
}

.loyalty-customer-chip {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.65rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(148, 163, 184, 0.35);
    position: relative;
}

.loyalty-customer-chip.is-attached {
    background: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.35);
}

.loyalty-discount-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    background: #f59e0b;
    color: #fff;
}

.loyalty-discount-badge.is-muted {
    background: #64748b;
}

#tableCustomerSearch {
    min-width: 220px;
    max-width: 320px;
}

.table-pos-loyalty-bar .customer-search-results {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    z-index: 20;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
    max-height: 220px;
    overflow: auto;
}

.receipt-preview-shell {
    min-height: 520px;
    max-height: 70vh;
    overflow: auto;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 12px;
    width: 100%;
}

.receipt-preview-mount {
    width: 100%;
}

.receipt-preview-shell .receipt-print,
.receipt-studio-stage .receipt-print {
    width: var(--receipt-width, 80mm);
    max-width: 100%;
    margin: 0 auto;
}

.receipt-preview-shell .receipt-print-inner,
.receipt-studio-stage .receipt-print-inner {
    width: 100%;
    max-width: 100%;
    margin: 0;
}

.receipt-ctrl-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem 1rem;
}

.receipt-ctrl-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
    margin-bottom: 0.2rem;
}

.receipt-ctrl-head label {
    font-size: 0.78rem;
    font-weight: 600;
    color: #334155;
    margin: 0;
}

.receipt-ctrl-val {
    font-size: 0.75rem;
    font-weight: 700;
    color: #EA580C;
    font-variant-numeric: tabular-nums;
}

.receipt-studio-preview {
    background: #fff;
    border: 1px solid #C9D3E0;
    border-radius: 18px;
    overflow: hidden;
    box-shadow:
        0 2px 4px rgba(26, 41, 64, 0.04),
        0 10px 24px rgba(26, 41, 64, 0.07);
    top: 1rem;
}

.receipt-studio-preview-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid #E8EEF5;
}

.receipt-studio-preview-head strong {
    display: block;
    font-size: 0.92rem;
}

.receipt-studio-preview-head span {
    display: block;
    font-size: 0.72rem;
    color: #64748B;
}

.receipt-studio-stage {
    background:
        radial-gradient(circle at top, rgba(255, 255, 255, 0.08), transparent 46%),
        linear-gradient(180deg, #1A2940 0%, #111827 100%);
    padding: 1.35rem 1rem 1.6rem;
    min-height: 560px;
    max-height: 74vh;
    overflow: auto;
}

.receipt-paper {
    width: min(100%, var(--receipt-width, 80mm));
    margin: 0 auto;
    background: #fffef8;
    box-shadow:
        0 18px 40px rgba(0, 0, 0, 0.35),
        inset 0 0 0 1px rgba(0, 0, 0, 0.04);
    position: relative;
}

.receipt-paper::before {
    content: "";
    display: block;
    height: 10px;
    background:
        repeating-linear-gradient(
            90deg,
            #fffef8 0 8px,
            transparent 8px 12px
        );
    clip-path: polygon(0 0, 8px 100%, 16px 0, 24px 100%, 32px 0, 40px 100%, 48px 0, 56px 100%, 64px 0, 72px 100%, 80px 0, 88px 100%, 96px 0, 104px 100%, 112px 0, 120px 100%, 128px 0, 100% 100%, 100% 0);
    margin: 0 0 2px;
}

@media (max-width: 767.98px) {
    .receipt-ctrl-grid {
        grid-template-columns: 1fr;
    }
}

/* Cash handover */
.cash-handover-stat-card {
    background: #fff;
    border: 1px solid var(--cash-report-border, #e8ecf1);
    border-radius: var(--radius-md, 10px);
    padding: 1rem 1.15rem;
    height: 100%;
    box-shadow: var(--shadow-sm);
}

.cash-handover-stat-card .label {
    display: block;
    font-size: 0.78rem;
    color: var(--text-muted, #64748b);
    margin-bottom: 0.35rem;
}

.cash-handover-stat-card strong {
    font-size: 1.05rem;
    color: var(--text-primary);
}

.cash-handover-stat-card.accent {
    border-color: rgba(242, 101, 34, 0.35);
    background: linear-gradient(135deg, rgba(242, 101, 34, 0.06), #fff);
}

.cash-handover-stat-card.accent strong {
    color: var(--brand, #F26522);
    font-size: 1.2rem;
}

.cash-handover-form-card {
    position: sticky;
    top: 1rem;
}

.cash-handover-diff {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    background: #f8fafc;
    border: 1px solid #e8ecf1;
    font-size: 0.9rem;
}

.cash-handover-diff strong {
    font-size: 1.05rem;
}

.cash-handover-diff.is-match {
    background: #ecfdf5;
    border-color: #a7f3d0;
    color: #065f46;
}

.cash-handover-diff.is-over {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #1e40af;
}

.cash-handover-diff.is-under {
    background: #fef2f2;
    border-color: #fecaca;
    color: #991b1b;
}

.handover-receipt-inner {
    max-width: 80mm;
    margin: 0 auto;
}

.receipt-info-table {
    width: 100%;
    font-size: 10pt;
    border-collapse: collapse;
}

.receipt-info-table td {
    padding: 0.15rem 0;
    vertical-align: top;
}

.receipt-info-table td:first-child {
    color: #666;
    width: 42%;
}

.receipt-info-table td:last-child {
    text-align: right;
}

.receipt-items-table {
    width: 100%;
    font-size: 9pt;
    border-collapse: collapse;
}

.receipt-items-table th,
.receipt-items-table td {
    padding: 0.12rem 0;
    border-bottom: 1px solid #eee;
}

.receipt-divider {
    border-top: 1px dashed #999;
    margin: 0.5rem 0;
}

/* Logistics panel */
.logistics-panel-page {
    animation: fadeIn 0.25s ease;
}

.logistics-alert {
    border-radius: 12px;
    border: none;
}

.logistics-fee-input {
    width: 88px;
}

.partnership-grid tbody tr.partnership-row {
    cursor: pointer;
}

.partnership-grid tbody tr.partnership-row:hover td {
    background: #f8fafc;
}

.partnership-grid tbody tr.partnership-row:focus-visible {
    outline: 2px solid var(--primary, #2563eb);
    outline-offset: -2px;
}

.partnership-row-link {
    font-weight: 600;
    color: inherit;
    text-decoration: none;
}

.partnership-row-link:hover {
    color: var(--primary, #2563eb);
}

.partnership-back {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 0.85rem;
    color: #64748b;
    font-size: 0.875rem;
    text-decoration: none;
}

.partnership-back:hover {
    color: var(--primary, #2563eb);
}

.partnership-status-badge {
    align-self: center;
    font-size: 0.85rem;
    padding: 0.45rem 0.75rem;
}

.partnership-facts {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem 1.25rem;
    margin: 0;
}

.partnership-facts > div {
    min-width: 0;
}

.partnership-facts dt {
    margin: 0 0 0.15rem;
    color: #64748b;
    font-size: 0.75rem;
    font-weight: 600;
}

.partnership-facts dd {
    margin: 0;
    font-weight: 600;
}

.partnership-facts-wide {
    grid-column: 1 / -1;
}

.partnership-money {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.partnership-money > div {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 0.85rem 0.95rem;
}

.partnership-money span {
    display: block;
    color: #64748b;
    font-size: 0.75rem;
    margin-bottom: 0.25rem;
}

.partnership-money strong {
    font-size: 1.15rem;
}

.partnership-diff {
    display: grid;
    gap: 0.55rem;
}

.partnership-diff > div {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.55rem;
}

.partnership-diff span {
    min-width: 8.5rem;
    color: #64748b;
    font-size: 0.85rem;
}

@media (max-width: 640px) {
    .partnership-facts,
    .partnership-money {
        grid-template-columns: 1fr;
    }
}

.logistics-status {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.55rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.logistics-status.pending { background: #FEF3C7; color: #B45309; }
.logistics-status.pool { background: #E0E7FF; color: #4338CA; }
.logistics-status.assigned { background: var(--primary-light, #DBEAFE); color: var(--primary-dark, #1D4ED8); }
.logistics-status.picked { background: #FCE7F3; color: #BE185D; }
.logistics-status.onway { background: #CFFAFE; color: #0E7490; }
.logistics-status.delivered { background: #DCFCE7; color: #15803D; }
.logistics-status.cancelled { background: #FEE2E2; color: #B91C1C; }

.logistics-courier-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0.85rem;
}

.logistics-courier-card {
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 14px;
    padding: 0.85rem 1rem;
    background: #fff;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.logistics-courier-card:hover {
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
    transform: translateY(-1px);
}

.logistics-courier-card.has-job {
    border-color: rgba(37, 99, 235, 0.25);
}

.logistics-courier-card.busy {
    background: linear-gradient(180deg, #fff 0%, #F8FAFF 100%);
}

.logistics-courier-card-top {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.logistics-courier-avatar {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--brand, #2563EB);
    color: #fff;
    font-weight: 700;
    flex-shrink: 0;
}

.logistics-courier-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 0.65rem;
    font-size: 0.78rem;
    color: #64748B;
}

.logistics-shift-badge {
    margin-left: auto;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.2rem 0.5rem;
    border-radius: 999px;
    white-space: nowrap;
}

.logistics-shift-badge.on {
    background: #DCFCE7;
    color: #15803D;
}

.logistics-shift-badge.off {
    background: #F1F5F9;
    color: #64748B;
}

.logistics-offshift-list {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.logistics-offshift-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.45rem 0.65rem;
    border-radius: 10px;
    background: #F8FAFC;
    font-size: 0.85rem;
}

.logistics-subsection-title {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #94A3B8;
}

.logistics-empty-state {
    text-align: center;
    padding: 2rem 1rem;
    color: #64748B;
}

.logistics-empty-state.compact {
    padding: 1.25rem 1rem;
}

.logistics-empty-state i {
    display: block;
    font-size: 2rem;
    margin-bottom: 0.65rem;
    opacity: 0.45;
}

.logistics-jobs-table td {
    vertical-align: middle;
}

.logistics-steps .logistics-step-card {
    height: 100%;
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 14px;
    padding: 1rem;
    background: #fff;
}

.logistics-step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 999px;
    background: var(--brand, #2563EB);
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.logistics-map-card .card-body-custom,
.logistics-map-card .logistics-map-canvas {
    padding: 0;
}

.logistics-map-canvas {
    height: min(68vh, 640px);
    min-height: 420px;
    width: 100%;
    border-radius: 0 0 14px 14px;
    z-index: 1;
}

.logistics-board-map {
    height: 460px;
    min-height: 360px;
}

@media (max-width: 768px) {
    .logistics-board-map {
        height: 220px;
        min-height: 200px;
    }
}

.logistics-board-page {
    min-width: 0;
    max-width: 100%;
}

.board-job-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.65rem;
    padding: 0.75rem;
    background: #EEF2F7;
    border: 1px solid #C5CEDB;
    border-radius: 14px;
    box-shadow:
        0 2px 4px rgba(26, 41, 64, 0.05),
        0 12px 28px rgba(26, 41, 64, 0.1);
}

.board-job-empty {
    padding: 1.25rem 0.85rem;
    text-align: center;
    color: var(--text-muted);
}

.board-job-wrap {
    position: relative;
}

.board-job-nav {
    position: absolute;
    right: 0.7rem;
    bottom: 0.7rem;
}

.board-job {
    display: block;
    min-width: 0;
    border: 1px solid #E8EEF5;
    border-radius: 12px;
    padding: 0.9rem 0.95rem;
    background: #fff;
    color: inherit;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(26, 41, 64, 0.06);
    transition: transform 0.12s ease, box-shadow 0.12s ease, border-color 0.12s ease;
}

a.board-job:hover {
    border-color: #E4E0DB;
    color: inherit;
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(26, 41, 64, 0.1);
}

.board-job-top,
.board-job-meta,
.board-assign {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem;
    min-width: 0;
}

.board-job-top strong,
.board-job-meta,
.board-job-address {
    overflow-wrap: anywhere;
}

.board-job-amount {
    flex: 0 0 auto;
    font-weight: 700;
    white-space: nowrap;
}

.board-job-meta {
    flex-wrap: wrap;
    justify-content: flex-start;
    margin-top: 0.45rem;
    color: #4b5563;
    font-size: 0.85rem;
}

.board-job-address {
    margin-top: 0.35rem;
    color: #6b7280;
    font-size: 0.82rem;
}

.board-assign {
    margin-top: 0.75rem;
    align-items: stretch;
}

.board-assign select {
    flex: 1 1 auto;
    min-width: 0;
}

@media (min-width: 992px) {
    .board-job-list {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .board-assign {
        flex-direction: column;
    }

    .board-assign .btn {
        width: 100%;
    }
}

.all-orders-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 0.75rem;
    box-shadow: var(--shadow-sm);
}

.all-orders-filters .form-control,
.all-orders-filters .form-select {
    width: auto;
    min-width: 9.5rem;
    flex: 1 1 9.5rem;
}

.all-orders-status {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    min-width: 11rem;
}

.all-orders-source {
    width: 1.7rem;
    height: 1.7rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    color: #fff;
    font-size: 0.85rem;
}

.all-orders-source.tone-phone { background: #16a34a; }
.all-orders-source.tone-web { background: #2563eb; }
.all-orders-source.tone-ys { background: #e11d48; }
.all-orders-source.tone-getir { background: #5b21b6; }
.all-orders-source.tone-trendyol { background: #f59e0b; color: #111827; }
.all-orders-source.tone-migros { background: #ea580c; }
.all-orders-source.tone-tikla { background: #e31c23; }
.all-orders-source.tone-other { background: #64748b; }

.order-exclude-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    align-self: stretch;
    gap: 0.65rem 1rem;
    flex: 1 1 100%;
    width: 100%;
    margin-top: 0.15rem;
    padding-top: 0.8rem;
    border-top: 1px dashed var(--border-color);
}

.order-exclude-filter .exclude-title {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 9.5rem;
}

.order-exclude-filter .exclude-title strong {
    font-size: 0.78rem;
    font-weight: 700;
    color: #111827;
}

.order-exclude-filter .exclude-title small {
    font-size: 0.7rem;
    color: #6b7280;
    line-height: 1.3;
}

.order-exclude-filter .exclude-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    flex: 1 1 16rem;
}

.order-exclude-filter label {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin: 0;
    padding: 0.32rem 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: #f8fafc;
    color: #374151;
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    cursor: pointer;
    user-select: none;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.order-exclude-filter label:hover {
    border-color: #cbd5e1;
    background: #fff;
}

.order-exclude-filter input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.order-exclude-filter label:has(input:checked) {
    background: #fff7ed;
    border-color: #fdba74;
    color: #9a3412;
}

.order-exclude-filter label:has(input:checked)::before {
    content: "−";
    margin-right: 0.28rem;
    font-weight: 700;
}

.order-exclude-filter label:focus-within {
    outline: 2px solid rgba(249, 115, 22, 0.35);
    outline-offset: 1px;
}

.status-stack {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
    min-width: 0;
}

.order-timing,
.order-age,
.order-age.is-delivered {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin-top: 0;
    padding: 0.18rem 0.55rem;
    border-radius: 999px;
    background: #EEF2F7;
    color: #475569;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    white-space: nowrap;
    line-height: 1.2;
}

.order-timing i,
.order-age i {
    font-size: 0.78rem;
    opacity: 0.9;
}

.order-timing.is-open {
    background: #FFF4ED;
    color: var(--primary-dark);
    border: 1px solid #FFD8BF;
}

.order-timing.is-delivered,
.order-age.is-delivered {
    background: #ECFDF5;
    color: #047857;
    border: 1px solid #A7F3D0;
}

.dispatch-note {
    display: inline-flex;
    align-items: center;
    padding: 0.14rem 0.45rem;
    border-radius: 999px;
    background: #EFF6FF;
    color: #1D4ED8;
    border: 1px solid #BFDBFE;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.01em;
}

.dispatch-note.is-urgent {
    background: #FEF2F2;
    color: #B91C1C;
    border-color: #FECACA;
}

.all-orders-customer {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
}

.all-orders-delivery {
    min-width: 7.5rem;
}

.all-orders-dispatch {
    display: flex;
    flex-wrap: wrap;
    gap: 0.28rem;
}

.all-orders-address {
    max-width: 16rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.all-orders-table .order-status-select {
    min-width: 8.5rem;
}

@keyframes logistics-unassigned-blink {
    0%, 100% { background-color: #fff7ed; }
    50% { background-color: #fb923c; }
}

.all-orders-table.table-panel tbody tr.logistics-unassigned-row > td,
.table-panel tbody tr.logistics-unassigned-row > td,
.table-panel tbody tr.logistics-unassigned-row:nth-child(even) > td,
.table-panel tbody tr.logistics-unassigned-row:hover > td {
    animation: logistics-unassigned-blink 1.05s ease-in-out infinite;
}

.table-panel tbody tr.logistics-unassigned-row > td.order-status-cell,
.table-panel tbody tr.logistics-unassigned-row:nth-child(even) > td.order-status-cell,
.table-panel tbody tr.logistics-unassigned-row:hover > td.order-status-cell {
    background: transparent !important;
    animation: none;
}

.table-panel tbody tr.logistics-unassigned-row .order-status-panel {
    animation: logistics-unassigned-blink 1.05s ease-in-out infinite;
    color: #7c2d12;
}

@media (prefers-reduced-motion: reduce) {
    .table-panel tbody tr.logistics-unassigned-row > td,
    .table-panel tbody tr.logistics-unassigned-row .order-status-panel {
        animation: none;
        background-color: #fdba74 !important;
    }
}

.all-orders-table.table-panel tbody td,
.day-orders-table.table-panel tbody td,
.orders-browse-page .table-panel tbody td {
    color: #000;
    font-size: 0.9rem;
    font-weight: 500;
}

.all-orders-table.table-panel tbody td .text-muted,
.day-orders-table.table-panel tbody td .text-muted,
.orders-browse-page .table-panel tbody td .text-muted,
.all-orders-table.table-panel tbody td .small,
.day-orders-table.table-panel tbody td .small,
.orders-browse-page .table-panel tbody td .small {
    color: #1f2937 !important;
    font-weight: 500;
}

.all-orders-table.table-panel tbody td strong,
.day-orders-table.table-panel tbody td strong,
.orders-browse-page .table-panel tbody td strong {
    color: #000;
    font-weight: 600;
}

.logistics-panel-page .all-orders-table.table-panel thead th {
    font-size: 0.9rem;
    font-weight: 600;
}

.logistics-panel-page .all-orders-table.table-panel tbody td {
    font-size: 0.8125rem;
    font-weight: 500;
}

.logistics-panel-page .all-orders-table.table-panel tbody td .text-muted,
.logistics-panel-page .all-orders-table.table-panel tbody td .small {
    font-size: 0.75rem;
    font-weight: 500;
}

.logistics-panel-page .all-orders-table.table-panel tbody td strong,
.logistics-panel-page .all-orders-table.table-panel tbody td .fw-semibold {
    font-weight: 600;
}

.logistics-panel-page .order-status-panel {
    --status-panel-font: 0.75rem;
    padding: 0.35rem 0.45rem;
}

.all-orders-row {
    cursor: pointer;
}

.courier-board {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr);
    min-width: 0;
}

.courier-board-head {
    padding: 0.75rem 0.9rem;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #6b7280;
    background: #f8fafc;
    border-bottom: 1px solid var(--border-color, #E5E7EB);
}

.courier-board-cell {
    min-width: 0;
    padding: 0.85rem 0.9rem;
    border-bottom: 1px solid var(--border-color, #E5E7EB);
    overflow-wrap: anywhere;
}

.courier-board-cell.no-courier {
    color: #9ca3af;
}

.courier-board-cell.has-courier {
    font-weight: 600;
}

@media (max-width: 768px) {
    .courier-board {
        display: flex;
        flex-direction: column;
        gap: 0.75rem;
        padding: 0.85rem;
    }

    .courier-board-head {
        display: none;
    }

    .courier-board-cell {
        border: 0;
        padding: 0.15rem 0;
    }

    .courier-board-cell[data-label="Kaynak"] {
        padding-top: 0.75rem;
    }

    .courier-board-cell[data-label="Kurye"] {
        padding-bottom: 0.75rem;
        border-bottom: 1px solid var(--border-color, #E5E7EB);
    }

    .courier-board-cell::before {
        content: attr(data-label);
        display: block;
        font-size: 0.7rem;
        font-weight: 700;
        letter-spacing: 0.03em;
        text-transform: uppercase;
        color: #9ca3af;
    }
}

.leaflet-div-icon.logistics-map-pin-wrap {
    background: none !important;
    border: none !important;
}

.logistics-map-pin-stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 132px;
    pointer-events: none;
}

.logistics-map-caption {
    margin-top: 3px;
    max-width: 128px;
    padding: 1px 6px;
    border-radius: 6px;
    background: #1A2940;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.3;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.28);
    pointer-events: auto;
}

.logistics-map-popup {
    min-width: 180px;
    font-size: 13px;
    line-height: 1.35;
}

.logistics-map-popup strong {
    display: block;
    margin-bottom: 4px;
}

.logistics-map-popup div {
    margin-top: 2px;
}

.logistics-map-popup span {
    color: #64748b;
    font-weight: 600;
}

.logistics-map-pin {
    position: relative;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid #fff;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.35);
}

.logistics-map-pin i {
    transform: rotate(45deg);
    color: #fff;
    font-size: 1.05rem;
    line-height: 1;
}

.logistics-map-pin.restaurant {
    background: #F59E0B;
}

.logistics-map-pin.courier {
    background: #2563EB;
}

.logistics-map-pin.courier.busy {
    background: #7C3AED;
}

.logistics-map-pin.job {
    background: #DC2626;
}

.courier-live-map,
.courier-job-map {
    height: 320px;
    min-height: 240px;
    width: 100%;
    background: #e8eef5;
}

.logistics-feature-cards .logistics-feature-card {
    border: 1px solid var(--border-color, #E5E7EB);
    border-radius: 14px;
    padding: 1rem;
    background: #fff;
    height: 100%;
}

.logistics-feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    margin-bottom: 0.65rem;
}

.analytics-tabs .nav-link {
    font-size: 0.875rem;
    padding: 0.55rem 0.9rem;
}

.analytics-table-scroll {
    max-height: 420px;
    overflow: auto;
}

.analytics-table-scroll--tall {
    max-height: 560px;
}

.analytics-tab-content {
    min-height: 200px;
}

.mobile-filter-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    width: 100%;
    max-width: 22rem;
}

.mobile-filter-field label {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 700;
    color: #6b7280;
}

.mobile-filter-field .form-select {
    width: 100%;
    min-height: 2.75rem;
    font-size: 1rem;
}

@media (max-width: 768px) {
    .mobile-filter-field,
    .orders-filter-bar .cash-filter-field,
    .orders-filter-bar .form-select,
    .orders-filter-bar .form-control {
        max-width: none;
        width: 100%;
    }

    .orders-filter-bar .form-select,
    .orders-filter-bar .form-control {
        min-height: 2.75rem;
        font-size: 1rem;
    }
}

/* Satış, masa siparişi, hızlı satış — ekrana sığan geniş yerleşim */
@media (min-width: 992px) {
    body:has(.table-pos-page),
    .app-shell:has(.table-pos-page),
    .main-wrapper:has(.table-pos-page) {
        height: 100dvh;
        max-height: 100dvh;
        overflow: hidden;
    }

    .main-content-compact:has(.table-pos-page) {
        padding: 0.45rem 0.6rem 0.5rem;
        overflow: hidden;
        height: calc(100dvh - 0.15rem);
        display: flex;
        flex-direction: column;
    }

    .main-content-compact:has(.table-pos-page) > #restaurant-notifications-mount:not([hidden]) {
        flex: 0 0 auto;
        max-height: 22vh;
        overflow: auto;
        margin-bottom: 0.45rem;
    }

    .table-pos-page:not(.market-pos-page) {
        flex: 1;
        min-height: 0;
        height: 100%;
        overflow: hidden;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-header {
        flex-shrink: 0;
        margin-bottom: 0.45rem;
        padding: 0.45rem 0.75rem;
    }

    .table-pos-page.quick-sale-page .market-pos-header {
        flex-shrink: 0;
        margin-bottom: 0.45rem;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-layout {
        display: grid !important;
        grid-template-columns: 172px minmax(0, 1fr) minmax(380px, 36%) !important;
        grid-template-rows: minmax(0, 1fr) !important;
        grid-template-areas: "cats products cart" !important;
        gap: 0.55rem;
        flex: 1;
        min-height: 0;
        align-items: stretch;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-categories {
        grid-area: cats !important;
        flex-direction: column !important;
        flex-wrap: nowrap !important;
        overflow-x: hidden !important;
        overflow-y: auto !important;
        max-height: none !important;
        gap: 5px;
        padding: 5px;
        background: #FFF3EB;
        border-color: #F8C9AE;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-category {
        white-space: normal;
        flex: 0 0 auto;
        border-bottom: none;
        min-height: 54px;
        padding: 0.72rem 0.7rem;
        font-size: 0.84rem;
        font-weight: 800;
        background: #fff;
        color: #111;
        border-left: 4px solid #FDBA74;
        box-shadow: 0 2px 6px rgba(21, 34, 56, 0.08);
    }

    .table-pos-page:not(.market-pos-page) .table-pos-category.active {
        background: var(--primary) !important;
        color: #fff !important;
        border-color: var(--primary-dark) !important;
        border-left-color: var(--primary-dark) !important;
        border-bottom-color: transparent;
        box-shadow: 0 5px 14px rgba(242, 101, 34, 0.34);
    }

    .table-pos-page:not(.market-pos-page) .table-pos-category.active i {
        color: #fff !important;
    }

    .table-pos-page.quick-sale-page .table-pos-category.active {
        background: linear-gradient(135deg, #0f766e 0%, #059669 55%, #10b981 100%) !important;
        color: #fff !important;
        border-color: #047857 !important;
        border-left-color: #0f766e !important;
        box-shadow: 0 5px 14px rgba(5, 150, 105, 0.34);
    }

    .table-pos-page.quick-sale-page .table-pos-category.active i {
        color: #fff !important;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-products {
        grid-area: products !important;
        max-height: none;
        min-height: 0;
        overflow: hidden;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-product-list:not(.is-list) {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 0.65rem;
        align-content: start;
        overflow: auto;
        min-height: 0;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-product-row {
        min-height: 72px;
        padding: 0.55rem 0.7rem;
        background: linear-gradient(180deg, #ffffff 0%, #f3f6fb 100%);
        border: 1px solid #c9d4e3;
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, 0.95),
            0 8px 16px rgba(21, 34, 56, 0.14);
    }

    .table-pos-page:not(.market-pos-page) .table-pos-product-row .name {
        white-space: normal;
        overflow-wrap: anywhere;
        line-height: 1.25;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-cart {
        grid-area: cart !important;
        align-self: stretch;
        height: 100% !important;
        max-height: 100% !important;
        min-height: 0 !important;
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-cart-table-wrap {
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-cart-footer,
    .table-pos-page:not(.market-pos-page) .phone-order-actions,
    .table-pos-page:not(.market-pos-page) .table-pos-payment-history {
        flex-shrink: 0;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-cart-footer {
        margin-top: 0;
        position: sticky;
        bottom: 0;
        z-index: 3;
        background: #fafbfc;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        flex-shrink: 0;
    }

    .phone-order-page .phone-order-summary {
        grid-template-columns: 1fr;
    }

    .phone-order-page .phone-order-cart,
    .phone-order-page .phone-order-cart-main,
    .phone-order-page .phone-order-form {
        flex: 1 1 auto;
        min-height: 0;
        overflow: hidden;
    }

    .phone-order-page .table-pos-cart-table-wrap,
    .phone-order-page .phone-order-cart-table-wrap {
        min-height: 0;
        flex: 1 1 auto;
        overflow-y: auto;
    }

    .phone-order-page .phone-order-details-panels {
        display: flex;
        flex-direction: column;
        flex: 0 0 auto;
        max-height: 46%;
        overflow: auto;
    }

    .phone-order-page .phone-order-details-panels .phone-order-panel:last-child {
        order: -1;
        position: sticky;
        top: 0;
        z-index: 2;
        background: #fff;
    }

    .phone-order-page .phone-order-actions {
        flex-shrink: 0;
        position: sticky;
        bottom: 0;
        z-index: 3;
        background: #fff;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-cart-table {
        font-size: 0.82rem;
    }

    .table-pos-page:not(.market-pos-page) .table-pos-cart-table thead th,
    .table-pos-page:not(.market-pos-page) .table-pos-cart-table tbody td {
        padding: 0.45rem 0.35rem;
    }

    .market-pos-page .table-pos-layout {
        grid-template-columns: minmax(0, 1fr) minmax(300px, 340px) !important;
    }

    .market-pos-page .market-pos-product-grid,
    .market-pos-page .table-pos-product-list.market-pos-product-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)) !important;
    }

    .market-pos-page .table-pos-cart,
    .market-pos-page .market-pos-cart {
        align-self: stretch;
        height: 100% !important;
        max-height: 100% !important;
        min-height: 0 !important;
        overflow: hidden !important;
        display: flex !important;
        flex-direction: column !important;
    }

    .market-pos-page .market-pos-cart-body,
    .market-pos-page .table-pos-cart-table-wrap {
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
    }

    .market-pos-page .market-pos-checkout {
        flex-shrink: 0;
        position: sticky;
        bottom: 0;
        z-index: 3;
        background: #fff;
    }
}

@media (max-width: 991.98px) {
    .table-pos-page .table-pos-cart-footer,
    .table-pos-page .phone-order-actions,
    .table-pos-page .market-pos-checkout {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 40;
        background: #fff;
        box-shadow: 0 -6px 18px rgba(15, 23, 42, 0.12);
    }

    .table-pos-page {
        padding-bottom: 5.75rem;
    }
}

.order-completed-overlay {
    position: fixed;
    inset: 0;
    z-index: 4000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.45);
}

.order-completed-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.65rem;
    min-width: 240px;
    padding: 1.6rem 2rem;
    border-radius: 16px;
    background: #fff;
    color: #166534;
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.2);
}

.order-completed-card i {
    font-size: 2.4rem;
}

.order-completed-card strong {
    font-size: 1.25rem;
}

.website-preview-address {
    margin: 0;
    padding: 0.55rem 0.9rem;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    color: #0f172a;
    font-size: 0.85rem;
    font-weight: 700;
    word-break: break-all;
}

.help-topic-icon {
    width: 40px;
    height: 40px;
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #fff4ed;
    color: #d9561a;
}

.help-steps {
    list-style: none;
    margin: 0 0 1.25rem;
    padding: 0;
}

.help-steps li {
    display: grid;
    grid-template-columns: 32px 1fr;
    gap: 0.75rem;
    padding: 0.85rem 0;
    border-top: 1px solid var(--border-color, #e5e7eb);
}

.help-steps li span {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #1a2940;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
}

.help-steps p {
    margin: 0.25rem 0 0;
    color: #64748b;
}

.courier-job-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 0.35rem;
}

.courier-early-hint {
    flex: 1 0 100%;
    text-align: right;
    font-size: 0.7rem;
    font-weight: 700;
    color: #92400e;
}

.courier-shift-due {
    background: #fef3c7;
    color: #92400e;
}

.logistics-panel-page tr.courier-urgent-row > td {
    background: #fff7ed;
}

.header-notif {
    position: relative;
}

.header-notif-btn {
    position: relative;
    width: 2.4rem;
    height: 2.4rem;
    border: 1px solid rgba(26, 41, 64, 0.12);
    border-radius: 12px;
    background: linear-gradient(#fff, #f4f7fb);
    color: #1A2940;
    box-shadow: inset 0 1px 0 #fff, 0 4px 10px rgba(26, 41, 64, 0.08);
}

.header-notif-badge {
    position: absolute;
    top: -0.3rem;
    right: -0.3rem;
    min-width: 1.1rem;
    height: 1.1rem;
    padding: 0 0.25rem;
    border-radius: 999px;
    background: #F26522;
    color: #fff;
    font-size: 0.68rem;
    line-height: 1.1rem;
    font-weight: 600;
}

.header-notif-pop {
    position: absolute;
    top: calc(100% + 0.45rem);
    right: 0;
    width: min(380px, calc(100vw - 1.5rem));
    background: #fff;
    border: 1px solid #e6edf5;
    border-radius: 16px;
    box-shadow: 0 16px 40px rgba(26, 41, 64, 0.18);
    z-index: 40;
    overflow: hidden;
}

.header-notif-head {
    padding: 0.75rem 0.9rem;
    font-weight: 600;
    color: #1A2940;
    background: linear-gradient(#fff, #f6f8fb);
    border-bottom: 1px solid #e6edf5;
}

.header-notif-compose {
    display: flex;
    gap: 0.45rem;
    align-items: flex-end;
    padding: 0.7rem 0.9rem;
    border-bottom: 1px solid #eef2f6;
}

.header-notif-compose textarea {
    flex: 1;
    resize: vertical;
    min-height: 2.4rem;
}

.header-notif-scroll {
    max-height: min(420px, 60vh);
    overflow: auto;
}

.header-notif-empty {
    margin: 0;
    padding: 1rem 0.9rem;
    color: #64748b;
}

.header-notif-item,
.header-notif-scroll .restaurant-notif-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    width: 100%;
    text-align: left;
    border: 0;
    border-bottom: 1px solid #eef2f6;
    background: #fff;
    padding: 0.7rem 0.9rem;
}

.header-notif-item-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
    color: #111;
    font-weight: 400;
}

.header-notif-item-text span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 230px;
}

.notice-state {
    flex: 0 0 auto;
    border-radius: 999px;
    padding: 0.16rem 0.55rem;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 500;
    line-height: 1.2;
}

.notice-state.is-new { background: #F26522; }
.notice-state.is-seen { background: #15803D; }

.panel-card:has(.all-orders-table) > .table-responsive,
.panel-card:has(.table-panel) > .table-responsive,
.panel-card:has(.pm-table) > .table-responsive,
.customers-panel .table-responsive {
    max-height: none !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
}
