/* =========================================================
   ScrumCraft header menu
   Appearance > Customise > Additional CSS
   Replace everything in Additional CSS with this block.
   ========================================================= */

/* 1. Services and Community link to sections of the home page, so
      WordPress marks them as the current page there. Show them normally. */
.main-navigation > div > ul > li.menu-item-has-children.current-menu-item > a {
  color: #3a2359 !important;
  text-decoration: none !important;
  border-bottom: 0 !important;
  box-shadow: none !important;
}
.main-navigation > div > ul > li.menu-item-has-children.current-menu-item > a:hover {
  color: #692fb9 !important;
}

/* 2. "Book a chat" as a pink button.
      Give that menu item the CSS class: sc-nav-cta */
.main-navigation .sc-nav-cta > a {
  margin-left: 8px;
  padding: 12px 22px !important;
  border-radius: 999px;
  background: #ed174c;
  color: #ffffff !important;
  font-weight: 700;
  line-height: 1.2 !important;
  text-decoration: none !important;
}
.main-navigation .sc-nav-cta > a:hover {
  background: #d2143f;
}

/* 3. Dropdown panels */

/* Remove the theme's dashes */
.main-navigation .sub-menu .menu-item a::before {
  content: none !important;
  counter-increment: none !important;
}

@media only screen and (min-width: 560px) {
  /* Open each dropdown right under its own menu item */
  .main-navigation > div > ul > li {
    position: relative !important;
  }
  .main-navigation > div > ul > li > .sub-menu {
    display: block !important;
    left: auto !important;
    right: 0 !important;
    top: 100% !important;
    width: max-content;
    min-width: 220px;
    max-width: 340px;
    margin-top: 6px !important;
    padding: 14px !important;
    border: 1px solid #eee6f4;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 28px 56px -24px rgba(62, 34, 92, .4) !important;
    /* Closed: hidden. It waits only a short grace period before closing,
       long enough for the pointer to reach the panel */
    visibility: hidden !important;
    opacity: 0 !important;
    transform: translateY(8px);
    transition: opacity .14s ease .18s, transform .14s ease .18s, visibility 0s linear .32s !important;
  }
  /* An invisible margin around the open panel: it covers the gap under
     the menu item and forgives the pointer drifting a little past the
     panel's edges, so the panel doesn't close by accident */
  .main-navigation > div > ul > li > .sub-menu::before {
    content: "";
    position: absolute;
    z-index: -1;
    top: -10px; left: -16px; right: -16px; bottom: -24px;
  }
  /* Open: straight away on hover or keyboard focus */
  .main-navigation > div > ul > li:hover > .sub-menu,
  .main-navigation > div > ul > li:focus-within > .sub-menu {
    visibility: visible !important;
    opacity: 1 !important;
    transform: none;
    transition: opacity .14s ease, transform .18s cubic-bezier(.22, .9, .3, 1), visibility 0s !important;
  }
  /* Moving onto another menu item that has its own dropdown
     closes the previous panel quickly */
  .main-navigation > div > ul:has(> li.menu-item-has-children:hover) > li:not(:hover):not(:focus-within) > .sub-menu {
    transition-delay: 0s, 0s, .1s !important;
    transition-duration: .1s, .1s, 0s !important;
  }
  .main-navigation > div > ul > li > .sub-menu li {
    width: auto;
  }
  /* the menu link stays above everything else in the bar, so it always takes the hover */
  .main-navigation > div > ul > li > a {
    position: relative;
    z-index: 3;
  }
}

/* Every dropdown link: smaller, calmer text */
.main-navigation .sub-menu .menu-item a {
  padding: 8px 12px !important;
  border-radius: 10px;
  font-size: 15px !important;
  font-weight: 600 !important;
  line-height: 1.35 !important;
  color: #3a2359 !important;
  text-decoration: none !important;
}
.main-navigation .sub-menu .menu-item a:hover {
  background: #f6f1fa;
  color: #692fb9 !important;
}

/* First level inside a dropdown, e.g. Training, Consulting, About */
.main-navigation > div > ul > li > .sub-menu > li.menu-item > a {
  font-size: 16px !important;
  font-weight: 700 !important;
}
.main-navigation > div > ul > li > .sub-menu > li.menu-item-has-children > a {
  font-weight: 800 !important;
}

/* Lists inside a dropdown (training types, then courses):
   indent the whole group and tie it to its heading with a line */
.main-navigation .sub-menu .sub-menu {
  margin: 2px 0 8px 14px !important;
  padding: 0 0 0 10px !important;
  border-left: 2px solid #eee6f4;
}

/* Training types, e.g. Instructor-led training */
.main-navigation .sub-menu .sub-menu > li > a {
  font-size: 15px !important;
  font-weight: 700 !important;
}

/* Individual courses */
.main-navigation .sub-menu .sub-menu .sub-menu > li > a {
  padding-top: 6px !important;
  padding-bottom: 6px !important;
  font-size: 14.5px !important;
  font-weight: 500 !important;
  color: #584a68 !important;
}

/* 4. Services: Training on the left, the other services on the right,
      on wider screens. Found by its shape (the only dropdown with lists
      inside it), so it keeps working wherever Services sits in the menu */
@media only screen and (min-width: 1000px) {
  .main-navigation > div > ul > li:has(> .sub-menu .sub-menu) > .sub-menu {
    display: grid !important;
    grid-template-columns: 330px 210px;
    column-gap: 18px;
    max-width: none;
    align-items: start;
  }
  .main-navigation > div > ul > li:has(> .sub-menu .sub-menu) > .sub-menu > li:first-child {
    grid-row: span 20;
    padding-right: 18px;
    border-right: 1px solid #eee6f4;
  }
}

/* 5. A compact header on every page: a smaller logo and less padding,
      so the top of each page shows more content */
@media only screen and (min-width: 560px) {
  :is(#masthead, .site-header, #site-header) {
    padding-top: 16px !important;
    padding-bottom: 16px !important;
  }
  :is(#masthead, .site-header, #site-header) :is(.custom-logo, .site-logo img, .wp-block-site-logo img) {
    max-height: 76px !important;
    width: auto !important;
    height: auto !important;
  }
}

/* 6. Readable text on blog pages (posts, blog list, archives, search, 404).
      The theme's Foreground colour is white, the same as the background.
      Pages rely on that white inside their dark sections, so Foreground stays
      as it is and blog content gets ScrumCraft purple here instead. */
:is(body.single-post, body.blog, body.archive, body.search, body.error404) .site-main {
  --wp--preset--color--foreground: #3e225c;
  --wp--preset--color--foreground-low-contrast: #3e225c;
  --wp--preset--color--foreground-high-contrast: #3e225c;
  color: #3e225c;
}
/* Dark blocks inside a post keep their white text */
:is(body.single-post, body.blog, body.archive, body.search, body.error404) .site-main :is(.has-foreground-color, .has-primary-background-color, .has-primary-dark-background-color, .has-secondary-background-color, .has-black-background-color) {
  --wp--preset--color--foreground: #ffffff;
  --wp--preset--color--foreground-low-contrast: #ffffff;
  --wp--preset--color--foreground-high-contrast: #ffffff;
  color: #ffffff;
}

/* 7. Readable tables on regular pages, e.g. the course dates and prices on
      Training. These tables inherit the white Foreground colour (see section 6).
      A table given its own text colour in the editor keeps it. */
body.page .site-main .wp-block-table:not(.has-text-color) {
  color: #3e225c;
}

/* 8. Footer: the "ScrumCraft, Powered by WordPress.com" line.
      The theme prints it in the Foreground colour, which is white, so on the
      white footer it was invisible. Give it readable colours on every page. */
:is(.site-footer, #colophon, footer.wp-block-template-part) :is(.site-info, .site-name, .imprint, .footer-credit),
:is(.site-footer, #colophon, footer.wp-block-template-part) .site-info :is(p, span, div) {
  color: #665878 !important;
}
:is(.site-footer, #colophon, footer.wp-block-template-part) :is(.site-info, .site-name, .imprint, .footer-credit) a,
:is(.site-footer, #colophon, footer.wp-block-template-part) a:is(.site-name, .imprint, .footer-credit) {
  color: #692fb9 !important;
}

/* 9. Footer line: "(c) 2026 ScrumCraft Pty Ltd" instead of "ScrumCraft, Powered by WordPress.com."
      Finds the line by the WordPress credit's link address, so it works whatever
      the theme calls the footer parts. The line is forced to plain text on one row
      (the theme lays it out as separate boxes), the credit link is hidden, the loose
      comma and full stop shrink to nothing, and the copyright text is added around
      the ScrumCraft name, which still links to the home page.
      Each January, change 2026 to the new year (one place, in the ::before rule). */
:is(.site-footer, #colophon, footer) :has(> a[href*="wordpress.com/?ref=footer"], > :is(span, em, strong) > a[href*="wordpress.com/?ref=footer"]) {
  display: block !important;
  font-size: 0 !important;
  white-space: nowrap !important;
}
:is(.site-footer, #colophon, footer) :has(> a[href*="wordpress.com/?ref=footer"], > :is(span, em, strong) > a[href*="wordpress.com/?ref=footer"])::before {
  content: "\0000A9\0000A02026\0000A0";
  display: inline !important;
  font-size: 15px;
}
:is(.site-footer, #colophon, footer) :has(> a[href*="wordpress.com/?ref=footer"], > :is(span, em, strong) > a[href*="wordpress.com/?ref=footer"])::after {
  content: "\0000A0Pty\0000A0Ltd";
  display: inline !important;
  font-size: 15px;
}
:is(.site-footer, #colophon, footer) :has(> a[href*="wordpress.com/?ref=footer"], > :is(span, em, strong) > a[href*="wordpress.com/?ref=footer"]) > :not(.comma, a[href*="wordpress.com/?ref=footer"], :has(a[href*="wordpress.com/?ref=footer"])) {
  display: inline !important;
  margin: 0 !important;
  padding: 0 !important;
  font-size: 15px !important;
}
:is(.site-footer, #colophon, footer) a[href*="wordpress.com/?ref=footer"] {
  display: none !important;
}

/* 10. Header logo: the logo image has a white background baked into the file.
      On white headers it's invisible, but the header is slightly translucent,
      so over coloured sections the white box shows. Multiply blends the white
      away. The AI page manages its own logo in dark mode, so it's left alone. */
:is(#masthead, .site-header, #site-header, header.wp-block-template-part) :is(.custom-logo, .site-logo img, .wp-block-site-logo img) {
  mix-blend-mode: multiply;
}
body:has(#sc-ai[data-mode="dark"]) :is(#masthead, .site-header, #site-header, header.wp-block-template-part) :is(.custom-logo, .site-logo img, .wp-block-site-logo img) {
  mix-blend-mode: normal;
}

/* 11. Blog in the ScrumCraft style.
      The Blog page is the site's "Posts page", so WordPress builds it from the
      theme and ignores anything added in the page editor. This section styles
      what the theme prints instead. It covers the blog list, category, tag
      and search pages (11a to 11e) and tidies single posts (11f). */

/* 11a. Page canvas: the same width as the other pages, a soft wash of brand
       colour behind the top, and posts laid out as cards in two columns */
:is(body.blog, body.archive, body.search) #primary {
  position: relative;
  overflow: hidden;
  overflow: clip;
  isolation: isolate;
  font-family: "Red Hat Display", -apple-system, "Segoe UI", sans-serif;
}
:is(body.blog, body.archive, body.search) #primary::before {
  content: "";
  position: absolute;
  z-index: -1;
  left: -10%;
  right: -10%;
  top: -180px;
  height: 760px;
  pointer-events: none;
  background:
    radial-gradient(closest-side at 22% 46%, rgba(244, 127, 72, .26), rgba(244, 127, 72, 0)),
    radial-gradient(closest-side at 70% 34%, rgba(78, 193, 184, .30), rgba(78, 193, 184, 0)),
    radial-gradient(closest-side at 88% 78%, rgba(237, 23, 76, .14), rgba(237, 23, 76, 0)),
    radial-gradient(closest-side at 46% 80%, rgba(241, 238, 129, .30), rgba(241, 238, 129, 0));
  filter: blur(20px);
  -webkit-mask-image: linear-gradient(180deg, #000 0, #000 62%, rgba(0, 0, 0, 0) 100%);
  mask-image: linear-gradient(180deg, #000 0, #000 62%, rgba(0, 0, 0, 0) 100%);
}
:is(body.blog, body.archive, body.search) #main {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(16px, 1.8vw, 26px);
  box-sizing: border-box;
  max-width: 1512px;
  margin: 0 auto;
  padding: clamp(28px, 4vw, 60px) clamp(20px, 5vw, 96px) clamp(56px, 6.5vw, 104px);
}
:is(body.blog, body.archive, body.search) #main > * {
  min-width: 0;
}

/* 11b. Page heading. The blog list has no heading of its own, so one is added
       here. Category, tag and search pages already print a heading, which is
       restyled to match. */
body.blog #main::before {
  content: "Ideas from the ScrumCraft team";
  grid-column: 1 / -1;
  order: -3;
  max-width: 14ch;
  font-size: clamp(40px, 4.7vw, 70px);
  line-height: .98;
  font-weight: 800;
  letter-spacing: -.035em;
  color: #3e225c;
}
body.blog #main::after {
  content: "Practical thinking on agile, product, leadership and AI, from the people who coach and train with your teams.";
  grid-column: 1 / -1;
  order: -2;
  max-width: 54ch;
  margin: 0 0 clamp(12px, 1.6vw, 24px);
  font-size: clamp(17px, 1.3vw, 20px);
  line-height: 1.55;
  font-weight: 500;
  color: #584a68;
}
:is(body.archive, body.search) #main > .page-header {
  grid-column: 1 / -1;
  max-width: none;
  width: auto;
  margin: 0 0 clamp(8px, 1.2vw, 18px);
  padding: 0;
}
:is(body.archive, body.search) #main > .page-header .page-title {
  margin: 0;
  font-family: inherit;
  font-size: clamp(18px, 1.4vw, 21px);
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: 0;
  color: #584a68;
}
:is(body.archive, body.search) #main > .page-header .page-description {
  display: block;
  margin-top: 6px;
  font-size: clamp(40px, 4.7vw, 70px);
  line-height: .98;
  font-weight: 800;
  letter-spacing: -.035em;
  color: #3e225c;
  text-transform: capitalize;
}
:is(body.archive, body.search) #main > .page-header .page-description::first-letter {
  text-transform: uppercase;
}

/* 11c. Post cards. Each card takes one of the brand colours in turn. */
:is(body.blog, body.archive, body.search) #main > article {
  --c: #ed174c;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 0 !important;
  padding: clamp(22px, 2.4vw, 34px);
  border-radius: 28px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(62, 34, 92, .06), 0 24px 48px -32px rgba(62, 34, 92, .5);
  transition: transform .5s cubic-bezier(.22, .9, .3, 1), box-shadow .5s;
}
:is(body.blog, body.archive, body.search) #main > article:nth-of-type(4n + 2) { --c: #4ec1b8; }
:is(body.blog, body.archive, body.search) #main > article:nth-of-type(4n + 3) { --c: #f47f48; }
:is(body.blog, body.archive, body.search) #main > article:nth-of-type(4n + 4) { --c: #f1ee81; }
/* A glow of the card's colour in the corner, brighter on hover */
:is(body.blog, body.archive, body.search) #main > article::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: .5;
  background: radial-gradient(340px circle at 100% 0, color-mix(in srgb, var(--c) 34%, transparent), transparent 70%);
  transition: opacity .5s;
}
:is(body.blog, body.archive, body.search) #main > article > * {
  position: relative;
  z-index: 1;
}
:is(body.blog, body.archive, body.search) #main > article:is(:hover, :focus-within) {
  transform: translateY(-6px);
  box-shadow: 0 0 0 3px var(--c), 0 36px 60px -30px rgba(62, 34, 92, .55);
}
:is(body.blog, body.archive, body.search) #main > article:is(:hover, :focus-within)::before {
  opacity: 1;
}
/* The theme centres these parts in a 900px column. Inside a card they fill it. */
:is(body.blog, body.archive, body.search) #main > article :is(.entry-header, .entry-content, .entry-footer, .entry-content > *) {
  max-width: none;
  width: auto;
  margin: 0;
  padding: 0;
}
:is(body.blog, body.archive, body.search) #main > article .entry-title {
  margin: 0;
  font-family: inherit;
  font-size: clamp(22px, 1.9vw, 29px);
  line-height: 1.14;
  font-weight: 800;
  letter-spacing: -.02em;
  text-wrap: balance;
}
:is(body.blog, body.archive, body.search) #main > article .entry-title a {
  color: #3e225c;
  text-decoration: none;
  transition: color .3s;
}
/* The whole card opens the post */
:is(body.blog, body.archive, body.search) #main > article .entry-title a::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 28px;
}
:is(body.blog, body.archive, body.search) #main > article .entry-title a:focus-visible {
  outline: none;
}
:is(body.blog, body.archive, body.search) #main > article:has(.entry-title a:focus-visible) {
  outline: 3px solid #3e225c;
  outline-offset: 3px;
}
:is(body.blog, body.archive, body.search) #main > article .entry-header {
  position: static;
}
:is(body.blog, body.archive, body.search) #main > article .entry-content {
  flex: 1 1 auto;
}
:is(body.blog, body.archive, body.search) #main > article .entry-content > p {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  overflow: hidden;
  font-size: 16.5px;
  line-height: 1.6;
  color: #4a3d5c;
}
:is(body.blog, body.archive, body.search) #main > article .entry-content > :not(p:first-child),
:is(body.blog, body.archive, body.search) #main > article .more-link {
  display: none;
}
/* "Read the post" cue at the foot of each card */
:is(body.blog, body.archive, body.search) #main > article::after {
  content: "Read the post";
  position: relative;
  z-index: 0;
  align-self: flex-start;
  padding-right: 28px;
  font-size: 16px;
  line-height: 1.5;
  font-weight: 800;
  color: #3e225c;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%233e225c' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") no-repeat right 2px center;
  transition: padding .45s cubic-bezier(.22, .9, .3, 1);
}
:is(body.blog, body.archive, body.search) #main > article:is(:hover, :focus-within)::after {
  padding-right: 34px;
}

/* 11d. Date and topic sit above the title. Posts are shown as the team's
       work, so the single author name, the comment count and the long tag
       list are left off the cards. They still show on the post itself. */
:is(body.blog, body.archive, body.search) #main > article .entry-footer {
  order: -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  font-size: 0;
  line-height: 1;
  color: #584a68;
}
:is(body.blog, body.archive, body.search) #main > article .entry-footer :is(.byline, .comments-link, .tags-links, .edit-link, time.updated:not(.published), svg, .screen-reader-text) {
  display: none !important;
}
:is(body.blog, body.archive, body.search) #main > article .entry-footer > span {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  font-size: 0;
}
:is(body.blog, body.archive, body.search) #main > article .entry-footer a {
  position: relative;
  z-index: 2;
  text-decoration: none;
  color: #584a68;
}
:is(body.blog, body.archive, body.search) #main > article .posted-on a {
  font-size: 14px;
  line-height: 1.3;
  font-weight: 700;
}
:is(body.blog, body.archive, body.search) #main > article .cat-links a {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 13px;
  line-height: 1.3;
  font-weight: 800;
  text-transform: capitalize;
  color: #3e225c;
  background: color-mix(in srgb, var(--c) 30%, #ffffff);
  transition: background .3s;
}
:is(body.blog, body.archive, body.search) #main > article .cat-links a:hover {
  background: color-mix(in srgb, var(--c) 55%, #ffffff);
}
:is(body.blog, body.archive, body.search) #main > article .cat-links a[href*="/category/uncategorized/"] {
  display: none;
}

/* Posts saved without a title still make a tidy card. The opening lines
   stand in for the title and the date opens the post. */
:is(body.blog, body.archive, body.search) #main > article:not(:has(.entry-title)) .entry-header {
  display: none;
}
:is(body.blog, body.archive, body.search) #main > article:not(:has(.entry-title)) .entry-content > p {
  -webkit-line-clamp: 6;
  font-size: clamp(17px, 1.3vw, 19px);
  font-weight: 600;
  color: #3e225c;
}
:is(body.blog, body.archive, body.search) #main > article:not(:has(.entry-title)) :is(.entry-footer, .posted-on, .posted-on a) {
  position: static;
}
:is(body.blog, body.archive, body.search) #main > article:not(:has(.entry-title)) .posted-on a::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: 28px;
}

/* 11e. The first post on each page is the feature card, on a peach panel
       across both columns */
:is(body.blog, body.archive, body.search) #main > article:first-of-type {
  background: #fee8db;
}
:is(body.blog, body.archive, body.search) #main > article:first-of-type::before {
  background: radial-gradient(520px circle at 100% 0, rgba(255, 255, 255, .85), rgba(255, 255, 255, 0) 70%);
}
:is(body.blog, body.archive, body.search) #main > article:first-of-type .cat-links a {
  background: #ffffff;
}
@media (min-width: 761px) {
  :is(body.blog, body.archive, body.search) #main > article:first-of-type {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    grid-template-rows: auto 1fr auto;
    column-gap: clamp(28px, 4vw, 72px);
    row-gap: 14px;
    padding: clamp(28px, 3.4vw, 52px);
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type .entry-footer {
    grid-column: 1;
    grid-row: 1;
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type .entry-header {
    grid-column: 1;
    grid-row: 2 / 4;
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type .entry-title {
    font-size: clamp(30px, 3.3vw, 50px);
    line-height: 1.04;
    letter-spacing: -.03em;
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type .entry-content {
    grid-column: 2;
    grid-row: 1 / 3;
    align-self: end;
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type .entry-content > p {
    -webkit-line-clamp: 6;
    font-size: clamp(17px, 1.3vw, 19px);
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type::after {
    grid-column: 2;
    grid-row: 3;
    justify-self: start;
    padding: 13px 48px 13px 24px;
    border-radius: 999px;
    color: #ffffff;
    background: #ed174c url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") no-repeat right 20px center;
    box-shadow: 0 14px 26px -14px rgba(237, 23, 76, .8);
    transition: background-position .45s cubic-bezier(.22, .9, .3, 1);
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type:is(:hover, :focus-within)::after {
    padding-right: 48px;
    background-position: right 16px center;
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type:not(:has(.entry-title)) {
    display: flex;
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type:not(:has(.entry-title)) .entry-content {
    align-self: stretch;
  }
  :is(body.blog, body.archive, body.search) #main > article:first-of-type:not(:has(.entry-title)) .entry-content > p {
    max-width: 70ch;
    font-size: clamp(19px, 1.7vw, 24px);
    line-height: 1.45;
  }
}
@media (max-width: 760px) {
  :is(body.blog, body.archive, body.search) #main {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Page numbers as round buttons */
:is(body.blog, body.archive, body.search) #main > .navigation.pagination {
  grid-column: 1 / -1;
  max-width: none;
  width: auto;
  margin: clamp(16px, 2vw, 32px) 0 0;
  padding: 0;
}
:is(body.blog, body.archive, body.search) .pagination .nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
}
:is(body.blog, body.archive, body.search) .pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  box-sizing: border-box;
  min-width: 48px;
  height: 48px;
  font-family: inherit;
  margin: 0;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 16px;
  line-height: 1;
  font-weight: 800;
  text-decoration: none;
  color: #3e225c;
  background: #ffffff;
  box-shadow: inset 0 0 0 2px #3e225c;
  transition: background .3s, color .3s, transform .45s cubic-bezier(.22, .9, .3, 1);
}
:is(body.blog, body.archive, body.search) .pagination .page-numbers svg {
  fill: currentColor;
}
:is(body.blog, body.archive, body.search) .pagination a.page-numbers:hover {
  color: #ffffff;
  background: #3e225c;
  transform: translateY(-3px);
}
:is(body.blog, body.archive, body.search) .pagination .page-numbers.current {
  color: #ffffff;
  background: #ed174c;
  box-shadow: 0 12px 22px -12px rgba(237, 23, 76, .8);
}
:is(body.blog, body.archive, body.search) .pagination .page-numbers.dots {
  min-width: 0;
  padding: 0 4px;
  background: none;
  box-shadow: none;
}
:is(body.blog, body.archive, body.search) .pagination :is(.next, .prev) {
  padding: 0 20px;
}

/* Movement, only for visitors who haven't asked for less of it.
   The colour wash drifts slowly, the heading rises in on load, and in
   browsers that support it each card rises into place as it scrolls into
   view and settles back as it leaves, in both directions. */
@keyframes scBlogDrift {
  from { transform: translate3d(-3%, 0, 0) rotate(-2deg) scale(1); }
  to { transform: translate3d(4%, 26px, 0) rotate(3deg) scale(1.08); }
}
@keyframes scBlogRise {
  from { opacity: 0; translate: 0 28px; }
  to { opacity: 1; translate: 0 0; }
}
@keyframes scBlogCard {
  from { opacity: 0; translate: 0 56px; scale: .94; }
  to { opacity: 1; translate: 0 0; scale: 1; }
}
@media (prefers-reduced-motion: no-preference) {
  :is(body.blog, body.archive, body.search) #primary::before {
    animation: scBlogDrift 16s ease-in-out infinite alternate;
  }
  body.blog #main::before,
  :is(body.archive, body.search) #main > .page-header {
    animation: scBlogRise .9s cubic-bezier(.22, .9, .3, 1) .05s backwards;
  }
  body.blog #main::after {
    animation: scBlogRise .9s cubic-bezier(.22, .9, .3, 1) .2s backwards;
  }
  @supports (animation-timeline: view()) {
    :is(body.blog, body.archive, body.search) #main > article {
      animation: scBlogCard linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 70%;
    }
    :is(body.blog, body.archive, body.search) #main > article:nth-of-type(2n + 1):not(:first-of-type) {
      animation-range: entry 12% entry 82%;
    }
  }
}
@media (prefers-reduced-motion: reduce) {
  :is(body.blog, body.archive, body.search) #main > article,
  :is(body.blog, body.archive, body.search) .pagination .page-numbers {
    transition: none;
  }
}

/* 11f. Single posts: the same type, a calmer title size, tidy details under
       the title, and "previous" and "next" as cards */
body.single-post #main {
  font-family: "Red Hat Display", -apple-system, "Segoe UI", sans-serif;
}
body.single-post #main > article .entry-title {
  font-family: inherit;
  font-size: clamp(34px, 3.6vw, 54px);
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: -.03em;
  text-wrap: balance;
  color: #3e225c;
}
body.single-post #main > article .entry-header .entry-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  margin-top: 20px;
  font-size: 14px;
  line-height: 1.3;
  font-weight: 700;
  color: #584a68;
}
body.single-post #main > article .entry-header .entry-meta > span {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0;
}
body.single-post #main > article .entry-header .entry-meta a {
  color: #584a68;
  text-decoration: none;
}
body.single-post #main > article .entry-header .entry-meta a:hover {
  color: #ed174c;
}
body.single-post #main > article .entry-header .entry-meta svg {
  fill: #ed174c;
}
body.single-post #main > article .entry-header .entry-meta time.updated:not(.published) {
  display: none;
}
body.single-post #main > article .entry-header .entry-meta .cat-links a {
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  text-transform: capitalize;
  color: #3e225c;
  background: #fee8db;
}
body.single-post #main > article .entry-header .entry-meta .cat-links a:hover {
  color: #3e225c;
  background: #f7ca9d;
}
body.single-post #main > article .entry-header .entry-meta .cat-links svg {
  display: none;
}
body.single-post #main > article .entry-header .entry-meta .tags-links {
  display: block;
  flex-basis: 100%;
  font-weight: 500;
}
body.single-post #main > article .entry-header .entry-meta .tags-links svg {
  margin-right: 6px;
  vertical-align: -3px;
}
body.single-post #main > article .entry-content > .wp-block-image:first-child img {
  border-radius: 28px;
}
body.single-post #main .post-navigation .nav-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
body.single-post #main .post-navigation .nav-links > div {
  margin: 0;
  max-width: none;
  width: auto;
}
body.single-post #main .post-navigation .nav-next {
  grid-column: 2;
  text-align: right;
}
body.single-post #main .post-navigation a {
  display: block;
  height: 100%;
  box-sizing: border-box;
  padding: 20px 24px;
  border-radius: 24px;
  font-weight: 800;
  text-decoration: none;
  color: #3e225c;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(62, 34, 92, .06), 0 24px 48px -32px rgba(62, 34, 92, .5);
  transition: transform .5s cubic-bezier(.22, .9, .3, 1), box-shadow .5s;
}
body.single-post #main .post-navigation a:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 0 3px #4ec1b8, 0 36px 60px -30px rgba(62, 34, 92, .55);
}
body.single-post #main .post-navigation .meta-nav {
  font-size: 14px;
  font-weight: 700;
  color: #ed174c;
}
@media (max-width: 600px) {
  body.single-post #main .post-navigation .nav-links {
    grid-template-columns: minmax(0, 1fr);
  }
  body.single-post #main .post-navigation .nav-next {
    grid-column: 1;
    text-align: left;
  }
}