/**
 * Authentication Pages Styles
 * @version 2.1 - Added Theme-Independent Full-Width layout
 */

/* ==================================================================
  THEME-INDEPENDENT FULL-WIDTH LAYOUT
  This forces auth pages to be full-width on themes like Astra/Neve.
==================================================================
*/

body.nm-auth-page #primary,
body.nm-auth-page .site-main {
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* Hide sidebars on these pages */
body.nm-auth-page #secondary,
body.nm-auth-page .widget-area {
    display: none !important;
}

/* Astra Overrides */
body.nm-auth-page.ast-separate-container .site-content,
body.nm-auth-page.ast-separate-container .ast-container {
    padding: 0 !important;
    margin: 0 !important;
    max-width: 100% !important;
}
body.nm-auth-page.ast-separate-container #primary.content-area {
    float: none !important;
    width: 100% !important;
    margin: 0 !important;
}

/* Neve Overrides */
body.nm-auth-page .neve-main .container .row {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
}
body.nm-auth-page .neve-main .container .col {
    padding: 0 !important;
}

/* ==================================================================
  PAGE CONTENT STYLES
==================================================================
*/

.nm-auth-wrapper {
    width: 100%; /* Fill the new full-width container */
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f7fa;
    padding: 40px 20px;
    box-sizing: border-box; /* Ensures padding is included */
}

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

.nm-auth-box {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: row;
    overflow: hidden;
    padding: 0;
}

/* --- 1. Promo Column (Left Side) --- */
.nm-auth-promo {
    flex-basis: 45%;
    flex-grow: 1;
    padding: 40px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.nm-promo-content h2 {
    color: white;
    font-size: 28px;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 15px;
}

.nm-promo-content p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 25px;
}

.nm-promo-benefits {
    list-style: none;
    padding: 0;
    margin: 0;
}

.nm-promo-benefits li {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 20px;
}

.nm-promo-benefits .nm-icon {
    font-size: 24px;
    line-height: 1.4;
}

.nm-promo-benefits strong {
    display: block;
    font-size: 16px;
    font-weight: 600;
    color: white;
}

.nm-promo-benefits .nm-desc {
    display: block;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.5;
}


/* --- 2. Form Column (Right Side) --- */
.nm-auth-form-container {
    flex-basis: 55%;
    flex-grow: 1;
    padding: 40px;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.nm-auth-header {
    text-align: left;
    margin-bottom: 30px;
}

.nm-auth-header h1 {
    font-size: 28px;
    color: #333;
    margin: 0 0 10px 0;
    font-weight: 700;
}

.nm-auth-header p {
    color: #666;
    font-size: 16px;
    margin: 0;
}

.nm-auth-form {
    margin-bottom: 24px;
}

.nm-form-group {
    margin-bottom: 20px;
}

.nm-form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 600;
    font-size: 14px;
}

.nm-form-group input[type="text"],
.nm-form-group input[type="email"],
.nm-form-group input[type="password"],
.nm-form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.nm-form-group input:focus,
.nm-form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.nm-password-field {
    position: relative;
}

.nm-toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #999;
    font-size: 18px;
}

.nm-toggle-password:hover {
    color: #667eea;
}

.nm-password-strength {
    margin-top: 8px;
    font-size: 13px;
    font-weight: 600;
}

.nm-form-hint {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: #999;
}

.nm-form-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.nm-checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 14px;
}

.nm-checkbox-label input[type="checkbox"] {
    margin-right: 8px;
    cursor: pointer;
}

.nm-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.nm-btn-primary {
    background: #667eea;
    color: #ffffff;
}

.nm-btn-primary:hover {
    background: #5568d3;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.nm-btn-block {
    width: 100%;
}

.nm-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

.nm-auth-divider {
    text-align: center;
    margin: 24px 0;
    position: relative;
}

.nm-auth-divider::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 1px;
    background: #e0e0e0;
}

.nm-auth-divider span {
    position: relative;
    background: #ffffff;
    padding: 0 16px;
    color: #999;
    font-size: 13px;
    font-weight: 600;
}

.nm-social-login {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.nm-btn-google,
.nm-btn-facebook {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    background: #ffffff;
    color: #333;
    font-weight: 600;
}

.nm-btn-google:hover {
    border-color: #ea4335;
    color: #ea4335;
}

.nm-btn-facebook:hover {
    border-color: #1877f2;
    color: #1877f2;
}

.nm-auth-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid #e0e0e0;
}

.nm-auth-footer p {
    margin: 0;
    color: #666;
    font-size: 14px;
}

.nm-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
}

.nm-link:hover {
    text-decoration: underline;
}

.nm-link-primary {
    color: #667eea;
    font-weight: 700;
    text-decoration: none;
}

.nm-link-primary:hover {
    text-decoration: underline;
}

.nm-error-message {
    background: #fee;
    color: #c33;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #c33;
}

.nm-success-message {
    background: #efe;
    color: #393;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #393;
}

/* --- 3. Responsive (Mobile) --- */
@media (max-width: 768px) {
    .nm-auth-box {
        flex-direction: column; /* Stack columns on mobile */
    }

    .nm-auth-promo {
        flex-basis: auto;
    }

    .nm-auth-form-container {
        flex-basis: auto;
    }

    .nm-auth-header {
        text-align: center;
    }
}