/* ===== Humanora AI — Clean Professional Theme ===== */
:root {
    --bg: #F4F5F7;
    --bg-card: #ffffff;
    --bg-input: #F4F5F7;
    --bg-header: rgba(255,255,255,0.95);
    --bg-tabs: #f9fafb;
    --text: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --border: #e2e8f0;
    --border-focus: #4F6EF7;
    --accent: #4F6EF7;
    --accent-light: #eef2ff;
    --accent-hover: #3b5de7;
    --success: #16a34a;
    --warning: #ea580c;
    --danger: #dc2626;
    --radius: 12px;
    --radius-sm: 8px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
    --shadow: 0 2px 8px rgba(0,0,0,0.07);
    --shadow-lg: 0 4px 16px rgba(0,0,0,0.1);
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --mono: 'JetBrains Mono', 'Consolas', monospace;
}

/* Dark Mode */
.dark-mode {
    --bg: #0f172a;
    --bg-card: #1e293b;
    --bg-input: #1e293b;
    --bg-header: rgba(15,23,42,0.95);
    --bg-tabs: #162032;
    --text: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border: #334155;
    --accent: #6384FF;
    --accent-light: rgba(99,132,255,0.12);
    --accent-hover: #7c9aff;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
    --shadow: 0 2px 8px rgba(0,0,0,0.3);
    --shadow-lg: 0 4px 16px rgba(0,0,0,0.4);
}

*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    transition: background 0.3s, color 0.3s;
}
a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; color: inherit; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }

/* ===== Header ===== */
.header {
    position: sticky; top: 0; z-index: 100;
    padding: 12px 0;
    background: var(--bg-header);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--border);
    transition: background 0.3s, border-color 0.3s;
}
.header .container { display: flex; align-items: center; justify-content: space-between; }
.logo { display: flex; align-items: center; gap: 10px; }
.logo-icon { width: 32px; height: 32px; }
.logo-text { font-size: 1.15rem; font-weight: 700; letter-spacing: -0.3px; color: var(--text); }
.logo-accent { color: var(--accent); }
.nav { display: flex; gap: 28px; }
.nav-link { font-size: 0.88rem; font-weight: 500; color: var(--text-secondary); transition: color 0.2s; }
.nav-link:hover { color: var(--accent); }
.header-actions { display: flex; gap: 8px; }

/* ===== Hero (Compact) ===== */
.hero { padding: 48px 0 24px; text-align: center; }
.hero-badge { display: none; }
.hero-title {
    font-size: clamp(1.6rem, 3.5vw, 2.2rem); font-weight: 800;
    line-height: 1.2; letter-spacing: -0.5px; margin-bottom: 10px; color: var(--text);
}
.gradient-text { color: var(--accent); background: none; -webkit-text-fill-color: var(--accent); }
.hero-subtitle { font-size: 0.95rem; color: var(--text-secondary); max-width: 520px; margin: 0 auto 20px; }
.hero-cta, .hero-stats { display: none; }
.badge-dot { display: none; }

/* ===== Buttons ===== */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 10px 22px; border-radius: var(--radius-sm);
    font-size: 0.9rem; font-weight: 600; transition: all 0.2s;
}
.btn svg { width: 16px; height: 16px; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost { background: var(--bg-card); border: 1px solid var(--border); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* ===== Sections ===== */
.section-header { text-align: center; margin-bottom: 40px; }
.section-tag {
    display: inline-block; padding: 4px 14px; border-radius: 100px;
    background: var(--accent-light); font-size: 0.75rem; font-weight: 600;
    color: var(--accent); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 12px;
}
.section-title { font-size: clamp(1.4rem, 3vw, 1.9rem); font-weight: 700; letter-spacing: -0.5px; margin-bottom: 8px; color: var(--text); }
.section-desc { color: var(--text-secondary); font-size: 0.92rem; max-width: 480px; margin: 0 auto; }

/* ===== Features ===== */
.features { padding: 60px 0; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.feature-card {
    padding: 28px; background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); transition: box-shadow 0.2s;
}
.feature-card:hover { box-shadow: var(--shadow); }
.feature-card.featured { border-color: var(--accent); }
.feature-badge {
    position: absolute; top: -10px; right: 20px; padding: 3px 12px; border-radius: 100px;
    background: var(--accent); font-size: 0.7rem; font-weight: 700; color: #fff;
}
.feature-icon {
    width: 44px; height: 44px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.feature-icon svg { width: 22px; height: 22px; }
.feature-icon-detect { background: var(--accent-light); color: var(--accent); }
.feature-icon-humanize { background: #e3f2fd; color: #1976d2; }
.feature-icon-fix { background: #fff3e0; color: #f57c00; }
.feature-card h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 8px; }
.feature-card p { color: var(--text-secondary); font-size: 0.85rem; margin-bottom: 14px; }
.feature-list { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.feature-list li { display: flex; align-items: center; gap: 6px; font-size: 0.82rem; color: var(--text-secondary); }
.feature-list li::before { content: '✓'; color: var(--accent); font-weight: 700; font-size: 0.75rem; }

/* ===== Tool Section ===== */
.tool-section { padding: 0 0 60px; }
.tool-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden;
}
.tool-tabs {
    display: flex; position: relative; border-bottom: 1px solid var(--border);
    background: #fafbfc;
}
.tool-tab {
    flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px;
    padding: 14px; font-size: 0.85rem; font-weight: 600;
    color: var(--text-secondary); transition: color 0.2s; position: relative; z-index: 1;
}
.tool-tab svg { width: 16px; height: 16px; }
.tool-tab.active { color: var(--accent); }
.tab-indicator {
    position: absolute; bottom: 0; height: 2px;
    background: var(--accent); border-radius: 2px 2px 0 0;
    transition: left 0.3s ease, width 0.3s ease;
}
.tool-body { padding: 24px; }

/* ===== Input Area ===== */
.input-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.input-label { display: flex; align-items: center; gap: 6px; font-size: 0.85rem; font-weight: 600; color: var(--text); }
.input-label svg { width: 14px; height: 14px; color: var(--accent); }
.input-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.input-action-btn {
    display: flex; align-items: center; gap: 5px;
    padding: 6px 12px; border-radius: 6px;
    font-size: 0.78rem; font-weight: 500;
    background: var(--bg-input); border: 1px solid var(--border); transition: all 0.2s;
}
.input-action-btn svg { width: 13px; height: 13px; }
.input-action-btn:hover { border-color: var(--accent); color: var(--accent); }
.text-input {
    width: 100%; min-height: 180px; padding: 16px;
    background: var(--bg-input); border: 1px solid var(--border); border-radius: var(--radius-sm);
    color: var(--text); font-family: var(--font); font-size: 0.92rem; line-height: 1.7;
    resize: vertical; outline: none; transition: border-color 0.2s;
}
.text-input::placeholder { color: var(--text-muted); }
.text-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(73,149,103,0.1); }
.input-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; flex-wrap: wrap; gap: 10px; }
.word-count { font-size: 0.78rem; color: var(--text-muted); font-family: var(--mono); }

/* ===== Analyze Button ===== */
.btn-analyze {
    padding: 10px 28px; border-radius: var(--radius-sm);
    background: var(--accent); color: #fff; font-weight: 600; font-size: 0.9rem;
    transition: all 0.2s;
}
.btn-analyze:hover { background: var(--accent-hover); }
.btn-analyze .btn-loading { display: none; }
.btn-analyze.loading .btn-text { display: none; }
.btn-analyze.loading .btn-loading { display: flex; align-items: center; gap: 8px; }
.spinner {
    width: 16px; height: 16px; border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff; border-radius: 50%; animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== Results ===== */
.results-area { margin-top: 24px; }
.result-panel { animation: fadeIn 0.4s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.result-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.result-header h3 { font-size: 1.05rem; font-weight: 700; }
.result-actions { display: flex; gap: 6px; }
.btn-copy-result {
    display: flex; align-items: center; gap: 5px;
    padding: 6px 14px; border-radius: 6px;
    background: var(--bg-input); border: 1px solid var(--border);
    font-size: 0.78rem; font-weight: 500; transition: all 0.2s;
}
.btn-copy-result svg { width: 13px; height: 13px; }
.btn-copy-result:hover { border-color: var(--accent); }

/* ===== Score Display ===== */
.dual-score { display: flex; justify-content: center; gap: 40px; margin-bottom: 12px; flex-wrap: wrap; }
.score-display { text-align: center; }
.dual-score .score-display { margin-bottom: 0; }
.score-ring { width: 120px; height: 120px; margin: 0 auto 10px; position: relative; }
.score-ring svg { width: 100%; height: 100%; }
.score-value {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    font-family: var(--mono); font-size: 1.6rem; font-weight: 800;
}
.score-percent { font-size: 0.85rem; opacity: 0.5; }
.score-label { font-size: 0.8rem; color: var(--text-secondary); }
.score-verdict { text-align: center; font-size: 0.95rem; font-weight: 600; margin-bottom: 20px; padding: 10px; border-radius: var(--radius-sm); background: var(--bg-input); }

/* ===== Metrics ===== */
.metrics-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin-bottom: 24px; }
.metric-card {
    padding: 16px; background: var(--bg-input); border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.metric-label { font-size: 0.75rem; color: var(--text-secondary); margin-bottom: 6px; }
.metric-value { font-size: 1rem; font-weight: 700; font-family: var(--mono); margin-bottom: 8px; }
.metric-bar { height: 4px; background: var(--border); border-radius: 2px; overflow: hidden; }
.metric-fill { height: 100%; border-radius: 2px; transition: width 0.8s ease; width: 0; }
#fill-perplexity { background: var(--accent); }
#fill-burstiness { background: #1976d2; }
#fill-vocabulary { background: #2e7d32; }
#fill-predictability { background: #f57c00; }

/* ===== Sentence Analysis ===== */
.sentence-analysis h4 { font-size: 0.95rem; font-weight: 700; margin-bottom: 12px; }
.sentence-list { display: flex; flex-direction: column; gap: 6px; max-height: 350px; overflow-y: auto; }
.sentence-item {
    display: flex; align-items: flex-start; gap: 10px;
    padding: 10px 14px; border-radius: var(--radius-sm);
    background: var(--bg-input); border: 1px solid var(--border); font-size: 0.85rem; line-height: 1.5;
}
.sentence-tag {
    flex-shrink: 0; padding: 2px 8px; border-radius: 4px;
    font-size: 0.68rem; font-weight: 700; text-transform: uppercase; white-space: nowrap;
}
.sentence-tag.ai { background: #ffebee; color: var(--danger); }
.sentence-tag.human { background: var(--accent-light); color: var(--accent); }
.sentence-tag.mixed { background: #fff8e1; color: #f57c00; }
.sentence-legend { display: flex; gap: 16px; margin-bottom: 12px; flex-wrap: wrap; }
.legend-item { display: flex; align-items: center; gap: 5px; font-size: 0.75rem; color: var(--text-secondary); }
.legend-dot { width: 8px; height: 8px; border-radius: 2px; }
.legend-dot.ai { background: var(--danger); }
.legend-dot.human { background: var(--accent); }
.legend-dot.mixed { background: #f57c00; }

/* ===== Humanize Results ===== */
.humanize-comparison { margin-bottom: 20px; }
.comparison-header { display: flex; align-items: center; justify-content: center; gap: 12px; margin-bottom: 16px; }
.comparison-badge { padding: 4px 14px; border-radius: 6px; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; }
.comparison-badge.before { background: #ffebee; color: var(--danger); }
.comparison-badge.after { background: var(--accent-light); color: var(--accent); }
.arrow-icon { width: 18px; height: 18px; color: var(--text-muted); }
.changes-summary { display: flex; justify-content: center; gap: 32px; flex-wrap: wrap; }
.change-stat { text-align: center; }
.change-num { display: block; font-size: 1.3rem; font-weight: 800; font-family: var(--mono); color: var(--accent); }
.change-label { font-size: 0.75rem; color: var(--text-secondary); }
.humanized-output {
    padding: 20px; background: var(--bg-input); border: 1px solid var(--border);
    border-radius: var(--radius-sm); font-size: 0.9rem; line-height: 1.8; white-space: pre-wrap;
}
.humanized-output .changed { background: var(--accent-light); border-radius: 2px; padding: 1px 2px; }

/* ===== Plagiarism Results ===== */
.plagiarism-stats { display: flex; justify-content: center; align-items: center; gap: 36px; margin-bottom: 24px; flex-wrap: wrap; }
.plag-stat { text-align: center; }
.plag-stat-ring { width: 80px; height: 80px; position: relative; margin: 0 auto 6px; }
.plag-stat-ring svg { width: 100%; height: 100%; }
.plag-stat-value {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    font-family: var(--mono); font-size: 1rem; font-weight: 800;
}
.plag-stat-num { display: block; font-size: 1.6rem; font-weight: 800; font-family: var(--mono); color: var(--accent); }
.plag-stat-label { font-size: 0.75rem; color: var(--text-secondary); }
.plagiarism-output {
    padding: 20px; background: var(--bg-input); border: 1px solid var(--border);
    border-radius: var(--radius-sm); font-size: 0.9rem; line-height: 1.8; white-space: pre-wrap;
}
.plagiarism-output .paraphrased { background: #e3f2fd; border-radius: 2px; padding: 1px 2px; }

/* ===== Controls Panel ===== */
.controls-panel {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px;
    padding: 20px 24px; border-bottom: 1px solid var(--border); background: #fafbfc;
}
.control-group { display: flex; flex-direction: column; gap: 8px; }
.control-label { font-size: 0.78rem; font-weight: 600; color: var(--text-secondary); display: flex; align-items: center; justify-content: space-between; }
.control-value { color: var(--accent); font-family: var(--mono); }
.rewrite-levels, .tone-toggle { display: flex; gap: 4px; }
.level-btn, .tone-btn {
    flex: 1; padding: 6px 10px; border-radius: 6px; font-size: 0.75rem; font-weight: 600;
    background: var(--bg-input); border: 1px solid var(--border); transition: all 0.2s; text-align: center;
}
.level-btn:hover, .tone-btn:hover { border-color: var(--accent); }
.level-btn.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.tone-btn.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.range-slider {
    -webkit-appearance: none; appearance: none; width: 100%; height: 4px;
    border-radius: 2px; background: var(--border); outline: none;
}
.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none; width: 16px; height: 16px;
    border-radius: 50%; background: var(--accent); cursor: pointer;
}
.range-slider::-moz-range-thumb {
    width: 16px; height: 16px; border-radius: 50%; border: none;
    background: var(--accent); cursor: pointer;
}
.range-labels { display: flex; justify-content: space-between; font-size: 0.68rem; color: var(--text-muted); }

/* ===== Source URLs ===== */
.source-urls-section { margin-bottom: 16px; }
.source-urls-section h4 { font-size: 0.95rem; font-weight: 700; margin-bottom: 10px; }
.source-urls-list { display: flex; flex-direction: column; gap: 8px; }
.source-url-card {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 14px; border-radius: var(--radius-sm);
    background: var(--bg-input); border: 1px solid var(--border); transition: border-color 0.2s;
}
.source-url-card:hover { border-color: #f57c00; }
.source-url-icon { width: 28px; height: 28px; border-radius: 6px; background: #fff3e0; color: #f57c00; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.source-url-icon svg { width: 14px; height: 14px; }
.source-url-info { flex: 1; min-width: 0; }
.source-url-title { font-size: 0.82rem; font-weight: 600; margin-bottom: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.source-url-link { font-size: 0.72rem; color: var(--accent); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.source-url-match { font-size: 0.72rem; font-weight: 700; color: #f57c00; font-family: var(--mono); white-space: nowrap; }

/* ===== References ===== */
.ref-desc { font-size: 0.85rem; color: var(--text-secondary); margin-bottom: 16px; }
.references-list { display: flex; flex-direction: column; gap: 10px; }
.reference-card { padding: 14px 16px; border-radius: var(--radius-sm); background: var(--bg-input); border: 1px solid var(--border); transition: border-color 0.2s; }
.reference-card:hover { border-color: var(--accent); }
.reference-type { display: inline-block; padding: 2px 8px; border-radius: 4px; font-size: 0.65rem; font-weight: 700; text-transform: uppercase; margin-bottom: 6px; }
.reference-type.paper { background: var(--accent-light); color: var(--accent); }
.reference-type.article { background: #e3f2fd; color: #1976d2; }
.reference-type.book { background: #fff3e0; color: #f57c00; }
.reference-title { font-size: 0.88rem; font-weight: 700; margin-bottom: 3px; }
.reference-authors { font-size: 0.78rem; color: var(--text-secondary); margin-bottom: 4px; }
.reference-link { font-size: 0.75rem; color: var(--accent); word-break: break-all; }
.reference-link:hover { text-decoration: underline; }

/* ===== How It Works ===== */
.how-it-works { padding: 60px 0; }
.steps-grid { display: flex; align-items: center; justify-content: center; gap: 0; flex-wrap: wrap; }
.step-card {
    flex: 1; min-width: 220px; max-width: 300px; padding: 28px; text-align: center;
    background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
}
.step-card:hover { box-shadow: var(--shadow); }
.step-number { font-size: 2rem; font-weight: 900; font-family: var(--mono); color: var(--accent); margin-bottom: 12px; }
.step-icon { width: 40px; height: 40px; margin: 0 auto 12px; color: var(--accent); }
.step-icon svg { width: 100%; height: 100%; }
.step-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 6px; }
.step-card p { font-size: 0.82rem; color: var(--text-secondary); }
.step-connector { width: 50px; flex-shrink: 0; color: var(--text-muted); }

/* ===== Footer ===== */
.footer { padding: 48px 0 24px; border-top: 1px solid var(--border); background: #fff; }
.footer-content { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 32px; }
.footer-desc { color: var(--text-secondary); font-size: 0.85rem; margin-top: 10px; max-width: 280px; }
.footer-links { display: flex; flex-direction: column; gap: 8px; }
.footer-links h4 { font-size: 0.85rem; font-weight: 700; margin-bottom: 4px; }
.footer-links a { font-size: 0.82rem; color: var(--text-secondary); transition: color 0.2s; }
.footer-links a:hover { color: var(--accent); }
.footer-bottom { text-align: center; padding-top: 20px; border-top: 1px solid var(--border); }
.footer-bottom p { font-size: 0.78rem; color: var(--text-muted); }

/* ===== Why Section (Qualities) ===== */
.why-section { padding: 60px 0; }
.qualities-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.quality-card {
    display: flex; align-items: flex-start; gap: 14px;
    padding: 22px; background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); transition: box-shadow 0.2s;
}
.quality-card:hover { box-shadow: var(--shadow); }
.quality-icon {
    width: 40px; height: 40px; min-width: 40px; border-radius: 10px;
    background: var(--accent-light); color: var(--accent);
    display: flex; align-items: center; justify-content: center;
}
.quality-icon i { font-size: 1.1rem; }
.quality-card h3 { font-size: 0.95rem; font-weight: 700; margin-bottom: 4px; }
.quality-card p { font-size: 0.82rem; color: var(--text-secondary); line-height: 1.5; }

/* ===== Audience Section ===== */
.audience-section { padding: 60px 0; }
.audience-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.audience-card {
    padding: 24px; background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); text-align: center; transition: box-shadow 0.2s;
}
.audience-card:hover { box-shadow: var(--shadow); }
.audience-icon {
    width: 50px; height: 50px; border-radius: 12px;
    background: var(--accent-light); color: var(--accent);
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 12px; font-size: 1.4rem;
}
.audience-card h3 { font-size: 0.95rem; font-weight: 700; margin-bottom: 6px; }
.audience-card p { font-size: 0.82rem; color: var(--text-secondary); line-height: 1.5; }

/* ===== Stats Banner ===== */
.stats-banner { padding: 40px 0; }
.stats-row {
    display: flex; justify-content: space-around; align-items: center; flex-wrap: wrap; gap: 24px;
    padding: 32px; background: var(--accent); border-radius: var(--radius); color: #fff;
}
.stat-item { text-align: center; }
.stat-num { font-size: 2rem; font-weight: 800; font-family: var(--mono); }
.stat-plus { font-size: 1.4rem; font-weight: 700; }
.stat-text { display: block; font-size: 0.8rem; font-weight: 500; opacity: 0.85; margin-top: 2px; }

/* ===== FAQ ===== */
.faq-section { padding: 60px 0; }
.faq-list { max-width: 720px; margin: 0 auto; display: flex; flex-direction: column; gap: 8px; }
.faq-item {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-sm); overflow: hidden; transition: border-color 0.2s;
}
.faq-item:hover { border-color: var(--accent); }
.faq-question {
    width: 100%; display: flex; justify-content: space-between; align-items: center;
    padding: 16px 20px; font-size: 0.9rem; font-weight: 600; text-align: left;
    color: var(--text); background: none; border: none; cursor: pointer;
    font-family: var(--font);
}
.faq-question svg { width: 18px; height: 18px; min-width: 18px; color: var(--text-muted); transition: transform 0.3s; }
.faq-item.open .faq-question svg { transform: rotate(180deg); }
.faq-answer {
    max-height: 0; overflow: hidden; transition: max-height 0.3s ease, padding 0.3s ease;
}
.faq-item.open .faq-answer { max-height: 300px; padding: 0 20px 16px; }
.faq-answer p { font-size: 0.85rem; color: var(--text-secondary); line-height: 1.7; }

/* ===== Toast definition removed from here (Duplicate) ===== */

/* ===== Scrollbar ===== */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #ccc; border-radius: 3px; }

/* ===== Hidden elements from old design ===== */
.bg-animation { display: none; }

/* ===== Theme Toggle ===== */
.theme-toggle {
    width: 38px; height: 38px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    background: var(--bg-input); border: 1px solid var(--border);
    transition: all 0.2s; color: var(--text-secondary);
}
.theme-toggle:hover { border-color: var(--accent); color: var(--accent); }
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .icon-moon { display: none; }
.dark-mode .theme-toggle .icon-sun { display: none; }
.dark-mode .theme-toggle .icon-moon { display: block; }

/* Dark mode tweaks */
.dark-mode .tool-tabs { background: var(--bg-tabs); }
.dark-mode .controls-panel { background: var(--bg-tabs); }
.dark-mode .footer { background: var(--bg-card); }
.dark-mode .score-ring circle:first-child { stroke: var(--border); }
.dark-mode .plag-stat-ring circle:first-child { stroke: var(--border); }
.dark-mode .metric-bar { background: var(--border); }

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .nav { display: none; }
    .hero { padding: 32px 0 16px; }
    .tool-tab span { display: none; }
    .tool-body { padding: 16px; }
    .features-grid { grid-template-columns: 1fr; }
    .footer-content { grid-template-columns: 1fr; gap: 24px; }
    .steps-grid { flex-direction: column; }
    .step-connector { display: none; }
    .metrics-grid { grid-template-columns: 1fr 1fr; }
    .plagiarism-stats { gap: 20px; }
    .input-footer { flex-direction: column; align-items: stretch; }
}
/* ===== Auth Modal ===== */
.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5); backdrop-filter: blur(4px);
    display: none; align-items: center; justify-content: center; z-index: 2000;
}
.modal-overlay.show { display: flex; }
.auth-modal {
    width: 100%; max-width: 400px; background: var(--bg-card);
    border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow-lg);
    position: relative; animation: modalSlide 0.3s ease;
}
@keyframes modalSlide { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.modal-close {
    position: absolute; top: 16px; right: 16px;
    background: none; border: none; font-size: 1.2rem; color: var(--text-muted);
    cursor: pointer; transition: color 0.2s;
}
.modal-close:hover { color: var(--text); }
.auth-tabs { display: flex; gap: 12px; margin-bottom: 24px; border-bottom: 1px solid var(--border); }
.auth-tab {
    padding: 10px 0; font-size: 0.95rem; font-weight: 600; color: var(--text-muted);
    background: none; border: none; cursor: pointer; position: relative; flex: 1;
}
.auth-tab.active { color: var(--accent); }
.auth-tab.active::after {
    content: ''; position: absolute; bottom: -1px; left: 0; width: 100%;
    height: 2px; background: var(--accent);
}
.auth-form { display: flex; flex-direction: column; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-size: 0.85rem; font-weight: 600; color: var(--text-secondary); }
.form-footer { display: flex; justify-content: flex-end; margin-top: 4px; }
.btn-link { font-size: 0.75rem; color: var(--accent); background: none; border: none; cursor: pointer; padding: 0; font-weight: 600; }
.btn-link:hover { text-decoration: underline; }
.input-with-icon { position: relative; width: 100%; }
.input-with-icon i:first-child {
    position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
    font-size: 0.9rem; color: var(--text-muted); pointer-events: none; z-index: 5;
}
.btn-eye {
    position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
    background: none; border: none; color: var(--text-muted); cursor: pointer;
    font-size: 1.1rem; padding: 10px; display: flex; align-items: center; justify-content: center;
    z-index: 10; transition: color 0.2s;
}
.toast {
    position: fixed; bottom: 20px; right: 20px;
    background: #333; color: #fff; padding: 16px 20px; border-radius: 8px;
    display: flex; align-items: flex-start; gap: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.4); z-index: 9999;
    opacity: 0; pointer-events: none; transition: all 0.4s ease;
    min-width: 280px; max-width: 350px;
    transform: translateX(50px);
}
.toast.show { opacity: 1; transform: translateX(0); }
.toast-icon { font-size: 1.5rem; margin-top: 2px; }
.toast-content { display: flex; flex-direction: column; gap: 4px; }
.toast-title { font-weight: 800; font-size: 1rem; text-transform: uppercase; letter-spacing: 0.5px; }
.toast-message { font-size: 0.85rem; font-weight: 500; line-height: 1.4; opacity: 0.9; }

/* Type Colors */
.toast.error { background: #d32f2f; border-left: 6px solid #8b0000; }
.toast.success { background: #2e7d32; border-left: 6px solid #1b5e20; }
.toast.info { background: #1976d2; border-left: 6px solid #0d47a1; }
.btn-eye:hover { color: var(--accent); }
.input-with-icon input {
    width: 100%; padding: 12px 42px; border: 1px solid var(--border);
    border-radius: var(--radius-sm); background: var(--bg); color: var(--text);
    font-family: var(--font); font-size: 0.95rem; transition: all 0.2s;
}
.input-with-icon input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-light); }
.input-with-icon input:focus { border-color: var(--accent); outline: none; }
.btn-full { width: 100%; justify-content: center; height: 42px; font-weight: 700; }
.auth-divider {
    display: flex; align-items: center; gap: 12px; margin: 20px 0;
    color: var(--text-muted); font-size: 0.75rem; font-weight: 600;
}
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.btn-google { display: flex; align-items: center; gap: 10px; border: 1px solid var(--border) !important; }
.btn-google img { width: 18px; height: 18px; }

/* User profile display in header */
.user-profile { display: flex; align-items: center; gap: 10px; }
.user-info { text-align: right; line-height: 1.2; }
.user-name { display: block; font-size: 0.85rem; font-weight: 700; color: var(--text); }
.btn-logout { font-size: 0.75rem; color: var(--text-muted); background: none; border: none; padding: 0; cursor: pointer; text-decoration: underline; }
.btn-logout:hover { color: #f44336; }
