/* Site-wide polish — reveal, sticky CTA, a11y, micro-interactions */

/* Skip link */
.ph-skip {
	position: absolute;
	left: -9999px;
	top: 0;
	z-index: 100000;
	padding: 12px 18px;
	background: var(--ph-navy, #111d6a);
	color: #fff !important;
	font-family: "Poppins", sans-serif;
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	border-radius: 0 0 10px 0;
}

.ph-skip:focus {
	left: 0;
}

/* Focus ring */
:focus-visible {
	outline: 2px solid var(--ph-accent, #f77f00);
	outline-offset: 3px;
}

a:focus:not(:focus-visible),
button:focus:not(:focus-visible) {
	outline: none;
}

/* Scroll reveal */
.ph-reveal {
	opacity: 0;
	transform: translateY(28px);
	transition:
		opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1),
		transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
	will-change: opacity, transform;
}

.ph-reveal.is-in {
	opacity: 1;
	transform: translateY(0);
}

.ph-reveal--delay-1 { transition-delay: 0.08s; }
.ph-reveal--delay-2 { transition-delay: 0.16s; }
.ph-reveal--delay-3 { transition-delay: 0.24s; }
.ph-reveal--delay-4 { transition-delay: 0.32s; }

@media (prefers-reduced-motion: reduce) {
	.ph-reveal {
		opacity: 1;
		transform: none;
		transition: none;
	}

	.ph-stat__num,
	.ph-split__btn,
	.ph-team__all,
	.ph-ap-btn,
	.ph-dept-el__btn,
	.ph-doc-card__cta,
	.ph-sticky-cta__btn {
		transition: none !important;
	}
}

/* Shared CTA press */
.ph-split__btn,
.ph-team__all,
.ph-ap-btn,
.ph-dept-el__btn,
.ph-svc .ph-ap-btn,
.ph-care__cta {
	transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.ph-split__btn:active,
.ph-team__all:active,
.ph-ap-btn:active,
.ph-dept-el__btn:active,
.ph-care__cta:active {
	transform: translateY(1px) scale(0.98);
}

/* Homepage stats */
.ph-stats {
	position: relative;
	z-index: 2;
	margin-top: -48px;
	padding: 0 20px 8px;
}

.ph-stats__grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 0;
	max-width: 1100px;
	margin: 0 auto;
	overflow: hidden;
	background: #fff;
	border: 1px solid var(--ph-line, #e8eef5);
	border-radius: 18px;
	box-shadow: 0 18px 44px rgba(17, 29, 106, 0.12);
}

.ph-stat {
	position: relative;
	padding: 28px 18px;
	text-align: center;
	background: linear-gradient(180deg, #ffffff 0%, #f7fafc 100%);
}

.ph-stat + .ph-stat::before {
	content: "";
	position: absolute;
	left: 0;
	top: 22%;
	bottom: 22%;
	width: 1px;
	background: var(--ph-line, #e8eef5);
}

.ph-stat__num {
	display: block;
	margin: 0 0 6px;
	color: var(--ph-navy, #111d6a);
	font-family: "Poppins", sans-serif;
	font-size: clamp(28px, 3.2vw, 40px);
	font-weight: 700;
	line-height: 1.1;
	letter-spacing: -0.02em;
}

.ph-stat__num span {
	color: var(--ph-accent, #f77f00);
}

.ph-stat__label {
	margin: 0;
	color: var(--ph-muted, #4a5568);
	font-family: "Poppins", sans-serif;
	font-size: 13px;
	font-weight: 500;
	line-height: 1.4;
}

/* Sticky mobile appointment bar */
.ph-sticky-cta {
	display: none;
}

@media (max-width: 760px) {
	.ph-stats {
		margin-top: -28px;
		padding-bottom: 4px;
	}

	.ph-stats__grid {
		grid-template-columns: 1fr 1fr;
		border-radius: 14px;
	}

	.ph-stat {
		padding: 20px 12px;
	}

	.ph-stat + .ph-stat::before {
		display: none;
	}

	.ph-stat:nth-child(odd) {
		border-right: 1px solid var(--ph-line, #e8eef5);
	}

	.ph-stat:nth-child(-n+2) {
		border-bottom: 1px solid var(--ph-line, #e8eef5);
	}

	.ph-sticky-cta {
		position: fixed;
		left: 0;
		right: 0;
		bottom: 0;
		z-index: 9999;
		display: grid;
		grid-template-columns: 1.35fr 1fr 1fr;
		gap: 0;
		background: var(--ph-navy, #111d6a);
		box-shadow: 0 -8px 28px rgba(17, 29, 106, 0.28);
		padding: env(safe-area-inset-bottom, 0) 0 0;
	}

	.ph-sticky-cta__btn {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		gap: 4px;
		min-height: 58px;
		padding: 8px 6px;
		color: #fff !important;
		font-family: "Poppins", sans-serif;
		font-size: 11px;
		font-weight: 600;
		text-decoration: none;
		border-right: 1px solid rgba(255, 255, 255, 0.12);
	}

	.ph-sticky-cta__btn:last-child {
		border-right: 0;
	}

	.ph-sticky-cta__btn svg {
		display: block;
	}

	.ph-sticky-cta__btn--book {
		background: var(--ph-accent, #f77f00);
		font-size: 12px;
		font-weight: 700;
		letter-spacing: 0.02em;
	}

	.ph-sticky-cta__btn--book:hover,
	.ph-sticky-cta__btn:hover {
		filter: brightness(1.05);
		color: #fff !important;
	}

	/* Hide old float + bump scrolltop above sticky */
	.ph-float {
		display: none !important;
	}

	.ph-scrolltop {
		bottom: 72px;
	}

	body {
		padding-bottom: 72px;
	}
}

/* Doctor card polish (archive cards) */
.ph-doctor-card:hover,
.ph-doc-card:hover {
	border-color: rgba(17, 29, 106, 0.22);
}

.ph-doc-card__content .ph-doc-card__role {
	display: inline-block;
	max-width: 100%;
	padding: 5px 10px;
	margin-top: 2px;
	background: var(--ph-accent-soft, #fff4e8);
	border-radius: 999px;
	color: var(--ph-accent-dark, #e06a00);
	font-size: 12px;
	font-weight: 600;
	line-height: 1.35;
}
