/* =========================================================================
   A3 PREGNANCY COMPANION — BRAND COLORS
   Sampled directly from healthreflected.com screenshots (hero, buttons,
   badges, stat numbers). These are the real brand values, not placeholders.
   ========================================================================= */
@import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@500;600;700;800&display=swap');

:root {
	--a3pc-primary: #E8390E;        /* brand orange-red — CTAs, badges, headline accent */
	--a3pc-primary-dark: #C22E0B;   /* hover/active states, darker orange-red */
	--a3pc-primary-light: #FCE8E1;  /* light tinted backgrounds (pale orange) */
	--a3pc-accent: #F2A627;         /* brand gold — badges, stat numbers, highlights */
	--a3pc-danger: #B91C1C;         /* medical red-flag warnings — deliberately distinct from brand orange */
	--a3pc-danger-light: #FBEAEA;
	--a3pc-text: #1A1A1A;
	--a3pc-text-muted: #6b6b6b;
	--a3pc-bg: #FAFAFA;
	--a3pc-border: #E5E5E5;
	--a3pc-white: #ffffff;
	--a3pc-radius: 14px;
	--a3pc-font-heading: 'Baloo 2', -apple-system, sans-serif;
	--a3pc-font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.a3pc-app {
	max-width: 640px;
	margin: 1.5rem auto;
	font-family: var(--a3pc-font-body);
	color: var(--a3pc-text);
	background: var(--a3pc-bg);
	border-radius: 20px;
	overflow: hidden;
	box-shadow: 0 4px 28px rgba(0, 0, 0, 0.08);
}

.a3pc-header-title,
.a3pc-header-week,
.a3pc-counter-number,
.a3pc-stat-value,
.a3pc-baby-size,
.a3pc-btn,
.a3pc-tap-btn {
	font-family: var(--a3pc-font-heading);
}

.a3pc-loading {
	padding: 3rem 1rem;
	text-align: center;
	color: var(--a3pc-text-muted);
}

/* ---------- Header / progress ---------- */
.a3pc-header {
	background: linear-gradient(135deg, var(--a3pc-primary), var(--a3pc-primary-dark));
	color: #fff;
	padding: 1.5rem 1.5rem 1.25rem;
}

.a3pc-header-top {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	margin-bottom: 0.75rem;
}

.a3pc-header-title {
	font-size: 1.1rem;
	font-weight: 700;
}

.a3pc-header-week {
	font-size: 0.85rem;
	opacity: 0.9;
}

.a3pc-progress-track {
	width: 100%;
	height: 8px;
	background: rgba(255, 255, 255, 0.25);
	border-radius: 8px;
	overflow: hidden;
}

.a3pc-progress-fill {
	height: 100%;
	background: #fff;
	border-radius: 8px;
	transition: width 0.4s ease;
}

/* ---------- Tabs ---------- */
.a3pc-tabs {
	display: flex;
	overflow-x: auto;
	background: var(--a3pc-white);
	border-bottom: 1px solid var(--a3pc-border);
	-webkit-overflow-scrolling: touch;
}

.a3pc-tab {
	flex: 0 0 auto;
	padding: 0.85rem 1rem;
	font-size: 0.85rem;
	font-weight: 600;
	color: var(--a3pc-text-muted);
	background: none;
	border: none;
	border-bottom: 3px solid transparent;
	cursor: pointer;
	white-space: nowrap;
}

.a3pc-tab.active {
	color: var(--a3pc-primary-dark);
	border-bottom-color: var(--a3pc-primary);
}

.a3pc-panel {
	padding: 1.5rem;
}

/* ---------- Setup / date entry ---------- */
.a3pc-field-group {
	margin-bottom: 1rem;
}

.a3pc-field-group label {
	display: block;
	font-size: 0.85rem;
	font-weight: 600;
	margin-bottom: 0.35rem;
}

.a3pc-field-group select,
.a3pc-field-group input {
	width: 100%;
	padding: 0.7rem 0.9rem;
	font-size: 1rem;
	border: 1.5px solid var(--a3pc-border);
	border-radius: 10px;
	box-sizing: border-box;
	background: var(--a3pc-white);
}

.a3pc-btn {
	display: inline-block;
	padding: 0.75rem 1.1rem;
	font-size: 0.95rem;
	font-weight: 700;
	color: #fff;
	background: var(--a3pc-primary);
	border: none;
	border-radius: 10px;
	cursor: pointer;
	text-align: center;
}

.a3pc-btn:hover {
	background: var(--a3pc-primary-dark);
}

.a3pc-btn.secondary {
	background: var(--a3pc-white);
	color: var(--a3pc-primary-dark);
	border: 1.5px solid var(--a3pc-primary);
}

.a3pc-btn.full {
	width: 100%;
}

.a3pc-btn.danger {
	background: var(--a3pc-danger);
}

/* ---------- Baby visual (size icon + growth bar) ---------- */
.a3pc-baby-visual {
	text-align: center;
	padding: 1.25rem 1rem 0.5rem;
}

.a3pc-baby-icon-big {
	font-size: 4rem;
	line-height: 1;
	margin-bottom: 0.6rem;
	filter: drop-shadow(0 4px 10px rgba(0,0,0,0.12));
}

.a3pc-baby-silhouette-track {
	width: 80%;
	max-width: 220px;
	height: 10px;
	background: var(--a3pc-primary-light);
	border-radius: 10px;
	margin: 0 auto;
	overflow: hidden;
}

.a3pc-baby-silhouette-fill {
	height: 100%;
	background: linear-gradient(90deg, var(--a3pc-primary), var(--a3pc-primary-dark));
	border-radius: 10px;
	transition: width 0.4s ease;
}

.a3pc-baby-visual-caption {
	font-size: 0.68rem;
	color: var(--a3pc-text-muted);
	margin-top: 0.5rem;
}

/* ---------- Baby size card ---------- */
.a3pc-baby-card {
	display: flex;
	gap: 1rem;
	align-items: center;
	background: var(--a3pc-primary-light);
	border-radius: var(--a3pc-radius);
	padding: 1.1rem;
	margin-bottom: 1rem;
}

.a3pc-baby-emoji {
	font-size: 2.5rem;
}

.a3pc-baby-size {
	font-weight: 800;
	font-size: 1.1rem;
	color: var(--a3pc-primary-dark);
}

.a3pc-baby-meta {
	font-size: 0.8rem;
	color: var(--a3pc-text-muted);
}

.a3pc-baby-note {
	font-size: 0.9rem;
	margin-top: 0.5rem;
	line-height: 1.4;
}

.a3pc-stat-row {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 0.6rem;
	margin-bottom: 1rem;
}

.a3pc-stat {
	background: var(--a3pc-white);
	border: 1px solid var(--a3pc-border);
	border-radius: 12px;
	padding: 0.8rem 0.4rem;
	text-align: center;
}

.a3pc-stat-value {
	display: block;
	font-size: 1.2rem;
	font-weight: 800;
}

.a3pc-stat-label {
	display: block;
	font-size: 0.68rem;
	color: var(--a3pc-text-muted);
	text-transform: uppercase;
	margin-top: 0.15rem;
}

/* ---------- Kick counter / contraction timer ---------- */
.a3pc-counter-display {
	text-align: center;
	padding: 1.5rem 0;
}

.a3pc-counter-number {
	font-size: 3.5rem;
	font-weight: 800;
	color: var(--a3pc-primary-dark);
	line-height: 1;
}

.a3pc-counter-label {
	color: var(--a3pc-text-muted);
	font-size: 0.85rem;
	margin-top: 0.3rem;
}

.a3pc-tap-btn {
	width: 140px;
	height: 140px;
	border-radius: 50%;
	background: var(--a3pc-primary);
	color: #fff;
	font-size: 1.1rem;
	font-weight: 700;
	border: none;
	margin: 1rem auto;
	display: block;
	cursor: pointer;
	box-shadow: 0 6px 20px rgba(232, 57, 14, 0.35);
}

.a3pc-tap-btn:active {
	transform: scale(0.96);
}

.a3pc-history-list {
	margin-top: 1rem;
	border-top: 1px solid var(--a3pc-border);
	padding-top: 1rem;
}

.a3pc-history-item {
	display: flex;
	justify-content: space-between;
	padding: 0.55rem 0;
	font-size: 0.85rem;
	border-bottom: 1px dashed var(--a3pc-border);
}

.a3pc-alert-banner {
	background: var(--a3pc-danger-light);
	color: var(--a3pc-danger);
	border: 1px solid var(--a3pc-danger);
	border-radius: 10px;
	padding: 0.9rem;
	font-size: 0.85rem;
	font-weight: 600;
	margin-bottom: 1rem;
	line-height: 1.4;
}

/* ---------- Weight chart ---------- */
.a3pc-chart-wrap {
	background: var(--a3pc-white);
	border: 1px solid var(--a3pc-border);
	border-radius: var(--a3pc-radius);
	padding: 1rem;
	margin-bottom: 1rem;
}

.a3pc-chart-legend {
	display: flex;
	gap: 1rem;
	font-size: 0.75rem;
	color: var(--a3pc-text-muted);
	margin-top: 0.5rem;
}

.a3pc-legend-dot {
	display: inline-block;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	margin-right: 4px;
}

/* ---------- Symptom list ---------- */
.a3pc-symptom-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0.5rem;
	margin-bottom: 1rem;
}

.a3pc-symptom-chip {
	padding: 0.6rem 0.7rem;
	border: 1.5px solid var(--a3pc-border);
	border-radius: 10px;
	font-size: 0.82rem;
	text-align: center;
	cursor: pointer;
	background: var(--a3pc-white);
}

.a3pc-symptom-chip.logged {
	background: var(--a3pc-primary-light);
	border-color: var(--a3pc-primary);
	color: var(--a3pc-primary-dark);
	font-weight: 700;
}

.a3pc-symptom-chip.redflag {
	border-color: var(--a3pc-danger);
}

.a3pc-symptom-chip.redflag.logged {
	background: var(--a3pc-danger-light);
	color: var(--a3pc-danger);
	border-color: var(--a3pc-danger);
}

/* ---------- Checklist ---------- */
.a3pc-checklist-category {
	margin-bottom: 1.25rem;
}

.a3pc-checklist-category h4 {
	font-size: 0.9rem;
	margin-bottom: 0.5rem;
	color: var(--a3pc-primary-dark);
}

.a3pc-checklist-item {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	padding: 0.5rem 0;
	font-size: 0.9rem;
	border-bottom: 1px solid var(--a3pc-border);
}

.a3pc-checklist-item input {
	width: 18px;
	height: 18px;
	flex-shrink: 0;
}

.a3pc-checklist-item.checked span {
	text-decoration: line-through;
	color: var(--a3pc-text-muted);
}

/* ---------- Save / sync ---------- */
.a3pc-sync-box {
	background: var(--a3pc-primary-light);
	border-radius: var(--a3pc-radius);
	padding: 1.1rem;
	text-align: center;
}

.a3pc-sync-box p {
	font-size: 0.85rem;
	color: var(--a3pc-text);
	margin-bottom: 0.75rem;
}

.a3pc-sync-form {
	display: flex;
	gap: 0.5rem;
}

.a3pc-sync-form input {
	flex: 1;
}

.a3pc-success-msg {
	color: var(--a3pc-primary-dark);
	font-weight: 700;
	font-size: 0.9rem;
	margin-top: 0.75rem;
}

.a3pc-disclaimer {
	font-size: 0.72rem;
	color: var(--a3pc-text-muted);
	line-height: 1.4;
	margin-top: 1.25rem;
	padding-top: 1rem;
	border-top: 1px dashed var(--a3pc-border);
}

@media (max-width: 480px) {
	.a3pc-app {
		margin: 0.5rem;
		border-radius: 14px;
	}
	.a3pc-panel {
		padding: 1.1rem;
	}
	.a3pc-symptom-grid {
		grid-template-columns: 1fr;
	}
}
