/* Modern Enterprise Authentication Styles */
@import url('../fonts/fonts.css');

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    direction: rtl;
    font-family: 'Vazirmatn', 'Tahoma', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Modern Container */
.auth-container {
    display: flex;
    min-height: 100vh;
    position: relative;
}

/* Desktop and large screens - keep right panel at reasonable height */
@media (min-width: 1200px) {
    .auth-presentation {
        height: 80vh;
        max-height: 80vh;
    }
}

/* Left Side - Project Presentation */
.auth-presentation {
    flex: 1;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.9) 0%, rgba(118, 75, 162, 0.9) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 40px 30px;
    position: relative;
    overflow: hidden;
    height: 100vh;
    max-height: 100vh;
    overflow-y: auto;
}

.auth-presentation::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.presentation-content {
    text-align: center;
    color: white;
    z-index: 2;
    position: relative;
    max-width: 450px;
    width: 100%;
}

.presentation-logo {
    width: 70px;
    height: 70px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.presentation-logo i {
    font-size: 2.5rem;
    color: white;
}

.presentation-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 8px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.presentation-subtitle {
    font-size: 0.9rem;
    margin-bottom: 15px;
    opacity: 0.9;
    line-height: 1.3;
}

.presentation-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 10px;
    margin-top: 20px;
}

.feature-item {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, 0.15);
}

.feature-icon {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 10px;
}

.feature-icon i {
    font-size: 1.2rem;
    color: white;
}

.feature-title {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 6px;
}

.feature-description {
    font-size: 0.75rem;
    opacity: 0.8;
    line-height: 1.3;
}

/* Right Side - Authentication Form */
.auth-form-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
    background: white;
    position: relative;
    max-height: 100vh;
    overflow-y: auto;
}

.auth-form-card {
    width: 100%;
    max-width: 450px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    padding: 35px 30px;
    position: relative;
    overflow: hidden;
}

.auth-form-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #667eea, #764ba2);
}

.auth-form-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-form-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
}

.auth-form-subtitle {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0;
}

/* Modern Form Styles */
.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-label {
    display: block;
    margin-bottom: 6px;
    color: #1a1a1a;
    font-weight: 600;
    font-size: 0.85rem;
}

.input-container {
    position: relative;
    display: flex;
    align-items: center;
    background: #f8f9fa;
    border: 2px solid transparent;
    border-radius: 10px;
    transition: all 0.3s ease;
    overflow: hidden;
}

.input-container:focus-within {
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.input-icon {
    padding: 12px 15px;
    color: #6c757d;
    font-size: 1rem;
    background: transparent;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
}

.form-input {
    flex: 1;
    border: none;
    padding: 12px 15px;
    font-size: 0.95rem;
    background: transparent;
    color: #1a1a1a;
    font-family: 'Vazirmatn', 'Tahoma', sans-serif;
    direction: rtl;
}

.form-input:focus {
    outline: none;
}

.form-input::placeholder {
    color: #adb5bd;
    font-family: 'Vazirmatn', 'Tahoma', sans-serif;
    direction: rtl;
    font-size: 0.9rem;
}

.password-toggle {
    padding: 12px 15px;
    background: transparent;
    border: none;
    color: #6c757d;
    cursor: pointer;
    transition: color 0.3s ease;
}

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

/* Modern Button */
.btn-modern {
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    font-family: 'Vazirmatn', 'Tahoma', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-modern:hover::before {
    left: 100%;
}

.btn-modern:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.btn-modern:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* Alert Styles */
.alert-modern {
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: 'Vazirmatn', 'Tahoma', sans-serif;
    direction: rtl;
    font-size: 0.85rem;
}

.alert-danger {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

.alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
}

.alert i {
    font-size: 1rem;
}

/* Footer */
.auth-form-footer {
    text-align: center;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
}

.auth-form-footer p {
    color: #666;
    margin: 0;
    font-size: 0.85rem;
}

.auth-form-footer a {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.auth-form-footer a:hover {
    color: #764ba2;
}

/* Validation Messages */
.validation-message {
    color: #dc2626;
    font-size: 0.75rem;
    margin-top: 6px;
    display: block;
    direction: rtl;
    font-family: 'Vazirmatn', 'Tahoma', sans-serif;
}

/* Loading Spinner */
.spinner-modern {
    width: 1rem;
    height: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .auth-container {
        flex-direction: column;
    }
    
    .auth-presentation {
        padding: 20px 15px;
        height: 30vh;
        min-height: 30vh;
        max-height: 30vh;
    }
    
    .presentation-logo {
        width: 50px;
        height: 50px;
        margin-bottom: 12px;
    }
    
    .presentation-title {
        font-size: 1.6rem;
        margin-bottom: 8px;
    }
    
    .presentation-subtitle {
        font-size: 0.9rem;
        margin-bottom: 15px;
    }
    
    .presentation-features {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 10px;
        margin-top: 20px;
    }
    
    .auth-form-container {
        padding: 20px;
        min-height: 65vh;
    }
    
    .auth-form-card {
        padding: 30px 25px;
    }
}

@media (max-width: 768px) {
    .auth-presentation {
        height: 25vh;
        min-height: 25vh;
        max-height: 25vh;
        padding: 15px 10px;
    }
    
    .presentation-logo {
        width: 40px;
        height: 40px;
        margin-bottom: 10px;
    }
    
    .presentation-title {
        font-size: 1.4rem;
        margin-bottom: 6px;
    }
    
    .presentation-subtitle {
        font-size: 0.85rem;
        margin-bottom: 12px;
    }
    
    .presentation-features {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
        gap: 8px;
        margin-top: 15px;
    }
    
    .auth-form-card {
        padding: 25px 20px;
        margin: 10px;
    }
    
    .auth-form-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .auth-presentation {
        display: none;
    }
    
    .auth-form-container {
        min-height: 100vh;
        padding: 15px;
    }
    
    .auth-form-card {
        margin: 0;
        padding: 20px 15px;
    }
}

/* Animation */
.auth-form-card {
    animation: slideInRight 0.6s ease-out;
}

.presentation-content {
    animation: slideInLeft 0.6s ease-out;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Row and Column Layout for Register */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* Select Input Styling */
.select-container {
    position: relative;
}

.select-container::after {
    content: '▼';
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    pointer-events: none;
    font-size: 0.7rem;
}

.form-select {
    appearance: none;
    background: transparent;
    border: none;
    padding: 12px 15px;
    font-size: 0.95rem;
    color: #1a1a1a;
    font-family: 'Vazirmatn', 'Tahoma', sans-serif;
    direction: rtl;
    width: 100%;
}

.form-select:focus {
    outline: none;
}

/* Textarea Styling */
.form-textarea {
    resize: vertical;
    min-height: 80px;
    font-family: 'Vazirmatn', 'Tahoma', sans-serif;
    direction: rtl;
}

/* Form Text */
.form-text {
    font-size: 0.75rem;
    color: #6c757d;
    margin-top: 6px;
    direction: rtl;
}

/* Hide default Blazor elements */
.auth-container .page,
.auth-container .sidebar,
.auth-container .top-row {
    display: none;
}

/* Ensure full screen */
.auth-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
} 