/* Base styles */

:root {

    --primary-color: #0d6efd;

    --success-color: #198754;

    --warning-color: #ffc107;

    --danger-color: #dc3545;

    --info-color: #0dcaf0;

    --dark-color: #212529;

    --light-bg: #f8f9fa;

    --card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);

    --card-shadow-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

}

body {

    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);

    min-height: 100vh;

    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;

}

/* App logo animation */

.app-logo i {

    animation: pulse 2s ease-in-out infinite;

}

@keyframes pulse {

    0%, 100% { transform: scale(1); }

    50% { transform: scale(1.05); }

}

/* Upload form styles */

.upload-form {

    background: white;

    border-radius: 16px;

    box-shadow: var(--card-shadow);

    overflow: hidden;

}

.form-section {

    padding: 1.5rem 2rem;

    border-bottom: 1px solid #e9ecef;

}

.form-section:last-of-type {

    border-bottom: none;

}

.form-section-title {

    color: var(--dark-color);

    font-weight: 600;

    margin-bottom: 1.25rem;

}

/* Drop zone styles */

.drop-zone {

    border: 2px dashed #dee2e6;

    border-radius: 12px;

    padding: 2.5rem;

    text-align: center;

    transition: all 0.3s ease;

    cursor: pointer;

    background: var(--light-bg);

}

.drop-zone:hover, .drop-zone.drag-over {

    border-color: var(--primary-color);

    background: rgba(13, 110, 253, 0.05);

}

.drop-zone-icon {

    font-size: 3rem;

    color: #6c757d;

    margin-bottom: 1rem;

    display: block;

}

.drop-zone-text {

    font-size: 1.1rem;

    color: #495057;

}

.drop-zone-selected {

    display: flex;

    align-items: center;

    justify-content: center;

    padding: 1rem;

    background: #d1e7dd;

    border-radius: 8px;

}

/* Video preview */

.video-preview {

    width: 100%;

    max-height: 300px;

    border-radius: 8px;

    background: #000;

}

/* Form range styling */

.form-range {

    flex: 1;

}

/* Submit button */

.submit-btn {

    padding: 1rem 2rem;

    font-size: 1.1rem;

    font-weight: 600;

    border-radius: 10px;

    margin: 1.5rem 2rem 2rem;

    transition: all 0.3s ease;

}

.submit-btn:hover:not(:disabled) {

    transform: translateY(-2px);

    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.4);

}

.submit-btn:disabled {

    opacity: 0.6;

    cursor: not-allowed;

}

/* Info cards */

.info-card {

    background: white;

    border-radius: 12px;

    padding: 1.5rem;

    text-align: center;

    box-shadow: var(--card-shadow);

    transition: transform 0.3s ease;

    height: 100%;

}

.info-card:hover {

    transform: translateY(-5px);

}

.info-card i {

    font-size: 2rem;

    margin-bottom: 0.75rem;

    display: block;

}

.info-card h6 {

    font-weight: 600;

    margin-bottom: 0.5rem;

}

/* Processing page styles */

.video-container {

    background: #000;

    border-radius: 12px;

    overflow: hidden;

    position: relative;

    min-height: 400px;

}

.video-frame {

    width: 100%;

    display: block;

}

.loading-overlay {

    position: absolute;

    top: 0;

    left: 0;

    right: 0;

    bottom: 0;

    background: rgba(0, 0, 0, 0.8);

    display: flex;

    flex-direction: column;

    align-items: center;

    justify-content: center;

    color: white;

}

/* Stat cards */

.stat-card {

    background: white;

    border-radius: 12px;

    padding: 1rem 1.25rem;

    display: flex;

    align-items: center;

    gap: 1rem;

    box-shadow: var(--card-shadow);

}

.stat-icon {

    width: 48px;

    height: 48px;

    border-radius: 10px;

    display: flex;

    align-items: center;

    justify-content: center;

    font-size: 1.25rem;

}

.bg-primary-soft { background: rgba(13, 110, 253, 0.1); }

.bg-success-soft { background: rgba(25, 135, 84, 0.1); }

.bg-warning-soft { background: rgba(255, 193, 7, 0.1); }

.bg-info-soft { background: rgba(13, 202, 240, 0.1); }

.stat-value {

    font-size: 1.5rem;

    font-weight: 700;

    display: block;

    line-height: 1.2;

}

.stat-label {

    font-size: 0.8rem;

    color: #6c757d;

    text-transform: uppercase;

    letter-spacing: 0.5px;

}

/* Sidebar panel */

.sidebar-panel {

    background: white;

    min-height: 100vh;

    border-left: 1px solid #e9ecef;

}

/* Detection log */

.detection-log {

    max-height: 500px;

    overflow-y: auto;

}

.detection-entry {

    background: var(--light-bg);

    border-radius: 8px;

    padding: 0.75rem 1rem;

    margin-bottom: 0.5rem;

    border-left: 3px solid var(--success-color);

}

.detection-entry.animate-in {

    animation: slideIn 0.3s ease;

}

@keyframes slideIn {

    from {

        opacity: 0;

        transform: translateX(-20px);

    }

    to {

        opacity: 1;

        transform: translateX(0);

    }

}

.plate-number {

    font-family: 'Courier New', monospace;

    font-weight: 700;

    font-size: 1.1rem;

    letter-spacing: 1px;

}

/* Spinner animation */

.spin {

    animation: spin 1s linear infinite;

}

@keyframes spin {

    from { transform: rotate(0deg); }

    to { transform: rotate(360deg); }

}

/* Results page styles */

.results-header {

    padding: 2rem 0;

}

.summary-card {

    border-radius: 16px;

    padding: 1.5rem;

    display: flex;

    align-items: center;

    gap: 1.25rem;

    box-shadow: var(--card-shadow);

}

.summary-icon {

    width: 64px;

    height: 64px;

    background: rgba(255, 255, 255, 0.2);

    border-radius: 12px;

    display: flex;

    align-items: center;

    justify-content: center;

    font-size: 1.75rem;

}

.summary-value {

    font-size: 2.5rem;

    font-weight: 700;

    margin-bottom: 0;

}

.summary-label {

    opacity: 0.9;

}

/* Results table */

.results-table-container {

    background: white;

    border-radius: 12px;

    box-shadow: var(--card-shadow);

    overflow: hidden;

}

.plate-code {

    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);

    color: white;

    padding: 0.35rem 0.75rem;

    border-radius: 6px;

    font-family: 'Courier New', monospace;

    font-weight: 700;

    font-size: 0.95rem;

    letter-spacing: 1px;

}

/* Sortable headers */

.sortable {

    cursor: pointer;

    user-select: none;

    transition: background-color 0.2s ease;

}

.sortable:hover {

    background-color: #343a40;

}

.sortable::after {

    content: 'Ôçà';

    margin-left: 0.5rem;

    opacity: 0.5;

}

.sortable.sort-asc::after {

    content: 'Ôåæ';

    opacity: 1;

}

.sortable.sort-desc::after {

    content: 'Ôåô';

    opacity: 1;

}

/* Responsive adjustments */

@media (max-width: 768px) {

    .sidebar-panel {

        min-height: auto;

        border-left: none;

        border-top: 1px solid #e9ecef;

    }

    .stat-card {

        padding: 0.75rem 1rem;

    }

    .stat-value {

        font-size: 1.25rem;

    }

    .summary-card {

        padding: 1rem;

    }

    .summary-value {

        font-size: 1.75rem;

    }

    .summary-icon {

        width: 48px;

        height: 48px;

        font-size: 1.25rem;

    }

}

/* ─── Vehicle Card Styles ──────────────────────────────────────────── */

.vehicle-card {

    background: white;

    border-radius: 14px;

    box-shadow: var(--card-shadow);

    overflow: hidden;

    transition: transform 0.2s ease, box-shadow 0.2s ease;

}

.vehicle-card:hover {

    transform: translateY(-3px);

    box-shadow: var(--card-shadow-hover);

}

.vehicle-card-header {

    padding: 1.25rem 1.5rem;

    border-bottom: 1px solid #e9ecef;

    background: var(--light-bg);

}

.vehicle-plate {

    font-family: 'Courier New', monospace;

    font-weight: 800;

    font-size: 1.3rem;

    letter-spacing: 2px;

    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);

    color: white;

    padding: 0.3rem 0.8rem;

    border-radius: 6px;

}

.vehicle-card-body {

    padding: 1.25rem 1.5rem;

}

.vehicle-spec {

    background: var(--light-bg);

    border-radius: 8px;

    padding: 0.6rem 0.8rem;

}

.spec-label {

    display: block;

    font-size: 0.7rem;

    text-transform: uppercase;

    letter-spacing: 0.5px;

    color: #6c757d;

    margin-bottom: 2px;

}

.spec-value {

    display: block;

    font-size: 0.95rem;

    font-weight: 600;

}

/* ─── Snow Estimate Panel ──────────────────────────────────────────── */

.snow-estimate-panel {

    background: linear-gradient(135deg, #e8f4f8 0%, #d4ecf7 100%);

    border-radius: 10px;

    padding: 1rem 1.25rem;

    border: 1px solid #b8daff;

}

.snow-stat {

    background: white;

    border-radius: 8px;

    padding: 0.75rem 0.5rem;

    box-shadow: 0 1px 3px rgba(0,0,0,0.08);

}

.snow-stat-value {

    display: block;

    font-size: 1.4rem;

    font-weight: 700;

    color: #0d6efd;

}

.snow-stat-label {

    display: block;

    font-size: 0.7rem;

    text-transform: uppercase;

    color: #6c757d;

}

/* ─── System Overview Page ─────────────────────────────────────────── */

.system-hero {

    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);

    color: white;

    padding: 5rem 0;

    position: relative;

    overflow: hidden;

}

.system-hero::before {

    content: '';

    position: absolute;

    top: -50%;

    right: -20%;

    width: 600px;

    height: 600px;

    background: radial-gradient(circle, rgba(13, 202, 240, 0.15) 0%, transparent 70%);

    border-radius: 50%;

}

.hero-visual {

    position: relative;

}

.hero-icon-stack {

    position: relative;

    display: inline-block;

}

.hero-icon-bg {

    font-size: 10rem;

    color: rgba(255,255,255,0.1);

}

.hero-icon-fg {

    position: absolute;

    top: 50%;

    left: 50%;

    transform: translate(-50%, -50%);

    font-size: 4rem;

    color: #0dcaf0;

    animation: float 3s ease-in-out infinite;

}

@keyframes float {

    0%, 100% { transform: translate(-50%, -50%); }

    50% { transform: translate(-50%, -60%); }

}

/* Pipeline Flow */

.pipeline-flow {

    background: white;

    border-radius: 16px;

    padding: 2rem;

    box-shadow: var(--card-shadow);

}

.pipeline-step {

    position: relative;

    text-align: center;

}

.pipeline-step-inner {

    padding: 1.5rem 1rem;

}

.pipeline-number {

    width: 32px;

    height: 32px;

    border-radius: 50%;

    background: var(--primary-color);

    color: white;

    font-weight: 700;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    margin-bottom: 0.75rem;

    font-size: 0.9rem;

}

.pipeline-icon {

    font-size: 2.5rem;

    margin-bottom: 0.75rem;

    color: var(--primary-color);

}

.pipeline-arrow {

    position: absolute;

    right: -12px;

    top: 50%;

    transform: translateY(-50%);

    font-size: 1.5rem;

    color: #dee2e6;

    z-index: 2;

}

/* Architecture Diagram */

.architecture-diagram {

    padding: 2rem 0;

}

.arch-layer {

    background: white;

    border-radius: 14px;

    padding: 1.5rem;

    box-shadow: var(--card-shadow);

    height: 100%;

    border-top: 3px solid #dee2e6;

}

.arch-layer-primary {

    border-top-color: var(--primary-color);

}

.arch-layer-title {

    font-weight: 600;

    margin-bottom: 1rem;

    color: #495057;

}

.arch-component {

    background: var(--light-bg);

    border-radius: 8px;

    padding: 0.75rem;

    margin-bottom: 0.5rem;

    text-align: center;

    transition: background 0.2s;

}

.arch-component:hover {

    background: #e9ecef;

}

.arch-component i {

    font-size: 1.5rem;

    display: block;

    margin-bottom: 0.3rem;

}

.arch-component span {

    font-weight: 600;

    font-size: 0.85rem;

}

/* Tech Cards */

.tech-card {

    background: white;

    border-radius: 14px;

    padding: 2rem;

    box-shadow: var(--card-shadow);

    height: 100%;

    transition: transform 0.2s ease;

}

.tech-card:hover {

    transform: translateY(-4px);

}

.tech-icon-wrap {

    font-size: 2.5rem;

    color: var(--primary-color);

    margin-bottom: 1rem;

}

.tech-specs {

    margin-top: 1rem;

    display: flex;

    gap: 0.5rem;

    flex-wrap: wrap;

}

/* Methodology */

.methodology-card {

    background: white;

    border-radius: 12px;

    padding: 1.5rem;

    box-shadow: var(--card-shadow);

}

.formula-box {

    background: #f0f4ff;

    border-radius: 8px;

    padding: 0.75rem 1rem;

    border-left: 3px solid var(--primary-color);

    font-size: 1.05rem;

}

.swe-reference-card {

    background: white;

    border-radius: 14px;

    padding: 1.5rem;

    box-shadow: var(--card-shadow);

}

/* Roadmap */

.roadmap-timeline {

    position: relative;

    padding-left: 40px;

}

.roadmap-timeline::before {

    content: '';

    position: absolute;

    left: 15px;

    top: 0;

    bottom: 0;

    width: 3px;

    background: #dee2e6;

}

.roadmap-item {

    position: relative;

    margin-bottom: 2rem;

}

.roadmap-marker {

    position: absolute;

    left: -40px;

    top: 4px;

    width: 34px;

    height: 34px;

    border-radius: 50%;

    background: #dee2e6;

    color: white;

    display: flex;

    align-items: center;

    justify-content: center;

    font-size: 0.9rem;

    z-index: 1;

}

.roadmap-item.completed .roadmap-marker {

    background: var(--success-color);

}

.roadmap-item.current .roadmap-marker {

    background: var(--primary-color);

    box-shadow: 0 0 0 4px rgba(13, 110, 253, 0.25);

}

.roadmap-content {

    background: white;

    border-radius: 12px;

    padding: 1.25rem;

    box-shadow: var(--card-shadow);

}

/* Requirements Cards */

.req-card {

    background: white;

    border-radius: 14px;

    padding: 1.5rem;

    box-shadow: var(--card-shadow);

    height: 100%;

}

.req-icon {

    font-size: 2.5rem;

    margin-bottom: 1rem;

}

.req-card ul {

    padding-left: 1.2rem;

}

.req-card li {

    margin-bottom: 0.3rem;

}
