/* Content UI (inc/content-ui.php): the Poison Control Centre page's layouts
   for the text-heavy pages. Loaded on those pages only. Card backgrounds are
   the theme's existing gradients (classes on the elements):
     Clinical Toxicology / About mission card  157.82deg #E5F5F5 -> #5796DC
     service card / header dropdown            360deg #A6E7E6 -> aqua fade   */

.cui { --cui-line: var(--color-primary-a50); --cui-dash: repeating-linear-gradient(90deg, var(--color-primary) 0 6px, transparent 6px 12px); }
.cui-wrap { max-width: 1400px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.cui-section { padding-top: 64px; padding-bottom: 64px; }
.cui-section--flush { padding-bottom: 0; }
.cui p { line-height: 1.7; }
.cui-text, .cui-head p, .cui-intro__text p, .cui-card p, .cui-note, .cui-callout p { color: var(--color-body); }
.cui-head { max-width: 900px; margin-bottom: 32px; }
.cui-head p, .cui-intro__text p { font-size: 1.05rem; }
.cui-head p + p, .cui-intro__text p + p, .cui-callout p + p { margin-top: 16px; }
.cui-sub { margin: 40px 0 20px; font-size: 1.35rem; font-weight: 600; color: var(--color-heading); }
.cui a:not([class]) { color: var(--color-brand); text-decoration: underline; }

/* Lead: the opening paragraph, larger, in heading colour. */
.cui-lead { font-size: clamp(1.15rem, 1rem + .5vw, 1.45rem) !important; line-height: 1.6 !important; color: var(--color-heading) !important; font-weight: 500; }

/* Phone numbers: the Poison Control Centre helpline style. */
.cui-phone { display: inline-block; font-size: clamp(1.4rem, 1.15rem + .8vw, 1.85rem); font-weight: 600; white-space: nowrap; color: var(--color-brand); }

/* Intro: text beside a Clinical Toxicology card (the About + helpline row). */
.cui-intro { display: grid; gap: 40px; align-items: start; }
@media (min-width: 1024px) { .cui-intro { grid-template-columns: minmax(0, 1fr) 400px; gap: 64px; } }
.cui-intro--solo { grid-template-columns: minmax(0, 1fr); max-width: 900px; }
.cui-aside { display: flex; flex-direction: column; gap: 18px; }
.cui-aside h3 { font-size: 1.3rem; font-weight: 600; color: var(--color-brand); line-height: 1.3; }
.cui-aside p, .cui-aside li { color: var(--color-heading); line-height: 1.6; }
.cui-aside ul { display: grid; gap: 12px; }
.cui-aside li { display: flex; gap: 12px; align-items: flex-start; }

/* Small square icon tiles (the contact card's location/phone icons). */
.cui-ic { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: rgba(3, 187, 185, .12); border: 1px solid rgba(3, 187, 185, .25); }
.cui-ic--brand { background: var(--color-brand); border-color: var(--color-brand); }
.cui-ic--sm { width: 32px; height: 32px; border-radius: 10px; }
.cui-ic img { width: 24px; height: 24px; object-fit: contain; }

/* Cards: the Poison Control Centre service cards. */
.cui-cards { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .cui-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .cui-cards--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* Five cards: two across the first row, three in the second (as on the Poison page). */
@media (min-width: 1100px) {
  .cui-cards--5 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .cui-cards--5 > * { grid-column: span 2; }
  .cui-cards--5 > :nth-child(-n+2) { grid-column: span 3; }
}
@media (min-width: 640px) and (max-width: 1099px) { .cui-cards--5 > :last-child:nth-child(odd) { grid-column: span 2; } }
.cui-card { display: flex; flex-direction: column; justify-content: space-between; gap: 32px; padding: 28px; border-radius: 24px; border: 1px solid var(--color-border-subtle); }
.cui-card__icon { width: 48px; height: 48px; object-fit: contain; }
.cui-card h3 { font-size: 1.15rem; font-weight: 600; color: var(--color-brand); line-height: 1.35; margin-bottom: 8px; }
.cui-card p { font-size: .975rem; }
.cui-card p + p { margin-top: 10px; }
.cui-card--text p { font-size: 1rem; color: var(--color-heading); }

/* Facts inside a card (a table row): label above value. */
.cui-facts { display: grid; gap: 14px; margin-top: 4px; }
.cui-facts--row { grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }
.cui-fact dt { font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--color-muted-dark); margin-bottom: 4px; }
.cui-fact dd { font-size: 1rem; font-weight: 500; color: var(--color-heading); line-height: 1.45; }
.cui-fact--big dd { font-size: 1.75rem; font-weight: 600; color: var(--color-brand); line-height: 1.1; }

/* Tiles: the About Us mission cards in a grid (Poison "Clinical Toxicology"). */
.cui-tiles { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .cui-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .cui-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } .cui-tiles--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.cui-tile { display: flex; flex-direction: column; gap: 32px; min-height: 13rem; padding: 32px; border-radius: 34px; }
.cui-tile img { width: 48px; }
.cui-tile h3, .cui-tile p { margin-top: auto; }
.cui-tile h3 { font-size: 1.125rem; font-weight: 600; color: var(--color-brand); line-height: 1.35; }
.cui-tile p { font-size: 1rem; color: var(--color-heading); line-height: 1.55; }
/* Tiles without an icon (tiles.php 'icon' => false): text centred, shorter. */
.cui-tile--plain { min-height: 0; justify-content: center; }
.cui-tile--plain h3, .cui-tile--plain p { margin-top: 0; }

/* Pills: plain fully rounded labels (the Poison network pills) in a grid. */
.cui-pills { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.cui-pill { display: flex; align-items: center; min-height: 56px; padding: 10px 24px; border-radius: 999px; border: 1px solid var(--color-border-subtle); font-weight: 500; line-height: 1.3; color: var(--color-brand); }

/* Note: a single closing line, in a soft card. */
.cui-note { display: flex; gap: 14px; align-items: flex-start; max-width: 900px; margin-top: 28px; padding: 18px 22px; border-radius: 20px; border: 1px solid var(--color-border-mid); font-size: 1rem; line-height: 1.6; }
.cui-note--plain { padding: 0; border: 0; border-radius: 0; background: none; }

/* Callout: a whole short section in a Clinical Toxicology card. */
.cui-callout { display: flex; flex-direction: column; gap: 16px; padding: 40px; border-radius: 34px; }
.cui-callout h2 { color: var(--color-brand); }
.cui-callout__links { display: flex; flex-wrap: wrap; gap: 8px 28px; }
.cui-callouts { display: grid; gap: 20px; }
@media (min-width: 900px) { .cui-callouts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.cui-callouts .cui-callout h3 { font-size: 1.3rem; font-weight: 600; color: var(--color-brand); line-height: 1.3; }

/* Flow: steps hanging off one line (the Poison network, phone layout). */
.cui-flow { position: relative; display: flex; flex-direction: column; gap: 14px; max-width: 1000px; padding-left: 60px; }
.cui-flow__item { position: relative; padding: 20px 26px; border-radius: 24px; border: 1px solid var(--color-border-subtle); color: var(--color-heading); line-height: 1.6; }
.cui-flow__item::before, .cui-flow__item::after { content: ''; position: absolute; pointer-events: none; }
/* The line: each item draws it from the gap above down to its middle, plus its branch. */
.cui-flow__item::before { left: -35px; top: -15px; bottom: 0; width: 2px; background: var(--cui-line); }
.cui-flow__item:first-child::before { top: 50%; }
.cui-flow__item:last-child::before { bottom: auto; height: calc(50% + 15px); }
.cui-flow__item:first-child:last-child::before { display: none; }
.cui-flow__item::after { left: -35px; top: 50%; width: 34px; height: 2px; margin-top: -1px; background: var(--cui-dash); }

/* Network: a hub with items branching off it (the Poison "Key areas"). */
.cui-net { position: relative; }
.cui-net__side { display: flex; flex-direction: column; gap: 14px; }
.cui-net__item { position: relative; display: flex; align-items: center; min-height: 64px; padding: 10px 28px; border-radius: 999px; border: 1px solid var(--color-border-subtle); font-weight: 500; line-height: 1.3; color: var(--color-brand); }
.cui-net__item::before, .cui-net__item::after, .cui-net__side::after { content: ''; position: absolute; pointer-events: none; }
.cui-net__hub { position: relative; display: grid; place-items: center; }
.cui-net__core { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 8px; }
.cui-net__icon { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 10px; border: 2px solid var(--color-brand-pale); background: var(--color-brand); }
.cui-net__icon svg { width: 18px; height: 18px; }
.cui-net__core h3 { font-size: 1.05rem; line-height: 1.3; }
@media (min-width: 1024px) {
  .cui-net { display: grid; grid-template-columns: minmax(0, 1fr) 220px minmax(0, 1fr); align-items: center; }
  .cui-net__hub { grid-column: 2; grid-row: 1; }
  .cui-net__side--left { grid-column: 1; grid-row: 1; padding-right: 56px; }
  .cui-net__side--right { grid-column: 3; grid-row: 1; padding-left: 56px; }
  .cui-net__side { position: relative; }
  .cui-net__item { min-height: 64px; }
  .cui-net__side--left::before, .cui-net__side--right::before { content: ''; position: absolute; top: 32px; bottom: 32px; width: 2px; background: var(--cui-line); }
  .cui-net__side--left::before { right: 27px; }
  .cui-net__side--right::before { left: 27px; }
  .cui-net__item::after, .cui-net__side::after { top: 50%; width: 28px; height: 2px; margin-top: -1px; background: var(--cui-dash); }
  .cui-net__side--left .cui-net__item::after { right: -29px; }
  .cui-net__side--right .cui-net__item::after { left: -29px; }
  .cui-net__side--left::after { right: 0; }
  .cui-net__side--right::after { left: 0; }
  .cui-net__core { align-items: center; justify-content: center; text-align: center; width: 220px; min-height: 136px; padding: 24px; border-radius: 28px; }

  .cui-net__core h3 { font-size: 1.15rem; }
}
@media (max-width: 1023px) {
  .cui-net__hub { justify-items: start; }
  .cui-net__core { align-items: flex-start; padding: 16px 24px; border-radius: 20px; text-align: left; }
  .cui-net__side { padding: 14px 0 0 60px; }
  .cui-net__item::before { left: -25px; top: -15px; bottom: 0; width: 2px; background: var(--cui-line); }
  .cui-net__side:last-child .cui-net__item:last-child::before { bottom: auto; height: calc(50% + 16px); }
  .cui-net__item::after { left: -25px; top: 50%; width: 24px; height: 2px; margin-top: -1px; background: var(--cui-dash); }
}


/* Phones */
@media (max-width: 639px) {
  .cui-section { padding-top: 48px; padding-bottom: 48px; }
  .cui-wrap p, .cui-wrap li, .cui .leading-relaxed { line-height: 1.5; }
  .cui-head p + p, .cui-intro__text p + p, .cui-callout p + p { margin-top: 12px; }
  .cui-card { padding: 22px; gap: 24px; border-radius: 22px; }
  .cui-tile { min-height: 0; padding: 22px; gap: 24px; border-radius: 24px; }
  .cui-tile img, .cui-card__icon { width: 38px; height: 38px; }
  .cui-callout { padding: 26px 20px; border-radius: 28px; }
  .cui-pills { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .cui-pill { min-height: 48px; padding: 8px 16px; font-size: .875rem; border-radius: 22px; }
  .cui-flow { padding-left: 34px; gap: 12px; }
  .cui-flow__item { padding: 16px 18px; border-radius: 20px; font-size: .9375rem; }
  .cui-flow__item::before, .cui-flow__item::after { left: -20px; }
  .cui-flow__item::after { width: 19px; }
  .cui-flow__item::before { top: -13px; }
  .cui-flow__item:last-child::before { height: calc(50% + 13px); }
  .cui-net__item { min-height: 52px; padding: 8px 20px; font-size: .9375rem; }
  .cui-net__side { gap: 12px; padding-top: 12px; padding-left: 34px; }
  .cui-net__item::before, .cui-net__item::after { left: -20px; }
  .cui-net__item::after { width: 19px; }
  .cui-net__item::before { top: -13px; }
  .cui-net__side:last-child .cui-net__item:last-child::before { height: calc(50% + 14px); }
  .cui-fact--big dd { font-size: 1.5rem; }
}

/* Blocks inside one page section (the editor-content renderer). */
.cui-block + .cui-block { margin-top: 72px; }
.cui-block > h2 { margin-bottom: 24px; }
.cui-block .cui-head + .cui-cards, .cui-block .cui-head + .cui-tiles, .cui-block .cui-head + .cui-pills { margin-top: 8px; }
.cui-stack > * + * { margin-top: 24px; }
@media (max-width: 639px) { .cui-block + .cui-block { margin-top: 52px; } }
/* A wider gap above a block (e.g. after the timeline). */
.cui-block + .cui-block--gap { margin-top: 128px; }
@media (max-width: 639px) { .cui-block + .cui-block--gap { margin-top: 88px; } }
@media (min-width: 1100px) { .cui-cards--4 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1280px) { .cui-cards--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
/* A card with much longer text spans two columns; the grid fills the gaps. */
.cui-cards { grid-auto-flow: row dense; }
@media (min-width: 640px) { .cui-card--wide { grid-column: span 2; } }
/* Phones: cards put the icon beside the text, so a stack of them stays short. */
@media (max-width: 639px) {
  .cui-card { flex-direction: row; justify-content: flex-start; align-items: flex-start; gap: 16px; padding: 18px; }
  .cui-card > div { flex: 1; min-width: 0; }
  .cui-card__icon { flex: none; width: 36px; height: 36px; }
  .cui-card h3 { font-size: 1.05rem; margin-bottom: 6px; }
  .cui-card p { font-size: .9375rem; }
}

/* Timeline (parts/components/content-ui/timeline.php): steps on a centre line,
   cards alternating sides, one after another (one column beside the line on
   phones). CSS only: the line fills and a dot travels down it as the page
   scrolls, lighting each step's dot as it reaches it, and on desktop each
   card slides out from beside the line to its side (scroll-driven
   animations). The "reach" point is 60% down the screen. Browsers without
   scroll-driven animations, and reduced motion, get the finished state: full
   line, every dot lit, cards in place. */
.cui-tl { --tl-x: 11px; --tl-mark: 12px; position: relative; max-width: 1200px; margin: 0 auto; view-timeline-name: --cui-tl; }
.cui-tl__list { position: relative; list-style: none; margin: 0; padding: 0; }
.cui-tl__rail { position: absolute; left: var(--tl-x); top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--color-brand-a20); }
.cui-tl__fill { position: absolute; left: 0; top: 0; width: 100%; height: 100%; background: var(--color-brand); }
.cui-tl__dot { display: none; position: absolute; left: 50%; top: 0; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; background: var(--color-brand); box-shadow: 0 0 0 4px var(--color-brand-a20); z-index: 2; }
.cui-tl__step { position: relative; padding-left: 40px; view-timeline-name: --cui-tl-step; }
.cui-tl__step + .cui-tl__step { margin-top: 24px; }
.cui-tl__mark { position: absolute; left: var(--tl-x); top: calc(var(--tl-mark) / -2); width: var(--tl-mark); height: var(--tl-mark); margin-left: calc(var(--tl-mark) / -2); border-radius: 50%; background: var(--color-brand); transform: scale(1.1667); z-index: 1; }
.cui-tl__card { padding: 26px; border-radius: 24px; }
.cui-tl__card p { font-size: .975rem; line-height: 1.6; color: var(--color-body); }

@media (min-width: 900px) {
  .cui-tl { --tl-x: 50%; }
  .cui-tl__step { width: 50%; padding-left: 0; }
  .cui-tl__step--right { margin-left: 50%; padding-left: 48px; }
  .cui-tl__step--left { padding-right: 48px; }
  .cui-tl__step--right .cui-tl__mark { left: 0; }
  .cui-tl__step--left .cui-tl__mark { left: 100%; }
  /* Cards at 75% of their side, centred in it. */
  .cui-tl__card { width: 75%; margin-left: auto; margin-right: auto; }
}
@media (max-width: 639px) {
  .cui-tl__card { padding: 18px; border-radius: 20px; }
  .cui-tl__card p { font-size: .9375rem; }
}

@keyframes cui-tl-fill { from { height: 0; } to { height: 100%; } }
@keyframes cui-tl-travel { from { top: 0; } to { top: 100%; } }
@keyframes cui-tl-light { from { opacity: .25; transform: none; } to { opacity: 1; transform: scale(1.1667); } }
@keyframes cui-tl-out-left { from { transform: translateX(16.667%); } to { transform: none; } }
@keyframes cui-tl-out-right { from { transform: translateX(-16.667%); } to { transform: none; } }

@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    /* The line: from its top reaching the 60% point to its bottom reaching it. */
    .cui-tl__fill, .cui-tl__dot { animation-timing-function: linear; animation-fill-mode: both; animation-timeline: --cui-tl; animation-range: cover 40vh cover calc(100% - 60vh); }
    .cui-tl__fill { animation-name: cui-tl-fill; }
    .cui-tl__dot { display: block; animation-name: cui-tl-travel; }
    /* A step's dot: faint at 12px, lit and 14px as the travelling dot reaches it. */
    .cui-tl__mark { animation: cui-tl-light linear both; animation-timeline: --cui-tl-step; animation-range: cover calc(40vh - 24px) cover 40vh; }
  }
  @media (prefers-reduced-motion: no-preference) and (min-width: 900px) {
    /* A card: beside the line, out at its side by the time the dot reaches it. */
    .cui-tl__card { animation-timing-function: linear; animation-fill-mode: both; animation-timeline: --cui-tl-step; animation-range: cover 15vh cover 40vh; }
    .cui-tl__step--left .cui-tl__card { animation-name: cui-tl-out-left; }
    .cui-tl__step--right .cui-tl__card { animation-name: cui-tl-out-right; }
  }
}

/* Tags (parts/components/content-ui/tags.php). */
.cui-tags { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.cui-tags li { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px 9px 12px; border-radius: 12px; background: rgba(3, 78, 163, .07); color: var(--color-brand); font-size: .9375rem; font-weight: 500; }
.cui-tags__icon { flex: none; width: 18px; height: 18px; }
.cui-tags__icon svg { width: 100%; height: 100%; }

/* Data tables (parts/components/content-ui/data-table.php): the PG Programme
   table design, scrolling sideways on narrow screens. */
.cui-dt { overflow-x: auto; border: 1px solid var(--color-border-subtle); border-radius: 12px; background: #fff; box-shadow: 0 1px 2px 0 #0A0D120D; }
.cui-dt table { width: 100%; min-width: 600px; border-collapse: collapse; margin: 0; }
.cui-dt thead { background: var(--color-surface); border-bottom: 1px solid var(--color-border-subtle); }
.cui-dt th { padding: 16px 24px; text-align: left; font-weight: 500; color: var(--color-body); }
.cui-dt td { padding: 24px; font-size: 1rem; color: var(--color-body); }
.cui-dt tbody tr + tr td { border-top: 1px solid var(--color-border-subtle); }
.cui-dt-note { max-width: 56rem; margin-top: 12px; color: var(--color-body); }

/* Call buttons (rich.php, 'phones' => 'buttons'). */
.cui-callbtns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.cui-callbtn { display: inline-flex; align-items: center; gap: 10px; padding: 12px 22px; border-radius: 999px; background: var(--color-brand); color: #fff; font-size: 1rem; font-weight: 500; line-height: 1.2; transition: background-color .2s ease; }
.cui-callbtn:hover { background: var(--color-brand-dark); }
.cui-callbtn svg { flex: none; width: 18px; height: 18px; }

/* Accent list (parts/components/content-ui/accent-list.php). */
.cui-accent { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: 10px 16px; }
.cui-accent li { padding: 13px 18px; border-left: 3px solid var(--color-brand); border-radius: 4px 12px 12px 4px; background: rgba(3, 78, 163, .05); color: var(--color-heading); font-size: 1rem; line-height: 1.5; }
@media (min-width: 640px) { .cui-accent { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Contact cards (parts/components/content-ui/contact-cards.php). */
.cui-contact { list-style: none; margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: 16px; }
/* Icon at the top, text at the bottom (space between, as the other cards). */
.cui-contact__card { display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; gap: 28px; padding: 24px; border-radius: 24px; }
.cui-contact__text { display: flex; flex-direction: column; gap: 6px; }
.cui-contact__icon { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; border: 2px solid var(--color-brand-pale); background: var(--color-brand); }
.cui-contact__icon svg { width: 20px; height: 20px; }
.cui-contact__label { font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--color-body); }
.cui-contact__value { font-size: 1rem; font-weight: 500; line-height: 1.5; color: var(--color-heading); }
.cui-contact__value a { color: var(--color-brand); }
.cui-contact__value a:hover { text-decoration: underline; }
.cui-contact__sep { margin: 0 6px; color: var(--color-body); }
@media (min-width: 768px) { .cui-contact { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
/* With a wide card (e.g. an address): 2 equal columns on tablets; from lg
   (1024px) 5 columns, the wide card spanning 2 (1+1+1+2). */
@media (min-width: 768px) { .cui-contact--wide { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .cui-contact--wide { grid-template-columns: repeat(5, minmax(0, 1fr)); } .cui-contact__card--wide { grid-column: span 2; } }

/* Chips (parts/components/content-ui/chips.php): outline chips with a faint
   version of the theme's light green card gradient, wrapping. */
.cui-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.cui-chips li { padding: 9px 18px; border: 1px solid var(--color-border-soft); border-radius: 999px; background: linear-gradient(360deg, rgba(166, 231, 230, .4) 10%, rgba(166, 231, 230, 0) 100%), #fff; color: var(--color-heading); font-size: .9375rem; line-height: 1.4; }

/* Blue gradient cards without an icon (cards.php 'blue'): text only. */
.cui-card--blue { gap: 0; justify-content: center; }

/* Accent cards (cards.php 'accent'): the accent rows look on the card grid. */
.cui-card--accent { gap: 0; justify-content: center; padding: 18px 22px; border: 0; border-left: 3px solid var(--color-brand); border-radius: 4px 16px 16px 4px; background: rgba(3, 78, 163, .05); }
.cui-card--accent h3 { margin: 0; font-size: 1rem; font-weight: 500; line-height: 1.5; color: var(--color-heading); }
.cui-contact__link { overflow-wrap: anywhere; text-decoration: underline; }

/* Accent list, one column (accent-list.php 'single'). */
.cui-accent.cui-accent--single { grid-template-columns: 1fr; max-width: 56rem; }
.cui-accent--single li { border: 1px solid #f1f2f4; border-left: 3px solid var(--color-brand); background: linear-gradient(90deg, rgba(3, 78, 163, .07), rgba(3, 78, 163, 0)); }

/* A block holding only a heading: the next block follows it closely. */
.cui-block.cui-block--head + .cui-block { margin-top: 0; }

/* Service groups (parts/components/content-ui/service-groups.php): an overview
   card with the other services beside it, then the team grid. */
.cui-svc__top { display: grid; grid-template-columns: 1fr; gap: 16px; }
.cui-svc__hero { display: flex; flex-direction: column; justify-content: flex-end; gap: 14px; padding: 32px; border-radius: 28px; }
.cui-svc__hero h3 { font-size: 1.5rem; font-weight: 600; line-height: 1.25; color: var(--color-brand); }
.cui-svc__hero p { font-size: 1rem; line-height: 1.7; color: var(--color-heading); }
.cui-svc__side { display: grid; gap: 16px; align-content: stretch; }
.cui-svc__card { display: flex; align-items: flex-start; gap: 16px; padding: 22px; border-radius: 20px; transition: border-color .2s ease, box-shadow .2s ease; }
.cui-svc__card:hover { border-color: rgba(3, 78, 163, .25); box-shadow: 0 6px 20px -12px rgba(3, 78, 163, .35); }
.cui-svc__card h4 { font-size: 1.0625rem; font-weight: 600; line-height: 1.3; color: var(--color-brand); }
.cui-svc__card p { margin-top: 6px; font-size: .9375rem; line-height: 1.6; color: var(--color-body); }
.cui-svc__icon { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; border: 2px solid var(--color-brand-pale); background: var(--color-brand); }
.cui-svc__icon svg { width: 22px; height: 22px; }
.cui-svc__icon--lg { width: 56px; height: 56px; border-radius: 16px; margin-bottom: auto; }
.cui-svc__icon--lg svg { width: 28px; height: 28px; }
.cui .cui-svc__team-title { margin: 56px 0 20px; font-size: 1.5rem; font-weight: 600; color: var(--color-heading); }
.cui-svc__team { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 768px) { .cui-svc__team { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) {
  .cui-svc__top { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cui-svc__hero { grid-column: span 2; min-height: 340px; padding: 40px; }
  .cui-svc__top--solo .cui-svc__hero { grid-column: 1 / -1; min-height: 0; }
  .cui-svc__team { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 639px) {
  .cui-svc__hero { padding: 24px; border-radius: 22px; }
  .cui-svc__hero h3 { font-size: 1.3rem; }
  .cui-svc__card { padding: 18px; gap: 14px; }
  .cui-svc__icon { width: 40px; height: 40px; }
  .cui .cui-svc__team-title { margin-top: 40px; font-size: 1.3rem; }
}
/* Nine team services (service-groups.php): 4 / wide + 1 / 3 on desktop. */
@media (min-width: 768px) and (max-width: 1023px) { .cui-svc__team--9 > :nth-child(5) { grid-column: span 2; } }
@media (min-width: 1024px) {
  .cui-svc__team--9 { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .cui-svc__team--9 > * { grid-column: span 4; }
  .cui-svc__team--9 > :nth-child(-n+4) { grid-column: span 3; }
  .cui-svc__team--9 > :nth-child(5) { grid-column: span 8; }
}
/* Team cards: icon at the top, text at the bottom (space between). */
.cui-svc__team .cui-svc__card { flex-direction: column; justify-content: space-between; gap: 24px; }
