        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            background: linear-gradient(135deg, #8B2635 0%, #C1374D 50%, #6B1B29 100%);
            min-height: 100vh;
            padding: clamp(10px, 3vw, 20px);
            position: relative;
        }

        body::before {
            content: '';
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: radial-gradient(circle at 20% 50%, rgba(193, 55, 77, 0.3) 0%, transparent 50%),
                        radial-gradient(circle at 80% 80%, rgba(139, 38, 53, 0.3) 0%, transparent 50%);
            pointer-events: none;
            z-index: 0;
        }

        /* Login Screen Styles */
        #loginScreen {
            display: flex;
            justify-content: center;
            align-items: center;
            min-height: 100vh;
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            z-index: 9999;
            background: linear-gradient(135deg, #8B2635 0%, #C1374D 50%, #6B1B29 100%);
        }

        .login-box {
            background: white;
            padding: 40px;
            border-radius: 20px;
            box-shadow: 0 10px 40px rgba(0,0,0,0.3);
            max-width: 400px;
            width: 90%;
            animation: slideIn 0.5s ease;
        }

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

        .login-box h2 {
            text-align: center;
            color: #8B2635;
            margin-bottom: 10px;
            font-size: 28px;
        }

        .login-box p {
            text-align: center;
            color: #666;
            margin-bottom: 30px;
            font-size: 14px;
        }

        .login-box input {
            width: 100%;
            padding: 15px;
            border: 2px solid #e0e0e0;
            border-radius: 10px;
            font-size: 16px;
            margin-bottom: 20px;
            transition: all 0.3s ease;
        }

        .login-box input:focus {
            outline: none;
            border-color: #C1374D;
            box-shadow: 0 0 0 3px rgba(193, 55, 77, 0.1);
        }

        .login-box button {
            width: 100%;
            padding: 15px;
            background: linear-gradient(135deg, #8B2635 0%, #C1374D 100%);
            color: white;
            border: none;
            border-radius: 10px;
            font-size: 16px;
            font-weight: bold;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .login-box button:hover {
            background: linear-gradient(135deg, #6B1B29 0%, #A12D3E 100%);
            transform: translateY(-2px);
            box-shadow: 0 6px 20px rgba(139, 38, 53, 0.4);
        }

        .error-msg {
            color: #dc3545;
            text-align: center;
            margin-top: 15px;
            display: none;
            font-weight: 600;
            animation: shake 0.5s;
        }

        @keyframes shake {
            0%, 100% { transform: translateX(0); }
            25% { transform: translateX(-10px); }
            75% { transform: translateX(10px); }
        }

        .container {
            max-width: 1900px;
            margin: 0 auto;
            position: relative;
            z-index: 1;
            display: none;
        }

        .header {
            background: linear-gradient(135deg, rgba(112, 74, 80, 0.95) 0%, #8B2635 100%);
            backdrop-filter: blur(10px);
            border-radius: clamp(10px, 2vw, 16px);
            padding: clamp(10px, 2vw, 16px) clamp(15px, 3vw, 25px);
            margin-bottom: clamp(10px, 2vw, 18px);
            box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
            border: 1px solid rgba(255, 255, 255, 0.1);
            display: flex;
            justify-content: space-between;
            align-items: center;
            flex-wrap: wrap;
            gap: 10px;
        }

        .header-content { flex: 1; }

        .brand-logo {
            display: block;
            max-width: clamp(80px, 14vw, 120px);
            margin: 0 auto 6px;
            border-radius: 10px;
        }

        .header h1 {
            color: white;
            font-size: clamp(1em, 2.6vw, 1.6em);
            margin-bottom: 6px;
            text-align: center;
            line-height: 1.3;
        }

        .header-side-actions {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 8px;
        }

        .current-user-label {
            color: white;
            font-weight: 600;
            font-size: 0.85em;
            background: rgba(255,255,255,0.15);
            padding: 4px 12px;
            border-radius: 20px;
        }

        .logout-btn {
            padding: 8px 16px;
            background: rgba(255, 255, 255, 0.2);
            color: white;
            border: 2px solid white;
            border-radius: 10px;
            cursor: pointer;
            font-weight: 600;
            transition: all 0.3s ease;
            white-space: nowrap;
            font-size: 0.9em;
        }

        .logout-btn:hover { background: white; color: #8B2635; }

        .auto-refresh-indicator {
            background: rgba(40, 167, 69, 0.9);
            color: white;
            padding: clamp(4px, 1vw, 6px) clamp(10px, 2vw, 12px);
            border-radius: 25px;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            font-size: clamp(0.7em, 1.6vw, 0.8em);
            margin: 6px auto 0;
            width: fit-content;
        }

        .refresh-dot {
            width: 8px;
            height: 8px;
            background: white;
            border-radius: 50%;
            animation: pulse 1s infinite;
        }

        @keyframes pulse {
            0%, 100% { opacity: 1; transform: scale(1); }
            50% { opacity: 0.5; transform: scale(0.8); }
        }

        .new-data-notification {
            position: fixed;
            top: 20px;
            left: 50%;
            transform: translateX(-50%) translateY(-100px);
            background: linear-gradient(135deg, #28a745, #20c997);
            color: white;
            padding: clamp(10px, 2vw, 15px) clamp(20px, 4vw, 30px);
            border-radius: 50px;
            font-size: clamp(0.9em, 2vw, 1.1em);
            font-weight: bold;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
            z-index: 10000;
            transition: transform 0.5s ease;
            display: none;
        }

        .new-data-notification.show {
            display: block;
            transform: translateX(-50%) translateY(0);
        }

        .confirmation-notification {
            position: fixed;
            top: 20px;
            left: 50%;
            transform: translateX(-50%) translateY(-100px);
            background: linear-gradient(135deg, #1e88e5, #00acc1);
            color: white;
            padding: clamp(10px, 2vw, 15px) clamp(20px, 4vw, 30px);
            border-radius: 50px;
            font-size: clamp(0.9em, 2vw, 1.1em);
            font-weight: bold;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
            z-index: 10000;
            transition: transform 0.5s ease;
            display: none;
        }

        .confirmation-notification.show {
            display: block;
            transform: translateX(-50%) translateY(0);
        }

        .stats {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
            gap: clamp(10px, 2vw, 20px);
            margin-bottom: clamp(15px, 3vw, 30px);
        }

        @media (max-width: 768px) { .stats { grid-template-columns: repeat(2, 1fr); } }
        @media (max-width: 480px) { .stats { grid-template-columns: 1fr; } }

        .stat-card {
            background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.95) 100%);
            border-radius: clamp(12px, 3vw, 20px);
            padding: clamp(15px, 4vw, 30px);
            text-align: center;
            box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
            transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
            border: 2px solid transparent;
            position: relative;
            overflow: hidden;
            cursor: pointer;
        }

        .stat-card::before {
            content: '';
            position: absolute;
            top: 0; left: 0; right: 0;
            height: 4px;
            background: linear-gradient(90deg, #8B2635 0%, #C1374D 50%, #8B2635 100%);
            transform: scaleX(0);
            transition: transform 0.4s ease;
        }

        .stat-card:hover::before { transform: scaleX(1); }

        .stat-card:hover {
            transform: translateY(-5px) scale(1.02);
            box-shadow: 0 15px 40px rgba(139, 38, 53, 0.3);
            border-color: #C1374D;
        }

        .stat-card.active-filter { border-color: #C1374D; box-shadow: 0 10px 30px rgba(139, 38, 53, 0.35); }

        .stat-number {
            font-size: clamp(1.8em, 5vw, 3em);
            font-weight: bold;
            margin-bottom: 8px;
        }

        .stat-label {
            font-size: clamp(0.85em, 2vw, 1.1em);
            color: #666;
            line-height: 1.3;
        }

        .filters {
            background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.95) 100%);
            border-radius: clamp(12px, 3vw, 20px);
            padding: clamp(15px, 3vw, 25px);
            margin-bottom: clamp(10px, 2vw, 20px);
            box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
            border: 1px solid rgba(193, 55, 77, 0.1);
        }

        .filters-row {
            display: flex;
            gap: clamp(10px, 2vw, 15px);
            flex-wrap: wrap;
            align-items: center;
            margin-bottom: clamp(10px, 2vw, 15px);
        }

        .filters-row:last-child { margin-bottom: 0; }

        .filter-group {
            display: flex;
            align-items: center;
            gap: clamp(5px, 1.5vw, 10px);
            flex-wrap: wrap;
        }

        .filter-group label {
            font-weight: 600;
            color: #333;
            font-size: clamp(0.85em, 2vw, 1em);
            white-space: nowrap;
        }

        input[type="text"], select, input[type="date"] {
            padding: clamp(8px, 2vw, 12px) clamp(12px, 3vw, 18px);
            border: 2px solid #e0e0e0;
            border-radius: clamp(8px, 2vw, 12px);
            font-size: clamp(0.85em, 2vw, 1em);
            transition: all 0.3s ease;
            background: white;
            min-width: 150px;
            font-family: inherit;
        }

        @media (max-width: 480px) {
            input[type="text"], select, input[type="date"] { width: 100%; min-width: unset; }
            .filter-group { width: 100%; }
        }

        input[type="text"]:focus, select:focus, input[type="date"]:focus {
            outline: none;
            border-color: #C1374D;
            box-shadow: 0 0 0 3px rgba(193, 55, 77, 0.1);
            transform: translateY(-1px);
        }

        .btn {
            padding: clamp(8px, 2vw, 12px) clamp(15px, 3vw, 24px);
            border: none;
            border-radius: clamp(8px, 2vw, 12px);
            font-size: clamp(0.85em, 2vw, 1em);
            cursor: pointer;
            transition: all 0.3s ease;
            font-weight: 600;
            position: relative;
            overflow: hidden;
            white-space: nowrap;
        }

        @media (max-width: 480px) { .btn { width: 100%; } }

        .btn::before {
            content: '';
            position: absolute;
            top: 50%; left: 50%;
            width: 0; height: 0;
            border-radius: 50%;
            background: rgba(255, 255, 255, 0.3);
            transform: translate(-50%, -50%);
            transition: width 0.6s, height 0.6s;
        }

        .btn:hover::before { width: 300px; height: 300px; }

        .btn-primary {
            background: linear-gradient(135deg, #8B2635 0%, #8B2635 100%);
            color: white;
            box-shadow: 0 4px 15px rgba(139, 38, 53, 0.4);
        }

        .btn-primary:hover {
            background: linear-gradient(135deg, #6B1B29 0%, #A12D3E 100%);
            transform: translateY(-2px);
            box-shadow: 0 6px 25px rgba(139, 38, 53, 0.5);
        }

        .btn-print-all {
            background: linear-gradient(135deg, #8B2635 0%, #8B2635 100%);
            color: white;
            box-shadow: 0 4px 15px rgba(161, 45, 62, 0.4);
        }

        .btn-print-all:hover {
            transform: translateY(-2px);
            box-shadow: 0 6px 25px rgba(161, 45, 62, 0.5);
        }

        .btn-print-all:disabled { background: #ccc; cursor: not-allowed; opacity: 0.5; }

        .table-container {
            background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.95) 100%);
            border-radius: clamp(12px, 3vw, 20px);
            padding: clamp(15px, 3vw, 25px);
            overflow: auto;
            max-height: 68vh;
            box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
            border: 1px solid rgba(193, 55, 77, 0.1);
        }

        .sticky-scrollbar {
            position: fixed;
            left: 0;
            right: 0;
            bottom: 0;
            height: 16px;
            overflow-x: auto;
            overflow-y: hidden;
            background: rgba(139, 38, 53, 0.15);
            border-top: 1px solid rgba(139, 38, 53, 0.3);
            z-index: 500;
            display: none;
        }

        .sticky-scrollbar.show { display: block; }

        .sticky-scrollbar-inner { height: 1px; }

        .sticky-scrollbar::-webkit-scrollbar { height: 14px; }
        .sticky-scrollbar::-webkit-scrollbar-thumb {
            background: linear-gradient(135deg, #8B2635 0%, #C1374D 100%);
            border-radius: 10px;
        }
        .sticky-scrollbar::-webkit-scrollbar-track { background: rgba(255,255,255,0.4); }

        table { width: 100%; border-collapse: collapse; }
        #dataTable { min-width: 2200px; }

        @media (max-width: 768px) { #dataTable { min-width: 1800px; } }

        thead { background: linear-gradient(135deg, #8B2635 0%, #8B2635 100%); color: white; }

        th, td {
            padding: clamp(10px, 2vw, 14px);
            text-align: right;
            border-bottom: 1px solid #ddd;
            font-size: clamp(0.78em, 1.8vw, 0.95em);
            vertical-align: top;
        }

        th {
            font-weight: 600;
            font-size: clamp(0.82em, 2vw, 1em);
            position: sticky;
            top: 0;
            background: linear-gradient(135deg, #8B2635 0%, #8B2635 100%);
            z-index: 10;
        }

        tbody tr { transition: background 0.3s; }
        tbody tr:hover { background: linear-gradient(90deg, rgba(193, 55, 77, 0.05) 0%, rgba(193, 55, 77, 0.1) 50%, rgba(193, 55, 77, 0.05) 100%); }
        tbody tr.new-row { animation: highlightNew 2s ease; }

        @keyframes highlightNew {
            0% { background: #d4edda; }
            100% { background: transparent; }
        }

        .badge {
            display: inline-block;
            padding: 4px 10px;
            border-radius: 20px;
            font-size: 0.78em;
            font-weight: 700;
            white-space: nowrap;
        }

        .badge-pending { background: #fff3cd; color: #856404; }
        .badge-confirm { background: #d4edda; color: #155724; }
        .badge-cancel { background: #f8d7da; color: #721c24; }
        .badge-waiting { background: #e2e3e5; color: #383d41; }
        .badge-printed { background: #d1ecf1; color: #0c5460; }
        .badge-hold { background: #fff3cd; color: #856404; }
        .badge-canceled { background: #f8d7da; color: #721c24; }
        .badge-sent-yes { background: #d4edda; color: #155724; }
        .badge-sent-no { background: #e2e3e5; color: #383d41; }
        .badge-neutral { background: #e2e3e5; color: #383d41; }

        .responsible-name { display: block; font-size: 0.82em; color: #555; margin-top: 4px; }

        .action-buttons {
            display: flex;
            gap: clamp(5px, 1.5vw, 8px);
            flex-wrap: wrap;
        }

        .btn-action {
            padding: clamp(6px, 1.5vw, 8px) clamp(10px, 2vw, 14px);
            border: none;
            border-radius: clamp(4px, 1vw, 6px);
            cursor: pointer;
            font-size: clamp(0.75em, 1.8vw, 0.85em);
            transition: all 0.3s;
            white-space: nowrap;
            font-weight: 600;
        }

        .btn-edit { background: #17a2b8; color: white; box-shadow: 0 3px 12px rgba(23,162,184,0.4); }
        .btn-edit:hover { background: #117a8b; transform: translateY(-2px); }

        .btn-print { background: #8B2635; color: white; box-shadow: 0 3px 12px rgba(139, 38, 53, 0.4); }
        .btn-print:hover { background: #6B1B29; box-shadow: 0 5px 20px rgba(139, 38, 53, 0.5); transform: translateY(-2px); }

        .btn-delete { background: #dc3545; color: white; box-shadow: 0 3px 12px rgba(220, 53, 69, 0.4); }
        .btn-delete:hover { background: #a71d2a; box-shadow: 0 5px 20px rgba(220, 53, 69, 0.5); transform: translateY(-2px); }

        .loading { text-align: center; padding: clamp(30px, 5vw, 50px); font-size: clamp(1.2em, 3vw, 1.5em); color: white; }
        .no-data { text-align: center; padding: clamp(20px, 4vw, 30px); color: #666; font-size: clamp(1em, 2.5vw, 1.2em); }

        .pagination {
            display: flex;
            justify-content: center;
            align-items: center;
            gap: clamp(5px, 1.5vw, 10px);
            margin-top: clamp(10px, 2vw, 20px);
            padding: clamp(10px, 2vw, 20px);
            flex-wrap: wrap;
        }

        .pagination button {
            padding: clamp(8px, 2vw, 12px) clamp(12px, 3vw, 20px);
            border: none;
            border-radius: clamp(8px, 2vw, 12px);
            background: linear-gradient(135deg, #8B2635 0%, #C1374D 100%);
            color: white;
            cursor: pointer;
            transition: all 0.3s ease;
            font-weight: 600;
            box-shadow: 0 4px 15px rgba(139, 38, 53, 0.4);
            font-size: clamp(0.8em, 2vw, 1em);
        }

        .pagination button:hover:not(:disabled) {
            background: linear-gradient(135deg, #6B1B29 0%, #A12D3E 100%);
            transform: translateY(-2px);
            box-shadow: 0 6px 25px rgba(139, 38, 53, 0.5);
        }

        .pagination button:disabled { background: #ccc; cursor: not-allowed; opacity: 0.5; }

        .pagination .page-info {
            padding: clamp(8px, 2vw, 12px) clamp(15px, 3vw, 24px);
            background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.95) 100%);
            border-radius: clamp(8px, 2vw, 12px);
            font-weight: 600;
            color: #8B2635;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
            border: 2px solid rgba(193, 55, 77, 0.2);
            font-size: clamp(0.85em, 2vw, 1em);
        }

        .pagination select {
            padding: clamp(8px, 2vw, 12px) clamp(10px, 2vw, 16px);
            border: 2px solid #C1374D;
            border-radius: clamp(8px, 2vw, 12px);
            background: white;
            color: #8B2635;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.3s ease;
            font-size: clamp(0.8em, 2vw, 1em);
        }

        .pagination select:hover { border-color: #8B2635; box-shadow: 0 4px 15px rgba(139, 38, 53, 0.2); }

        .order-id-badge {
            background: linear-gradient(135deg, #8B2635 0%, #C1374D 100%);
            color: white;
            padding: clamp(4px, 1vw, 6px) clamp(10px, 2vw, 14px);
            border-radius: clamp(15px, 3vw, 20px);
            font-size: clamp(0.75em, 1.8vw, 0.85em);
            font-weight: 700;
            display: inline-block;
            box-shadow: 0 3px 12px rgba(139, 38, 53, 0.4);
            letter-spacing: 0.5px;
        }

        .no-print { display: block; }

        .print-separator {
            margin: 0;
            padding: 5px 0;
            border-top: 2px dashed #000;
            text-align: center;
            font-size: 14px;
            font-weight: bold;
            page-break-inside: avoid;
        }

        @media print {
            @page { size: 80mm auto; margin: 0; }
            * { visibility: hidden; }
            body { margin: 0; padding: 0; background: white; }
            .no-print, .no-print * { display: none !important; visibility: hidden !important; }
            #printArea, #printArea * { visibility: visible !important; }
            #printArea { display: block !important; position: absolute !important; left: 0 !important; top: 0 !important; width: 80mm !important; margin: 0 !important; padding: 0 !important; }
            .print-separator { display: block; page-break-inside: avoid; visibility: visible !important; }
            .print-content { page-break-inside: avoid; visibility: visible !important; }
        }

        #printArea { display: none; }

        .print-content {
            width: 75mm;
            padding: 2.5mm;
            font-family: 'Courier New', monospace;
            font-size: 13px;
            line-height: 1.6;
            background: white;
            color: black;
        }

        .print-header { text-align: center; margin-bottom: 12px; border-bottom: 2px dashed #000; padding-bottom: 10px; }
        .print-header h2 { font-size: 20px; margin: 5px 0; font-weight: bold; }
        .print-header p { font-size: 12px; margin: 3px 0; }

        .print-barcode {
            text-align: center;
            margin: 12px 0;
            font-size: 22px;
            font-weight: bold;
            letter-spacing: 2px;
            padding: 8px;
            border: 2px solid #000;
        }

        .print-row { margin: 8px 0; padding: 6px 0; border-bottom: 1px dotted #999; display: flex; justify-content: space-between; }
        .print-label { font-weight: bold; flex: 0 0 40%; }
        .print-value { flex: 1; text-align: left; word-wrap: break-word; }
        .print-footer { text-align: center; margin-top: 15px; padding-top: 10px; border-top: 2px dashed #000; font-size: 11px; }
        .print-footer p { margin: 4px 0; }

        /* Edit Modal */
        .modal-overlay {
            display: none;
            position: fixed;
            top: 0; left: 0; right: 0; bottom: 0;
            background: rgba(0,0,0,0.55);
            z-index: 20000;
            align-items: center;
            justify-content: center;
            padding: 15px;
        }

        .modal-overlay.show { display: flex; }

        .modal-box {
            background: white;
            border-radius: 16px;
            padding: clamp(20px, 4vw, 30px);
            max-width: 500px;
            width: 100%;
            max-height: 90vh;
            overflow-y: auto;
            box-shadow: 0 20px 60px rgba(0,0,0,0.4);
            animation: slideIn 0.3s ease;
            position: relative;
        }

        .modal-close-btn {
            position: absolute;
            top: 14px;
            left: 14px;
            width: 32px;
            height: 32px;
            border: none;
            border-radius: 50%;
            background: #f1f1f1;
            color: #8B2635;
            font-size: 1.3em;
            line-height: 1;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s;
        }

        .modal-close-btn:hover { background: #8B2635; color: white; transform: rotate(90deg); }

        .modal-box h3 { color: #8B2635; margin-bottom: 20px; text-align: center; }

        .modal-field { margin-bottom: 16px; }
        .modal-field label { display: block; font-weight: 600; color: #333; margin-bottom: 6px; font-size: 0.9em; }
        .modal-field select { width: 100%; min-width: unset; }

        .toggle-group { display: flex; gap: 10px; }
        .toggle-btn {
            flex: 1;
            padding: 10px;
            border: 2px solid #e0e0e0;
            border-radius: 10px;
            background: white;
            cursor: pointer;
            font-weight: 600;
            transition: all 0.2s;
        }
        .toggle-btn.active-yes { background: #28a745; color: white; border-color: #28a745; }
        .toggle-btn.active-no { background: #6c757d; color: white; border-color: #6c757d; }

        .modal-actions { display: flex; gap: 10px; margin-top: 20px; }
        .modal-actions .btn { flex: 1; }
        .btn-secondary { background: #e0e0e0; color: #333; }
        .btn-secondary:hover { background: #ccc; }

        @media (max-width: 768px) {
            body { padding: 10px; }
            .table-container { margin-left: -10px; margin-right: -10px; border-radius: 0; }
            .header h1 { word-break: break-word; }
            .header { flex-direction: column; text-align: center; }
            .logout-btn { width: 100%; }
        }

        @media (max-width: 480px) {
            .stat-card:hover { transform: translateY(-3px) scale(1.01); }
            .filters-row { flex-direction: column; }
            .login-box { padding: 30px 20px; }
        }
