/* =============================================================================
   RTM PRO-MAX LOGIN PAGE STYLES
   Consistent with main RTM Pro-Max Layout Design System
   ============================================================================= */

/* =============================================================================
   CSS VARIABLES - RTM Theme (matching main style.css)
   ============================================================================= */
:root {
    /* Primary Colors (Dark Theme) */
    --rtm-primary: #1a1a2e;
    --rtm-primary-light: #16213e;
    --rtm-primary-dark: #0f0f1a;

    /* Accent Colors (Neon) */
    --rtm-accent: #00d4ff;
    --rtm-accent-hover: #00b8e6;
    --rtm-accent-glow: rgba(0, 212, 255, 0.3);

    /* Semantic Colors */
    --rtm-success: #28a745;
    --rtm-success-light: #4ade80;
    --rtm-warning: #ffc107;
    --rtm-warning-light: #ffda6a;
    --rtm-danger: #dc3545;
    --rtm-danger-light: #f87171;
    --rtm-info: #17a2b8;

    /* Text Colors */
    --rtm-text-light: #ffffff;
    --rtm-text-muted: #a2a8d3;
    --rtm-text-secondary: #94a3b8;

    /* Spacing */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;

    /* Typography */
    --font-family-primary: 'Poppins', 'Roboto', sans-serif;

    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 15px 50px rgba(0, 0, 0, 0.25);

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.3s ease;
}

/* =============================================================================
   RESET AND BASE STYLES
   ============================================================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    height: 100%;
    width: 100%;
    font-size: 16px; /* Base font size for rem calculations */
}

body {
    font-family: var(--font-family-primary);
    min-height: 100vh;
    min-height: -webkit-fill-available; /* iOS Safari fix */
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    overflow-y: auto;
    background: var(--rtm-primary-dark);
    position: relative;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* =============================================================================
   UNIVERSE BACKGROUND
   ============================================================================= */
.universe-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: linear-gradient(180deg, var(--rtm-primary-dark) 0%, var(--rtm-primary-light) 100%);
}

/* Nebula Layers */
.nebula {
    position: absolute;
    filter: blur(100px);
    opacity: 0.25;
    will-change: transform, opacity;
    animation: nebulaDrift 30s infinite ease-in-out;
}

.nebula-1 {
    width: 50%;
    height: 50%;
    top: 10%;
    left: 10%;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.5), transparent);
}

.nebula-2 {
    width: 40%;
    height: 40%;
    top: 40%;
    right: 20%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.4), transparent);
}

.nebula-3 {
    width: 60%;
    height: 60%;
    bottom: 0%;
    left: 30%;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.3), transparent);
}

@keyframes nebulaDrift {
    0% { transform: translate(-5%, -5%) scale(1); opacity: 0.25; }
    50% { transform: translate(5%, 5%) scale(1.02); opacity: 0.35; }
    100% { transform: translate(-5%, -5%) scale(1); opacity: 0.25; }
}

/* Distant Planet */
.planet {
    position: absolute;
    width: 120px;
    height: 120px;
    bottom: 20%;
    right: 15%;
    background: radial-gradient(circle at 30% 30%, var(--rtm-primary-light), var(--rtm-primary-dark));
    border-radius: 50%;
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.4), inset 0 0 10px rgba(0, 0, 0, 0.8);
    opacity: 0.85;
}

/* Orbital Moon */
.moon {
    width: 30px;
    height: 30px;
    background: radial-gradient(circle at 40% 40%, #e2e8f0, #64748b);
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(226, 232, 240, 0.3);
    opacity: 0.9;
    z-index: 5;
}

/* Meteors with Green Trails */
.meteor {
    position: absolute;
    width: 8px;
    height: 8px;
    background: radial-gradient(circle, var(--rtm-success-light), var(--rtm-success));
    border-radius: 50%;
    box-shadow: 0 0 20px rgba(34, 197, 94, 0.9), 0 0 40px rgba(34, 197, 94, 0.5);
    opacity: 0.9;
    z-index: 4;
}

.meteor::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 3px;
    background: linear-gradient(to left, rgba(34, 197, 94, 0.7), transparent);
    filter: blur(2px);
    top: 50%;
    left: -296px;
    transform: translateY(-50%);
    z-index: -1;
    animation: shimmer 1.5s infinite ease-in-out;
}

@keyframes shimmer {
    0% { opacity: 0.7; }
    50% { opacity: 1; }
    100% { opacity: 0.7; }
}

/* =============================================================================
   LOGIN WRAPPER & CONTAINER
   ============================================================================= */
.login-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    min-height: 100vh;
    min-height: -webkit-fill-available;
    padding: var(--space-md);
    position: relative;
    z-index: 10;
}

.login-container {
    background: rgba(26, 26, 46, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(0, 212, 255, 0.15);
    padding: var(--space-xl);
    border-radius: 16px;
    box-shadow: var(--shadow-lg),
                inset 0 0 20px rgba(0, 212, 255, 0.05),
                0 0 40px rgba(0, 212, 255, 0.1);
    max-width: 420px;
    width: 100%;
    animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* =============================================================================
   LOGO
   ============================================================================= */
.logo {
    text-align: center;
    margin-bottom: var(--space-lg);
}

.logo img {
    max-width: 180px;
    height: auto;
    display: block;
    margin: 0 auto;
    filter: drop-shadow(0 0 10px rgba(0, 212, 255, 0.3));
}

/* =============================================================================
   TYPOGRAPHY
   ============================================================================= */
h1 {
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--rtm-text-light);
    text-align: center;
    margin-bottom: var(--space-sm);
    text-shadow: 0 0 15px var(--rtm-accent-glow);
}

.subtitle {
    text-align: center;
    color: var(--rtm-text-muted);
    font-size: 0.95rem;
    margin-bottom: var(--space-lg);
}

/* =============================================================================
   ALERT MESSAGES
   ============================================================================= */
.alert {
    padding: var(--space-md);
    border-radius: 8px;
    margin-bottom: var(--space-md);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.alert i,
.alert .fas {
    font-size: 1rem;
}

.alert-warning {
    background: rgba(255, 193, 7, 0.15);
    border: 1px solid rgba(255, 193, 7, 0.3);
    color: var(--rtm-warning-light);
}

.alert-danger {
    background: rgba(220, 53, 69, 0.15);
    border: 1px solid rgba(220, 53, 69, 0.3);
    color: var(--rtm-danger-light);
}

.alert-info {
    background: rgba(0, 212, 255, 0.15);
    border: 1px solid rgba(0, 212, 255, 0.3);
    color: var(--rtm-accent);
}

.alert-success {
    background: rgba(40, 167, 69, 0.15);
    border: 1px solid rgba(40, 167, 69, 0.3);
    color: var(--rtm-success-light);
}

/* =============================================================================
   VERIFICATION STEPS
   ============================================================================= */
.verification-steps {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: var(--space-lg);
    flex-wrap: wrap;
    gap: var(--space-sm);
}

.step {
    display: flex;
    align-items: center;
    color: var(--rtm-text-muted);
    font-size: 0.85rem;
}

.step.completed {
    color: var(--rtm-success-light);
}

.step.active {
    color: var(--rtm-accent);
    font-weight: 600;
}

.step-number {
    background: rgba(255, 255, 255, 0.1);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: var(--space-sm);
    font-size: 0.75rem;
    font-weight: 600;
}

.step.completed .step-number {
    background: var(--rtm-success);
}

.step.active .step-number {
    background: var(--rtm-accent);
    color: var(--rtm-primary-dark);
}

.step-connector {
    width: 40px;
    height: 2px;
    background: rgba(255, 255, 255, 0.2);
    margin: 0 var(--space-sm);
}

/* =============================================================================
   FORM ELEMENTS
   ============================================================================= */
.form-group {
    margin-bottom: var(--space-md);
}

label {
    display: block;
    font-weight: 500;
    color: var(--rtm-text-light);
    margin-bottom: var(--space-xs);
    font-size: 0.9rem;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 12px;
    color: var(--rtm-text-secondary);
    font-size: 1.1rem;
    z-index: 1;
}

input[type="text"],
input[type="password"],
input[type="number"] {
    width: 100%;
    padding: 14px 14px 14px 44px; /* 14px for touch-friendly height */
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    font-size: 16px; /* Prevents iOS zoom on focus */
    color: var(--rtm-text-light);
    transition: border-color var(--transition-normal), box-shadow var(--transition-normal);
    font-family: inherit;
    min-height: 48px; /* Touch-friendly minimum height */
}

input::placeholder {
    color: var(--rtm-text-secondary);
    opacity: 0.7;
}

input:hover {
    border-color: rgba(0, 212, 255, 0.4);
}

input:focus {
    outline: none;
    border-color: var(--rtm-accent);
    box-shadow: 0 0 0 3px var(--rtm-accent-glow);
    background: rgba(255, 255, 255, 0.08);
}

/* Password Toggle */
.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--rtm-text-secondary);
    font-size: 1.1rem;
    padding: 8px;
    border-radius: 4px;
    transition: color var(--transition-fast);
    z-index: 1;
}

.password-toggle:hover {
    color: var(--rtm-accent);
}

/* =============================================================================
   FORM OPTIONS (Remember Me)
   ============================================================================= */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-md);
    flex-wrap: wrap;
    gap: var(--space-sm);
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    cursor: pointer;
}

.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--rtm-accent);
    cursor: pointer;
}

.checkbox-group label {
    margin-bottom: 0;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--rtm-text-muted);
}

.forgot-password {
    color: var(--rtm-accent);
    font-size: 0.85rem;
    text-decoration: none;
    transition: color var(--transition-fast);
}

.forgot-password:hover {
    color: var(--rtm-accent-hover);
    text-decoration: underline;
}

/* =============================================================================
   CAPTCHA
   ============================================================================= */
.captcha-group {
    text-align: center;
    margin-bottom: var(--space-md);
    padding: var(--space-md);
    background: rgba(0, 212, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(0, 212, 255, 0.1);
}

.captcha-question {
    color: var(--rtm-text-light);
    font-weight: 600;
    margin-bottom: var(--space-sm);
    font-size: 1rem;
}

.captcha-group input[type="number"] {
    padding-left: 14px;
    text-align: center;
    font-weight: 600;
    letter-spacing: 2px;
    max-width: 150px;
    margin: 0 auto;
    display: block;
}

/* Remove number input spinners */
.captcha-group input[type="number"]::-webkit-outer-spin-button,
.captcha-group input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.captcha-group input[type="number"] {
    -moz-appearance: textfield;
}

/* =============================================================================
   BUTTONS
   ============================================================================= */
button {
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, var(--rtm-accent) 0%, #0099cc 100%);
    color: var(--rtm-primary-dark);
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform var(--transition-fast), box-shadow var(--transition-normal);
    font-family: inherit;
    min-height: 48px; /* Touch-friendly */
    -webkit-tap-highlight-color: transparent;
}

button:hover:not(.loading):not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 212, 255, 0.4);
}

button:active:not(.loading):not(:disabled) {
    transform: translateY(0);
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Loading State */
.loading {
    opacity: 0.8;
    cursor: wait;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 2px solid var(--rtm-primary-dark);
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

@keyframes spin {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Success State */
.success {
    background: linear-gradient(135deg, var(--rtm-success) 0%, #1e7e34 100%) !important;
    color: var(--rtm-text-light) !important;
}

/* =============================================================================
   ERROR MESSAGE
   ============================================================================= */
.error-message {
    color: var(--rtm-danger-light);
    text-align: center;
    font-size: 0.9rem;
    margin-top: var(--space-md);
    padding: var(--space-sm) var(--space-md);
    background: rgba(220, 53, 69, 0.1);
    border-radius: 6px;
    display: none;
}

.error-message:not(:empty) {
    display: block;
}

/* =============================================================================
   SMS VERIFICATION CONTAINER
   ============================================================================= */
.sms-verification-container {
    display: none;
    margin-top: var(--space-lg);
    padding: var(--space-lg);
    background: rgba(0, 212, 255, 0.05);
    border-radius: 12px;
    border: 1px solid rgba(0, 212, 255, 0.2);
}

.sms-verification-container.show {
    display: block;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sms-info {
    text-align: center;
    margin-bottom: var(--space-md);
    color: var(--rtm-text-light);
}

.sms-info .phone-number {
    font-weight: 600;
    color: var(--rtm-accent);
    font-size: 1.1rem;
}

.sms-code-input {
    text-align: center !important;
    font-size: 1.25rem !important;
    letter-spacing: 4px !important;
    font-weight: 600 !important;
    padding-left: 14px !important;
}

.sms-attempts-info {
    text-align: center;
    font-size: 0.8rem;
    color: var(--rtm-warning-light);
    margin-bottom: var(--space-sm);
    padding: var(--space-sm);
    background: rgba(255, 193, 7, 0.1);
    border-radius: 6px;
}

.back-to-login {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--rtm-text-light);
    padding: 10px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    text-decoration: none;
    display: inline-block;
    margin-top: var(--space-md);
    transition: all var(--transition-fast);
    min-height: 44px;
    line-height: 24px;
}

.back-to-login:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--rtm-accent);
    color: var(--rtm-accent);
    text-decoration: none;
}

/* =============================================================================
   USER PANEL BUTTON
   ============================================================================= */
.user-panel-button {
    display: block;
    width: 100%;
    padding: 14px 20px;
    margin-top: var(--space-md);
    background: linear-gradient(135deg, var(--rtm-success) 0%, #1e7e34 100%);
    color: var(--rtm-text-light);
    text-align: center;
    border-radius: 8px;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    font-family: inherit;
    transition: transform var(--transition-fast), box-shadow var(--transition-normal);
    min-height: 48px;
    line-height: 20px;
}

.user-panel-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.4);
    color: var(--rtm-text-light);
    text-decoration: none;
}

/* =============================================================================
   FOOTER
   ============================================================================= */
footer {
    text-align: center;
    margin-top: var(--space-lg);
    color: var(--rtm-text-secondary);
    font-size: 0.8rem;
}

footer p {
    opacity: 0.7;
}

/* =============================================================================
   PARTICLE BURST ANIMATION
   ============================================================================= */
.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--rtm-accent);
    animation: burst 1s ease-out forwards;
    z-index: 10;
}

@keyframes burst {
    0% { transform: scale(1); opacity: 1; }
    100% { transform: translate(calc((var(--x) - 0.5) * 80px), calc((var(--y) - 0.5) * 80px)) scale(0); opacity: 0; }
}

/* Cache Refresh Indicator */
.cache-refresh-indicator {
    position: fixed;
    top: 10px;
    right: 10px;
    background: rgba(40, 167, 69, 0.9);
    color: white;
    padding: var(--space-sm) var(--space-md);
    border-radius: 6px;
    font-size: 0.85rem;
    display: none;
    z-index: 10000;
    backdrop-filter: blur(10px);
}

/* =============================================================================
   RESPONSIVE BREAKPOINTS
   Matching RTM Pro-Max Layout System:
   - xs: 0 - 575px (mobile)
   - sm: 576px - 767px (large phones)
   - md: 768px - 991px (tablets)
   - lg: 992px - 1199px (laptops)
   - xl: 1200px+ (desktops)
   ============================================================================= */

/* Large Phones and up (576px+) */
@media (min-width: 576px) {
    .login-container {
        padding: var(--space-xl) 40px;
    }

    h1 {
        font-size: 1.875rem;
    }

    .logo img {
        max-width: 200px;
    }
}

/* Tablets (max-width: 767px) */
@media (max-width: 767px) {
    body {
        align-items: flex-start;
        padding-top: var(--space-md);
    }

    .login-wrapper {
        padding: var(--space-sm);
        min-height: auto;
    }

    .login-container {
        padding: var(--space-lg);
        max-width: 100%;
        margin: var(--space-md);
        border-radius: 12px;
    }

    h1 {
        font-size: 1.5rem;
    }

    .subtitle {
        font-size: 0.875rem;
    }

    .logo img {
        max-width: 150px;
    }

    /* Reduce space effects on mobile */
    .planet {
        width: 80px;
        height: 80px;
        right: 5%;
        bottom: 10%;
        opacity: 0.5;
    }

    .moon {
        width: 20px;
        height: 20px;
    }

    .meteor {
        width: 5px;
        height: 5px;
    }

    .meteor::after {
        width: 150px;
    }

    .nebula {
        opacity: 0.15;
    }
}

/* Small Mobile (max-width: 575px) */
@media (max-width: 575px) {
    body {
        align-items: flex-start;
    }

    .login-wrapper {
        padding: var(--space-xs);
    }

    .login-container {
        padding: var(--space-md);
        margin: var(--space-sm);
        border-radius: 10px;
    }

    h1 {
        font-size: 1.35rem;
    }

    .subtitle {
        font-size: 0.85rem;
        margin-bottom: var(--space-md);
    }

    .logo img {
        max-width: 130px;
    }

    .verification-steps {
        margin-bottom: var(--space-md);
    }

    .step {
        font-size: 0.75rem;
    }

    .step-number {
        width: 20px;
        height: 20px;
        font-size: 0.65rem;
    }

    .step-connector {
        width: 25px;
    }

    label {
        font-size: 0.85rem;
    }

    input[type="text"],
    input[type="password"],
    input[type="number"] {
        padding: 12px 12px 12px 40px;
        font-size: 16px; /* Keep 16px to prevent iOS zoom */
    }

    .input-icon {
        left: 10px;
        font-size: 1rem;
    }

    .password-toggle {
        right: 10px;
        font-size: 1rem;
    }

    button,
    .user-panel-button {
        padding: 12px 16px;
        font-size: 0.95rem;
    }

    .captcha-group {
        padding: var(--space-sm);
    }

    .captcha-question {
        font-size: 0.9rem;
    }

    .sms-verification-container {
        padding: var(--space-md);
    }

    .sms-code-input {
        font-size: 1.1rem !important;
        letter-spacing: 3px !important;
    }

    .alert {
        padding: var(--space-sm);
        font-size: 0.85rem;
    }

    footer {
        font-size: 0.75rem;
        margin-top: var(--space-md);
    }

    /* Minimize space effects on very small screens */
    .planet {
        width: 60px;
        height: 60px;
        opacity: 0.3;
    }

    .moon {
        display: none;
    }

    .meteor::after {
        width: 100px;
    }
}

/* Very Small Mobile (max-width: 375px) */
@media (max-width: 375px) {
    .login-container {
        padding: var(--space-md) var(--space-sm);
        margin: var(--space-xs);
    }

    h1 {
        font-size: 1.2rem;
    }

    .logo img {
        max-width: 110px;
    }

    .step span {
        display: none; /* Hide step text, show only numbers */
    }

    .step-connector {
        width: 20px;
    }
}

/* Landscape Mobile */
@media (max-height: 500px) and (orientation: landscape) {
    body {
        align-items: flex-start;
    }

    .login-wrapper {
        padding: var(--space-sm);
        min-height: auto;
    }

    .login-container {
        padding: var(--space-md);
    }

    .logo img {
        max-width: 100px;
        margin-bottom: var(--space-sm);
    }

    h1 {
        font-size: 1.25rem;
        margin-bottom: var(--space-xs);
    }

    .subtitle {
        margin-bottom: var(--space-sm);
    }

    .verification-steps {
        margin-bottom: var(--space-sm);
    }

    .form-group {
        margin-bottom: var(--space-sm);
    }

    .captcha-group {
        margin-bottom: var(--space-sm);
        padding: var(--space-sm);
    }

    footer {
        margin-top: var(--space-sm);
    }

    /* Hide space effects in landscape */
    .planet,
    .moon {
        display: none;
    }
}

/* =============================================================================
   TOUCH DEVICE OPTIMIZATIONS
   ============================================================================= */
@media (hover: none) and (pointer: coarse) {
    /* Larger touch targets */
    button,
    .user-panel-button,
    .back-to-login {
        min-height: 48px;
    }

    input[type="text"],
    input[type="password"],
    input[type="number"] {
        min-height: 48px;
    }

    .password-toggle {
        padding: 12px;
    }

    .checkbox-group input[type="checkbox"] {
        width: 22px;
        height: 22px;
    }

    /* Remove hover effects that don't work well on touch */
    button:hover:not(.loading):not(:disabled) {
        transform: none;
    }

    .user-panel-button:hover {
        transform: none;
    }
}

/* =============================================================================
   REDUCED MOTION (Accessibility)
   ============================================================================= */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .nebula,
    .meteor::after {
        animation: none;
    }
}

/* =============================================================================
   HIGH CONTRAST MODE (Accessibility)
   ============================================================================= */
@media (prefers-contrast: high) {
    .login-container {
        border: 2px solid var(--rtm-accent);
    }

    input[type="text"],
    input[type="password"],
    input[type="number"] {
        border: 2px solid rgba(255, 255, 255, 0.5);
    }

    input:focus {
        border-color: var(--rtm-accent);
        box-shadow: 0 0 0 4px var(--rtm-accent-glow);
    }

    button {
        border: 2px solid var(--rtm-accent);
    }
}

/* =============================================================================
   PRINT STYLES
   ============================================================================= */
@media print {
    .universe-background,
    .nebula,
    .planet,
    .moon,
    .meteor,
    #meteorContainer,
    .cache-refresh-indicator {
        display: none !important;
    }

    body {
        background: white;
    }

    .login-container {
        background: white;
        box-shadow: none;
        border: 1px solid #ccc;
        color: black;
    }

    h1, label, .subtitle, footer {
        color: black;
    }
}
