/* Change Password Page - Mobile Optimized */
:root {
    --primary: #0B4F6C;
    --primary-dark: #083b4f;
    --primary-light: #1a6b8a;
    --secondary: #10B981;
    --accent: #F59E0B;
    --danger: #EF4444;
    --dark: #1F2937;
    --gray-800: #1F2937;
    --gray-700: #374151;
    --gray-600: #4B5563;
    --gray-500: #6B7280;
    --gray-400: #9CA3AF;
    --gray-300: #D1D5DB;
    --gray-200: #E5E7EB;
    --gray-100: #F3F4F6;
    --white: #FFFFFF;
    --shadow: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-lg: 0 4px 12px rgba(0,0,0,0.08);
    --radius: 12px;
    --radius-sm: 8px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: var(--gray-100);
    color: var(--dark);
    line-height: 1.5;
    padding-bottom: 70px;
}

/* Mobile Header */
.mobile-header {
    position: sticky;
    top: 0;
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
    z-index: 100;
    box-shadow: var(--shadow);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
}

.back-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: var(--gray-100);
    border-radius: 50%;
    color: var(--gray-600);
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.back-btn:active {
    background: var(--gray-200);
    transform: scale(0.95);
}

.logo {
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
}

.logo-circle {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 18px;
    font-style: italic;
}

.logo-text {
    font-weight: 700;
    font-size: 18px;
    color: var(--primary);
}

.logo-text span {
    color: var(--primary);
}

.menu-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: var(--gray-100);
    border-radius: 50%;
    color: var(--gray-600);
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

/* Page Title */
.page-title {
    padding: 8px 16px 12px;
}

.page-title h1 {
    font-size: 24px;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 2px;
}

.page-title p {
    font-size: 14px;
    color: var(--gray-500);
}

/* Main Content */
.main-content {
    padding: 16px;
    max-width: 600px;
    margin: 0 auto;
}

/* Loading State */
.loading-state {
    text-align: center;
    padding: 40px 20px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--gray-200);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Info Card */
.info-card {
    background: #EFF6FF;
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid var(--primary-light);
}

.info-card i {
    font-size: 32px;
    color: var(--primary);
    width: 48px;
    height: 48px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.info-text h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 8px;
}

.info-text ul {
    list-style: none;
    font-size: 13px;
    color: var(--gray-700);
}

.info-text ul li {
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.info-text ul li::before {
    content: '•';
    color: var(--primary);
    font-weight: bold;
    font-size: 16px;
}

/* Password Form */
.password-form {
    background: var(--white);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
}

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

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--gray-700);
}

.form-group .required {
    color: var(--danger);
}

/* Password Input Wrapper */
.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrapper input {
    width: 100%;
    padding: 14px 45px 14px 14px;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius-sm);
    font-size: 15px;
    transition: all 0.2s;
}

.password-input-wrapper input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(11, 79, 108, 0.1);
}

.password-input-wrapper input.error {
    border-color: var(--danger);
}

.toggle-password {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    color: var(--gray-500);
    font-size: 18px;
    cursor: pointer;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toggle-password:active {
    color: var(--primary);
}

/* Password Strength Meter */
.password-strength {
    height: 4px;
    background: var(--gray-200);
    border-radius: 2px;
    margin-top: 8px;
    overflow: hidden;
}

.strength-bar {
    height: 100%;
    width: 0;
    transition: all 0.3s ease;
}

.strength-bar.weak {
    width: 25%;
    background: var(--danger);
}

.strength-bar.fair {
    width: 50%;
    background: var(--accent);
}

.strength-bar.good {
    width: 75%;
    background: var(--secondary);
}

.strength-bar.strong {
    width: 100%;
    background: var(--secondary);
}

.strength-text {
    font-size: 12px;
    margin-top: 4px;
    color: var(--gray-500);
}

.strength-text.weak { color: var(--danger); }
.strength-text.fair { color: var(--accent); }
.strength-text.good { color: var(--secondary); }
.strength-text.strong { color: var(--secondary); }

/* Password Match Indicator */
.password-match {
    font-size: 12px;
    margin-top: 4px;
    min-height: 18px;
}

.password-match.match {
    color: var(--secondary);
}

.password-match.error {
    color: var(--danger);
}

/* Password Checklist */
.password-checklist {
    background: var(--gray-100);
    border-radius: var(--radius-sm);
    padding: 16px;
    margin: 20px 0;
}

.checklist-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 0;
    font-size: 13px;
    color: var(--gray-600);
    transition: all 0.2s;
}

.checklist-item.valid {
    color: var(--secondary);
}

.checklist-item i {
    width: 18px;
    font-size: 14px;
}

.checklist-item.valid i {
    color: var(--secondary);
}

/* Session Section */
.session-section {
    background: var(--gray-100);
    border-radius: var(--radius-sm);
    padding: 16px;
    margin: 20px 0;
}

.session-section h3 {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--dark);
}

.session-section h3 i {
    color: var(--primary);
}

.form-check {
    margin-bottom: 8px;
}

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

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.session-note {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--gray-500);
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--gray-200);
}

.session-note i {
    color: var(--primary);
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.btn-primary {
    flex: 2;
    padding: 14px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 30px;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s;
}

.btn-primary:active {
    background: var(--primary-dark);
    transform: scale(0.98);
}

.btn-primary:disabled {
    background: var(--gray-300);
    cursor: not-allowed;
}

.btn-secondary {
    flex: 1;
    padding: 14px;
    background: var(--white);
    color: var(--gray-700);
    border: 1px solid var(--gray-300);
    border-radius: 30px;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-secondary:active {
    background: var(--gray-100);
}

/* Forgot Password Link */
.forgot-password {
    text-align: center;
    margin: 20px 0;
}

.forgot-password a {
    color: var(--primary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
}

.forgot-password a:active {
    text-decoration: underline;
}

/* Recent Changes */
.recent-changes {
    background: var(--white);
    border-radius: var(--radius);
    padding: 20px;
    margin-top: 20px;
    box-shadow: var(--shadow);
}

.recent-changes h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--dark);
}

.recent-changes h3 i {
    color: var(--primary);
}

.changes-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.change-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid var(--gray-100);
}

.change-item:last-child {
    border-bottom: none;
}

.change-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 14px;
}

.change-details {
    flex: 1;
}

.change-device {
    font-size: 14px;
    font-weight: 500;
    color: var(--dark);
    margin-bottom: 2px;
}

.change-time {
    font-size: 11px;
    color: var(--gray-500);
}

.change-location {
    font-size: 11px;
    color: var(--gray-500);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: var(--radius);
    width: 100%;
    max-width: 400px;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideUp 0.3s ease;
    padding: 24px;
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
}

.modal-icon.success {
    background: #E7F5E8;
    color: var(--secondary);
}

.modal-icon.error {
    background: #FEE2E2;
    color: var(--danger);
}

.modal-icon.warning {
    background: #FEF3C7;
    color: var(--accent);
}

.modal h3 {
    text-align: center;
    font-size: 20px;
    margin-bottom: 8px;
    color: var(--dark);
}

.modal p {
    text-align: center;
    color: var(--gray-600);
    margin-bottom: 20px;
}

.modal-actions {
    display: flex;
    gap: 12px;
}

/* Bottom Navigation */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--white);
    border-top: 1px solid var(--gray-200);
    display: flex;
    padding: 8px 0 12px;
    z-index: 100;
}

.nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--gray-400);
    font-size: 11px;
    gap: 4px;
}

.nav-item i {
    font-size: 20px;
}

.nav-item.active {
    color: var(--primary);
}

/* Toast */
.toast {
    position: fixed;
    bottom: 80px;
    left: 16px;
    right: 16px;
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 14px 20px;
    border-radius: 30px;
    font-size: 14px;
    text-align: center;
    z-index: 2000;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s;
    max-width: 400px;
    margin: 0 auto;
}

.toast.show {
    transform: translateY(0);
    opacity: 1;
}

.toast.success {
    background: var(--secondary);
}

.toast.error {
    background: var(--danger);
}

/* Responsive */
@media (max-width: 480px) {
    .info-card {
        flex-direction: column;
        text-align: center;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
    }
    
    .modal-actions {
        flex-direction: column;
    }
    
    .password-checklist {
        font-size: 12px;
    }
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
    /* Add dark mode styles if needed */
}