/* ===================================
   MODERN LOGIN PAGE DESIGN 2024
   Apple iCloud inspired clean interface
   ================================== */

/* Modern Login Background */
body.modern-login {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background: #f5f5f7;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica', 'Arial', sans-serif;
    overflow-x: hidden;
    position: relative;
}

/* Modern Page Center */
.page-center {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

.page-center-in {
    width: 100%;
    max-width: 440px;
    display: block;
    padding: 0;
}

/* Modern Logo */
.modern-logo {
    height: 60px;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Modern Sign Box */
.sign-box.modern {
    background: #ffffff;
    border: 1px solid #d2d2d7;
    border-radius: 18px;
    padding: 3.5rem 3rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: visible;
    max-width: none;
    margin: 0;
}

.sign-box.modern::before {
    display: none;
}

/* Modern Header */
.modern-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto 2rem;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.login-icon::before {
    content: '';
    position: absolute;
    inset: 8px;
    border-radius: 50%;
    background: conic-gradient(from 0deg, #ff9500, #ff2d55, #af52de, #5e5ce6, #32ade6, #30d158, #ffcc00, #ff9500);
    opacity: 0.15;
}

.login-icon i {
    font-size: 2.5rem;
    color: #1d1d1f;
    position: relative;
    z-index: 1;
}

.sign-title.modern {
    font-size: 1.75rem;
    font-weight: 600;
    color: #1d1d1f;
    margin: 0 0 0.25rem 0;
    letter-spacing: -0.02em;
}

.sign-subtitle {
    color: #86868b;
    font-size: 0.95rem;
    margin: 0;
    font-weight: 400;
}

/* Modern Form Content */
.modern-form-content {
    margin-top: 2rem;
}

/* Modern Form Groups */
.form-group.modern {
    margin-bottom: 1.25rem;
    position: relative;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    right: 1rem;
    color: #86868b;
    font-size: 1rem;
    z-index: 3;
    transition: color 0.2s ease;
}

.form-control.modern {
    width: 100%;
    padding: 0.875rem 3rem 0.875rem 1rem;
    border: 1px solid #d2d2d7;
    border-radius: 10px;
    font-size: 1rem;
    background: #ffffff;
    transition: all 0.2s ease;
    color: #1d1d1f;
}

.form-control.modern::placeholder {
    color: #86868b;
}

.form-control.modern:focus {
    outline: none;
    border-color: #0071e3;
    box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.1);
}

.form-control.modern:focus + .input-icon,
.input-wrapper:focus-within .input-icon {
    color: #0071e3;
}

/* Modern Checkbox */
.modern-checkbox {
    margin: 1.25rem 0;
}

.modern-checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.875rem;
    color: #1d1d1f;
    user-select: none;
}

.modern-checkbox-input {
    display: none;
}

.checkmark {
    width: 18px;
    height: 18px;
    border: 1px solid #d2d2d7;
    border-radius: 4px;
    margin-right: 0.5rem;
    position: relative;
    transition: all 0.2s ease;
    background: white;
}

.modern-checkbox-input:checked + .checkmark {
    background: #0071e3;
    border-color: #0071e3;
}

.modern-checkbox-input:checked + .checkmark::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 11px;
    font-weight: bold;
}

/* Modern Button */
.btn-modern-primary {
    width: 100%;
    padding: 0.875rem 1.5rem;
    background: #0071e3;
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 1.5rem 0 1rem 0;
}

.btn-modern-primary:hover {
    background: #0077ed;
}

.btn-modern-primary:active {
    background: #006edb;
    transform: scale(0.98);
}

.btn-modern-primary i {
    display: none;
}

/* Modern Footer */
.modern-footer {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e5e7;
}

.help-text {
    color: #86868b;
    font-size: 0.875rem;
    margin: 0 0 0.5rem 0;
}

.help-link {
    color: #0071e3;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 400;
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    transition: all 0.2s ease;
}

.help-link:hover {
    color: #0077ed;
    text-decoration: none;
}

.help-link i {
    font-size: 0.75rem;
}

/* Validation Errors */
.validation-error {
    color: #ff3b30;
    font-size: 0.8125rem;
    margin-top: 0.375rem;
    display: block;
}

.alert {
    border-radius: 10px;
    padding: 0.875rem 1rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.alert-danger {
    background-color: #fff5f5;
    border: 1px solid #ffd4d4;
    color: #c41e3a;
}

/* Responsive Design */
@media (max-width: 768px) {
    .page-center {
        padding: 1rem;
    }

    .sign-box.modern {
        padding: 2.5rem 2rem;
        border-radius: 16px;
    }

    .login-icon {
        width: 80px;
        height: 80px;
        margin-bottom: 1.5rem;
    }

    .sign-title.modern {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .sign-box.modern {
        padding: 2rem 1.5rem;
    }

    .modern-header {
        margin-bottom: 1.5rem;
    }
}
