/* WordPress-only additions (13 Nov 2026).
   Kept apart from site.css so that file can still be re-synced from the original site. */

/* ---------- Reading cards: thumbnail, topic, title. Used by Further Reading and by More to read on articles ---------- */
.reading-card { display: flex; flex-direction: column; width: 100%; background: var(--cream); color: var(--ink); border-radius: 14px; overflow: hidden; text-decoration: none; font-size: var(--fs-body); font-weight: 400; transition: transform .35s, background .25s, color .25s; }
.reading-card__media { display: block; aspect-ratio: 2 / 1; overflow: hidden; background: rgba(14, 12, 10, .08); }
.reading-card__img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.reading-card__body { display: flex; flex-direction: column; flex: 1; gap: 10px; padding: max(18px, calc(24 * var(--u))); }
.reading-card__meta { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-size: var(--fs-small); line-height: 1.3; color: var(--quiet); transition: color .25s; }
.reading-card__topic { font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.reading-card__title { font-family: var(--font-display); font-size: var(--fs-h4); font-weight: 700; line-height: 1.15; letter-spacing: -.025em; text-wrap: balance; }
.reading-card__text { font-size: var(--fs-small); line-height: 1.5; color: var(--body); transition: color .25s; }
.reading-card__cta { display: inline-flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 6px; font-size: var(--fs-small); font-weight: 700; }
.reading-card__cta .icon { width: 1.1em; height: 1.1em; flex: none; transition: transform .3s; }
.reading-card:focus-visible { outline-offset: 4px; }
@media (hover: hover) {
  .reading-card:hover { background: var(--ink); color: var(--cream); }
  .reading-card:hover .reading-card__meta { color: rgba(243, 238, 230, .72); }
  .reading-card:hover .reading-card__text { color: rgba(243, 238, 230, .8); }
  .reading-card:hover .reading-card__cta .icon { transform: translate(3px, -3px); }
}
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .reading-card:hover .reading-card__img { transform: scale(1.04); }
}

/* Further Reading on the service pages: three cards in a row */
.also__links.also__links--cards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: calc(28 * var(--u)); margin-top: max(20px, calc(28 * var(--u))); align-items: stretch; }
.also__links--cards > li { display: flex; }
.also__links .reading-card { font-weight: 400; text-decoration: none; }
@media (max-width: 860px) {
  .also__links.also__links--cards { grid-template-columns: 1fr; gap: 18px; }
}

/* More to read at the foot of an article: two cards */
.related__grid { column-gap: calc(28 * var(--u)); align-items: stretch; }
.related__card { display: flex; }
.related__card .reading-card { text-decoration: none; }

/* ---------- Articles: the opening picture keeps its shape instead of being cropped on shorter screens ---------- */
.article-opening__img { max-height: none; }

/* ---------- Marketing Audits: the opening picture is larger and has a second page beside it ---------- */
.opening__media--layered { position: relative; width: min(100%, calc(440 * var(--u))); }
.opening__media--layered .card-shot--page-detail { position: absolute; left: -24%; bottom: max(34px, calc(52 * var(--u))); width: 70%; z-index: 2; border-radius: 10px; background: #fff; }
.opening__media--layered .card-shot--page-detail img { display: block; width: 100%; height: auto; }
@media (max-width: 860px) {
  .opening__media--layered { width: auto; }
  .opening__media--layered .card-shot--page-detail { display: none; }
}

/* ---------- About: the founder photo is a small round profile picture ---------- */
.headshot { margin-top: max(20px, calc(30 * var(--u))); width: clamp(104px, calc(140 * var(--u)), 172px); aspect-ratio: 1; border-radius: 50%; overflow: hidden; background: var(--sand, #ddd3c2); box-shadow: 0 0 0 1px rgba(14, 12, 10, .14), 0 16px 30px -16px rgba(14, 12, 10, .5); }
.headshot img { display: block; width: 100%; height: 100%; object-fit: cover; }
/* A short caption so the photo is not left unexplained. */
.headshot__caption { margin-top: 12px; font-size: var(--fs-small); line-height: 1.3; color: var(--ink); opacity: .75; }
.headshot__caption strong { font-weight: 600; }

/* ---------- Phones: pictures are shown whole instead of being cropped into a box ---------- */
@media (max-width: 860px) {
  /* wide overview pictures in the full-width bands */
  .placeholder--band:has(> img) { aspect-ratio: auto !important; }
  .placeholder--band > img { position: static !important; height: auto !important; }
  /* phone screens in the Ledger and Co gallery are tall, so they keep their own shape */
  .concept-img--crop { aspect-ratio: auto; object-fit: contain; }
  .detail-gallery__grid { align-items: flex-start; }
}

/* ---------- Footer: Facebook and LinkedIn icon links ---------- */
.tn-social { display: flex; gap: 12px; list-style: none; padding: 0; margin: 0; }
.footer__social { margin-top: max(16px, calc(20 * var(--u))); }
.contact__social { margin-top: max(14px, calc(18 * var(--u))); }
.tn-social a { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; }
.tn-social .social-icon { width: 40px; height: 40px; transition: transform .3s; }
.tn-social .social-icon rect { fill: var(--cream); transition: fill .25s; }
.tn-social .social-icon svg { fill: var(--ink); }
.tn-social a:focus-visible { outline: 2px solid var(--cream); outline-offset: 3px; }
/* in the contact section (light background) the squares are dark with a light logo */
.contact__social .social-icon rect { fill: var(--ink); }
.contact__social .social-icon svg { fill: var(--cream); }
.contact__social a:focus-visible { outline-color: var(--ink); }
@media (hover: hover) {
  .footer__social a:hover .social-icon rect { fill: #fff; }
  .contact__social a:hover .social-icon rect { fill: #000; }
}
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .tn-social a:hover .social-icon { transform: translateY(-2px); }
}
/* ---------- Sizing on resize ---------- */
/* Each "one screen" band is as tall as one screen at the size the design was drawn for (1366 x 768, scaled with the
   window), never taller. Before, a tall window made every band as tall as the window, leaving big empty gaps. */
:root {
  --screen: min(calc(var(--vh) * 100 - var(--header-h)), calc(696 * var(--u)));
}
/* Only the opening band keeps the full one-screen height; the others are tighter, so a wide, roomy window does not
   leave large empty bands above and below the content. Content can still make a band taller. */
@media (min-width: 861px) {
  .screen:not(.hero):not(.sheet) { min-height: calc(var(--screen) * 0.8); }
  .screen.sheet { min-height: calc(var(--screen) * 0.8 + var(--sheet-r)); }
  .intro.screen, .who.screen { min-height: calc(var(--screen) * 0.68); } /* short, centred statements */
  /* A service row taller than one screen is not stacked; its picture used to sit at the very top of its column with a
     long empty run underneath. Centre it against the text instead. */
  .services:not(.is-stacked) .service-card__media { align-self: center; margin-top: max(12px, calc(20 * var(--u))); }
}
/* Phone swipe galleries: a picture keeps its own shape instead of stretching to the height of the tallest one beside it. */
@media (max-width: 860px) {
  .concept-planning__media .concept-img { align-self: flex-start; height: auto; }
}
/* Cookie table on phones: six columns do not fit, so each row becomes a short list (label, then value) instead of
   scrolling sideways. The labels match the table's column headings, in order; change them here if the headings change. */
@media (max-width: 860px) {
  .reading__table { overflow-x: visible; }
  .reading__table table { min-width: 0; display: block; }
  .reading__table thead { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
  .reading__table tbody, .reading__table tr, .reading__table td { display: block; }
  .reading__table tr { border-top: 1px solid var(--rule); padding: 12px 0; }
  .reading__table td { border: 0; padding: 3px 0; }
  .reading__table td::before { display: block; font-weight: 600; color: var(--text); }
  .reading__table td:nth-child(1)::before { content: "Technology"; }
  .reading__table td:nth-child(2)::before { content: "Name"; }
  .reading__table td:nth-child(3)::before { content: "Who sets it"; }
  .reading__table td:nth-child(4)::before { content: "Purpose"; }
  .reading__table td:nth-child(5)::before { content: "How long"; }
  .reading__table td:nth-child(6)::before { content: "Consent required?"; }
}

/* ---------- Brand rule fixes (15 Nov 2026, from the final checks) ---------- */
/* Deep teal is never used as text: the small Good to Know labels use the same quiet ink as every other label. */
.fit--bento .fit__tag { color: rgba(14, 12, 10, .72); }
/* The About opening did not anchor its corner 29, so it sat at the bottom of the screen under the next band instead of whole inside the opening (the home hero does anchor it). */
.about-opening { position: relative; }
