/* ================================================================
   TrungNguyen Account Theme — Custom Layout
   Scroll-style Login + Single-column Register
   Warm gold (#d4a04a) + Crimson (#c0392b) accent
   ================================================================ */

/* ===================== LOGIN — Scroll-style Centered ===================== */
.tn-login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    background:
        radial-gradient(ellipse at 25% 35%, rgba(192, 57, 43, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 75% 65%, rgba(212, 160, 74, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 20%, rgba(192, 57, 43, 0.05) 0%, transparent 60%),
        linear-gradient(180deg, #0a0e1a 0%, #0d1225 50%, #0a0e1a 100%);
}

.tn-login-scroll {
    width: 100%;
    max-width: 440px;
    background: rgba(13, 18, 32, 0.96);
    border: 1px solid rgba(192, 57, 43, 0.18);
    border-radius: 4px;
    padding: 2.5rem 2.25rem;
    position: relative;
    box-shadow:
        0 8px 40px rgba(0, 0, 0, 0.5),
        0 0 50px rgba(192, 57, 43, 0.05),
        inset 0 1px 0 rgba(212, 160, 74, 0.08);
}

/* Top ornament bar */
.tn-scroll-ornament-top {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, #c0392b, #d4a04a, #c0392b, transparent);
    border-radius: 4px 4px 0 0;
}

/* Bottom ornament bar */
.tn-scroll-ornament-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, #c0392b, #d4a04a, #c0392b, transparent);
    border-radius: 0 0 4px 4px;
}

/* Header */
.tn-login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.tn-login-logo-img {
    width: 72px;
    height: 72px;
    border-radius: 12px;
    margin-bottom: 1rem;
    filter: drop-shadow(0 0 15px rgba(192, 57, 43, 0.2));
}

.tn-login-title {
    font-size: 1.6rem;
    font-weight: 800;
    color: #d4a04a;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    text-shadow: 0 0 15px rgba(212, 160, 74, 0.25);
    margin-bottom: 0.75rem;
}

/* Diamond ornament divider */
.tn-ornament-divider {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 1rem 0;
}

.tn-ornament-sm {
    margin: 0.75rem 0;
}

.tn-deco-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(192, 57, 43, 0.4), transparent);
}

.tn-deco-diamonds {
    font-size: 0.6rem;
    color: #c0392b;
    letter-spacing: 0.3em;
    opacity: 0.8;
}

.tn-login-subtitle {
    font-size: 1.1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.25rem;
}

.tn-login-desc {
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.4);
}

/* Login form */
.tn-login-form {
    margin-top: 1.5rem;
}

/* Footer */
.tn-login-footer {
    margin-top: 1.5rem;
    text-align: center;
}

.tn-login-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 0.75rem;
}

.tn-login-links a {
    color: rgba(255, 255, 255, 0.45);
    text-decoration: none;
    font-size: 0.85rem;
    transition: color 0.2s;
}

.tn-login-links a:hover {
    color: #d4a04a;
}

.tn-link-sep {
    color: rgba(255, 255, 255, 0.15);
    font-size: 0.8rem;
}

/* ===================== REGISTER — Single-column Scroll ===================== */
.tn-register-scroll {
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
    background: rgba(13, 18, 32, 0.96);
    border: 1px solid rgba(192, 57, 43, 0.18);
    border-radius: 4px;
    padding: 2.5rem 2.25rem;
    position: relative;
    box-shadow:
        0 8px 40px rgba(0, 0, 0, 0.5),
        0 0 50px rgba(192, 57, 43, 0.05),
        inset 0 1px 0 rgba(212, 160, 74, 0.08);
}

.tn-register-form {
    margin-top: 1rem;
}

/* Register sections */
.tn-register-section {
    margin-bottom: 1.5rem;
}

.tn-section-divider {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 0.75rem;
}

.tn-section-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.65);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 1rem;
}

/* ===================== SHARED FORM ELEMENTS ===================== */
.tn-form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    margin-bottom: 1rem;
}

.tn-form-group:last-child {
    margin-bottom: 0;
}

.tn-form-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.tn-form-input,
.tn-form-select {
    width: 100%;
    padding: 0.7rem 0.9rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(212, 160, 74, 0.12);
    border-radius: 4px;
    color: #e8e8e8;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    outline: none;
    box-sizing: border-box;
}

.tn-form-input:focus,
.tn-form-select:focus {
    border-color: #c0392b;
    background: rgba(0, 0, 0, 0.45);
    box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.1), 0 0 12px rgba(192, 57, 43, 0.06);
}

.tn-form-input::placeholder {
    color: rgba(255, 255, 255, 0.22);
}

.tn-form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23c0392b' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.9rem center;
    padding-right: 2.5rem;
}

.tn-form-select option {
    background: #0d1225;
    color: #e8e8e8;
}

/* Submit button — Crimson */
.tn-btn-submit {
    display: block;
    width: auto;
    padding: 0.8rem 2.5rem;
    margin: 1.5rem auto 0;
    background: linear-gradient(135deg, #c0392b, #96281b);
    color: #fff;
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    border: 1px solid rgba(212, 160, 74, 0.15);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.25s ease;
}

.tn-btn-submit:hover {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    box-shadow: 0 0 20px rgba(192, 57, 43, 0.35), 0 4px 12px rgba(0, 0, 0, 0.3);
    border-color: rgba(212, 160, 74, 0.3);
    transform: translateY(-1px);
}

.tn-btn-submit:active {
    transform: translateY(0);
}

.tn-btn-submit-wide {
    width: 100%;
}

/* Captcha row */
.tn-captcha-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.tn-captcha-input {
    flex: 1;
    max-width: 160px;
}

.tn-captcha-img {
    height: 42px;
    border-radius: 4px;
    border: 1px solid rgba(192, 57, 43, 0.2);
    cursor: pointer;
    transition: opacity 0.2s;
}

.tn-captcha-img:hover {
    opacity: 0.85;
}

.tn-captcha-refresh {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(192, 57, 43, 0.06);
    border: 1px solid rgba(192, 57, 43, 0.2);
    border-radius: 4px;
    color: #c0392b;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s;
}

.tn-captcha-refresh:hover {
    background: rgba(192, 57, 43, 0.12);
    border-color: #c0392b;
}

/* Error styling */
.tn-login-page .account-error,
.tn-login-page .account-error:not(:empty) {
    background: rgba(192, 57, 43, 0.1);
    border: 1px solid rgba(192, 57, 43, 0.3);
    color: #e74c3c;
    border-radius: 4px;
    padding: 0.75rem 1rem;
    margin-bottom: 1.25rem;
    font-size: 0.85rem;
}

.form-error {
    color: #e74c3c;
    font-size: 0.78rem;
    margin-top: 0.2rem;
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 576px) {
    .tn-login-page {
        padding: 1rem 0.5rem;
    }

    .tn-login-scroll {
        padding: 2rem 1.25rem;
    }

    .tn-login-logo-img {
        width: 56px;
        height: 56px;
    }

    .tn-login-title {
        font-size: 1.3rem;
    }

    .tn-register-scroll {
        padding: 2rem 1.25rem;
    }

    .tn-captcha-row {
        flex-wrap: wrap;
    }

    .tn-captcha-input {
        max-width: none;
        flex: 1 1 100%;
    }
}
