/*
 * Town / service-area / For Patients / For Providers pages (page-town.php only).
 * Homepage visual system: navy Montserrat headings, orange as accent, white cards
 * with the homepage border + shadow on light-grey bands, pill buttons. Task #58.
 * Colours are the theme's: navy #014E6C / #1D5797, blue #016FB7, orange #FB8637,
 * band #f4f7fb, card border #e4ebf4.
 */

#primary.gps-tp { color: #3a4458; }

/* ---------- Hero ---------- */
.gps-tp-hero {
	background: linear-gradient(180deg, #f4f7fb 0%, #eaf1fb 100%);
	border-bottom: 1px solid #e4ebf4;
	padding: 2.5rem 0 2.75rem;
}
.gps-tp-hero__grid { display: grid; gap: 2rem; align-items: center; }
.gps-tp-hero--photo .gps-tp-hero__grid { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 992px) {
	.gps-tp-hero { padding: 3.5rem 0; }
	.gps-tp-hero--photo .gps-tp-hero__grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 3rem; }
}
#primary.gps-tp h1.gps-tp-hero__title {
	font-family: 'Montserrat', sans-serif;
	color: #014E6C;
	font-weight: 600;
	font-size: clamp(1.75rem, 1.2rem + 2vw, 2.6rem);
	line-height: 1.2;
	margin: 0 0 1rem;
	padding: 0;
}
#primary.gps-tp h1.gps-tp-hero__title::before { content: none; }
#primary.gps-tp .gps-tp-hero__title::after {
	content: ""; display: block; width: 64px; height: 3px;
	background: #FB8637; border-radius: 2px; margin-top: .85rem;
}
#primary.gps-tp p.gps-tp-hero__lead {
	font-size: 1.25rem; line-height: 1.55; color: #4a5673; margin: 0 0 1.5rem;
}
@media (max-width: 767px) {
	.gps-tp-hero { padding: 1.75rem 0 2rem; }
	#primary.gps-tp p.gps-tp-hero__lead { font-size: 1.125rem; }
}
.gps-tp-hero__btns { display: flex; flex-wrap: wrap; gap: .6rem; }
.gps-tp-hero__photo { margin: 0; }
.gps-tp-hero__photo img {
	display: block; width: 100%; height: auto; aspect-ratio: 2 / 1; object-fit: cover;
	border-radius: 12px; box-shadow: 3px 15px 37px rgba(37, 56, 88, 0.12);
}
.gps-tp-hero__photo figcaption { font-size: .8rem; color: #5b6577; margin-top: .5rem; line-height: 1.4; }
.gps-tp-hero__photo figcaption a { color: inherit; }

/* ---------- Buttons (pill, like the homepage) ---------- */
#primary.gps-tp a.gps-tp-btn {
	display: inline-flex; align-items: center; justify-content: center;
	font-family: 'Montserrat', sans-serif; font-weight: 700; font-size: .95rem;
	padding: .65rem 1.5rem; border-radius: 50px; text-decoration: none;
	border: 2px solid #016FB7; line-height: 1.2; min-height: 44px;
	transition: background .15s ease, color .15s ease;
}
#primary.gps-tp a.gps-tp-btn--call { background: #016FB7; color: #fff; }
#primary.gps-tp a.gps-tp-btn--call:hover { background: #014E6C; border-color: #014E6C; }
#primary.gps-tp a.gps-tp-btn--ghost { background: #fff; color: #014E6C; }
#primary.gps-tp a.gps-tp-btn--ghost:hover { background: #014E6C; border-color: #014E6C; color: #fff; }

/* ---------- Layout: main column + sticky sidebar ---------- */
.gps-tp-body { padding-top: 2rem; padding-bottom: 3rem; }
.gps-tp-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2rem; }
@media (min-width: 1100px) {
	.gps-tp--aside .gps-tp-layout { grid-template-columns: minmax(0, 1fr) 340px; gap: 2.5rem; align-items: start; }
	.gps-tp-aside__inner { position: sticky; top: 1.5rem; }
}
@media (max-width: 575px) {
	#primary.gps-tp .container { padding-left: 16px; padding-right: 16px; }
}

/* ---------- Type ---------- */
#primary.gps-tp .entry-content h2,
#primary.gps-tp .gps-tp-aside h2 {
	font-family: 'Montserrat', sans-serif;
	color: #014E6C; font-weight: 600;
	font-size: clamp(1.35rem, 1.1rem + 0.8vw, 1.7rem);
	line-height: 1.25; margin: 0 0 1rem; padding: 0;
}
#primary.gps-tp .entry-content h2::after {
	content: ""; display: block; width: 48px; height: 3px;
	background: #FB8637; border-radius: 2px; margin-top: .6rem;
}
#primary.gps-tp .entry-content h3 {
	font-family: 'Montserrat', sans-serif;
	color: #1D5797; font-weight: 600; font-size: 1.1rem; line-height: 1.35;
	margin: 1.5rem 0 .4rem;
}
#primary.gps-tp .entry-content p,
#primary.gps-tp .entry-content li,
#primary.gps-tp .gps-tp-aside p {
	color: #3a4458; font-size: 1.0625rem; line-height: 1.65;
}
#primary.gps-tp .entry-content li { margin: .45rem 0; }
#primary.gps-tp .entry-content strong { color: #22304a; }
#primary.gps-tp .entry-content a:not(.gps-tp-btn):not(.wp-block-button__link) { color: #016FB7; }
@media (max-width: 480px) {
	#primary.gps-tp .entry-content p,
	#primary.gps-tp .entry-content li { font-size: 1rem; }
}

/* ---------- Sections and bands ---------- */
.gps-tp-sec { padding: 1.75rem 0; }
.gps-tp-sec:first-child { padding-top: .5rem; }
.gps-tp-sec--band {
	background: #f4f7fb; border: 1px solid #e4ebf4; border-radius: 16px;
	padding: 1.75rem 1.5rem; margin: 1rem 0;
}
.gps-tp-sec--band + .gps-tp-sec--band { margin-top: 1.25rem; }
@media (max-width: 575px) {
	.gps-tp-sec--band { padding: 1.25rem 1rem; border-radius: 12px; }
}
.gps-tp-sec > .wp-block-group { margin: 0; padding: 0; }

/* Bullet lists in plain sections: orange dot, two columns on wide screens */
#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ul { list-style: none; padding-left: 0; }
#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ul > li { position: relative; padding-left: 1.25rem; }
#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ul > li::before {
	content: ""; position: absolute; left: 0; top: .7em;
	width: 7px; height: 7px; border-radius: 50%; background: #FB8637; margin-left: 0;
}
/* two columns only for longer lists; a two-item list reads better as one */
@media (min-width: 768px) {
	#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ul:has(> li:nth-child(6)) { columns: 2; column-gap: 2.5rem; }
	#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ul > li { break-inside: avoid; }
}

/* ---------- Cards ---------- */
.gps-tp-card,
#primary.gps-tp .gps-tp-sec--band .wp-block-group__inner-container > ul > li,
#primary.gps-tp .gps-town-steps ol > li,
#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ol > li,
#primary.gps-tp blockquote.gps-town-review,
#primary.gps-tp .gps-tp-sec--band .gps-town-weather,
#primary.gps-tp .gps-tp-contact {
	background: #fff; border: 1px solid #e4ebf4; border-radius: 12px;
	box-shadow: 3px 15px 37px rgba(37, 56, 88, 0.06);
}

/* Card grids: at a glance, health resources, practices */
#primary.gps-tp .gps-tp-sec--band .wp-block-group__inner-container > ul {
	list-style: none; padding: 0; margin: 0;
	display: grid; gap: 1rem; grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 768px) {
	#primary.gps-tp .gps-tp-sec--band .wp-block-group__inner-container > ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	#primary.gps-tp .gps-tp-sec--band .gps-local-facts:not(.gps-town-resources):not(.gps-town-practices) > .wp-block-group__inner-container > ul { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
#primary.gps-tp .gps-tp-sec--band .wp-block-group__inner-container > ul > li { margin: 0; padding: 1.1rem 1.2rem; font-size: 1rem; }
#primary.gps-tp .gps-tp-sec--band .wp-block-group__inner-container > ul > li::before { content: none; display: none; }

/* Weather */
#primary.gps-tp .gps-tp-sec--band .gps-town-weather { margin: 0; padding: 1.25rem 1.4rem; }
#primary.gps-tp .gps-town-weather h2 { font-size: 1.35rem !important; }
#primary.gps-tp .gps-town-weather p.gps-town-weather__now { font-size: 1.2rem; color: #014E6C; font-weight: 700; }
#primary.gps-tp .gps-town-weather p.gps-town-weather__src { font-size: .875rem; color: #5b6577; }

/* Reviews: quote cards with the name */
#primary.gps-tp .gps-town-reviews > .wp-block-group__inner-container { display: grid; gap: 1rem; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 768px) {
	#primary.gps-tp .gps-town-reviews > .wp-block-group__inner-container { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	#primary.gps-tp .gps-town-reviews > .wp-block-group__inner-container > h2,
	#primary.gps-tp .gps-town-reviews > .wp-block-group__inner-container > p { grid-column: 1 / -1; }
}
#primary.gps-tp .gps-town-reviews h2 { margin-bottom: 0; }
#primary.gps-tp blockquote.gps-town-review {
	margin: 0; padding: 1.4rem 1.4rem 1.1rem; border-left: 1px solid #e4ebf4;
	display: flex; flex-direction: column; font-style: normal;
}
#primary.gps-tp blockquote.gps-town-review::before {
	content: "★★★★★"; color: #FB8637; letter-spacing: .05em; margin-bottom: .6rem; font-size: .95rem;
}
#primary.gps-tp blockquote.gps-town-review p { font-style: normal; font-size: 1rem; flex: 1; margin-bottom: .9rem; }
#primary.gps-tp blockquote.gps-town-review cite {
	font-style: normal; font-weight: 700; color: #1D5797; font-size: .95rem;
	padding-top: .7rem; border-top: 1px solid #eef2f7;
}
#primary.gps-tp .gps-town-reviews > .wp-block-group__inner-container > p { margin: 0; }

/* How to get a prescription filled: numbered step cards */
#primary.gps-tp .gps-town-steps ol,
#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ol {
	list-style: none; counter-reset: gpstp; padding: 0; margin: 0 0 1.25rem;
	display: grid; gap: 1rem; grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 768px) {
	#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ol { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
	#primary.gps-tp .gps-town-steps ol { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
#primary.gps-tp .gps-town-steps ol > li,
#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ol > li {
	counter-increment: gpstp; margin: 0; padding: 1.25rem 1.2rem 1.3rem; font-size: 1rem;
}
#primary.gps-tp .gps-town-steps ol > li::before,
#primary.gps-tp .gps-tp-sec:not(.gps-tp-sec--band) > ol > li::before {
	content: counter(gpstp);
	display: flex; align-items: center; justify-content: center;
	width: 44px; height: 44px; border-radius: 50%; margin-bottom: .75rem;
	background: #FB8637; color: #fff; font-weight: 700; font-size: 1.2rem;
	font-family: 'Montserrat', sans-serif;
}
#primary.gps-tp .gps-town-steps p:last-child { margin-bottom: 0; }

/* About <Town> and other plain groups */
#primary.gps-tp .gps-town-about p:last-child { margin-bottom: 0; }

/* ---------- Sidebar: map + contact ---------- */
.gps-tp-aside .gps-town-map {
	background: #fff; border: 1px solid #e4ebf4; border-radius: 12px; overflow: hidden;
	box-shadow: 3px 15px 37px rgba(37, 56, 88, 0.06); margin-bottom: 1.25rem;
}
#primary.gps-tp .gps-tp-aside .gps-town-map h2 { font-size: 1.05rem !important; line-height: 1.3 !important; padding: 1rem 1.1rem 0; margin-bottom: .75rem; }
.gps-tp-aside .gps-town-map iframe { height: 300px; }
#primary.gps-tp .gps-tp-aside .gps-town-map__credit { font-size: .85rem; line-height: 1.5; padding: .7rem 1.1rem .9rem; margin: 0; }
#primary.gps-tp .gps-tp-contact { padding: 1.2rem 1.25rem 1.35rem; }
#primary.gps-tp .gps-tp-contact h2 { font-size: 1.2rem !important; line-height: 1.3 !important; }
#primary.gps-tp .gps-tp-contact p { font-size: 1rem; margin-bottom: .75rem; }
#primary.gps-tp .gps-tp-contact a.gps-tp-btn { width: 100%; margin-top: .25rem; }

/* Doctors named under a practice (item 8) */
#primary.gps-tp .gps-town-practices .gps-town-doctors { display: block; margin-top: .35rem; font-size: .9375rem; line-height: 1.5; color: #3a4458; }

/* Pictures (task #58, Dino Nov. 22nd): icon per list point, photo beside the first text section. */
#primary.gps-tp .gps-tp-sec > ul.gps-tp-iconlist{list-style:none;padding:0;margin:1rem 0 0;display:grid;grid-template-columns:1fr;gap:.75rem 1.5rem}
@media (min-width:768px){#primary.gps-tp .gps-tp-sec > ul.gps-tp-iconlist{grid-template-columns:1fr 1fr;columns:auto!important}}
#primary.gps-tp .gps-tp-sec > ul.gps-tp-iconlist>li{display:flex;gap:.85rem;align-items:flex-start;margin:0;padding:0;break-inside:avoid}
#primary.gps-tp .gps-tp-sec > ul.gps-tp-iconlist>li::before{content:none!important;display:none!important}
#primary.gps-tp .gps-tp-sec > ul.gps-tp-iconlist>li>div{flex:1;min-width:0;padding-top:.45rem}
.gps-tp-ico{flex:0 0 44px;width:44px;height:44px;border-radius:50%;background:#eaf2fa;color:#014E6C;display:flex;align-items:center;justify-content:center;box-shadow:inset 0 -3px 0 #FB8637}
.gps-tp-secimg{margin:0 0 1rem}
.gps-tp-secimg img{display:block;width:100%;height:auto;aspect-ratio:894/600;object-fit:cover;border-radius:12px;box-shadow:0 6px 20px rgba(1,78,108,.12)}
@media (min-width:768px){.gps-tp-secimg{float:right;width:42%;max-width:380px;margin:.25rem 0 1rem 1.75rem}.gps-tp-sec--intro::after{content:"";display:table;clear:both}}
/* Resource / practice cards: icon left of the name (task #58 pictures part 2) */
#primary.gps-tp .gps-tp-sec--band ul.gps-tp-placelist>li{display:flex;gap:.85rem;align-items:flex-start}
#primary.gps-tp .gps-tp-sec--band ul.gps-tp-placelist>li>div{flex:1;min-width:0;padding-top:.15rem}
/* Static sidebar map (task 58): a picture of the OSM view, links to the larger map. */
.gps-town-map .gps-tp-staticmap { display: block; line-height: 0; }
.gps-town-map .gps-tp-staticmap img { display: block; width: 100%; height: auto; max-height: 380px; object-fit: cover; border: 0; border-radius: 0; box-shadow: none; }
#primary.gps-tp .gps-town-practices .gps-tp-dist{display:block;margin-top:.35rem;font-size:.875rem;line-height:1.45;color:#5a6476}
/* Task 58: 'What we compound' pictures (img/sections thumbs); icon items get the same slot. */
.gps-tp-thumb{flex:0 0 96px;width:96px;height:64px;border-radius:10px;overflow:hidden;box-shadow:0 4px 12px rgba(1,78,108,.12)}
.gps-tp-thumb img{display:block;width:100%;height:100%;object-fit:cover;border-radius:0;box-shadow:none;margin:0}
.gps-tp-thumb--ico{background:#eaf2fa;display:flex;align-items:center;justify-content:center;box-shadow:none}
.gps-tp-thumb--ico .gps-tp-ico{box-shadow:none;background:transparent}
#primary.gps-tp .gps-tp-sec > ul.gps-tp-iconlist--photo{gap:1rem 1.5rem}
#primary.gps-tp .gps-tp-sec > ul.gps-tp-iconlist--photo>li>div{padding-top:0}
@media (min-width:768px){.gps-tp-thumb{flex-basis:120px;width:120px;height:80px}}
