/* Pickle Court Booking — modern colorful theme */

body .pcb-widget,
body .pcb-widget *,
body .pcb-widget *::before,
body .pcb-widget *::after {
	box-sizing: border-box;
}

body .pcb-widget {
	--pcb-green: #16a34a;
	--pcb-green-dark: #0f7a38;
	--pcb-lime: #a3e635;
	--pcb-teal: #0d9488;
	--pcb-yellow: #facc15;
	--pcb-orange: #fb923c;
	--pcb-red: #ef4444;
	--pcb-blue: #38bdf8;
	--pcb-ink: #10221a;
	--pcb-muted: #5f7368;
	--pcb-border: #dde8e0;
	--pcb-bg-soft: #f3faf5;

	/* Admin-customizable theme colors (Settings → Calendar Colors).
	   These default to the palette above but can be overridden per-site via
	   an inline style block enqueued in class-pcb-public.php. */
	--pcb-accent: var(--pcb-green);
	--pcb-accent-soft: color-mix(in srgb, var(--pcb-accent) 65%, white);
	--pcb-accent-dark: color-mix(in srgb, var(--pcb-accent) 80%, black);
	--pcb-status-open: var(--pcb-green);
	--pcb-status-open-bg: color-mix(in srgb, var(--pcb-status-open) 12%, white);
	--pcb-status-open-dark: color-mix(in srgb, var(--pcb-status-open) 80%, black);
	--pcb-status-partial: var(--pcb-yellow);
	--pcb-status-partial-bg: color-mix(in srgb, var(--pcb-status-partial) 18%, white);
	--pcb-status-partial-dark: color-mix(in srgb, var(--pcb-status-partial) 65%, black);
	--pcb-status-full: var(--pcb-red);
	--pcb-status-full-bg: color-mix(in srgb, var(--pcb-status-full) 10%, white);
	--pcb-status-full-dark: color-mix(in srgb, var(--pcb-status-full) 70%, black);

	max-width: 760px;
	margin: 0 auto;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: var(--pcb-ink);
}

/* Hero header */
body .pcb-hero {
	background: linear-gradient(135deg, var(--pcb-teal) 0%, var(--pcb-accent) 55%, var(--pcb-accent-soft) 130%);
	border-radius: 20px;
	padding: 26px 28px;
	margin-bottom: 18px;
	color: #fff;
	box-shadow: 0 10px 30px -12px rgba(15, 122, 56, 0.45);
	position: relative;
	overflow: hidden;
}
body .pcb-hero::after {
	content: "";
	position: absolute;
	right: -30px;
	top: -30px;
	width: 140px;
	height: 140px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.14);
}
body .pcb-hero-eyebrow {
	display: inline-block;
	font-size: 0.72rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	background: rgba(255, 255, 255, 0.22);
	padding: 4px 10px;
	border-radius: 999px;
	margin-bottom: 8px;
}
body .pcb-hero-title {
	margin: 0;
	font-size: 1.5rem;
	font-weight: 800;
	letter-spacing: -0.01em;
}

/* Court selector */
body .pcb-court-selector {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 16px;
	flex-wrap: wrap;
}
body .pcb-court-selector-label {
	font-size: 0.8rem;
	color: var(--pcb-muted);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}
body .pcb-court-tabs {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
}
body .pcb-court-tab {
	border: 2px solid var(--pcb-border);
	background: #fff;
	border-radius: 999px;
	padding: 7px 18px;
	font-size: 0.85rem;
	font-weight: 600;
	cursor: pointer;
	color: var(--pcb-ink);
	transition: all 0.15s ease;
}
body .pcb-court-tab:hover { border-color: var(--pcb-accent); transform: translateY(-1px); background-color:#0D9488; }
body .pcb-court-tab-active {
	background: linear-gradient(135deg, var(--pcb-accent), var(--pcb-teal));
	border-color: transparent;
	color: #fff;
	box-shadow: 0 6px 14px -6px rgba(15, 122, 56, 0.55);
}

/* Calendar card */
body .pcb-calendar {
	border: 1px solid var(--pcb-border);
	border-radius: 18px;
	padding: 20px;
	background: #fff;
	box-shadow: 0 4px 20px -14px rgba(15, 34, 26, 0.25);
}

body .pcb-calendar-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 14px;
}

body .pcb-calendar-header h3 {
	margin: 0;
	font-size: 1.15rem;
	font-weight: 800;
}

body .pcb-nav {
	background: var(--pcb-bg-soft);
	border: none;
	border-radius: 10px;
	width: 36px;
	height: 36px;
	font-size: 1.3rem;
	cursor: pointer;
	color: var(--pcb-accent-dark);
	transition: background 0.15s ease, transform 0.1s ease;
}
body .pcb-nav:hover { background: #dcf3e2; transform: scale(1.06); }

body .pcb-calendar-grid {
	display: grid;
	grid-template-columns: repeat(7, minmax(0, 1fr));
	gap: 6px;
}

/* These stay as real DOM elements (JS queries them, and they group the
   weekday labels / day buttons semantically) but don't generate their own
   box — their children become direct items of .pcb-calendar-grid above, so
   the header row and every day row always share the exact same column
   tracks. This is what keeps "Sun/Mon/Tue…" aligned with the day cells
   beneath them at any screen width, instead of two separate grids that can
   round pixel widths slightly differently from each other. */
body .pcb-weekdays,
body .pcb-days {
	display: contents;
	text-align: center;
}

body .pcb-weekdays span {
	font-size: 0.72rem;
	font-weight: 700;
	color: var(--pcb-muted);
	padding: 4px 0;
	text-transform: uppercase;
	letter-spacing: 0.03em;
}

body .pcb-day {
	aspect-ratio: 1 / 1;
	border: 2px solid var(--pcb-border);
	border-radius: 12px;
	background: #fff;
	cursor: pointer;
	font-size: 0.9rem;
	font-weight: 600;
	min-height: 38px;
	transition: transform 0.1s ease, box-shadow 0.15s ease;
}

body .pcb-day:disabled { cursor: not-allowed; color: #c3cbc6; background: #f7f8f7; border-color: var(--pcb-border); }
body .pcb-day-blank { border: none; background: transparent; cursor: default; }

body .pcb-day-open { border-color: var(--pcb-status-open); background: var(--pcb-status-open-bg); color: var(--pcb-status-open-dark); }
body .pcb-day-partial { border-color: var(--pcb-status-partial); background: var(--pcb-status-partial-bg); color: var(--pcb-status-partial-dark); }
body .pcb-day-full { border-color: var(--pcb-status-full); background: var(--pcb-status-full-bg); color: var(--pcb-status-full-dark); }
body .pcb-day-closed { background: #f7f8f7; color: #c3cbc6; border-color: var(--pcb-border); }
body .pcb-day-past { background: #f7f8f7; color: #c3cbc6; border-color: var(--pcb-border); }

body .pcb-day:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 8px 16px -8px rgba(15, 122, 56, 0.4); background-color:#0D9488; }
body .pcb-day:focus,
body .pcb-slot:focus,
body .pcb-slot:hover{background-color:#0D9488;}
body .pcb-legend {
	margin-top: 16px;
	font-size: 0.8rem;
	color: var(--pcb-muted);
	display: flex;
	align-items: center;
	gap: 16px;
	flex-wrap: wrap;
}
body .pcb-legend span { display: inline-flex; align-items: center; gap: 6px; }
body .pcb-dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
body .pcb-dot-open { background: var(--pcb-status-open); }
body .pcb-dot-partial { background: var(--pcb-status-partial); }
body .pcb-dot-full { background: var(--pcb-status-full); }

/* Booking panel */
body .pcb-panel {
	margin-top: 22px;
	border: 1px solid var(--pcb-border);
	border-radius: 18px;
	padding: 22px;
	background: #fff;
	box-shadow: 0 4px 20px -14px rgba(15, 34, 26, 0.25);
}

body .pcb-panel-title {
	margin: 0 0 12px;
	font-size: 1.1rem;
	font-weight: 800;
	color: var(--pcb-accent-dark);
}

/* Multi-date / multi-slot booking toggle */
body .pcb-multi-toggle {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 2px 0 14px;
	padding: 8px 14px;
	border: 2px dashed var(--pcb-border);
	border-radius: 999px;
	font-size: 0.82rem;
	font-weight: 700;
	color: var(--pcb-muted);
	cursor: pointer;
	transition: border-color 0.15s ease, color 0.15s ease;
}
body .pcb-multi-toggle:has(input:checked) {
	border-color: var(--pcb-accent);
	border-style: solid;
	color: var(--pcb-accent-dark);
	background: var(--pcb-bg-soft);
}
body .pcb-multi-toggle input { accent-color: var(--pcb-accent); }

/* Cart of selected dates/slots when booking multiple at once */
body .pcb-cart {
	margin-top: 16px;
	padding: 16px 18px;
	border-radius: 14px;
	background: var(--pcb-bg-soft);
	border: 1px solid var(--pcb-border);
}
body .pcb-cart-title { margin: 0 0 10px; font-size: 0.95rem; font-weight: 800; color: var(--pcb-accent-dark); }
body .pcb-cart-list { list-style: none; margin: 0 0 10px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
body .pcb-cart-item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	background: #fff;
	border: 1px solid var(--pcb-border);
	border-radius: 10px;
	padding: 8px 12px;
	font-size: 0.85rem;
	font-weight: 600;
	color: var(--pcb-ink);
}
body .pcb-cart-item-remove {
	border: none;
	background: transparent;
	color: var(--pcb-red);
	font-weight: 800;
	cursor: pointer;
	font-size: 1rem;
	line-height: 1;
	padding: 2px 6px;
}
body .pcb-cart-item-remove:hover { transform: scale(1.15); }
body .pcb-cart-total { margin: 0 0 4px; font-weight: 800; color: var(--pcb-accent-dark); }
body .pcb-cart-empty { color: var(--pcb-muted); font-size: 0.85rem; margin: 0 0 10px; }

body .pcb-btn-secondary {
	background: #2BA855;
	color: #fff;
	border: 2px solid var(--pcb-accent);
	box-shadow: none;
}
body .pcb-btn-secondary:hover:not(:disabled) { background: var(--pcb-bg-soft); transform: translateY(-1px); border: 1px solid #2BA855; color: #2BA855; }
body .pcb-btn-secondary:disabled { opacity: 0.5; cursor: not-allowed; }

body .pcb-slot-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
	gap: 10px;
	margin: 12px 0 4px;
}

body .pcb-slot {
	padding: 11px 6px;
	border-radius: 12px;
	border: 2px solid var(--pcb-status-open);
	background: var(--pcb-status-open-bg);
	color: var(--pcb-status-open-dark);
	cursor: pointer;
	font-size: 0.75rem;
	font-weight: 700;
	transition: all 0.12s ease;
}
body .pcb-slot:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 8px 16px -8px rgba(15, 122, 56, 0.45); }
body .pcb-slot:disabled { border-color: var(--pcb-border); background: #f7f8f7; color: #c3cbc6; cursor: not-allowed; }
body .pcb-slot-pending:disabled { border-color: var(--pcb-status-partial); background: var(--pcb-status-partial-bg); color: var(--pcb-status-partial-dark); }
body .pcb-slot-booked:disabled { border-color: var(--pcb-status-full); background: var(--pcb-status-full-bg); color: var(--pcb-status-full-dark); }
body .pcb-slot-selected {
	background: linear-gradient(135deg, var(--pcb-accent), var(--pcb-teal));
	border-color: transparent;
	color: #fff;
	box-shadow: 0 8px 18px -8px rgba(15, 122, 56, 0.55);
}

body .pcb-booking-form { margin-top: 18px; padding-top: 18px; border-top: 1px dashed var(--pcb-border); }
body .pcb-booking-form h4 { margin: 0 0 4px; font-size: 1rem; font-weight: 800; }
body .pcb-selected-slot { color: var(--pcb-muted); font-size: 0.88rem; margin: 0 0 14px; font-weight: 600; }

body .pcb-field-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
	gap: 12px;
	margin-bottom: 6px;
}

body .pcb-booking-form label {
	display: block;
	font-size: 0.82rem;
	font-weight: 700;
	color: var(--pcb-muted);
	margin-bottom: 4px;
}
body .pcb-booking-form input[type="text"],
body .pcb-booking-form input[type="email"],
body .pcb-booking-form input[type="tel"] {
	display: block;
	width: 100%;
	padding: 10px 12px;
	margin-top: 4px;
	border: 2px solid var(--pcb-border);
	border-radius: 10px;
	box-sizing: border-box;
	font-size: 0.9rem;
	font-weight: 500;
	color: var(--pcb-ink);
	transition: border-color 0.15s ease;
}
body .pcb-booking-form input:focus {
	outline: none;
	border-color: var(--pcb-accent);
	box-shadow: 0 0 0 3px color-mix(in srgb, var(--pcb-accent) 15%, transparent);
}

body .pcb-section-label { font-size: 0.82rem; font-weight: 700; color: var(--pcb-muted); margin: 16px 0 8px; }

body .pcb-payment-methods { margin: 6px 0 4px; }

body .pcb-loyalty-toggle-row { margin: 14px 0 0; }
body .pcb-loyalty-checkbox { display: flex; align-items: center; gap: 8px; font-size: 0.86rem; font-weight: 700; color: var(--pcb-ink); cursor: pointer; }
body .pcb-loyalty-checkbox[hidden] { display: none; }
body .pcb-loyalty-checkbox input { accent-color: var(--pcb-accent); width: 16px; height: 16px; }
body .pcb-loyalty-apply-box { margin: 10px 0 4px; padding: 14px; border-radius: 12px; background: var(--pcb-bg-soft); border: 1px solid var(--pcb-border); }
body .pcb-loyalty-apply-box label { display: block; font-size: 0.82rem; font-weight: 700; color: var(--pcb-muted); margin-bottom: 4px; }
body .pcb-loyalty-apply-row { display: flex; gap: 8px; }
body .pcb-loyalty-apply-row input[type="text"] {
	flex: 1;
	padding: 9px 12px;
	border: 2px solid var(--pcb-border);
	border-radius: 10px;
	box-sizing: border-box;
	font-size: 0.88rem;
	font-weight: 500;
	color: var(--pcb-ink);
}
body .pcb-loyalty-apply-row .pcb-btn { margin-top: 0; padding: 9px 16px; white-space: nowrap; }
body .pcb-loyalty-apply-message { font-size: 0.82rem; font-weight: 600; margin: 8px 0 0; }
body .pcb-loyalty-apply-message.pcb-loyalty-ok { color: var(--pcb-status-open-dark); }
body .pcb-loyalty-apply-message.pcb-loyalty-error { color: var(--pcb-red); }
body #pcb-loyalty-redeem-row { margin-top: 10px; }
body .pcb-loyalty-checkbox:has(input:disabled) { opacity: 0.55; cursor: not-allowed; }
body .pcb-loyalty-checkbox:has(input:disabled) input { cursor: not-allowed; }
body .pcb-pay-options { display: flex; flex-wrap: wrap; gap: 10px; }
body .pcb-pay-option {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 9px 16px;
	border: 2px solid var(--pcb-border);
	border-radius: 999px;
	font-weight: 700;
	font-size: 0.85rem;
	cursor: pointer;
	color: var(--pcb-ink);
	background: #fff;
	transition: all 0.15s ease;
}
body .pcb-pay-option:has(input:checked) {
	border-color: var(--pcb-accent);
	background: var(--pcb-bg-soft);
	color: var(--pcb-accent-dark);
	box-shadow: 0 4px 10px -6px rgba(15, 122, 56, 0.4);
}
body .pcb-pay-option input { accent-color: var(--pcb-accent); }

body .pcb-manual-upload {
	margin-top: 14px;
	padding: 16px;
	border-radius: 14px;
	background: #fff7ed;
	border: 1px dashed var(--pcb-orange);
}
body .pcb-manual-instructions { margin: 0 0 10px; font-size: 0.85rem; color: #7c4a11; white-space: pre-line; }
body .pcb-file-label {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: #fff;
	border: 2px solid var(--pcb-orange);
	color: #c2410c;
	border-radius: 10px;
	padding: 9px 16px;
	font-weight: 700;
	font-size: 0.85rem;
	cursor: pointer;
}
body .pcb-file-icon { font-size: 1.1rem; }
body #pcb-proof-input { position: absolute; width: 1px; height: 1px; overflow: hidden; opacity: 0; }
body .pcb-file-preview-name { margin: 8px 0 0; font-size: 0.8rem; color: var(--pcb-muted); font-weight: 600; }

body .pcb-btn {
	border: none;
	border-radius: 12px;
	padding: 13px 26px;
	cursor: pointer;
	font-size: 0.95rem;
	font-weight: 800;
	margin-top: 18px;
	transition: transform 0.1s ease, box-shadow 0.15s ease;
}
body .pcb-btn-primary {
	background: linear-gradient(135deg, var(--pcb-accent), var(--pcb-teal));
	color: #fff;
	box-shadow: 0 10px 22px -10px rgba(15, 122, 56, 0.55);
}
body .pcb-btn-primary:hover:not(:disabled) { transform: translateY(-1px); }
body .pcb-btn-primary:disabled { background: #9bbfa8; box-shadow: none; cursor: wait; }

body .pcb-form-message { color: var(--pcb-red); font-size: 0.85rem; font-weight: 600; margin-top: 10px; }

/* Result cards */
body .pcb-result-card {
	border-radius: 16px;
	padding: 22px;
	text-align: center;
	font-weight: 600;
}
body .pcb-result-info { background: #eff9ff; border: 1px solid #bae6fd; color: #075985; }
body .pcb-result-pending { background: #fff7ed; border: 1px solid #fed7aa; color: #9a3412; }
body .pcb-result-success { background: #ecfdf3; border: 1px solid #a7f3c9; color: var(--pcb-accent-dark); font-size: 1.02rem; }
body .pcb-result-error { background: #fef2f2; border: 1px solid #fecaca; color: #b42323; }
body .pcb-pending-icon { font-size: 1.8rem; margin: 0 0 6px; }

body .pcb-qr-image { display: block; margin: 14px auto; max-width: 220px; border-radius: 12px; border: 1px solid #bae6fd; }
body .pcb-waiting { font-size: 0.85rem; opacity: 0.85; }

body .pcb-loading, .pcb-error { padding: 10px 4px; color: var(--pcb-muted); font-size: 0.85rem; }

/* Admin */
.pcb-status { padding: 3px 10px; border-radius: 999px; font-size: 0.78rem; font-weight: 700; display: inline-block; }
.pcb-status-paid { background: #ecfdf3; color: #0f7a38; }
.pcb-status-pending { background: #fffbea; color: #92700c; }
.pcb-status-pending_verification { background: #fff7ed; color: #9a3412; }
.pcb-status-rejected { background: #fef2f2; color: #b42323; }
.pcb-status-expired { background: #f3f4f6; color: #6b7280; }
.pcb-proof-thumb { width: 48px; height: 48px; object-fit: cover; border-radius: 8px; border: 1px solid #dde8e0; }

.pcb-admin h1 { display: flex; align-items: center; gap: 10px; }
.pcb-admin h2 {
	margin-top: 28px;
	padding-bottom: 8px;
	border-bottom: 2px solid #dcf3e2;
	color: #0f7a38;
}
.pcb-admin .widefat.striped tbody tr:hover { background: #f3faf5; }

/* Bookings filter bar */
.pcb-filters {
	background: #fff;
	border: 1px solid #dde8e0;
	border-radius: 10px;
	padding: 16px 18px 14px;
	margin: 16px 0 18px;
}
.pcb-filters-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
	gap: 12px 16px;
}
.pcb-filter-field label {
	display: block;
	font-size: 0.78rem;
	font-weight: 700;
	color: #5f7368;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	margin-bottom: 4px;
}
.pcb-filter-field input[type="date"],
.pcb-filter-field input[type="text"],
.pcb-filter-field select {
	width: 100%;
	box-sizing: border-box;
}
.pcb-filters-actions {
	margin-top: 14px;
	display: flex;
	gap: 8px;
	align-items: center;
}

/* Grouped multi-slot booking badge in the admin list */
.pcb-group-badge {
	display: inline-block;
	margin-top: 3px;
	font-size: 0.72rem;
	font-weight: 700;
	color: #0f7a38;
	background: #ecfdf3;
	border: 1px solid #a7f3c9;
	border-radius: 999px;
	padding: 1px 8px;
}

/* Bulk "delete filtered / clean test data" tool */
.pcb-bulk-delete-form {
	display: none;
	background: #fef2f2;
	border: 1px solid #fecaca;
	border-radius: 10px;
	padding: 12px 18px 10px;
	margin: 0 0 18px;
}
.pcb-bulk-delete-btn.button-link-delete {
	background: #fff;
	border-color: #b42323;
	color: #b42323;
}
.pcb-bulk-delete-btn.button-link-delete:hover {
	background: #b42323;
	color: #fff;
}
.pcb-bulk-delete-form .description { margin: 6px 0 0; }

/* Per-row delete button in the bookings table */
.pcb-delete-row-btn.button-link-delete {
	margin-left: 4px;
	color: #b42323;
	border-color: #f3c6c6;
}
.pcb-delete-row-btn.button-link-delete:hover {
	background: #b42323;
	border-color: #b42323;
	color: #fff;
}

/* Danger Zone (Settings page) */
.pcb-danger-heading { color: #b42323 !important; border-bottom-color: #fecaca !important; }
.pcb-danger-zone {
	background: #fef2f2;
	border: 1px solid #fecaca;
	border-radius: 10px;
	padding: 16px 18px;
	margin: 12px 0 24px;
}
.pcb-danger-zone > p:first-child { margin-top: 0; }
.pcb-danger-btn.button-link-delete {
	background: #fff;
	border-color: #b42323;
	color: #b42323;
}
.pcb-danger-btn.button-link-delete:hover { background: #b42323; color: #fff; }
.pcb-danger-zone .description { margin: 10px 0 0; }

/* "Go to Settings to delete everything" note shown on the Bookings page
   when no filters are applied (so there's nothing to scope a bulk delete to) */
.pcb-delete-all-hint {
	background: #fff;
	border: 1px dashed #dde8e0;
	border-radius: 10px;
	padding: 12px 16px;
	margin: 0 0 18px;
}

/* ============================================================
   Mobile responsiveness — public booking widget
   ============================================================ */
@media screen and (max-width: 460px) {
	body .pcb-widget { padding: 0 2px; }

	body .pcb-hero { padding: 18px 16px; border-radius: 16px; margin-bottom: 14px; }
	body .pcb-hero-eyebrow { font-size: 0.65rem; padding: 3px 9px; }
	body .pcb-hero-title { font-size: 1.15rem; }

	body .pcb-court-selector { gap: 8px; margin-bottom: 12px; }
	body .pcb-court-tabs { gap: 6px; }
	body .pcb-court-tab { padding: 6px 12px; font-size: 0.78rem; }

	body .pcb-calendar,
	body .pcb-panel { padding: 14px; border-radius: 14px; }
	body .pcb-panel { margin-top: 16px; }

	body .pcb-calendar-header { margin-bottom: 10px; }
	body .pcb-calendar-header h3 { font-size: 1rem; }
	body .pcb-nav { width: 32px; height: 32px; font-size: 1.1rem; border-radius: 8px; }

	body .pcb-calendar-grid { gap: 4px; }
	body .pcb-weekdays span { font-size: 0.62rem; padding: 2px 0; }
	body .pcb-day { min-height: 32px; font-size: 0.78rem; border-radius: 8px; border-width: 1px; }

	body .pcb-legend { gap: 10px 14px; font-size: 0.72rem; margin-top: 12px; }
	body .pcb-dot { width: 9px; height: 9px; }

	body .pcb-panel-title { font-size: 1rem; }
	body .pcb-multi-toggle { padding: 7px 12px; font-size: 0.78rem; }

	body .pcb-slot-grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
	body .pcb-slot { padding: 9px 4px; font-size: 0.78rem; }

	body .pcb-field-grid { grid-template-columns: 1fr; gap: 10px; }

	body .pcb-pay-options { gap: 8px; }
	body .pcb-pay-option { padding: 8px 12px; font-size: 0.78rem; }

	body .pcb-manual-upload { padding: 12px; }
	body .pcb-file-label { padding: 8px 14px; font-size: 0.8rem; }

	body .pcb-btn { width: 100%; padding: 12px 18px; font-size: 0.9rem; }

	body .pcb-result-card { padding: 16px; }
	body .pcb-qr-image { max-width: 180px; }

	body .pcb-cart { padding: 12px 14px; }
	body .pcb-cart-item { flex-wrap: wrap; }
}

@media screen and (max-width: 360px) {
	body .pcb-hero { padding: 14px 12px; }
	body .pcb-hero-title { font-size: 1.02rem; }

	body .pcb-calendar,
	body .pcb-panel { padding: 10px; }

	body .pcb-calendar-grid { gap: 3px; }
	body .pcb-weekdays span { font-size: 0.58rem; padding: 1px 0; }
	body .pcb-day { min-height: 27px; font-size: 0.7rem; border-radius: 6px; }

	body .pcb-nav { width: 28px; height: 28px; font-size: 1rem; }
	body .pcb-calendar-header h3 { font-size: 0.92rem; }

	body .pcb-court-tab { padding: 5px 10px; font-size: 0.72rem; }

	body .pcb-slot-grid { grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 6px; }
	body .pcb-slot { padding: 8px 3px; font-size: 0.72rem; }

	body .pcb-legend { font-size: 0.68rem; gap: 8px 10px; }

	body .pcb-pay-option { padding: 7px 10px; font-size: 0.74rem; }
	body .pcb-file-label { padding: 7px 12px; font-size: 0.76rem; }
}

/* ============================================================
   Mobile responsiveness — wp-admin screens (Bookings / Settings)
   ============================================================ */
@media screen and (max-width: 460px) {
	.pcb-filters-grid { grid-template-columns: 1fr; }
	.pcb-filters-actions { flex-wrap: wrap; }
	.pcb-filters-actions .button { width: 100%; text-align: center; }

	.pcb-danger-zone form { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
	.pcb-danger-btn { width: 100%; text-align: center; }
}

@media screen and (max-width: 782px) {
	.pcb-admin table.widefat { display: block; overflow-x: auto; white-space: nowrap; }
	.pcb-admin table.widefat thead,
	.pcb-admin table.widefat tbody,
	.pcb-admin table.widefat tr { display: table; width: 100%; table-layout: auto; }
}

/* ============================================================
   Schedule Report + Sales Report admin pages
   ============================================================ */
.pcb-report-pdf-form { margin: 4px 0 20px; }

.pcb-report-group-heading {
	margin-top: 26px;
	margin-bottom: 8px;
	padding-bottom: 6px;
	border-bottom: 1px solid #dde8e0;
	color: #0f7a38;
	font-size: 1.02rem;
}
.pcb-report-court-tag {
	display: inline-block;
	margin-left: 8px;
	font-size: 0.72rem;
	font-weight: 700;
	color: #0f7a38;
	background: #ecfdf3;
	border: 1px solid #a7f3c9;
	border-radius: 999px;
	padding: 2px 10px;
	vertical-align: middle;
}

.pcb-schedule-table td, .pcb-schedule-table th { padding: 8px 10px; }

/* Per-slot vacancy status badges (distinct from the payment-status badges
   used on the Bookings list, which use .pcb-status-*). */
.pcb-slot-status { padding: 3px 10px; border-radius: 999px; font-size: 0.78rem; font-weight: 700; display: inline-block; }
.pcb-slot-status-available { background: #ecfdf3; color: #0f7a38; }
.pcb-slot-status-booked { background: #fef2f2; color: #b42323; }
.pcb-slot-status-pending { background: #fffbea; color: #92700c; }
.pcb-slot-status-past { background: #f3f4f6; color: #6b7280; }

.pcb-sales-summary {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
	gap: 14px;
	margin: 14px 0 24px;
}
.pcb-sales-stat {
	background: #fff;
	border: 1px solid #dde8e0;
	border-radius: 10px;
	padding: 14px 16px;
}
.pcb-sales-stat-label {
	display: block;
	font-size: 0.76rem;
	font-weight: 700;
	color: #5f7368;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	margin-bottom: 6px;
}
.pcb-sales-stat-value {
	display: block;
	font-size: 1.5rem;
	font-weight: 800;
	color: #0f7a38;
}
.pcb-sales-breakdown-table { margin-bottom: 22px; max-width: 560px; }

/* Sales Report charts: fixed-size (never squeezed to fit), horizontally
   scrollable, and responsive — the wrapper never exceeds the width of its
   column, so on narrow/mobile screens the chart scrolls instead of
   overflowing the page. Color comes from CSS custom properties set inline
   per-chart (see pcb-chart-color setting), with !important so it always
   wins over any theme/admin stylesheet that happens to target svg fill.
   The `!important` is scoped to these plugin-specific classes only, so it
   can't affect anything outside these charts. */
.pcb-sales-chart {
	background: #fff;
	border: 1px solid #dde8e0;
	border-radius: 10px;
	padding: 12px 14px 4px;
	margin: 8px 0 22px;
	max-width: 100%;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
}
.pcb-sales-chart svg { display: block; }

.pcb-chart-bar { fill: var(--pcb-chart-color, #16a34a) !important; transition: fill 0.15s ease; }
.pcb-chart-bar-group:hover .pcb-chart-bar { fill: var(--pcb-chart-color-dark, #0f7a38) !important; }
.pcb-chart-value { font-size: 8px; fill: var(--pcb-chart-color-dark, #0f7a38) !important; font-weight: 700; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; }
.pcb-chart-label { font-size: 8px; fill: #5f7368 !important; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; }

.pcb-chart-line { fill: none; stroke: var(--pcb-chart-color, #16a34a) !important; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.pcb-chart-area { fill: var(--pcb-chart-color, #16a34a) !important; fill-opacity: 0.12; stroke: none; }
.pcb-chart-dot { fill: #fff !important; stroke: var(--pcb-chart-color, #16a34a) !important; stroke-width: 2; transition: r 0.15s ease, fill 0.15s ease; }
.pcb-chart-dot:hover { fill: var(--pcb-chart-color, #16a34a) !important; r: 4.5; }

/* Email-report boxes on the Schedule Report / Sales Report pages */
.pcb-email-report-box {
	margin: 4px 0 22px;
	max-width: 640px;
}
.pcb-email-report-box summary {
	cursor: pointer;
	font-weight: 600;
	color: #0f7a38;
	padding: 8px 0;
}
.pcb-email-report-form {
	background: #fff;
	border: 1px solid #dde8e0;
	border-radius: 10px;
	padding: 14px 16px;
	margin-top: 6px;
}
.pcb-email-report-form .description { margin: 0 0 10px; }
.pcb-email-report-confirm { display: block; margin-bottom: 12px; font-weight: 600; color: #33413a; }
.pcb-email-report-confirm input[type="checkbox"] { margin-right: 6px; }