/* =============================================================================
   APG Coaching — Admin Styles
   ============================================================================= */

/* Cards do dashboard */
.apg-admin-cards {
	display: flex;
	gap: 20px;
	margin: 24px 0;
	flex-wrap: wrap;
}

.apg-admin-card {
	background: #ffffff;
	border: 1px solid #e2e4e7;
	border-radius: 8px;
	padding: 24px 36px;
	display: flex;
	flex-direction: column;
	align-items: center;
	min-width: 160px;
	box-shadow: 0 1px 4px rgba( 0, 0, 0, 0.06 );
}

.apg-card-number {
	font-size: 2.6rem;
	font-weight: 700;
	color: #1a3a5c;
	line-height: 1;
}

.apg-card-label {
	font-size: 0.82rem;
	color: #666;
	margin-top: 8px;
	text-align: center;
}

/* Info shortcode */
.apg-admin-shortcode-info {
	background: #eaf4f7;
	border: 1px solid #a8d4dd;
	border-radius: 6px;
	padding: 16px 20px;
	margin-top: 24px;
	max-width: 480px;
}

.apg-admin-shortcode-info h3 {
	margin: 0 0 8px;
	font-size: 0.95rem;
	color: #1a3a5c;
}

.apg-admin-shortcode-info p {
	margin: 0 0 8px;
	font-size: 0.9rem;
	color: #444;
}

.apg-admin-shortcode-info code {
	background: #fff;
	border: 1px solid #a8d4dd;
	padding: 4px 10px;
	border-radius: 4px;
	font-size: 1rem;
	color: #1a3a5c;
}

/* Formulario de filtro */
.apg-filter-form {
	margin: 16px 0;
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
}

.apg-filter-form select,
.apg-filter-form input[type="number"] {
	height: 30px;
	padding: 0 8px;
	border: 1px solid #8c8f94;
	border-radius: 4px;
	font-size: 0.9rem;
}

/* Contador */
.apg-total-count {
	color: #555;
	font-size: 0.9rem;
	margin: 8px 0 12px;
}

/* Tabela */
.apg-checkins-table .col-note {
	width: 70px;
	text-align: center;
}

.apg-checkins-table .col-ceo    { width: 160px; }
.apg-checkins-table .col-period { width: 120px; }
.apg-checkins-table .col-date   { width: 100px; }
.apg-checkins-table .col-actions { width: 80px; }

/* Badge de nota */
.apg-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: #1a3a5c;
	color: #ffffff;
	border-radius: 50%;
	width: 28px;
	height: 28px;
	font-weight: 700;
	font-size: 0.8rem;
}

/* Preview do conteudo */
.apg-content-preview {
	color: #666;
	font-style: italic;
	font-size: 0.875rem;
	cursor: help;
}

/* Botao deletar */
.apg-btn-delete {
	color: #b32d2e !important;
	border-color: #b32d2e !important;
}

.apg-btn-delete:hover {
	background: #b32d2e !important;
	color: #ffffff !important;
}

/* Paginacao */
.apg-pagination {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 8px 0;
}

.apg-page-info {
	font-size: 0.875rem;
	color: #555;
}

/* Score badges in admin checkin list */
/* Group pill — used in admin lists where the group name needs room */
.apg-group-pill {
	display: inline-block;
	background: #1a3a5c;
	color: #fff;
	padding: 4px 14px;
	border-radius: 999px;
	font-weight: 600;
	font-size: 0.82rem;
	line-height: 1.4;
	letter-spacing: 0.2px;
	white-space: nowrap;
	max-width: 100%;
	overflow: hidden;
	text-overflow: ellipsis;
	vertical-align: middle;
}

.apg-badge--score-1 { background: #ef4444 !important; color: #fff !important; }
.apg-badge--score-2 { background: #f59e0b !important; color: #fff !important; }
.apg-badge--score-3 { background: #22c55e !important; color: #fff !important; }
.apg-checkins-table .apg-badge { font-weight: 600; padding: 3px 8px; border-radius: 4px; font-size: 0.78rem; white-space: nowrap; }

/* Attendance report */
.apg-att-report th, .apg-att-report td { text-align: center; }
.apg-att-report th:first-child, .apg-att-report td:first-child { text-align: left; }
.apg-att-report .apg-total-col { background: #eaf4f7; font-weight: 700; }
.apg-att-report tfoot .apg-total-row { background: #f5f9ff; font-weight: 600; }
.apg-att-report .apg-att-cell { font-weight: 600; white-space: nowrap; }
.apg-att-code-1 { background: #d1fae5 !important; color: #065f46 !important; }
.apg-att-code-2 { background: #fef3c7 !important; color: #92400e !important; }
.apg-att-code-3 { background: #fee2e2 !important; color: #991b1b !important; }

/* OCI report */
.apg-oci-report th, .apg-oci-report td { text-align: center; }
.apg-oci-report th:first-child, .apg-oci-report td:first-child { text-align: left; }
.apg-oci-report .apg-total-col { background: #eaf4f7; font-weight: 700; }
.apg-oci-report tfoot .apg-total-row { background: #f5f9ff; font-weight: 600; }
.apg-oci-report .apg-qtr-col { background: #f0ebff; font-weight: 600; }
.apg-oci-report .apg-oci-has { background: #d1fae5; color: #065f46; font-weight: 700; }

/* Score semaphore dots — used in the check-ins admin list */
.apg-checkins-table .apg-badge--score-1,
.apg-checkins-table .apg-badge--score-2,
.apg-checkins-table .apg-badge--score-3 {
	display: inline-block;
	width: 18px;
	height: 18px;
	border-radius: 50%;
	padding: 0 !important;
	font-size: 0 !important;
	line-height: 0;
	vertical-align: middle;
	box-shadow: 0 0 0 2px rgba(0,0,0,0.06);
}
.apg-checkins-table .apg-badge--score-0 {
	display: inline-block;
	width: 18px;
	height: 18px;
	border-radius: 50%;
	background: #e5e7eb !important;
	padding: 0 !important;
	font-size: 0 !important;
}

/* Frontend admin shortcode container + tabs */
.apg-admin-shortcode {
	max-width: 1200px;
	margin: 0 auto;
	padding: 16px 20px 40px;
	background: #f0f0f1;
	min-height: 400px;
}
.apg-admin-shortcode-nav {
	display: flex;
	flex-wrap: wrap;
	gap: 2px;
	border-bottom: 1px solid #c3c4c7;
	margin-bottom: 20px;
}
.apg-admin-shortcode-tab {
	display: inline-block;
	padding: 10px 18px;
	background: #f6f7f7;
	color: #50575e;
	text-decoration: none;
	border: 1px solid #c3c4c7;
	border-bottom: none;
	border-radius: 4px 4px 0 0;
	font-weight: 600;
	font-size: 0.9rem;
	margin-bottom: -1px;
}
.apg-admin-shortcode-tab:hover { background: #fff; color: #1a3a5c; }
.apg-admin-shortcode-tab.is-active {
	background: #fff;
	color: #1d2327;
	border-bottom: 1px solid #fff;
	position: relative;
	z-index: 1;
}
.apg-admin-shortcode-body {
	background: #fff;
	padding: 4px 20px 20px;
	border: 1px solid #c3c4c7;
	border-top: none;
}
.apg-admin-shortcode-body .wrap { margin: 0; padding-top: 8px; }

/* Attendance legend — pill-shaped labels (overrides the round .apg-badge look) */
.apg-att-legend {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 12px 0;
}
.apg-att-legend-pill {
	display: inline-block;
	padding: 3px 12px;
	border-radius: 999px;
	font-size: 0.82rem;
	font-weight: 600;
	letter-spacing: 0.2px;
	white-space: nowrap;
	line-height: 1.6;
}
