/* Watts Branded Standalone Pages
   Dark gradient background, glass-morphism card, pink/purple accent */

/* Reset & Base */
.watts-standalone-page {
	margin: 0;
	padding: 0;
	min-height: 100vh;
	background: linear-gradient(135deg, #0f0c29 0%, #1a1a3e 40%, #24243e 100%);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
	color: #b0b0c0;
	font-size: 15px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

/* Wrapper — centers card vertically and horizontally */
.watts-standalone-wrapper {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 100vh;
	padding: 40px 20px;
	box-sizing: border-box;
}

/* Glass Card */
.watts-standalone-card {
	background: rgba(255, 255, 255, 0.05);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 16px;
	padding: 40px;
	width: 100%;
	max-width: 460px;
	box-sizing: border-box;
}

/* Logo */
.watts-standalone-logo {
	text-align: center;
	margin-bottom: 32px;
}

.watts-standalone-logo img {
	max-width: 220px;
	height: auto;
}

.watts-standalone-logo a {
	display: inline-block;
}

/* Content area — shortcode renders here */
.watts-standalone-content h2 {
	color: #ffffff;
	font-size: 22px;
	font-weight: 600;
	margin: 0 0 8px;
	text-align: center;
}

.watts-standalone-content .watts-form-description {
	text-align: center;
	margin: 0 0 24px;
	color: #8888a0;
	font-size: 14px;
}

/* ----------------------------------------------------------------
   Form Elements (shared across login, register, lost password)
   ---------------------------------------------------------------- */

/* Labels */
.watts-standalone-page label {
	display: block;
	color: #ffffff;
	font-size: 13px;
	font-weight: 500;
	margin-bottom: 6px;
	letter-spacing: 0.02em;
}

.watts-standalone-page label .required {
	color: #ff6b9d;
}

/* Inputs */
.watts-standalone-page input[type="text"],
.watts-standalone-page input[type="email"],
.watts-standalone-page input[type="password"],
.watts-standalone-page input[type="tel"],
.watts-standalone-page select {
	width: 100%;
	padding: 12px 14px;
	background: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 8px;
	color: #ffffff;
	font-size: 15px;
	font-family: inherit;
	outline: none;
	transition: border-color 0.2s, box-shadow 0.2s;
	box-sizing: border-box;
}

.watts-standalone-page input[type="text"]:focus,
.watts-standalone-page input[type="email"]:focus,
.watts-standalone-page input[type="password"]:focus,
.watts-standalone-page input[type="tel"]:focus,
.watts-standalone-page select:focus {
	border-color: rgba(139, 92, 246, 0.5);
	box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
}

.watts-standalone-page input::placeholder {
	color: rgba(255, 255, 255, 0.3);
}

/* Form rows */
.watts-standalone-page .watts-form-row {
	margin-bottom: 20px;
}

.watts-standalone-page .watts-form-row:last-child {
	margin-bottom: 0;
}

/* Two-column rows (registration form) */
.watts-standalone-page .watts-form-col {
	margin-bottom: 20px;
}

@media (min-width: 481px) {
	.watts-standalone-page .watts-form-row:has(.watts-form-col) {
		display: flex;
		gap: 16px;
		margin-bottom: 0;
	}

	.watts-standalone-page .watts-form-col {
		flex: 1;
	}
}

/* Field hints */
.watts-standalone-page .watts-field-hint {
	margin: 4px 0 0;
	font-size: 12px;
	color: #6b6b80;
}

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

.watts-standalone-page .watts-checkbox-label input[type="checkbox"] {
	width: 16px;
	height: 16px;
	accent-color: #8b5cf6;
}

.watts-standalone-page .watts-remember-row {
	margin-bottom: 24px;
}

/* ----------------------------------------------------------------
   Password Show/Hide Toggle
   ---------------------------------------------------------------- */

.watts-password-wrapper {
	position: relative;
}

.watts-password-wrapper input {
	padding-right: 44px;
}

.watts-toggle-password {
	position: absolute;
	right: 10px;
	top: 50%;
	transform: translateY(-50%);
	background: none;
	border: none;
	cursor: pointer;
	padding: 4px;
	color: rgba(255, 255, 255, 0.4);
	transition: color 0.2s;
}

.watts-toggle-password:hover {
	color: rgba(255, 255, 255, 0.7);
}

.watts-eye-icon::before {
	content: "\1F441";
	font-size: 16px;
}

.watts-toggle-password.active .watts-eye-icon::before {
	content: "\1F441";
	opacity: 0.5;
}

/* ----------------------------------------------------------------
   Buttons
   ---------------------------------------------------------------- */

.watts-standalone-page .watts-submit-btn {
	display: block;
	width: 100%;
	padding: 14px 24px;
	background: linear-gradient(135deg, #ff1493, #8b5cf6);
	color: #ffffff;
	font-size: 15px;
	font-weight: 700;
	font-family: inherit;
	letter-spacing: 0.05em;
	border: none;
	border-radius: 8px;
	cursor: pointer;
	transition: opacity 0.2s, transform 0.1s;
	text-transform: uppercase;
}

.watts-standalone-page .watts-submit-btn:hover {
	opacity: 0.9;
}

.watts-standalone-page .watts-submit-btn:active {
	transform: scale(0.99);
}

/* ----------------------------------------------------------------
   Messages & Errors
   ---------------------------------------------------------------- */

.watts-standalone-page .watts-form-messages {
	background: rgba(34, 197, 94, 0.15);
	border: 1px solid rgba(34, 197, 94, 0.3);
	border-radius: 8px;
	padding: 12px 16px;
	margin-bottom: 20px;
}

.watts-standalone-page .watts-form-messages p {
	margin: 0;
	color: #86efac;
	font-size: 14px;
}

.watts-standalone-page .watts-form-errors {
	background: rgba(220, 38, 38, 0.15);
	border: 1px solid rgba(220, 38, 38, 0.3);
	border-radius: 8px;
	padding: 12px 16px;
	margin-bottom: 20px;
}

.watts-standalone-page .watts-form-errors p {
	margin: 0;
	color: #fca5a5;
	font-size: 14px;
}

.watts-standalone-page .watts-form-errors p + p {
	margin-top: 6px;
}

/* ----------------------------------------------------------------
   Links
   ---------------------------------------------------------------- */

.watts-standalone-page a {
	color: #ff6b9d;
	text-decoration: none;
	transition: color 0.2s;
}

.watts-standalone-page a:hover {
	color: #ff8cb3;
}

.watts-form-links {
	display: flex;
	justify-content: space-between;
	margin-top: 24px;
	font-size: 14px;
}

.watts-form-links a {
	color: #ff6b9d;
}

/* Single link (back to login) */
.watts-form-links:has(a:only-child) {
	justify-content: center;
}

/* Already logged in */
.watts-standalone-page .watts-already-logged-in {
	text-align: center;
	color: #b0b0c0;
}

/* ----------------------------------------------------------------
   Co-branded Logo (distributor + Watts side by side)
   ---------------------------------------------------------------- */

/* Hide the default standalone logo when co-brand is present */
.watts-standalone-page:has(.watts-cobrand) .watts-standalone-logo {
	display: none;
}

.watts-cobrand {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0;
	margin-bottom: 24px;
}

.watts-cobrand-logo {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 0;
}

.watts-cobrand-logo img {
	max-width: 180px;
	max-height: 60px;
	width: auto;
	height: auto;
	object-fit: contain;
}

.watts-cobrand-logo a {
	display: flex;
	align-items: center;
	justify-content: center;
}

/* The glowing divider between logos */
.watts-cobrand-divider {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 60px;
	flex-shrink: 0;
}

.watts-cobrand-divider span {
	display: block;
	width: 32px;
	height: 32px;
	position: relative;
}

/* Gradient "+" icon via CSS */
.watts-cobrand-divider span::before,
.watts-cobrand-divider span::after {
	content: '';
	position: absolute;
	background: linear-gradient(135deg, #ff1493, #8b5cf6);
	border-radius: 2px;
}

/* Horizontal bar */
.watts-cobrand-divider span::before {
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 20px;
	height: 3px;
}

/* Vertical bar */
.watts-cobrand-divider span::after {
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 3px;
	height: 20px;
}

@media (max-width: 480px) {
	.watts-cobrand-logo img {
		max-width: 120px;
		max-height: 45px;
	}

	.watts-cobrand-divider {
		width: 40px;
	}

	.watts-cobrand-divider span {
		width: 24px;
		height: 24px;
	}

	.watts-cobrand-divider span::before {
		width: 14px;
		height: 2px;
	}

	.watts-cobrand-divider span::after {
		width: 2px;
		height: 14px;
	}
}

/* ----------------------------------------------------------------
   Distributor Banner (registration form)
   ---------------------------------------------------------------- */

.watts-standalone-page .watts-distributor-banner {
	background: rgba(139, 92, 246, 0.15);
	border: 1px solid rgba(139, 92, 246, 0.3);
	border-radius: 8px;
	padding: 10px 16px;
	margin-bottom: 20px;
	text-align: center;
	font-size: 14px;
	color: #c4b5fd;
}

/* Login link in registration form */
.watts-standalone-page .watts-login-link {
	text-align: center;
	font-size: 14px;
}

/* ----------------------------------------------------------------
   Password match hint
   ---------------------------------------------------------------- */

.watts-password-match-hint {
	margin: 4px 0 0;
	font-size: 12px;
}

.watts-password-match-hint.match {
	color: #86efac;
}

.watts-password-match-hint.no-match {
	color: #fca5a5;
}

/* ----------------------------------------------------------------
   Responsive
   ---------------------------------------------------------------- */

@media (max-width: 480px) {
	.watts-standalone-wrapper {
		padding: 20px 0;
		align-items: flex-start;
	}

	.watts-standalone-card {
		border-radius: 0;
		border-left: none;
		border-right: none;
		padding: 32px 20px;
		max-width: 100%;
	}
}

/* ----------------------------------------------------------------
   Registration form overrides inside standalone
   The registration form has its own CSS; these ensure consistency
   ---------------------------------------------------------------- */

.watts-standalone-page .watts-registration-form .watts-form-row {
	margin-bottom: 20px;
}

/* ----------------------------------------------------------------
   Profile Form
   ---------------------------------------------------------------- */

.watts-profile-form h2 {
	color: #ffffff;
	font-size: 22px;
	font-weight: 600;
	margin: 0 0 20px;
}

.watts-profile-form h3 {
	color: #ffffff;
	font-size: 16px;
	font-weight: 600;
	margin: 0 0 4px;
}

.watts-profile-avatar {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-bottom: 24px;
	padding: 16px;
	background: rgba(255, 255, 255, 0.04);
	border-radius: 10px;
}

.watts-profile-avatar img {
	border-radius: 50%;
	width: 80px;
	height: 80px;
}

.watts-profile-avatar-info {
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.watts-profile-avatar-info strong {
	color: #ffffff;
	font-size: 16px;
}

.watts-profile-avatar-info span {
	color: #8888a0;
	font-size: 14px;
}

.watts-profile-divider {
	border: none;
	border-top: 1px solid rgba(255, 255, 255, 0.1);
	margin: 28px 0 20px;
}

.watts-standalone-page .watts-profile-form .watts-form-row {
	margin-bottom: 20px;
}

.watts-standalone-page .watts-profile-form input:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

/* ----------------------------------------------------------------
   Distributor Dashboard
   ---------------------------------------------------------------- */

/* Full width — remove card constraints */
.watts-standalone-page:has(.watts-dashboard) .watts-standalone-card {
	max-width: 100%;
	background: transparent;
	backdrop-filter: none;
	-webkit-backdrop-filter: none;
	border: none;
	border-radius: 0;
	padding: 24px 40px;
}

.watts-standalone-page:has(.watts-dashboard) .watts-standalone-wrapper {
	padding: 0;
	align-items: flex-start;
}

.watts-dashboard-header h2 {
	color: #ffffff;
	font-size: 22px;
	margin: 0 0 12px;
}

.watts-dashboard-stats {
	display: flex;
	gap: 16px;
	flex-wrap: wrap;
	margin-bottom: 24px;
}

.watts-stat {
	font-size: 14px;
	color: #b0b0c0;
	padding: 6px 12px;
	background: rgba(255, 255, 255, 0.05);
	border-radius: 6px;
}

.watts-stat-complete {
	color: #86efac;
}

.watts-stat-incomplete {
	color: #fbbf24;
}

/* Controls bar — tabs + search */
.watts-dashboard-controls {
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	flex-wrap: wrap;
	gap: 12px;
	margin-bottom: 20px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.watts-dashboard-tabs {
	display: flex;
	gap: 4px;
}

.watts-tab {
	padding: 10px 20px;
	color: #b0b0c0;
	text-decoration: none;
	font-size: 14px;
	font-weight: 500;
	border-bottom: 2px solid transparent;
	transition: color 0.2s, border-color 0.2s;
}

.watts-tab:hover {
	color: #ffffff;
}

.watts-tab-active {
	color: #ff6b9d;
	border-bottom-color: #ff6b9d;
}

.watts-dashboard-search {
	padding-bottom: 8px;
}

.watts-dashboard-search input {
	background: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 6px;
	color: #ffffff;
	padding: 8px 14px;
	font-size: 14px;
	font-family: inherit;
	outline: none;
	min-width: 240px;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.watts-dashboard-search input:focus {
	border-color: rgba(139, 92, 246, 0.5);
	box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
}

.watts-dashboard-search input::placeholder {
	color: rgba(255, 255, 255, 0.3);
}

.watts-dashboard-empty {
	text-align: center;
	color: #86efac;
	font-size: 16px;
	padding: 40px 0;
}

/* Table */
.watts-dashboard-table-wrap {
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
}

.watts-dashboard-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 14px;
}

.watts-dashboard-table thead th {
	text-align: left;
	color: #ffffff;
	font-weight: 600;
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	padding: 12px 16px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.15);
	white-space: nowrap;
	background: rgba(255, 255, 255, 0.03);
}

.watts-dashboard-table tbody td {
	padding: 12px 16px;
	color: #b0b0c0;
	border-bottom: none;
}

/* Alternating row backgrounds */
.watts-dashboard-table tbody tr:nth-child(odd) td {
	background: rgba(255, 255, 255, 0.02);
}

.watts-dashboard-table tbody tr:nth-child(even) td {
	background: rgba(255, 255, 255, 0.05);
}

.watts-dashboard-table tbody tr:hover td {
	background: rgba(255, 255, 255, 0.08);
}

.watts-col-name {
	white-space: nowrap;
}

.watts-col-email {
	white-space: nowrap;
	font-family: monospace;
	font-size: 13px;
}

.watts-course-status {
	white-space: nowrap;
	font-size: 13px;
}

.watts-course-completed {
	color: #86efac;
}

.watts-course-progress {
	color: #fbbf24;
}

.watts-course-not-started {
	color: #6b6b80;
}

/* Pending stat */
.watts-stat-pending {
	color: #fb923c;
}

/* Approval buttons */
.watts-col-actions {
	white-space: nowrap;
}

.watts-btn-approve,
.watts-btn-deny {
	padding: 6px 16px;
	border: none;
	border-radius: 6px;
	font-size: 13px;
	font-weight: 600;
	font-family: inherit;
	cursor: pointer;
	transition: opacity 0.2s;
}

.watts-btn-approve {
	background: linear-gradient(135deg, #22c55e, #16a34a);
	color: #ffffff;
	margin-right: 6px;
}

.watts-btn-approve:hover {
	opacity: 0.85;
}

.watts-btn-deny {
	background: rgba(220, 38, 38, 0.2);
	color: #fca5a5;
	border: 1px solid rgba(220, 38, 38, 0.3);
}

.watts-btn-deny:hover {
	background: rgba(220, 38, 38, 0.35);
}

@media (max-width: 480px) {
	.watts-standalone-page:has(.watts-dashboard) .watts-standalone-card {
		padding: 16px 12px;
	}

	.watts-dashboard-stats {
		flex-direction: column;
		gap: 8px;
	}

	.watts-dashboard-controls {
		flex-direction: column;
		align-items: stretch;
	}

	.watts-dashboard-search input {
		min-width: 0;
		width: 100%;
	}
}
