/**
 * DW250 Custom Authentication Styles
 *
 * Styles for login and password reset forms.
 *
 * @package DW250_Theme
 * @since 1.0.0
 */

/* Container */
.dw250-auth-container {
	max-width: 420px;
	margin: 40px auto;
	padding: 0 20px;
}

.dw250-auth-box {
	background: #fff;
	border-radius: 8px;
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
	padding: 40px;
}

/* Title */
.dw250-auth-title {
	font-size: 28px;
	font-weight: 700;
	color: #1B3B6F;
	margin: 0 0 8px 0;
	text-align: center;
}

.dw250-auth-subtitle {
	color: #666;
	font-size: 14px;
	text-align: center;
	margin: 0 0 24px 0;
	line-height: 1.5;
}

/* Form */
.dw250-auth-form {
	margin-top: 24px;
}

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

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

.dw250-form-group input[type="text"],
.dw250-form-group input[type="email"],
.dw250-form-group input[type="password"] {
	width: 100%;
	padding: 12px 16px;
	font-size: 16px;
	border: 2px solid #e0e0e0;
	border-radius: 6px;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
	box-sizing: border-box;
}

.dw250-form-group input:focus {
	outline: none;
	border-color: #1B3B6F;
	box-shadow: 0 0 0 3px rgba(27, 59, 111, 0.1);
}

.dw250-form-group input.password-mismatch {
	border-color: #DC3545;
}

/* Password Wrapper */
.dw250-password-wrapper {
	position: relative;
}

.dw250-password-wrapper input {
	padding-right: 48px;
}

.dw250-toggle-password {
	position: absolute;
	right: 12px;
	top: 50%;
	transform: translateY(-50%);
	background: none;
	border: none;
	cursor: pointer;
	color: #666;
	padding: 4px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.dw250-toggle-password:hover {
	color: #1B3B6F;
}

.dw250-toggle-password .dashicons {
	font-size: 20px;
	width: 20px;
	height: 20px;
}

/* Password Strength */
.dw250-password-strength {
	margin-top: 8px;
	display: flex;
	align-items: center;
	gap: 8px;
}

.strength-bar {
	height: 4px;
	width: 80px;
	border-radius: 2px;
	background: #e0e0e0;
}

.strength-bar.weak {
	background: linear-gradient(to right, #DC3545 33%, #e0e0e0 33%);
}

.strength-bar.medium {
	background: linear-gradient(to right, #FFA500 66%, #e0e0e0 66%);
}

.strength-bar.strong {
	background: #28A745;
}

.strength-label {
	font-size: 12px;
	font-weight: 600;
}

.strength-bar.weak + .strength-label {
	color: #DC3545;
}

.strength-bar.medium + .strength-label {
	color: #FFA500;
}

.strength-bar.strong + .strength-label {
	color: #28A745;
}

/* Form Row */
.dw250-form-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
	gap: 12px;
}

/* Checkbox */
.dw250-checkbox-label {
	display: flex;
	align-items: center;
	gap: 8px;
	cursor: pointer;
	font-size: 14px;
	color: #666;
}

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

/* Forgot Link */
.dw250-forgot-link {
	font-size: 14px;
	color: #1B3B6F;
	text-decoration: none;
}

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

/* Buttons */
.dw250-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 12px 24px;
	font-size: 16px;
	font-weight: 600;
	border-radius: 6px;
	border: none;
	cursor: pointer;
	text-decoration: none;
	transition: all 0.2s ease;
}

.dw250-btn-primary {
	background: #1B3B6F;
	color: #fff;
}

.dw250-btn-primary:hover {
	background: #2A4A7F;
}

.dw250-btn-secondary {
	background: transparent;
	color: #1B3B6F;
	border: 2px solid #1B3B6F;
}

.dw250-btn-secondary:hover {
	background: #1B3B6F;
	color: #fff;
}

.dw250-btn-block {
	width: 100%;
}

.dw250-btn:disabled {
	opacity: 0.7;
	cursor: not-allowed;
}

.dw250-btn-loading {
	position: relative;
}

/* Spinner */
.dw250-spinner {
	display: inline-block;
	width: 16px;
	height: 16px;
	border: 2px solid rgba(255, 255, 255, 0.3);
	border-radius: 50%;
	border-top-color: #fff;
	animation: dw250-spin 0.8s linear infinite;
}

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

/* Messages */
.dw250-auth-message {
	padding: 12px 16px;
	border-radius: 6px;
	margin-bottom: 20px;
	font-size: 14px;
	line-height: 1.5;
}

.dw250-message-error {
	background: #FEE2E2;
	color: #991B1B;
	border: 1px solid #FECACA;
}

.dw250-message-success {
	background: #D1FAE5;
	color: #065F46;
	border: 1px solid #A7F3D0;
}

/* Footer Link */
.dw250-auth-footer {
	text-align: center;
	margin-top: 24px;
	padding-top: 24px;
	border-top: 1px solid #e0e0e0;
	font-size: 14px;
	color: #666;
}

.dw250-auth-footer a {
	color: #1B3B6F;
	font-weight: 600;
	text-decoration: none;
}

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

/* Success State */
.dw250-auth-success {
	text-align: center;
	padding: 20px 0;
}

.dw250-success-icon {
	width: 64px;
	height: 64px;
	background: #D1FAE5;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto 20px;
}

.dw250-success-icon .dashicons {
	font-size: 32px;
	width: 32px;
	height: 32px;
	color: #059669;
}

.dw250-auth-success h3 {
	font-size: 22px;
	color: #1B3B6F;
	margin: 0 0 12px 0;
}

.dw250-auth-success p {
	color: #666;
	margin: 0 0 12px 0;
	line-height: 1.6;
}

.dw250-auth-note {
	font-size: 13px;
	color: #888;
}

/* Error State */
.dw250-auth-error-state {
	text-align: center;
	padding: 20px 0;
}

.dw250-error-icon {
	width: 64px;
	height: 64px;
	background: #FEE2E2;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0 auto 20px;
}

.dw250-error-icon .dashicons {
	font-size: 32px;
	width: 32px;
	height: 32px;
	color: #DC2626;
}

.dw250-auth-error-state h3 {
	font-size: 22px;
	color: #DC2626;
	margin: 0 0 12px 0;
}

.dw250-auth-error-state p {
	color: #666;
	margin: 0 0 20px 0;
	line-height: 1.6;
}

/* Logged In State */
.dw250-auth-logged-in {
	text-align: center;
	padding: 20px 0;
}

.dw250-auth-logged-in p {
	font-size: 16px;
	color: #666;
	margin: 0 0 20px 0;
}

/* Responsive */
@media (max-width: 480px) {
	.dw250-auth-container {
		padding: 0 16px;
		margin: 20px auto;
	}

	.dw250-auth-box {
		padding: 24px;
	}

	.dw250-auth-title {
		font-size: 24px;
	}

	.dw250-form-row {
		flex-direction: column;
		align-items: flex-start;
	}
}

/* WordPress Dashicons (ensure loaded) */
.dw250-auth-container .dashicons {
	font-family: dashicons;
	font-style: normal;
	font-weight: normal;
	line-height: 1;
}
