{* Section: Passwort *}

<div class="admin2000-form-section">
<div class="admin2000-form-section-title">Passwort</div>

{* Row 1: Password Action Dropdown *}
<div class="admin2000-form-group">
	<label class="admin2000-form-label">Aktion {if $customer_data.pass == ''}<span style="color:#999;font-size:12px;font-weight:normal;"> (Kunde hat kein Passwort)</span>{/if}</label>
	<select id="password_action" class="admin2000-form-select" name="customer_password_action">
		<option value="0">-</option>
		<option value="1">Neues Passwort mit Benachrichtigung</option>
		<option value="2">Neues Passwort manuell vergeben</option>
	</select>
</div>

{* Row 2: Manual Password Fields (hidden by default) *}
<div id="show_passwords" style="display:none;">
	<div class="admin2000-form-row admin2000-form-row-2">
		<div class="admin2000-form-group">
			<label class="admin2000-form-label">Passwort</label>
			<input type="password" class="admin2000-form-input" name="customer_field[pass1]" value="" autocomplete="new-password">
		</div>

		<div class="admin2000-form-group">
			<label class="admin2000-form-label">Passwort wiederholen</label>
			<input type="password" class="admin2000-form-input" name="customer_field[pass2]" value="" autocomplete="new-password">
		</div>
	</div>
	<div id="password_match_spring"></div>
</div>

<script>
$(document).ready(function() {
	// Show/hide password fields based on action
	$('#password_action').change(function() {
		if ($(this).val() == '2') {
			$('#show_passwords').slideDown();
		} else {
			$('#show_passwords').slideUp();
		}
	});
});
</script>
</div>
