/* GamutLogic - Modern Engineering Style */

/* Fonts */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.font-mono {
    font-family: 'JetBrains Mono', 'Courier New', monospace;
}

/* Engineering Input Style - Modern & Minimal */
.eng-input {
    width: 100%;
    padding: 12px 16px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.875rem;
    font-weight: 500;
    color: #0f172a;
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.02em;
}

.eng-input:hover {
    border-color: #cbd5e1;
    background: #f8fafc;
}

.eng-input:focus {
    border-color: #6366f1;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
    outline: none;
}

/* Input wrapper with bottom indicator */
.input-wrapper {
    position: relative;
}

.input-wrapper::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0;
    height: 2px;
    background: linear-gradient(to right, #6366f1, #8b5cf6);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 1px;
}

.input-wrapper:focus-within::after {
    width: 100%;
}

/* Modern Card Style */
.modern-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    transition: all 0.2s ease;
}

.modern-card:hover {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

/* Remove spacing when data-preview-card is hidden */
#data-preview-card.hidden + .modern-card {
    margin-top: 0 !important;
    padding-top: 0;
}

/* Engineering Card Header */
.card-header {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-bottom: 1px solid #e2e8f0;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeIn {
    animation: fadeIn 0.4s ease-out;
}

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

.animate-slideDown {
    animation: slideDown 0.3s ease-out;
}

/* Data Table Styles - Engineering Look */
#data-table {
    border-collapse: separate;
    border-spacing: 0;
    width: 100%;
}

#data-table thead th {
    position: sticky;
    top: 0;
    z-index: 10;
    background: #0f172a;
    color: #e2e8f0;
    border-bottom: 2px solid #334155;
    padding: 14px 16px;
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: none !important;
    letter-spacing: 0.1em;
    text-align: center;
    font-family: 'Inter', sans-serif;
}

#data-table tbody tr {
    transition: background-color 0.15s ease;
    border-bottom: 1px solid #e2e8f0;
}

#data-table tbody tr:nth-child(odd) {
    background-color: #ffffff;
}

#data-table tbody tr:nth-child(even) {
    background-color: #f8fafc;
}

#data-table tbody tr:hover {
    background-color: #f1f5f9 !important;
}

#data-table td {
    padding: 12px 16px;
    font-size: 0.75rem;
    border-right: 1px solid #f1f5f9;
    white-space: nowrap;
    text-align: center;
    font-family: 'JetBrains Mono', monospace;
    color: #334155;
    font-weight: 500;
}

#data-table th {
    border-right: 1px solid #334155;
}

#data-table td:last-child,
#data-table th:last-child {
    border-right: none;
}

/* Scrollbar Styling - Modern */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Data Preview Card Scrollbar */
#data-preview-card .overflow-x-auto::-webkit-scrollbar,
#data-preview-card .overflow-y-auto::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

#data-preview-card .overflow-x-auto::-webkit-scrollbar-track,
#data-preview-card .overflow-y-auto::-webkit-scrollbar-track {
    background: #f8fafc;
    border-radius: 3px;
}

#data-preview-card .overflow-x-auto::-webkit-scrollbar-thumb,
#data-preview-card .overflow-y-auto::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

#data-preview-card .overflow-x-auto::-webkit-scrollbar-thumb:hover,
#data-preview-card .overflow-y-auto::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Logs Container Scrollbar */
#logs::-webkit-scrollbar-track {
    background: #1e293b;
}

#logs::-webkit-scrollbar-thumb {
    background: #475569;
}

#logs::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* Status Badge */
.status-badge {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.625rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 4px;
    letter-spacing: 0.05em;
}

/* Engineering Badge */
.eng-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: #0f172a;
    color: #10b981;
    font-size: 0.625rem;
    font-weight: 700;
    font-family: 'JetBrains Mono', monospace;
    border-radius: 4px;
    letter-spacing: 0.05em;
}

/* Section Title */
.section-title {
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #64748b;
    margin-bottom: 8px;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .eng-input {
        font-size: 0.875rem;
        padding: 10px 14px;
    }
}

/* Language Selector */
#language-selector {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.5rem center;
    padding-right: 2rem;
}

#language-selector:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.3);
}

/* Print Styles */
@media print {
    nav, footer, button {
        display: none;
    }
    
    body {
        background: white;
    }
}
