/* Orders CSS Styles ? palette aligned with tables */
:root {
    --bg: #0b0f14;
    --surface: #1e293b;
    --surface-2: #0f172a;
    --border: #334155;
    --border-hover: #475569;
    --text: #e5e7eb;
    --muted: #94a3b8;
    --accent: #6366f1;
    --accent-hover: #818cf8;
    --success: #22c55e;
    --danger: #ef4444;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Inter, system-ui, -apple-system, sans-serif;
    background: #0b0f14;
    color: #e5e7eb;
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: hidden;
    font-weight: 400;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 25% 25%, rgba(99, 102, 241, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(139, 92, 246, 0.03) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 16px;
    position: relative;
}

.header {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

.header h1 {
    font-size: 2.5rem;
    font-weight: 600;
    color: #e5e7eb;
    margin-bottom: 8px;
    letter-spacing: -0.01em;
    line-height: 1.1;
}

.create-order-btn {
    background: #1e293b;
    color: #e5e7eb;
    border: 1px solid #334155;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

.create-order-btn:hover {
    background: #334155;
    border-color: #475569;
}

.create-order-btn:active {
    transform: translateY(0);
}

/* ????????? ???? */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    height: 100dvh; /* ???????????? ?????? viewport */
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

/* ????? ??? ?????????? ???? ?????? ???? */
.dish-search-modal {
    z-index: 1001; /* ?????? ????????? ?????????? ???? */
}

.dish-search-modal .modal-content {
    max-width: 100%;
    max-height: 100vh;
    width: 100%;
    height: 100vh;
    border-radius: 0;
}

.dish-search-results-modal {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    margin-top: 5px;
}

.dish-search-result-modal {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dish-search-result-modal:hover {
    background: rgba(255, 255, 255, 0.1);
}

.dish-search-result-modal.selected {
    background: rgba(99, 102, 241, 0.2);
    border-left: 3px solid #6366f1;
}

.dish-search-name-modal {
    font-weight: 500;
    color: #e5e7eb;
}

.selected-dishes-modal {
    margin-top: 20px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.selected-dishes-modal h3 {
    margin: 0 0 15px 0;
    color: #e5e7eb;
    font-size: 16px;
}

.selected-dish-modal {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    margin: 5px 0;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.selected-dish-info-modal {
    flex: 1;
}

.selected-dish-name-modal {
    font-weight: 500;
    color: #e5e7eb;
    margin-bottom: 2px;
}

.remove-dish-btn-modal {
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 6px 10px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s ease;
}

.remove-dish-btn-modal:hover {
    background: #dc2626;
    transform: translateY(-1px);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh; /* ???????????? ?????? viewport */
    max-width: none;
    max-height: none;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
}

.dish-search-modal .modal-content {
    animation: slideDown 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(100vh);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-100vh);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    padding: 15px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #e5e7eb;
    margin: 0;
}

.back-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #e5e7eb;
    padding: 8px 16px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: none;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.back-btn.active {
    display: block;
}

.close-btn {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.close-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #e5e7eb;
}

.modal-body {
    padding: 15px;
    flex: 1;
    overflow-y: auto;
}

.modal-footer {
    padding: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #94a3b8;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #334155;
    border-radius: 8px;
    background: #0f172a;
    color: #e5e7eb;
    font-size: 14px;
    transition: all 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
    background: #1e293b;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #94a3b8;
}

.dish-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    margin-top: 5px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    padding: 10px 0;
}

.dish-search-result {
    padding: 12px;
    cursor: pointer;
    color: #e5e7eb;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dish-search-result:hover {
    background: rgba(255, 255, 255, 0.15);
}

.dish-search-result:last-child {
    border-bottom: none;
}

.dish-search-result.selected {
    background: rgba(99, 102, 241, 0.2);
    border-left: 3px solid #6366f1;
}

.dish-search-result.selected .dish-search-name {
    color: #6366f1;
}

.dish-search-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.dish-search-result-modal.selected .dish-search-name-modal {
    color: #6366f1;
}

/* ????? ??? ?????????? ??????????? */
.quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 10px;
}

.quantity-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #e5e7eb;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: bold;
    transition: all 0.3s ease;
}

.quantity-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.quantity-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.quantity-display {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #e5e7eb;
    min-width: 40px;
    height: 30px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
}

.select-dish-btn {
    background: linear-gradient(45deg, #6366f1, #4f46e5);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-left: 10px;
}

.select-dish-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.select-dish-btn:disabled {
    background: rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.comment-btn {
    background: #6366f1;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-left: 5px;
}

.comment-btn:hover {
    background: #4f46e5;
    transform: translateY(-1px);
}

.dish-actions {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* ????????? ???? ??????????? ?????? ???? ?????? ???? ????????? */
#commentModal, #addCommentModal {
    z-index: 10002;
}

#commentModal .modal-content, #addCommentModal .modal-content {
    z-index: 10003;
}

.dish-search-info-modal {
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dish-search-details-modal {
    flex: 1;
}

.dish-search-name {
    font-weight: 600;
    margin-bottom: 4px;
    color: #e5e7eb;
}

.dish-search-description {
    font-size: 0.8rem;
    color: #94a3b8;
    margin-bottom: 4px;
}

.categories-section,
.dishes-section {
    margin-top: 10px;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.category-card {
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.category-card:hover {
    background: #1e293b;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border-color: #6366f1;
}

.category-card.selected {
    background: #1e40af;
    border-color: #6366f1;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.dishes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.dish-card {
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.dish-card:hover {
    background: #1e293b;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border-color: #6366f1;
}

.dish-card.selected {
    background: #1e40af;
    border-color: #6366f1;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.dish-card.selected::after {
    content: '?';
    position: absolute;
    top: 10px;
    right: 15px;
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
}

.dish-title {
    font-weight: 600;
    margin-bottom: 6px;
    color: #ffffff;
    font-size: 0.9rem;
    line-height: 1.3;
}

.dish-description {
    color: #94a3b8;
    font-size: 0.8rem;
    margin-bottom: 6px;
}

.selected-dishes {
    margin-top: 20px;
    padding: 20px;
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid rgba(76, 175, 80, 0.3);
    border-radius: 15px;
}

.selected-dishes h3 {
    color: #6366f1;
    margin-bottom: 15px;
}

.selected-dish-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    margin-bottom: 10px;
    gap: 10px;
}

.selected-dish-item span {
    flex: 1;
}

.remove-dish {
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.remove-dish:hover {
    background: #dc2626;
    transform: scale(1.1);
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.btn {
    padding: 8px 16px;
    border: 1px solid #334155;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
    background: #1e293b;
    color: #e5e7eb;
}

.btn-primary {
    background: #1e293b;
    border-color: #334155;
    color: #e5e7eb;
}

.btn-secondary {
    background: #1e293b;
    color: #e5e7eb;
    border-color: #334155;
}

.btn:hover {
    background: #334155;
    border-color: #475569;
}

.btn:active {
    transform: translateY(0);
}

.orders-grid {
    display: block;
    width: 100%;
}

.order-card {
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 12px;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.order-card:hover {
    border-color: #6366f1;
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.order-card:nth-child(even) {
    background-color: #0f172a;
}

.order-card:nth-child(odd) {
    background-color: rgb(12, 21, 39);
}

/* Inline styles moved to CSS */
.dishes-section {
    display: none;
}

.form-group-margin-top {
    margin-top: 20px;
}

.dish-search-container {
    display: flex;
    gap: 10px;
}

.dish-search-input {
    flex: 1;
}

.extended-search-btn {
    padding: 8px 16px;
    background: #1e293b;
    color: #e5e7eb;
    border: 1px solid #334155;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 14px;
}

.extended-search-btn:hover {
    background: #334155;
    border-color: #475569;
}

.confirm-add-dishes-btn {
    display: none;
}

.comment-modal-content {
    max-width: 500px;
}

.comment-dish-name {
    color: #ffffff;
    font-weight: 500;
    margin-bottom: 10px;
    display: block;
}

.comment-textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #3a3a3a;
    border-radius: 8px;
    background: #2a2a2a;
    color: #ffffff;
    resize: vertical;
}

.subcategory-group {
    margin-bottom: 6px;
    background: rgba(255, 255, 255, 0.01);
    padding: 6px;
}

.subcategory-name {
    color: #10b981;
    font-weight: 600;
    font-size: 0.8rem;
    margin-bottom: 4px;
    display: inline-block;
}

.dishes-list {
    margin-left: 0;
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 4px;
}

.dish-item {
    margin-bottom: 0;
    padding: 6px 8px;
    background: rgba(255, 255, 255, 0.02);
    transition: all 0.2s ease;
}

.dish-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: #475569;
}

.dish-item.ordered {
    /* ?????????? ????? - ??? ?????????, ??????? ??? */
    background: transparent;
    border-left: 1px solid #374151;
}

.dish-item.closed {
    background: rgba(107, 114, 128, 0.1);
    border-left: 3px solid #6b7280;
}


.dish-item.created {
    /* ?? ?????????? ????? - ??? ?????????, ?????? badge */
    background: transparent;
    border-left: 1px solid #374151;
}

.dish-name {
    color: #e5e7eb;
    font-size: 0.9rem;
    display: inline;
    margin-right: 4px;
    flex: 1;
    text-transform: lowercase;
}



.dish-comment {
    color: #94a3b8;
    font-style: italic;
    font-size: 0.75rem;
    background: rgba(148, 163, 184, 0.05);
    padding: 2px 6px;
    border-radius: 3px;
    display: block;
    margin-left: 20px;
}

.dish-status {
    color: #94a3b8;
    font-weight: 500;
    font-size: 0.8rem;
    margin-left: 4px;
    display: inline;
}


.status-btn {
    background: #1f2937;
    color: #e5e7eb;
    border: 1px solid #374151;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
}

.status-btn.completed {
    background: #059669;
    color: white;
    border-color: #059669;
}

.status-btn:hover {
    opacity: 0.8;
}

.order-ready-status {
    color: #94a3b8;
    font-weight: 500;
    font-size: 14px;
    margin-left: 10px;
}

.empty-orders {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px 20px;
    color: #94a3b8;
}

.empty-orders h3 {
    margin-bottom: 8px;
    font-weight: 600;
    color: #e5e7eb;
}

.empty-orders p {
    margin: 0;
    font-weight: 400;
}

.not-found {
    grid-column: 1 / -1;
    text-align: center;
    padding: 20px;
    color: #94a3b8;
    font-weight: 400;
}

.comment-btn {
    background: #1e293b;
    color: #e5e7eb;
    border: 1px solid #334155;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 12px;
}

.comment-btn.has-comment {
    background: #1e293b;
    border-color: #334155;
}

.comment-btn:hover {
    background: #334155;
    border-color: #475569;
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 0 0 12px 0;
    margin-bottom: 12px;
    border-bottom: 1px solid #1f2937;
}

.order-number {
    font-size: 0.8rem;
    color: #94a3b8;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.order-status {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.order-status.active {
    background: rgba(34, 197, 94, 0.2);
    color: #10b981;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.order-status.inactive {
    background: rgba(107, 114, 128, 0.2);
    color: #6b7280;
    border: 1px solid rgba(107, 114, 128, 0.3);
}

.order-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: #e5e7eb;
    line-height: 1.3;
    padding: 0;
}

.order-description {
    color: #94a3b8;
    margin-bottom: 16px;
    line-height: 1.4;
    padding: 0;
    font-size: 0.9rem;
}

.order-category {
    display: inline-block;
    background: rgba(100, 181, 246, 0.2);
    color: #64b5f6;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    margin-bottom: 12px;
}

.order-content {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 16px;
    align-items: start;
}

.order-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.order-actions {
    display: flex;
    flex-direction: row;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}


.order-dishes h4 {
    color: #e5e7eb;
    font-size: 0.9rem;
    margin-bottom: 10px;
    font-weight: 600;
    border-bottom: 1px solid #1f2937;
    padding-bottom: 8px;
}

.category-name {
    color: #6366f1;
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 12px 0;
    padding: 8px 12px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 6px;
    border-left: 4px solid #6366f1;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dishes-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 8px;
}

.dish-item {
    color: #e5e7eb;
    font-size: 0.9rem;
    padding: 0 10px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.02);
    transition: all 0.2s ease;
}

.dish-checkbox-label {
    display: flex;
    align-items: center;
    padding: 0 0 0px 0px;
    cursor: pointer;
    width: 100%;
    margin: 0;
}

.dish-checkbox {
    margin-right: 8px;
    width: 16px;
    height: 16px;
    transform: scale(1.2);
    cursor: pointer;
    accent-color: #10b981;
}

.dish-content {
    flex: 1;
    display: flex;
    align-items: center;
}

.dish-item:hover {
    background: rgba(255, 255, 255, 0.05);
}


.order-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.add-dish-btn {
    padding: 8px 16px;
    border: 1px solid #374151;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #1f2937;
    color: #e5e7eb;
    font-size: 0.85rem;
}

.add-dish-btn:hover {
    background: #37513e;
    border-color: #4b5563;
}

.toggle-status-btn {
    padding: 8px 16px;
    border: 1px solid #374151;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
}

.toggle-status-btn.active {
    color: white;
    background: #8f242466;
}

.toggle-status-btn.inactive {
    background: #059669;
    color: white;
    border-color: #059669;
}

.toggle-status-btn:hover {
    opacity: 0.8;
}

.loading {
    display: none;
    text-align: center;
    padding: 20px;
}

.spinner {
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid #64b5f6;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 0 auto 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.alert {
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: none;
}

.alert.success {
    background: rgba(99, 102, 241, 0.2);
    border: 1px solid rgba(76, 175, 80, 0.3);
    color: #6366f1;
}

.alert.error {
    background: rgba(244, 67, 54, 0.2);
    border: 1px solid rgba(244, 67, 54, 0.3);
    color: #ef4444;
}

/* Navigation styles */
.nav-links {
    display: flex;
    gap: 16px;
    margin-bottom: 30px;
    justify-content: center;
}

.nav-link {
    padding: 12px 24px;
    background: #1f2937;
    color: #e5e7eb;
    text-decoration: none;
    border-radius: 8px;
    border: 1px solid #374151;
    font-weight: 500;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.nav-link:hover {
    background: #374151;
    border-color: #4b5563;
}

.nav-link.active {
    background: #6366f1;
    border-color: #6366f1;
    color: white;
}

/* Empty state styles */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #6b7280;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: #9ca3af;
}

.empty-state p {
    font-size: 1rem;
    line-height: 1.6;
}

/* Responsive styles */
@media (max-width: 1024px) {
    .order-card {
        padding: 12px;
    }
}

@media (max-width: 768px) {
    .order-card {
        padding: 10px;
        margin-bottom: 8px;
    }
    
    .order-content {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .order-actions {
        align-items: stretch;
    }
    
    .category-group {
        padding: 12px;
    }
    
    .subcategory-group {
        padding: 4px;
    }
    
    .dish-item {
        padding: 4px 6px;
    }

    .container { 
        padding: 15px;
    }

    .header h1 {
        font-size: 2rem;
    }

    .categories-grid,
    .dishes-grid {
        grid-template-columns: 1fr;
    }

    .orders-grid {
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column;
    }
}
/* Orders CSS Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Inter, system-ui, -apple-system, sans-serif;
    background: #0b0f14;
    color: #e5e7eb;
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: hidden;
    font-weight: 400;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 25% 25%, rgba(99, 102, 241, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(139, 92, 246, 0.03) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 16px;
    position: relative;
}

.header {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

.header h1 {
    font-size: 2.5rem;
    font-weight: 600;
    color: #e5e7eb;
    margin-bottom: 8px;
    letter-spacing: -0.01em;
    line-height: 1.1;
}

.create-order-btn {
    background: #1e293b;
    color: #e5e7eb;
    border: 1px solid #334155;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

.create-order-btn:hover {
    background: #334155;
    border-color: #475569;
}

.create-order-btn:active {
    transform: translateY(0);
}

/* ????????? ???? */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    height: 100dvh; /* ???????????? ?????? viewport */
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

/* ????? ??? ?????????? ???? ?????? ???? */
.dish-search-modal {
    z-index: 1001; /* ?????? ????????? ?????????? ???? */
}

.dish-search-modal .modal-content {
    max-width: 100%;
    max-height: 100vh;
    width: 100%;
    height: 100vh;
    border-radius: 0;
}

.dish-search-results-modal {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    margin-top: 5px;
}

.dish-search-result-modal {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dish-search-result-modal:hover {
    background: rgba(255, 255, 255, 0.1);
}

.dish-search-result-modal.selected {
    background: rgba(99, 102, 241, 0.2);
    border-left: 3px solid #6366f1;
}

.dish-search-name-modal {
    font-weight: 500;
    color: #e5e7eb;
}

.selected-dishes-modal {
    margin-top: 20px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.selected-dishes-modal h3 {
    margin: 0 0 15px 0;
    color: #e5e7eb;
    font-size: 16px;
}

.selected-dish-modal {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    margin: 5px 0;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.selected-dish-info-modal {
    flex: 1;
}

.selected-dish-name-modal {
    font-weight: 500;
    color: #e5e7eb;
    margin-bottom: 2px;
}

.remove-dish-btn-modal {
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 6px 10px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s ease;
}

.remove-dish-btn-modal:hover {
    background: #dc2626;
    transform: translateY(-1px);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh; /* ???????????? ?????? viewport */
    max-width: none;
    max-height: none;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
}

.dish-search-modal .modal-content {
    animation: slideDown 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(100vh);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-100vh);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    padding: 15px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #e5e7eb;
    margin: 0;
}

.back-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #e5e7eb;
    padding: 8px 16px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: none;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.back-btn.active {
    display: block;
}

.close-btn {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.close-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #e5e7eb;
}

.modal-body {
    padding: 15px;
    flex: 1;
    overflow-y: auto;
}

.modal-footer {
    padding: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #94a3b8;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #334155;
    border-radius: 8px;
    background: #0f172a;
    color: #e5e7eb;
    font-size: 14px;
    transition: all 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
    background: #1e293b;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #94a3b8;
}

.dish-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    margin-top: 5px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    padding: 10px 0;
}

.dish-search-result {
    padding: 12px;
    cursor: pointer;
    color: #e5e7eb;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dish-search-result:hover {
    background: rgba(255, 255, 255, 0.15);
}

.dish-search-result:last-child {
    border-bottom: none;
}

.dish-search-result.selected {
    background: rgba(99, 102, 241, 0.2);
    border-left: 3px solid #6366f1;
}

.dish-search-result.selected .dish-search-name {
    color: #6366f1;
}

.dish-search-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.dish-search-result-modal.selected .dish-search-name-modal {
    color: #6366f1;
}

/* ????? ??? ?????????? ??????????? */
.quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 10px;
}

.quantity-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #e5e7eb;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: bold;
    transition: all 0.3s ease;
}

.quantity-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.quantity-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.quantity-display {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #e5e7eb;
    min-width: 40px;
    height: 30px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
}

.select-dish-btn {
    background: linear-gradient(45deg, #6366f1, #4f46e5);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-left: 10px;
}

.select-dish-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.select-dish-btn:disabled {
    background: rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.comment-btn {
    background: #6366f1;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-left: 5px;
}

.comment-btn:hover {
    background: #4f46e5;
    transform: translateY(-1px);
}

.dish-actions {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* ????????? ???? ??????????? ?????? ???? ?????? ???? ????????? */
#commentModal, #addCommentModal {
    z-index: 10002;
}

#commentModal .modal-content, #addCommentModal .modal-content {
    z-index: 10003;
}

.dish-search-info-modal {
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dish-search-details-modal {
    flex: 1;
}

.dish-search-name {
    font-weight: 600;
    margin-bottom: 4px;
    color: #e5e7eb;
}

.dish-search-description {
    font-size: 0.8rem;
    color: #94a3b8;
    margin-bottom: 4px;
}

.categories-section,
.dishes-section {
    margin-top: 10px;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.category-card {
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.category-card:hover {
    background: #1e293b;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border-color: #6366f1;
}

.category-card.selected {
    background: #1e40af;
    border-color: #6366f1;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.dishes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.dish-card {
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.dish-card:hover {
    background: #1e293b;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border-color: #6366f1;
}

.dish-card.selected {
    background: #1e40af;
    border-color: #6366f1;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.dish-card.selected::after {
    content: '?';
    position: absolute;
    top: 10px;
    right: 15px;
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
}

.dish-title {
    font-weight: 600;
    margin-bottom: 6px;
    color: #ffffff;
    font-size: 0.9rem;
    line-height: 1.3;
}

.dish-description {
    color: #94a3b8;
    font-size: 0.8rem;
    margin-bottom: 6px;
}

.selected-dishes {
    margin-top: 20px;
    padding: 20px;
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid rgba(76, 175, 80, 0.3);
    border-radius: 15px;
}

.selected-dishes h3 {
    color: #6366f1;
    margin-bottom: 15px;
}

.selected-dish-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    margin-bottom: 10px;
    gap: 10px;
}

.selected-dish-item span {
    flex: 1;
}

.remove-dish {
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.remove-dish:hover {
    background: #dc2626;
    transform: scale(1.1);
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.btn {
    padding: 8px 16px;
    border: 1px solid #334155;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
    background: #1e293b;
    color: #e5e7eb;
}

.btn-primary {
    background: #1e293b;
    border-color: #334155;
    color: #e5e7eb;
}

.btn-secondary {
    background: #1e293b;
    color: #e5e7eb;
    border-color: #334155;
}

.btn:hover {
    background: #334155;
    border-color: #475569;
}

.btn:active {
    transform: translateY(0);
}

.orders-grid {
    display: block;
    width: 100%;
}

.order-card {
    background: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 12px;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.order-card:hover {
    border-color: #6366f1;
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.order-card:nth-child(even) {
    background-color: #0f172a;
}

.order-card:nth-child(odd) {
    background-color: rgb(12, 21, 39);
}

/* Inline styles moved to CSS */
.dishes-section {
    display: none;
}

.form-group-margin-top {
    margin-top: 20px;
}

.dish-search-container {
    display: flex;
    gap: 10px;
}

.dish-search-input {
    flex: 1;
}

.extended-search-btn {
    padding: 8px 16px;
    background: #1e293b;
    color: #e5e7eb;
    border: 1px solid #334155;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 14px;
}

.extended-search-btn:hover {
    background: #334155;
    border-color: #475569;
}

.confirm-add-dishes-btn {
    display: none;
}

.comment-modal-content {
    max-width: 500px;
}

.comment-dish-name {
    color: #ffffff;
    font-weight: 500;
    margin-bottom: 10px;
    display: block;
}

.comment-textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #3a3a3a;
    border-radius: 8px;
    background: #2a2a2a;
    color: #ffffff;
    resize: vertical;
}

.subcategory-group {
    margin-bottom: 6px;
    background: rgba(255, 255, 255, 0.01);
    padding: 6px;
}

.subcategory-name {
    color: #10b981;
    font-weight: 600;
    font-size: 0.8rem;
    margin-bottom: 4px;
    display: inline-block;
}

.dishes-list {
    margin-left: 0;
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 4px;
}

.dish-item {
    margin-bottom: 0;
    padding: 6px 8px;
    background: rgba(255, 255, 255, 0.02);
    transition: all 0.2s ease;
}

.dish-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: #475569;
}

.dish-item.ordered {
    /* ?????????? ????? - ??? ?????????, ??????? ??? */
    background: transparent;
    border-left: 1px solid #374151;
}

.dish-item.closed {
    background: rgba(107, 114, 128, 0.1);
    border-left: 3px solid #6b7280;
}


.dish-item.created {
    /* ?? ?????????? ????? - ??? ?????????, ?????? badge */
    background: transparent;
    border-left: 1px solid #374151;
}

.dish-name {
    color: #e5e7eb;
    font-size: 0.9rem;
    display: inline;
    margin-right: 4px;
    flex: 1;
    text-transform: lowercase;
}



.dish-comment {
    color: #94a3b8;
    font-style: italic;
    font-size: 0.75rem;
    background: rgba(148, 163, 184, 0.05);
    padding: 2px 6px;
    border-radius: 3px;
    display: block;
    margin-left: 20px;
}

.dish-status {
    color: #94a3b8;
    font-weight: 500;
    font-size: 0.8rem;
    margin-left: 4px;
    display: inline;
}


.status-btn {
    background: #1f2937;
    color: #e5e7eb;
    border: 1px solid #374151;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
}



.status-btn:hover {
    opacity: 0.8;
}

.order-ready-status {
    color: #94a3b8;
    font-weight: 500;
    font-size: 14px;
    margin-left: 10px;
}

.empty-orders {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px 20px;
    color: #94a3b8;
}

.empty-orders h3 {
    margin-bottom: 8px;
    font-weight: 600;
    color: #e5e7eb;
}

.empty-orders p {
    margin: 0;
    font-weight: 400;
}

.not-found {
    grid-column: 1 / -1;
    text-align: center;
    padding: 20px;
    color: #94a3b8;
    font-weight: 400;
}

.comment-btn {
    background: #1e293b;
    color: #e5e7eb;
    border: 1px solid #334155;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 12px;
}

.comment-btn.has-comment {
    background: #1e293b;
    border-color: #334155;
}

.comment-btn:hover {
    background: #334155;
    border-color: #475569;
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 0 0 12px 0;
    margin-bottom: 12px;
    border-bottom: 1px solid #1f2937;
}

.order-number {
    font-size: 0.8rem;
    color: #94a3b8;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.order-status {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.order-status.active {
    background: rgba(34, 197, 94, 0.2);
    color: #10b981;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.order-status.inactive {
    background: rgba(107, 114, 128, 0.2);
    color: #6b7280;
    border: 1px solid rgba(107, 114, 128, 0.3);
}

.order-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: #e5e7eb;
    line-height: 1.3;
    padding: 0;
}

.order-description {
    color: #94a3b8;
    margin-bottom: 16px;
    line-height: 1.4;
    padding: 0;
    font-size: 0.9rem;
}

.order-category {
    display: inline-block;
    background: rgba(100, 181, 246, 0.2);
    color: #64b5f6;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    margin-bottom: 12px;
}

.order-content {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 16px;
    align-items: start;
}

.order-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.order-actions {
    display: flex;
    flex-direction: row;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}


.order-dishes h4 {
    color: #e5e7eb;
    font-size: 0.9rem;
    margin-bottom: 10px;
    font-weight: 600;
    border-bottom: 1px solid #1f2937;
    padding-bottom: 8px;
}

.category-name {
    color: #6366f1;
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 12px 0;
    padding: 8px 12px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 6px;
    border-left: 4px solid #6366f1;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dishes-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 8px;
}

.dish-item {
    color: #e5e7eb;
    font-size: 0.9rem;
    padding: 0 10px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.02);
    transition: all 0.2s ease;
}

.dish-checkbox-label {
    display: flex;
    align-items: center;
    padding: 0 0 0px 0px;
    cursor: pointer;
    width: 100%;
    margin: 0;
}

.dish-checkbox {
    margin-right: 8px;
    width: 16px;
    height: 16px;
    transform: scale(1.2);
    cursor: pointer;
    accent-color: #10b981;
}

.dish-content {
    flex: 1;
    display: flex;
    align-items: center;
}

.dish-item:hover {
    background: rgba(255, 255, 255, 0.05);
}


.order-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.add-dish-btn {
    padding: 8px 16px;
    border: 1px solid #374151;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #1f2937;
    color: #e5e7eb;
    font-size: 0.85rem;
}

.add-dish-btn:hover {
    background: #37513e;
    border-color: #4b5563;
}

.toggle-status-btn {
    padding: 8px 16px;
    border: 1px solid #374151;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
}

.toggle-status-btn.active {
    color: white;
    background: #8f242466;
}

.toggle-status-btn.inactive {
    background: #059669;
    color: white;
    border-color: #059669;
}

.toggle-status-btn:hover {
    opacity: 0.8;
}

.loading {
    display: none;
    text-align: center;
    padding: 20px;
}

.spinner {
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid #64b5f6;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 0 auto 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.alert {
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: none;
}

.alert.success {
    background: rgba(99, 102, 241, 0.2);
    border: 1px solid rgba(76, 175, 80, 0.3);
    color: #6366f1;
}

.alert.error {
    background: rgba(244, 67, 54, 0.2);
    border: 1px solid rgba(244, 67, 54, 0.3);
    color: #ef4444;
}

/* Navigation styles */
.nav-links {
    display: flex;
    gap: 16px;
    margin-bottom: 30px;
    justify-content: center;
}

.nav-link {
    padding: 12px 24px;
    background: #1f2937;
    color: #e5e7eb;
    text-decoration: none;
    border-radius: 8px;
    border: 1px solid #374151;
    font-weight: 500;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.nav-link:hover {
    background: #374151;
    border-color: #4b5563;
}

.nav-link.active {
    background: #6366f1;
    border-color: #6366f1;
    color: white;
}

/* Empty state styles */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #6b7280;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: #9ca3af;
}

.empty-state p {
    font-size: 1rem;
    line-height: 1.6;
}

/* Responsive styles */
@media (max-width: 1024px) {
    .order-card {
        padding: 12px;
    }
}

@media (max-width: 768px) {
    .order-card {
        padding: 10px;
        margin-bottom: 8px;
    }
    
    .order-content {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .order-actions {
        align-items: stretch;
    }
    
    .category-group {
        padding: 12px;
    }
    
    .subcategory-group {
        padding: 4px;
    }
    
    .dish-item {
        padding: 4px 6px;
    }

    .container { 
        padding: 15px;
    }

    .header h1 {
        font-size: 2rem;
    }

    .categories-grid,
    .dishes-grid {
        grid-template-columns: 1fr;
    }

    .orders-grid {
        grid-template-columns: 1fr;
    }

    .form-actions {
        flex-direction: column;
    }
}

/* ????? ??? ????????? ??????? */
.dish-item {
    position: relative;
}


.item-group-badge {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dish-actions {
    margin-top: 8px;
    display: flex;
    gap: 8px;
}



/* ?????????????? ????? ??? ?????? ?????????? */
.quantity-controls .quantity-btn {
    position: relative;
    z-index: 10;
    pointer-events: auto;
}

.quantity-controls .quantity-btn:not(:disabled) {
    cursor: pointer;
}

.quantity-controls .quantity-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* ??????????, ??? ?????? ?????????? ???????? */
.selected-dish-item .quantity-controls,
.selected-dish-modal .quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 10px;
}

/* ????????????? ???????? ????? ??? ????? ?? ?????? ?????????? */
.quantity-controls button {
    pointer-events: auto !important;
    position: relative;
    z-index: 10;
}

.quantity-controls button:active {
    transform: none !important;
}

/* ????????????? ???????? ??????? ?? ?????? ?????????? */
.quantity-controls {
    position: relative;
    z-index: 10;
}

.quantity-controls * {
    pointer-events: auto !important;
}

/* Search Input Container */
.search-input-container {
    position: relative;
    display: flex;
    align-items: center;
}

.dish-search-input {
    width: 100%;
    padding: 12px 40px 12px 12px;
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 8px;
    background: rgba(17, 24, 39, 0.8);
    color: #e5e7eb;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.dish-search-input:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.clear-search-btn {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.2s ease;
    z-index: 10;
}

.clear-search-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
    color: #fca5a5;
    transform: translateY(-50%) scale(1.1);
}

.clear-search-btn:active {
    transform: translateY(-50%) scale(0.95);
}

/* Comment Styles */
.dish-comment {
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 6px;
    padding: 8px 12px;
    margin: 8px 0;
    font-size: 0.9rem;
    color: #93c5fd;
    line-height: 1.4;
    word-wrap: break-word;
}

.comment-btn {
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    color: #60a5fa;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
}

.comment-btn:hover {
    background: rgba(99, 102, 241, 0.2);
    border-color: rgba(99, 102, 241, 0.5);
    color: #93c5fd;
    transform: translateY(-1px);
}

.comment-btn.has-comment {
    background: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.3);
    color: #4ade80;
}

.comment-btn.has-comment:hover {
    background: rgba(34, 197, 94, 0.2);
    border-color: rgba(34, 197, 94, 0.5);
    color: #86efac;
}

.comment-counter {
    text-align: right;
    font-size: 0.8rem;
    color: #9ca3af;
    margin-top: 4px;
}

.comment-counter span {
    color: #60a5fa;
    font-weight: 500;
}

/* Comment Modal Styles */
#commentModal .modal-content, #addCommentModal .modal-content {
    max-width: 500px;
}

#commentModal textarea, #addCommentModal textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 8px;
    background: rgba(17, 24, 39, 0.8);
    color: #e5e7eb;
    font-size: 0.9rem;
    resize: vertical;
    min-height: 80px;
    max-height: 200px;
    font-family: inherit;
    line-height: 1.5;
}

#commentModal textarea:focus, #addCommentModal textarea:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

#commentModal textarea::placeholder, #addCommentModal textarea::placeholder {
    color: #6b7280;
}

/* Responsive adjustments for comments */
@media (max-width: 768px) {
    .comment-btn {
        min-width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }
    
    .dish-comment {
        font-size: 0.8rem;
        padding: 6px 10px;
    }
    
    .clear-search-btn {
        width: 20px;
        height: 20px;
        font-size: 12px;
        right: 6px;
    }
    
    .dish-search-input {
        padding: 10px 32px 10px 10px;
        font-size: 0.8rem;
    }
}

/* ????? ??? ????????? ???? */
.dish-checkbox:checked {
    accent-color: #22c55e;
}

/* ?????????????? ????? ??? ????????? ????????? */
@supports (height: 100dvh) {
    .modal {
        height: 100dvh; /* ?????????? ???????????? ?????? viewport ???? ?????????????? */
    }
    
    .modal-content {
        height: 100dvh; /* ?????????? ???????????? ?????? viewport ???? ?????????????? */
    }
}

/* Fallback ??? ?????? ????????? */
@supports not (height: 100dvh) {
    .modal {
        height: 100vh;
        height: calc(var(--vh, 1vh) * 100); /* CSS ?????????? ??? ???????????? ?????? */
    }
    
    .modal-content {
        height: 100vh;
        height: calc(var(--vh, 1vh) * 100); /* CSS ?????????? ??? ???????????? ?????? */
    }
}

/* ????? ????? ??? ??????????? ????????? */
.header-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    flex-wrap: wrap;
}

.header-title {
    flex: 1;
    min-width: 0;
}

/* ?????????? ???? ??? ??????? */
.dropdown-menu-container {
    position: relative;
    display: inline-block;
}

.dropdown-toggle {
    background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0;
    color: #e5e7eb;
    transition: all 0.2s ease;
}

.dropdown-toggle:hover {
    opacity: 0.8;
}

.dropdown-toggle h1 {
    margin: 0;
    font-size: 2.5rem;
    font-weight: 600;
    color: #e5e7eb;
    letter-spacing: -0.01em;
    line-height: 1.1;
}

.dropdown-arrow {
    font-size: 0.8rem;
    transition: transform 0.2s ease;
    color: #94a3b8;
}

.dropdown-toggle.active .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 8px;
    background: #1e293b;
    border: 1px solid #334155;
    border-radius: 8px;
    min-width: 200px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1000;
    overflow: hidden;
}

.dropdown-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #e5e7eb;
    text-decoration: none;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid #334155;
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background-color: #334155;
}

.dropdown-icon {
    font-size: 1.2rem;
}

.order-stats {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 12px;
    border-radius: 8px;
    background: rgba(30, 41, 59, 0.6);
    border: 1px solid rgba(51, 65, 85, 0.3);
    backdrop-filter: blur(10px);
    transition: all 0.2s ease;
    min-width: 60px;
}

.stat-item:hover {
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(51, 65, 85, 0.5);
    transform: translateY(-1px);
}

.stat-item.active {
    border-color: rgba(34, 197, 94, 0.3);
    background: rgba(34, 197, 94, 0.1);
}

.stat-item.inactive {
    border-color: rgba(239, 68, 68, 0.3);
    background: rgba(239, 68, 68, 0.1);
}

.stat-item.pending {
    border-color: rgba(245, 158, 11, 0.3);
    background: rgba(245, 158, 11, 0.1);
}

.stat-item.total {
    border-color: rgba(99, 102, 241, 0.3);
    background: rgba(99, 102, 241, 0.1);
}

.stat-number {
    font-size: 1.25rem;
    font-weight: 700;
    color: #e5e7eb;
    line-height: 1;
    margin-bottom: 2px;
}

.stat-label {
    font-size: 0.75rem;
    color: #94a3b8;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-icon {
    font-size: 16px;
    line-height: 1;
}

.btn-text {
    font-weight: 600;
}

/* ??????????? ????? ??? ?????? ???????? ?????? */
.create-order-btn {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: #e5e7eb;
    border: 1px solid #475569;
    padding: 14px 20px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    min-width: 160px;
    justify-content: center;
}

.create-order-btn:hover {
    background: linear-gradient(135deg, #818cf8 0%, #6366f1 100%);
    border-color: #64748b;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.create-order-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* ???????????? ??? ????????? ????????? */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }
    
    .header h1 {
        font-size: 2rem;
        text-align: center;
    }
    
    .order-stats {
        justify-content: center;
        gap: 12px;
    }
    
    .stat-item {
        min-width: 50px;
        padding: 6px 10px;
    }
    
    .stat-number {
        font-size: 1.1rem;
    }
    
    .stat-label {
        font-size: 0.7rem;
    }

    .header-actions {
        width: 100%;
        flex-direction: column;
    }

    .tables-link-btn,
    .create-order-btn {
        width: 100%;
        justify-content: center;
    }
}

/* ?????????????? ????? ??? ?????????????? ?????? ?? ??????? ?????? */
@media (max-width: 768px) {
    .modal {
        /* ??????????, ??? ????????? ???? ?? ??????? ?? ??????? ?????? */
        max-height: 100vh;
        max-height: 100dvh;
        overflow: hidden;
    }
    
    .modal-content {
        /* ???????????? ???????????? ?????? ???????? */
        max-height: 100vh;
        max-height: 100dvh;
        overflow-y: auto;
    }
    
    .modal-body {
        /* ????????? ??????? ??? ????????? */
        padding-bottom: 20px;
    }
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.tables-link-btn {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: #e5e7eb;
    border: 1px solid #475569;
    padding: 14px 20px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    text-decoration: none;
    justify-content: center;
    min-width: 110px;
}

.tables-link-btn:hover {
    background: linear-gradient(135deg, #818cf8 0%, #6366f1 100%);
    border-color: #64748b;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    color: #e5e7eb;
}

.tables-section {
    margin: 0 0 28px;
    padding: 18px 20px;
    background: rgba(30, 41, 59, 0.45);
    border: 1px solid rgba(71, 85, 105, 0.4);
    border-radius: 14px;
}

.tables-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    gap: 12px;
}

.tables-section-title {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #e5e7eb;
}

.tables-manage-link {
    color: #94a3b8;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
}

.tables-manage-link:hover {
    color: #e5e7eb;
}

.tables-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
    gap: 10px;
}

.table-tile {
    appearance: none;
    border: 1px solid rgba(71, 85, 105, 0.6);
    background: linear-gradient(145deg, #1e293b 0%, #0f172a 100%);
    color: #e5e7eb;
    border-radius: 12px;
    padding: 14px 10px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: 72px;
    transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
    position: relative;
}

.table-tile:hover {
    transform: translateY(-2px);
    border-color: #64748b;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
}

.table-tile:active {
    transform: translateY(0);
}

.table-tile.has-order {
    border-color: rgba(34, 197, 94, 0.55);
    background: linear-gradient(145deg, rgba(34, 197, 94, 0.15) 0%, #0f172a 100%);
}

.table-tile.has-pending {
    border-color: rgba(245, 158, 11, 0.65);
    background: linear-gradient(145deg, rgba(245, 158, 11, 0.18) 0%, #0f172a 100%);
}

.table-tile-number {
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1;
}

.table-tile-name {
    font-size: 0.7rem;
    color: #94a3b8;
    text-align: center;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.table-tile-badge {
    position: absolute;
    top: 6px;
    right: 6px;
    font-size: 0.6rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #86efac;
    background: rgba(34, 197, 94, 0.2);
    padding: 2px 5px;
    border-radius: 4px;
}

.table-tile-badge.pending {
    color: #fff;
    background: #f59e0b;
    text-transform: none;
    font-size: 0.75rem;
    font-weight: 700;
    min-width: 1.35rem;
    height: 1.35rem;
    padding: 0 5px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    letter-spacing: 0;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.45);
}

.table-tile-badge.ready {
    color: #86efac;
    background: rgba(34, 197, 94, 0.25);
    text-transform: none;
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0;
}

@media (max-width: 768px) {
    .tables-section {
        padding: 14px;
    }

    .tables-grid {
        grid-template-columns: repeat(auto-fill, minmax(72px, 1fr));
        gap: 8px;
    }
}


/* === Final palette sync with /tables === */
body {
    font-family: Inter, system-ui, -apple-system, sans-serif !important;
    background: var(--bg) !important;
    color: var(--text) !important;
}

.create-order-btn {
    background: linear-gradient(135deg, var(--accent) 0%, #4f46e5 100%) !important;
    color: #fff !important;
    border: 1px solid var(--accent) !important;
    border-radius: 10px !important;
}

.create-order-btn:hover {
    background: linear-gradient(135deg, var(--accent-hover) 0%, var(--accent) 100%) !important;
    border-color: var(--accent-hover) !important;
}

.tables-link-btn {
    background: var(--surface) !important;
    color: var(--text) !important;
    border: 1px solid var(--border) !important;
}

.tables-link-btn:hover {
    background: var(--border) !important;
    border-color: var(--border-hover) !important;
    color: var(--text) !important;
}

.order-card {
    background: linear-gradient(145deg, var(--surface) 0%, var(--surface-2) 100%) !important;
    border-color: var(--border) !important;
}

.order-card:hover {
    border-color: var(--accent) !important;
}

.order-card:nth-child(even),
.order-card:nth-child(odd) {
    background: linear-gradient(145deg, var(--surface) 0%, var(--surface-2) 100%) !important;
}

.btn-primary,
.select-dish-btn.selected,
.order-all-btn,
.status-btn {
    background: var(--accent) !important;
    border-color: var(--accent) !important;
    color: #fff !important;
}

.btn-primary:hover,
.select-dish-btn.selected:hover {
    background: var(--accent-hover) !important;
    border-color: var(--accent-hover) !important;
}

.form-group input:focus,
.form-group textarea:focus,
.dish-search-input:focus,
#tableNumber:focus {
    border-color: var(--accent) !important;
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.25) !important;
}

.tables-section {
    background: rgba(30, 41, 59, 0.6) !important;
    border-color: var(--border) !important;
}

.table-tile {
    background: linear-gradient(145deg, var(--surface) 0%, var(--surface-2) 100%) !important;
    border-color: var(--border) !important;
}

.table-tile:hover {
    border-color: var(--accent) !important;
}

.table-tile.has-order {
    border-color: rgba(34, 197, 94, 0.55) !important;
    background: linear-gradient(145deg, rgba(34, 197, 94, 0.15) 0%, var(--surface-2) 100%) !important;
}

.table-tile.has-pending {
    border-color: rgba(245, 158, 11, 0.65) !important;
    background: linear-gradient(145deg, rgba(245, 158, 11, 0.18) 0%, var(--surface-2) 100%) !important;
}

.table-tile.has-pending:hover {
    border-color: #f59e0b !important;
}

.dropdown-menu {
    background: var(--surface) !important;
    border-color: var(--border) !important;
}

.dropdown-item:hover {
    background: var(--border) !important;
}

.modal-content {
    background: var(--surface-2) !important;
    border-color: var(--border) !important;
}

/* Table order modal — single window */
.table-order-modal {
    z-index: 1100;
}

.table-order-modal-content {
    max-width: 720px;
    width: 100%;
    max-height: 92vh;
    display: flex;
    flex-direction: column;
}

.table-order-modal .modal-body {
    overflow-y: auto;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.table-section-heading {
    margin: 0 0 12px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text, #e5e7eb);
}

.table-add-section {
    background: rgba(30, 41, 59, 0.55);
    border: 1px solid var(--border, #334155);
    border-radius: 12px;
    padding: 16px;
}

.table-submit-btn {
    width: 100%;
    margin-top: 12px;
    padding: 12px 16px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid var(--accent, #6366f1);
    background: var(--accent, #6366f1);
    color: #fff;
}

.table-submit-btn:hover {
    background: var(--accent-hover, #818cf8);
}

.table-existing-section {
    border-top: 1px solid var(--border, #334155);
    padding-top: 8px;
}

.table-existing-orders .order-card {
    margin-bottom: 12px;
}

.table-existing-orders .order-card:last-child {
    margin-bottom: 0;
}

.table-modal-empty {
    padding: 20px;
    text-align: center;
    color: var(--muted, #94a3b8);
    background: rgba(15, 23, 42, 0.5);
    border: 1px dashed var(--border, #334155);
    border-radius: 10px;
}
