:root {
  --pm-margin-desktop: 5rem;
  --pm-margin-tablet: 2.5rem;
  --pm-margin-mobile: 1.25rem;
  --pm-header-h: 4.5rem;
  --pm-brass: #8c7348;
  --pm-brass-dark: #725b32;
  --pm-hairline: #e6e2d8;
  --pm-ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

* { border-color: #e7e1d4; }
html { scroll-behavior: smooth; }
[id] { scroll-margin-top: calc(var(--pm-header-h) + 1rem); }
body { font-family: 'Plus Jakarta Sans', system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
::selection { background-color: #e6e2d8; color: #1c1c16; }

.tnum, .tabular-nums { font-variant-numeric: tabular-nums; }
.hairline-b { border-bottom: 1px solid var(--pm-hairline); }
.hairline-t { border-top: 1px solid var(--pm-hairline); }
.hairline-l { border-left: 1px solid var(--pm-hairline); }
.hairline-r { border-right: 1px solid var(--pm-hairline); }
.hairline-all { border: 1px solid var(--pm-hairline); }
.hairline-brass { border-color: var(--pm-brass-dark); }
.hairline-ink { border-color: #1c1c16; }
.brass-hairline { border-color: var(--pm-brass); }
.brass-hairline-l { border-left: 1.5px solid var(--pm-brass); }
.brass-bottom-hover:hover { border-bottom-color: var(--pm-brass) !important; }
.paper-scrim { background-color: rgba(20, 20, 20, 0.35); }

.brass-hairline-b { position: relative; }
.brass-hairline-b::after {
  content: ''; position: absolute; bottom: -4px; left: 0; width: 100%; height: 1px; background-color: var(--pm-brass);
}
.brass-hover { position: relative; transition: color 0.15s ease; }
.brass-hover::after {
  content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 1px;
  background-color: var(--pm-brass-dark); transition: width 0.2s ease;
}
.brass-hover:hover::after { width: 100%; }

.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 20;
  vertical-align: middle;
  display: inline-block;
  line-height: 1;
}
body.compact-icons .material-symbols-outlined { font-size: 1.15rem; }

input:focus, textarea:focus { outline: none; }
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #f4f0e6; }
::-webkit-scrollbar-thumb { background: #e6e2d8; }
::-webkit-scrollbar-thumb:hover { background: var(--pm-brass-dark); }
.custom-scroll::-webkit-scrollbar { width: 4px; }
.custom-scroll::-webkit-scrollbar-track { background: #fdf9ef; }
.custom-scroll::-webkit-scrollbar-thumb { background: #e6e2d8; }
.custom-scroll::-webkit-scrollbar-thumb:hover { background: var(--pm-brass-dark); }

body.is-mobile-mock { min-height: max(884px, 100dvh); }

/* ---------- Responsive spacing & type ---------- */
@media (max-width: 1279.98px) {
  .px-margin-desktop { padding-left: var(--pm-margin-tablet) !important; padding-right: var(--pm-margin-tablet) !important; }
}
@media (max-width: 767.98px) {
  .px-margin-desktop { padding-left: var(--pm-margin-mobile) !important; padding-right: var(--pm-margin-mobile) !important; }
  .text-display-hero { font-size: 2.25rem; line-height: 2.75rem; letter-spacing: -0.01em; }
  .text-headline-lg { font-size: 1.75rem; line-height: 2.25rem; }
  .py-space-2xl { padding-top: 3rem !important; padding-bottom: 3rem !important; }
  .pt-space-2xl { padding-top: 3rem !important; }
  .pb-space-xl { padding-bottom: 2rem !important; }
}
img, video { max-width: 100%; }
table { max-width: 100%; }
.overflow-x-auto, .table-wrap { -webkit-overflow-scrolling: touch; }

/* ---------- Header ---------- */
header[class*="sticky"][class*="sticky"] { backdrop-filter: saturate(1.1); transition: box-shadow 0.25s ease, background-color 0.25s ease; }
header[class*="sticky"].is-scrolled { box-shadow: 0 1px 0 var(--pm-hairline), 0 8px 24px -16px rgba(28, 28, 22, 0.35); }
header[class*="sticky"] nav a, header[class*="sticky"] a, header[class*="sticky"] span { white-space: nowrap; }

header[class*="sticky"] .pm-nav-toggle {
  display: none; align-items: center; justify-content: center; width: 2.75rem; height: 2.75rem;
  border: 1px solid var(--pm-hairline); background: transparent; color: #1c1c16; cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
header[class*="sticky"] .pm-nav-toggle:hover { border-color: var(--pm-brass-dark); }
header[class*="sticky"] .pm-nav-toggle .material-symbols-outlined { font-size: 1.5rem; }

header[class*="sticky"] > div { flex-wrap: nowrap; gap: 1.5rem; }
header[class*="sticky"] nav { flex-wrap: nowrap; flex-shrink: 1; min-width: 0; }
header[class*="sticky"] nav a { flex-shrink: 0; white-space: nowrap; border-bottom: 1px solid transparent; }
header[class*="sticky"] nav a.is-active { color: #1c1c16; border-bottom-color: var(--pm-brass-dark); }
header[class*="sticky"] > div > :first-child { flex-shrink: 0; }
header[class*="sticky"] > div > :last-child { flex-shrink: 0; }

@media (max-width: 1099.98px) {
  header[class*="sticky"] nav.hidden { display: none !important; }
  header[class*="sticky"] .pm-nav-toggle { display: inline-flex; }
  header[class*="sticky"] .pm-hide-laptop { display: none !important; }
}
@media (min-width: 1100px) and (max-width: 1535.98px) {
  header[class*="sticky"] > div { padding-left: 1.5rem !important; padding-right: 1.5rem !important; gap: 1rem; }
  header[class*="sticky"] nav { gap: clamp(0.75rem, 1.4vw, 1.5rem) !important; }
  header[class*="sticky"] nav a { font-size: clamp(0.75rem, 0.95vw, 0.875rem); }
  header[class*="sticky"] .pm-hide-laptop { display: none !important; }
  header[class*="sticky"] > div > :last-child a { padding-left: 0.875rem; padding-right: 0.875rem; font-size: 0.8125rem; }
}
@media (max-width: 639.98px) {
  header[class*="sticky"] > div { gap: 0.75rem; }
  header[class*="sticky"] .pm-hide-mobile { display: none !important; }
}

.pm-drawer {
  position: fixed; left: 0; right: 0; top: var(--pm-header-h); bottom: 0; z-index: 40;
  background: #fdf9ef; overflow-y: auto; padding: 1.5rem var(--pm-margin-mobile) 3rem;
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s linear 0.25s;
}
body.pm-nav-open .pm-drawer { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
body.pm-nav-open { overflow: hidden; }
.pm-drawer a.pm-drawer-link {
  display: flex; justify-content: space-between; align-items: center; padding: 1.1rem 0;
  border-bottom: 1px solid var(--pm-hairline); font-family: 'Playfair Display', serif; font-size: 1.5rem; color: #1c1c16;
}
.pm-drawer a.pm-drawer-link::after { content: '→'; color: var(--pm-brass-dark); font-size: 1.1rem; }
.pm-drawer a.pm-drawer-link.is-current { color: var(--pm-brass-dark); }
.pm-drawer .pm-drawer-cta {
  display: flex; justify-content: center; margin-top: 2rem; padding: 0.95rem 1rem; background: #1c1b1b; color: #fff;
  font-weight: 600; font-size: 0.95rem;
}
.pm-drawer .pm-drawer-meta { margin-top: 1.5rem; font-size: 0.8125rem; color: #444748; line-height: 1.6; }

/* ---------- Hero slider ---------- */
.hero-slider { position: relative; height: calc(100svh - var(--pm-header-h)); min-height: 680px; max-height: 840px; }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1.1s ease; pointer-events: none; }
.hero-slide.is-active { opacity: 1; pointer-events: auto; }
.hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; transform: scale(1.08); transition: transform 8s linear; }
.hero-slide.is-active .hero-bg { transform: scale(1); }
.hero-texts { display: grid; }
.hero-text { grid-area: 1 / 1; opacity: 0; visibility: hidden; pointer-events: none; }
.hero-text > * { opacity: 0; transform: translateY(22px); transition: opacity 0.7s var(--pm-ease), transform 0.7s var(--pm-ease); }
.hero-text.is-active { opacity: 1; visibility: visible; pointer-events: auto; }
.hero-text.is-active > * { opacity: 1; transform: none; }
.hero-text.is-active > *:nth-child(1) { transition-delay: 0.25s; }
.hero-text.is-active > *:nth-child(2) { transition-delay: 0.4s; }
.hero-text.is-active > *:nth-child(3) { transition-delay: 0.55s; }
.hero-bar { position: relative; width: 1.75rem; height: 2px; background: var(--pm-hairline); overflow: hidden; border: 0; padding: 0; cursor: pointer; }
.hero-bar::before { content: ''; position: absolute; inset: 0; background: var(--pm-brass-dark); transform: scaleX(0); transform-origin: left; }
.hero-bar.is-done::before { transform: scaleX(1); }
.hero-bar.is-active::before { animation: heroBar var(--hero-interval, 7000ms) linear forwards; }
.hero-slider.is-paused .hero-bar.is-active::before { animation-play-state: paused; }
@keyframes heroBar { to { transform: scaleX(1); } }
.hero-arrow {
  width: 2.5rem; height: 2.5rem; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--pm-hairline); background: rgba(253, 249, 239, 0.85); color: #1c1c16; cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
.hero-arrow:hover { border-color: var(--pm-brass-dark); background: #fdf9ef; }
.hero-preview { transition: color 0.2s ease; cursor: pointer; text-align: left; width: 100%; background: none; border: 0; padding: 0; }
.hero-preview.is-active { color: #1c1c16; }
.hero-preview.is-active .hero-preview-arrow { opacity: 1; }
@media (max-width: 1023.98px) {
  .hero-slider { height: auto; min-height: 640px; max-height: none; }
}

/* ---------- Scroll reveal ---------- */
.js .reveal {
  opacity: 0; transform: translateY(26px);
  transition: opacity 0.9s var(--pm-ease) var(--rd, 0ms), transform 0.9s var(--pm-ease) var(--rd, 0ms);
  will-change: opacity, transform;
}
.js .reveal.reveal-left { transform: translateX(-32px); }
.js .reveal.reveal-right { transform: translateX(32px); }
.js .reveal.reveal-zoom { transform: scale(0.96); }
.js .reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .hero-bg, .hero-slide, .hero-text > * { transition: none !important; }
  html { scroll-behavior: auto; }
}

/* ---------- Article filter ---------- */
.is-filtered-out { display: none !important; }

/* ---------- Top notice strip ---------- */
@media (max-width: 639.98px) {
  .pm-topstrip > div:first-child > span:nth-child(n+3) { display: none; }
}
