:root {
    --bg-color: #f8fafc;
    --card-bg: #ffffff;
    --text-primary: #0f172a;
    --text-secondary: #64748b;
    --primary: #2563eb; 
    --primary-hover: #1d4ed8;
    --accent: #38bdf8;
    --border: #e2e8f0;
    --success: #10b981;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Remove dark mode blobs, keep them very subtle for a modern feel */
.background-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
    background: #f8fafc;
}

.blob {
    position: absolute;
    filter: blur(100px);
    opacity: 0.15;
    border-radius: 50%;
    animation: float 20s ease-in-out infinite;
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, #3b82f6 0%, transparent 70%);
}

.blob-2 {
    bottom: -20%;
    right: -10%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, #38bdf8 0%, transparent 70%);
    animation-delay: -10s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(30px, -50px) scale(1.1); }
    66% { transform: translate(-20px, 20px) scale(0.9); }
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 3rem 1.5rem;
}

header {
    text-align: center;
    margin-bottom: 2rem;
}

h1 {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 1rem 0;
}

header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Progress Indicator */
.progress-container {
    margin-bottom: 2.5rem;
    position: relative;
    padding: 0 1rem;
}

.progress-bar-bg {
    position: absolute;
    top: 50%;
    left: 1rem;
    right: 1rem;
    height: 4px;
    background: var(--border);
    transform: translateY(-50%);
    z-index: 1;
    border-radius: 2px;
}

.progress-bar-fill {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0%; 
    background: var(--primary);
    transition: width 0.4s ease;
    border-radius: 2px;
}

.progress-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    z-index: 2;
}

.progress-steps .step {
    width: 35px;
    height: 35px;
    background: var(--card-bg);
    border: 2px solid var(--border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: var(--text-secondary);
    transition: all 0.4s ease;
}

.progress-steps .step.active {
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.progress-steps .step.completed {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* Form Steps */
.step-content {
    display: none;
    animation: fadeIn 0.4s ease;
}

.step-content.active {
    display: block;
}

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

.form-section {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
}

h2 {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    padding-bottom: 0.8rem;
    border-bottom: 1px solid var(--border);
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
    font-size: 0.95rem;
}

input, textarea {
    width: 100%;
    background: #fff;
    border: 1px solid var(--border);
    color: var(--text-primary);
    padding: 0.85rem 1rem;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s ease;
}

input::placeholder, textarea::placeholder {
    color: #cbd5e1;
}

input:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

/* Upload Area */
.upload-area {
    border: 2px dashed var(--border);
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
    background: #f8fafc;
    transition: all 0.3s ease;
}

.upload-area:hover {
    border-color: var(--primary);
    background: #f1f5f9;
}

.btn-upload {
    background: #fff;
    border: 1px solid var(--border);
    color: var(--text-primary);
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
}

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

/* Navigation Buttons */
.form-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 2rem;
}

#nextBtn {
    margin-left: auto;
}

.nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 1.8rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

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

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

.btn-secondary {
    background: #f1f5f9;
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: #e2e8f0;
}

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

.btn-submit:hover {
    background: var(--primary-hover);
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.5); /* Dimming background */
    backdrop-filter: blur(4px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    display: flex;
    opacity: 1;
}

.modal-content {
    background: var(--card-bg);
    border-radius: 16px;
    width: 95%;
    padding: 2rem;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

.modal-large { 
    max-width: 800px; 
    max-height: 90vh; 
    display: flex; 
    flex-direction: column; 
}

.modal.show .modal-content {
    transform: scale(1);
}

.close-btn {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 2rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.3s ease;
}

.close-btn:hover { color: var(--text-primary); }

.news-content {
    background: #f8fafc;
    padding: 1.5rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow-y: auto;
    flex-grow: 1;
    font-family: 'Georgia', serif;
    line-height: 1.8;
    color: var(--text-primary);
    white-space: pre-wrap; 
}

.result-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

/* Loading State */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 0;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #e2e8f0;
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1.5rem;
}

@keyframes spin { 
    100% { transform: rotate(360deg); } 
}

/* Mobile Friendly Adjustments */
@media (max-width: 600px) {
    .container { 
        padding: 1.5rem 1rem; 
    }
    .form-section { 
        padding: 1.5rem; 
        border-radius: 12px;
    }
    h1 { 
        font-size: 1.8rem; 
    }
    .progress-steps .step {
        width: 30px;
        height: 30px;
        font-size: 0.85rem;
    }
    .nav-btn {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }
    .modal-content {
        padding: 1.5rem;
    }
}
