/* ========================================
   rsa-leinster — Westmeath body design (Phase 7e)

   Westmeath GAA jersey: maroon and white. Two colours, like Louth, but
   the design intent is to look CLEARLY different from both Carlow's
   tri-colour treatment AND Louth's solid red treatment.

   Westmeath axis: midlands lakes county. Mullingar sits between Lough
   Owel and Lough Ennell. Athlone sits on the Shannon. The design picks
   up the water + bridge motif: lake-silhouette SVG in the test centre
   block, slash separators in the hero stats, two-stack section
   underlines suggesting a lake reflection.

   Differentiation from prior hubs (4+ axes vs both Carlow AND Louth):
   - Top banner: maroon bar with notched right corner (triangular cut)
     (Carlow tri-band, Louth solid red + hairline)
   - Hero layout: left-aligned, no side card, large stats with slash
     separators (Carlow 2-col + side card, Louth stacked centred)
   - Card accent: bottom maroon border (Carlow left, Louth top)
   - Section underline: two-stack pills (Carlow tri-band, Louth solid bar)
   - Town grid: 5 columns desktop, clustered by sub-region (Carlow 3,
     Louth 4, both flat alphabetical)
   - Test centre SVG: twin lake silhouettes (Carlow three roundabouts,
     Louth has 2-card comparison)
   - Price display: after-hero band with pipe `|` dividers between cells
   - Hero stat divider: slash `/` characters
   ======================================== */

/* --- Westmeath accent palette (GAA maroon + white) --- */
body[data-county="westmeath"] {
  --accent:      #7A1F2D;  /* maroon, primary */
  --accent-fg:   #FFFFFF;
  --accent-2:    #F5F5F4;  /* near-white, secondary */
  --accent-2-fg: #1A1A1A;
  /* --accent-3 inherits --brand (deep blue) for two-colour county */
}

/* --- Top banner: maroon bar with notched right corner --- */
.cn-ribbon {
  display: block;
  height: 10px;
  width: 100%;
  margin-top: 130px;
  background: var(--accent);
  position: relative;
}
.cn-ribbon::before {
  /* notch on the right edge: triangular cut */
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 60px;
  background: var(--bg-deep);
  clip-path: polygon(100% 0, 100% 100%, 0 100%);
}
.cn-ribbon::after {
  /* hairline below the bar in the deep brand */
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 60px;
  height: 1px;
  background: rgba(122, 31, 45, 0.45);
}
.cn-ribbon span { display: none; }

/* --- Hero (left-aligned, single column, no side card) --- */
.cn-hero {
  position: relative;
  padding: 4rem 0 3rem;
  background:
    radial-gradient(1200px 500px at 0% -10%, rgba(122, 31, 45, 0.10), transparent 60%),
    radial-gradient(800px 400px at 100% 90%, rgba(245, 245, 244, 0.05), transparent 60%),
    var(--bg-deep);
  overflow: hidden;
}
.cn-hero-grid {
  display: block;
  max-width: 880px;
  margin: 0;
  padding: 0;
  text-align: left;
}
.cn-hero-eyebrow {
  display: inline-flex;
  gap: 0.5em;
  align-items: center;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}
.cn-hero-eyebrow::before {
  content: "";
  display: inline-block;
  width: 32px;
  height: 8px;
  background: linear-gradient(to right, var(--accent) 0 50%, var(--accent-2) 50% 100%);
  border-radius: 1px;
}
.cn-hero h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.4rem, 5.2vw, 4.2rem);
  line-height: 1.05;
  letter-spacing: -0.025em;
  color: var(--text-primary);
  margin-bottom: 1.25rem;
  max-width: 14ch;
}
.cn-hero h1 em {
  font-style: normal;
  color: var(--accent);
}
.cn-hero-sub {
  font-size: 1.18rem;
  line-height: 1.55;
  color: var(--text-secondary);
  max-width: 56ch;
  margin: 0 0 1rem;
}
.cn-hero-meta {
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text-muted);
  max-width: 56ch;
  margin: 0 0 2rem;
  letter-spacing: 0.01em;
}

/* Hero stats inline horizontal with slash `/` separators */
.cn-hero-stats {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin: 0 0 2.25rem;
  padding: 1.25rem 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}
.cn-hero-stats > div {
  flex: 0 1 auto;
  padding: 0 1.5rem 0 0;
  margin-right: 1.5rem;
  position: relative;
}
.cn-hero-stats > div + div {
  padding-left: 0;
}
.cn-hero-stats > div + div::before {
  content: "/";
  position: absolute;
  left: -1.6rem;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--accent);
  opacity: 0.55;
}
.cn-stat-value {
  display: block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.85rem;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  line-height: 1.05;
}
.cn-stat-value em { font-style: normal; color: var(--accent); }
.cn-stat-label {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}
.cn-stat-label small { color: var(--text-muted); opacity: 0.85; }

.cn-hero-ctas { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.cn-hero-ctas .btn-primary {
  background: var(--accent);
  color: var(--accent-fg);
  border-color: var(--accent);
}
.cn-hero-ctas .btn-primary:hover { background: #5e1822; border-color: #5e1822; }
.cn-hero-ctas .btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-medium);
}

/* --- Quick price strip (after-hero, pipe-separated cells, uppercase labels) --- */
.cn-quick-strip {
  background: var(--bg-elevated);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  padding: 1.25rem 0;
  position: relative;
}
.cn-quick-strip-inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem 0;
}
.cn-quick-strip h2 {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent);
  margin: 0 1.5rem 0 0;
  padding: 0;
}
.cn-quick-strip-cell {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0 1.25rem;
  border-left: 1px solid var(--border-subtle);
}
.cn-quick-strip-cell:first-of-type { border-left: none; padding-left: 0; }
.cn-quick-strip-cell span {
  font-size: 0.7rem;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
}
.cn-quick-strip-cell strong {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
}
.cn-quick-strip-cta { margin-left: auto; }
.cn-quick-strip-cta .btn-primary {
  background: var(--accent);
  color: var(--accent-fg);
  border-color: var(--accent);
}
.cn-quick-strip-cta .btn-primary:hover { background: #5e1822; border-color: #5e1822; }

/* --- Trust band (Westmeath: white-edged left + maroon stat values) --- */
.cn-trust {
  background: var(--bg-surface);
  padding: 1.4rem 0;
  position: relative;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}
.cn-trust-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  text-align: center;
}
.cn-trust-cell {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0 0.5rem;
  border-right: 1px dashed var(--border-subtle);
}
.cn-trust-cell:last-child { border-right: none; }
.cn-trust-cell strong {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--accent);
}
.cn-trust-cell span { font-size: 0.78rem; color: var(--text-muted); letter-spacing: 0.02em; }
.cn-trust-note {
  margin-top: 0.9rem;
  font-size: 0.72rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.45;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

/* --- Section headers (Westmeath: two-stack pill underlines) --- */
.cn-section-header { margin-bottom: 2.5rem; }
.cn-section-eyebrow {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}
.cn-section-header h2 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  position: relative;
  padding-bottom: 1.1rem;
}
.cn-section-header h2::before {
  content: "";
  position: absolute;
  bottom: 0; left: 0;
  width: 70px; height: 4px;
  background: var(--accent);
  border-radius: 4px;
}
.cn-section-header h2::after {
  content: "";
  position: absolute;
  bottom: -2px; left: 18px;
  width: 38px; height: 4px;
  background: var(--accent-2);
  border: 1px solid var(--accent);
  border-radius: 4px;
}

/* --- Two-column intro prose --- */
.cn-intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}
.cn-intro-grid p { font-size: 1.05rem; line-height: 1.65; color: var(--text-secondary); }
.cn-intro-grid p + p { margin-top: 1rem; }

/* --- Test centre approach: SVG (twin lakes) + prose --- */
.cn-approach {
  display: grid;
  grid-template-columns: 1.1fr 1.4fr;
  gap: 2.5rem;
  align-items: center;
}
.cn-approach-svg {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-bottom: 3px solid var(--accent);
  border-radius: 6px;
  padding: 2rem;
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cn-approach-svg svg { width: 100%; height: auto; max-width: 320px; }
.cn-approach-prose h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}
.cn-approach-prose p { color: var(--text-secondary); line-height: 1.65; }
.cn-approach-prose p + p { margin-top: 0.75rem; }

/* --- Triplet card grid (Westmeath: BOTTOM maroon border) --- */
.cn-triplet {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
}
.cn-triplet-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-bottom: 3px solid var(--accent);
  border-radius: 4px;
  padding: 1.5rem;
  position: relative;
  transition: transform 0.18s ease, border-bottom-width 0.18s ease;
}
.cn-triplet-card:hover {
  transform: translateY(-2px);
  border-bottom-width: 5px;
}
.cn-triplet-card h4 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}
.cn-triplet-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.55;
}

/* --- Town grid: 5 cols, clustered by region --- */
.cn-town-cluster + .cn-town-cluster { margin-top: 2.5rem; }
.cn-town-cluster-h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 0.4rem;
  position: relative;
  padding-left: 1rem;
}
.cn-town-cluster-h3::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 14px;
  background: var(--accent);
  border-radius: 2px;
}
.cn-town-cluster-intro {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 1rem;
  max-width: 70ch;
}
.cn-town-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.75rem;
}
.cn-town-card {
  display: block;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-bottom: 2px solid transparent;
  border-radius: 4px;
  padding: 0.9rem 1rem;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.18s ease, transform 0.18s ease, background 0.18s ease;
}
.cn-town-card:hover {
  border-color: var(--accent);
  border-bottom-color: var(--accent);
  background: var(--bg-elevated);
  transform: translateY(-2px);
}
.cn-town-card h4 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}
.cn-town-card p {
  font-size: 0.78rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
}
.cn-town-card-meta {
  display: block;
  margin-top: 0.45rem;
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
}

/* --- FAQ (Westmeath: bottom-border accent on open, no left/top accent) --- */
.cn-faq { max-width: 760px; margin: 0 auto; }
.cn-faq details {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-bottom: 2px solid transparent;
  border-radius: 4px;
  padding: 1rem 1.25rem;
  margin-bottom: 0.6rem;
  transition: border-bottom-color 0.2s ease;
}
.cn-faq details[open] { border-bottom-color: var(--accent); }
.cn-faq summary {
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-primary);
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.cn-faq summary::-webkit-details-marker { display: none; }
.cn-faq summary::after {
  content: "+";
  color: var(--accent);
  font-size: 1.4rem;
  font-weight: 700;
  transition: transform 0.2s ease;
}
.cn-faq details[open] summary::after { content: "−"; }
.cn-faq details p {
  margin-top: 0.75rem;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* --- Closing CTA (Westmeath: bottom maroon border + offset accent strip) --- */
.cn-final-cta {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-bottom: 4px solid var(--accent);
  border-radius: 4px;
  padding: 2.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cn-final-cta::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 24px;
  width: 80px;
  height: 4px;
  background: var(--accent-2);
  border: 1px solid var(--accent);
  border-radius: 4px;
}
.cn-final-cta h2 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}
.cn-final-cta p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
  max-width: 56ch;
  margin-left: auto;
  margin-right: auto;
}
.cn-final-cta .cn-cta-row { display: flex; justify-content: center; gap: 0.75rem; flex-wrap: wrap; }
.cn-final-cta .btn-primary {
  background: var(--accent);
  color: var(--accent-fg);
  border-color: var(--accent);
}
.cn-final-cta .btn-primary:hover { background: #5e1822; border-color: #5e1822; }
.cn-final-cta .cn-tell-once {
  display: block;
  margin-top: 1.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  font-style: italic;
}

/* --- Per-section accent links --- */
body[data-county="westmeath"] a { color: var(--accent); }
body[data-county="westmeath"] a:hover { color: var(--text-primary); }
body[data-county="westmeath"] .nav-links a { color: var(--text-secondary); }
body[data-county="westmeath"] .nav-links a:hover { color: var(--text-primary); }
body[data-county="westmeath"] .nav-phone,
body[data-county="westmeath"] .nav-cta { color: #fff; background: var(--brand); }
body[data-county="westmeath"] .nav-phone:hover,
body[data-county="westmeath"] .nav-cta:hover { background: var(--accent-red-bright); }
body[data-county="westmeath"] footer a { color: var(--text-secondary); }
body[data-county="westmeath"] footer a:hover { color: var(--accent); }

/* --- Responsive --- */
@media (max-width: 1100px) {
  .cn-quick-strip-inner { gap: 1rem 0.75rem; }
  .cn-quick-strip h2 { width: 100%; margin-right: 0; padding-bottom: 0.5rem; border-bottom: 1px solid var(--border-subtle); margin-bottom: 0.5rem; }
  .cn-quick-strip-cta { margin-left: 0; width: 100%; padding-top: 0.5rem; }
  .cn-town-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .cn-intro-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .cn-approach { grid-template-columns: 1fr; }
  .cn-triplet { grid-template-columns: 1fr; }
  .cn-town-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cn-trust-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
  .cn-trust-cell:nth-child(2n) { border-right: none; }
}
@media (max-width: 640px) {
  .cn-town-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cn-hero-stats { flex-wrap: wrap; gap: 1rem 0; }
  .cn-hero-stats > div { padding-right: 1rem; margin-right: 1rem; }
  .cn-hero-stats > div + div::before { display: none; }
  .cn-quick-strip-cell { padding: 0 0.75rem; }
}
@media (max-width: 420px) {
  .cn-town-grid { grid-template-columns: 1fr; }
}
