﻿/* 📱 KufeArt Tablet - Dashboard Styles */

/* 🏠 DASHBOARD LAYOUT */

.dashboard-container {
    height: calc(100vh - var(--header-height));
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* 📊 DASHBOARD STATS */
.dashboard-stats {
    padding: var(--space-xl);
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    gap: var(--space-xl);
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md) var(--space-lg);
    background: var(--gray-50);
    border-radius: var(--border-radius-lg);
    border-left: 4px solid var(--primary);
}

    .stat-item.pending {
        border-left-color: var(--warning);
    }

    .stat-item.ready {
        border-left-color: var(--success);
    }

    .stat-item.total {
        border-left-color: var(--info);
    }

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--font-xl);
    color: var(--white);
}

.stat-item.pending .stat-icon {
    background: linear-gradient(135deg, var(--warning), var(--warning-light));
}

.stat-item.ready .stat-icon {
    background: linear-gradient(135deg, var(--success), var(--success-light));
}

.stat-item.total .stat-icon {
    background: linear-gradient(135deg, var(--info), var(--info-light));
}

.stat-info {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.stat-value {
    font-size: var(--font-2xl);
    font-weight: var(--font-bold);
    color: var(--gray-900);
}

.stat-label {
    font-size: var(--font-sm);
    color: var(--gray-600);
    font-weight: var(--font-medium);
}

/* 📋 ORDERS SECTION */
.orders-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.orders-header {
    padding: var(--space-xl);
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.orders-title {
    font-size: var(--font-xl);
    font-weight: var(--font-bold);
    color: var(--gray-900);
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.orders-actions {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.refresh-button {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: var(--white);
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow);
}

    .refresh-button:hover {
        background: linear-gradient(135deg, var(--primary-dark), var(--primary));
        transform: translateY(-2px);
        box-shadow: var(--shadow-lg);
    }

    .refresh-button.loading {
        animation: spin 1s linear infinite;
    }

/* 📱 ORDERS GRID */
.orders-grid {
    flex: 1;
    overflow-y: auto;
    padding: var(--space-xl);
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: var(--space-xl);
    align-content: start;
}

/* 📱 ORDER CARD ENHANCEMENTS */
.order-card {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
    border-left: 4px solid var(--gray-300);
    position: relative;
}

    .order-card.new-order {
        border-left-color: var(--warning);
        animation: newOrderPulse 2s infinite;
    }

        .order-card.new-order::before {
            content: 'YENİ';
            position: absolute;
            top: var(--space-md);
            right: var(--space-md);
            background: var(--warning);
            color: var(--white);
            padding: var(--space-xs) var(--space-sm);
            border-radius: var(--border-radius-sm);
            font-size: var(--font-xs);
            font-weight: var(--font-bold);
            z-index: 10;
        }

@keyframes newOrderPulse {
    0% {
        box-shadow: var(--shadow);
    }

    50% {
        box-shadow: 0 0 20px rgba(243, 156, 18, 0.4);
        transform: translateY(-2px);
    }

    100% {
        box-shadow: var(--shadow);
    }
}

.order-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-3px);
}

/* 🎯 ORDER ACTIONS */
.order-actions {
    padding: var(--space-lg) var(--space-xl);
    background: var(--gray-50);
    border-top: 1px solid var(--gray-200);
    display: flex;
    gap: var(--space-md);
}

.action-button {
    flex: 1;
    background: linear-gradient(135deg, var(--success), var(--success-light));
    color: var(--white);
    border: none;
    border-radius: var(--border-radius);
    padding: var(--space-md) var(--space-lg);
    font-weight: var(--font-semibold);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    min-height: 44px;
}

    .action-button:hover {
        background: linear-gradient(135deg, var(--success-dark), var(--success));
        transform: translateY(-1px);
    }

    .action-button.secondary {
        background: linear-gradient(135deg, var(--gray-400), var(--gray-500));
    }

        .action-button.secondary:hover {
            background: linear-gradient(135deg, var(--gray-500), var(--gray-600));
        }

/* 🔔 NOTIFICATION OVERLAY */
.notification-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

    .notification-overlay.show {
        opacity: 1;
        visibility: visible;
    }

.notification-modal {
    background: var(--white);
    border-radius: var(--border-radius-2xl);
    padding: var(--space-4xl);
    text-align: center;
    max-width: 500px;
    width: 90%;
    box-shadow: var(--shadow-xl);
    transform: scale(0.8);
    transition: var(--transition);
}

.notification-overlay.show .notification-modal {
    transform: scale(1);
}

.notification-modal-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-xl);
    font-size: var(--font-3xl);
    color: var(--white);
    background: linear-gradient(135deg, var(--success), var(--success-light));
}

.notification-modal-title {
    font-size: var(--font-2xl);
    font-weight: var(--font-bold);
    color: var(--gray-900);
    margin-bottom: var(--space-md);
}

.notification-modal-message {
    font-size: var(--font-lg);
    color: var(--gray-600);
    margin-bottom: var(--space-xl);
    line-height: 1.6;
}

/* 📱 RESPONSIVE DASHBOARD */
@media screen and (orientation: portrait) {
    .dashboard-stats {
        padding: var(--space-lg);
        flex-direction: column;
        gap: var(--space-lg);
    }

    .stat-item {
        width: 100%;
        justify-content: center;
        padding: var(--space-lg);
    }

    .orders-grid {
        grid-template-columns: 1fr;
        padding: var(--space-lg);
        gap: var(--space-lg);
    }

    .orders-header {
        padding: var(--space-lg);
        flex-direction: column;
        gap: var(--space-md);
    }

    .orders-actions {
        width: 100%;
        justify-content: center;
    }

    .order-header {
        padding: var(--space-lg);
    }

    .order-body {
        padding: var(--space-lg);
    }

    .order-actions {
        padding: var(--space-lg);
        flex-direction: column;
        gap: var(--space-md);
    }

    .action-button {
        width: 100%;
    }
}

@media screen and (max-width: 480px) {
    .orders-grid {
        grid-template-columns: 1fr;
        padding: var(--space-md);
        gap: var(--space-md);
    }

    .order-card {
        border-radius: var(--border-radius);
    }

    .stat-item {
        padding: var(--space-md);
    }

    .stat-icon {
        width: 40px;
        height: 40px;
        font-size: var(--font-lg);
    }

    .stat-value {
        font-size: var(--font-xl);
    }
}

/* 🌟 SPECIAL ANIMATIONS */
.fade-in-up {
    animation: fadeInUp 0.5s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slide-in-right {
    animation: slideInRight 0.4s ease;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* 🎯 FULLSCREEN MODE */
.fullscreen-mode {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    background: var(--white);
}

    .fullscreen-mode .tablet-header {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 10001;
    }

    .fullscreen-mode .dashboard-container {
        margin-top: var(--header-height);
        height: calc(100vh - var(--header-height));
    }

/* 🔊 SOUND CONTROL */
.sound-control {
    position: fixed;
    bottom: var(--space-xl);
    right: var(--space-xl);
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--font-xl);
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-lg);
    z-index: 1000;
}

    .sound-control:hover {
        background: var(--primary-dark);
        transform: scale(1.1);
    }

    .sound-control.muted {
        background: var(--gray-400);
    }

        .sound-control.muted:hover {
            background: var(--gray-500);
        }

/* 🎵 SOUND INDICATOR */
.sound-indicator {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 20px;
    height: 20px;
    background: var(--success);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--font-xs);
    color: var(--white);
    font-weight: var(--font-bold);
    animation: pulse 1s infinite;
}

    .sound-indicator.muted {
        background: var(--danger);
        animation: none;
    }

/* 🌊 WAVE ANIMATION */
.wave-animation {
    position: relative;
    overflow: hidden;
}

    .wave-animation::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
        animation: wave 2s infinite;
    }

@keyframes wave {
    0% {
        left: -100%;
    }

    100% {
        left: 100%;
    }
}

/* 🔥 HOT ORDER INDICATOR */
.hot-order {
    position: relative;
}

    .hot-order::after {
        content: '🔥';
        position: absolute;
        top: var(--space-sm);
        left: var(--space-sm);
        font-size: var(--font-lg);
        z-index: 10;
        animation: bounce 1s infinite;
    }

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-10px);
    }

    60% {
        transform: translateY(-5px);
    }
}

/* 📊 PROGRESS INDICATOR */
.progress-bar {
    width: 100%;
    height: 4px;
    background: var(--gray-200);
    border-radius: var(--border-radius-sm);
    overflow: hidden;
    margin-top: var(--space-md);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--success), var(--success-light));
    border-radius: var(--border-radius-sm);
    transition: width 0.3s ease;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -100% 0;
    }

    100% {
        background-position: 100% 0;
    }
}

.progress-fill {
    background: linear-gradient(90deg, var(--success), var(--success-light), var(--success), var(--success-light));
    background-size: 200% 100%;
}
/* 📱 KufeArt Tablet - Dashboard Styles (Continuation) */
/* Bu dosya daha önce kesintiye uğramıştı, devamını ekliyoruz */

.tablet-app {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    position: fixed; /* Sayfa scroll'unu engelle */
    top: 0;
    left: 0;
}

/* Dashboard specific styles */
.dashboard-body {
    background: var(--gray-100);
    overflow: hidden;
}

/* Connection status indicator */
.connection-status {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--border-radius-sm);
    font-size: var(--font-xs);
    font-weight: var(--font-medium);
}

    .connection-status.connected {
        background: var(--success-light);
        color: var(--success-dark);
    }

    .connection-status.disconnected {
        background: var(--danger-light);
        color: var(--danger-dark);
    }

/* Tablet header adjustments */
.tablet-header {
    flex-shrink: 0;
}


/* Stats section */
.dashboard-stats {
    flex-shrink: 0;
    padding: var(--space-lg);
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    gap: var(--space-lg);
    overflow-x: auto;
}

/* Orders section */
.orders-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.orders-header {
    flex-shrink: 0;
    padding: var(--space-lg);
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
}

.orders-grid {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: var(--space-lg);
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: var(--space-lg);
    align-content: start;
    /* Smooth scroll ekle */
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch; /* iOS için smooth scroll */
}

/* Empty state */
.empty-state {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-4xl);
    text-align: center;
}

/* Responsive adjustments */
@media screen and (orientation: portrait) {
    .orders-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-stats {
        flex-direction: column;
        gap: var(--space-md);
    }
}

/* 📱 Tablet Scroll Düzeltmeleri */

/* Ana container'larda scroll'u düzelt */
.tablet-app {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    position: fixed; /* Sayfa scroll'unu engelle */
    top: 0;
    left: 0;
}

.dashboard-container {
    height: calc(100vh - var(--header-height));
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Orders grid'de scroll'u aktif et */
.orders-grid {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: var(--space-lg);
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: var(--space-lg);
    align-content: start;
    /* Smooth scroll ekle */
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch; /* iOS için smooth scroll */
}

    /* Tablet modunda scroll bar'ı gizle ama scroll'u koru */
    .orders-grid::-webkit-scrollbar {
        width: 8px;
    }

    .orders-grid::-webkit-scrollbar-track {
        background: var(--gray-100);
    }

    .orders-grid::-webkit-scrollbar-thumb {
        background: var(--gray-400);
        border-radius: 4px;
    }

        .orders-grid::-webkit-scrollbar-thumb:hover {
            background: var(--gray-500);
        }

/* Order card'lar daha detaylı görünsün */
.order-card {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow);
    overflow: visible; /* İçeriğin görünmesi için */
    transition: var(--transition);
    border-left: 4px solid var(--gray-300);
    min-height: 250px; /* Minimum yükseklik */
    display: flex;
    flex-direction: column;
}

/* Order body'nin scroll olması */
.order-body {
    flex: 1;
    padding: var(--space-lg);
    overflow-y: auto;
    max-height: 300px; /* Maksimum yükseklik */
}

/* Portrait modda daha iyi görünüm */
@media screen and (orientation: portrait) {
    .orders-grid {
        grid-template-columns: 1fr;
        padding: var(--space-md);
        gap: var(--space-md);
    }

    .order-card {
        min-height: 200px;
    }

    .order-body {
        max-height: 250px;
    }
}

/* Tablet fullscreen modda iyileştirmeler */
body:fullscreen,
body:-webkit-full-screen,
body:-moz-full-screen {
    overflow: hidden;
}

    body:fullscreen .tablet-app,
    body:-webkit-full-screen .tablet-app,
    body:-moz-full-screen .tablet-app {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        z-index: 9999;
    }

/* 🃏 ORDER CARD - Yükseklik artırımı */
.order-card {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
    border-left: 4px solid var(--gray-300);
    min-height: 350px; /* 250px'den 350px'e çıkardık */
    max-height: 500px; /* Maksimum yükseklik */
    display: flex;
    flex-direction: column;
}

/* Order body - 3 ürün için optimize */
.order-body {
    flex: 1;
    padding: var(--space-lg);
    overflow-y: auto;
    min-height: 200px; /* Minimum yükseklik artırıldı */
    max-height: 300px; /* 3 ürün için yeterli alan */
}

/* Order items container */
.order-items {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    min-height: 150px; /* 3 ürün için minimum alan */
}

/* Her bir order item */
.order-item {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md);
    background: var(--gray-50);
    border-radius: var(--border-radius);
    transition: var(--transition);
    min-height: 60px; /* Her item için minimum yükseklik */
}

    .order-item:hover {
        background: var(--gray-100);
    }

/* Item quantity badge */
.item-quantity {
    background: var(--primary);
    color: var(--white);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: var(--font-bold);
    font-size: var(--font-md);
    flex-shrink: 0;
}

/* Item info */
.item-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.item-name {
    font-weight: var(--font-semibold);
    color: var(--gray-900);
    font-size: var(--font-md);
    line-height: 1.3;
}

.item-description {
    font-size: var(--font-sm);
    color: var(--gray-600);
    line-height: 1.4;
}

/* 3'ten fazla item varsa scroll indicator */
.items-overflow {
    border-top: 1px solid var(--gray-200);
    padding-top: var(--space-md);
    margin-top: var(--space-md);
    text-align: center;
}

.btn-more-items {
    background: var(--gray-100);
    border: 1px solid var(--gray-300);
    border-radius: var(--border-radius);
    padding: var(--space-sm) var(--space-md);
    font-size: var(--font-sm);
    color: var(--gray-600);
    cursor: pointer;
    transition: var(--transition);
}

    .btn-more-items:hover {
        background: var(--gray-200);
        color: var(--gray-800);
    }

/* Grid responsive ayarları */
.orders-grid {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: var(--space-lg);
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); /* Genişlik artırıldı */
    gap: var(--space-xl);
    align-content: start;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

/* Portrait mode optimizasyonları */
@media screen and (orientation: portrait) {
    .orders-grid {
        grid-template-columns: 1fr;
        padding: var(--space-md);
        gap: var(--space-lg);
    }

    .order-card {
        min-height: 320px; /* Portrait'te biraz daha küçük */
        max-height: 450px;
    }

    .order-body {
        min-height: 180px;
        max-height: 280px;
    }

    .order-items {
        min-height: 120px;
    }
}

/* Küçük ekranlar için */
@media screen and (max-width: 480px) {
    .order-card {
        min-height: 280px;
        max-height: 400px;
    }

    .order-body {
        min-height: 150px;
        max-height: 250px;
    }

    .item-quantity {
        width: 32px;
        height: 32px;
        font-size: var(--font-sm);
    }

    .item-name {
        font-size: var(--font-sm);
    }

    .item-description {
        font-size: var(--font-xs);
    }
}

/* Scroll bar styling for order body */
.order-body::-webkit-scrollbar {
    width: 6px;
}

.order-body::-webkit-scrollbar-track {
    background: var(--gray-100);
    border-radius: 3px;
}

.order-body::-webkit-scrollbar-thumb {
    background: var(--gray-300);
    border-radius: 3px;
}

    .order-body::-webkit-scrollbar-thumb:hover {
        background: var(--gray-400);
    }

/* Empty state adjustments */
.empty-state {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-4xl);
    text-align: center;
    min-height: 400px; /* Empty state için de yükseklik artırıldı */
}
/* 📱 PORTRAIT MODE İYİLEŞTİRMELERİ */
@media screen and (orientation: portrait) {
    /* Orders grid - Dikey modda tek sütun */
    .orders-grid {
        grid-template-columns: 1fr;
        padding: var(--space-md);
        gap: var(--space-md);
        /* Grid container'ın padding'ini azalt */
    }

    /* Order card - Dikey modda daha kompakt */
    .order-card {
        min-height: 280px; /* 350px'den 280px'e düşür */
        max-height: 400px; /* Maksimumu da düşür */
        display: flex;
        flex-direction: column;
        margin-bottom: var(--space-md); /* Card'lar arası boşluk */
    }

    /* Order header - Daha kompakt */
    .order-header {
        padding: var(--space-md); /* space-lg'den space-md'ye */
        flex-shrink: 0; /* Header'ın küçülmesini engelle */
    }

    /* Order body - Dikey modda scroll alanını optimize et */
    .order-body {
        flex: 1;
        padding: var(--space-md); /* space-lg'den space-md'ye */
        overflow-y: auto;
        min-height: 120px; /* Minimum yüksekliği düşür */
        max-height: 200px; /* Maksimumu da düşür */
    }

    /* Order actions - Mutlaka görünsün */
    .order-actions {
        padding: var(--space-md); /* space-lg'den space-md'ye */
        background: var(--gray-50);
        border-top: 1px solid var(--gray-200);
        flex-shrink: 0; /* Action'ların kaybolmasını engelle */
        margin-top: auto; /* Alt'a yapıştır */
    }

    /* Action button - Dikey modda daha büyük */
    .action-button {
        width: 100%;
        min-height: 48px; /* Touch için minimum yükseklik */
        font-size: var(--font-md);
        font-weight: var(--font-semibold);
    }

    /* Order items - Dikey modda daha kompakt */
    .order-items {
        gap: var(--space-sm); /* space-md'den space-sm'ye */
        min-height: 80px; /* Minimum yüksekliği düşür */
    }

    /* Order item - Daha küçük */
    .order-item {
        padding: var(--space-sm) var(--space-md); /* Padding'i küçült */
        min-height: 50px; /* 60px'den 50px'e */
    }

    /* Item quantity - Daha küçük */
    .item-quantity {
        width: 32px;
        height: 32px;
        font-size: var(--font-sm);
    }

    /* Note - Dikey modda daha kompakt */
    .order-note {
        padding: var(--space-sm) var(--space-md); /* Padding'i küçült */
        margin-bottom: var(--space-md);
        font-size: var(--font-sm);
    }
}

/* 📱 Küçük tablet'ler için ekstra optimizasyon */
@media screen and (orientation: portrait) and (max-height: 800px) {
    .order-card {
        min-height: 240px; /* Daha da küçük */
        max-height: 350px;
    }

    .order-body {
        min-height: 100px;
        max-height: 160px;
    }

    .order-header {
        padding: var(--space-sm) var(--space-md);
    }

    .order-actions {
        padding: var(--space-sm) var(--space-md);
    }
}

/* 📱 Çok küçük tabletler için */
@media screen and (orientation: portrait) and (max-height: 700px) {
    .order-card {
        min-height: 200px;
        max-height: 300px;
    }

    .order-body {
        min-height: 80px;
        max-height: 140px;
    }

    .order-header,
    .order-actions {
        padding: var(--space-sm);
    }

    .action-button {
        min-height: 44px;
        font-size: var(--font-sm);
    }
}

/* 🔧 Fade-in-up animasyonunu iyileştir */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px); /* 30px'den 20px'e düşür */
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.4s ease-out; /* 0.5s'den 0.4s'ye */
}
/* 📱 PORTRAIT MODE TAMAMEN YENİDEN */
@media screen and (orientation: portrait) {
    /* Container'ı optimize et */
    .dashboard-container {
        height: calc(100vh - var(--header-height));
        overflow: hidden;
    }

    /* Orders section - Flex yapısını düzelt */
    .orders-section {
        flex: 1;
        display: flex;
        flex-direction: column;
        min-height: 0;
    }

    /* Orders header - Daha kompakt */
    .orders-header {
        padding: var(--space-md);
        flex-shrink: 0;
        background: var(--white);
        border-bottom: 1px solid var(--gray-200);
    }

    /* Orders grid - Portrait için optimize */
    .orders-grid {
        flex: 1;
        overflow-y: auto;
        padding: var(--space-md);
        display: flex;
        flex-direction: column;
        gap: var(--space-md);
        align-content: flex-start;
    }

    /* Order card - BOYUT OPTİMİZASYONU */
    .order-card {
        width: 100%;
        min-height: 220px; /* Daha küçük minimum */
        max-height: none; /* Maksimum sınırını kaldır */
        height: auto; /* Otomatik yükseklik */
        display: flex;
        flex-direction: column;
        flex-shrink: 0; /* Küçülmeyi engelle */
        margin-bottom: 0; /* Grid gap kullan */
    }

    /* Order header - Kompakt */
    .order-header {
        padding: var(--space-sm) var(--space-md);
        flex-shrink: 0;
        background: var(--gray-50);
        border-bottom: 1px solid var(--gray-200);
    }

    /* Order body - Esnek yükseklik */
    .order-body {
        flex: 1;
        padding: var(--space-md);
        overflow-y: auto;
        max-height: 140px; /* Sabit maksimum */
        min-height: 80px;
    }

    /* Order actions - HER ZAMAN GÖRÜNÜR */
    .order-actions {
        padding: var(--space-md);
        background: var(--gray-50);
        border-top: 1px solid var(--gray-200);
        flex-shrink: 0; /* ASLA küçülmesin */
        margin-top: 0;
    }

    /* Action button - Touch friendly */
    .action-button {
        width: 100%;
        min-height: 44px;
        font-size: var(--font-md);
        font-weight: var(--font-semibold);
        padding: var(--space-md);
    }
}
/* ✅ TAMAMLANAN SİPARİŞ STİLLERİ */
.order-card.order-completed {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%) !important;
    border-left-color: #28a745 !important;
    opacity: 0.8;
    border: 2px solid #28a745;
}

.completed-badge {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.completion-timer {
    background: #6c757d;
    color: white;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 4px;
}

.order-completed .order-header {
    opacity: 0.7;
}

.order-completed .order-body {
    opacity: 0.7;
}
/* ✅ MODAL STİLLERİ */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

    .modal-overlay.show {
        opacity: 1;
    }

.modal-container {
    background: white;
    border-radius: 16px;
    max-width: 90vw;
    max-height: 90vh;
    width: 600px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    overflow: hidden;
}

.modal-overlay.show .modal-container {
    transform: scale(1);
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
}

.modal-body {
    padding: 24px;
    max-height: 60vh;
    overflow-y: auto;
}

.modal-footer {
    padding: 20px 24px;
    border-top: 1px solid #eee;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    background: #f8f9fa;
}

.modal-close {
    background: #e9ecef;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s;
}

    .modal-close:hover {
        background: #dee2e6;
    }
/* ✅ MODAL STİLLERİ - GÜZELLEŞTİRİLMİŞ VERSİYON */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

    .modal-overlay.show {
        opacity: 1;
    }

.modal-container {
    background: white;
    border-radius: 20px;
    max-width: 95vw;
    max-height: 90vh;
    width: 700px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4);
    transform: scale(0.8) translateY(20px);
    transition: all 0.3s ease;
    overflow: hidden;
    position: relative;
}

.modal-overlay.show .modal-container {
    transform: scale(1) translateY(0);
}

.modal-header {
    padding: 24px 28px 20px;
    border-bottom: 2px solid #eef2f7;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

    .modal-header h3 {
        margin: 0;
        color: #2c3e50;
        font-size: 1.4rem;
        font-weight: 600;
        display: flex;
        align-items: center;
        gap: 10px;
    }

        .modal-header h3::before {
            content: "📋";
            font-size: 1.2rem;
        }

.modal-close {
    background: #ff4757;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    color: white;
    font-size: 1.1rem;
}

    .modal-close:hover {
        background: #ff3742;
        transform: scale(1.1);
    }

.modal-body {
    padding: 28px;
    max-height: 60vh;
    overflow-y: auto;
    background: #fafbfc;
}

/* Modal İçerik Stilleri */
.modal-section {
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid #e9ecef;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.modal-section-title {
    color: #2c3e50;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.info-item {
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    font-size: 0.95rem;
}

    .info-item strong {
        color: #2c3e50;
    }

.modal-items-grid {
    display: grid;
    gap: 12px;
}

.modal-item {
    display: flex;
    align-items: center;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 10px;
    border-left: 4px solid #3742fa;
}

.modal-item-quantity {
    background: #3742fa;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    margin-right: 12px;
}

.modal-item-info {
    flex: 1;
}

.modal-item-name {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 4px;
}

.modal-item-description {
    color: #7f8c8d;
    font-size: 0.9rem;
}

.modal-footer {
    padding: 20px 28px;
    border-top: 2px solid #eef2f7;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.2s;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
}

.btn-outline {
    background: #6c757d;
    color: white;
}

    .btn-outline:hover {
        background: #5a6268;
        transform: translateY(-1px);
    }

.btn-success {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
}

    .btn-success:hover {
        background: linear-gradient(135deg, #218838, #1e9b83);
        transform: translateY(-1px);
    }

/* Tamamlanan Buton Stili */
.completed-button {
    background: #6c757d !important;
    cursor: not-allowed !important;
    opacity: 0.7;
}

.completed-badge {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.completion-timer {
    background: #6c757d;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Responsive */
@media (max-width: 768px) {
    .modal-container {
        width: 95vw;
        margin: 20px;
    }

    .info-grid {
        grid-template-columns: 1fr;
    }

    .modal-header, .modal-body, .modal-footer {
        padding: 20px;
    }
}

/* ✅ TAMAMLANAN SİPARİŞ STİLLERİ */
.order-card.order-completed {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%) !important;
    border-left-color: #28a745 !important;
    opacity: 0.8;
    border: 2px solid #28a745;
}

.completed-badge {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.completion-timer {
    background: #6c757d;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 4px;
}

.completed-button {
    background: #6c757d !important;
    cursor: not-allowed !important;
    opacity: 0.7 !important;
    color: white !important;
}

    .completed-button:disabled {
        background: #6c757d !important;
        cursor: not-allowed !important;
    }

.order-completed .order-header {
    opacity: 0.7;
}

.order-completed .order-body {
    opacity: 0.7;
}