/* ==========================================================================
   1. GLOBAL SYSTEM ARCHITECTURE VARIABLES
   ========================================================================== */
:root {
    --forest-primary: #2d8659;
    --forest-hover: #195539;
    --forest-accent: #4da576;
    --champagne: #e0a84e;
    --bg-dark: #0f1419;
    --bg-slate-card: rgba(26, 31, 46, 0.7);
    --border-subtle: rgba(148, 163, 184, 0.12);
    
    --text-primary: #ffffff;
    --text-secondary: #cbd5e1;
    --text-muted: #64748b;
    --text-inputs: #e2e8f0;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.auth-body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-dark);
    min-height: 100vh;
    color: var(--text-primary);
    overflow-x: hidden;
    letter-spacing: -0.011em;
}

/* Custom Styled Premium Scrollbar Interface */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: rgba(15, 20, 25, 0.3);
}
::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.2);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(148, 163, 184, 0.35);
}

/* ==========================================================================
   2. SITE MAIN LAYOUT ARCHITECTURE
   ========================================================================== */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    position: relative;
    z-index: 10;
}

.auth-container {
    width: 100%;
    max-width: 1150px;
    margin: 0 auto;
}

.auth-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center;
}

/* Left Panel: App System Messaging Showcase Layout */
.branding-side {
    display: none; /* Mobile Fallback Rule State */
}

.brand-logo-box {
    margin-bottom: 2.5rem;
}

.brand-logo {
    height: 48px;
    width: auto;
}

.welcome-content {
    margin-bottom: 3rem;
}

.welcome-title {
    font-size: 2.5rem;
    font-weight: 600;
    line-height: 1.2;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.highlight-text {
    color: var(--forest-accent);
}

.welcome-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Trust Infrastructures Grid */
.trust-indicators {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-subtle);
}

.indicator-card {
    text-align: center;
}

.indicator-icon-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background-color: #1e293b;
    margin-bottom: 0.75rem;
    font-size: 1.15rem;
}

.text-forest { color: var(--forest-accent); }
.text-gold { color: var(--champagne); }

.indicator-label {
    font-size: 0.85rem;
    color: #94a3b8;
    font-weight: 500;
}

/* Right Panel: Interactive Form Target Architecture */
.form-side {
    width: 100%;
}

.mobile-logo-box {
    text-align: center;
    margin-bottom: 2.5rem;
}

.brand-logo-mobile {
    height: 40px;
    width: auto;
}

/* ==========================================================================
   3. INDIVIDUAL FORM ELEMENT UI DESIGNS
   ========================================================================== */
.auth-card {
    background: var(--bg-slate-card);
    border: 1px solid var(--border-subtle);
    border-radius: 16px;
    padding: 2.5rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.card-header {
    margin-bottom: 2rem;
}

.form-title {
    font-size: 1.65rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.form-subtitle {
    font-size: 0.95rem;
    color: #94a3b8;
    line-height: 1.5;
}

.secure-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.field-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.field-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.field-icon {
    position: absolute;
    left: 1rem;
    color: #475569;
    font-size: 1.05rem;
    pointer-events: none;
}

.auth-input {
    width: 100%;
    background: rgba(15, 20, 25, 0.6);
    border: 1px solid rgba(148, 163, 184, 0.15);
    color: var(--text-inputs);
    padding: 0.875rem 1rem 0.875rem 3rem;
    border-radius: 12px;
    font-size: 0.925rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.auth-input:focus {
    background: rgba(15, 20, 25, 0.8);
    border-color: var(--forest-primary);
    box-shadow: 0 0 0 3px rgba(45, 134, 89, 0.15);
    outline: none;
}

.auth-input::placeholder {
    color: rgba(226, 232, 240, 0.3);
}

/* Custom Interactive Password Eye Trigger */
.password-toggle-trigger {
    position: absolute;
    right: 1rem;
    background: none;
    border: none;
    color: #475569;
    cursor: pointer;
    font-size: 1.05rem;
    transition: color 0.2s ease;
}

.password-toggle-trigger:hover {
    color: var(--text-secondary);
}

/* Custom Semantic Checkbox Rules Engine */
.checkbox-group {
    margin: 0.25rem 0;
}

.checkbox-container {
    display: flex;
    align-items: center;
    position: relative;
    cursor: pointer;
    user-select: none;
}

.native-checkbox {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.custom-checkbox {
    height: 18px;
    width: 18px;
    background-color: #334155;
    border-radius: 4px;
    margin-right: 0.75rem;
    position: relative;
    transition: all 0.2s ease;
}

.checkbox-container:hover .native-checkbox ~ .custom-checkbox {
    background-color: #475569;
}

.checkbox-container .native-checkbox:checked ~ .custom-checkbox {
    background-color: var(--forest-primary);
}

.custom-checkbox::after {
    content: "";
    position: absolute;
    display: none;
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.checkbox-container .native-checkbox:checked ~ .custom-checkbox::after {
    display: block;
}

.checkbox-label {
    font-size: 0.875rem;
    color: #94a3b8;
}

/* Interactive Action Form Submit Buttons */
.auth-submit-btn {
    width: 100%;
    background-color: var(--forest-primary);
    color: var(--text-primary);
    border: none;
    padding: 0.95rem;
    border-radius: 12px;
    font-size: 0.925rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.auth-submit-btn:hover {
    background-color: var(--forest-hover);
}

.auth-submit-btn:active {
    transform: scale(0.99);
}

.arrow-icon {
    font-size: 0.85rem;
    transition: transform 0.2s ease;
}

.auth-submit-btn:hover .arrow-icon {
    transform: translateX(3px);
}

/* Middle Visual Form Separator Elements */
.divider-row {
    position: relative;
    text-align: center;
    margin: 0.5rem 0;
}

.divider-row::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    background-color: #334155;
    z-index: 1;
}

.divider-text {
    position: relative;
    background-color: #1a1f2e;
    padding: 0 1rem;
    color: var(--text-muted);
    font-size: 0.875rem;
    z-index: 2;
}

/* Secondary Registration Button Pathway Link */
.auth-register-btn {
    width: 100%;
    background-color: transparent;
    border: 1px solid rgba(45, 134, 89, 0.3);
    color: var(--text-secondary);
    text-decoration: none;
    padding: 0.95rem;
    border-radius: 12px;
    font-size: 0.925rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    transition: all 0.2s ease;
}

.auth-register-btn:hover {
    border-color: rgba(45, 134, 89, 0.6);
    background-color: rgba(45, 134, 89, 0.05);
    color: var(--text-primary);
}

.auth-link {
    color: var(--forest-primary);
    text-decoration: none;
    transition: color 0.2s ease;
    font-weight: 500;
}

.auth-link:hover {
    color: var(--forest-accent);
}

.card-footer {
    border-top: 1px solid rgba(51, 65, 85, 0.5);
    padding-top: 1.5rem;
    margin-top: 1.5rem;
}

.legal-notice {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.text-center { text-align: center; }


/* Error message */

.error-alert {
    display: none; 
    background-color: rgba(239, 68, 68, 0.1); 
    border: 1px solid rgba(239, 68, 68, 0.3); 
    border-radius: 0.75rem; 
    padding: 1rem; 
    max-width: 24rem;
    width: 100%;
}

.error-alert > * + * {
    margin-top: 0.5rem; 
}

.error-header {
    display: flex; 
    align-items: center; 
    margin-bottom: 0.5rem; 
}

.error-header > * + * {
    margin-left: 0.5rem; 
}

.error-icon {
    width: 1.25rem; 
    height: 1.25rem; 
    color: #f87171; 
}

.error-title {
    font-size: 0.875rem; 
    font-weight: 600; 
    color: #fca5a5; 
    margin: 0;
}

/* Itemized list arrangement and alignment offsets */
.error-list {
    margin-left: 1.75rem; 
    padding-left: 0;
    margin-top: 0;
    margin-bottom: 0;
    list-style-type: disc;
}

/* Compiles list item stack gaps */
.error-list > * + * {
    margin-top: 0.25rem; 
}

/* Individual list item description font treatment */
.error-item {
    font-size: 0.875rem; 
    color: #fca5a5;
    list-style: none; 
}

/* ==========================================================================
   4. DEVICE GRID RESPONSIVE MEDIA BREAKPOINTS
   ========================================================================== */
@media (min-width: 992px) {
    .auth-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 4rem;
    }
    
    .branding-side {
        display: block;
    }
    
    .mobile-logo-box {
        display: none;
    }
    
    .auth-card {
        padding: 3rem;
    }
}