/*
Theme Name: Playbook of Beauty Redesign
Theme URI: https://playbookof Beauty.com
Author: Playbook of Beauty
Author URI: https://playbookofbeauty.com
Description: A modern, sleek redesign for Playbook of Beauty featuring a black & white + burnt orange accent theme with square (1:1) color covers.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: pob-theme
Tags: blog, news, beauty, magazine, custom-menu, featured-images
*/

/* =====================================================================
   PLAYBOOK OF BEAUTY — Premium redesign
   Theme: Black & white + burnt orange accent. Square (1:1) color covers.
   ===================================================================== */

:root {
  --ink:        #111111;
  --ink-soft:   #444444;
  --paper:      #ffffff;
  --rule:       #d8d4cc;
  --rule-strong:#111111;
  --accent:     #BA4609;
  --bg-tint:    #faf8f4;
  --muted:      #6b6b6b;

  --serif: "Playfair Display", "Source Serif 4", Georgia, "Times New Roman", serif;
  --logo:  "Besley", "Playfair Display", "Source Serif 4", Georgia, serif;
  --serif-text: "Source Serif 4", "Lora", Georgia, serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}

@font-face {
  font-family: "Besley";
  src: url("assets/fonts/Besley-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  font-family: var(--serif-text);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.5;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }
img { max-width: 100%; display: block; }

.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Fade-in on load ---------- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
.lead, .card, .newsletter, .related {
  animation: fadeUp .6s ease both;
}
.card:nth-child(2) { animation-delay: .08s; }
.card:nth-child(3) { animation-delay: .16s; }
.card:nth-child(4) { animation-delay: .24s; }
.card:nth-child(5) { animation-delay: .32s; }
.card:nth-child(6) { animation-delay: .40s; }

/* ---------- Sticky top bar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--paper);
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.02em;
}
.topbar .wrap {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  height: 44px;
  color: var(--ink-soft);
}
.topbar .left {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  min-width: 0;
}
.topbar .right { justify-self: end; display: flex; gap: 14px; align-items: center; }
.topbar .center { justify-self: center; }
.topbar .date { text-transform: capitalize; font-size: 12px; color: var(--muted); }
.topbar-logo {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  display: block;
  max-width: min(560px, 52vw);
  overflow: visible;
  opacity: 0;
  visibility: hidden;
  color: var(--ink);
  font-family: var(--logo);
  font-weight: 400;
  font-size: 24px;
  line-height: 1;
  letter-spacing: 0.04em;
  white-space: nowrap;
  text-transform: uppercase;
  text-align: center;
  pointer-events: none;
  transform: translate(-50%, calc(-50% + 3px));
  transition: opacity .16s ease, visibility .16s ease, transform .16s ease;
}
.topbar.has-compact-logo .topbar-logo {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translate(-50%, -50%);
}
.topbar-logo:hover { color: var(--accent); }
.topbar .left,
.topbar .right {
  position: relative;
  z-index: 3;
}
.topbar nav a {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0 14px;
  display: inline-block;
  line-height: 44px;
  position: relative;
}
.topbar nav a::after {
  content: '';
  position: absolute;
  bottom: 10px;
  left: 14px;
  right: 14px;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform .25s ease;
}
.topbar nav a.active::after { transform: scaleX(1); }
.topbar nav a:hover::after { transform: scaleX(1); }
.topbar nav a:hover { color: var(--accent); }

/* ---------- Inline search ---------- */
.topbar-search {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.search-toggle {
  background: none;
  border: 1px solid var(--rule);
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 14px;
  color: var(--ink-soft);
  transition: border-color .15s ease, color .15s ease;
  flex-shrink: 0;
}
.search-toggle:hover { border-color: var(--ink); color: var(--ink); }
.topbar-search.is-open .search-toggle {
  border-color: var(--ink);
  color: var(--ink);
}
.search-panel {
  position: relative;
  width: 0;
  opacity: 0;
  pointer-events: none;
  transition: width .2s ease, opacity .15s ease;
}
.topbar-search.is-open .search-panel {
  width: min(280px, 28vw);
  opacity: 1;
  pointer-events: auto;
}
.search-field {
  width: 100%;
  height: 30px;
  border: 1px solid var(--rule);
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 13px;
  line-height: 30px;
  padding: 0 10px;
}
.search-field:focus {
  outline: 2px solid var(--accent);
  outline-offset: 0;
  border-color: var(--accent);
}
.search-suggestions {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: min(360px, 82vw);
  max-height: 340px;
  overflow-y: auto;
  background: var(--paper);
  border: 1px solid var(--rule);
  box-shadow: 0 14px 34px rgba(0,0,0,0.12);
  display: none;
  z-index: 200;
}
.search-suggestions.is-visible { display: block; }
.search-suggestion,
.search-empty {
  display: block;
  padding: 12px 14px;
  border-bottom: 1px solid var(--rule);
  text-align: left;
}
.search-suggestion:last-child,
.search-empty:last-child { border-bottom: none; }
.search-suggestion:hover,
.search-suggestion:focus {
  background: var(--bg-tint);
  color: var(--ink);
}
.search-suggestion .kicker {
  display: block;
  color: var(--accent);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.search-suggestion .title {
  display: block;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: 0;
  text-transform: none;
}
.search-suggestion .date,
.search-empty {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.02em;
  text-transform: none;
}

.btn-subscribe {
  background: var(--ink);
  color: #fff !important;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 7px 16px;
  border: 1px solid var(--ink);
  transition: background .15s ease, border-color .15s ease;
}
.btn-subscribe:hover { background: var(--accent); color: #fff !important; border-color: var(--accent); }

.btn-linkedin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--ink);
  border: 1px solid var(--ink);
  transition: background .15s ease;
  flex-shrink: 0;
}
.btn-linkedin:hover { background: var(--ink-soft); }
.btn-linkedin svg { width: 16px; height: 16px; }

/* ---------- Masthead ---------- */
.masthead {
  text-align: center;
  padding: 30px 24px 22px;
  border-bottom: 1px solid var(--rule);
}
.masthead .logo {
  font-family: var(--logo);
  font-weight: 400;
  font-size: clamp(30px, 5.5vw, 58px);
  letter-spacing: 0.04em;
  line-height: 1;
  color: var(--ink);
  display: block;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
}
.masthead .tagline {
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 12px;
}

/* ---------- Lead story ---------- */
.lead {
  padding: 40px 0 32px;
  border-bottom: 1px solid var(--rule);
}
.lead-grid {
  display: grid;
  grid-template-columns: 0.6fr 1fr;
  gap: 32px;
  align-items: center;
}
.lead .lead-image {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #eee;
}
.lead .lead-image img { width: 100%; height: 100%; object-fit: cover; }
.lead .kicker { font-family: var(--sans); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
.lead h1 {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(22px, 2.8vw, 34px);
  line-height: 1.15; /* 5) More breathing room */
  letter-spacing: -0.01em;
  margin: 12px 0 16px;
}
.lead h1:hover { color: var(--accent); cursor: pointer; }
.lead .excerpt { font-size: 18px; color: var(--ink-soft); line-height: 1.55; }
.lead .meta { font-family: var(--sans); font-size: 12px; color: var(--muted); margin-top: 18px; letter-spacing: 0.03em; }

/* ---------- Section heading ---------- */
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 30px 0 18px;
}
.section-head h2 {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink);
}

/* ---------- Article grid ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}
.card {
  padding: 26px 22px 30px;
}
.card .cover {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #eee;
  margin-bottom: 16px;
}
.card .cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.card:hover .cover img { transform: scale(1.03); }
.card .kicker { font-family: var(--sans); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
.card h3 {
  font-family: var(--serif);
  font-weight: 700;
  font-size: 21px;
  line-height: 1.15; /* 5) Breathing room */
  margin: 8px 0 10px;
  letter-spacing: -0.005em;
}
.card:hover h3 { color: var(--accent); }
.card .excerpt { font-size: 14.5px; color: var(--ink-soft); line-height: 1.5; }
.card .meta { font-family: var(--sans); font-size: 11.5px; color: var(--muted); margin-top: 12px; letter-spacing: 0.02em; }

/* ---------- Search results ---------- */
.search-page {
  padding-top: 36px;
  padding-bottom: 50px;
}
.search-header {
  border-bottom: 1px solid var(--rule);
  margin-bottom: 30px;
  padding-bottom: 18px;
}
.search-header .kicker {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
}
.search-header h1 {
  font-family: var(--serif);
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 800;
  line-height: 1.08;
  margin-top: 8px;
}
.search-results {
  margin-top: 0;
}
.search-empty-state {
  color: var(--ink-soft);
  font-size: 18px;
  padding: 34px 0;
}
.pagination {
  border-top: 1px solid var(--rule);
  font-family: var(--sans);
  font-size: 13px;
  margin-top: 30px;
  padding-top: 20px;
}
.pagination .nav-links {
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}
.pagination a,
.pagination span {
  border: 1px solid var(--rule);
  color: var(--ink);
  display: inline-block;
  min-width: 34px;
  padding: 7px 10px;
  text-align: center;
}
.pagination .current,
.pagination a:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

/* ---------- Newsletter band ---------- */
.newsletter {
  background: var(--bg-tint);
  padding: 48px 0;
  margin-top: 40px;
  text-align: center;
}
.newsletter .nl-inner { max-width: 620px; margin: 0 auto; }
.newsletter .kicker { font-family: var(--sans); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
.newsletter h2 {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(24px, 3vw, 34px);
  margin: 10px 0 10px;
}
.newsletter p { color: var(--ink-soft); font-size: 16px; margin-bottom: 22px; }
.newsletter .nl-form {
  display: flex;
  gap: 8px;
  max-width: 440px;
  margin: 0 auto;
}
.newsletter input[type="email"] {
  flex: 1;
  padding: 12px 14px;
  border: 1px solid #c9c4ba;
  font-family: var(--sans);
  font-size: 14px;
  background: #fff;
}
.newsletter input[type="email"]:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.newsletter button {
  background: var(--ink);
  color: #fff;
  border: none;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 12px 22px;
  cursor: pointer;
  transition: background .15s ease;
}
.newsletter button:hover { background: var(--accent); }

/* ---------- Article page ---------- */
.article-page { max-width: 720px; margin: 0 auto; padding: 40px 24px 60px; }
.article-page .kicker { font-family: var(--sans); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
.article-page h1 {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.15; /* 5) Breathing room */
  letter-spacing: -0.01em;
  margin: 12px 0 16px;
}
.article-page .meta { font-family: var(--sans); font-size: 12px; color: var(--muted); margin-bottom: 28px; letter-spacing: 0.03em; }
.article-page .hero { aspect-ratio: 1 / 1; overflow: hidden; margin-bottom: 32px; }
.article-page .hero img { width: 100%; height: 100%; object-fit: cover; }
.article-page .body-text { font-family: var(--serif-text); font-size: 18px; line-height: 1.7; color: var(--ink-soft); }
.article-page .body-text p { margin-bottom: 22px; }
.article-page .body-text img { margin-bottom: 22px; }
.article-page .body-text p:first-of-type::first-letter {
  font-family: var(--serif);
  font-weight: 800;
  font-size: 3.4em;
  float: left;
  line-height: 0.8;
  margin: 4px 10px 0 0;
  color: var(--ink);
}
.article-page .body-text h2 {
  font-family: var(--serif);
  font-weight: 800;
  font-size: 26px;
  margin: 36px 0 16px;
  color: var(--ink);
  line-height: 1.15;
}
.article-page .body-text blockquote {
  border-left: 3px solid var(--accent);
  padding: 12px 0 12px 20px;
  margin: 28px 0;
  font-style: italic;
  font-size: 19px;
  color: var(--ink);
}
.article-page .share-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 24px 0;
  margin-top: 40px;
  font-family: var(--sans);
  font-size: 13px;
}
.article-page .share-bar span { font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; font-size: 11px; color: var(--muted); }
.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--rule);
  border-radius: 4px; /* 10) Rounded corners */
  font-size: 14px;
  transition: border-color .15s ease, color .15s ease;
}
.share-btn:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- Newsletter in article ---------- */
.article-newsletter {
  background: var(--bg-tint);
  padding: 36px;
  text-align: center;
  margin: 40px 0 0;
}
.article-newsletter .kicker { font-family: var(--sans); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
.article-newsletter h3 { font-family: var(--serif); font-weight: 800; font-size: 22px; margin: 10px 0 8px; }
.article-newsletter p { font-size: 15px; color: var(--ink-soft); margin-bottom: 18px; }
.article-newsletter .nl-form {
  display: flex;
  gap: 8px;
  max-width: 380px;
  margin: 0 auto;
}
.article-newsletter input[type="email"] {
  flex: 1;
  padding: 11px 14px;
  border: 1px solid #c9c4ba;
  font-family: var(--sans);
  font-size: 14px;
  background: #fff;
}
.article-newsletter input[type="email"]:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.article-newsletter button { background: var(--ink); color: #fff; border: none; font-family: var(--sans); font-weight: 600; font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; padding: 11px 20px; cursor: pointer; transition: background .15s ease; }
.article-newsletter button:hover { background: var(--accent); }

/* ---------- Related articles ---------- */
.related { padding: 40px 0; }
.related h2 { font-family: var(--serif); font-weight: 800; font-size: 22px; margin-bottom: 24px; }
.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.related .card { padding: 0; }
.related .card .cover { margin-bottom: 12px; }

/* ---------- Footer ---------- */
footer {
  border-top: 1px solid var(--rule);
  padding: 40px 0 30px;
  font-family: var(--sans);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 30px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--rule);
}
footer h4 { font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink); margin-bottom: 12px; }
footer ul { list-style: none; }
footer li { margin-bottom: 7px; }
footer a { font-size: 13px; color: var(--ink-soft); }
footer .brand { font-family: var(--logo); font-weight: 400; font-size: 20px; margin-bottom: 8px; }
footer .brand-desc { font-size: 13px; color: var(--muted); line-height: 1.5; }
.footer-content { padding-bottom: 28px; border-bottom: 1px solid var(--rule); }
.footer-content .brand { margin-bottom: 10px; }
.footer-bottom { display: flex; align-items: baseline; gap: 18px; }
.footer-bottom .brand-desc { margin-bottom: 0; flex: 1; }
.footer-links { display: flex; align-items: center; gap: 14px; }
.footer-contact { font-family: var(--sans); font-size: 13px; color: var(--ink-soft); white-space: nowrap; }
.footer-contact:hover { color: var(--accent); }
.footer-cookie-settings {
  background: transparent;
  border: none;
  color: var(--ink-soft);
  cursor: pointer;
  font-family: var(--sans);
  font-size: 13px;
  padding: 0;
  white-space: nowrap;
}
.footer-cookie-settings:hover { color: var(--accent); }
.copyright { border-top: 1px solid var(--rule); }
.copyright { padding-top: 18px; font-size: 12px; color: var(--muted); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }

/* ---------- Cookie consent ---------- */
.cookie-banner[hidden],
.cookie-modal[hidden] { display: none; }
.cookie-banner {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: min(520px, calc(100vw - 40px));
  background: var(--paper);
  border: 1px solid var(--rule);
  box-shadow: 0 18px 46px rgba(0,0,0,0.14);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  padding: 20px;
  z-index: 100000;
}
.cookie-banner .kicker,
.cookie-modal .kicker {
  color: var(--accent);
  display: block;
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  margin-bottom: 7px;
  text-transform: uppercase;
}
.cookie-banner p {
  color: var(--ink-soft);
  font-family: var(--serif-text);
  font-size: 14px;
  line-height: 1.5;
  margin-bottom: 8px;
}
.cookie-banner a {
  color: var(--accent);
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.cookie-banner__actions,
.cookie-modal__actions {
  display: flex;
  gap: 8px;
}
.cookie-banner__actions {
  align-items: stretch;
  flex-direction: column;
}
.cookie-btn {
  border: 1px solid var(--ink);
  cursor: pointer;
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  min-height: 34px;
  padding: 9px 12px;
  text-transform: uppercase;
  white-space: nowrap;
}
.cookie-btn--primary {
  background: var(--ink);
  color: #fff;
}
.cookie-btn--primary:hover { background: var(--accent); border-color: var(--accent); }
.cookie-btn--secondary {
  background: var(--paper);
  color: var(--ink);
}
.cookie-btn--secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.cookie-btn--ghost {
  background: var(--bg-tint);
  border-color: var(--rule);
  color: var(--ink);
}
.cookie-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.42);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 100001;
}
.cookie-modal__panel {
  background: var(--paper);
  border: 1px solid var(--rule);
  box-shadow: 0 18px 60px rgba(0,0,0,0.22);
  max-height: min(720px, calc(100vh - 40px));
  max-width: 620px;
  overflow-y: auto;
  width: 100%;
}
.cookie-modal__header,
.cookie-modal__actions {
  padding: 18px 22px;
}
.cookie-modal__header {
  align-items: flex-start;
  border-bottom: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  gap: 18px;
}
.cookie-modal__header h2 {
  font-family: var(--serif);
  font-size: 26px;
  line-height: 1.05;
}
.cookie-modal__close {
  background: transparent;
  border: none;
  color: var(--ink);
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
}
.cookie-modal__body {
  padding: 20px 22px 4px;
}
.cookie-modal__body > p {
  color: var(--ink-soft);
  font-size: 15px;
  margin-bottom: 16px;
}
.cookie-choice {
  align-items: center;
  border-top: 1px solid var(--rule);
  display: flex;
  gap: 18px;
  justify-content: space-between;
  padding: 16px 0;
}
.cookie-choice h3 {
  font-family: var(--serif);
  font-size: 18px;
  margin-bottom: 3px;
}
.cookie-choice p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}
.cookie-always {
  color: var(--accent);
  flex-shrink: 0;
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.cookie-switch {
  flex-shrink: 0;
  position: relative;
}
.cookie-switch input {
  opacity: 0;
  position: absolute;
}
.cookie-switch span {
  background: var(--rule);
  cursor: pointer;
  display: block;
  height: 26px;
  position: relative;
  transition: background .18s ease;
  width: 48px;
}
.cookie-switch span::after {
  background: #fff;
  content: '';
  height: 20px;
  left: 3px;
  position: absolute;
  top: 3px;
  transition: transform .18s ease;
  width: 20px;
}
.cookie-switch input:checked + span {
  background: var(--accent);
}
.cookie-switch input:checked + span::after {
  transform: translateX(22px);
}
.cookie-modal__actions {
  border-top: 1px solid var(--rule);
  justify-content: flex-end;
}

/* ---------- Responsive ---------- */

/* Tablet */
@media (max-width: 900px) {
  .lead-grid { grid-template-columns: 1fr; gap: 24px; }
  .lead h1 { font-size: 26px; }
  .topbar .date { display: none; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr; gap: 22px; }
  .related-grid { grid-template-columns: repeat(2, 1fr); }
  .article-page .body-text { font-size: 17px; }
}

/* Mobile */
@media (max-width: 640px) {
  body { font-size: 16px; }
  .topbar {
    position: sticky;
    top: 0;
    border-bottom: 1px solid var(--rule);
  }
  .topbar .wrap {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 10px;
    height: 54px;
    align-items: center;
    justify-content: stretch;
    padding: 0 16px;
  }
  .topbar .left {
    min-width: 0;
  }
  .topbar .date { display: none; }
  .topbar-logo {
    font-size: clamp(15px, 4vw, 19px);
    line-height: 1.18;
    letter-spacing: 0.04em;
    max-width: min(60vw, 260px);
    opacity: 0;
    visibility: hidden;
    transform: translate(-50%, calc(-50% + 2px));
  }
  .topbar.has-compact-logo .topbar-logo {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%);
  }
  .topbar.has-open-search .topbar-logo,
  .topbar:has(.topbar-search.is-open) .topbar-logo {
    opacity: 0;
    visibility: hidden;
  }
  .topbar .center { display: none; }
  .topbar .right {
    align-items: center;
    justify-content: flex-end;
    width: 100%;
    min-width: 0;
    gap: 8px;
  }
  .topbar .right .btn-subscribe,
  .topbar .right .btn-linkedin { display: none; }
  .topbar .right .topbar-search {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    width: 100%;
    min-height: 34px;
  }
  .topbar .right .search-toggle {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: center;
    line-height: 1;
  }
  .search-panel {
    flex: 0 1 auto;
    max-width: calc(100vw - 68px);
  }
  .topbar-search.is-open .search-panel {
    flex: 1 1 auto;
    width: auto;
    max-width: calc(100vw - 68px);
  }
  .search-field {
    height: 34px;
    line-height: 34px;
    font-size: 16px;
  }
  .search-suggestions {
    left: auto;
    right: 0;
    max-height: 280px;
    width: calc(100vw - 32px);
  }
  .masthead { padding: 22px 16px 16px; }
  .masthead .logo { font-size: clamp(26px, 8vw, 42px); }
  .masthead .tagline { font-size: 9px; margin-top: 8px; white-space: nowrap; }
  .lead { padding: 24px 0 20px; border-bottom: none; }
  .lead h1 { font-size: 19px; }
  .lead .excerpt { font-size: 14px; }
  .section-head { display: none; }
  .grid { grid-template-columns: 1fr; }
  .card { padding: 20px 0; }
  .card .cover { margin-bottom: 14px; }
  .card h3 { font-size: 19px; }
  .card .excerpt { font-size: 14px; }
  .newsletter { padding: 32px 0; margin-top: 0; }
  .newsletter h2 { font-size: 18px; }
  .newsletter p { display: none; }
  .newsletter .nl-form { flex-direction: column; }
  .newsletter input[type="email"] { width: 100%; }
  .footer-content { display: none; }
  .copyright { flex-direction: column; border-top: none; padding-top: 0; }
  .article-page { padding: 24px 16px 40px; }
  .article-page h1 { font-size: 26px; }
  .article-page .body-text { font-size: 16px; }
  .article-page .body-text h2 { font-size: 22px; margin: 28px 0 14px; }
  .article-page .body-text blockquote { font-size: 17px; padding-left: 16px; }
  .article-newsletter { padding: 32px 0; margin-top: 0; text-align: center; }
  .article-newsletter h3 { font-size: 18px; }
  .article-newsletter p { display: none; }
  .article-newsletter .nl-form { flex-direction: column; max-width: 440px; margin: 0 auto; }
  .article-newsletter input[type="email"] { width: 100%; }
  .related-grid { grid-template-columns: 1fr; }
  .related .card { padding: 16px 0; }
  .cookie-banner {
    bottom: 14px;
    grid-template-columns: 1fr;
    left: 14px;
    max-height: calc(100dvh - 28px);
    overflow-y: auto;
    right: 14px;
    width: auto;
  }
  .cookie-banner__actions,
  .cookie-modal__actions {
    flex-direction: column;
  }
  .cookie-modal {
    align-items: flex-end;
    padding: 0;
  }
  .cookie-modal__panel {
    border-width: 1px 0 0;
    max-height: 88dvh;
  }
  .cookie-modal__header,
  .cookie-modal__actions {
    padding: 16px;
  }
  .cookie-modal__body {
    padding: 16px 16px 4px;
  }
  .cookie-choice {
    align-items: flex-start;
    gap: 12px;
  }
  .cookie-choice h3 {
    font-size: 17px;
  }
  .cookie-choice p {
    font-size: 12.5px;
  }
  .cookie-btn {
    width: 100%;
  }
}

/* Small mobile */
@media (max-width: 380px) {
  .masthead .logo { font-size: 22px; }
  .lead h1 { font-size: 19px; }
  .article-page h1 { font-size: 23px; }
  .btn-subscribe { padding: 6px 12px; font-size: 11px; }
}

.load-more-wrap {
  text-align: center;
  padding: 20px 0;
}
.btn-load-more {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--ink);
  color: var(--paper);
  border: none;
  padding: 14px 40px;
  cursor: pointer;
  transition: background 0.15s ease;
}
.btn-load-more:hover {
  background: var(--ink-soft);
}
.btn-load-more:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
