/* ========================================
   Smart Mudhra Samadhan - Main Stylesheet
   Mobile-First, GIGW 3.0 Compliant
   ======================================== */

/* ========== CSS VARIABLES ========== */
:root {
    /* Colors - Jharkhand Green Theme */
    --primary-green: #1B5E20;
    --primary-green-dark: #0D3B10;
    --primary-green-light: #2E7D32;
    --accent-green: #4CAF50;
    
    /* Tricolor */
    --tricolor-saffron: #FF9933;
    --tricolor-white: #FFFFFF;
    --tricolor-green: #138808;
    
    /* Text Colors */
    --text-dark: #1a1a1a;
    --text-medium: #444444;
    --text-light: #666666;
    
    /* Background Colors */
    --bg-light: #f8f9fa;
    --bg-cream: #fefcf8;
    
    /* Border & Shadow */
    --border-color: #e0e0e0;
    --border-gray: #eeeeee;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --shadow-lg: 0 8px 24px rgba(27, 94, 32, 0.15);
    
    /* Font Sizes */
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;
    --font-size-3xl: 2rem;
    
    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
}

/* ========== RESET & BASE ========== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Sans', 'Noto Sans Devanagari', sans-serif;
    font-size: var(--font-size-base);
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--bg-cream);
    min-height: 100vh;
}

img {
    max-width: 100%;
    height: auto;
}

a {
    color: var(--primary-green);
    text-decoration: none;
}

/* ========== UTILITY CLASSES ========== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-green);
    color: white;
    padding: 8px 16px;
    z-index: 100;
}

.skip-link:focus {
    top: 0;
}

.hide-mobile {
    display: none;
}

@media (min-width: 768px) {
    .hide-mobile {
        display: initial;
    }
}




/* NOTE: Header & Footer styles moved to header.js and footer.js */
/* Include header-footer-styles.css for those styles */

/* ========== HERO SECTION ========== */
.hero-section {
    padding: var(--spacing-lg) 0;
    background: linear-gradient(135deg, var(--bg-cream) 0%, #f0f8f0 100%);
}

.hero-grid {
    display: grid;
    gap: var(--spacing-lg);
}

.video-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.video-wrapper {
    position: relative;
    padding-top: 56.25%;
    background: #000;
}

.video-wrapper video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: var(--primary-green);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.play-btn::after {
    content: '';
    border-left: 18px solid white;
    border-top: 12px solid transparent;
    border-bottom: 12px solid transparent;
    margin-left: 4px;
}

.video-info {
    padding: 15px;
}

.video-info h2 {
    font-size: var(--font-size-lg);
    color: var(--primary-green);
    margin-bottom: 5px;
}

.video-info p {
    font-size: var(--font-size-sm);
    color: var(--text-light);
}

.about-box {
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-light));
    padding: 15px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: var(--spacing-md);
}

.about-box .icon {
    font-size: 2rem;
}

.about-box h3 {
    color: white;
    font-size: var(--font-size-sm);
    margin-bottom: 4px;
}

.about-box .disclaimer {
    color: rgba(255,255,255,0.8);
    font-size: var(--font-size-xs);
}

.services-panel {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.service-card {
    background: white;
    border-radius: 12px;
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    transition: all 0.3s;
}

.service-card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--primary-green);
}

.service-icon {
    width: 45px;
    height: 45px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.service-icon.yellow { background: #FFF3E0; }
.service-icon.green { background: #E8F5E9; }
.service-icon.blue { background: #E3F2FD; }

.service-content {
    flex: 1;
}

.service-content h3 {
    font-size: var(--font-size-sm);
    color: var(--text-dark);
    margin-bottom: 4px;
}

.service-content p {
    font-size: var(--font-size-xs);
    color: var(--text-light);
    line-height: 1.4;
}

.service-arrow {
    color: var(--primary-green);
    font-size: 1.2rem;
}

.tip-box {
    background: #FFF8E1;
    border: 1px solid #FFE082;
    border-radius: 8px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tip-box .bulb {
    font-size: 1.2rem;
}

.tip-box p {
    font-size: var(--font-size-xs);
    color: var(--text-medium);
}

@media (min-width: 768px) {
    .hero-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--spacing-xl);
    }
}

/* ========== PMMY SECTION ========== */
.pmmy-section {
    padding: var(--spacing-xl) 0;
    background: white;
}

.pmmy-grid {
    display: grid;
    gap: var(--spacing-lg);
}

.loan-categories-card {
    background: linear-gradient(135deg, #E8F5E9, #C8E6C9);
    border-radius: 16px;
    padding: var(--spacing-lg);
    text-align: center;
}

.mudra-logo-box {
    margin-bottom: var(--spacing-md);
}

.mudra-logo-large {
    height: 60px;
}

.loan-categories-card h2 {
    color: var(--primary-green);
    font-size: var(--font-size-lg);
    margin-bottom: 8px;
}

.loan-categories-card .subtitle {
    color: var(--text-medium);
    font-size: var(--font-size-sm);
    margin-bottom: var(--spacing-md);
}

.loan-table {
    width: 100%;
    border-collapse: collapse;
}

.loan-table tr {
    border-bottom: 1px solid rgba(27, 94, 32, 0.2);
}

.loan-table td {
    padding: 12px 10px;
    font-size: var(--font-size-sm);
}

.loan-name {
    font-weight: 600;
    color: var(--primary-green);
    text-align: left;
}

.loan-amount {
    color: var(--text-medium);
    text-align: right;
}

.benefits-section h2 {
    color: var(--primary-green);
    font-size: var(--font-size-lg);
    margin-bottom: var(--spacing-md);
}

.benefits-list {
    list-style: none;
}

.benefits-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 0;
    font-size: var(--font-size-sm);
    color: var(--text-medium);
    border-bottom: 1px solid var(--border-gray);
}

.benefits-list .check {
    width: 20px;
    height: 20px;
    background: var(--primary-green);
    border-radius: 50%;
    flex-shrink: 0;
    position: relative;
}

.benefits-list .check::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
}

@media (min-width: 768px) {
    .pmmy-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* ========== FEATURES SECTION ========== */
.features-section {
    padding: var(--spacing-xl) 0;
    background: var(--bg-light);
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

.section-header h2 {
    color: var(--primary-green);
    font-size: var(--font-size-xl);
    margin-bottom: 8px;
}

.section-header p {
    color: var(--text-light);
    font-size: var(--font-size-sm);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.feature-card {
    background: white;
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.feature-card .icon {
    font-size: 2rem;
    margin-bottom: 8px;
}

.feature-card h4 {
    font-size: var(--font-size-sm);
    color: var(--text-dark);
    margin-bottom: 4px;
}

.feature-card p {
    font-size: var(--font-size-xs);
    color: var(--text-light);
}

@media (min-width: 768px) {
    .features-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ========== CTA SECTION ========== */
.cta-section {
    padding: var(--spacing-xl) 0;
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-dark));
    text-align: center;
}

.cta-section h2 {
    color: white;
    font-size: var(--font-size-xl);
    margin-bottom: 8px;
}

.cta-section p {
    color: rgba(255,255,255,0.9);
    font-size: var(--font-size-sm);
    margin-bottom: var(--spacing-lg);
}

.cta-buttons {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    align-items: center;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: 8px;
    font-size: var(--font-size-base);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    border: 2px solid transparent;
}

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

.btn-primary:hover {
    background: #f0f0f0;
}

.btn-secondary {
    background: transparent;
    color: white;
    border-color: white;
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.1);
}

@media (min-width: 768px) {
    .cta-buttons {
        flex-direction: row;
        justify-content: center;
    }
}


/* ========== CHAT PAGE LAYOUT ========== */
.chat-page {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 120px);
}

.chat-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    max-width: 100%;
    padding: 10px;
}

@media (min-width: 768px) {
    .chat-container {
        flex-direction: row;
        max-width: 1200px;
        margin: 0 auto;
        padding: 20px;
        gap: 20px;
    }
}

/* ========== CHAT INTERFACE ========== */
.chat-interface {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    min-height: 400px;
    max-height: calc(100vh - 200px);
}

.chat-header {
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-dark));
    padding: 12px 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: white;
    flex-shrink: 0;
}

.chat-avatar {
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.chat-title h3 {
    font-size: var(--font-size-sm);
    margin-bottom: 2px;
}

.chat-title p {
    font-size: var(--font-size-xs);
    opacity: 0.85;
}

.chat-status {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: var(--font-size-xs);
}

.status-dot {
    width: 8px;
    height: 8px;
    background: #4CAF50;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Chat Messages */
.chat-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background: var(--bg-light);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.message {
    display: flex;
    gap: 8px;
    max-width: 90%;
    animation: fadeIn 0.3s ease;
}

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

.message.ai {
    align-self: flex-start;
}

.message.user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.message .avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.message.ai .avatar {
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-light));
    color: white;
}

.message.user .avatar {
    background: var(--border-color);
}

.message .bubble {
    padding: 10px 14px;
    border-radius: 16px;
    font-size: var(--font-size-sm);
    line-height: 1.5;
}

.message.ai .bubble {
    background: white;
    border: 1px solid var(--border-color);
    border-bottom-left-radius: 4px;
}

.message.user .bubble {
    background: var(--primary-green);
    color: white;
    border-bottom-right-radius: 4px;
}

.message .time {
    font-size: 10px;
    color: var(--text-light);
    margin-top: 4px;
}

.message.user .time {
    text-align: right;
    color: rgba(255,255,255,0.7);
}

/* Quick Actions */
.quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}

.quick-action {
    padding: 6px 12px;
    background: rgba(27, 94, 32, 0.1);
    border: 1px solid rgba(27, 94, 32, 0.2);
    border-radius: 16px;
    font-size: var(--font-size-xs);
    color: var(--primary-green);
    cursor: pointer;
    transition: all 0.3s;
}

.quick-action:hover {
    background: var(--primary-green);
    color: white;
}

/* Uploaded Document */
.uploaded-doc {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: rgba(27, 94, 32, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(27, 94, 32, 0.2);
}

.uploaded-doc .icon {
    font-size: 1.5rem;
}

.uploaded-doc .info h4 {
    font-size: var(--font-size-xs);
    color: var(--text-dark);
}

.uploaded-doc .info p {
    font-size: 10px;
    color: var(--primary-green);
}

/* ========== VOICE INPUT AREA (DEFAULT) ========== */
.voice-input-area {
    padding: 15px;
    background: white;
    border-top: 1px solid var(--border-color);
    flex-shrink: 0;
}

.voice-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.voice-visualizer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    height: 50px;
    width: 100%;
}

.voice-bar {
    width: 4px;
    height: 20px;
    background: var(--primary-green);
    border-radius: 2px;
    transition: height 0.1s;
}

.voice-bar.active {
    animation: barPulse 0.5s ease infinite alternate;
}

@keyframes barPulse {
    from { height: 10px; }
    to { height: 40px; }
}

.mic-btn-large {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-light));
    color: white;
    border: none;
    cursor: pointer;
    font-size: 1.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(27, 94, 32, 0.3);
    transition: all 0.3s;
}

.mic-btn-large:hover {
    transform: scale(1.05);
}

.mic-btn-large.recording {
    background: #f44336;
    animation: pulse-recording 1s infinite;
}

@keyframes pulse-recording {
    0%, 100% { box-shadow: 0 0 0 0 rgba(244, 67, 54, 0.4); }
    50% { box-shadow: 0 0 0 15px rgba(244, 67, 54, 0); }
}

.voice-hint {
    font-size: var(--font-size-xs);
    color: var(--text-light);
    text-align: center;
}

.recording-time {
    font-family: monospace;
    font-size: var(--font-size-lg);
    color: var(--primary-green);
    font-weight: 600;
}

.voice-controls {
    display: none;
    gap: 10px;
}

.voice-controls.active {
    display: flex;
}

.voice-controls button {
    padding: 8px 20px;
    border-radius: 20px;
    border: none;
    font-size: var(--font-size-sm);
    cursor: pointer;
}

.cancel-voice {
    background: var(--bg-light);
    color: var(--text-medium);
}

.send-voice {
    background: var(--primary-green);
    color: white;
}

/* Text input toggle */
.text-input-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding-top: 10px;
    border-top: 1px solid var(--border-gray);
    margin-top: 10px;
}

.text-input-toggle button {
    background: none;
    border: none;
    color: var(--primary-green);
    font-size: var(--font-size-xs);
    cursor: pointer;
    text-decoration: underline;
}

/* Text input area (hidden by default) */
.text-input-area {
    display: none;
    padding: 10px 15px;
    background: white;
    border-top: 1px solid var(--border-color);
}

.text-input-area.active {
    display: block;
}

.input-row {
    display: flex;
    gap: 8px;
    align-items: center;
}

.chat-input {
    flex: 1;
    padding: 10px 14px;
    border: 2px solid var(--border-color);
    border-radius: 20px;
    font-size: var(--font-size-sm);
}

.chat-input:focus {
    outline: none;
    border-color: var(--primary-green);
}

.chat-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

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

.upload-btn {
    background: var(--bg-light);
    border: 2px solid var(--border-color);
    color: var(--text-medium);
}

/* ========== SIDEBAR ========== */
.chat-sidebar {
    display: none;
    width: 280px;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    padding: 15px;
    flex-shrink: 0;
    height: fit-content;
    max-height: calc(100vh - 200px);
    overflow-y: auto;
}

@media (min-width: 768px) {
    .chat-sidebar {
        display: block;
    }
}

/* Mobile sidebar toggle */
.sidebar-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: white;
    padding: 10px 15px;
    border-radius: 8px;
    margin-bottom: 10px;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
}

.sidebar-toggle h4 {
    font-size: var(--font-size-sm);
    color: var(--primary-green);
}

.sidebar-toggle .arrow {
    transition: transform 0.3s;
}

.sidebar-toggle.open .arrow {
    transform: rotate(180deg);
}

.mobile-sidebar {
    display: none;
    background: white;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    box-shadow: var(--shadow-sm);
}

.mobile-sidebar.open {
    display: block;
}

@media (min-width: 768px) {
    .sidebar-toggle,
    .mobile-sidebar {
        display: none !important;
    }
}

.sidebar-section {
    margin-bottom: var(--spacing-lg);
}

.sidebar-section h4 {
    font-size: var(--font-size-sm);
    color: var(--primary-green);
    margin-bottom: var(--spacing-sm);
    display: flex;
    align-items: center;
    gap: 6px;
}

.progress-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.progress-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    background: var(--bg-light);
    border-radius: 6px;
    font-size: var(--font-size-sm);
}

.progress-item.completed {
    background: rgba(27, 94, 32, 0.1);
}

.progress-item .check {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    flex-shrink: 0;
}

.progress-item.completed .check {
    background: var(--primary-green);
    color: white;
}

.progress-item.pending .check {
    border: 2px solid var(--border-color);
}

.download-btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-light));
    color: white;
    border: none;
    border-radius: 8px;
    font-size: var(--font-size-sm);
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* ========== PROGRESS BAR (for risk assessment) ========== */
.progress-bar {
    background: white;
    padding: 12px 15px;
    border-bottom: 1px solid var(--border-color);
}

.steps {
    display: flex;
    justify-content: center;
    max-width: 500px;
    margin: 0 auto;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    flex: 1;
}

.step:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 12px;
    left: 60%;
    width: 80%;
    height: 2px;
    background: var(--border-color);
}

.step.completed:not(:last-child)::after {
    background: var(--primary-green);
}

.step-circle {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 600;
    color: white;
    position: relative;
    z-index: 1;
}

.step.completed .step-circle {
    background: var(--primary-green);
}

.step.active .step-circle {
    background: var(--primary-green);
    box-shadow: 0 0 0 3px rgba(27, 94, 32, 0.2);
}

.step-label {
    margin-top: 4px;
    font-size: 9px;
    color: var(--text-light);
    text-align: center;
}

.step.active .step-label {
    color: var(--primary-green);
    font-weight: 600;
}

/* ========== LOGIN PAGE ========== */
.login-container {
    padding: 20px 15px;
    min-height: calc(100vh - 200px);
}

.login-grid {
    max-width: 900px;
    margin: 0 auto;
    display: grid;
    gap: 20px;
}

.info-section {
    display: none;
}

@media (min-width: 768px) {
    .login-grid {
        grid-template-columns: 1fr 400px;
        gap: 30px;
    }
    
    .info-section {
        display: block;
    }
}

.welcome-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow-md);
    border-left: 4px solid var(--primary-green);
}

.welcome-card h2 {
    color: var(--primary-green);
    font-size: var(--font-size-lg);
    margin-bottom: 10px;
}

.welcome-card p {
    color: var(--text-light);
    font-size: var(--font-size-sm);
    line-height: 1.6;
}

.loan-types {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 15px;
}

.loan-type {
    background: var(--bg-light);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 12px;
    text-align: center;
}

.loan-type .icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    font-size: 1rem;
}

.loan-type h4 {
    color: var(--primary-green);
    font-size: var(--font-size-sm);
}

.loan-type p {
    color: var(--text-light);
    font-size: var(--font-size-xs);
}

.helpline-card {
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-light));
    border-radius: 10px;
    padding: 15px;
    color: white;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 15px;
}

.helpline-card .icon {
    font-size: 1.5rem;
}

.helpline-card h4 {
    font-size: var(--font-size-xs);
    opacity: 0.9;
}

.helpline-card .number {
    font-size: var(--font-size-lg);
    font-weight: 700;
}

.login-card {
    background: white;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.login-header {
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-dark));
    padding: 20px;
    text-align: center;
    color: white;
}

.login-header h3 {
    font-size: var(--font-size-lg);
    margin-bottom: 4px;
}

.login-header p {
    font-size: var(--font-size-sm);
    opacity: 0.9;
}

.login-body {
    padding: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    font-size: var(--font-size-sm);
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--text-dark);
}

.input-wrapper {
    position: relative;
}

.input-wrapper input {
    width: 100%;
    padding: 12px 12px 12px 40px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: var(--font-size-base);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--primary-green);
}

.input-wrapper .icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1rem;
}

.tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 15px;
}

.tab {
    flex: 1;
    padding: 10px;
    border: 2px solid var(--border-color);
    background: var(--bg-light);
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    font-size: var(--font-size-sm);
    color: var(--text-light);
}

.tab.active {
    border-color: var(--primary-green);
    background: rgba(27, 94, 32, 0.1);
    color: var(--primary-green);
}

.captcha-section {
    background: var(--bg-light);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 12px;
    margin-bottom: 15px;
}

.captcha-display {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.captcha-image {
    flex: 1;
    height: 45px;
    background: linear-gradient(45deg, #f0f0f0, #e8e8e8);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: monospace;
    font-size: 1.3rem;
    font-weight: bold;
    letter-spacing: 4px;
    text-decoration: line-through;
}

.refresh-captcha {
    width: 40px;
    height: 40px;
    border: 2px solid var(--primary-green);
    background: white;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
}

.captcha-input {
    width: 100%;
    padding: 10px;
    border: 2px solid var(--border-color);
    border-radius: 6px;
    text-align: center;
    letter-spacing: 3px;
}

.submit-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-dark));
    color: white;
    border: none;
    border-radius: 10px;
    font-size: var(--font-size-base);
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

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

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

.modal,
.otp-modal {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 400px;
    overflow: hidden;
}

.close-modal {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 28px;
    height: 28px;
    border: none;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    color: white;
    cursor: pointer;
}

.otp-header,
.modal-header {
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-dark));
    padding: 25px;
    text-align: center;
    color: white;
    position: relative;
}

.otp-header .icon,
.modal-header .icon {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.otp-header h3,
.modal-header h3 {
    font-size: var(--font-size-lg);
    margin-bottom: 4px;
}

.otp-header p,
.modal-header p {
    font-size: var(--font-size-sm);
    opacity: 0.9;
}

.otp-body,
.modal-body {
    padding: 20px;
}

.otp-sent-to {
    text-align: center;
    margin-bottom: 20px;
}

.otp-sent-to p {
    font-size: var(--font-size-sm);
    color: var(--text-light);
}

.otp-sent-to .destination {
    font-size: var(--font-size-lg);
    color: var(--primary-green);
    font-weight: 600;
}

.otp-inputs {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 15px;
}

.otp-input {
    width: 40px;
    height: 48px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    text-align: center;
    font-size: var(--font-size-xl);
    font-weight: 600;
}

.otp-input:focus {
    outline: none;
    border-color: var(--primary-green);
}

.resend-section {
    text-align: center;
    margin-bottom: 15px;
}

.resend-section p {
    font-size: var(--font-size-sm);
    color: var(--text-light);
}

.timer {
    color: var(--primary-green);
    font-weight: 600;
}

.resend-btn {
    background: none;
    border: none;
    color: var(--primary-green);
    font-weight: 600;
    cursor: pointer;
    text-decoration: underline;
}

.resend-btn:disabled {
    color: var(--text-light);
    cursor: not-allowed;
    text-decoration: none;
}

.verify-btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, var(--primary-green), var(--primary-green-dark));
    color: white;
    border: none;
    border-radius: 8px;
    font-size: var(--font-size-base);
    font-weight: 600;
    cursor: pointer;
}

/* Application ID in success modal */
.application-id {
    text-align: center;
    padding: 15px;
    background: var(--bg-light);
    border-radius: 10px;
    margin-bottom: 15px;
}

.application-id .label {
    font-size: var(--font-size-sm);
    color: var(--text-light);
    margin-bottom: 5px;
}

.application-id .id {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--primary-green);
    font-family: monospace;
}

.timeline-info h4 {
    font-size: var(--font-size-sm);
    margin-bottom: 10px;
}

.timeline-steps {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.timeline-step {
    display: flex;
    gap: 10px;
    padding: 8px;
    background: var(--bg-light);
    border-radius: 6px;
}

.timeline-step .day {
    font-weight: 600;
    color: var(--primary-green);
    font-size: var(--font-size-sm);
    min-width: 50px;
}

.timeline-step .desc {
    font-size: var(--font-size-sm);
    color: var(--text-medium);
}

.modal-footer {
    padding: 15px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: center;
    gap: 10px;
}

/* ========== RISK ASSESSMENT CARDS ========== */
.main-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px 15px;
}

.page-title {
    text-align: center;
    margin-bottom: 20px;
}

.page-title h2 {
    color: var(--primary-green);
    font-size: var(--font-size-xl);
    margin-bottom: 5px;
}

.page-title p {
    color: var(--text-light);
    font-size: var(--font-size-sm);
}

.content-grid {
    display: grid;
    gap: 15px;
}

@media (min-width: 768px) {
    .content-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .risk-score-card {
        grid-column: span 2;
    }
}

.card {
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.card-header {
    padding: 12px 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--primary-green);
    color: white;
}

.card-header .icon {
    font-size: 1.1rem;
}

.card-header h3 {
    font-size: var(--font-size-sm);
    font-weight: 600;
}

.card-body {
    padding: 15px;
}

.risk-meter-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

@media (min-width: 768px) {
    .risk-meter-container {
        flex-direction: row;
        gap: 30px;
    }
}

.risk-meter {
    position: relative;
    width: 150px;
    height: 150px;
    flex-shrink: 0;
}

.risk-meter svg {
    width: 100%;
    height: 100%;
}

.risk-meter #riskMeterFill {
    transition: stroke-dashoffset 1.5s ease-out;
}

.score-value {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.score-value .score {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-green);
    line-height: 1;
}

.score-value .label {
    font-size: var(--font-size-xs);
    color: var(--text-light);
}

.score-details {
    flex: 1;
}

.score-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: var(--font-size-sm);
    font-weight: 600;
    margin-bottom: 10px;
    background: rgba(27, 94, 32, 0.1);
    color: var(--primary-green);
}

.score-details p {
    font-size: var(--font-size-sm);
    color: var(--text-medium);
    margin-bottom: 15px;
}

.score-factors {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.factor {
    display: flex;
    align-items: center;
    gap: 10px;
}

.factor-label {
    width: 100px;
    font-size: var(--font-size-xs);
    color: var(--text-medium);
}

.factor-bar {
    flex: 1;
    height: 6px;
    background: var(--bg-light);
    border-radius: 3px;
    overflow: hidden;
}

.factor-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-green), var(--accent-green));
    border-radius: 3px;
}

.factor-value {
    width: 35px;
    text-align: right;
    font-size: var(--font-size-xs);
    font-weight: 600;
    color: var(--primary-green);
}

.summary-list {
    display: flex;
    flex-direction: column;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-gray);
    font-size: var(--font-size-sm);
}

.summary-item:last-child {
    border-bottom: none;
}

.summary-item .label {
    color: var(--text-light);
}

.summary-item .value {
    font-weight: 600;
    color: var(--text-dark);
}

.doc-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.doc-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: rgba(27, 94, 32, 0.05);
    border-radius: 6px;
    font-size: var(--font-size-sm);
}

.doc-icon {
    font-size: 1rem;
}

.doc-name {
    flex: 1;
}

.doc-status {
    font-size: var(--font-size-xs);
    color: var(--primary-green);
    font-weight: 600;
}

.action-section {
    margin-top: 20px;
}

.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

@media (min-width: 768px) {
    .action-buttons {
        flex-direction: row;
        justify-content: center;
    }
}

.btn-outline {
    background: transparent;
    color: var(--text-medium);
    border: 2px solid var(--border-color);
}
