:root {
    --bg: #ffffff;
    --text: #333333;
    --muted: #666666;
    --primary: #4169E1;
    --surface: #ffffff;
    --surface-2: #f9f9fb;
    --border: #dddddd;
}

.dark {
    --bg: #0f1220;
    --text: #ffffff;
    --muted: #ffffff;
    --primary: #7aa2ff;
    --surface: #161a2b;
    --surface-2: #0f1220;
    --border: #2a2f45;
}

body {
    background-color: var(--bg);
    color: var(--text);
}

.container {
    background-color: transparent;
}

.upload-container { background-color: var(--surface); }
.feature-card { background-color: var(--surface); }
.hero-description, .feature, .feature-card p, .copyright { color: var(--muted); }
nav a, .nav-links a { color: var(--text); }
.primary-btn, .upload-btn { background-color: var(--primary); }
.upload-area { border-color: var(--border); }
.upload-area.dragover { background-color: rgba(65,105,225,0.06); }

/* Loader */
.loader {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
    padding: 12px 16px;
    border: 1px solid var(--border);
    background-color: var(--surface);
    border-radius: 8px;
}
.spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0,0,0,0.1);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
.loader-text { color: var(--muted); font-size: 14px; }
.dark .spinner { border-color: rgba(255,255,255,0.2); border-top-color: var(--primary); }
.dark .loader { background-color: var(--surface); border-color: var(--border); }

.theme-toggle {
    background: none;
    border: 1px solid var(--border);
    padding: 0.4rem 0.7rem;
    border-radius: 9999px;
    cursor: pointer;
    color: var(--text);
}
/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

.login-button {
    color: white;
    background-color: #4267e3;
    padding: 10px;
    border-radius: 15px;
    width: 80px;
}

.login-page-full {
    background-color: #f5f5f5;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;

}

.d {
    display: none;
}

.login-page {
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    width: 90%;
    max-width: 400px;
    padding: 2rem;
}

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

.login-page-header h1 {
    color: #333;
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.login-page-header p {
    color: #777;
    font-size: 0.9rem;
}

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

.form-field label {
    display: block;
    margin-bottom: 0.5rem;
    color: #555;
    font-size: 0.9rem;
}

.form-field input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-field input:focus {
    outline: none;
    border-color: #4A90E2;
}

.remember-forgot-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
}

.remember-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #555;
}

.forgot-option a {
    color: #4A90E2;
    text-decoration: none;
}

.forgot-option a:hover {
    text-decoration: underline;
}

.login-submit-button {
    width: 100%;
    padding: 0.75rem;
    background-color: #4A90E2;
    border: none;
    border-radius: 4px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
}

.login-submit-button:hover {
    background-color: #3A80D2;
}

.register-account-link {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: #555;
}

.register-account-link a {
    color: #4A90E2;
    text-decoration: none;
    font-weight: 600;
}

.register-account-link a:hover {
    text-decoration: underline;
}

@media (max-width: 480px) {
    .login-page {
        width: 95%;
        padding: 1.5rem;
    }
}

.register-page {
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    width: 90%;
    max-width: 500px;
    padding: 2rem;
}

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

.register-page-header h1 {
    color: #333;
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.register-page-header p {
    color: #777;
    font-size: 0.9rem;
}

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

.form-row-group {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.form-row-group .form-field {
    flex: 1;
    margin-bottom: 0;
}

.form-field label {
    display: block;
    margin-bottom: 0.5rem;
    color: #555;
    font-size: 0.9rem;
}

.form-field input,
.form-field select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-field input:focus,
.form-field select:focus {
    outline: none;
    border-color: #4A90E2;
}

.terms-agreement {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.terms-agreement input {
    margin-top: 0.25rem;
}

.terms-agreement label {
    color: #555;
    font-size: 0.85rem;
    line-height: 1.4;
}

.terms-agreement a {
    color: #4A90E2;
    text-decoration: none;
}

.terms-agreement a:hover {
    text-decoration: underline;
}

.register-submit-button {
    width: 100%;
    padding: 0.75rem;
    background-color: #4A90E2;
    border: none;
    border-radius: 4px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
}

.register-submit-button:hover {
    background-color: #3A80D2;
}

.existing-account-link {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: #555;
}

.existing-account-link a {
    color: #4A90E2;
    text-decoration: none;
    font-weight: 600;
}

/* Navigation Styles */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 5%;
    position: relative;
}

.nav-logo {
    display: flex;
    align-items: center;
    font-size: 1.2rem;
    font-weight: 600;
    gap: 0.5rem;
    color: var(--text);
    text-decoration: none;
    z-index: 10;
}

.nav-logo svg {
    color: var(--primary);
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text);
}

.upload-btn {
    background-color: #4169E1;
    color: white;
    padding: 0.7rem 1.2rem;
    border-radius: 9999px;
    text-decoration: none;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Hero Section Styles */
.hero {
    text-align: center;
    padding: 5rem 1rem;
    max-width: 800px;
    margin: 0 auto;
}

.badge {
    background-color: #E6EEFF;
    color: var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    display: inline-block;
    margin-bottom: 2rem;
}

.hero-title {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.hero-title span {
    color: var(--primary);
    display: block;
}

.hero-description {
    color: var(--muted);
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 4rem;
}

.primary-btn {
    background-color: #4169E1;
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 9999px;
    text-decoration: none;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.secondary-btn {
    color: #333;
    padding: 0.8rem 1.5rem;
    border-radius: 9999px;
    text-decoration: none;
    font-weight: 500;
}

/* Features Section */
.features {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    max-width: 900px;
    margin: 0 auto;
}

.feature {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--muted);
}

.feature svg {
    color: var(--primary);
}

/* Mobile menu button */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 10;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .hero-title {
        font-size: 3rem;
    }

    /* Hide nav links by default on mobile */
    .nav-links {
        display: none;
        position: fixed;
        top: 0;
        right: 0;
        height: 100vh;
        width: 80%;
        max-width: 360px;
        background-color: var(--surface);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        z-index: 20;
        gap: 2rem;
        box-shadow: -8px 0 24px rgba(0,0,0,0.15);
        transform: translateX(100%);
        transition: transform 0.25s ease-in-out;
    }

    /* Show nav links when toggled */
    .nav-links.show {
        display: flex;
        transform: translateX(0%);
    }

    /* Show mobile menu button */
    .mobile-menu-btn {
        display: block;
    }

    .buttons {
        flex-direction: column;
        align-items: center;
    }

    .features {
        flex-direction: column;
        align-items: center;
    }

    /* Adjust padding for mobile */
    .hero {
        padding: 3rem 1rem;
    }

    .hero-description {
        font-size: 1rem;
    }
}

/* Overlay for mobile menu */
.nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.35);
    z-index: 15;
    opacity: 0;
    transition: opacity 0.2s ease-out;
}
.nav-overlay.show { opacity: 1; }
.dark .nav-links { background-color: var(--surface); }

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

body {
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.header {
    text-align: center;
    margin-bottom: 40px;
}

.header h1 {
    font-size: 32px;
    color: var(--text);
    margin-bottom: 16px;
    font-weight: 600;
}

.header p {
    font-size: 16px;
    color: var(--muted);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

.features {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 60px;
}

.feature-card {
    background-color: var(--surface);
    border-radius: 8px;
    padding: 30px;
    width: 250px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.icon-wrapper {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.icon-document {
    background-color: #e8eeff;
}

.icon-chart {
    background-color: #e8eeff;
}

.icon-check {
    background-color: #e8eeff;
}

.icon-warning {
    background-color: #e8eeff;
}

.feature-card h3 {
    font-size: 18px;
    margin-bottom: 12px;
    color: var(--text);
    font-weight: 600;
}

.feature-card p {
    font-size: 14px;
    color: var(--muted);
    line-height: 1.5;
}

.cta-section {
    text-align: center;
    margin-bottom: 50px;
}

.cta-section h2 {
    font-size: 28px;
    margin-bottom: 16px;
    color: var(--text);
    font-weight: 600;
}

.cta-section p {
    font-size: 16px;
    color: var(--muted);
    max-width: 700px;
    margin: 0 auto 40px;
    line-height: 1.6;
}

.upload-container {
    background-color: var(--surface);
    max-width: 700px;
    margin: 0 auto;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.upload-container h3 {
    text-align: center;
    font-size: 22px;
    margin-bottom: 12px;
    color: var(--text);
    font-weight: 600;
}

.upload-container p {
    text-align: center;
    font-size: 14px;
    color: var(--muted);
    margin-bottom: 30px;
}

.upload-area {
    border: 2px dashed var(--border);
    border-radius: 8px;
    padding: 40px;
    text-align: center;
    cursor: pointer;
}

.inputbox {
    height: 50vh;
    width: 100%;
}

.upload-icon {
    color: var(--primary);
    margin-bottom: 20px;
    font-size: 24px;
}

.upload-text {
    font-size: 14px;
    color: var(--primary);
    margin-bottom: 5px;
}

.upload-format {
    font-size: 12px;
    color: var(--muted);
}


/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

body {
    background-color: #ffffff;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Hero Section */
.hero-section {
    background-color: #f5f7ff;
    min-height: 70vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 3rem 1rem;
}

.hero-title {
    font-size: 2.25rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.1rem;
    font-weight: 400;
    color: #5a5a6e;
    max-width: 700px;
    line-height: 1.6;
    margin-bottom: 2.5rem;
}

.get-started-btn {
    background-color: #4267e3;
    color: white;
    padding: 0.75rem 1.75rem;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    transition: background-color 0.3s;
}

.get-started-btn:hover {
    background-color: #3658ce;
}

.arrow-icon {
    margin-left: 0.5rem;
}

/* Footer */
.footer {
    margin-top: auto;
    padding: 2rem 1rem;
    text-align: center;
    background-color: #ffffff;
}

.footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    font-size: 1.2rem;
    color: #333;
    font-weight: 500;
}

.footer-logo svg {
    margin-right: 0.5rem;
}

.copyright {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.download-link {
    color: #4267e3;
    text-decoration: none;
    font-size: 0.9rem;
}

/* Update these CSS rules */
.upload-container {
    background-color: #fff;
    max-width: 700px;
    margin: 0 auto;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.upload-area {
    border: 2px dashed #ddd;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    margin-bottom: 20px;
}

.upload-area.dragover {
    border-color: #4a7dfc;
    background-color: #f0f5ff;
}

.inputbox {
    height: 200px;
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    resize: vertical;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;
    overflow-y: auto;
}

/* Make the result area more visible */
#result {
    margin-top: 30px;
    padding: 24px;
    background-color: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    min-height: 64px;
    white-space: pre-wrap;
    word-break: break-word;
    font-family: inherit;
    color: var(--text);
}

/* Score badge styling */
.score-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 9999px;
    font-weight: 600;
    margin-bottom: 12px;
}
.score-good { background-color: rgba(46, 204, 113, 0.15); color: #2ecc71; }
.score-mid  { background-color: rgba(241, 196, 15, 0.15); color: #f1c40f; }
.score-bad  { background-color: rgba(231, 76, 60, 0.15); color: #e74c3c; }
.dark .score-good { color: #2ecc71; }
.dark .score-mid  { color: #f1c40f; }
.dark .score-bad  { color: #e74c3c; }



@media (max-width: 768px) {
    .nav-links.show {
        display: flex;
        background-color: white;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    }

    .nav-links a,
    .nav-links button {
        font-size: 1.2rem;
        padding: 1rem;
    }
}

.download-link:hover {
    text-decoration: underline;
}

/* ---- Theme overrides to ensure toggle updates key UI ---- */
.dark body { background-color: var(--bg); color: var(--text); }
.dark nav { background-color: var(--surface); border-bottom: 1px solid var(--border); }
.dark .nav-logo { color: var(--text); }
.dark .nav-logo svg { color: var(--primary); }
.dark .nav-links a { color: var(--text); }
.dark .login-button { background-color: var(--primary); color: #fff; }
.dark .buttons .primary-btn { background-color: var(--primary); }
.dark .hero-description, 
.dark .feature, 
.dark .feature-card p, 
.dark .header p, 
.dark .copyright { color: var(--muted); }
.dark .feature-card, 
.dark .upload-container, 
.dark .login-page, 
.dark .register-page { background-color: var(--surface); }
.dark .feature svg { color: var(--primary); }
.dark .hero-title span { color: var(--primary); }
.dark .upload-area { border-color: var(--border); }
.dark .upload-icon, 
.dark .upload-text, 
.dark .download-link { color: var(--primary); }
.dark .footer { background-color: var(--surface); }
.dark #result { background-color: var(--surface); }
.dark .form-field label { color: var(--muted); }
.dark .form-field input, 
.dark .form-field select { background-color: var(--surface); color: var(--text); border: 1px solid var(--border); }
.dark .remember-option, 
.dark .existing-account-link, 
.dark .register-account-link { color: var(--muted); }
/* Ensure key resume headings are white in dark mode */
.dark .hero-title,
.dark .header h1,
.dark .upload-container h3,
.dark .feature-card h3 { color: #ffffff; }