/* =========================
   HERO — DESKTOP FIRST
   (no mobile rules here)
   ========================= */

:root{
  --hero-height: 70vh;        /* desktop visual height */
  --hero-min: 520px;          /* safety floor */
  --ink: #fff;
  --ink-dim: rgba(255,255,255,.78);
  --accent: #caa27b;
  --overlay: linear-gradient(to top, rgba(0,0,0,.45), rgba(0,0,0,.18) 60%, rgba(0,0,0,0));
  --ease: cubic-bezier(.2,.7,.1,1);
  --fade-ms: 900ms;
  --kenburns-s: 10s;
}

/* Frame */
html, body{ margin:0; }
.hero{
  position: relative;
  width: 100%;                 /* full content width (no forced 100vw) */
  height: min(85vh, var(--hero-height));
  min-height: var(--hero-min);
  overflow: hidden;
  background: #000;
  color: var(--ink);
  isolation: isolate;
}

.hero__slides{ position:absolute; inset:0; }

/* Slides */
.hero__slide{
  position:absolute; inset:0;
  opacity:0;
  transition: opacity var(--fade-ms) var(--ease);
  will-change: opacity, transform;
}
.hero__slide.is-active{ opacity:1; }

/* Media (edge-proof for desktop too) */
.hero__image{
  position:absolute;
  /* modest bleed is enough on desktop */
  inset: -6rem;
  width: calc(100% + 12rem);
  height: calc(100% + 12rem);
  object-fit: cover;
  object-position: center;

  /* gentle Ken Burns base scale */
  transform: translateZ(0) scale(1.12);
  backface-visibility: hidden;
  will-change: transform;
  outline: 1px solid transparent;
  filter: saturate(1.02) contrast(1.02);
}
.hero__slide.is-active .hero__image{
  animation: kenburns-desktop var(--kenburns-s) var(--ease) both;
}

/* Readability overlay */
.hero::after{
  content:"";
  position:absolute; inset:0;
  background: var(--overlay);
  pointer-events:none;
}

/* Caption */
.hero__caption{
  position:absolute; z-index:3;
  left: 56px; bottom: 72px;
  max-width: 900px;
}
.hero__caption .title{
  font-size: clamp(40px, 3.4vw, 60px);
  font-weight: 700;
  line-height: 1.1;
  margin: 0 0 .25em;
  letter-spacing: .02em;
  text-shadow: 0 3px 20px rgba(0,0,0,.5);
}
.hero__caption .sub{
  font-size: clamp(16px, 1.2vw, 20px);
  margin: 0;
  color: var(--ink-dim);
}

/* Prev/Next buttons (you use <button><img></button>) */
.hero__nav{
  position:absolute; top:50%; transform:translateY(-50%);
  z-index:4; border:0; background:none; cursor:pointer; padding:0;
}
.hero__nav img{
  width: clamp(42px, 3.8vw, 60px);
  height: clamp(42px, 3.8vw, 60px);
  display:block;
  opacity:.6;
  filter: drop-shadow(0 3px 10px rgba(0,0,0,.55));
  transition: transform .18s var(--ease), opacity .18s var(--ease), filter .18s var(--ease);
}
.hero__nav:hover img{ transform: scale(1.08); opacity: 1; }
.hero__nav:focus-visible{ outline:2px solid var(--accent); outline-offset:6px; border-radius:10px; }
.hero__nav--prev{ left: 24px; }
.hero__nav--next{ right: 24px; }

/* Dots */
.hero__dots{
  position:absolute; left:50%; transform:translateX(-50%);
  bottom: 24px; z-index:4;
  display:flex; gap: 10px;
}
.hero__dot{
  width: 10px; height: 10px; border-radius: 50%;
  background: rgba(255,255,255,.45); border: 0; padding: 0; cursor: pointer;
  transition: transform .18s var(--ease), background .18s var(--ease), box-shadow .18s var(--ease);
}
.hero__dot[aria-selected="true"]{
  background: #fff;
  transform: scale(1.35);
  box-shadow: 0 0 0 3px rgba(255,255,255,.18);
}
.hero__dot:focus-visible{ outline:2px solid var(--accent); outline-offset:2px; }

/* Animations */
@keyframes kenburns-desktop{
  0%   { transform: translateZ(0) scale(1.12); }
  100% { transform: translateZ(0) scale(1.22); }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce){
  .hero__slide, .hero__nav img, .hero__dot{ transition: none !important; }
  .hero__slide.is-active .hero__image{ animation: none !important; transform: none !important; }
}
@media (forced-colors: active){
  .hero__dot[aria-selected="true"]{ outline: 2px solid CanvasText; box-shadow: none; }
  .hero__nav:focus-visible{ outline-color: Highlight; }
}
.pg-brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  gap: 0.5rem;
  flex-shrink: 0;
}

/* Super responsive logo */
.pg-brand__mark {
  height: clamp(28px, 5vw, 48px); /* grows/shrinks smoothly by screen width */
  width: auto;
  max-width: clamp(120px, 20vw, 200px);
  object-fit: contain;
  transition: transform 0.3s ease, filter 0.3s ease;
}

/* Optional hover style (for premium sites) */
.pg-brand:hover .pg-brand__mark {
  transform: scale(1.05);
  filter: brightness(1.1);
}

/* Ensure scaling inside header stays consistent */
@media (max-width: 640px) {
  .pg-brand__mark {
    height: clamp(22px, 8vw, 40px);
    max-width: 160px;
  }
}
