/*
Theme Name: Kobiety e-biznesu
Theme URI: https://kobietyebiznesu.pl
Author: Fundacja kobiety e-biznesu
Author URI: https://kobietyebiznesu.pl
Description: Nowoczesny motyw dla Fundacji "kobiety e-biznesu" — technologia, kompetencje, przyszłość. Zawiera edytowalną stronę główną (Customizer), typ treści "Programy" oraz sekcję aktualności opartą na wpisach.
Version: 1.4.0
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: kobiety-e-biznesu
Tags: business, education, foundation, custom-colors, custom-menu, custom-logo, featured-images, translation-ready
*/

/* =============================================================
   1. Design tokens
   ============================================================= */
:root {
  /* Brand colors */
  --c-teal:   #00D1B2;
  --c-cyan:   #22D3EE;
  --c-purple: #6D28D9;
  --c-dark:   #0B0D1A;
  --c-light:  #F7F7FA;

  /* Semantic */
  --color-bg:        #ffffff;
  --color-surface:   var(--c-light);
  --color-ink:       var(--c-dark);
  --color-ink-soft:  #4b4f63;
  --color-line:      #e6e7ef;
  --color-accent:    var(--c-purple);

  /* Signature gradient */
  --grad-brand: linear-gradient(120deg, var(--c-teal) 0%, var(--c-cyan) 45%, var(--c-purple) 100%);
  --grad-brand-soft: linear-gradient(120deg, rgba(0,209,178,.14) 0%, rgba(34,211,238,.12) 45%, rgba(109,40,217,.16) 100%);

  /* Typography */
  --font-base: 'General Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;

  /* Layout */
  --container: 1200px;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --radius-sm: 10px;
  --radius: 18px;
  --radius-lg: 28px;

  /* Shadows */
  --shadow-sm: 0 6px 20px rgba(11,13,26,.06);
  --shadow-md: 0 18px 50px rgba(11,13,26,.12);

  --header-h: 80px;
}

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-base);
  font-weight: 400;
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--color-ink-soft);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  color: var(--color-ink);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 .5em;
}

p { margin: 0 0 1rem; }

a { color: inherit; text-decoration: none; }

img, svg { display: block; max-width: 100%; height: auto; }

ul { margin: 0; padding: 0; list-style: none; }

/* =============================================================
   3. Layout helpers
   ============================================================= */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: clamp(1.5rem, 3vw, 2.75rem); }

.eyebrow {
  display: inline-block;
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--c-teal);
  margin-bottom: 1rem;
}

.text-gradient {
  background: var(--grad-brand);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: clamp(2rem, 4vw, 3rem);
}
.section-head h2 { font-size: clamp(1.9rem, 4vw, 2.75rem); }
.section-head__actions { display: flex; align-items: center; gap: 1.25rem; }

/* Programs section — longer heading, so a smaller size reads better here
   than the shared .section-head h2 size used by the other sections. */
.programs .section-head h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); }

/* Manual "next" control for the horizontally-scrolling programs track —
   the track itself has no visible scrollbar and doesn't respond to a
   normal vertical mouse wheel, so without this button a 4th+ card was
   effectively unreachable for most desktop users. */
.programs__nav {
  flex: none;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1.5px solid var(--color-line);
  background: #fff;
  color: var(--color-ink);
  cursor: pointer;
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.programs__nav:hover { background: var(--grad-brand); border-color: transparent; color: #fff; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-weight: 600;
  color: var(--c-purple);
  white-space: nowrap;
}
.link-arrow svg { transition: transform .25s ease; }
.link-arrow:hover svg { transform: translateX(4px); }

/* =============================================================
   4. Buttons
   ============================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  padding: .95rem 1.6rem;
  border-radius: 999px;
  font-family: inherit;
  font-size: .95rem;
  font-weight: 600;
  letter-spacing: .02em;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .25s ease, background .25s ease, color .25s ease;
  white-space: nowrap;
}
.btn svg { flex: none; }
.btn:hover { transform: translateY(-2px); }

.btn--primary {
  background: var(--grad-brand);
  color: #fff;
  box-shadow: 0 10px 26px rgba(34,211,238,.35);
}
.btn--primary:hover { box-shadow: 0 14px 34px rgba(109,40,217,.4); color: #fff; }

.btn--outline {
  background: transparent;
  color: var(--color-ink);
  border-color: var(--color-ink);
}
.btn--outline:hover { background: var(--color-ink); color: #fff; }

.btn--light {
  background: #fff;
  color: var(--color-ink);
}
.btn--light:hover { color: var(--color-ink); }
.btn--ghost-light {
  background: transparent;
  color: #fff;
  border-color: rgba(255,255,255,.5);
}
.btn--ghost-light:hover { background: #fff; color: var(--color-ink); }

/* =============================================================
   5. Header / navigation
   ============================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.85);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: box-shadow .3s ease, border-color .3s ease;
}
.site-header.is-scrolled {
  box-shadow: var(--shadow-sm);
  border-color: var(--color-line);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  height: var(--header-h);
}

/* Logo */
.brand { display: inline-flex; align-items: center; gap: .7rem; }
.brand__mark { width: 42px; height: 42px; }
.brand__text { line-height: 1; }
.brand__kicker {
  display: block;
  font-size: .58rem;
  font-weight: 600;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--c-teal);
  margin-bottom: 3px;
}
.brand__name {
  display: block;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -.01em;
  color: var(--color-ink);
}
.brand--custom-logo img { width: auto; max-height: 46px; }

/* Primary nav */
.main-nav ul { display: flex; align-items: center; gap: clamp(1rem, 2.2vw, 2rem); margin: 0; padding: 0; list-style: none; }
.main-nav li { position: relative; flex: 0 0 auto; }
.main-nav a {
  font-size: .85rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--color-ink);
  position: relative;
  padding-block: .4rem;
  display: inline-block;
  white-space: nowrap;
}
.main-nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0; height: 2px;
  background: var(--grad-brand);
  transition: width .25s ease;
}
.main-nav a:hover::after,
.main-nav .current-menu-item > a::after { width: 100%; }

/* Sub-menus */
.main-nav .sub-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 210px;
  background: #fff;
  border: 1px solid var(--color-line);
  border-radius: 14px;
  box-shadow: var(--shadow-md);
  padding: .5rem;
  display: none;
  flex-direction: column;
  gap: .1rem;
  z-index: 20;
}
@media (min-width: 1321px) {
  .main-nav .sub-menu {
    left: 50%;
    right: auto;
    width: max-content;
    max-width: min(360px, calc(100vw - 2rem));
    transform: translateX(-50%);
  }
}
.main-nav li:hover > .sub-menu { display: flex; }
.main-nav .sub-menu a { text-transform: none; letter-spacing: 0; padding: .5rem .75rem; border-radius: 8px; }
.main-nav .sub-menu a::after { display: none; }
.main-nav .sub-menu a:hover { background: var(--color-surface); }

.header-actions { display: flex; align-items: center; gap: .85rem; }

/* Hamburger */
.nav-toggle {
  --bar: #0B0D1A;
  display: none;
  width: 46px; height: 46px;
  border: 1.5px solid var(--color-line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  padding: 0;
  place-items: center;
}
.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  display: block;
  width: 20px; height: 2px;
  background: var(--bar);
  border-radius: 2px;
  transition: transform .3s ease, opacity .2s ease;
}
.nav-toggle span { position: relative; }
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after  { position: absolute; top: 6px; }
.nav-open .nav-toggle span { background: transparent; }
.nav-open .nav-toggle span::before { transform: translateY(6px) rotate(45deg); }
.nav-open .nav-toggle span::after  { transform: translateY(-6px) rotate(-45deg); }

/* =============================================================
   6. Hero
   ============================================================= */
.hero { position: relative; overflow: hidden; }
.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: stretch;
  padding-top: clamp(2.5rem, 6vw, 4.5rem);
  padding-bottom: 0;
}
.hero__title {
  font-size: clamp(2.75rem, 7vw, 5rem);
  margin-bottom: 1.25rem;
}
.hero__lead { font-size: 1.15rem; max-width: 32ch; margin-bottom: 2rem; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 3rem; }

/* Hero media — full, uncropped photo, scaled to the box's height */
.hero__media {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero__photo {
  position: relative;
  width: auto;
  height: 100%;
  max-width: 100%;
  object-fit: contain;
}

/* Stats — sit inside the content column, below the actions, beside the photo */
.stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem 2rem;
  margin-top: 1rem;
}
.stat { display: flex; align-items: center; gap: .85rem; min-width: 0; }
.stat__icon {
  flex: none;
  width: 40px; height: 40px;
  color: var(--c-cyan);
}
.stat__num {
  display: block;
  font-size: clamp(1.1rem, 3vw, 2rem);
  font-weight: 700;
  color: var(--color-ink);
  line-height: 1;
}
.stat__label { display: block; font-size: clamp(.68rem, 1.4vw, .9rem); line-height: 1.3; overflow-wrap: break-word; }

/* =============================================================
   7. About
   ============================================================= */
/* A deliberate, larger gap after the hero (hero itself has no bottom
   padding, so this section supplies the whole visual break). */
.about.section { padding-top: clamp(3rem, 6vw, 5rem); }
.about__title { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.about__grid {
  display: grid;
  /* The photo column is intentionally wider than the text column — see
     the client's reference crop (three ~2:3 portraits need more room
     than a square grid gives them). */
  grid-template-columns: .8fr 1.2fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
.about__gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.about__gallery img {
  width: 100%;
  /* Fixed (not dynamic) height on desktop — tuned to span the full
     intro column, from the eyebrow label at the top to the CTA button
     at the bottom (measured against the real rendered content). */
  height: 400px;
  border-radius: var(--radius);
  object-fit: cover;
  box-shadow: var(--shadow-sm);
}

/* =============================================================
   8. Partners / trust bar
   ============================================================= */
.partners { padding-block: clamp(1.25rem, 2.5vw, 2rem); }
.partners__row {
  display: flex;
  align-items: center;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  flex-wrap: wrap;
}
.partners__label {
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--color-ink);
}
.partners__logos {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  overflow: hidden;
  flex: 1;
  min-width: 0;
  align-self: stretch;
  width: 100%;
}
.partners__logos span {
  font-weight: 700;
  font-size: 1.25rem;
  color: #9aa0b5;
  letter-spacing: .02em;
}
.partners__logos img { display: block; max-width: 180px; max-height: 52px; width: auto; height: auto; object-fit: contain; filter: grayscale(1); opacity: .7; transition: filter .25s ease, opacity .25s ease; }
.partners__logos img:hover { filter: grayscale(0); opacity: 1; }
.partners__logos.keb-partners--color img { filter: none; opacity: 1; }
.keb-vc-partners__inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: clamp(1rem, 3vw, 1.5rem); }
.partners__logos.keb-partners--wrap {
  flex-wrap: wrap;
  width: 100%;
  justify-content: center;
  overflow: visible;
  gap: clamp(1.5rem, 4vw, 3rem);
}

/* Single-row logo strip — auto-scrolls like a news ticker once the logos
   no longer fit; .partners__logos-track holds one set of logos, doubled by
   JS only when it overflows (see main.js), so this stays static otherwise. */
.partners__logos-track {
  display: flex;
  align-items: center;
  gap: clamp(1.5rem, 4vw, 3rem);
  width: max-content;
}
.partners__logos:not(.is-marquee) {
  justify-content: center;
}
.partners__logos.is-marquee .partners__logos-track {
  animation: keb-marquee var(--keb-marquee-duration, 25s) linear infinite;
}
.partners__logos.is-marquee:hover .partners__logos-track {
  animation-play-state: paused;
}
@keyframes keb-marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* =============================================================
   9. Programs
   ============================================================= */
.programs {
  background: var(--color-surface);
  border-radius: clamp(24px, 5vw, 48px);
  padding: clamp(2rem, 4vw, 3.5rem);
}
.programs__track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(300px, 1fr);
  gap: 1.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 1rem;
  scrollbar-width: none;
}
.programs__track::-webkit-scrollbar { display: none; }

.program-card {
  position: relative;
  scroll-snap-align: start;
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 460px;
  background: var(--c-dark);
  color: #fff;
  isolation: isolate;
}
.program-card__content {
  position: relative;
  z-index: 2;
  max-width: 78%;
  min-height: 460px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.75rem;
}
/* Full-bleed photo layer behind the text. The source images are now
   pre-cropped (see DZIENNIK/WDROZENIE notes) tight around the people at
   close to this card's own aspect ratio, so object-fit:cover only needs
   a light touch-up — no more fighting a panoramic source image inside a
   narrow, tall card. */
.program-card__media {
  position: absolute;
  inset: 0;
  z-index: 1;
}
.program-card__photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.program-card__media::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(90deg, var(--c-dark) 0%, var(--c-dark) 32%, rgba(11,13,26,0) 68%);
}
.program-card__tag {
  align-self: flex-start;
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: .4rem .8rem;
  border-radius: 999px;
  background: var(--grad-brand);
  margin-bottom: auto;
}
.program-card h3 { color: #fff; font-size: 1.5rem; margin-top: 1.25rem; }
.program-card__desc { color: rgba(255,255,255,.8); font-size: .95rem; margin-bottom: 1rem; }
.program-card__list { display: grid; gap: .5rem; margin-bottom: 1.5rem; }
.program-card__list li {
  display: flex; align-items: center; gap: .55rem;
  font-size: .9rem; color: rgba(255,255,255,.9);
}
.program-card__list svg { color: var(--c-teal); flex: none; }

/* =============================================================
   10. News
   ============================================================= */
.news__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}
.news-card {
  background: #fff;
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .25s ease, box-shadow .25s ease;
}
.news-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.news-card__media { aspect-ratio: 3/2; overflow: hidden; display: block; }
.news-card__media img { width: 100%; height: 100%; object-fit: cover; }
.news-card__body { padding: 1.25rem 1.35rem 1.5rem; display: flex; flex-direction: column; flex: 1; }
.news-card__date {
  font-size: .72rem; font-weight: 600; letter-spacing: .1em;
  text-transform: uppercase; color: var(--c-purple); margin-bottom: .6rem;
}
.news-card h3 { font-size: 1.05rem; line-height: 1.3; }
.news-card__more {
  margin-top: auto;
  align-self: flex-end;
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 50%;
  border: 1.5px solid var(--color-line);
  color: var(--color-ink);
  transition: background .25s ease, color .25s ease, border-color .25s ease;
}
.news-card:hover .news-card__more { background: var(--grad-brand); color: #fff; border-color: transparent; }

/* =============================================================
   11-12. Footer (light, with a rounded-top gradient CTA banner)
   ============================================================= */
.site-footer {
  background: var(--color-bg);
  color: var(--color-ink-soft);
}

/* Gradient CTA banner — full-bleed, rounded only at the top, flush with
   the light footer content directly below it (no gap/margin). */
.footer__cta {
  position: relative;
  overflow: hidden;
  background: var(--grad-brand);
  border-radius: clamp(20px, 4vw, 36px) clamp(20px, 4vw, 36px) 0 0;
}
.footer__cta-inner {
  position: relative;
  padding-block: clamp(2.5rem, 5vw, 4rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}
.footer__cta::before {
  content: "";
  position: absolute;
  left: 3%; top: 50%;
  transform: translateY(-50%);
  width: 140px; height: 140px;
  background-image: radial-gradient(rgba(255,255,255,.55) 2px, transparent 2px);
  background-size: 18px 18px;
  opacity: .5;
}
.footer__cta h2 { color: #fff; font-size: clamp(1.8rem, 4vw, 2.6rem); position: relative; }
.footer__cta p { color: rgba(255,255,255,.9); max-width: 46ch; margin: 0; position: relative; }
/* Capped width so the heading wraps early enough to always leave room
   for the button beside it (not below it) at typical desktop widths. */
.footer__cta-text { position: relative; max-width: 640px; }
.footer__cta-inner > .btn { flex: none; }

/* Newsletter signup strip — sits between the gradient CTA and the link
   columns, matching the client's mockup. Built as a single grid spanning
   the full section width: the CF7 wrapper elements are unwrapped with
   `display: contents` so its field rows become direct grid items
   alongside the intro text, instead of being boxed into a narrow form
   column — that's what let the RODO consent rows stretch full width
   instead of wrapping awkwardly under a skinny form. The shared CF7 form
   (also used on the "Strefa Wiedzy" page) keeps its own fields and
   required consent checkboxes untouched — this is purely a local reflow. */
.footer__newsletter { border-bottom: 1px solid var(--color-line); }
.footer__newsletter-inner {
  padding-block: clamp(1.5rem, 3vw, 2.25rem);
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(200px, 260px) auto;
  align-items: center;
  gap: .85rem 1.5rem;
}
.footer__newsletter-text {
  grid-column: 1;
  grid-row: 1 / 3;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.footer__newsletter-icon { flex: none; width: 44px; height: 44px; }
.footer__newsletter-text h3 { font-size: 1.15rem; margin-bottom: .3rem; }
.footer__newsletter-text p { margin: 0; font-size: .9rem; color: var(--color-ink-soft); }

.footer__newsletter-form,
.footer__newsletter-form .wpcf7,
.footer__newsletter-form .wpcf7-form,
.footer__newsletter-form #kb-newsletter {
  display: contents;
}
.footer__newsletter-form p { margin: 0; }
/* Email + submit + name all stay in the right-hand "form" columns (2-3),
   beside the text — only the RODO consent rows break out to the full
   section width at the bottom. Name sits above email, both confined to
   column 2 so they render the same width; submit sits beside email. */
.footer__newsletter-form p:has([data-name="your-name"]) { grid-column: 2; grid-row: 1; }
.footer__newsletter-form p:has([data-name="your-email"]) { grid-column: 2; grid-row: 2; }
.footer__newsletter-form p:has(> input.wpcf7-submit) { grid-column: 3; grid-row: 2; }
.footer__newsletter-form p:has([data-name^="acceptance-"]) { grid-column: 1 / -1; font-size: .78rem; }
.footer__newsletter-form p:has([data-name="acceptance-1111"]) { grid-row: 3; }
.footer__newsletter-form p:has([data-name="acceptance-1112"]) { grid-row: 4; }
.footer__newsletter-form .kb-new {
  display: block;
  float: none !important;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--color-ink-soft);
  margin-bottom: .3rem;
}
.footer__newsletter-form input[type="text"],
.footer__newsletter-form input[type="email"] {
  width: 100%;
  padding: .75rem 1.1rem;
  border: 1.5px solid var(--color-line);
  border-radius: 999px;
  font-family: inherit;
  font-size: .92rem;
  background: #fff;
}
.footer__newsletter-form input.wpcf7-submit {
  background: var(--grad-brand);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: .85rem 1.6rem;
  font-family: inherit;
  font-size: .92rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}
.footer__newsletter-form .wpcf7-list-item { margin: 0; display: flex; align-items: flex-start; gap: .5rem; }
.footer__newsletter-form .wpcf7-list-item-label { font-size: .78rem; line-height: 1.4; color: var(--color-ink-soft); }
.footer__newsletter-form .wpcf7-not-valid-tip { font-size: .78rem; }
.footer__newsletter-form .wpcf7-response-output { margin: .5rem 0 0; font-size: .82rem; }

.footer__grid {
  padding-top: clamp(2.5rem, 5vw, 4rem);
  display: grid;
  grid-template-columns: 1.4fr repeat(4, 1fr);
  gap: 2.5rem;
}
.footer__intro { max-width: 30ch; }
.footer__socials { display: flex; gap: .6rem; margin-top: 1.5rem; }
.footer__socials a {
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 50%;
  border: 1.5px solid var(--color-line);
  color: var(--color-ink);
  transition: background .25s ease, border-color .25s ease, color .25s ease;
}
.footer__socials a:hover { background: var(--grad-brand); border-color: transparent; color: #fff; }
.footer__col h4 {
  color: var(--color-ink);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin-bottom: 1.2rem;
}
.footer__col ul { margin: 0; padding: 0; list-style: none; }
.footer__col li { margin-bottom: .7rem; }
.footer__col a { font-size: .95rem; transition: color .2s ease; }
.footer__col a:hover { color: var(--c-purple); }
.footer__bottom {
  margin-top: 3rem;
  padding-top: 1.5rem;
  padding-bottom: 2rem;
  border-top: 1px solid var(--color-line);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: .85rem;
}

/* =============================================================
   13. WordPress content (pages, posts, archives, comments)
   ============================================================= */
.page-hero { padding-block: clamp(2.5rem, 6vw, 4.5rem) 0; }
.page-hero .eyebrow { margin-bottom: .5rem; }
.page-hero h1 { font-size: clamp(2rem, 5vw, 3.25rem); }

.entry-content { max-width: 780px; }
.entry-content > * { margin-block: 0 1.25rem; }
.entry-content h2 { font-size: 1.7rem; margin-top: 2rem; }
.entry-content h3 { font-size: 1.35rem; margin-top: 1.75rem; }
.entry-content a { color: var(--c-purple); text-decoration: underline; }
.entry-content img,
.entry-content .wp-block-image { border-radius: var(--radius); }
.entry-content ul,
.entry-content ol { padding-left: 1.25rem; margin-bottom: 1.25rem; }
.entry-content ul { list-style: disc; }
.entry-content ol { list-style: decimal; }
.entry-content li { margin-bottom: .4rem; }
.entry-content blockquote {
  border-left: 4px solid var(--c-cyan);
  padding-left: 1.25rem;
  margin: 1.75rem 0;
  font-size: 1.15rem;
  color: var(--color-ink);
}
.entry-content figure { margin: 0 0 1.5rem; }
.entry-content .wp-caption-text,
.entry-content figcaption { font-size: .85rem; color: var(--color-ink-soft); margin-top: .5rem; }

.post-thumbnail img { border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); width: 100%; }
.entry-meta { font-size: .8rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--c-purple); margin-bottom: 1rem; }

/* Pages migrated from the old page-builder theme: let the content set its
   own heading/width instead of the default page title + 780px text column. */
.entry-content--builder { max-width: none; }

.keb-spacer { display: block; width: 100%; }

.keb-heading { position: relative; margin: 0 0 1.25rem; color: var(--color-ink); }
.keb-heading--left { text-align: left; }
.keb-heading--center { text-align: center; }
.keb-heading--right { text-align: right; }
.keb-heading--separator { padding-bottom: 1.25rem; }
.keb-heading--separator::after {
  content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 56px; height: 3px; border-radius: 2px; background: var(--grad-brand);
}
.keb-heading--separator.keb-heading--left::after { left: 0; transform: none; }
.keb-heading--separator.keb-heading--right::after { left: auto; right: 0; transform: none; }

.keb-grid {
  display: grid;
  grid-template-columns: repeat(var(--keb-grid-cols, 1), 1fr);
  column-gap: var(--keb-grid-col-gap, 20px);
  row-gap: var(--keb-grid-row-gap, 20px);
}

.keb-box-icon {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  gap: .9rem; padding: 1.75rem 1.25rem; height: 100%;
  background: var(--color-surface); border: 1px solid var(--color-line); border-radius: var(--radius);
  color: inherit; text-decoration: none;
  transition: box-shadow .2s ease, transform .2s ease;
}
a.keb-box-icon:hover { box-shadow: var(--shadow-sm); transform: translateY(-3px); }
.keb-box-icon__media img { display: block; width: 100%; max-width: 140px; height: auto; object-fit: contain; }
.keb-box-icon__heading { margin: 0; font-size: 1.05rem; color: var(--color-ink); }
.keb-box-icon__text { margin: 0; font-size: .9rem; line-height: 1.6; color: var(--color-ink-soft); }

.keb-blog__pagination { margin-top: 2rem; }
.keb-button-wrap { margin-block: 1.5rem; }

/* tm_team_member / tm_counter come as bare, unwrapped shortcodes in the old
   content (no enclosing grid tag) — turn whichever element ends up holding
   them (a wpautop-generated <p>, or .entry-content itself) into a row. */
.entry-content p:has(> .keb-team-item),
.entry-content--builder:has(> .keb-team-item) {
  display: flex; flex-wrap: wrap; gap: 1.5rem; margin-bottom: 2rem;
}
.entry-content p:has(> .keb-counter-item),
.entry-content--builder:has(> .keb-counter-item) {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; margin-bottom: 2rem;
}
.entry-content p:has(> .keb-image),
.entry-content--builder:has(> .keb-image) {
  display: flex; flex-wrap: wrap; gap: 1.5rem; margin-bottom: 2rem;
}
.entry-content p:has(> .keb-image) .keb-image,
.entry-content--builder:has(> .keb-image) .keb-image {
  flex: 1 1 200px; max-width: 260px;
}
.keb-image { display: block; }
.keb-image img { display: block; width: 100%; height: auto; }

.keb-team-item {
  flex: 1 1 220px; max-width: 280px;
  display: flex; flex-direction: column; align-items: center; gap: .4rem;
  text-align: center; padding: 1.75rem 1.25rem;
  background: #fff; border: 1px solid var(--color-line); border-radius: var(--radius);
}
.keb-team-item__link {
  display: flex; flex-direction: column; align-items: center; gap: .75rem;
  color: inherit; text-decoration: none;
}
.keb-team-item__photo {
  width: 96px; height: 96px; border-radius: 50%; overflow: hidden; display: block;
}
.keb-team-item__photo img { width: 100%; height: 100%; object-fit: cover; }
.keb-team-item__name { font-size: 1.05rem; font-weight: 600; color: var(--color-ink); }
.keb-team-item__position {
  font-size: .78rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--c-purple);
}
.keb-team-item__desc { margin: 0; font-size: .88rem; line-height: 1.6; color: var(--color-ink-soft); }
.keb-team-item__socials { display: flex; gap: .5rem; margin-top: .25rem; }
.keb-team-item__socials a {
  width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%;
  border: 1px solid var(--color-line); color: var(--color-ink);
  transition: background .25s ease, color .25s ease, border-color .25s ease;
}
.keb-team-item__socials a:hover { background: var(--grad-brand); color: #fff; border-color: transparent; }

/* Alignment support */
.alignleft  { float: left; margin: .3rem 1.5rem 1rem 0; }
.alignright { float: right; margin: .3rem 0 1rem 1.5rem; }
.aligncenter { display: block; margin-inline: auto; }
.wp-block-image.alignwide { max-width: min(1100px, 92vw); margin-inline: auto; }
.wp-block-image.alignfull { max-width: 100vw; }

/* Pagination */
.pagination { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: 3rem; }
.pagination .page-numbers {
  display: grid; place-items: center;
  min-width: 44px; height: 44px; padding: 0 .75rem;
  border: 1.5px solid var(--color-line); border-radius: 12px;
  font-weight: 600;
}
.pagination .page-numbers.current { background: var(--grad-brand); color: #fff; border-color: transparent; }
.pagination a.page-numbers:hover { border-color: var(--color-ink); }

/* Comments */
.comments-area { max-width: 780px; margin-top: 3rem; }
.comment-list { list-style: none; padding: 0; }
.comment-list .comment { padding: 1.25rem 0; border-top: 1px solid var(--color-line); }
.comment-list .children { list-style: none; padding-left: 1.5rem; }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea,
.search-form input[type="search"] {
  width: 100%; padding: .8rem 1rem;
  border: 1.5px solid var(--color-line); border-radius: 12px;
  font-family: inherit; font-size: 1rem; background: #fff;
}
.comment-form textarea { min-height: 140px; }

/* Blog / archive grid reuses the news card styling */
.post-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

/* Accessibility */
.screen-reader-text {
  border: 0; clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px; width: 1px; margin: -1px; padding: 0;
  overflow: hidden; position: absolute !important; word-wrap: normal !important;
}
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: #fff; color: var(--color-ink); padding: .75rem 1.25rem; border-radius: 0 0 12px 0;
}
.skip-link:focus { left: 0; }

/* WordPress admin bar offset for the sticky header */
.admin-bar .site-header { top: 32px; }
@media screen and (max-width: 782px) {
  .admin-bar .site-header { top: 46px; }
}

/* =============================================================
   14. Responsive
   ============================================================= */
@media (max-width: 992px) {
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .footer__intro { grid-column: 1 / -1; }
  .news__grid { grid-template-columns: repeat(2, 1fr); }
  .post-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  .main-nav {
    position: fixed;
    inset: var(--header-h) 0 0 auto;
    width: min(340px, 82vw);
    background: #fff;
    box-shadow: var(--shadow-md);
    transform: translateX(100%);
    transition: transform .3s ease;
    padding: 2rem;
    overflow-y: auto;
  }
  .admin-bar .main-nav { inset: calc(var(--header-h) + 46px) 0 0 auto; }
  .nav-open .main-nav { transform: translateX(0); }
  .main-nav ul { flex-direction: column; gap: .5rem; }
  .main-nav a { display: block; padding: .75rem 0; font-size: 1rem; }
  .main-nav .sub-menu { position: static; display: flex; box-shadow: none; border: none; padding: 0 0 0 1rem; }
  .nav-toggle { display: grid; }
  .header-actions .btn { display: none; }

  .hero__grid { grid-template-columns: 1fr; }
  .hero__media { order: -1; max-width: 480px; margin-inline: auto; }
  .hero__lead { max-width: none; }
  .about__grid { grid-template-columns: 1fr; }
  .about__gallery img { height: 320px; }
  .stat { gap: .5rem; }
  .stat__icon { width: 26px; height: 26px; }
  .footer__cta-inner { flex-direction: column; align-items: flex-start; }
  .footer__newsletter-inner { grid-template-columns: 1fr; }
  .footer__newsletter-form p {
    grid-column: 1 !important;
    grid-row: auto !important;
    max-width: none !important;
  }
}

@media (max-width: 560px) {
  .stats { grid-template-columns: 1fr; }
  .stat { flex-direction: column; align-items: flex-start; gap: .35rem; text-align: left; }
  .stat__icon { display: none; }
  .about__gallery img { height: 220px; }
  .news__grid { grid-template-columns: 1fr; }
  .post-grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .section-head { flex-direction: column; align-items: flex-start; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}

/* Homepage correction 2026: editable programs, experts and card actions. */
.programs__controls { display: inline-flex; gap: .5rem; }
.programs__nav--prev svg { transform: rotate(180deg); }
.programs__nav:disabled { opacity: .35; cursor: not-allowed; }
.programs__track { cursor: grab; overscroll-behavior-inline: contain; touch-action: pan-x pan-y; }
.programs__track.is-dragging { cursor: grabbing; user-select: none; scroll-snap-type: none; }
.program-card__fallback {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 80% 18%, rgba(255,255,255,.32), transparent 28%),
    linear-gradient(135deg, #7050a2 0%, #3f2b68 48%, #171527 100%);
}
.program-card--fallback-2 .program-card__fallback { background: radial-gradient(circle at 75% 20%, rgba(255,255,255,.28), transparent 30%), linear-gradient(135deg, #149d9a, #356879 52%, #14252d); }
.program-card--fallback-3 .program-card__fallback { background: radial-gradient(circle at 78% 18%, rgba(255,255,255,.3), transparent 30%), linear-gradient(135deg, #e45f9b, #7e3f8c 55%, #2e1b42); }
.program-card__media[aria-hidden="true"]::before { background: linear-gradient(90deg, rgba(12,13,27,.92), rgba(12,13,27,.45) 64%, rgba(12,13,27,.08)); }
.program-archive__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; }
.program-archive .program-card { min-width: 0; }

.home-experts { background: linear-gradient(180deg, #fff, #faf8fc); }
.home-experts__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem; }
.home-expert { overflow: hidden; border: 1px solid var(--color-line); border-radius: var(--radius); background: #fff; }
.home-expert__image { aspect-ratio: 4 / 5; overflow: hidden; background: var(--color-surface); }
.home-expert__image img, .home-expert__image > span { display: block; width: 100%; height: 100%; object-fit: cover; object-position: var(--keb-expert-focus, 50% 20%); }
.home-expert__body { padding: 1.25rem; }
.home-expert__body h3 { margin: 0 0 .35rem; font-size: 1.15rem; }
.home-expert__body p { margin: 0; color: var(--color-ink-soft); }

.news-card__more { width: auto; min-width: 38px; padding-inline: .7rem; gap: .45rem; border-radius: 999px; text-decoration: none; }
.news-card__more-label { font-size: .82rem; font-weight: 650; white-space: nowrap; }
.news-card:focus-within { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.news-card:focus-within .news-card__more { background: var(--grad-brand); color: #fff; border-color: transparent; }
.herflow-card__more { display: inline-flex; align-items: center; gap: .35rem; }
.herflow-card__link:focus-visible .herflow-card__more,
.herflow-card__link:hover .herflow-card__more { color: var(--c-purple); text-decoration: underline; text-underline-offset: .2em; }

.brand--custom-logo .custom-logo-link { display: block; }
.brand--custom-logo .custom-logo { display: block; width: auto; height: clamp(46px, 4.2vw, 66px); max-width: min(250px, 31vw); object-fit: contain; }
.site-footer .brand--custom-logo .custom-logo { max-width: min(290px, 70vw); }

@media (max-width: 900px) {
  .home-experts__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .program-archive__grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .home-experts__grid { grid-template-columns: 1fr; }
  .programs { padding-inline: 1rem; }
  .programs__track { grid-auto-columns: minmax(270px, 88vw); }
  .program-card, .program-card__content { min-height: 430px; }
  .program-card__content { max-width: 94%; }
  .brand--custom-logo .custom-logo { max-width: 48vw; height: 48px; }
}
@media (hover: none) {
  .news-card__more-label { display: inline; }
}
