:root {
    --bg-page: #f7f7f2;
    --bg-surface: #ffffff;
    --border-subtle: #e5e7e1;
    --text-primary: #1a2421;
    --text-secondary: #5c6862;
    --green-dark: #0b5e42;
    --green-dark-hover: #094c35;
    --green-mint: #e6f4ee;
    --green-mint-text: #0f5c41;
    --font-serif: Georgia, 'Times New Roman', Times, serif;
    --font-sans: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

html[data-theme="dark"] {
    --bg-page: #111614;
    --bg-surface: #19211d;
    --border-subtle: #2d3a34;
    --text-primary: #eef2ef;
    --text-secondary: #b1bdb6;
    --green-dark: #15845d;
    --green-dark-hover: #1a9b6d;
    --green-mint: rgba(21, 132, 93, 0.22);
    --green-mint-text: #7be0b8;
}

html[data-theme="dark"] .form-input,
html[data-theme="dark"] .form-select {
    background-color: #222c27;
    color: var(--text-primary);
}

.auth-theme-toggle {
    position: fixed;
    top: 18px;
    right: 20px;
    padding: 8px 14px;
    border-radius: 10px;
    border: 1px solid var(--border-subtle);
    background-color: var(--bg-surface);
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 0.84rem;
    font-weight: 600;
    cursor: pointer;
}

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

body.auth-page {
    font-family: var(--font-sans);
    background-color: var(--bg-page);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    -webkit-font-smoothing: antialiased;
}

.auth-container {
    width: 100%;
    max-width: 440px;
}

.auth-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 24px;
}

.auth-brand-icon {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    background-color: var(--green-dark);
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.auth-brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}

.auth-brand-kicker {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-primary);
}

.auth-brand-subtitle {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.auth-card {
    background-color: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: 16px;
    padding: 32px 28px;
    box-shadow: 0 4px 16px rgba(16, 24, 20, 0.05);
}

.auth-title {
    font-family: var(--font-serif);
    font-size: 1.65rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.auth-subtitle {
    font-size: 0.92rem;
    color: var(--text-secondary);
    margin-bottom: 22px;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-label {
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--text-primary);
}

.form-input,
.form-select {
    width: 100%;
    height: 44px;
    padding: 0 14px;
    border: 1px solid var(--border-subtle);
    border-radius: 10px;
    background-color: #ffffff;
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-input::placeholder {
    color: #9aa39e;
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: var(--green-dark);
    box-shadow: 0 0 0 3px rgba(11, 94, 66, 0.14);
}

.btn-auth-primary {
    width: 100%;
    height: 46px;
    border: none;
    border-radius: 10px;
    background-color: var(--green-dark);
    color: #ffffff;
    font-family: var(--font-sans);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    margin-top: 6px;
    transition: background-color 0.15s ease;
}

.btn-auth-primary:hover {
    background-color: var(--green-dark-hover);
}

.flash-message {
    padding: 12px 14px;
    border-radius: 10px;
    margin-bottom: 18px;
    font-size: 0.88rem;
    font-weight: 500;
}

.flash-message.success {
    background-color: var(--green-mint);
    color: var(--green-mint-text);
}

.flash-message.error {
    background-color: #fde8e8;
    color: #9b1c1c;
}

.auth-note {
    margin-top: 18px;
    font-size: 0.82rem;
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.5;
}

.auth-footer {
    margin-top: 20px;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-secondary);
}
