/* ==========
   Global layout
   ========== */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: #111827;
    background-color: #f3f4f6;
}

.auth-body {
    min-height: 100vh;
    display: flex;
    align-items: stretch;
    justify-content: center;
}

/* Wrapper: 2 columns (brand + form) */
.auth-wrapper {
    display: flex;
    width: 100%;
    max-width: 1100px;
    min-height: 100vh;
    background: #f9fafb;
}

/* ==========
   Left brand panel
   ========== */

.auth-brand-panel {
    flex: 1.1;
    background: radial-gradient(circle at top left, #22c55e 0, #16a34a 35%, #15803d 65%, #14532d 100%);
    color: #ecfdf5;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 32px;
}

.auth-brand-inner {
    max-width: 340px;
}

.auth-logo {
    width: 120px;
    height: auto;
    margin-bottom: 24px;
    display: block;
}

.auth-brand-title {
    font-size: 1.9rem;
    font-weight: 700;
    margin: 0 0 8px;
}

.auth-brand-text {
    font-size: 0.98rem;
    line-height: 1.5;
    margin: 0 0 16px;
    color: #dcfce7;
}

.auth-brand-points {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.9rem;
}

.auth-brand-points li {
    margin-bottom: 6px;
}

/* ==========
   Right form panel
   ========== */

.auth-form-panel {
    flex: 1.2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 40px 32px;
}

.auth-card {
    background: #ffffff;
    border-radius: 18px;
    box-shadow:
        0 10px 15px -3px rgba(15, 23, 42, 0.12),
        0 4px 6px -4px rgba(15, 23, 42, 0.08);
    padding: 32px 28px;
}

.auth-card-header {
    margin-bottom: 18px;
}

.auth-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0 0 4px;
    color: #111827;
}

.auth-subtitle {
    margin: 0;
    font-size: 0.96rem;
    color: #6b7280;
}

.auth-card-body {
    margin-top: 12px;
}

/* ==========
   Alerts (success / error)
   ========== */

.auth-alert {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 0.92rem;
    margin-bottom: 14px;
    border: 1px solid transparent;
}

.auth-alert-success {
    background: #ecfdf5;
    color: #14532d;
    border-color: #bbf7d0;
}

.auth-alert-error {
    background: #fef2f2;
    color: #7f1d1d;
    border-color: #fecaca;
}

.auth-alert-icon {
    margin-top: 2px;
}

.auth-alert ul {
    margin: 0;
    padding-left: 18px;
}

/* ==========
   Form elements
   ========== */

.auth-form {
    width: 100%;
}

.auth-field {
    margin-bottom: 14px;
}

.auth-label {
    display: block;
    font-size: 0.9rem;
    color: #374151;
    margin-bottom: 5px;
    font-weight: 500;
}

.auth-input {
    width: 100%;
    border-radius: 10px;
    border: 1px solid #d1d5db;
    padding: 10px 11px;
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
    background-color: #f9fafb;
}

.auth-input:focus {
    border-color: #16a34a;
    box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.4);
    background-color: #ffffff;
}

.auth-row-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 8px 0 14px;
    gap: 8px;
}

.auth-checkbox-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.88rem;
    color: #4b5563;
}

.auth-checkbox-label input[type="checkbox"] {
    width: 14px;
    height: 14px;
}

/* ==========
   Buttons & links
   ========== */

.auth-btn {
    width: 100%;
    border-radius: 999px;
    border: none;
    font-size: 0.98rem;
    font-weight: 600;
    padding: 10px 16px;
    cursor: pointer;
    transition: background-color 0.15s ease, box-shadow 0.15s ease, transform 0.05s ease;
}

.auth-btn-primary {
    background: linear-gradient(135deg, #22c55e, #16a34a);
    color: #ffffff;
    box-shadow: 0 10px 15px -3px rgba(22, 163, 74, 0.4);
}

.auth-btn-primary:hover {
    background: linear-gradient(135deg, #16a34a, #15803d);
    box-shadow: 0 12px 18px -4px rgba(22, 163, 74, 0.55);
}

.auth-btn-primary:active {
    transform: translateY(1px);
    box-shadow: 0 8px 12px -4px rgba(22, 163, 74, 0.5);
}

/* ========== 
   Secondary / Ghost buttons 
   ========== */

.auth-btn-secondary {
    width: 100%;
    border-radius: 999px;
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #374151;
    font-size: 0.95rem;
    font-weight: 500;
    padding: 10px 16px;
    cursor: pointer;
    margin-top: 8px;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease, transform 0.05s ease;
}

.auth-btn-secondary:hover {
    background: #f9fafb;
    border-color: #9ca3af;
    box-shadow: 0 6px 10px -4px rgba(148, 163, 184, 0.5);
}

.auth-btn-secondary:active {
    transform: translateY(1px);
    box-shadow: 0 4px 8px -4px rgba(148, 163, 184, 0.6);
}

/* Small helper for center-aligned buttons-container */
.auth-buttons-stack {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 8px;
}

.auth-link {
    font-size: 0.88rem;
    color: #16a34a;
    text-decoration: none;
}

.auth-link:hover {
    text-decoration: underline;
}

.auth-link-strong {
    font-weight: 600;
    color: #16a34a;
    text-decoration: none;
}

.auth-link-strong:hover {
    text-decoration: underline;
}

/* ==========
   Footer text
   ========== */

.auth-switch-text {
    margin-top: 16px;
    font-size: 0.9rem;
    color: #4b5563;
    text-align: center;
}

.auth-footer-text {
    margin-top: 22px;
    font-size: 0.8rem;
    color: #9ca3af;
    text-align: center;
}

/* OTP Boxes */
.otp-box {
    border: 1px solid #d1d5db;
    border-radius: 10px;
    background: #f9fafb;
    font-size: 24px;
    font-weight: 600;
    text-align: center;
    outline: none;
}

.otp-box:focus {
    border-color: #16a34a;
    box-shadow: 0 0 0 2px rgba(22, 163, 74, 0.25);
    background: #ffffff;
}


/* ==========
   Responsive
   ========== */

@media (max-width: 900px) {
    .auth-wrapper {
        max-width: 100%;
    }

    .auth-card {
        padding: 26px 22px;
    }

    .auth-brand-panel {
        padding: 32px 20px;
    }
}

@media (max-width: 768px) {
    .auth-wrapper {
        flex-direction: column;
        max-width: 480px;
        margin: 0 auto;
    }

    .auth-brand-panel {
        min-height: 210px;
        border-bottom-left-radius: 24px;
        border-bottom-right-radius: 24px;
    }

    .auth-form-panel {
        padding: 24px 18px 32px;
    }

    .auth-card {
        margin-top: -40px;
        border-radius: 18px;
    }

    .auth-brand-inner {
        text-align: left;
    }
}

@media (max-width: 480px) {
    .auth-brand-title {
        font-size: 1.6rem;
    }

    .auth-title {
        font-size: 1.4rem;
    }

    .auth-card {
        padding: 22px 16px;
    }
}