/* Palma Cleaning: light improvement layer, 2026-10-14.
   Loaded after the site's own stylesheet on every page (improve.py adds the link).
   Same colours, font and layout family as the site; this only tightens readability,
   contrast, spacing and tap targets, and styles the few sections improve.py adds. */

:root {
  --pi-green: #305048;
  --pi-green-dark: #26403a;
  --pi-coral: #FF8057;
  --pi-coral-text: #BC4925; /* the brand coral, deepened only where it is small text on a light background */
  --pi-mist: #F4F7F6;
  --pi-line: #E3EAE8;
  --pi-ink: #374151;
}

/* 1. Long paragraphs that sat centred under a heading read left-aligned, in a comfortable measure. */
.pi-prose { text-align: left; max-width: 68ch; margin-left: auto; margin-right: auto; }
.pi-prose + .pi-prose { margin-top: 1rem; }

/* 2. Card rows whose last row was short (two cards stranded on the left): centre the last row. */
.pi-center-grid { display: flex !important; flex-wrap: wrap; justify-content: center; }
.pi-center-grid > * { flex: 1 1 100%; }
@media (min-width: 768px) { .pi-center-grid > * { flex: 0 1 calc(50% - .75rem); } }
@media (min-width: 1024px) { .pi-center-grid > * { flex: 0 1 calc(33.333% - 1rem); } }

/* 3. Small coral text on white or light-grey sections was hard to read (2.3 to 2.5 contrast).
      improve.py marks exactly those labels and links with pi-ct; they get the same coral, a shade
      deeper. Buttons, icons and coral on the green stay as they were. Hover colours still apply. */
.pi-ct { color: var(--pi-coral-text); }
/* light grey helper text on the light-grey sections */
.bg-\[\#F4F7F6\] .text-gray-500 { color: #5b6370; }
/* footer text a touch brighter on the green */
footer .text-white\/70 { color: rgba(255, 255, 255, .8); }
footer .text-white\/60 { color: rgba(255, 255, 255, .74); }

/* 4. Tap targets on phones: footer links and the small text links get room around them. */
@media (max-width: 767px) {
  footer ul a { display: inline-block; padding: .4rem 0; }
  footer ul.space-y-2 > :not([hidden]) ~ :not([hidden]) { margin-top: .1rem; }
  footer .flex.space-x-4 > a { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; }
  footer .flex.space-x-4 > :not([hidden]) ~ :not([hidden]) { margin-left: .25rem; }
  nav[aria-label="Breadcrumb"] a, .text-gray-500 > a { display: inline-block; padding: .55rem 0; }
}

/* 5. Keyboard focus is visible everywhere. */
a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible,
select:focus-visible, textarea:focus-visible { outline: 3px solid var(--pi-coral); outline-offset: 2px; border-radius: 4px; }

/* 6. Section rhythm on phones: the tallest section padding is trimmed so a phone screen shows content, not air. */
@media (max-width: 639px) {
  main section.py-24 { padding-top: 4rem; padding-bottom: 4rem; }
  main section.py-20 { padding-top: 3.5rem; padding-bottom: 3.5rem; }
}

/* 7. Sections improve.py adds. */
.pi-section { padding: 4.5rem 0; }
@media (max-width: 639px) { .pi-section { padding: 3.5rem 0; } }
.pi-section.pi-mist { background: var(--pi-mist); }
.pi-section.pi-white { background: #fff; }
.pi-head { max-width: 48rem; margin: 0 auto 2.5rem; text-align: center; }
.pi-eyebrow { font-size: .875rem; font-weight: 600; text-transform: uppercase; letter-spacing: .3em; color: var(--pi-coral-text); }
.pi-h2 { font-size: 1.875rem; line-height: 2.25rem; font-weight: 700; color: var(--pi-green); margin-top: .5rem; }
@media (min-width: 768px) { .pi-h2 { font-size: 2.25rem; line-height: 2.5rem; } }
.pi-lead { margin-top: 1rem; color: #4b5563; font-size: 1.0625rem; line-height: 1.7; }
.pi-cards { display: grid; grid-template-columns: 1fr; gap: 1.5rem; max-width: 72rem; margin: 0 auto; }
@media (min-width: 768px) { .pi-cards { grid-template-columns: repeat(3, 1fr); } .pi-cards.pi-two { grid-template-columns: repeat(2, 1fr); } .pi-cards.pi-four { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1200px) { .pi-cards.pi-four { grid-template-columns: repeat(4, 1fr); } }
.pi-card { background: #fff; border: 1px solid var(--pi-line); border-radius: 1rem; padding: 1.75rem; box-shadow: 0 6px 18px rgba(48, 80, 72, .06); }
.pi-mist .pi-card { background: #fff; }
.pi-white .pi-card { background: var(--pi-mist); box-shadow: none; }
.pi-num { display: inline-flex; align-items: center; justify-content: center; width: 2.5rem; height: 2.5rem; border-radius: 9999px; background: var(--pi-coral); color: var(--pi-green); font-weight: 700; margin-bottom: 1rem; }
.pi-card h3 { font-size: 1.15rem; font-weight: 600; color: var(--pi-green); line-height: 1.4; }
.pi-card p { margin-top: .6rem; color: var(--pi-ink); font-size: .95rem; line-height: 1.7; }
.pi-card a, .pi-lead a, .pi-faq a { color: var(--pi-green); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.pi-card a:hover, .pi-lead a:hover, .pi-faq a:hover { color: var(--pi-coral-text); }
.pi-links { max-width: 72rem; margin: 2.5rem auto 0; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: .75rem; }
.pi-links span { font-weight: 600; color: var(--pi-green); margin-right: .25rem; }
.pi-links a { display: inline-flex; align-items: center; min-height: 44px; padding: .5rem 1.1rem; border-radius: 9999px; background: #fff; border: 1px solid var(--pi-line); color: var(--pi-green); font-weight: 600; font-size: .9rem; transition: border-color .2s, color .2s; }
.pi-white .pi-links a { background: var(--pi-mist); }
.pi-links a:hover { border-color: var(--pi-coral); color: var(--pi-coral-text); }
.pi-faq { max-width: 52rem; margin: 0 auto; display: grid; gap: 1rem; }
.pi-faq details { background: #fff; border: 1px solid var(--pi-line); border-radius: .9rem; padding: 0 1.4rem; }
.pi-white .pi-faq details { background: var(--pi-mist); }
.pi-faq summary { cursor: pointer; list-style: none; padding: 1.1rem 2rem 1.1rem 0; font-weight: 600; color: var(--pi-green); position: relative; min-height: 44px; }
.pi-faq summary::-webkit-details-marker { display: none; }
.pi-faq summary::after { content: "+"; position: absolute; right: 0; top: .9rem; font-size: 1.4rem; color: var(--pi-coral-text); line-height: 1; }
.pi-faq details[open] summary::after { content: "\2212"; }
.pi-faq details p { padding: 0 0 1.2rem; color: var(--pi-ink); line-height: 1.7; }
.pi-note { max-width: 52rem; margin: 2rem auto 0; text-align: center; color: #4b5563; font-size: .95rem; }
.pi-faq-title { max-width: 52rem; margin: 2.75rem auto 1rem; font-size: 1.25rem; font-weight: 700; color: var(--pi-green); text-align: center; }
