:root {
            --primary: #6366f1;
            --primary-dark: #4f46e5;
            --primary-light: #a5b4fc;
            --secondary: #06b6d4;
            --secondary-dark: #0891b2;
            --accent: #f59e0b;
            --success: #10b981;
            --error: #ef4444;
            --warning: #f59e0b;
            --info: #3b82f6;
            --bg-primary: #ffffff;
            --bg-secondary: #f8fafc;
            --bg-tertiary: #f1f5f9;
            --text-primary: #0f172a;
            --text-secondary: #64748b;
            --text-tertiary: #94a3b8;
            --border-primary: #e2e8f0;
            --border-secondary: #cbd5e1;
            --shadow-color: rgba(15, 23, 42, 0.08);
            --dark-bg-primary: #0f172a;
            --dark-bg-secondary: #1e293b;
            --dark-bg-tertiary: #334155;
            --dark-text-primary: #f1f5f9;
            --dark-text-secondary: #cbd5e1;
            --dark-text-tertiary: #94a3b8;
            --dark-border-primary: #334155;
            --dark-border-secondary: #475569;
            --dark-shadow-color: rgba(0, 0, 0, 0.3);
            --gradient-primary: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
            --gradient-secondary: linear-gradient(135deg, var(--secondary) 0%, var(--primary) 100%);
            --gradient-accent: linear-gradient(135deg, var(--accent) 0%, #ff6b35 100%);
            --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
            --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
            --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
            --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
            --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
            --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
            --shadow-glow: 0 0 20px rgba(99, 102, 241, 0.3);
            --animation-fast: 0.15s;
            --animation-normal: 0.3s;
            --animation-slow: 0.5s;
            --ease-out-cubic: cubic-bezier(0.33, 1, 0.68, 1);
            --ease-in-out-cubic: cubic-bezier(0.65, 0, 0.35, 1);
        }
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }
        html {
            font-size: 16px;
            scroll-behavior: smooth;
        }
        body {
            font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
            font-weight: 400;
            line-height: 1.6;
            color: var(--text-primary);
            background: var(--bg-secondary);
            overflow-x: hidden;
            min-height: 100vh;
            position: relative;
        }
        body::before {
            content: '';
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            z-index: -1;
            background: 
                radial-gradient(circle at 20% 80%, rgba(99, 102, 241, 0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(6, 182, 212, 0.08) 0%, transparent 50%),
                radial-gradient(circle at 40% 40%, rgba(165, 180, 252, 0.06) 0%, transparent 50%),
                linear-gradient(135deg, var(--bg-secondary) 0%, #f8fafc 100%);
            animation: backgroundFlow 20s ease-in-out infinite;
        }
        body.dark-mode {
            background: var(--dark-bg-primary);
            color: var(--dark-text-primary);
        }
        body.dark-mode::before {
            background: 
                radial-gradient(circle at 20% 80%, rgba(99, 102, 241, 0.08) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(6, 182, 212, 0.06) 0%, transparent 50%),
                radial-gradient(circle at 40% 40%, rgba(165, 180, 252, 0.04) 0%, transparent 50%),
                linear-gradient(135deg, var(--dark-bg-primary) 0%, #1e293b 100%);
        }
        @keyframes backgroundFlow {
            0%, 100% { transform: translateX(0) translateY(0) scale(1); }
            33% { transform: translateX(-10px) translateY(-15px) scale(1.02); }
            66% { transform: translateX(15px) translateY(10px) scale(0.98); }
        }
        .register-wrapper {
            min-height: 100vh;
            padding: 2rem 1rem;
            display: flex;
            align-items: center;
            justify-content: center;
            position: relative;
            z-index: 1;
        }
        .register-container {
            width: 100%;
            max-width: 680px;
            position: relative;
        }
        .register-card {
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(20px);
            -webkit-backdrop-filter: blur(20px);
            border: 1px solid rgba(255, 255, 255, 0.3);
            border-radius: 24px;
            box-shadow: var(--shadow-2xl);
            overflow: hidden;
            position: relative;
            animation: cardEntrance 0.8s var(--ease-out-cubic);
            transform-origin: center;
        }
        body.dark-mode .register-card {
            background: rgba(30, 41, 59, 0.95);
            border: 1px solid rgba(99, 102, 241, 0.2);
            box-shadow: 
                var(--shadow-2xl),
                0 0 40px rgba(99, 102, 241, 0.15);
        }
        .card-header {
            background: var(--gradient-primary);
            padding: 2.5rem 2rem 2rem;
            text-align: center;
            position: relative;
            overflow: hidden;
        }
        .card-header::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
            animation: headerShimmer 3s infinite;
        }
        .brand-container {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 1rem;
            position: relative;
            z-index: 2;
        }
        .logo-wrapper {
            width: 80px;
            height: 80px;
            background: rgba(255, 255, 255, 0.15);
            border-radius: 20px;
            display: flex;
            align-items: center;
            justify-content: center;
            backdrop-filter: blur(10px);
            border: 1px solid rgba(255, 255, 255, 0.2);
            position: relative;
            overflow: hidden;
            animation: logoFloat 3s ease-in-out infinite;
        }
        .logo-wrapper::before {
            content: '';
            position: absolute;
            top: -2px; left: -2px; right: -2px; bottom: -2px;
            background: linear-gradient(45deg, rgba(255, 255, 255, 0.3), transparent, rgba(255, 255, 255, 0.3));
            border-radius: 20px;
            z-index: -1;
        }
        .logo-wrapper img {
            width: 48px; height: 48px; object-fit: contain; filter: brightness(0) invert(1);
        }
        .logo-wrapper i {
            font-size: 32px; color: white;
        }
        .brand-title {
            color: white;
            font-size: 2rem;
            font-weight: 700;
            margin: 0 0 0.5rem;
            letter-spacing: -0.025em;
            text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
            position: relative;
            z-index: 2;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }
        .brand-subtitle {
            color: rgba(255, 255, 255, 0.9);
            font-size: 1rem;
            font-weight: 400;
            margin: 0;
            position: relative;
            z-index: 2;
        }
        .card-body {
            padding: 2rem;
        }
        body.dark-mode .card-body {
            color: var(--dark-text-primary);
        }
        .form-section {
            margin-bottom: 2rem;
        }
        .form-section:last-child {
            margin-bottom: 0;
        }
        .section-title {
            font-size: 1.125rem;
            font-weight: 600;
            color: var(--text-primary);
            margin-bottom: 1.5rem;
            padding-bottom: 0.5rem;
            border-bottom: 2px solid var(--border-primary);
            position: relative;
            display: flex;
            align-items: center;
            gap: 0.75rem;
        }
        body.dark-mode .section-title {
            color: var(--dark-text-primary);
            border-bottom-color: var(--dark-border-primary);
        }
        .section-title::after {
            content: '';
            position: absolute;
            bottom: -2px; left: 0;
            width: 40px; height: 2px;
            background: var(--gradient-primary);
            border-radius: 1px;
        }
        .form-label {
            font-weight: 500;
            margin-bottom: 0.5rem;
            color: var(--text-secondary);
            font-size: 0.875rem;
            display: flex;
            align-items: center;
            gap: 0.5rem;
            transition: color var(--animation-normal) ease;
        }
        body.dark-mode .form-label {
            color: var(--dark-text-secondary);
        }
        .form-label .required {
            color: var(--error); font-weight: 500;
        }
        .input-wrapper {
            position: relative;
            margin-bottom: 1.5rem;
        }
        .input-icon {
            position: absolute;
            left: 1rem; top: 50%;
            transform: translateY(-50%);
            color: var(--text-tertiary);
            font-size: 1rem;
            z-index: 2;
            pointer-events: none;
            transition: color var(--animation-normal) ease;
        }
        .form-control {
            width: 100%; height: 3.5rem;
            padding: 0 1rem 0 2.75rem;
            border: 1.5px solid var(--border-primary);
            border-radius: 12px;
            background: var(--bg-primary);
            color: var(--text-primary);
            font-size: 0.9375rem;
            font-weight: 400;
            transition: all var(--animation-normal) var(--ease-out-cubic);
            outline: none;
        }
        body.dark-mode .form-control {
            background: var(--dark-bg-secondary);
            border-color: var(--dark-border-primary);
            color: var(--dark-text-primary);
        }
        .form-control::placeholder {
            color: var(--text-tertiary);
            font-weight: 400;
        }
        body.dark-mode .form-control::placeholder {
            color: var(--dark-text-tertiary);
        }
        .form-control:focus {
            border-color: var(--primary);
            box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
            background: var(--bg-primary);
            transform: translateY(-1px);
        }
        body.dark-mode .form-control:focus {
            border-color: var(--primary);
            box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
            background: var(--dark-bg-secondary);
        }
        .form-control:focus + .input-icon,
        .form-control:not(:placeholder-shown) + .input-icon {
            color: var(--primary);
        }
        .form-row {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 1.5rem;
        }
        .password-toggle {
            position: absolute;
            right: 0.75rem; top: 50%;
            transform: translateY(-50%);
            width: 2rem; height: 2rem;
            border: none; background: none;
            color: var(--text-tertiary);
            cursor: pointer;
            border-radius: 6px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 0.875rem;
            transition: all var(--animation-normal) ease;
            z-index: 3;
        }
        .password-toggle:hover {
            background: rgba(99, 102, 241, 0.1);
            color: var(--primary);
        }
        body.dark-mode .password-toggle {
            color: var(--dark-text-tertiary);
        }
        body.dark-mode .password-toggle:hover {
            background: rgba(99, 102, 241, 0.2);
            color: var(--primary-light);
        }
        .btn-register {
            width: 100%; height: 3.5rem;
            background: var(--gradient-primary);
            border: none;
            border-radius: 12px;
            color: white;
            font-size: 1rem;
            font-weight: 600;
            letter-spacing: 0.025em;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.5rem;
            position: relative;
            overflow: hidden;
            transition: all var(--animation-normal) var(--ease-out-cubic);
            margin-top: 1.5rem;
            box-shadow: var(--shadow-md);
        }
        .btn-register::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 var(--animation-slow) ease;
        }
        .btn-register:hover {
            transform: translateY(-2px);
            box-shadow: var(--shadow-lg), var(--shadow-glow);
        }
        .btn-register:hover::before { left: 100%; }
        .btn-register:active { transform: translateY(0); }
        .btn-register:disabled {
            opacity: 0.7;
            cursor: not-allowed;
            transform: none;
        }
        .btn-register:disabled:hover { box-shadow: var(--shadow-md); }
        .terms-text {
            padding: 1rem;
            line-height: 1.5;
        }
        .terms-link {
            color: var(--primary);
            font-weight: 600;
            text-decoration: none;
            transition: all var(--animation-normal) ease;
            position: relative;
        }
        .terms-link:hover {
            color: var(--primary-dark);
            text-decoration: underline;
        }
        .login-section {
            text-align: center;
            margin-top: 2rem;
            padding-top: 2rem;
            border-top: 1px solid var(--border-primary);
            position: relative;
        }
        body.dark-mode .login-section {
            border-top-color: var(--dark-border-primary);
        }
        .login-section::before {
            content: 'OU';
            position: absolute;
            top: -12px; left: 50%;
            transform: translateX(-50%);
            background: var(--bg-secondary);
            color: var(--text-tertiary);
            padding: 0 1rem;
            font-size: 0.875rem;
            font-weight: 600;
            letter-spacing: 0.1em;
        }
        body.dark-mode .login-section::before {
            background: var(--dark-bg-secondary);
            color: var(--dark-text-tertiary);
        }
        .login-text {
            color: var(--text-secondary);
            font-size: 0.9375rem;
            margin: 0;
        }
        body.dark-mode .login-text {
            color: var(--dark-text-secondary);
        }
        .login-link {
            color: var(--primary);
            text-decoration: none;
            font-weight: 600;
            transition: all var(--animation-normal) ease;
            position: relative;
        }
        .login-link::after {
            content: '';
            position: absolute;
            bottom: -2px; left: 0;
            width: 0; height: 2px;
            background: var(--gradient-primary);
            transition: width var(--animation-normal) ease;
        }
        .login-link:hover { color: var(--primary-dark); }
        .login-link:hover::after { width: 100%; }
        .theme-toggle {
            position: fixed;
            bottom: 1.5rem; right: 1.5rem;
            width: 3rem; height: 3rem;
            border-radius: 50%;
            border: none;
            background: var(--gradient-primary);
            color: white;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.125rem;
            box-shadow: var(--shadow-lg);
            transition: all var(--animation-normal) var(--ease-out-cubic);
            z-index: 1000;
        }
        .theme-toggle:hover {
            transform: scale(1.1);
            box-shadow: var(--shadow-xl), var(--shadow-glow);
        }
        .modal-backdrop { backdrop-filter: blur(8px); }
        .modal-content {
            border: none;
            border-radius: 20px;
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(20px);
            box-shadow: var(--shadow-2xl);
            overflow: hidden;
        }
        body.dark-mode .modal-content {
            background: rgba(30, 41, 59, 0.95);
            color: var(--dark-text-primary);
        }
        .modal-header {
            background: var(--gradient-primary);
            color: white;
            border-radius: 20px 20px 0 0;
            border-bottom: none;
            padding: 1.5rem 2rem;
        }
        .modal-header .btn-close {
            filter: invert(1);
            opacity: 0.8;
            font-size: 1.2rem;
        }
        .modal-body {
            padding: 2rem;
            max-height: 400px;
            overflow-y: auto;
        }
        .modal-body h5 {
            color: var(--primary);
            margin-bottom: 1rem;
            font-weight: 600;
            font-size: 1.1rem;
        }
        body.dark-mode .modal-body h5 { color: var(--primary-light); }
        .modal-body ul { padding-left: 1.25rem; }
        .modal-body li { margin-bottom: 0.5rem; line-height: 1.6; }
        .toast-container {
            position: fixed;
            top: 1rem; right: 1rem;
            z-index: 9999;
            max-width: 400px;
            width: calc(100vw - 2rem);
        }
        .toast {
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(20px);
            border: 1px solid rgba(255, 255, 255, 0.3);
            border-radius: 16px;
            box-shadow: var(--shadow-xl);
            margin-bottom: 0.75rem;
            overflow: hidden;
            animation: toastSlideIn 0.5s var(--ease-out-cubic);
            position: relative;
        }
        body.dark-mode .toast {
            background: rgba(30, 41, 59, 0.95);
            border: 1px solid rgba(99, 102, 241, 0.2);
        }
        .toast.success { border-left: 4px solid var(--success); }
        .toast.error { border-left: 4px solid var(--error); }
        .toast-header {
            padding: 1rem 1rem 0.5rem;
            display: flex;
            align-items: center;
            gap: 0.75rem;
            border-bottom: 1px solid rgba(0, 0, 0, 0.05);
            background: transparent;
        }
        body.dark-mode .toast-header { border-bottom-color: rgba(255, 255, 255, 0.1); }
        .toast-title {
            font-weight: 600;
            color: var(--text-primary);
            flex: 1; margin: 0;
            font-size: 0.9375rem;
        }
        body.dark-mode .toast-title { color: var(--dark-text-primary); }
        .toast-body {
            padding: 0 1rem 1rem;
            color: var(--text-secondary);
            font-size: 0.875rem;
            line-height: 1.5;
        }
        body.dark-mode .toast-body { color: var(--dark-text-secondary); }
        @keyframes cardEntrance {
            from { opacity: 0; transform: translateY(2rem) scale(0.95); }
            to { opacity: 1; transform: translateY(0) scale(1); }
        }
        @keyframes headerShimmer {
            0% { left: -100%; } 100% { left: 100%; }
        }
        @keyframes logoFloat {
            0%, 100% { transform: translateY(0) rotate(0deg); }
            50% { transform: translateY(-5px) rotate(2deg); }
        }
        @keyframes toastSlideIn {
            from { transform: translateX(100%); opacity: 0; }
            to { transform: translateX(0); opacity: 1; }
        }
        @media (max-width: 768px) {
            .register-wrapper { padding: 1rem; align-items: flex-start; }
            .register-card { margin-top: 1rem; border-radius: 20px; }
            .card-header { padding: 2rem 1.5rem; }
            .brand-title { font-size: 1.75rem; }
            .card-body { padding: 2rem 1.5rem; }
            .form-row { grid-template-columns: 1fr; gap: 0; }
            .form-control { height: 3.25rem; font-size: 16px; }
            .theme-toggle { width: 2.75rem; height: 2.75rem; bottom: 1rem; right: 1rem; font-size: 1rem; }
            .toast-container { max-width: calc(100vw - 1.5rem); right: 0.75rem; top: 0.75rem; }
        }
        @media (max-width: 576px) {
            .register-wrapper { padding: 0.5rem; }
            .card-header { padding: 1.5rem 1rem; }
            .card-body { padding: 1.5rem 1rem; }
            .brand-title { font-size: 1.5rem; }
            .logo-wrapper { width: 70px; height: 70px; }
            .logo-wrapper img { width: 40px; height: 40px; }
            .logo-wrapper i { font-size: 28px; }
        }
        @media (prefers-reduced-motion: reduce) {
            *, *::before, *::after {
                animation-duration: 0.01ms !important;
                animation-iteration-count: 1 !important;
                transition-duration: 0.01ms !important;
            }
        }
        @media (prefers-contrast: high) {
            .register-card { border: 2px solid currentColor; }
            .form-control { border: 2px solid currentColor; }
        }
        @media print {
            .theme-toggle, .toast-container { display: none !important; }
        }
        .btn-register:focus-visible,
        .form-control:focus-visible,
        .password-toggle:focus-visible,
        .theme-toggle:focus-visible {
            outline: 2px solid var(--primary);
            outline-offset: 2px;
        }
