/*
Theme Name: Madison Livingston Academic Blog
Theme URI: https://example.com/madison-livingston-academic-blog
Author: OpenAI
Description: Editable block-based WordPress theme for Madison Livingston. Pages, posts, media, press cards, resource links, and the homepage are all editable directly in WordPress.
Version: 2.1.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: madison-livingston
Tags: blog, education, accessibility, full-site-editing, block-patterns, custom-logo, featured-images
*/

:root {
  --ml-cream: #fbf7ea;
  --ml-paper: #fffdf7;
  --ml-blush: #f8c8c8;
  --ml-pink: #f8acc0;
  --ml-rose: #d03048;
  --ml-burgundy: #880818;
  --ml-wine: #702030;
  --ml-navy: #151b3a;
  --ml-teal: #b8c8d0;
  --ml-ink-soft: #30334c;
  --ml-border: rgba(112, 32, 48, 0.14);
  --ml-shadow: 0 20px 50px rgba(112, 32, 48, 0.13);
  --ml-radius-lg: 34px;
  --ml-radius-md: 22px;
  --ml-max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ml-cream);
  color: var(--ml-navy);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  font-size: 17px;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ml-burgundy); text-underline-offset: 0.18em; }
a:hover { color: var(--ml-wine); }

h1, h2, h3, h4, .wp-block-site-title {
  font-family: Georgia, "Times New Roman", serif;
  letter-spacing: -0.045em;
  line-height: 1.05;
}
h1, h2, h3 { margin-top: 0; }
p { margin-top: 0; }

.wp-site-blocks { background: var(--ml-cream); min-height: 100vh; }
.ml-wrap {
  width: min(var(--ml-max), calc(100% - 48px));
  margin-inline: auto;
}
.ml-section { padding: clamp(66px, 8vw, 110px) 0; }
.ml-main-content { min-height: 60vh; }

/* Header / navigation */
.ml-topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 247, 234, 0.94);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(112, 32, 48, 0.09);
}
body.admin-bar .ml-topbar { top: 32px; }
@media (max-width: 782px) { body.admin-bar .ml-topbar { top: 46px; } }
.ml-nav {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding-block: 12px;
}
.ml-brand { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.ml-brand .wp-block-site-logo img { width: 54px; height: 54px; object-fit: contain; }
.ml-brand .wp-block-site-title { margin: 0; font-size: clamp(1.7rem, 3vw, 2.35rem); font-weight: 700; }
.ml-brand .wp-block-site-title a { color: var(--ml-navy); text-decoration: none; }
.ml-nav-right { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; justify-content: flex-end; }
.wp-block-navigation a { color: var(--ml-navy); font-weight: 740; text-decoration: none; }
.wp-block-navigation a:hover { color: var(--ml-burgundy); text-decoration: underline; text-underline-offset: 0.32em; }
.wp-block-navigation__submenu-container { border-color: var(--ml-border) !important; border-radius: 16px; box-shadow: var(--ml-shadow); overflow: hidden; }
.wp-block-social-links .wp-social-link { background: var(--ml-paper) !important; color: var(--ml-burgundy) !important; border: 1px solid var(--ml-border); }

/* Buttons */
.ml-button,
.wp-block-button__link,
.wp-block-file__button,
button[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--ml-burgundy);
  color: #ffffff !important;
  border-radius: 999px;
  border: 2px solid var(--ml-burgundy);
  padding: 13px 20px;
  font-weight: 760;
  text-decoration: none;
  box-shadow: 0 12px 28px rgba(136, 8, 24, 0.18);
  cursor: pointer;
}
.ml-button:hover,
.wp-block-button__link:hover,
.wp-block-file__button:hover,
button[type="submit"]:hover { background: var(--ml-wine); border-color: var(--ml-wine); transform: translateY(-1px); }
.ml-button-secondary,
.is-style-outline .wp-block-button__link {
  background: transparent !important;
  color: var(--ml-burgundy) !important;
  border-color: var(--ml-burgundy) !important;
  box-shadow: none;
}
.ml-button-row, .wp-block-buttons { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

/* Hero */
.ml-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(70px, 10vw, 130px) 0 clamp(60px, 8vw, 95px);
  background: var(--ml-cream);
  isolation: isolate;
}
.ml-hero::before {
  content: "";
  position: absolute;
  width: min(58vw, 790px);
  height: min(58vw, 790px);
  border-radius: 50%;
  background: var(--ml-pink);
  right: -170px;
  top: -240px;
  opacity: 0.65;
  z-index: -1;
  pointer-events: none;
}
.ml-hero::after {
  content: "";
  position: absolute;
  width: min(38vw, 520px);
  height: min(38vw, 520px);
  border-radius: 50%;
  background: var(--ml-blush);
  left: -190px;
  bottom: -250px;
  opacity: 0.85;
  z-index: -1;
  pointer-events: none;
}
.ml-hero-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(42px, 7vw, 86px);
  align-items: center;
}
.ml-eyebrow,
.ml-card-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(248, 200, 200, 0.72);
  color: var(--ml-wine);
  font-weight: 760;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  font-size: 0.78rem;
}
.ml-eyebrow::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--ml-burgundy);
}
.ml-hero-copy h1, .ml-hero-copy .wp-block-heading {
  margin-top: 20px;
  font-size: clamp(3.25rem, 8.2vw, 7.3rem);
  color: var(--ml-navy);
}
.ml-hero-copy p {
  margin-top: 24px;
  font-size: clamp(1.05rem, 1.5vw, 1.3rem);
  color: var(--ml-ink-soft);
  max-width: 56ch;
}
.ml-hero-photo-card {
  position: relative;
  min-height: 460px;
  border-radius: 46px;
  overflow: hidden;
  box-shadow: var(--ml-shadow);
  border: 1px solid rgba(112, 32, 48, 0.14);
  background: var(--ml-paper);
}
.ml-hero-photo-card figure, .ml-hero-photo-card .wp-block-image { margin: 0; height: 100%; }
.ml-hero-photo-card img { width: 100%; height: 100%; min-height: 460px; object-fit: cover; }
.ml-hero-badge {
  position: absolute;
  left: 24px;
  bottom: 24px;
  right: 24px;
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 14px;
  align-items: center;
  background: rgba(255, 253, 247, 0.92);
  border-radius: 22px;
  padding: 12px 16px;
  box-shadow: 0 16px 34px rgba(21, 27, 58, 0.16);
  font-weight: 780;
  color: var(--ml-wine);
}
.ml-hero-badge img { width: 56px; height: 56px; object-fit: contain; min-height: 0; }

/* Section heads */
.ml-section-head {
  display: flex;
  justify-content: space-between;
  gap: 28px;
  align-items: end;
  margin-bottom: 34px;
}
.ml-section-head h2, .ml-section-head .wp-block-heading {
  font-size: clamp(2.2rem, 5vw, 4.35rem);
  color: var(--ml-wine);
  max-width: 780px;
}
.ml-section-head p { max-width: 440px; margin: 0; color: var(--ml-ink-soft); }

/* Research / cards */
.ml-research {
  background: var(--ml-paper);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.ml-research::before {
  content: "";
  position: absolute;
  width: 540px;
  height: 540px;
  border-radius: 50%;
  background: var(--ml-blush);
  left: -180px;
  top: 70px;
  opacity: 0.55;
  z-index: -1;
  pointer-events: none;
}
.ml-pub-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}
.ml-pub {
  background: var(--ml-cream);
  border: 1px solid rgba(112, 32, 48, 0.14);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(112, 32, 48, 0.08);
}
.ml-pub figure, .ml-pub .wp-block-image { margin: 0; }
.ml-pub img { width: 100%; aspect-ratio: 1 / 0.78; object-fit: cover; }
.ml-pub-body { padding: 18px; }
.ml-pub-body h3, .ml-pub-body .wp-block-heading { font-size: 1.25rem; color: var(--ml-navy); margin: 0; }
.ml-pub-body p { margin: 10px 0 16px; font-size: 0.95rem; color: var(--ml-ink-soft); }
.ml-pub-body a { font-weight: 780; color: var(--ml-burgundy); text-decoration-thickness: 2px; text-underline-offset: 4px; }

/* Home about */
.ml-home-about { background: linear-gradient(135deg, var(--ml-cream), #fff4f5); }
.ml-home-about-grid {
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  gap: clamp(34px, 6vw, 78px);
  align-items: center;
}
.ml-home-about-image {
  background: var(--ml-blush);
  border-radius: 42px;
  padding: 18px;
  box-shadow: var(--ml-shadow);
}
.ml-home-about-image img { border-radius: 30px; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.ml-home-about-copy h2 { font-size: clamp(2.2rem, 4.5vw, 4.6rem); color: var(--ml-navy); }
.ml-home-about-copy p { color: var(--ml-ink-soft); font-size: 1.05rem; max-width: 68ch; }

/* Press */
.ml-press-preview,
.ml-press-page-list { background: var(--ml-cream); position: relative; overflow: hidden; isolation: isolate; }
.ml-press-preview::before {
  content: "";
  position: absolute;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: var(--ml-pink);
  right: -200px;
  top: -160px;
  opacity: 0.38;
  z-index: -1;
}
.ml-press-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.ml-press-card {
  background: var(--ml-paper);
  border: 1px solid var(--ml-border);
  border-radius: 26px;
  box-shadow: 0 12px 30px rgba(112, 32, 48, 0.08);
  padding: 24px;
  min-height: 260px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.ml-press-card h3 { color: var(--ml-navy); font-size: 1.45rem; margin: 10px 0 10px; }
.ml-press-card p { color: var(--ml-ink-soft); }
.ml-press-meta { color: var(--ml-wine); font-weight: 780; font-size: 0.86rem; text-transform: uppercase; letter-spacing: 0.05em; }
.ml-press-bottom { margin-top: 18px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ml-press-bottom span { font-size: 0.82rem; color: var(--ml-ink-soft); }
.ml-press-bottom a { font-weight: 780; }
.ml-press-action, .ml-blog-preview-action { margin-top: 28px; }
.ml-press-hero {
  background: var(--ml-wine);
  color: #fff;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.ml-press-hero::before {
  content: "";
  position: absolute;
  width: 540px;
  height: 540px;
  border-radius: 50%;
  background: var(--ml-pink);
  right: -190px;
  top: -260px;
  opacity: 0.45;
  z-index: -1;
}
.ml-press-hero h1, .ml-press-hero p, .ml-press-hero .ml-eyebrow { color: #fff; }
.ml-press-hero .ml-eyebrow { background: rgba(255,255,255,0.12); }
.ml-press-hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 44px; align-items: center; }
.ml-press-hero h1 { font-size: clamp(3rem, 7vw, 6.6rem); margin: 18px 0; }
.ml-press-hero p { font-size: 1.15rem; max-width: 62ch; }
.ml-press-hero-image img { border-radius: 38px; box-shadow: 0 22px 48px rgba(0,0,0,0.22); width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }

/* Latest posts and blog query */
.ml-blog-preview { background: var(--ml-paper); }
.ml-feature-posts,
.ml-blog-post-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.ml-blog-post-list { grid-template-columns: 1fr; gap: 0; }
.ml-feature-post,
.ml-blog-card {
  background: var(--ml-cream);
  border: 1px solid var(--ml-border);
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(112, 32, 48, 0.08);
  display: grid;
  grid-template-columns: 0.95fr 1fr;
  gap: 0;
  min-height: 280px;
}
.ml-feature-post figure,
.ml-blog-card figure { margin: 0; height: 100%; }
.ml-feature-post img,
.ml-blog-card img { width: 100%; height: 100%; min-height: 280px; object-fit: cover; }
.ml-feature-post-body,
.ml-blog-copy { padding: 24px; display: flex; flex-direction: column; justify-content: center; }
.ml-feature-post h3,
.ml-feature-post .wp-block-post-title,
.ml-blog-copy h2,
.ml-blog-copy .wp-block-post-title { font-size: clamp(1.7rem, 3vw, 2.5rem); color: var(--ml-navy); margin: 8px 0 12px; }
.ml-feature-post .wp-block-post-title a,
.ml-blog-copy .wp-block-post-title a { color: var(--ml-navy); text-decoration: none; }
.ml-feature-post .wp-block-post-title a:hover,
.ml-blog-copy .wp-block-post-title a:hover { color: var(--ml-burgundy); text-decoration: underline; }
.ml-feature-post p,
.ml-feature-post .wp-block-post-excerpt,
.ml-blog-copy p,
.ml-blog-copy .wp-block-post-excerpt { color: var(--ml-ink-soft); }
.ml-blog-page { background: var(--ml-paper); }
.ml-page-title { font-size: clamp(3.2rem, 7vw, 6.6rem); color: var(--ml-navy); margin-bottom: 50px; }
.ml-blog-card {
  display: grid;
  grid-template-columns: 0.9fr 1fr;
  gap: clamp(34px, 6vw, 78px);
  align-items: center;
  padding: 24px 0 54px;
  border: 0;
  border-bottom: 1px solid rgba(21, 27, 58, 0.12);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  min-height: 0;
}
.ml-blog-card img { aspect-ratio: 1.05 / 1; min-height: 0; }
.ml-blog-copy { padding: 0; }
.ml-blog-copy .wp-block-post-date { font-size: 1.15rem; margin-bottom: 18px; color: var(--ml-navy); }
.ml-blog-copy .wp-block-post-title { font-size: clamp(2.4rem, 5.6vw, 5.3rem); font-weight: 500; line-height: 1.05; margin: 0; }
.ml-blog-copy .wp-block-post-excerpt { max-width: 56ch; margin: 26px 0 28px; }
.ml-blog-copy .wp-block-read-more { font-size: 1.15rem; font-weight: 700; text-decoration-thickness: 2px; text-underline-offset: 6px; }

/* Contact */
.ml-conversation { background: linear-gradient(135deg, var(--ml-cream), var(--ml-blush)); }
.ml-contact-panel {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 28px;
  background: var(--ml-paper);
  border-radius: var(--ml-radius-lg);
  box-shadow: var(--ml-shadow);
  border: 1px solid rgba(112, 32, 48, 0.12);
  padding: clamp(24px, 4vw, 46px);
}
.ml-contact-panel h2 { font-size: clamp(2.2rem, 4vw, 3.8rem); color: var(--ml-wine); }
.ml-contact-panel p { color: var(--ml-ink-soft); }
.ml-contact-panel input,
.ml-contact-panel textarea,
.wp-block-jetpack-field input,
.wp-block-jetpack-field textarea,
.wp-block-jetpack-field select {
  width: 100%;
  border: 1.5px solid rgba(21, 27, 58, 0.18);
  border-radius: 15px;
  background: #ffffff;
  padding: 14px 15px;
  font: inherit;
  color: var(--ml-navy);
}
.ml-contact-panel textarea,
.wp-block-jetpack-field textarea { min-height: 140px; }
.ml-small-contact { font-size: 0.96rem; }

/* About */
.ml-about { position: relative; overflow: hidden; isolation: isolate; }
.ml-about::after {
  content: "";
  position: absolute;
  width: 620px;
  height: 620px;
  border-radius: 50%;
  background: var(--ml-burgundy);
  right: -260px;
  top: 70px;
  opacity: 0.08;
  z-index: -1;
}
.ml-about-layout {
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  gap: clamp(32px, 6vw, 74px);
  align-items: start;
}
.ml-about-photo-stack { display: grid; gap: 18px; }
.ml-about-portrait img, .ml-about-portrait { border-radius: 40px; box-shadow: var(--ml-shadow); width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.ml-about-mini-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.ml-about-mini-grid img { border-radius: 24px; aspect-ratio: 1 / 0.95; width: 100%; object-fit: cover; }
.ml-about-rich-copy h1 { font-size: clamp(2.6rem, 5.6vw, 5.4rem); color: var(--ml-navy); margin: 18px 0 20px; }
.ml-about-rich-copy p { font-size: 1.05rem; color: var(--ml-ink-soft); max-width: 76ch; }
.ml-milestones { background: var(--ml-paper); }
.ml-milestone-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.ml-milestone { background: var(--ml-cream); border: 1px solid var(--ml-border); border-radius: 26px; padding: 24px; box-shadow: 0 12px 28px rgba(112, 32, 48, 0.07); }
.ml-milestone h3 { color: var(--ml-wine); font-size: 1.35rem; }
.ml-photo-band { background: linear-gradient(135deg, var(--ml-blush), var(--ml-pink)); }
.ml-photo-band-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.ml-photo-band-grid img { border-radius: 26px; aspect-ratio: 4 / 3; object-fit: cover; width: 100%; box-shadow: var(--ml-shadow); }

/* Consulting */
.ml-consulting { background: var(--ml-wine); color: #fff; position: relative; overflow: hidden; isolation: isolate; }
.ml-consulting::before {
  content: "";
  position: absolute;
  width: 520px;
  height: 520px;
  background: var(--ml-pink);
  border-radius: 50%;
  right: -150px;
  top: -230px;
  opacity: 0.4;
  z-index: -1;
}
.ml-consulting h1, .ml-consulting h2, .ml-consulting h3, .ml-consulting p { color: #fff; }
.ml-consulting .ml-eyebrow { background: rgba(255,255,255,0.12); color: #fff; }
.ml-consulting-grid { display: grid; grid-template-columns: 1fr 0.9fr; gap: 42px; align-items: center; }
.ml-consulting-image img { border-radius: 38px; box-shadow: 0 22px 48px rgba(0,0,0,0.24); aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.ml-service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.ml-service { background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.18); border-radius: 26px; padding: 26px; }
.ml-service h3 { font-size: 1.55rem; }

/* Posts / pages */
.ml-post-shell { background: var(--ml-paper); }
.ml-post-content { width: min(860px, calc(100% - 48px)); margin: 0 auto; padding: clamp(56px, 7vw, 92px) 0; }
.ml-post-content h1 { font-size: clamp(2.8rem, 7vw, 5.4rem); color: var(--ml-navy); margin-bottom: 8px; }
.ml-date, .wp-block-post-date { color: var(--ml-wine); font-weight: 760; }
.ml-post-featured img, .wp-block-post-featured-image img { border-radius: 30px; box-shadow: var(--ml-shadow); }
.ml-page-copy p,
.ml-post-content p,
.ml-post-content li { font-size: 1.06rem; color: var(--ml-ink-soft); }
.ml-page-copy h2,
.ml-post-content h2 { color: var(--ml-wine); font-size: clamp(2rem, 4vw, 3.2rem); margin-top: 42px; }
.ml-resource-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 30px; }
.ml-resource-card { background: var(--ml-cream); border: 1px solid var(--ml-border); border-radius: 26px; padding: 22px; box-shadow: 0 12px 30px rgba(112, 32, 48, 0.08); }
.wp-block-file { background: var(--ml-cream); border: 1px solid var(--ml-border); border-radius: 24px; padding: 18px; box-shadow: 0 12px 30px rgba(112, 32, 48, 0.08); }
.wp-block-file object { border-radius: 16px; background: #fff; }
.wp-block-file a:not(.wp-block-file__button) { font-weight: 780; color: var(--ml-navy); }

/* Footer */
.ml-footer { background: var(--ml-teal); padding: 34px 0; color: var(--ml-navy); }
.ml-footer-grid { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; }
.ml-footer strong, .ml-footer .wp-block-site-title { font-family: Georgia, "Times New Roman", serif; font-size: 1.4rem; }
.ml-footer-links { display: flex; gap: 16px; flex-wrap: wrap; justify-content: flex-end; }
.ml-footer a { color: var(--ml-navy); font-weight: 700; }

/* Editor friendliness */
.block-editor-block-list__layout .ml-wrap { width: 100%; }
.block-editor-block-list__layout .ml-hero::before,
.block-editor-block-list__layout .ml-hero::after,
.block-editor-block-list__layout .ml-research::before { pointer-events: none; }

/* Responsive */
@media (max-width: 1080px) {
  .ml-pub-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ml-milestone-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ml-press-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .ml-nav { align-items: flex-start; flex-direction: column; }
  .ml-nav-right { justify-content: flex-start; }
  .ml-hero-grid,
  .ml-home-about-grid,
  .ml-contact-panel,
  .ml-about-layout,
  .ml-consulting-grid,
  .ml-press-hero-grid,
  .ml-blog-card { grid-template-columns: 1fr; }
  .ml-section-head { display: block; }
  .ml-section-head p { margin-top: 14px; }
  .ml-feature-posts { grid-template-columns: 1fr; }
  .ml-feature-post { grid-template-columns: 1fr; }
  .ml-service-grid { grid-template-columns: 1fr; }
  .ml-footer-grid { grid-template-columns: 1fr; }
  .ml-footer-links { justify-content: flex-start; }
}
@media (max-width: 620px) {
  .ml-wrap,
  .ml-post-content { width: min(100% - 30px, var(--ml-max)); }
  .ml-brand .wp-block-site-logo img { width: 42px; height: 42px; }
  .ml-hero-photo-card { min-height: 330px; }
  .ml-hero-photo-card img { min-height: 330px; }
  .ml-pub-grid,
  .ml-press-grid,
  .ml-milestone-grid,
  .ml-photo-band-grid,
  .ml-resource-grid { grid-template-columns: 1fr; }
  .ml-hero-copy h1 { font-size: clamp(3rem, 15vw, 4.4rem); }
}


/* v2.1.0 sizing corrections
   These rules keep editable WordPress blocks from expanding, stretching, or
   cropping unpredictably while preserving the original visual direction. */
.wp-site-blocks > * {
  margin-block-start: 0;
}
.wp-site-blocks > * + * {
  margin-block-start: 0;
}
:where(.ml-section.alignfull, .ml-hero.alignfull, .ml-footer, .ml-topbar) {
  width: 100%;
  max-width: 100%;
}
.ml-wrap {
  max-width: var(--ml-max);
  width: min(var(--ml-max), calc(100% - clamp(30px, 5vw, 64px)));
}
.wp-block-image,
.wp-block-post-featured-image {
  max-width: 100%;
}
.wp-block-image img,
.wp-block-post-featured-image img {
  display: block;
  max-width: 100%;
}

/* Header sizing */
.ml-brand {
  min-width: 0;
}
.ml-brand .wp-block-site-logo,
.ml-brand .wp-block-site-logo a {
  flex: 0 0 auto;
  width: 54px;
  height: 54px;
}
.ml-brand .wp-block-site-logo img {
  width: 54px !important;
  height: 54px !important;
  object-fit: contain;
}
.ml-nav-right {
  min-width: 0;
}

/* Hero sizing */
.ml-hero-copy h1,
.ml-hero-copy .wp-block-heading {
  font-size: clamp(3rem, 7vw, 6.25rem);
}
.ml-hero-photo-card {
  display: grid;
  min-height: 0;
  aspect-ratio: 4 / 3;
  max-height: 620px;
}
.ml-hero-photo-card > .wp-block-image,
.ml-hero-photo-card > figure {
  grid-area: 1 / 1;
  width: 100%;
  height: 100%;
  margin: 0;
}
.ml-hero-photo-card > .wp-block-image img,
.ml-hero-photo-card > figure img {
  width: 100%;
  height: 100% !important;
  min-height: 0 !important;
  object-fit: cover;
}
.ml-hero-badge {
  z-index: 3;
  max-width: calc(100% - 48px);
}
.ml-hero-badge > .wp-block-image,
.ml-heart-icon {
  width: 56px !important;
  height: 56px !important;
  margin: 0;
}
.ml-hero-badge img,
.ml-heart-icon img {
  width: 56px !important;
  height: 56px !important;
  min-height: 0 !important;
  aspect-ratio: 1 / 1 !important;
  object-fit: contain !important;
}

/* Card/image sizing */
.ml-pub-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 235px), 1fr));
}
.ml-pub {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.ml-pub > .wp-block-image,
.ml-pub > figure {
  width: 100%;
  margin: 0;
  background: #ffffff;
}
.ml-pub > .wp-block-image img,
.ml-pub > figure img {
  width: 100%;
  height: clamp(180px, 18vw, 240px) !important;
  min-height: 0 !important;
  aspect-ratio: auto;
  object-fit: cover;
}
.ml-pub-body {
  flex: 1 1 auto;
}
.ml-press-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}
.ml-press-card {
  min-height: 0;
  height: auto;
}
.ml-milestone-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}
.ml-photo-band-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
}
.ml-photo-band-grid .wp-block-image,
.ml-photo-band-grid figure {
  margin: 0;
}
.ml-photo-band-grid img {
  width: 100%;
  height: auto !important;
  min-height: 0 !important;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

/* Homepage latest posts: stable, editable card layout */
.ml-feature-posts {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  align-items: stretch;
}
.ml-feature-post {
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
}
.ml-feature-post .wp-block-post-featured-image,
.ml-feature-post-image {
  width: 100%;
  height: auto;
  margin: 0;
}
.ml-feature-post .wp-block-post-featured-image img,
.ml-feature-post-image img {
  width: 100%;
  height: clamp(220px, 25vw, 330px) !important;
  min-height: 0 !important;
  aspect-ratio: auto;
  object-fit: cover;
  border-radius: 0;
  box-shadow: none;
}
.ml-feature-post-body {
  flex: 1 1 auto;
  padding: clamp(20px, 3vw, 28px);
}

/* Blog page list sizing */
.ml-blog-card {
  grid-template-columns: minmax(260px, 0.85fr) minmax(0, 1fr);
}
.ml-blog-card .wp-block-post-featured-image,
.ml-blog-thumb {
  width: 100%;
  margin: 0;
}
.ml-blog-card .wp-block-post-featured-image img,
.ml-blog-thumb img {
  width: 100%;
  height: auto !important;
  min-height: 0 !important;
  aspect-ratio: 1.05 / 1;
  object-fit: cover;
  border-radius: 0;
  box-shadow: none;
}
.ml-blog-copy {
  min-width: 0;
}

/* About and consulting image sizing */
.ml-home-about-image .wp-block-image,
.ml-about-photo-stack .wp-block-image,
.ml-about-mini-grid .wp-block-image,
.ml-consulting-image .wp-block-image,
.ml-press-hero-image .wp-block-image {
  margin: 0;
  width: 100%;
}
.ml-home-about-image img,
.ml-about-portrait img,
.ml-consulting-image img,
.ml-press-hero-image img {
  width: 100%;
  height: auto !important;
  min-height: 0 !important;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}
.ml-consulting-image img,
.ml-press-hero-image img {
  aspect-ratio: 4 / 3;
}
.ml-about-mini-grid img {
  width: 100%;
  height: auto !important;
  min-height: 0 !important;
  aspect-ratio: 1 / 0.95;
  object-fit: cover;
}

/* File/PDF resource blocks */
.wp-block-file object,
.wp-block-file__embed {
  width: 100% !important;
  max-width: 100% !important;
  height: clamp(260px, 38vw, 420px) !important;
}
.ml-resource-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}

/* Contact form sizing */
.wp-block-jetpack-contact-form,
.ml-contact-panel form {
  width: 100%;
}
.wp-block-jetpack-contact-form > * {
  max-width: 100%;
}

@media (max-width: 900px) {
  .ml-hero-photo-card {
    aspect-ratio: 16 / 10;
  }
  .ml-blog-card {
    grid-template-columns: 1fr;
    gap: 22px;
    padding-bottom: 44px;
  }
  .ml-blog-card .wp-block-post-featured-image img,
  .ml-blog-thumb img {
    aspect-ratio: 16 / 10;
  }
}
@media (max-width: 620px) {
  .ml-section {
    padding: 54px 0;
  }
  .ml-nav {
    gap: 16px;
  }
  .ml-hero-photo-card {
    aspect-ratio: 4 / 3;
  }
  .ml-hero-badge {
    left: 14px;
    right: 14px;
    bottom: 14px;
    max-width: calc(100% - 28px);
    grid-template-columns: 46px 1fr;
  }
  .ml-hero-badge > .wp-block-image,
  .ml-heart-icon,
  .ml-hero-badge img,
  .ml-heart-icon img {
    width: 46px !important;
    height: 46px !important;
  }
  .ml-feature-post .wp-block-post-featured-image img,
  .ml-feature-post-image img,
  .ml-pub > .wp-block-image img,
  .ml-pub > figure img {
    height: auto !important;
    aspect-ratio: 16 / 10;
  }
}
