:root {
    /* Pastel / Anthropic-like Theme */
    --bg-color: #f9f8f6;
    /* Soft warm beige/white */
    --text-color: #333333;
    /* Dark charcoal for readability */
    --accent-color: #da7756;
    /* Muted Terra Cotta / Salmon */
    --glass-bg: rgba(255, 255, 255, 0.7);
    /* White glass */
    --glass-border: rgba(0, 0, 0, 0.05);
    /* Subtle dark border */
    --input-bg: rgba(255, 255, 255, 0.8);
    --selection-bg: #f0e6e4;
    /* Very light accent for backgrounds */
    --success-color: #4f8b6e;
    /* Muted green */
    --error-color: #d15a5a;
    /* Muted red */
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: 'Inter', sans-serif;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    /* Subtle warmer gradient */
    background-image:
        radial-gradient(circle at 10% 20%, rgba(218, 119, 86, 0.08) 0%, transparent 20%),
        radial-gradient(circle at 90% 80%, rgba(200, 180, 160, 0.1) 0%, transparent 20%);
}

.container {
    width: 100%;
    max-width: 1400px;
    padding: 2rem;
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 2.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05), 0 2px 8px rgba(0, 0, 0, 0.02);
    animation: fadeIn 0.5s ease-out;
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h1,
h2 {
    font-weight: 700;
    margin-bottom: 1.5rem;
    /* Darker, solid color for headings rather than gradient */
    color: #1a1a1a;
    text-align: center;
    letter-spacing: -0.02em;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #555555;
}

input[type="text"],
input[type="password"] {
    width: 100%;
    padding: 0.75rem;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    background: var(--input-bg);
    color: var(--text-color);
    margin-bottom: 1.5rem;
    transition: all 0.2s;
    box-sizing: border-box;
}

input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px rgba(218, 119, 86, 0.15);
}

.btn {
    width: 100%;
    padding: 0.75rem;
    border: none;
    border-radius: 8px;
    background: var(--accent-color);
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s, opacity 0.2s;
}

.btn:hover {
    opacity: 0.9;
}

.btn:active {
    transform: scale(0.98);
}

.error-message {
    color: var(--error-color);
    text-align: center;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

/* App specific styles */
.upload-area {
    border: 2px dashed rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    margin-bottom: 2rem;
    transition: all 0.2s;
    cursor: pointer;
    position: relative;
    background: rgba(255, 255, 255, 0.5);
}

.upload-area:hover,
.upload-area.dragover {
    border-color: var(--accent-color);
    background: rgba(218, 119, 86, 0.05);
}

.file-input {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    opacity: 0;
    cursor: pointer;
}

.results-area {
    margin-top: 2rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 12px;
    min-height: 100px;
    line-height: 1.6;
    font-size: 0.95rem;
    color: var(--text-color);
}

.results-area h1,
.results-area h2,
.results-area h3 {
    background: none;
    -webkit-text-fill-color: initial;
    color: #1a1a1a;
    text-align: left;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.results-area h1 {
    font-size: 1.5rem;
}

.results-area h2 {
    font-size: 1.3rem;
}

.results-area h3 {
    font-size: 1.1rem;
}

.results-area p {
    margin-bottom: 1rem;
}

.results-area ul,
.results-area ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.results-area li {
    margin-bottom: 0.5rem;
}

.results-area code {
    background: rgba(0, 0, 0, 0.06);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
    color: #d63384;
}

.results-area pre {
    background: #f1f5f9;
    padding: 1rem;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 1rem;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.results-area pre code {
    background: none;
    padding: 0;
    color: #333;
}

.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top-color: var(--accent-color);
    animation: spin 1s ease-in-out infinite;
    margin-left: 10px;
    vertical-align: middle;
}

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

.header-actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1rem;
}

.btn-small {
    width: auto;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    background: transparent;
    border: 1px solid rgba(0, 0, 0, 0.2);
    color: var(--text-color);
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.2s;
}

.btn-small:hover {
    background: rgba(0, 0, 0, 0.05);
}

/* Model Selection Styles */
.model-selection {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.model-option {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: background 0.2s;
}

.model-option:hover {
    background: var(--selection-bg);
}

.model-option input[type="radio"] {
    margin-right: 0.5rem;
    accent-color: var(--accent-color);
    cursor: pointer;
}

.model-label-text {
    font-weight: 500;
}

.model-badge {
    font-size: 0.75rem;
    padding: 0.1rem 0.4rem;
    border-radius: 4px;
    margin-left: 0.5rem;
    background: #e2e8f0;
    color: #64748b;
}

/* Model Badges specific colors */
.model-option input[value="fast"]:checked~.model-badge {
    background: #dbeafe;
    color: #2563eb;
}

.model-option input[value="pro"]:checked~.model-badge {
    background: #ede9fe;
    color: #7c3aed;
}

/* Split View Styles */
.split-view-container {
    display: block;
    width: 100%;
    transition: all 0.3s ease;
}

.split-view-container.split-active {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.pdf-viewer-container {
    background: white;
    padding: 0.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    height: 100%;
}

.split-view-container.split-active .results-area {
    margin-top: 0;
    height: 600px;
    overflow-y: auto;
}

/* Compare Button Active State */
#compareBtn.active {
    background: #da7756;
    color: white;
}

#compareBtn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s;
}

@media (max-width: 1024px) {
    .split-view-container.split-active {
        grid-template-columns: 1fr;
    }

    .split-view-container.split-active .results-area {
        height: auto;
        max-height: 500px;
    }
}
.ai-disclaimer {
    margin: 1rem auto 0;
    width: fit-content;
    max-width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 1px solid rgba(218, 119, 86, 0.35);
    background: var(--selection-bg);
    color: var(--text-color);
    font-size: 0.85rem;
    text-align: center;
}
