/* ─────────────────────────────────────────────────── */
/* Auth Pages (Login, Register, etc.) */
/* ─────────────────────────────────────────────────── */

.auth-shell {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 100vh;
    align-items: stretch;
}

.auth-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background:
        radial-gradient(circle at top right, rgba(47, 111, 94, 0.08), transparent 40%),
        radial-gradient(circle at bottom left, rgba(215, 168, 110, 0.06), transparent 35%),
        linear-gradient(180deg, #faf7f1 0%, var(--color-bg) 100%);
}

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

.auth-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s ease;
}

.auth-brand:hover {
    opacity: 0.8;
}

.auth-brand .brand-mark {
    width: 2.7rem;
    height: 2.7rem;
    border-radius: 0.95rem;
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-strong));
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1.05rem;
    box-shadow: 0 10px 24px rgba(35, 79, 68, 0.22);
}

.auth-brand .brand-name {
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.auth-intro {
    max-width: 360px;
    margin-bottom: 2rem;
    text-align: center;
}

.auth-intro .eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.9rem;
    border: 1px solid var(--color-border);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.65);
    color: var(--color-primary-strong);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    margin-bottom: 0.8rem;
}

.auth-title {
    font-size: clamp(1.6rem, 5vw, 2.2rem);
    line-height: 1.15;
    letter-spacing: -0.03em;
    margin-bottom: 0.6rem;
    color: var(--color-text);
    font-weight: 700;
}

.auth-subtitle {
    color: var(--color-text-soft);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ─────────────────────────────────────────────────── */
/* Messages */
/* ─────────────────────────────────────────────────── */

.auth-message {
    width: 100%;
    max-width: 360px;
    padding: 0.9rem 1.1rem;
    border-radius: 1rem;
    margin-bottom: 1.5rem;
    border: 1px solid transparent;
    font-size: 0.95rem;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-message-error {
    background: rgba(220, 53, 69, 0.08);
    border-color: rgba(220, 53, 69, 0.2);
    color: #c3192f;
}

.auth-message-warning {
    background: rgba(255, 193, 7, 0.08);
    border-color: rgba(255, 193, 7, 0.2);
    color: #856404;
}

.auth-message-success {
    background: rgba(40, 167, 69, 0.08);
    border-color: rgba(40, 167, 69, 0.2);
    color: #1e7e34;
}

.auth-message-info {
    background: rgba(23, 162, 184, 0.08);
    border-color: rgba(23, 162, 184, 0.2);
    color: #0c5460;
}

/* ─────────────────────────────────────────────────── */
/* Form */
/* ─────────────────────────────────────────────────── */

.auth-form {
    width: 100%;
    max-width: 360px;
    margin-bottom: 2rem;
}

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

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

.form-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.form-label {
    display: block;
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 0.5rem;
    letter-spacing: 0.01em;
}

.form-control-wrapper {
    position: relative;
    display: flex;
    flex-direction: column;
}

.auth-form input {
    min-height: 48px;
    padding: 0 1rem;
    border: 1px solid var(--color-border);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.72);
    color: var(--color-text);
    font-size: 0.95rem;
    font-family: inherit;
    transition: all 0.2s ease;
}

.auth-form input:placeholder-shown {
    color: var(--color-text-soft);
}

.auth-form input::placeholder {
    color: var(--color-text-soft);
}

.auth-form input:focus {
    outline: none;
    border-color: var(--color-primary);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 0 0 3px rgba(47, 111, 94, 0.08);
}

.auth-form input.error {
    border-color: #dc3545;
}

.auth-form input.error:focus {
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.08);
}

/* ─────────────────────────────────────────────────── */
/* Buttons */
/* ─────────────────────────────────────────────────── */

.btn-lg {
    min-height: 48px;
    padding: 0 1.5rem;
    font-size: 1rem;
    font-weight: 700;
    border-radius: 999px;
}

.btn-block {
    width: 100%;
}

/* ─────────────────────────────────────────────────── */
/* Form Error */
/* ─────────────────────────────────────────────────── */

.form-error {
    display: block;
    margin-top: 0.4rem;
    font-size: 0.85rem;
    color: #dc3545;
    animation: slideDown 0.2s ease;
}

/* ─────────────────────────────────────────────────── */
/* Footer */
/* ─────────────────────────────────────────────────── */

.auth-footer {
    width: 100%;
    max-width: 360px;
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
}

.auth-footer-text {
    font-size: 0.92rem;
    color: var(--color-text-soft);
    margin: 0;
}

.auth-footer-text a {
    color: var(--color-primary);
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s ease;
}

.auth-footer-text a:hover {
    color: var(--color-primary-strong);
    text-decoration: underline;
}

/* ─────────────────────────────────────────────────── */
/* Side Content (Desktop Only) */
/* ─────────────────────────────────────────────────── */

.auth-side {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-strong) 100%);
    color: #fff;
    position: relative;
    overflow: hidden;
}

.auth-side::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.1), transparent 35%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.08), transparent 40%);
    pointer-events: none;
}

.auth-side-content {
    position: relative;
    z-index: 1;
    max-width: 340px;
    text-align: center;
}

.side-badge {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
}

.side-badge-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    flex: 0 0 auto;
    font-size: 1rem;
}

.side-badge-text {
    text-align: left;
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.4;
}

/* ─────────────────────────────────────────────────── */
/* Responsive */
/* ─────────────────────────────────────────────────── */

@media (max-width: 991.98px) {
    .auth-shell {
        grid-template-columns: 1fr;
    }

    .auth-side {
        display: none;
    }

    .auth-container {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 640px) {
    .auth-container {
        padding: 1.5rem 1rem;
    }

    .auth-intro {
        margin-bottom: 1.5rem;
    }

    .auth-form {
        max-width: 100%;
    }

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

    .auth-footer {
        max-width: 100%;
        padding-top: 1rem;
    }

    .auth-title {
        font-size: 1.5rem;
    }

    .auth-subtitle {
        font-size: 0.9rem;
    }
}
