:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    --secondary: #475569;
    --accent: #f59e0b;
    --success: #10b981;
    --danger: #ef4444;
    --background: #f8fafc;
    --card-bg: #ffffff;
    --text-dark: #1e293b;
    --text-gray: #64748b;
    --text-light: #f8fafc;
    --border: #e2e8f0;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.12);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1);
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--background);
    color: var(--text-dark);
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
}

.container-fluid {
    padding: 0;
}

/* Navbar Styles */
.navbar {
    padding: 0.75rem 0;
    box-shadow: var(--shadow-md);
    z-index: 1000;
}

.navbar-brand {
    display: flex;
    align-items: center;
}

.logo-circle {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

.navbar-brand span {
    font-size: 1.1rem;
    letter-spacing: -0.5px;
}

.navbar-brand small {
    font-size: 0.7rem;
    opacity: 0.8;
}

.navbar-nav .nav-link {
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.5rem 1rem !important;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.navbar-nav .nav-link:hover {
    background: rgba(255,255,255,0.1);
}

.navbar-nav .nav-link.active {
    background: rgba(255,255,255,0.15);
}

/* Hero Section */
.hero-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-bottom: 1px solid var(--border);
}

.hero-section h1 {
    color: var(--text-dark);
    letter-spacing: -0.5px;
}

.hero-section .lead {
    font-size: 1.1rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.stats {
    margin: 2rem 0;
}

.stat-item {
    text-align: center;
    padding: 1rem;
    min-width: 120px;
}

.stat-item h3 {
    margin-bottom: 0.25rem;
}

.stat-item small {
    font-size: 0.85rem;
    color: var(--text-gray);
}

/* Upload Card */
.upload-card {
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.upload-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg) !important;
}

.upload-area {
    border: 2px dashed var(--primary);
    border-radius: var(--radius-md);
    background-color: rgba(37, 99, 235, 0.03);
    transition: all 0.3s ease;
    cursor: pointer;
}

.upload-area:hover {
    background-color: rgba(37, 99, 235, 0.08);
    border-color: var(--primary-dark);
}

.icon-box {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
}

.btn {
    padding: 0.6rem 1.2rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all 0.2s ease;
}

.btn-primary {
    background-color: var(--primary);
    border-color: var(--primary);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-success {
    background-color: var(--success);
    border-color: var(--success);
}

.btn-success:hover {
    background-color: #0f9d58;
    border-color: #0f9d58;
    transform: translateY(-1px);
}

/* Tabs */
.custom-tabs {
    border-bottom: 2px solid var(--border);
    margin-bottom: 1.5rem;
}

.custom-tabs .nav-link {
    color: var(--secondary);
    padding: 1rem 1.5rem;
    border: none;
    position: relative;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    font-weight: 500;
}

.custom-tabs .nav-link span {
    margin-left: 0.5rem;
}

.custom-tabs .nav-link.active {
    color: var(--primary);
    background: none;
    border: none;
}

.custom-tabs .nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background-color: var(--primary);
}

/* Card Styles */
.card {
    border-radius: var(--radius-lg);
    border: none;
    box-shadow: var(--shadow-md);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.card-header {
    background-color: var(--card-bg);
    border-bottom: 1px solid var(--border);
    padding: 1rem 1.5rem;
}

.card-body {
    padding: 1.5rem;
}

/* Q&A Section */
.qa-container {
    max-height: 500px;
    overflow-y: auto;
    padding: 1rem;
}

.qa-message {
    margin-bottom: 1.5rem;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    max-width: 80%;
    position: relative;
}

.qa-question {
    background-color: #f1f5f9;
    margin-right: auto;
    border-bottom-left-radius: 4px;
}

.qa-answer {
    background-color: #e0f2f1;
    margin-left: auto;
    border-bottom-right-radius: 4px;
}

.qa-message i {
    margin-right: 0.5rem;
    font-size: 1.2rem;
}

/* Analysis Content */
.analysis-content {
    padding: 1.5rem;
    line-height: 1.7;
}

.analysis-content strong {
    color: var(--primary);
}

/* Footer */
footer {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    padding: 3rem 0 1.5rem;
    margin-top: 3rem;
}

footer h5 {
    font-weight: 600;
    margin-bottom: 1.25rem;
    font-size: 1rem;
    letter-spacing: 0.5px;
}

footer ul li {
    margin-bottom: 0.75rem;
}

footer a {
    text-decoration: none;
    transition: color 0.2s ease;
}

footer a:hover {
    color: var(--primary-light) !important;
}

footer .social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    margin-right: 0.5rem;
    transition: all 0.2s ease;
}

footer .social-links a:hover {
    background: var(--primary);
    transform: translateY(-2px);
}

footer .social-links a i {
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .navbar .container {
        padding: 0 1rem;
    }
    
    .hero-section {
        padding: 3rem 0;
    }
    
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .custom-tabs .nav-link {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
    
    .qa-message {
        max-width: 95%;
    }
    
    footer .row g-4 {
        row-gap: 2rem;
    }
}
