body.auth-screen {
    min-height: 100vh;
    margin: 0;
    background-color: #2c160d;
    background-image: url("../img/banner.png");
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
    background-attachment: fixed;
    font-family: "Source Sans 3", Helvetica, Arial, sans-serif;
    color: #374151;
}

body.auth-screen input,
body.auth-screen textarea,
body.auth-screen select {
    -webkit-user-select: text;
    user-select: text;
}

.auth-wrap {
    min-height: 100vh;
    display: flex;
    align-items: safe center;
    justify-content: center;
    padding: 28px 16px 48px;
    box-sizing: border-box;
}

body.auth-screen-long .auth-wrap {
    align-items: flex-start;
    padding-top: 32px;
}

.auth-card {
    width: min(440px, 100%);
    background: #fff;
    border-radius: 28px;
    box-shadow: 0 28px 60px rgba(42, 18, 8, 0.38);
    position: relative;
    padding: 26px 18px 18px;
}

body.auth-screen-long .auth-card,
body.auth-screen-choice .auth-card {
    width: min(520px, 100%);
}

.auth-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    font-size: 18px;
    z-index: 3;
}

.auth-close:hover {
    color: #4b5563;
}

.auth-brand {
    text-align: center;
    margin: 4px 0 26px;
}

.auth-wordmark {
    display: block;
    font-family: "Playfair Display", Georgia, serif;
    color: #c8102e;
    font-size: 44px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.4px;
}

.auth-wordmark:hover {
    color: #c8102e;
}

.auth-badge {
    display: inline-block;
    margin-top: 8px;
    background: #146c36;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.15px;
    text-transform: uppercase;
    padding: 5px 12px 4px;
    border-radius: 999px;
    line-height: 1.2;
}

.auth-panel {
    background: #146c36;
    border-radius: 18px;
    padding: 16px 12px 14px;
    margin-top: 8px;
}

.auth-panel-plain {
    padding-top: 14px;
}

.auth-tabs {
    display: flex;
    gap: 8px;
    margin: 0 2px 12px;
    position: relative;
    z-index: 2;
}

.auth-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 46px;
    padding: 10px 8px;
    border-radius: 12px;
    background: #f3f4f6;
    color: #6b7280;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
    cursor: pointer;
    user-select: none;
}

.auth-tab i {
    font-size: 14px;
}

a.auth-tab,
a.auth-tab:visited {
    text-decoration: none;
    color: #6b7280;
}

a.auth-tab:hover,
a.auth-tab.active,
a.auth-tab.active:hover,
a.auth-tab.active:visited,
a.auth-tab.active span,
a.auth-tab.active i {
    color: #fff;
    text-decoration: none;
}

.auth-tab.active {
    background: #146c36;
    color: #fff;
}

.auth-tab.active span,
.auth-tab.active i {
    color: #fff;
    background: transparent;
}

.auth-tab.active {
    box-shadow: 0 8px 16px rgba(12, 70, 34, 0.18);
}

@media (hover: hover) and (pointer: fine) {
    .auth-tab:hover {
        background: #146c36;
        color: #fff;
    }

    .auth-tab:hover span,
    .auth-tab:hover i {
        color: #fff;
        background: transparent;
    }
}

.auth-sheet {
    background: #fff;
    border-radius: 16px;
    padding: 22px 18px 16px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
}

.auth-sheet > h2,
.auth-sheet > form > h2 {
    margin: 0 0 6px;
    color: #e10600;
    text-align: center;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.25;
    font-family: "Source Sans 3", Helvetica, Arial, sans-serif;
}

.auth-lead {
    margin: 0 0 16px;
    text-align: center;
    color: #6b7280;
    font-size: 14px;
    line-height: 1.45;
}

body.auth-screen .form-group {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    width: 100%;
}

body.auth-screen .form-control {
    padding: 0 0 12px;
    width: 100%;
}

body.auth-screen .form-control label,
body.auth-screen .register-form .form-control label,
body.auth-screen .form-control-required label {
    display: block !important;
    color: #4b5563;
    font-size: 14px;
    font-weight: 600;
    padding-bottom: 6px;
    font-family: "Source Sans 3", Helvetica, Arial, sans-serif;
}

body.auth-screen .form-control input,
body.auth-screen .form-control textarea,
body.auth-screen .form-control select {
    width: 100%;
    height: 46px;
    padding: 10px 14px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    color: #111827;
    font-size: 14px;
    font-family: "Source Sans 3", Helvetica, Arial, sans-serif;
    box-sizing: border-box;
}

body.auth-screen .form-control textarea {
    height: auto;
    min-height: 84px;
}

body.auth-screen input[type="date"] {
    min-width: 0;
    width: 100%;
    height: 46px;
}

body.auth-screen .form-control input::placeholder,
body.auth-screen .form-control textarea::placeholder {
    color: #9ca3af;
    font-size: 14px;
}

body.auth-screen .form-control input:focus,
body.auth-screen .form-control textarea:focus,
body.auth-screen .form-control select:focus {
    outline: none;
    border-color: #146c36;
    box-shadow: 0 0 0 3px rgba(20, 108, 54, 0.12);
}

body.auth-screen .form-control-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 0;
}

body.auth-screen .form-control-checkbox input {
    width: 16px;
    height: 16px;
    min-height: 0;
    padding: 0;
    border-radius: 4px;
    accent-color: #146c36;
    flex: 0 0 auto;
}

body.auth-screen .form-control-checkbox label {
    display: inline !important;
    padding: 0;
    margin: 0;
    color: #4b5563;
    font-size: 14px;
    font-weight: 600;
}

body.auth-screen .remember {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 2px 0 14px;
}

body.auth-screen .forget {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #146c36;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}

body.auth-screen .forget i {
    color: #e39b12;
    font-size: 13px;
}

body.auth-screen .auth-sheet .btn.btn-primary {
    display: block;
    width: 100%;
    margin-top: 4px;
    padding: 13px 16px;
    border: 0;
    border-radius: 12px;
    background: linear-gradient(180deg, #f6d56a 0%, #e8b423 100%);
    color: #1f2937;
    font-family: "Source Sans 3", Helvetica, Arial, sans-serif;
    font-size: 18px;
    font-weight: 800;
    letter-spacing: 0.1px;
    text-transform: none;
    box-shadow: 0 8px 16px rgba(232, 180, 35, 0.28);
}

body.auth-screen .auth-sheet .btn.btn-primary:hover {
    background: linear-gradient(180deg, #f8dc7a 0%, #d9a61a 100%);
    color: #1f2937;
}

.auth-switch {
    margin: 14px 0 2px;
    text-align: center;
    color: #6b7280;
    font-size: 14px;
}

.auth-switch a {
    color: #e10600;
    font-weight: 700;
    text-decoration: underline;
}

.auth-alt {
    margin: 10px 0 2px;
    text-align: center;
}

body.auth-screen .login-link span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #146c36;
    font-size: 15px;
    font-weight: 700;
}

body.auth-screen .login-link span::before {
    content: "\2014\00a0";
}

body.auth-screen .password-rules {
    margin: 0 0 12px;
    padding: 10px 12px;
    border-radius: 10px;
    background: #f3faf4;
    border: 1px solid #cfe6d4;
    color: #1f5c32;
    font-size: 13px;
    line-height: 1.45;
    text-align: left;
}

body.auth-screen .error {
    display: block;
    margin-top: 4px;
}

body.auth-screen #login-code-panel {
    padding: 4px 0 0;
    text-align: center;
    color: #374151;
}

body.auth-screen #login-code-panel > p:first-child {
    color: #e10600;
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 8px;
}

body.auth-screen #login-code-panel .login-code-copy,
body.auth-screen #login-code-panel .login-code-timer {
    color: #4b5563;
    font-size: 14px;
    line-height: 1.45;
}

body.auth-screen #login-code-panel .login-code-resend {
    margin-top: 12px;
    width: 100%;
    background: transparent;
    border: 1px solid #146c36;
    color: #146c36;
    border-radius: 12px;
    padding: 12px 16px;
    font-weight: 700;
}

body.auth-screen #login-code-panel .login-code-resend:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.auth-choices {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.auth-choice {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
    background: #146c36;
    border-radius: 14px;
    padding: 18px 14px 20px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    transition: transform 0.2s ease;
}

.auth-choice:hover {
    transform: translateY(-2px);
}

.auth-choice i {
    font-size: 28px;
    color: #ffe933;
    margin-bottom: 4px;
}

.auth-choice strong {
    color: #ffe933;
    font-size: 18px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.2px;
}

.auth-choice span {
    color: #fff;
    font-size: 14px;
}

.auth-toasts {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 80;
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: min(320px, calc(100vw - 28px));
    pointer-events: none;
}

.auth-toast {
    background: #fff;
    border-radius: 12px;
    border-left: 5px solid #e10600;
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.16);
    padding: 12px 14px 13px;
    animation: auth-toast-in 0.2s ease;
}

.auth-toast strong {
    display: block;
    margin-bottom: 3px;
    color: #e10600;
    font-size: 15px;
}

.auth-toast p {
    margin: 0;
    color: #4b5563;
    font-size: 14px;
    line-height: 1.4;
}

.auth-toast-success {
    border-left-color: #146c36;
}

.auth-toast-success strong {
    color: #146c36;
}

@keyframes auth-toast-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

@media screen and (max-width: 480px) {
    .auth-card,
    body.auth-screen-long .auth-card,
    body.auth-screen-choice .auth-card {
        width: 100%;
        border-radius: 22px;
        padding: 22px 12px 14px;
    }

    .auth-wordmark {
        font-size: 36px;
    }

    .auth-tab {
        font-size: 11px;
        gap: 4px;
        padding: 8px 4px;
    }

    .auth-sheet > h2,
    .auth-sheet > form > h2 {
        font-size: 18px;
    }

    .auth-toasts {
        right: 12px;
        left: 12px;
        width: auto;
    }
}
