/**
 * Frontend Shortcode Styles
 * 
 * Styles for [erl_user_status] shortcode - Compact version for 400px max
 */

/* Inline display mode */
.erl-inline-status {
	font-family: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	font-size: 12px;
	font-weight: 500;
	color: #333;
	line-height: 1.4;
}

.erl-inline-header {
	font-size: 12px;
	font-weight: 700;
	color: #333;
	margin-bottom: 2px;
}

.erl-inline-none {
	color: #666;
}

.erl-inline-period {
	display: block;
	padding: 2px 0;
}

/* Popup link wrapper */
.erl-inline-popup-link {
	text-decoration: none;
	color: inherit;
	cursor: pointer;
	display: block;
}

.erl-inline-popup-link:hover {
	opacity: 0.85;
}

.erl-inline-popup-link:hover .erl-inline-header {
	text-decoration: underline;
}

.erl-inline-period strong {
	font-weight: 600;
}

.erl-inline-period.erl-inline-ok strong {
	color: #4caf50;
}

.erl-inline-period.erl-inline-warning strong {
	color: #ff9800;
}

.erl-inline-period.erl-inline-limit strong {
	color: #f44336;
}

/* Wrapper */
.erl-status-wrapper {
	max-width: 500px;
	margin: 0 auto;
	padding: 8px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
	font-size: 14px;
	line-height: 1.5;
}

.erl-status-wrapper * {
	box-sizing: border-box;
}

/* Intro explanation text */
.erl-status-wrapper .erl-intro-text {
	font-family: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
	font-size: 16px !important;
	line-height: 1.6 !important;
	color: #555 !important;
	margin: 0 0 10px 0 !important;
	padding: 0 !important;
}

/* Not logged in / excluded messages */
.erl-not-logged-in p,
.erl-excluded p,
.erl-no-periods {
	background: #f0f0f0;
	padding: 8px;
	border-radius: 6px;
	text-align: center;
	color: #666;
	font-size: 14px;
	margin: 0;
}

.erl-excluded p {
	background: #e8f5e9;
	color: #2e7d32;
}

/* Tenure badge */
.erl-tenure-badge {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 4px 8px;
	border-radius: 16px;
	margin-bottom: 8px;
	font-size: 13px;
}

.erl-tenure-new {
	background: #fff3e0;
	color: #e65100;
}

.erl-tenure-established {
	background: #e8f5e9;
	color: #2e7d32;
}

.erl-tenure-label {
	font-weight: 600;
}

.erl-tenure-months {
	opacity: 0.8;
}

/* Periods grid */
.erl-periods-grid {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin-bottom: 8px;
}

/* Period card */
.erl-period-card {
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 8px;
	padding: 8px 12px;
}

/* Status-based borders */
.erl-period-card.erl-status-ok {
	border-left: 4px solid #4caf50;
}

.erl-period-card.erl-status-warning {
	border-left: 4px solid #ff9800;
}

.erl-period-card.erl-status-limit {
	border-left: 4px solid #f44336;
}

/* Period header */
.erl-period-header {
	margin-bottom: 8px;
}

.erl-period-name {
	margin: 0;
	font-size: 16px;
	font-weight: 600;
	color: #333;
}

.erl-period-dates {
	font-size: 15px;
	font-weight: 600;
	color: #333;
}

/* Global status */
.erl-global-status {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.erl-count-row {
	display: flex;
	align-items: center;
	gap: 8px;
}

.erl-count-display {
	font-size: 36px;
	font-weight: 700;
	line-height: 1;
}

.erl-status-ok .erl-count-number {
	color: #4caf50;
}

.erl-status-warning .erl-count-number {
	color: #ff9800;
}

.erl-status-limit .erl-count-number {
	color: #f44336;
}

.erl-count-separator {
	color: #ccc;
	margin: 0 2px;
}

.erl-count-limit {
	color: #666;
}

.erl-count-label {
	font-size: 16px;
	color: #555;
	font-weight: 500;
}

.erl-status-message {
	display: inline-block;
	padding: 4px 10px;
	border-radius: 20px;
	font-size: 14px;
	font-weight: 600;
}

.erl-status-message.erl-remaining {
	background: #e8f5e9;
	color: #2e7d32;
}

.erl-status-warning .erl-status-message.erl-remaining {
	background: #fff3e0;
	color: #e65100;
}

.erl-status-message.erl-at-limit {
	background: #ffebee;
	color: #c62828;
}

/* Venue limits */
.erl-venue-limits {
	margin-top: 10px;
	padding-top: 8px;
	border-top: 1px solid #eee;
}

.erl-venue-heading {
	font-size: 12px;
	font-weight: 700;
	margin: 0 0 6px 0;
	color: #888;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.erl-venue-grid {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.erl-venue-item {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 4px 8px;
	background: #f8f8f8;
	border-radius: 6px;
	font-size: 13px;
}

.erl-venue-item.erl-venue-at-limit {
	background: #ffebee;
}

.erl-venue-name {
	color: #111;
	flex: 1;
	margin-right: 12px;
}

.erl-venue-count {
	font-weight: 600;
	color: #555;
}

.erl-venue-at-limit .erl-venue-count {
	color: #c62828;
}

/* Release info */
.erl-release-info {
	margin-top: 16px;
	padding-top: 12px;
	border-top: 1px solid #eee;
	font-size: 13px;
	color: #888;
}

.erl-release-passed {
	color: #4caf50;
	font-weight: 500;
}

/* Registrations list */
.erl-registrations-list {
	margin-top: 16px;
	padding-top: 16px;
	border-top: 1px solid #eee;
}

.erl-registrations-list h4 {
	font-size: 12px;
	font-weight: 700;
	margin: 0 0 12px 0;
	color: #888;
	text-transform: uppercase;
}

.erl-registrations-list ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.erl-registrations-list li {
	display: flex;
	justify-content: space-between;
	padding: 4px 0;
	border-bottom: 1px solid #f5f5f5;
	font-size: 13px;
}

.erl-registrations-list li:last-child {
	border-bottom: none;
}

.erl-reg-title {
	color: #111;
	font-weight: 500;
	flex: 1;
}

.erl-reg-date {
	color: #888;
	font-size: 12px;
}

/* Uncounted events section */
.erl-uncounted-section {
	background: #fafafa;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	padding: 16px;
}

.erl-uncounted-heading {
	margin: 0 0 6px 0;
	font-size: 14px;
	font-weight: 700;
	color: #333;
}

.erl-uncounted-description {
	margin: 0 0 12px 0;
	font-size: 13px;
	color: #777;
}

.erl-uncounted-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.erl-uncounted-item {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
	padding: 8px 0;
	border-bottom: 1px solid #eee;
	font-size: 13px;
}

.erl-uncounted-item:last-child {
	border-bottom: none;
}

.erl-uncounted-title {
	flex: 1;
	color: #111;
	font-weight: 500;
}

.erl-uncounted-date {
	color: #888;
	font-size: 12px;
}

/* ========================================
   Exempt Events List (Unlimited Events)
   ======================================== */

.erl-exempt-list-section {
	margin-top: 24px;
	padding-top: 20px;
	border-top: 2px solid #e0e0e0;
}

.erl-exempt-list-header {
	text-align: center;
	margin-bottom: 20px;
}

.erl-exempt-list-title {
	font-size: 18px;
	font-weight: 600;
	color: #2e7d32;
	margin: 0 0 8px 0;
}

.erl-status-wrapper .erl-exempt-list-description {
	font-family: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
	font-size: 16px !important;
	line-height: 1.6 !important;
	color: #666 !important;
	margin: 0 !important;
}

.erl-exempt-list-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 16px;
}

.erl-exempt-card {
	position: relative;
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 8px;
	padding: 16px;
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.erl-exempt-card:hover {
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
	transform: translateY(-2px);
}

.erl-exempt-card.erl-exempt-registered {
	background: #f1f8f1;
	border-color: #c8e6c9;
}

/* Badge */
.erl-exempt-badge {
	display: inline-block;
	font-size: 10px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	padding: 3px 8px;
	border-radius: 12px;
	margin-bottom: 10px;
}

.erl-badge-free {
	background: #e8f5e9;
	color: #2e7d32;
}

.erl-badge-registered {
	background: #c8e6c9;
	color: #1b5e20;
}

/* Card content */
.erl-exempt-card-title {
	font-size: 12px;
	font-weight: 600;
	margin: 0 0 8px 0;
	line-height: 1.3;
}

.erl-exempt-card-title a {
	color: #333;
	text-decoration: none;
}

.erl-exempt-card-title a:hover {
	color: #1976d2;
}

.erl-exempt-card-meta {
	display: flex;
	gap: 16px;
	font-size: 12px;
	color: #666;
	margin-bottom: 6px;
}

.erl-exempt-date {
	font-weight: 500;
}

.erl-exempt-time {
	color: #888;
}

.erl-exempt-venue {
	font-size: 11px;
	color: #888;
	margin-bottom: 12px;
}

/* Register button */
.erl-exempt-register-btn {
	display: inline-block;
	width: 100%;
	text-align: center;
	padding: 8px 16px;
	background: #4caf50;
	color: #fff;
	font-size: 12px;
	font-weight: 600;
	text-decoration: none;
	border-radius: 6px;
	transition: background 0.2s ease;
}

.erl-exempt-register-btn:hover {
	background: #388e3c;
	color: #fff;
}

/* Mobile responsiveness */
@media (max-width: 600px) {
	.erl-exempt-list-grid {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 400px) {
	.erl-status-wrapper {
		padding: 6px;
	}

	.erl-period-header {
		flex-direction: column;
		align-items: flex-start;
		gap: 1px;
	}
}
