/*
Theme Name: Thistle & Hearth
Author: Pop & Thistle
Author URI: https://popandthistle.com/
Theme URI: https://popandthistle.com/introducing-thistle-hearth-a-free-cozy-wordpress-theme-for-creative-bloggers/
Description: A warm, editorial block theme for creative journals, cozy living, knitting, crochet, crafts, and thoughtful lifestyle blogs.
Version: 1.5.1
Requires at least: 6.6
Requires PHP: 7.4
Tested up to: 6.6
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: thistle-hearth
Tags: blog, one-column, two-columns, three-columns, custom-colors, custom-logo, editor-style, full-site-editing, block-patterns, wide-blocks, featured-images, translation-ready
*/

:root {
  --th-ink: var(--wp--preset--color--ink, #2e3e35);
  --th-sage: var(--wp--preset--color--sage, #798974);
  --th-paper: var(--wp--preset--color--paper, #fbf8f2);
  --th-muted: var(--wp--preset--color--muted, #656f65);
  --th-lilac: var(--wp--preset--color--lilac, #d7c9d8);
  --th-card: var(--wp--preset--color--cream, #f3efe6);
}
*,*::before,*::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; -webkit-font-smoothing: antialiased; }
body, button, input, textarea { font-family: var(--wp--preset--font-family--body, system-ui, sans-serif); }
.wp-site-blocks { overflow: clip; }
a { text-underline-offset: .2em; transition: color .2s ease; }
a:hover { color: var(--wp--preset--color--clay, #a56962); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible { outline: 3px solid var(--wp--preset--color--clay,#a56962); outline-offset: 4px; }
::selection { background: #e7dbe5; color: #23362d; }
.wp-block-image img, .wp-block-post-featured-image img { height: auto; }
.th-site-header { border-bottom: 1px solid rgba(49,68,56,.12); }
.th-header-inner { min-height: 98px; gap: 24px; }
.th-wordmark .wp-block-site-title { margin: 0; font-weight: 500; letter-spacing: -.055em; font-size: clamp(1.7rem,2.4vw,2.2rem); line-height: 1.15; }
.th-wordmark .wp-block-site-title a { text-decoration:none; }
.th-wordmark .wp-block-site-tagline { font-size: .67rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; opacity: .7; margin-top: .65rem; }
.th-header-inner .wp-block-navigation { gap: clamp(.9rem,2.1vw,2rem); }
.th-header-inner .wp-block-navigation a { font-size: .78rem; text-decoration: none; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; }
.th-header-inner .wp-block-navigation a:hover { text-decoration: underline; text-decoration-color: var(--wp--preset--color--clay,#a56962); text-underline-offset: 6px; }
.th-topnote { font-size: .67rem; letter-spacing: .18em; text-transform: uppercase; font-weight: 700; }
.th-hero { position: relative; isolation: isolate; }
.th-hero::before { content: '✳'; position:absolute; top: 9%; left: -2%; color: var(--wp--preset--color--rose,#d4aba9); font-size:2.8rem; opacity: .8; z-index:-1; }
.th-hero-copy { padding-top: clamp(1.5rem,4vw,3rem); padding-bottom: clamp(2rem,5vw,3.5rem); }
.th-hero h1 { font-size: clamp(3.2rem,6vw,5.6rem); line-height: 1.03; letter-spacing: -.055em; max-width: 12ch; margin: .55em 0 .27em; font-weight: 500; }
.th-hero .th-hero-summary { font-size: clamp(1rem,1.4vw,1.12rem); line-height: 1.85; max-width: 48ch; }
.th-hero-art { min-height: clamp(370px,48vw,600px); background-image: url('assets/images/atelier-hero.svg'); background-size: contain; background-repeat: no-repeat; background-position:center; }
.th-btn .wp-block-button__link { border-radius: 2px; font-size: .79rem; font-weight: 750; letter-spacing: .07em; text-transform: uppercase; padding: 1.05rem 1.8rem; transition: transform .2s ease,background .2s ease; }
.th-btn .wp-block-button__link:hover { transform: translateY(-2px); }
.th-hero-tag { display:inline-block; margin:0; padding-bottom:12px; border-bottom: 1px solid var(--wp--preset--color--clay,#a56962); }
.th-squiggle { color: var(--wp--preset--color--clay,#a56962); font-family: Georgia,serif; font-size:2rem; }
.th-quiet-strip { border-top: 1px solid rgba(49,68,56,.12); border-bottom: 1px solid rgba(49,68,56,.12); }
.th-quiet-strip .wp-block-columns { margin-bottom:0; }
.th-quiet-strip p { font-size: .72rem; font-weight: 650; text-transform: uppercase; letter-spacing:.14em; margin: .65rem 0; }
.th-quiet-strip .th-divider-dot { font-size: 1rem; color: var(--wp--preset--color--clay,#a56962); }
.th-section { padding-top: clamp(3.6rem,6.5vw,6.7rem); padding-bottom: clamp(3.8rem,7vw,7rem); }
.th-section-heading { margin-bottom: 2.2rem; }
.th-section-heading h2 { margin:.2rem 0; font-size: clamp(2.3rem,3.5vw,3.7rem); letter-spacing:-.04em; line-height:1.12; font-weight:500; }
.th-eyebrow { text-transform: uppercase; letter-spacing: .18em; color:var(--wp--preset--color--clay,#a56962); font-weight:750; font-size:.69rem; }
.th-eyebrow a { color:inherit; text-decoration:none; }
.th-posts-query .wp-block-post-template { gap: clamp(2rem,2.8vw,3.25rem) clamp(1.1rem,2.3vw,2.2rem); }
.th-posts-query .wp-block-post { border-bottom: 1px solid rgba(49,68,56,.15); padding-bottom:1.5rem; }
.th-posts-query .wp-block-post-featured-image { overflow:hidden; background:#e6e5d9; margin: 0 0 1.3rem; }
.th-posts-query .wp-block-post-featured-image img { display:block; aspect-ratio: 4/3; width:100%; object-fit:cover; transition: transform .5s ease; }
.th-posts-query .wp-block-post-featured-image:hover img { transform: scale(1.04); }
.th-posts-query .wp-block-post-terms { font-size: .65rem; text-transform:uppercase; letter-spacing:.12em; font-weight:700; color:var(--wp--preset--color--clay,#a56962); margin: 0 0 .7rem; }
.th-posts-query .wp-block-post-terms a { text-decoration:none; color:inherit; }
.th-posts-query .wp-block-post-title { font-family:var(--wp--preset--font-family--heading,Georgia,serif); font-size: clamp(1.3rem,2vw,1.8rem); line-height:1.22; font-weight:500; letter-spacing:-.025em; margin:.15rem 0 .7rem; }
.th-posts-query .wp-block-post-title a { text-decoration:none; }
.th-posts-query .wp-block-post-excerpt { color: var(--th-muted); font-size:.9rem; line-height:1.8; margin-bottom:.5rem; }
.th-posts-query .wp-block-post-excerpt__more-link { display:inline-block; text-transform:uppercase; letter-spacing:.1em; font-size:.68rem; font-weight:750; color:var(--th-ink); text-decoration:none; margin-top:.6rem; }
.th-posts-query .wp-block-post-date { color:var(--th-muted); font-size:.7rem; }
.th-posts-query .wp-block-query-pagination { margin-top:3rem; justify-content:center; gap:.8rem; }
.th-posts-query .wp-block-query-pagination a { text-decoration:none; }
.th-posts-query .wp-block-query-pagination .current { color:var(--wp--preset--color--clay,#a56962); }
.th-feature-band { border-radius: 3px; position:relative; overflow:hidden; }
.th-feature-band::after { content:'✳'; position:absolute; font-size:17rem; color:rgba(255,255,255,.18); right:-2rem; bottom:-10rem; pointer-events:none; }
.th-feature-band h2 { font-weight:500; font-size:clamp(2.1rem,3.9vw,4rem); letter-spacing:-.045em; line-height:1.1; }
.th-feature-band p { max-width:45ch; }
.th-content-shell { padding-top: clamp(2.8rem,6vw,6rem); padding-bottom:clamp(4rem,7vw,7rem); }
.th-content-shell h1 { font-weight:500; font-size:clamp(2.65rem,5vw,4.9rem); line-height:1.09; letter-spacing:-.045em; }
.th-content-shell .th-single-title { max-width:16ch; }
.th-content-shell .wp-block-post-featured-image { margin:2.1rem 0 3rem; }
.th-content-shell .wp-block-post-featured-image img { max-height:640px; width:100%; object-fit:cover; }
.th-content-shell .entry-content { line-height:1.95; }
.th-content-shell .entry-content > * { margin-block-start: 1.5em; margin-block-end:1.5em; }
.th-content-shell .entry-content h2, .th-content-shell .entry-content h3 { margin-top:2em; line-height:1.2; letter-spacing:-.025em; }
.th-content-shell .entry-content h2 { font-size: clamp(1.85rem,3vw,2.5rem); }
.th-content-shell .entry-content h3 { font-size:clamp(1.45rem,2.3vw,1.9rem); }
.th-content-shell .entry-content img { border-radius:2px; }
.th-content-shell .wp-block-post-terms, .th-content-shell .wp-block-post-date { font-size:.72rem; }
.th-content-shell .wp-block-post-navigation-link { font-size:.87rem; }
.th-entry-meta { color:var(--th-muted); gap:1.2rem; }
.th-entry-meta .wp-block-post-terms a { color:var(--wp--preset--color--clay,#a56962); text-decoration:none; }
.th-site-footer { border-top:1px solid rgba(49,68,56,.1); }
.th-site-footer .th-footer-wordmark { font-family:var(--wp--preset--font-family--heading,Georgia,serif); font-size:2rem; line-height:1; letter-spacing:-.04em; margin-bottom:.6rem; }
.th-site-footer .th-footer-wordmark a { text-decoration:none; }
.th-site-footer .th-footer-line { font-size:.88rem; max-width:36ch; line-height:1.75; }
.th-footer-bottom { border-top:1px solid rgba(49,68,56,.16); font-size:.73rem; }
.th-footer-bottom a { text-decoration:underline; text-underline-offset:3px; }
.th-footer-credit { color:var(--th-muted); }
.th-no-results { padding:2rem; background:var(--th-card); }
.th-slim-archive { max-width:950px; }
.th-spacer-sm { height: .75rem; }
.wp-block-search__button { border-radius:2px; }
.wp-block-button__link:focus-visible { outline:3px solid var(--wp--preset--color--clay,#a56962); outline-offset:3px; }
@media(max-width:781px) {
  .th-header-inner { min-height:78px; }
  .th-hero-copy { padding-top:2rem; padding-bottom:1rem; }
  .th-hero-art { min-height:400px; }
  .th-quiet-strip .wp-block-columns { gap:.3rem; }
  .th-quiet-strip .wp-block-column { flex-basis: 100%!important; }
  .th-quiet-strip .th-divider-dot { display:none; }
  .th-section { padding-block:3.3rem; }
  .th-site-footer .wp-block-columns { gap:2rem; }
}
@media(max-width:600px) {
  .th-header-inner { padding-block:1rem; }
  .th-wordmark .wp-block-site-title { font-size:1.6rem; }
  .th-wordmark .wp-block-site-tagline { font-size:.55rem; }
  .th-hero h1 { font-size:clamp(2.7rem,11vw,4rem); }
  .th-hero-art { min-height:300px; }
  .th-posts-query .wp-block-post-template { grid-template-columns:1fr!important; }
  .th-feature-band { padding:2rem!important; }
  .th-footer-bottom .wp-block-columns { flex-direction:column; gap:.4rem; }
}
@media(prefers-reduced-motion:reduce) {
  html { scroll-behavior:auto; }
  *,*::before,*::after { transition-duration:.01ms!important; animation-duration:.01ms!important; }
}

/* 1.1: Balanced, more compact welcome section. */
.th-hero { padding-top: .5rem !important; padding-bottom: 1.3rem !important; }
.th-hero-copy { padding-top: 1.2rem; padding-bottom: 1.4rem; }
.th-hero h1 { font-size: clamp(3rem, 4.35vw, 4.65rem); max-width: 16ch; line-height: 1.055; margin: .42em 0 .26em; }
.th-hero .th-hero-summary { max-width: 54ch; line-height: 1.7; }
.th-hero-art { min-height: 0; background: none; display: flex; justify-content: center; align-items: center; }
.th-hero-illustration { max-width: 440px; width: 100%; margin-inline: auto; }
.th-hero-illustration img { display: block; width: 100%; height: auto; }
.th-hero .th-btn { margin-top: .4rem; }
.th-section { padding-top: clamp(2.8rem, 5vw, 5rem); padding-bottom: clamp(3rem, 5vw, 5rem); }
/* Traditional widgets coexist with editable Sidebar and Footer template parts. */
.th-body-with-sidebar { gap: clamp(1.8rem, 3.5vw, 3.4rem); align-items: flex-start; margin-top: 1.7rem; }
.th-body-with-sidebar > .wp-block-column { min-width: 0; }
.th-body-with-sidebar .th-posts-query .wp-block-post-template { gap: 2.2rem 1.5rem; }
.th-sidebar-panel { border-top: 2px solid var(--wp--preset--color--rose, #d8b3b1); background: var(--wp--preset--color--cream, #f1ebe1); padding: clamp(1.1rem, 2vw, 1.7rem); }
.th-sidebar-panel .wp-block-heading { font-size: 1.55rem; margin-bottom: .85rem; }
.th-sidebar-panel .wp-block-search, .th-sidebar-panel .wp-block-categories, .th-sidebar-panel .wp-block-latest-posts { font-size: .9rem; }
.th-sidebar-panel .wp-block-categories-list, .th-sidebar-panel .wp-block-latest-posts { padding-left: 1.2rem; }
.th-sidebar-panel li { margin: .35rem 0; }
.th-sidebar-panel a { text-decoration: none; }
.th-sidebar-panel a:hover { text-decoration: underline; }
.th-widget-area { width: 100%; }
.th-widget-area.th-widget-home { max-width: 1160px; margin: 2rem auto 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); gap: 1.25rem; }
.th-widget-area.th-widget-home .widget { background: var(--wp--preset--color--cream, #f1ebe1); padding: 1.25rem; }
.th-widget-area.th-widget-footer { max-width: 1160px; margin: 0 auto 2.2rem; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 1.5rem; padding-bottom: 1.6rem; border-bottom: 1px solid rgba(49,68,56,.15); }
.th-widget-area .widget { margin: 0 0 1.5rem; overflow-wrap: anywhere; }
.th-widget-area .widget-title { font: 500 1.45rem/1.22 Georgia, 'Times New Roman', serif; margin: 0 0 .85rem; }
.th-widget-area ul { padding-left: 1.15rem; margin: 0; }
.th-widget-area li { margin: .32rem 0; }
.th-widget-area img, .th-sidebar-panel img { height: auto; max-width: 100%; }
.th-widget-area input, .th-sidebar-panel input { max-width: 100%; }
.th-widget-area select, .th-sidebar-panel select { width: 100%; max-width: 100%; }
.th-content-shell .th-body-with-sidebar { margin-top: 0; }
.th-content-shell .th-body-with-sidebar h1 { font-size: clamp(2.55rem, 4vw, 4.1rem); }
.th-content-shell .th-body-with-sidebar .th-single-title { max-width: 24ch; }
.th-content-shell .th-body-with-sidebar .wp-block-post-featured-image { margin: 2rem 0 2.5rem; }
@media (max-width: 900px) {
  .th-body-with-sidebar { flex-wrap: wrap !important; gap: 2.5rem; }
  .th-body-with-sidebar > .wp-block-column { flex-basis: 100% !important; }
  .th-hero h1 { font-size: clamp(2.8rem, 6vw, 4.2rem); }
  .th-hero-illustration { max-width: 360px; }
}
@media (max-width: 781px) {
  .th-hero { padding-top: .5rem !important; }
  .th-hero-copy { padding-top: .8rem; padding-bottom: .4rem; }
  .th-hero-art { min-height: 0; }
  .th-widget-area.th-widget-home, .th-widget-area.th-widget-footer { padding-inline: 1rem; }
}
@media (max-width: 600px) {
  .th-hero h1 { font-size: clamp(2.65rem, 11vw, 3.7rem); max-width: 15ch; }
  .th-hero-illustration { max-width: 300px; }
  .th-body-with-sidebar .th-posts-query .wp-block-post-template { grid-template-columns: 1fr !important; }
}


/* 1.2: clear right-hand sidebars and optional templates. */
.th-body-with-sidebar { align-items: flex-start; column-gap: clamp(1.6rem, 3.8vw, 3.4rem); }
.th-body-with-sidebar > .wp-block-column { min-width: 0; }
.th-body-with-sidebar > .wp-block-column:first-child { flex: 1 1 0 !important; }
.th-body-with-sidebar > .wp-block-column:last-child { flex: 0 0 clamp(240px, 27%, 310px) !important; }
.th-body-with-sidebar .entry-content { overflow-wrap: anywhere; }
.th-body-with-sidebar .entry-content :is(img, video, iframe, table) { max-width: 100%; }
.th-sidebar { width: 100%; }
.th-sidebar-panel { border-radius: 3px; box-shadow: 0 10px 28px rgba(39,53,43,.035); }
.th-sidebar-panel > :first-child { margin-top: 0; }
.th-sidebar-panel .th-widget-sidebar > .widget:last-child { margin-bottom: .35rem; }
.th-sidebar-panel .th-sidebar-starter { margin-top: .2rem; }
.th-sidebar-panel:has(.th-widget-sidebar) .th-sidebar-starter { border-top: 1px solid rgba(49,68,56,.15); padding-top: 1.15rem; margin-top: 1.3rem; }
.th-sidebar-panel .wp-block-search__inside-wrapper { max-width: 100%; }
.th-sidebar-panel .wp-block-search__button { padding: .55rem .8rem; }
.th-home-widgets { max-width: 1160px; margin: 0 auto; padding: clamp(1.6rem, 3vw, 2.5rem) 0 .5rem; }
.th-home-widgets .th-widget-area.th-widget-home { margin-top: 0; }
.th-home-widgets .widget-title { font-size: 1.55rem; }
.th-page-with-sidebar .wp-block-post-featured-image { margin: 1.6rem 0 2.1rem; }
.th-post-full-width .entry-content { max-width: 760px; margin-inline:auto; }
.th-post-full-width .th-single-title { max-width: 19ch; }
@media (min-width: 901px) {
  .th-body-with-sidebar { flex-wrap: nowrap !important; }
}
@media (max-width: 900px) {
  .th-body-with-sidebar { flex-wrap: wrap !important; }
  .th-body-with-sidebar > .wp-block-column:first-child,
  .th-body-with-sidebar > .wp-block-column:last-child { flex: 0 0 100% !important; }
  .th-body-with-sidebar .th-sidebar { max-width: 580px; margin-inline: auto; }
}


/* 1.3: distinct, accessible primary menu below the site identity. */
.th-site-header { border-bottom: 0; }
.th-header-inner { min-height: 88px; padding-block: .7rem; }
.th-nav-band {
  border-top: 1px solid rgba(49,68,56,.1);
  border-bottom: 1px solid rgba(49,68,56,.14);
}
.th-nav-inner { min-height: 54px; gap: 1.7rem; padding-block: .5rem; }
.th-nav-caption { margin: 0; color: var(--wp--preset--color--clay,#a56962); font-size: .69rem; font-weight: 750; letter-spacing: .17em; text-transform: uppercase; white-space: nowrap; }
.th-nav-inner .th-primary-navigation { width:auto; max-width:100%; margin:0; }
.th-nav-inner .th-primary-navigation .wp-block-navigation__container { gap: .6rem clamp(.95rem,2vw,2.2rem); }
.th-nav-inner .th-primary-navigation .wp-block-navigation-item__content {
  color: var(--th-ink);
  text-decoration:none;
  font-size:.76rem;
  line-height:1.5;
  font-weight:700;
  text-transform:uppercase;
  letter-spacing:.09em;
  padding-block:.48rem;
  transition: color .2s ease;
}
.th-nav-inner .th-primary-navigation .wp-block-navigation-item__content:hover,
.th-nav-inner .th-primary-navigation .current-menu-item > .wp-block-navigation-item__content { color: var(--wp--preset--color--clay,#a56962); }
.th-nav-inner .th-primary-navigation .wp-block-navigation-item__content:focus-visible,
.th-nav-inner .th-primary-navigation button:focus-visible { outline: 2px solid var(--wp--preset--color--clay,#a56962); outline-offset:4px; }
.th-nav-inner .th-primary-navigation .wp-block-navigation__submenu-container {
  background:var(--wp--preset--color--paper,#fbf8f2);
  color:var(--th-ink);
  border:1px solid rgba(49,68,56,.13);
  padding:.45rem .3rem;
  box-shadow:0 8px 20px rgba(49,68,56,.09);
}
.th-nav-inner .th-primary-navigation .wp-block-navigation__submenu-container .wp-block-navigation-item__content { padding:.5rem .7rem; }
.th-nav-inner .wp-block-navigation__responsive-container-open { color:var(--th-ink); border: 1px solid rgba(49,68,56,.26); border-radius: 2px; padding:.28rem .4rem; }
@media (max-width: 900px) {
  .th-nav-caption { display:none; }
  .th-nav-inner { justify-content:flex-end; }
}
@media (max-width: 600px) {
  .th-header-inner { min-height:76px; padding-block:.7rem; }
  .th-nav-inner { min-height:48px; }
  .th-nav-inner .th-primary-navigation .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content { font-size:1rem; padding-block:.7rem; }
}



/* Version 1.5: native Site Editor navigation and widget-like block regions. */
.th-nav-inner .th-primary-navigation { margin-left:auto; flex: 1 1 auto; }
.th-nav-inner .th-primary-navigation .wp-block-navigation__container { justify-content: flex-end; }
.th-primary-navigation .wp-block-navigation__responsive-container.is-menu-open {
  background: var(--wp--preset--color--paper,#fbf8f2);
  color: var(--th-ink);
  padding: clamp(1rem,5vw,2rem);
}
.th-primary-navigation .wp-block-navigation__responsive-container-open,
.th-primary-navigation .wp-block-navigation__responsive-container-close { cursor: pointer; }
.th-home-widgets { margin-top: clamp(1rem,2vw,2rem); margin-bottom: 1rem; }
.th-home-widgets-columns { gap: 1rem 1.4rem; }
.th-home-widgets-columns > .wp-block-column {
  background: var(--wp--preset--color--cream,#f1ebe1);
  padding: clamp(1.1rem,1.6vw,1.6rem);
  min-width: 0;
}
.th-home-widgets h3, .th-footer-extras h3 { margin-top:0; font-size: clamp(1.2rem,2vw,1.5rem); }
.th-home-widgets ul, .th-footer-extras ul { padding-left:1.2rem; margin:0; }
.th-home-widgets li, .th-footer-extras li { margin-bottom:.3rem; }
.th-home-widgets a, .th-footer-extras a { text-decoration: none; }
.th-home-widgets a:hover, .th-footer-extras a:hover { text-decoration: underline; }
.th-footer-extras { padding-bottom:2rem; margin-bottom:1.5rem; border-bottom: 1px solid rgba(49,68,56,.15); }
.th-footer-extras-note { margin-top:0; font-size:.84rem; color: var(--th-muted); }
.th-footer-extras .wp-block-search__inside-wrapper,
.th-home-widgets .wp-block-search__inside-wrapper { max-width:100%; }
.th-main-content { min-width:0; }
@media (max-width: 781px) {
  .th-nav-inner .th-primary-navigation { flex: 0 0 auto; }
  .th-home-widgets-columns > .wp-block-column { padding:1.1rem; }
}
