/* =========================================================
   BarePress skin — generated by the design machine.
   Custom properties in :root are deterministic per domain.
   ========================================================= */

:root {
  --accent: hsl(351.556, 62%, 42%);
  --accent-dark: hsl(351.556, 62%, 33%);
  --accent-soft: hsl(351.556, 55%, 94%);
  --accent-contrast: #ffffff;
  --bg: #ffffff;
  --surface: #f5f6f8;
  --text: #16181d;
  --muted: #68707e;
  --border: #e6e8ee;
  --font-head: 'Space Grotesk', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --space: 16px;
  --gap: 12px;
  --radius: 16px;
  --radius-sm: 8px;
  --shadow: none;
  --shadow-hover: none;
  --container: 1100px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  font-size: calc(16px * 1.07);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }

/* Container */
.site-main { max-width: var(--container); margin: 0 auto; padding: var(--space); }

/* ---------- Header ---------- */
.site-header { background: var(--bg); border-bottom: 1px solid var(--border); }
.header-inner {
  max-width: var(--container); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--gap); padding: calc(var(--space) * 0.75) var(--space);
  flex-wrap: wrap;
}
.site-title { font-family: var(--font-head); font-weight: 800; font-size: 1.5rem; letter-spacing: -0.02em; }
.custom-logo { height: 44px; width: auto; max-width: 100%; }

/* variant 0 — centered */
.site-header--center .header-inner { flex-direction: column; justify-content: center; }
.site-header--center .site-title { font-size: 1.8rem; }

/* variant 1 — left + sticky */
.site-header--sticky { position: sticky; top: 0; z-index: 50; }

/* variant 2 — top bar */
.site-header--bar { border-bottom: 2px solid var(--accent); }
.site-header--bar .site-title { font-size: 1.25rem; }

/* Nav */
.site-nav .menu { list-style: none; display: flex; gap: calc(var(--gap) * 0.8); margin: 0; padding: 0; flex-wrap: wrap; }
.site-nav .menu a { font-family: var(--font-head); font-weight: 600; font-size: 0.95rem; padding: 4px 0; }
.site-nav .menu a:hover { color: var(--accent); }
.site-nav .menu .current-menu-item > a { color: var(--accent); }

/* ---------- Cards ---------- */
.card {
  background: var(--bg);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex; flex-direction: column;
}
.card-media { display: block; aspect-ratio: 3 / 2; overflow: hidden; background: var(--surface); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease; }
.card:hover .card-media img { transform: scale(1.04); }
.card-body { padding: calc(var(--gap) * 0.75); display: flex; flex-direction: column; gap: 6px; }
.card-cat {
  align-self: flex-start;
  font-family: var(--font-head); font-weight: 700; font-size: 0.72rem;
  letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--accent-dark); background: var(--accent-soft);
  padding: 3px 9px; border-radius: 999px;
}
.card-cat:hover { color: var(--accent-contrast); background: var(--accent); }
.card-title { margin: 0; font-family: var(--font-head); font-weight: 700; font-size: 1.05rem; line-height: 1.3; }
.card-title a:hover { color: var(--accent); }
.card-excerpt { margin: 0; color: var(--muted); font-size: 0.92rem; line-height: 1.55; }
.card-meta { color: var(--muted); font-size: 0.8rem; }

/* card style 0 — bordered */
.bp-card-0 .card { border: 1px solid var(--border); box-shadow: none; }
/* card style 1 — clean (subtle shadow) */
.bp-card-1 .card { border: 1px solid var(--border); box-shadow: var(--shadow); }
/* card style 2 — filled surface */
.bp-card-2 .card { border: none; background: var(--surface); box-shadow: none; }
.bp-card-2 .card-media { background: #e9ebef; }

.card:hover { box-shadow: var(--shadow-hover); }

/* ---------- Section titles ---------- */
.section-title {
  font-family: var(--font-head); font-weight: 800; font-size: 1.3rem;
  margin: calc(var(--space) * 1.4) 0 var(--gap);
  padding-left: 12px; border-left: 4px solid var(--accent);
}
/* title style 1 — underline */
.bp-title-1 .section-title { border-left: none; padding-left: 0; border-bottom: 2px solid var(--accent); padding-bottom: 6px; }
/* title style 2 — boxed */
.bp-title-2 .section-title { border-left: none; padding-left: 0; background: var(--accent-soft); color: var(--accent-dark); padding: 6px 12px; border-radius: var(--radius-sm); }

/* ---------- Homepage 0: hero ---------- */
.home-hero { display: grid; grid-template-columns: 2fr 1fr; gap: var(--gap); }
.card--hero .card-media { aspect-ratio: 16 / 9; }
.card--hero .card-title { font-size: 1.9rem; }
.card--hero .card-excerpt { font-size: 1rem; }
.hero-side { display: flex; flex-direction: column; gap: var(--gap); }
.hero-side .card { flex-direction: row; }
.hero-side .card-media { width: 40%; aspect-ratio: auto; min-height: 100%; }
.hero-side .card-title { font-size: 0.95rem; }

/* ---------- Homepage 1: featured ---------- */
.home-featured { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); }
.card--featured .card-title { font-size: 1.3rem; }

/* ---------- Homepage 2: lead list ---------- */
.home-lead { display: flex; flex-direction: column; gap: var(--gap); margin-bottom: var(--space); }
.card--lead { border-bottom: 1px solid var(--border); border-radius: 0; }
.card--lead .card-title { font-size: 1.4rem; }

/* ---------- Grids ---------- */
.home-grid { display: grid; gap: var(--gap); }
.home-grid--two { grid-template-columns: 1fr 1fr; }
.home-grid--three { grid-template-columns: repeat(3, 1fr); }
.home-grid--four { grid-template-columns: repeat(4, 1fr); }
.home-grid--compact { grid-template-columns: repeat(3, 1fr); }

/* ---------- Single article ---------- */
.single { max-width: 760px; margin: 0 auto; }
.single-header { margin: var(--space) 0; }
.single-title { font-family: var(--font-head); font-weight: 800; font-size: 2.1rem; line-height: 1.2; margin: 12px 0; }
.single-meta { color: var(--muted); font-size: 0.9rem; display: flex; gap: 12px; }
.single-thumb { margin: 0 0 var(--space); border-radius: var(--radius); overflow: hidden; }
.single-content { font-size: 1.08rem; line-height: 1.75; }
.single-content h2, .single-content h3 { font-family: var(--font-head); line-height: 1.3; margin-top: 1.6em; }
/* Cap heading sizes in article content — fixes giant subtitles/FAQ headings that old
   themes/Gutenberg block font-sizes leave behind. !important so it beats inline styles. */
.single-content h1 { font-size: 1.7rem !important; }
.single-content h2 { font-size: 1.4rem !important; }
.single-content h3 { font-size: 1.2rem !important; }
.single-content h4 { font-size: 1.05rem !important; }
.single-content h5, .single-content h6 { font-size: 0.95rem !important; }
.single-content a { color: var(--accent); text-decoration: underline; }
.single-content img { border-radius: var(--radius-sm); }

/* ---------- Archive ---------- */
.archive-header { margin: var(--space) 0; }
.archive-title { font-family: var(--font-head); font-weight: 800; font-size: 1.8rem; margin: 0; }
.archive-desc { color: var(--muted); }

/* ---------- Pagination ---------- */
.nav-links { display: flex; gap: 8px; justify-content: center; margin: var(--space) 0; flex-wrap: wrap; }
.nav-links a, .nav-links span { padding: 8px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 0.9rem; }
.nav-links .current { background: var(--accent); color: var(--accent-contrast); border-color: var(--accent); }
.nav-links a:hover { border-color: var(--accent); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); margin-top: calc(var(--space) * 2); }
.footer-inner { max-width: var(--container); margin: 0 auto; padding: var(--space); }
.site-footer--simple { text-align: center; color: var(--muted); font-size: 0.9rem; }
.site-footer--columns .footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: var(--gap); }
.footer-col { color: var(--muted); font-size: 0.9rem; }
.footer-col .widget { margin: 0 0 var(--gap); }
.footer-col .widget-title { font-family: var(--font-head); font-weight: 700; font-size: 0.95rem; color: var(--text); margin: 0 0 8px; }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin: 4px 0; }
.footer-tagline { color: var(--muted); }
.footer-bottom { border-top: 1px solid var(--border); text-align: center; padding: var(--gap) var(--space); color: var(--muted); font-size: 0.85rem; }

/* ---------- 404 ---------- */
.error-404 { text-align: center; padding: calc(var(--space) * 2) 0; }
.error-title { font-family: var(--font-head); font-size: 4rem; margin: 0; color: var(--accent); }
.error-home { display: inline-block; margin-top: var(--gap); background: var(--accent); color: var(--accent-contrast); padding: 10px 20px; border-radius: var(--radius-sm); }
.error-home:hover { background: var(--accent-dark); color: var(--accent-contrast); }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .home-hero { grid-template-columns: 1fr; }
  .home-grid--four { grid-template-columns: repeat(2, 1fr); }
  .site-footer--columns .footer-inner { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .home-grid--two, .home-grid--three, .home-grid--four, .home-grid--compact, .home-featured { grid-template-columns: 1fr; }
  .single-title { font-size: 1.6rem; }
  .card--hero .card-title { font-size: 1.4rem; }
  .hero-side .card { flex-direction: column; }
  .hero-side .card-media { width: 100%; }
}

/* ---------- Card layout 1: horizontal ---------- */
.card--l1 { flex-direction: row; }
.card--l1 .card-media { width: 38%; aspect-ratio: auto; min-height: 100%; flex-shrink: 0; }
.card--l1 .card-body { flex: 1; }

/* ---------- Card layout 2: overlay ---------- */
.card--l2 { position: relative; }
.card--l2 .card-shade {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,0.78) 100%);
  pointer-events: none;
}
.card--l2 .card-body--overlay {
  position: absolute; left: 0; right: 0; bottom: 0;
  color: #fff; padding: calc(var(--gap) * 0.75);
}
.card--l2 .card-title a, .card--l2 .card-meta { color: #fff; }
.card--l2 .card-title a:hover { color: #fff; }
.card--l2 .card-cat { background: var(--accent); color: #fff; }

/* ---------- Card layout 3: list (small thumb + text) ---------- */
.card--l3 { flex-direction: row; align-items: center; border-bottom: 1px solid var(--border); padding-bottom: var(--gap); }
.card--l3 .card-media { width: 96px; height: 64px; aspect-ratio: auto; flex-shrink: 0; }
.card--l3 .card-body { flex: 1; padding: 0 0 0 var(--gap); }
.card--l3, .card--l3:hover { box-shadow: none; }
.card--l3 .card-title { font-size: 1.05rem; }

/* ---------- Header 3: split ---------- */
.site-header--split .header-inner { justify-content: flex-start; }
.site-header--split .header-navrow { border-top: 1px solid var(--border); }
.site-header--split .header-navrow .header-inner { padding-top: 0; padding-bottom: 0; }

/* ---------- Header 4: masthead ---------- */
.site-header--masthead .header-inner { flex-direction: column; text-align: center; justify-content: center; }
.site-header--masthead .site-title { font-size: 2.2rem; }
.site-tagline { color: var(--muted); margin: 4px 0 var(--gap); font-size: 0.95rem; }

/* ---------- Homepage 4: full-width hero ---------- */
.home-hero--full { display: block; }
.home-hero--full .card--hero .card-media { aspect-ratio: 21 / 9; }
.home-hero--full .card--hero .card-title { font-size: 2.2rem; }

/* ---------- Homepage 5: sidebar ---------- */
.home-layout--sidebar { display: grid; grid-template-columns: 1fr 320px; gap: var(--gap); align-items: start; }
.home-sidebar .widget { margin-bottom: var(--space); }
.home-sidebar .widget-title { font-family: var(--font-head); font-weight: 700; font-size: 1rem; margin: 0 0 10px; }

/* ---------- Footer 2: bar ---------- */
.site-footer--bar { text-align: center; padding: var(--gap) 0; font-size: 0.85rem; color: var(--muted); border-top: 2px solid var(--accent); }

/* ---------- Responsive for new variants ---------- */
@media (max-width: 960px) {
  .home-layout--sidebar { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .card--l1 { flex-direction: column; }
  .card--l1 .card-media { width: 100%; aspect-ratio: 3 / 2; min-height: 0; }
  .home-hero--full .card--hero .card-title { font-size: 1.4rem; }
  .site-header--masthead .site-title { font-size: 1.7rem; }
}

/* ---------- Rebuild: category sections + related ---------- */
.home-cat-section { margin-bottom: calc(var(--space) * 1.6); }
.home-cat-head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--gap); }
.home-cat-head .section-title { margin-top: 0; }
.home-cat-head .more { font-family: var(--font-head); font-weight: 600; font-size: 0.9rem; color: var(--muted); white-space: nowrap; }
.home-cat-head .more:hover { color: var(--accent); }
.related-posts { margin-top: calc(var(--space) * 2); }
@media (max-width: 640px) {
  .home-cat-head { flex-direction: column; align-items: flex-start; gap: 6px; }
}

/* ---------- extra header variants (5 dark, 6 minimal) ---------- */
.site-header--dark { background: var(--text); border-bottom-color: rgba(255,255,255,0.12); }
.site-header--dark .site-title, .site-header--dark .site-nav .menu a { color: #fff; }
.site-header--dark .site-tagline { color: rgba(255,255,255,0.7); }
.site-header--minimal .site-nav { display: none; }

/* ---------- extra footer variants (3 dark, 4 two-column) ---------- */
.site-footer--dark { background: var(--text); color: #fff; border-top-color: rgba(255,255,255,0.12); }
.site-footer--dark a, .site-footer--dark .footer-col, .site-footer--dark .footer-tagline { color: rgba(255,255,255,0.85); }
.site-footer--twocol .footer-inner { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); align-items: center; }

/* ---------- extra card layouts (4 accent-border, 5 image-right) ---------- */
.card--l4 { border-top: 4px solid var(--accent); }
.card--l5 { flex-direction: row-reverse; }
.card--l5 .card-media { width: 38%; aspect-ratio: auto; min-height: 100%; flex-shrink: 0; }
.card--l5 .card-body { flex: 1; }
@media (max-width: 640px) {
  .card--l5 { flex-direction: column; }
  .card--l5 .card-media { width: 100%; aspect-ratio: 3 / 2; min-height: 0; }
}
