/* Service / service-detail / region pages — photo-first, mobile re-flow (320px+) */
html, body { max-width: 100%; overflow-x: clip; }
.pg, .pg * , .pg-cta, .pg-cta * { min-width: 0; }
.pg img, .pg-cta img { max-width: 100%; height: auto; }
.pg p, .pg li, .pg h1, .pg h2, .pg h3, .pg a, .pg span, .pg td, .pg th, .pg summary,
.pg-related h3, .faq-item h3, .faq-item p, .pg-cta h2, .pg-cta p { overflow-wrap: anywhere; word-break: keep-all; }
.pg-sec { padding: 56px 0; }
.pg-wrap { max-width: 920px; }
.pg-sec .section-head { margin-bottom: 28px; }
.pg-sec .section-head h2 { font-size: 1.6rem; line-height: 1.35; }
.pg-h2 { font-size: 1.4rem; line-height: 1.35; margin: 0 0 20px; text-align: center; }
.pg-intro { font-size: 1.1rem; line-height: 1.8; margin: 0; text-align: center; color: var(--gray-800); }
.pg-text p { margin: 0 0 16px; line-height: 1.85; }
.pg-text p:last-child { margin-bottom: 0; }
.pg-note { font-size: .85rem; color: var(--gray-600); margin: 12px 0 0; }
.pg-extra + .pg-extra { margin-top: 44px; }

/* photos: square, same size inside a group */
.pg-photos { display: grid; gap: 14px; grid-template-columns: repeat(2, 1fr); }
.pg-fig { margin: 0; border-radius: 12px; overflow: hidden; border: 1px solid var(--gray-200); background: #fff; }
.pg-fig img { width: 100%; aspect-ratio: 1 / 1; height: auto; object-fit: cover; }
.pg-fig figcaption { padding: 10px 12px; font-size: .88rem; line-height: 1.5; color: var(--gray-600); }

/* cards: no fixed heights, no clamping */
.pg-cards { gap: 16px; }
.pg-card { text-align: left; padding: 20px 18px; }
.pg-card .icon { font-size: 1.8rem; margin-bottom: 8px; }
.pg-point { border-left: 4px solid var(--accent); background: var(--gray-50); border-radius: 0 12px 12px 0; padding: 18px 20px; }
.pg-point strong { color: var(--accent); letter-spacing: .04em; font-size: .85rem; }
.pg-point p { margin: 6px 0 0; line-height: 1.75; }

/* steps */
.pg-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; counter-reset: none; }
.pg-steps li { display: flex; gap: 14px; align-items: flex-start; background: #fff; border: 1px solid var(--gray-200); border-radius: 12px; padding: 16px 18px; }
.pg-step-num { flex: 0 0 auto; width: 38px; height: 38px; border-radius: 50%; background: var(--primary); color: #fff; font-weight: 700; font-size: .9rem; display: flex; align-items: center; justify-content: center; }
.pg-steps p { margin: 0; line-height: 1.75; flex: 1 1 0; }

/* checklists */
.pg-checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; grid-template-columns: 1fr 1fr; }
.pg-checks li { background: #fff; border: 1px solid var(--gray-200); border-radius: 12px; padding: 14px 16px 14px 44px; position: relative; line-height: 1.6; }
.pg-checks li::before { content: "\2713"; position: absolute; left: 16px; top: 14px; color: var(--accent); font-weight: 800; }
.pg-checks li strong { display: block; margin-bottom: 4px; }
.pg-checks li span { color: var(--gray-600); font-size: .92rem; }

/* tables */
.table-wrap { width: 100%; }
.pg-table { table-layout: auto; }
.pg-table th, .pg-table td { overflow-wrap: anywhere; word-break: keep-all; vertical-align: top; }

/* related */
.pg-related { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.pg-related .service-item { padding: 18px 14px; display: block; }
.pg-related .service-item h3 { font-size: .98rem; margin: 0; }
.pg-related .service-item .icon { font-size: 1.6rem; margin-bottom: 6px; }

/* CTA */
.pg-cta-btns { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.pg-cta-btns .btn { min-height: 48px; max-width: 100%; white-space: normal; text-align: center; line-height: 1.4; }

/* timeline / compare / accordion from page data */
.timeline { max-width: 100%; }
.accordion-item summary { padding-right: 24px; }

@media (max-width: 900px) {
  .pg-checks { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .pg-sec { padding: 40px 0; }
  .pg-sec .section-head h2, .pg-h2 { font-size: 1.3rem; }
  .pg-intro { font-size: 1.02rem; text-align: left; }
  .pg-photos { gap: 10px; }
  .pg-fig figcaption { font-size: .8rem; padding: 8px 10px; }
  .pg .hero h1, .hero-content h1 { overflow-wrap: anywhere; word-break: keep-all; }
  .pg-cta-btns .btn { width: 100%; }
  /* wide tables -> stacked cards (no sideways scroll) */
  .pg-table, .pg-table tbody, .pg-table tr, .pg-table td { display: block; width: 100%; }
  .pg-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .pg-table { border: 0; background: transparent; }
  .pg-table tr { background: #fff; border: 1px solid var(--gray-200); border-radius: 12px; margin-bottom: 12px; padding: 6px 0; }
  .pg-table td { border: 0; padding: 8px 14px; font-size: .92rem; }
  .pg-table td::before { content: attr(data-label); display: block; font-size: .78rem; font-weight: 700; color: var(--accent); margin-bottom: 2px; }
  .timeline { padding-left: 24px; }
  .timeline-num { left: -37px; }
}
/* very small phones: photos one per row so subjects stay recognisable */
@media (max-width: 349px) {
  .pg-photos { grid-template-columns: 1fr; }
  .container { padding: 0 16px; }
}

/* photos must be visible on the first screen: compact hero, tight intro, photo grid right under it */
.hero.hero-compact { min-height: 0; }
.hero-compact .hero-content { padding: 44px 20px 36px; }
.hero-compact .hero-content h1 { font-size: 2.1rem; margin-bottom: 10px; }
.hero-compact .hero-content p { font-size: 1rem; margin-bottom: 16px; }
.hero-compact .hero-scroll-hint { display: none; }
.pg > .pg-sec:first-child { padding: 24px 0 8px; }
.pg > .pg-sec:nth-child(2) { padding-top: 12px; }
.pg > .pg-sec:nth-child(2) .section-head { margin-bottom: 16px; }
.pg > .pg-sec:nth-child(2) .section-head h2 { font-size: 1.35rem; margin: 4px 0 0; }
.pg > .pg-sec:nth-child(2) .section-head p { display: none; }
.pg-photos-4 { max-width: 780px; margin: 0 auto; }
.breadcrumb.container { padding: 8px 20px 0; font-size: .85rem; }
@media (max-width: 640px) {
  .hero-compact .hero-content { padding: 28px 16px 22px; }
  .hero-compact .hero-content h1 { font-size: 1.55rem; }
  .hero-compact .hero-content p { font-size: .95rem; margin-bottom: 12px; }
  .hero-compact .hero-badge { margin-bottom: 10px; }
  .pg > .pg-sec:first-child { padding: 16px 0 4px; }
  .pg-intro { font-size: .98rem; line-height: 1.7; }
}
