/*
Theme Name: Kepoli
Theme URI: https://kepoli.com
Author: Isalune Merovik
Author URI: https://kepoli.com/despre-autor/
Description: A lightweight Romanian food blog theme built for recipes, editorial reading, internal linking, and ad-ready spacing.
Version: 1.0.0
Requires at least: 6.4
Tested up to: 6.8
Requires PHP: 8.1
Text Domain: kepoli
*/

:root {
  --paper: #fbf7ef;
  --paper-soft: #f4eadc;
  --surface: #fffdf8;
  --ink: #252416;
  --muted: #6b654f;
  --olive: #4f5525;
  --olive-dark: #34391a;
  --copper: #c8743f;
  --clay: #b95f39;
  --sage: #d7ddc0;
  --line: #e6d9c8;
  --shadow: 0 18px 60px rgba(41, 34, 20, 0.08);
  --radius: 8px;
  --content: min(1120px, calc(100vw - 32px));
  --measure: 740px;
  font-size: 16px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}

body.nav-open {
  overflow: hidden;
}

body.admin-bar .site-header {
  top: 32px;
}

a {
  color: var(--olive-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--copper);
}

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

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

button,
input,
textarea {
  font: inherit;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -48px;
  z-index: 1000;
  padding: 10px 14px;
  background: var(--ink);
  color: #fff;
}

.skip-link:focus {
  top: 12px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 247, 239, 0.94);
  border-bottom: 1px solid rgba(113, 88, 57, 0.16);
  backdrop-filter: blur(12px);
}

.site-header__inner {
  width: var(--content);
  min-height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 28px;
}

.site-header__cluster {
  display: flex;
  align-items: center;
  gap: 10px;
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 178px;
  text-decoration: none;
}

.site-brand img {
  width: 136px;
  height: auto;
}

.site-nav-panel {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 16px;
}

.site-nav {
  margin-left: 0;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.93rem;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 2px;
  color: var(--ink);
  text-decoration: none;
}

.site-nav a:hover,
.site-nav .current-menu-item > a,
.site-nav .current_page_item > a {
  color: var(--clay);
}

.search-link {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  text-decoration: none;
}

.search-link svg {
  width: 18px;
  height: 18px;
}

.search-link--panel {
  display: none;
  width: auto;
  padding: 0 14px;
  gap: 8px;
  font-family: Arial, Helvetica, sans-serif;
}

.site-nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  cursor: pointer;
}

.site-nav-toggle span {
  display: block;
  width: 16px;
  height: 1.5px;
  margin: 0 auto 4px;
  background: var(--ink);
  transition: transform 180ms ease, opacity 180ms ease;
}

.site-nav-toggle span:nth-child(3) {
  margin-bottom: 0;
}

.site-nav-toggle.is-open span:nth-child(1) {
  transform: translateY(5.5px) rotate(45deg);
}

.site-nav-toggle.is-open span:nth-child(2) {
  opacity: 0;
}

.site-nav-toggle.is-open span:nth-child(3) {
  transform: translateY(-5.5px) rotate(-45deg);
}

.reading-progress {
  width: 100%;
  height: 3px;
  background: rgba(79, 85, 37, 0.08);
}

.reading-progress__bar {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--copper), var(--olive));
  transition: width 120ms linear;
}

.ad-slot {
  width: min(100%, 970px);
  min-height: 92px;
  margin: 28px auto;
  display: grid;
  place-items: center;
  border: 1px dashed rgba(79, 85, 37, 0.3);
  background: rgba(255, 253, 248, 0.72);
  color: var(--muted);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.ad-slot--sidebar {
  min-height: 280px;
  margin: 0;
}

.ad-slot--below-content {
  min-height: 140px;
}

.home-hero {
  min-height: calc(100svh - 76px);
  display: grid;
  align-items: center;
  background-color: #ded5c2;
  background-image: linear-gradient(90deg, rgba(37, 36, 22, 0.82), rgba(37, 36, 22, 0.44) 42%, rgba(37, 36, 22, 0.1)), var(--hero-image);
  background-position: center;
  background-size: cover;
}

.home-hero__inner {
  width: var(--content);
  margin: 0 auto;
  padding: 72px 0;
  color: #fffdf8;
  animation: kepoli-rise 640ms ease-out both;
}

.home-hero__brand {
  width: min(260px, 72vw);
  margin-bottom: 24px;
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.22));
}

.home-hero h1 {
  max-width: 760px;
  margin: 0;
  color: #fffdf8;
  font-size: clamp(3rem, 7vw, 5.8rem);
  line-height: 0.96;
  letter-spacing: 0;
  text-shadow: 0 12px 42px rgba(0, 0, 0, 0.28);
}

.home-hero p {
  max-width: 610px;
  margin: 24px 0 34px;
  color: rgba(255, 253, 248, 0.9);
  font-size: clamp(1.1rem, 2vw, 1.35rem);
}

.home-hero__meta {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.home-hero__meta span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(255, 253, 248, 0.18);
  background: rgba(255, 253, 248, 0.12);
  color: #fffdf8;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--copper);
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 700;
  text-decoration: none;
  transition: transform 160ms ease, background 160ms ease, color 160ms ease;
}

.button:hover {
  transform: translateY(-1px);
  background: var(--olive);
  color: #fff;
}

.button--ghost {
  border-color: rgba(255, 253, 248, 0.62);
  background: rgba(255, 253, 248, 0.08);
  color: #fff;
}

.button--ghost:hover {
  background: #fffdf8;
  color: var(--ink);
}

.section {
  width: var(--content);
  margin: 0 auto;
  padding: 74px 0;
}

.section--tight {
  padding: 42px 0;
}

.section__header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

.section__header--compact {
  margin-bottom: 22px;
}

.section-link {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--copper);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

h1,
h2,
h3,
h4 {
  color: var(--ink);
  font-weight: 500;
  line-height: 1.08;
}

h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.6rem);
}

h3 {
  font-size: 1.55rem;
}

.section__header p,
.archive-header p {
  max-width: 520px;
  margin: 0;
  color: var(--muted);
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.post-card {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  border-top: 2px solid var(--tone-strong, var(--olive));
  background: rgba(255, 253, 248, 0.72);
  box-shadow: var(--shadow);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.post-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 70px rgba(41, 34, 20, 0.12);
}

.post-card__visual {
  display: block;
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, var(--tone-soft, var(--sage)), #fff5e6);
}

.post-card__badges {
  position: absolute;
  left: 18px;
  top: 18px;
  z-index: 3;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.post-card__badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--tone-strong, var(--olive));
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.post-card__badge--ghost {
  background: rgba(255, 253, 248, 0.9);
  color: var(--ink);
}

.post-card__body {
  min-height: 100%;
  padding: 20px;
  display: flex;
  flex: 1;
  flex-direction: column;
}

.post-media {
  position: relative;
  min-height: 132px;
  width: 100%;
  overflow: hidden;
}

.post-media__image,
.post-media__icon {
  width: 100%;
  height: 100%;
}

.post-media__image {
  object-fit: cover;
}

.post-media__shade,
.post-media__fill {
  position: absolute;
  inset: 0;
}

.post-media__shade {
  background: linear-gradient(180deg, rgba(37, 36, 22, 0.06), rgba(37, 36, 22, 0.38));
}

.post-media__mark {
  position: absolute;
  right: 14px;
  bottom: 14px;
  width: 36px;
  height: 36px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.92);
  box-shadow: 0 8px 22px rgba(37, 36, 22, 0.16);
}

.post-media__fill {
  background: linear-gradient(135deg, var(--tone-soft, var(--sage)), #fff5e6);
}

.post-media__icon {
  position: absolute;
  right: 18px;
  bottom: 18px;
  width: 66px;
  height: 66px;
  object-fit: contain;
  opacity: 0.78;
}

.post-media--related {
  min-height: 210px;
}

.post-card__meta,
.entry-meta,
.breadcrumbs {
  color: var(--muted);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.83rem;
}

.entry-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
}

.entry-meta span {
  display: inline-flex;
  align-items: center;
}

.entry-meta span:not(:last-child)::after {
  content: "/";
  margin-left: 10px;
  color: rgba(107, 101, 79, 0.65);
}

.post-card h3 {
  margin: 6px 0 10px;
  font-size: 1.32rem;
}

.post-card h3 a {
  color: var(--ink);
  text-decoration: none;
}

.post-card p {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.96rem;
}

.post-card__link {
  margin-top: auto;
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 700;
  text-decoration: none;
}

.tone-default,
.tone-guides {
  --tone-strong: var(--olive);
  --tone-soft: var(--sage);
}

.tone-soups {
  --tone-strong: #587666;
  --tone-soft: #dce8df;
}

.tone-mains {
  --tone-strong: #8b5a35;
  --tone-soft: #edd9c8;
}

.tone-sweets {
  --tone-strong: #9a5d6a;
  --tone-soft: #f0dde4;
}

.tone-pantry {
  --tone-strong: #6d6d3b;
  --tone-soft: #e7e5c8;
}

.category-band {
  background: var(--olive-dark);
  color: #fffdf8;
}

.category-band .section {
  padding: 74px 0;
}

.category-band h2,
.category-band a {
  color: #fffdf8;
}

.category-list {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  background: rgba(255, 253, 248, 0.22);
}

.category-list a {
  min-height: 122px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px;
  background: var(--olive-dark);
  text-decoration: none;
  transition: background 160ms ease;
}

.category-list a:hover {
  background: var(--copper);
}

.category-list strong {
  font-size: 1.18rem;
  line-height: 1.2;
}

.category-list span {
  color: rgba(255, 253, 248, 0.72);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.82rem;
}

.author-strip {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: 42px;
  align-items: center;
}

.author-strip__photo {
  min-height: 380px;
  background-image: var(--author-image);
  background-position: center;
  background-size: cover;
}

.author-strip__copy {
  max-width: 620px;
}

.author-strip__copy p {
  color: var(--muted);
  font-size: 1.1rem;
}

.browse-links {
  margin-top: 26px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.browse-link {
  min-height: 92px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 16px 18px;
  border-top: 2px solid var(--tone-strong, var(--olive));
  background: rgba(255, 253, 248, 0.82);
  color: var(--ink);
  text-decoration: none;
}

.browse-link strong,
.browse-link span {
  display: block;
}

.browse-link strong {
  font-size: 1rem;
}

.browse-link span {
  color: var(--muted);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.78rem;
}

.site-main {
  min-height: 60vh;
}

.archive-header,
.search-header {
  width: var(--content);
  margin: 0 auto;
  padding: 58px 0 28px;
}

.archive-header--compact {
  width: 100%;
  padding: 0 0 28px;
}

.archive-header h1,
.search-header h1 {
  max-width: 860px;
  margin: 0 0 16px;
}

.meta-strip {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.meta-strip--inline {
  margin-top: 0;
}

.meta-strip__item {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.82);
  color: var(--muted);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
}

.home-cluster {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: 20px;
  align-items: start;
}

.home-cluster--reverse {
  grid-template-columns: minmax(320px, 0.9fr) minmax(0, 1.1fr);
}

.home-cluster--reverse .compact-post-list {
  order: -1;
}

.lead-story {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  background: var(--surface);
  border-top: 2px solid var(--tone-strong, var(--olive));
  box-shadow: var(--shadow);
  overflow: hidden;
}

.lead-story__media {
  display: block;
  min-height: 100%;
  text-decoration: none;
}

.lead-story__media .post-media {
  min-height: 100%;
  height: 100%;
}

.lead-story__body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
}

.lead-story__body h3 {
  margin: 0;
  font-size: clamp(1.8rem, 2.8vw, 2.4rem);
}

.lead-story__body h3 a {
  color: var(--ink);
  text-decoration: none;
}

.lead-story__body p {
  margin: 0;
  color: var(--muted);
}

.compact-post-list {
  padding: 20px;
  background: rgba(255, 253, 248, 0.72);
  border: 1px solid var(--line);
}

.compact-post-list__heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.compact-post-list__heading .eyebrow {
  margin-bottom: 0;
}

.compact-post + .compact-post {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.compact-post {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.compact-post__media {
  display: block;
  text-decoration: none;
}

.compact-post__media .post-media {
  min-height: 96px;
}

.compact-post__body {
  min-width: 0;
}

.compact-post__body h3 {
  margin: 6px 0 8px;
  font-size: 1.08rem;
  line-height: 1.24;
}

.compact-post__body h3 a {
  color: var(--ink);
  text-decoration: none;
}

.compact-post__body p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.content-layout {
  width: var(--content);
  margin: 0 auto;
  padding: 52px 0 72px;
  display: grid;
  grid-template-columns: minmax(0, var(--measure)) minmax(260px, 320px);
  gap: 62px;
  align-items: start;
}

.content-layout--single-post {
  padding-top: 42px;
  gap: 48px;
}

.content-layout--single {
  width: 100%;
  padding: 0;
  grid-template-columns: minmax(0, var(--measure));
}

.entry {
  min-width: 0;
}

.entry-header {
  margin-bottom: 28px;
}

.content-layout--single-post .entry-header {
  margin-bottom: 22px;
}

.entry-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 14px;
}

.entry-toolbar__pill {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--tone-soft, var(--paper-soft));
  color: var(--tone-strong, var(--olive-dark));
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  text-decoration: none;
}

.entry-toolbar__pill--link {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
}

.entry-toolbar__pill--muted {
  background: rgba(79, 85, 37, 0.08);
  color: var(--muted);
}

.breadcrumbs {
  margin-bottom: 18px;
}

.breadcrumbs a {
  text-decoration: none;
}

.entry-title {
  margin: 0 0 14px;
  font-size: clamp(2.4rem, 5vw, 4.8rem);
  letter-spacing: 0;
}

.entry-excerpt {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 1.14rem;
}

.entry-summary-board {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(250px, 0.9fr);
  gap: 18px;
  margin-bottom: 18px;
  padding: 18px;
  background: rgba(255, 253, 248, 0.82);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.entry-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.entry-meta-grid__item {
  min-height: 72px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.entry-meta-grid__item span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
}

.entry-meta-grid__item strong {
  display: block;
  font-size: 1rem;
  line-height: 1.35;
}

.share-tools {
  display: flex;
  flex-wrap: wrap;
  align-content: start;
  gap: 10px;
}

.share-tools__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.84rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, color 160ms ease;
}

.share-tools__button:hover {
  border-color: rgba(200, 116, 63, 0.4);
  background: rgba(255, 253, 248, 0.96);
  color: var(--copper);
}

.share-tools__icon {
  width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: var(--paper-soft);
  color: var(--olive-dark);
  font-size: 0.9rem;
  line-height: 1;
}

.entry-jumpnav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.entry-jumpnav a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  text-decoration: none;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.84rem;
}

.entry-outline {
  margin-top: 14px;
  padding: 16px;
  background: rgba(255, 253, 248, 0.82);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.entry-outline__header {
  margin-bottom: 10px;
}

.entry-outline__header .eyebrow {
  margin-bottom: 0;
}

.entry-outline__list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.entry-outline__list li {
  margin: 0;
}

.entry-outline__list a {
  min-height: 56px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
}

.entry-outline__number {
  width: 26px;
  height: 26px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: var(--olive-dark);
  color: #fffdf8;
  font-size: 0.78rem;
  flex: 0 0 auto;
}

.entry-content {
  font-size: 1.05rem;
  line-height: 1.72;
}

.entry-content--page {
  max-width: 820px;
  margin: 0 auto;
}

.entry-content > p:first-child {
  font-size: 1.12rem;
}

.entry-content h2,
.entry-content h3 {
  margin-top: 1.7em;
  margin-bottom: 0.55em;
}

.entry-content p,
.entry-content ul,
.entry-content ol {
  margin-top: 0;
  margin-bottom: 1em;
}

.entry-content li + li {
  margin-top: 0.35em;
}

.kepoli-recipe-box,
.related-posts,
.author-box,
.page-panel {
  margin: 28px 0;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.content-layout--recipe .entry-content h2 {
  padding-top: 14px;
  border-top: 1px solid rgba(230, 217, 200, 0.9);
}

.content-layout--recipe .entry-content ul,
.content-layout--recipe .entry-content ol {
  padding-left: 0;
  list-style: none;
}

.content-layout--recipe .entry-content ul {
  display: grid;
  gap: 10px;
}

.content-layout--recipe .entry-content ul li {
  position: relative;
  padding: 12px 14px 12px 32px;
  background: rgba(255, 253, 248, 0.82);
  border: 1px solid var(--line);
}

.content-layout--recipe .entry-content ul li::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 20px;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--copper);
}

.content-layout--recipe .entry-content ol {
  counter-reset: recipe-step;
  display: grid;
  gap: 12px;
}

.content-layout--recipe .entry-content ol li {
  position: relative;
  min-height: 56px;
  padding: 14px 16px 14px 56px;
  background: rgba(255, 253, 248, 0.88);
  border: 1px solid var(--line);
}

.content-layout--recipe .entry-content ol li::before {
  counter-increment: recipe-step;
  content: counter(recipe-step);
  position: absolute;
  left: 14px;
  top: 14px;
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: var(--olive-dark);
  color: #fffdf8;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.84rem;
  font-weight: 700;
}

.kepoli-recipe-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin: 18px 0;
  background: var(--line);
  border: 1px solid var(--line);
}

.kepoli-recipe-meta div {
  min-height: 68px;
  padding: 12px 14px;
  background: var(--surface);
}

.kepoli-recipe-meta span {
  display: block;
  color: var(--muted);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.76rem;
  text-transform: uppercase;
}

.kepoli-recipe-meta strong {
  font-size: 1rem;
}

.related-posts ul,
.more-list,
.footer-menu ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.related-posts li + li,
.more-list li + li {
  margin-top: 10px;
}

.more-list--stacked li + li {
  margin-top: 12px;
}

.more-list--stacked a {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 0 12px;
  border-bottom: 1px solid var(--line);
}

.more-list--stacked strong {
  color: var(--muted);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.78rem;
}

.more-list--posts li + li {
  margin-top: 12px;
}

.more-list--posts a {
  display: block;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.more-list__eyebrow {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
}

.more-list--posts strong {
  display: block;
  color: var(--ink);
  font-size: 0.98rem;
  line-height: 1.35;
}

.related-posts--cards {
  padding: 0;
  background: transparent;
  border: 0;
}

.related-posts__heading {
  margin-bottom: 18px;
}

.related-posts__heading h2 {
  margin-bottom: 8px;
  font-size: clamp(1.65rem, 2.6vw, 2.3rem);
}

.related-posts__heading p:last-child {
  max-width: 640px;
  color: var(--muted);
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.related-card {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border-top: 2px solid var(--tone-strong, var(--olive));
  box-shadow: var(--shadow);
}

.related-card__media {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  text-decoration: none;
}

.related-card__body {
  min-height: 100%;
  padding: 22px;
  display: flex;
  flex: 1;
  flex-direction: column;
}

.related-card__body h3 {
  margin: 8px 0 12px;
  font-size: 1.4rem;
}

.related-card__body h3 a {
  color: var(--ink);
  text-decoration: none;
}

.related-card__body p {
  margin: 0 0 18px;
  color: var(--muted);
}

.post-navigation-pro {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.post-navigation-pro__item {
  min-height: 100%;
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  background: var(--surface);
  border-top: 2px solid var(--tone-strong, var(--olive));
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.post-navigation-pro__body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.post-navigation-pro__eyebrow {
  color: var(--copper);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
}

.post-navigation-pro__body strong {
  font-size: 1.1rem;
  line-height: 1.25;
}

.post-navigation-pro__body span:last-child {
  color: var(--muted);
  font-size: 0.92rem;
}

.sidebar {
  position: sticky;
  top: 104px;
}

.content-layout--single-post .sidebar {
  top: 92px;
}

.sidebar-section {
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}

.sidebar-section h2,
.sidebar-section h3 {
  margin: 0 0 14px;
  font-size: 1.25rem;
}

.sidebar-section a {
  text-decoration: none;
}

.author-box {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
}

.author-box img {
  width: 76px;
  height: 76px;
  object-fit: cover;
  border-radius: 999px;
}

.author-box h2,
.author-box h3,
.author-box p {
  margin: 0;
}

.author-box p {
  color: var(--muted);
  font-size: 0.95rem;
}

.author-box--expanded {
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: start;
}

.author-box--expanded img {
  width: 92px;
  height: 92px;
}

.author-box__links {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.88rem;
}

.content-layout--single-post .author-box {
  margin-top: 24px;
}

.page-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin-top: 32px;
}

.page-panel h2 {
  margin-bottom: 14px;
  font-size: 1.7rem;
}

.page-panel p {
  margin: 0;
  color: var(--muted);
}

.page-links {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  font-family: Arial, Helvetica, sans-serif;
}

.page-links a {
  padding: 10px 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  text-decoration: none;
}

.search-empty {
  grid-column: 1 / -1;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.search-empty p {
  margin: 0;
  color: var(--muted);
}

.pagination {
  margin-top: 36px;
  font-family: Arial, Helvetica, sans-serif;
}

.pagination .nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pagination a,
.pagination span {
  min-width: 40px;
  min-height: 40px;
  display: inline-grid;
  place-items: center;
  padding: 0 12px;
  border: 1px solid var(--line);
  text-decoration: none;
}

.pagination .current {
  background: var(--olive);
  color: #fff;
}

.search-form {
  display: flex;
  gap: 10px;
  max-width: 640px;
}

.search-form label {
  flex: 1;
}

.search-field {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  background: #fff;
}

.search-submit {
  min-width: 118px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  border-radius: 999px;
  border: 0;
  background: var(--olive);
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 700;
  cursor: pointer;
}

.site-footer {
  background: #252416;
  color: rgba(255, 253, 248, 0.78);
}

.site-footer__inner {
  width: var(--content);
  margin: 0 auto;
  padding: 54px 0 36px;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) repeat(2, minmax(0, 0.7fr));
  gap: 42px;
}

.site-footer img {
  width: 160px;
  margin-bottom: 18px;
}

.site-footer__brand {
  min-width: 0;
}

.site-footer__column {
  min-width: 0;
}

.site-footer a {
  color: #fffdf8;
  text-decoration: none;
}

.site-footer p {
  max-width: 560px;
}

.site-footer__identity {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 18px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.9rem;
}

.footer-links-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.footer-menu ul {
  display: grid;
  gap: 8px;
}

.footer-bottom {
  width: var(--content);
  margin: 0 auto;
  padding: 18px 0;
  border-top: 1px solid rgba(255, 253, 248, 0.16);
  color: rgba(255, 253, 248, 0.58);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.83rem;
}

.not-found {
  width: min(720px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 90px 0;
}

@keyframes kepoli-rise {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 980px) {
  .site-header__inner {
    min-height: 76px;
    padding: 12px 0;
    gap: 12px;
  }

  .site-header__cluster {
    margin-left: auto;
  }

  .site-nav-toggle {
    display: inline-grid;
    place-items: center;
  }

  .search-link--desktop {
    display: none;
  }

  .search-link--panel {
    display: inline-flex;
    justify-content: center;
  }

  .site-nav-panel {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 1px);
    display: grid;
    gap: 14px;
    padding: 18px 12px 20px;
    background: rgba(251, 247, 239, 0.98);
    border-bottom: 1px solid rgba(113, 88, 57, 0.16);
    box-shadow: 0 20px 60px rgba(41, 34, 20, 0.12);
    max-height: calc(100svh - 82px);
    overflow-y: auto;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity 180ms ease, transform 180ms ease;
  }

  .site-nav-panel.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .site-nav {
    width: 100%;
  }

  .site-nav ul {
    display: grid;
    gap: 6px;
  }

  .site-nav a {
    min-height: 44px;
    width: 100%;
    padding: 0 8px;
  }

  .home-hero {
    min-height: 680px;
  }

  .post-grid,
  .category-list,
  .author-strip,
  .content-layout,
  .related-grid,
  .post-navigation-pro,
  .site-footer__inner,
  .lead-story,
  .home-cluster,
  .home-cluster--reverse {
    grid-template-columns: 1fr;
  }

  .entry-summary-board {
    grid-template-columns: 1fr;
  }

  .entry-outline__list {
    grid-template-columns: 1fr;
  }

  .home-cluster--reverse .compact-post-list {
    order: 0;
  }

  .browse-links,
  .page-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sidebar {
    position: static;
  }

  .category-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .entry-header {
    margin-bottom: 24px;
  }

  .entry-excerpt {
    font-size: 1.08rem;
  }

  .share-tools__button {
    flex: 1 1 calc(50% - 8px);
    min-height: 44px;
  }

  .entry-meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .compact-post {
    grid-template-columns: 112px minmax(0, 1fr);
  }
}

@media (max-width: 640px) {
  :root {
    --content: min(100vw - 24px, 1120px);
  }

  body.admin-bar .site-header {
    top: 0;
  }

  .site-brand img {
    width: 132px;
  }

  .site-header__inner {
    min-height: 68px;
    gap: 14px;
  }

  .site-nav-panel {
    padding: 16px 12px calc(20px + env(safe-area-inset-bottom));
  }

  .post-navigation-pro__item {
    grid-template-columns: 1fr;
  }

  .browse-links,
  .page-grid {
    grid-template-columns: 1fr;
  }

  .home-hero {
    min-height: 620px;
    background-position: 58% center;
  }

  .home-hero__inner {
    padding: 76px 0 54px;
  }

  .home-hero h1 {
    font-size: 3rem;
  }

  .home-hero__meta {
    gap: 8px;
  }

  .home-hero__meta span {
    width: 100%;
    justify-content: center;
  }

  .section {
    padding: 48px 0;
  }

  .section__header {
    display: block;
  }

  .meta-strip {
    gap: 8px;
  }

  .meta-strip__item {
    min-height: 32px;
  }

  .post-grid,
  .category-list {
    grid-template-columns: 1fr;
  }

  .compact-post-list {
    padding: 16px;
  }

  .compact-post {
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 12px;
  }

  .compact-post__media .post-media {
    min-height: 84px;
  }

  .entry-title {
    font-size: 2.45rem;
  }

  .entry-meta {
    gap: 6px 8px;
  }

  .entry-meta span:not(:last-child)::after {
    margin-left: 8px;
  }

  .entry-toolbar {
    gap: 8px;
  }

  .entry-toolbar__pill {
    min-height: 34px;
  }

  .share-tools {
    gap: 8px;
  }

  .share-tools__button {
    flex: 1 1 100%;
  }

  .entry-summary-board {
    padding: 14px;
    gap: 14px;
  }

  .entry-outline {
    padding: 14px;
  }

  .entry-meta-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .entry-meta-grid__item {
    min-height: auto;
  }

  .related-card__body,
  .post-card__body,
  .post-navigation-pro__body,
  .lead-story__body,
  .kepoli-recipe-box,
  .author-box,
  .page-panel {
    padding: 20px;
  }

  .search-form {
    flex-direction: column;
  }

  .search-submit {
    width: 100%;
    min-height: 46px;
  }

  .kepoli-recipe-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .content-layout--recipe .entry-content ul li,
  .content-layout--recipe .entry-content ol li {
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .author-box {
    grid-template-columns: 1fr;
  }
}

@media print {
  body {
    background: #fff;
    color: #000;
  }

  .site-header,
  .site-footer,
  .sidebar,
  .ad-slot,
  .share-tools,
  .reading-progress,
  .post-navigation-pro,
  .related-posts--cards,
  .search-link,
  .site-nav-toggle {
    display: none !important;
  }

  .content-layout {
    width: 100%;
    padding: 0;
    display: block;
  }

  .entry,
  .entry-content,
  .kepoli-recipe-box {
    max-width: none;
  }

  .entry-title,
  .entry-excerpt,
  .entry-content,
  .entry-content p,
  .entry-content li,
  .entry-content h2,
  .entry-content h3 {
    color: #000;
  }

  a {
    color: #000;
    text-decoration: none;
  }
}
