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

        body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            background: #f5f7fa;
            overflow-x: hidden;
        }

        /* Hero Section */
        .hero-section {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 80px 0;
            min-height: 100vh;
            display: flex;
            align-items: center;
        }

        .hero-content h1 {
            font-size: 3.5rem;
            font-weight: 700;
            margin-bottom: 20px;
            line-height: 1.2;
        }

        .hero-content p {
            font-size: 1.3rem;
            margin-bottom: 30px;
            opacity: 0.95;
        }

        .feature-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
            gap: 20px;
            margin-top: 40px;
        }

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

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

        .feature-item i {
            font-size: 2rem;
            margin-bottom: 15px;
            display: block;
        }

        .feature-item h5 {
            font-weight: 600;
            margin-bottom: 8px;
        }

        .feature-item p {
            font-size: 0.95rem;
            margin: 0;
            opacity: 0.9;
        }

        /* Auth Container */
        .auth-wrapper {
            background: white;
            border-radius: 20px;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
            overflow: hidden;
        }

        .auth-header {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 30px;
            text-align: center;
        }

        .auth-header h2 {
            font-weight: 700;
            margin-bottom: 8px;
        }

        .auth-header p {
            opacity: 0.95;
            margin: 0;
            font-size: 0.95rem;
        }

        .auth-body {
            padding: 40px;
        }

        /* Form Styling */
        .form-group {
            margin-bottom: 20px;
        }

        .form-label {
            display: block;
            color: #333;
            font-weight: 600;
            margin-bottom: 8px;
            font-size: 0.95rem;
        }

        .form-control {
            border: 2px solid #e9ecef;
            border-radius: 10px;
            padding: 12px 15px;
            font-size: 0.95rem;
            transition: all 0.3s ease;
        }

        .form-control:focus {
            border-color: #667eea;
            box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.15);
            outline: none;
        }

        .form-control::placeholder {
            color: #adb5bd;
        }

        /* Password Strength Indicator */
        .password-strength {
            margin-top: 8px;
            height: 4px;
            background: #e9ecef;
            border-radius: 2px;
            overflow: hidden;
        }

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

        .strength-weak {
            background: #dc3545;
            width: 33.33%;
        }

        .strength-fair {
            background: #ffc107;
            width: 66.66%;
        }

        .strength-strong {
            background: #28a745;
            width: 100%;
        }

        .strength-text {
            font-size: 0.8rem;
            margin-top: 5px;
            font-weight: 600;
        }

        .strength-weak-text { color: #dc3545; }
        .strength-fair-text { color: #ffc107; }
        .strength-strong-text { color: #28a745; }

        /* Password Confirmation Match */
        .password-match {
            font-size: 0.85rem;
            margin-top: 5px;
            font-weight: 600;
        }

        .match-success {
            color: #28a745;
        }

        .match-error {
            color: #dc3545;
        }

        /* Role Selection */
        .role-selection {
            display: flex;
            gap: 12px;
            margin-bottom: 25px;
        }

        .role-option {
            flex: 1;
            position: relative;
        }

        .role-option input[type="radio"] {
            display: none;
        }

        .role-label {
            display: block;
            padding: 18px;
            border: 2px solid #e9ecef;
            border-radius: 12px;
            text-align: center;
            cursor: pointer;
            transition: all 0.3s ease;
            background: #f8f9fa;
        }

        .role-label i {
            font-size: 1.8rem;
            display: block;
            margin-bottom: 10px;
            color: #667eea;
        }

        .role-label span {
            display: block;
            font-weight: 600;
            font-size: 0.95rem;
            color: #333;
        }

        .role-label small {
            display: block;
            font-size: 0.8rem;
            color: #6c757d;
            margin-top: 5px;
        }

        .role-option input[type="radio"]:checked + .role-label {
            border-color: #667eea;
            background: #f0f3ff;
        }

        /* Buttons */
        .btn-auth {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            border: none;
            color: white;
            padding: 12px 20px;
            border-radius: 10px;
            font-weight: 600;
            width: 100%;
            transition: all 0.3s ease;
            cursor: pointer;
            font-size: 0.95rem;
        }

        .btn-auth:hover:not(:disabled) {
            transform: translateY(-2px);
            box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
        }

        .btn-auth:disabled {
            opacity: 0.65;
            cursor: not-allowed;
        }

        /* Links */
        .auth-link {
            color: #667eea;
            text-decoration: none;
            font-weight: 600;
            transition: all 0.2s ease;
        }

        .auth-link:hover {
            color: #764ba2;
            text-decoration: underline;
        }

        /* Alerts */
        .alert {
            border-radius: 10px;
            border: 1px solid transparent;
            padding: 12px 15px;
            margin-bottom: 20px;
            font-size: 0.95rem;
        }

        .alert-danger {
            background: #f8d7da;
            color: #721c24;
            border-color: #f5c6cb;
        }

        .alert-success {
            background: #d4edda;
            color: #155724;
            border-color: #c3e6cb;
        }

        .alert-info {
            background: #d1ecf1;
            color: #0c5460;
            border-color: #bee5eb;
        }

        /* Tab Navigation */
        .tab-buttons {
            display: flex;
            gap: 12px;
            margin-bottom: 30px;
            border-bottom: 2px solid #e9ecef;
        }

        .tab-button {
            background: none;
            border: none;
            padding: 12px 20px;
            cursor: pointer;
            font-weight: 600;
            color: #6c757d;
            border-bottom: 3px solid transparent;
            transition: all 0.3s ease;
            position: relative;
            margin-bottom: -2px;
        }

        .tab-button.active {
            color: #667eea;
            border-bottom-color: #667eea;
        }

        .tab-button i {
            margin-right: 8px;
        }

        /* Tab Content */
        .tab-pane {
            display: none;
        }

        .tab-pane.active {
            display: block;
            animation: fadeIn 0.3s ease;
        }

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

        /* Footer Links */
        .auth-footer {
            text-align: center;
            margin-top: 25px;
            padding-top: 20px;
            border-top: 1px solid #e9ecef;
            color: #6c757d;
            font-size: 0.95rem;
        }

        .auth-footer a {
            color: #667eea;
            text-decoration: none;
            font-weight: 600;
        }

        .auth-footer a:hover {
            text-decoration: underline;
        }

        /* Email Verification Info */
        .verification-info {
            background: #e7f3ff;
            border-left: 4px solid #667eea;
            padding: 12px 15px;
            border-radius: 6px;
            margin-bottom: 20px;
            font-size: 0.9rem;
            color: #0c5460;
        }

        .verification-info i {
            margin-right: 8px;
            color: #667eea;
        }

        /* ─── iOS auto-zoom prevention: inputs must be ≥ 16px ─── */
        .form-control {
            font-size: 1rem; /* overrides the 0.95rem default — Safari zooms anything below 16px */
        }

        /* ─── Minimum 48px touch targets for inputs and primary button ─── */
        .form-control,
        .btn-auth {
            min-height: 48px;
        }

        /* ─── Responsive ─── */
        @media (max-width: 991.98px) {
            /* On mobile the page is a full-gradient surface with the card floating on it.
               Switch to flex-start so a tall register form doesn't clip off the bottom. */
            .hero-section {
                padding: 48px 0 64px;
                align-items: flex-start;
            }

            /* Equal-width tab buttons for larger, equal hit areas */
            .tab-button {
                flex: 1;
                text-align: center;
                padding: 14px 10px;
                font-size: 0.95rem;
            }

            .tab-buttons {
                gap: 6px;
            }

            /* Slightly tighten card body padding on smaller screens */
            .auth-body {
                padding: 24px 20px;
            }

            /* Role cards stack vertically */
            .role-selection {
                flex-direction: column;
            }

            /* Feature grid single column if somehow visible (fallback) */
            .feature-grid {
                grid-template-columns: 1fr;
            }
        }

        /* Forgot Password Link */
        .forgot-link {
            text-align: right;
            margin-bottom: 10px;
        }

        .forgot-link a {
            color: #667eea;
            font-size: 0.85rem;
            text-decoration: none;
            font-weight: 600;
        }

        .forgot-link a:hover {
            text-decoration: underline;
        }

        /* Tutor Code Container */
        .tutor-code-container {
            background: #f8f9fa;
            padding: 15px;
            border-radius: 10px;
            margin-bottom: 20px;
            border: 1px solid #e9ecef;
        }

        .tutor-code-container label {
            margin-bottom: 10px;
        }

        .tutor-code-hint {
            font-size: 0.8rem;
            color: #6c757d;
            margin-top: 5px;
        }
