:root {
    --primary-color: #5850EC;
    --primary-hover: #4338CA;
    --background-gradient: linear-gradient(135deg, #4c1d95 0%, #1e1b4b 100%);
    --text-color: #1F2937;
    --text-light: #6B7280;
    --white: #ffffff;
    --glass-bg: rgba(255, 255, 255, 0.95);
    --input-bg: #F3F4F6;
    --input-border: #E5E7EB;
    --font-stack: 'Inter', system-ui, -apple-system, sans-serif;
}

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

body {
    font-family: var(--font-stack);
    background: var(--background-gradient);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text-color);
    line-height: 1.5;
}

.header {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--white);
    margin-bottom: 2rem;
    position: relative;
}

.gtranslate_wrapper {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1000;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.logo-icon {
    width: 24px;
    height: 24px;
    background-color: var(--white);
    border-radius: 50%;
    /* Placeholder for logo */
    position: relative;
}

.logo-icon::after {
    content: '';
    position: absolute;
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}


.subtitle {
    font-size: 1.25rem;
    font-weight: 400;
    opacity: 0.9;
}

.main-container {
    width: 100%;
    max-width: 600px;
    padding: 0 1rem;
    margin-bottom: 3rem;
    position: relative;
    /* For loader positioning context if needed */
}

.card {
    background: var(--glass-bg);
    border-radius: 1rem;
    padding: 2.5rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.card-title {
    text-align: center;
    color: #4338CA;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.card-description {
    text-align: center;
    color: var(--text-light);
    font-size: 0.875rem;
    margin-bottom: 2rem;
}

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

.form-label {
    display: block;
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--input-border);
    border-radius: 0.5rem;
    background-color: var(--white);
    font-size: 0.95rem;
    transition: all 0.2s;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(88, 80, 236, 0.1);
}

.info-box {
    background-color: #F0F9FF;
    border-left: 4px solid #3B82F6;
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 2rem;
}

.info-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #1E40AF;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.info-list {
    list-style-type: disc;
    padding-left: 1.5rem;
    color: #374151;
    font-size: 0.85rem;
}

.info-list li {
    margin-bottom: 0.25rem;
}

.btn-submit {
    width: 100%;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 0.875rem;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s, transform 0.1s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

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

.btn-submit:active {
    transform: translateY(1px);
}

.footer {
    padding: 1rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.75rem;
    margin-top: auto;
}

/* Loading State */
.loading-overlay {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 1rem;
    text-align: center;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(88, 80, 236, 0.1);
    border-left-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

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

.loading-text {
    font-weight: 500;
    color: var(--text-color);
}

/* Results Area */
.result-area {
    display: none;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--input-border);
    animation: fadeIn 0.5s ease-out;
}

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

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

.result-content {
    line-height: 1.7;
    color: #374151;
}

.result-content h2 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
    color: #111827;
}

.result-content h3 {
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    color: #1F2937;
}

.result-content p {
    margin-bottom: 1rem;
}

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

.result-content li {
    margin-bottom: 0.5rem;
}

.result-content blockquote {
    border-left: 4px solid var(--primary-color);
    padding-left: 1rem;
    color: #4B5563;
    font-style: italic;
    margin: 1rem 0;
}

.btn-new {
    margin-top: 2rem;
    background-color: #6B7280;
}

.btn-new:hover {
    background-color: #4B5563;
}