/* ============================================================
   HeyBuddy.photo — style.css
   ============================================================ */

:root {
  --c-bg:          #FDF0DA;
  --c-bg-alt:      #FCF3DA;
  --c-bg-alt:      #fffbf1;
  --c-bg-alt:      hsl(43, 100%, 95%);
  --c-bg-alt-2:    #FCE3DA;
  --c-bg-dark:     #2c2c24;
  --c-nav-hover-bg:#f3d8ce;
  --c-text:        #2c2c24;
  --c-text:        #3a2603;
  --c-text-muted:  #6b6558;
  --c-text-light:  #9c9488;
  --c-accent:      #433b23;
  --c-accent:      #a54f4a;
  --c-accent-dark: #b64b20;
  --c-accent-dark: #a54f4a;
  --c-accent-warm: #c4a882;
  --c-accent-warm-dark: #7a5e38;
  --c-border:      rgba(44,44,36,0.1);
  --c-border-med:  rgba(44,44,36,0.18);
  --c-focus:       #56597F;
  /* nav-cta: ciemne tło + biały tekst = kontrast ~9:1 */
  --c-cta-bg:      #D25625;
  --c-cta-bg:      #a54f4a;
  --font-serif:    "Cormorant Garamond", Georgia, serif;
  --font-sans:     "Manrope", sans-serif;
  --max-w:         1440px;
  --px:            clamp(1.25rem, 5vw, 3.5rem);
  --section-gap:   clamp(4rem, 8vw, 8rem);
  --radius:        4px;
  --nav-h:         80px;
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); }
body {
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }

/* ── FOCUS ── */
:focus-visible {
  outline: 2px solid var(--c-focus);
  outline-offset: 3px;
  border-radius: 4px;
}
.nav-cta:focus-visible,
.btn-primary:focus-visible,
.btn-ghost:focus-visible {
  outline-offset: 4px;
  border-radius: 100px;
}
.nav-links a:focus-visible { outline-offset: 2px; border-radius: 8px; }
.footer-nav a:focus-visible,
.footer-right a:focus-visible,
.footer-legal a:focus-visible { outline-color: #fff; }

/* ── SKIP LINK ── */
.skip-link {
  position: absolute; top: -100%; left: 1rem; z-index: 200;
  background: var(--c-focus); color: #fff;
  padding: 0.75rem 1.25rem;
  border-radius: 0 0 var(--radius) var(--radius);
  font-size: 1rem; font-weight: 600;
  font-family: var(--font-sans); text-decoration: none;
  transition: top 0.1s;
}
.skip-link:focus { top: 0; outline: 2px solid #fff; outline-offset: 2px; }

/* ── NAV ── */
nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--c-bg);
  border-bottom: 1px solid var(--c-border);
  height: var(--nav-h);
  transition: box-shadow 0.3s;
}
nav.shadow { box-shadow: 0 2px 20px rgba(44,44,36,0.1); }
.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--px);
  height: 100%;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo svg { height: 48px; width: auto; display: block; color: var(--c-text); }
.nav-links { display: flex; gap: 0.25rem; list-style: none; }
.nav-links a {
  font-size: 1rem; font-weight: 500;
  color: var(--c-text-muted); padding: 0.5rem 0.75rem; border-radius: 8px;
  transition: color 0.2s, background 0.2s;
}
.nav-links a:hover { color: var(--c-text); background: var(--c-nav-hover-bg); }
.nav-links a[aria-current="page"] { color: var(--c-accent-dark); font-weight: 600; }

/* CTA — ciemne tło, biały tekst, kontrast > 7:1 */
.nav-cta {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.5rem 1.25rem;
  background: var(--c-cta-bg); color: #fff;
  border-radius: 100px; font-size: 1rem; font-weight: 600;
  transition: background 0.2s, transform 0.15s; white-space: nowrap;
}
.nav-cta:hover { background: hsl(17, 70%, 38%); transform: translateY(-1px); }

.hamburger {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: 1.5px solid transparent; border-radius: 8px;
  cursor: pointer; padding: 16px 12px; transition: border-color 0.2s;
}
.hamburger:hover { border-color: var(--c-border-med); }
.hamburger span {
  display: block; width: 22px; height: 1.5px;
  background: var(--c-text); border-radius: 2px; transition: all 0.3s;
}
.hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ── MOBILE MENU ── */
.mobile-menu {
  display: none; position: fixed; inset: 0; z-index: 99;
  background: var(--c-bg);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5rem var(--px) 3rem;
  gap: 1rem;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  font-family: var(--font-serif); font-size: clamp(1.8rem, 6vw, 2.4rem); font-weight: 400;
  color: var(--c-text-muted);
  padding: 0.65rem 1.5rem;
  text-align: center;
  border-bottom: none;
  transition: color 0.2s;
}
.mobile-menu a:hover { color: var(--c-accent); }
.mobile-menu a[aria-current="page"] { color: var(--c-accent-dark); font-weight: 600; }
.mobile-close {
  position: absolute; top: 1rem; right: var(--px);
  background: none; border: 1.5px solid transparent; border-radius: 8px;
  font-size: 1.5rem; color: var(--c-text-muted); cursor: pointer;
  font-family: var(--font-serif); padding: 0.25rem 0.6rem;
  transition: border-color 0.2s;
}
.mobile-close:hover { border-color: var(--c-border-med); }
.mobile-menu .nav-cta {
  margin-top: 1.5rem; font-size: 1rem;
  justify-content: center; padding: 0.875rem; border-radius: 100px;
}

/* Responsive: switch nav to mobile at 1024px viewport width */
@media (max-width: 1024px) {
  /* hide desktop links, keep CTA visible on the bar */
  .nav-links { display: none; }

  /* show hamburger button */
  .hamburger { display: flex; }

  /* slightly reduce logo size and tighten nav spacing */
  .nav-logo svg { height: 48px; }
  .nav-inner { padding: 0 var(--px); gap: 0.5rem; }

  /* make nav height adapt to content on smaller viewports */
  nav { height: 64px; }
}

/* ── HERO ── */
.hero {
  display: flex;
  flex-direction: column;
  padding: 24px 0 var(--section-gap);
  align-items: center;
  justify-content: center;
  height: calc(100vh - var(--nav-h));
}
.hero-text {
  padding: 0 var(--px);
  max-width: var(--max-w);
  margin: 0 auto;
  width: 100%;
  display: flex;
  justify-content: center;
  text-align: center;
  margin-top: 3rem;
  box-sizing: border-box;
}
.hero-headline {
  font-family: var(--font-serif);
  font-size: clamp(1.75rem, 3vw, 3rem);
  font-style: normal;
  font-weight: 500; line-height: 1.3; letter-spacing: -0.01em;
  color: var(--c-text);
  /* max-width: 22ch; */
}
.hero-headline em {font-style: normal; color: var(--c-accent-dark); }
/* .hero-motto {
  font-size: 1.1rem; color: var(--c-text);
  font-family: var(--font-serif); font-style: normal;
  max-width: 44ch; line-height: 1.7;
}
.hero-image {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  box-sizing: border-box;
  border-radius: var(--radius);
} */
.hero-drawing {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  box-sizing: border-box;
}
.hero-drawing svg {
  display: block; width: 65%; height: auto; margin: 0 auto;
}
/* .hero-img-desk { display: block; width: 100%; height: 100%; object-fit: cover; }
.hero-img-mob  { display: none; }
.hero-img-placeholder {
  width: 100%; height: 100%; min-height: 380px;
  display: flex; align-items: flex-end; padding: 1.5rem var(--px);
  background: linear-gradient(160deg, #c8c4b0 0%, #a8a490 40%, #8a9478 100%);
}
.hero-img-label {
  font-size: 0.875rem; font-weight: 500; letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--c-text-light); background: rgba(245,240,232,0.85);
  padding: 0.35rem 0.7rem; border-radius: 6px;
} */
.hero-scroll {
  position: absolute; bottom: 1.5rem; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center;
}
.hero-scroll.is-hidden {
  display: none;
}
.hero-scroll svg {
  height: 100px; width: auto; color: var(--c-text);
}

/* Strzałka scroll -- pulsuje tylko gdy hover na hero-scroll */
@keyframes scroll-pulse {
  0%   { transform: translateY(0); opacity: 1; }
  40%  { transform: translateY(-10px); opacity: 0.3; }
  100% { transform: translateY(0); opacity: 1; }
}
.scroll-arrow {
  transform-origin: center top;
  /* domyślnie bez animacji */
}
.hero-scroll:hover .scroll-arrow {
  animation: scroll-pulse 0.9s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  .hero-scroll:hover .scroll-arrow { animation: none; }
}

@media (max-width: 600px) {
  .hero svg { width: 80%; }
  .hero-text {
    padding: 0 calc(var(--px) + 0.25rem);
  }
  .hero-headline {
    max-width: 100%;
  }
}

/* ── DOG SCENE ANIMATION ── */
.hero-drawing.dog-scene {
  position: relative;
  overflow: visible;
  width: min(760px, 100%);
  margin: 0 auto;
  transform: translateX(45px); /* kompensuje pustą przestrzeń SVG po prawej */
}

@media (max-width: 600px) {
  .hero-drawing.dog-scene {
    transform: translateX(16px);
  }
}

/* kontener w hero musi mieć width: 100% bo hero ma align-items: center */
.hero > .container {
  width: 100%;
}

/* Wszystkie warstwy mają ten sam viewBox 1086x390 -- nakładamy absolutnie */
.scene-layer {
  display: block;
  width: 100%;
  height: auto;
}
.scene-foto {
  position: relative; /* definiuje wysokość kontenera */
  z-index: 1;
}
.scene-dog {
  position: absolute;
  top: 0; left: 0;
  z-index: 2;
  /* Morfowanie odbywa się przez anime.js -- brak opacity transitions */
}

/* Bang -- startuje ze środka sceny, lekko dryfuje w stronę psa (w lewo) */
.scene-bang-wrap {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 3;
  pointer-events: none;
  display: flex;
  align-items: center;
  /* start trochę po prawej środka -- między środkiem a fotografem */
  justify-content: center;
  padding-right: 10%;
}
.scene-bang {
  display: block;
  width: 0;
  height: 0;
  opacity: 0;
  transform-origin: center center;
  pointer-events: none;
}

/* Keyframe: bang wyrasta, lekko przesuwa się w lewo ku psu */
@keyframes bang-fly {
  0% {
    width: 3%;
    height: auto;
    opacity: 0;
    transform: translateX(0) scale(0.1);
  }
  15% {
    opacity: 1;
  }
  55% {
    width: 22%;
    height: auto;
    opacity: 1;
    transform: translateX(-20%) scale(.8);
  }
  78% {
    opacity: 1;
    transform: translateX(-25%) scale(.85);
  }
  100% {
    width: 22%;
    opacity: 0;
    transform: translateX(-28%) scale(.75);
  }
}

.dog-scene.bursting .scene-bang {
  animation: bang-fly 1.2s ease-out forwards;
}

@media (max-width: 600px) {
  .hero-drawing.dog-scene { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .scene-dog { transition: none !important; }
  .scene-bang { animation: none !important; }
}

/* ── DIVIDER ── */
.section-divider { height: 1px; background: var(--c-border); }

/* ── COMMONS ── */
.container {
  max-width: var(--max-w); margin: 0 auto; padding: 0 var(--px);
}
.label {
  font-size: 0.875rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--c-accent-dark); display: flex; align-items: center; gap: 0.6rem;
  margin-bottom: 0.875rem;
}
/* .label::before {
  content: ''; display: block; width: 1.25rem; height: 1.5px; background: var(--c-accent);
} */
.section-h2 {
  font-family: var(--font-serif); font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  font-weight: 400; line-height: 1.25; margin-bottom: 1.25rem;
}
.section-h2 em { font-style: normal; color: var(--c-accent-dark); }
.body-text p { color: var(--c-text-muted); margin-bottom: 1rem; font-size: 1rem; }
.body-text p:last-child { margin-bottom: 0; }

/* cytat bez ozdobnej ramy -- zwykly tekst z lekkim wyroznieniem */
blockquote.pull {
  margin: 1.75rem 0;
  font-family: var(--font-sans); 
  font-size: 1rem; 
  font-weight: 500;
  color: var(--c-text); 
  line-height: 1.75;
}

/* ── ABOUT ── */
.about { padding: var(--section-gap) 0; background: var(--c-bg-alt); }
.about-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(2.5rem, 6vw, 6rem); align-items: center;
}
.about-img-wrap {
  aspect-ratio: 2/3; background: var(--c-bg-alt);
  border-radius: var(--radius); overflow: hidden; position: relative;
}
.about-img-wrap img {
  display: block;
  object-fit: contain;
  width: 100%;
  height: auto;
}
.about-img-placeholder {
  width: 100%; height: 100%;
  background: linear-gradient(160deg, #c8c0ac 0%, #a89e8c 100%);
  display: flex; align-items: flex-end; padding: 1.25rem;
}
.img-label {
  font-size: 0.875rem; font-weight: 500; letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--c-text-light); background: rgba(245,240,232,0.85);
  padding: 0.3rem 0.6rem; border-radius: 6px;
}
.about-logo-wrap {
  display: flex; justify-content: center; align-items: center;
  width: 100%; 
  margin-top: 2.4rem;
}
.about-logo {
  display: inline-block; width: auto; height: 160px; color: var(--c-text); margin-bottom: 1.25rem;
}

/* ── WHAT ── */
.what { padding: var(--section-gap) 0; }
.what-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(2.5rem, 6vw, 6rem); align-items: center;
}
.what-text .big {
  font-family: var(--font-serif); font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 400; line-height: 1.3; margin-bottom: 1.25rem; color: var(--c-text);
}
.what-text .big em { font-style: normal; color: var(--c-accent-dark); }
.what-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }
.what-photo { background: var(--c-bg); border-radius: var(--radius); overflow: hidden; }
.what-photo:first-child { grid-column: 1 / -1; aspect-ratio: 3/2; }
.what-photo:not(:first-child) { aspect-ratio: 2/3; }
.what-ph { width: 100%; height: 100%; min-height: 120px; }

/* ── FOOTER ── */
footer {
  background: var(--c-bg-dark);
  color: rgba(200,194,182,0.9);
  padding: 3rem 0 2rem;
}
.footer-inner {
  max-width: var(--max-w); margin: 0 auto; padding: 0 var(--px);
}
.footer-top {
  display: flex; justify-content: space-between; align-items: start;
  gap: 2rem; margin-bottom: 2rem; padding-bottom: 2rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-logo p {
  font-size: 0.875rem; color: rgba(200,194,182,0.75); margin-top: 0.5rem;
}
.footer-contact {
  display: flex; flex-direction: column; align-items: flex-end; gap: 0.75rem;
}
.footer-email {
  background: none; border: none; cursor: pointer;
  font-family: var(--font-sans); font-size: 1rem;
  color: rgba(200,194,182,0.9); padding: 0;
  display: flex; align-items: center; gap: 0.5rem; transition: color 0.2s;
}
.footer-email:hover { color: #fff; }
.footer-email:focus-visible { outline-color: #fff; border-radius: 4px; }
.copy-feedback {
  font-size: 0.8rem; color: var(--c-accent);
  opacity: 0; transition: opacity 0.3s;
}
.copy-feedback.visible { opacity: 1; }
.footer-social { display: flex; gap: 1.25rem; }
.footer-social a {
  font-size: 1rem; color: rgba(200,194,182,0.75); transition: color 0.2s;
}
.footer-social a:hover { color: #fff; }
.footer-social a:focus-visible { outline-color: #fff; }
.footer-location { font-size: 0.875rem; color: rgba(200,194,182,0.5); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 0.875rem; color: rgba(200,194,182,0.5); flex-wrap: wrap; gap: 0.75rem;
}
.footer-legal { display: flex; gap: 1.5rem; list-style: none; }
.footer-legal a { color: rgba(200,194,182,0.7); transition: color 0.2s; }
.footer-legal a:hover { color: rgba(200,194,182,0.85); }
.footer-legal a:focus-visible { outline-color: #fff; }

@media (max-width: 600px) {
  .footer-top { flex-direction: column; align-items: center; text-align: center; }
  .footer-contact { align-items: center; }
  .footer-bottom { flex-direction: column; align-items: center; text-align: center; }
}

/* ── RESPONSIVE ── */
@media (max-width: 860px) {
  .about-grid, .what-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; text-align: center; }
  .footer-right { text-align: center; }
}
@media (max-width: 600px) {
  .nav-links, .nav-cta { display: none; }
  .hamburger { display: flex; }
  .hero-img-desk { display: none; }
  .hero-img-mob { display: block; width: 100%; height: 100%; object-fit: cover; }
  .hero-img-placeholder { min-height: 480px; }
  .footer-bottom { flex-direction: column; align-items: center; text-align: center; }
  .what-photos { grid-template-columns: 1fr; }
  .what-photo:first-child,
  .what-photo:not(:first-child) { aspect-ratio: 3/2; }
}
@media (max-width: 360px) {
  :root { --px: 1rem; }
  .hero-headline { font-size: 1.625rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}


/* ── NAV RIGHT GROUP + LANGUAGE SWITCH (dwujęzyczność) ── */
.nav-right { display: flex; align-items: center; gap: 0.85rem; }
.lang-switch {
  display: inline-flex; align-items: center; gap: 0;
  font-family: var(--font-sans); font-size: 0.82rem; font-weight: 600;
  letter-spacing: 0.03em; white-space: nowrap;
}
.lang-switch a,
.lang-switch span[aria-current] {
  min-width: 44px; min-height: 44px;
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0 0.35rem;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
}
.lang-switch a { color: var(--c-text-light); }
.lang-switch a:hover { color: var(--c-accent-dark); background: var(--c-nav-hover-bg); }
.lang-switch [aria-current="true"] { color: var(--c-text); }
.lang-switch .sep { color: var(--c-border-med); font-weight: 400; padding: 0 0.1rem; }
/* mobile lang-switch removed from menu — stays only in nav bar */

/* ── SOCIAL ICONS (nav bar + mobile menu) ── */
/* Ikony: domyślnie odbarwione (grayscale), na hover filtr znika i wraca oryginalny kolor. */
.nav-socials,
.mobile-socials { display: inline-flex; align-items: center; gap: 0.5rem; }
.social-link { display: inline-flex; align-items: center; }
.nav-socials .social-link svg,
.mobile-socials .social-link svg {
  display: block; width: 22px; height: 22px;
  filter: grayscale(1) opacity(0.7);
  transition: filter 0.3s ease;
  border-radius: 5px;
}
.nav-socials .social-link:hover svg,
.nav-socials .social-link:focus-visible svg,
.mobile-socials .social-link:hover svg,
.mobile-socials .social-link:focus-visible svg { filter: grayscale(0) opacity(1); }

/* W nawigacji (pasek) widoczne powyżej 768px; kopia w mobile menu ukryta. */
.mobile-socials { display: none; }

/* Od 768px w dół: ikony znikają z paska i pojawiają się w mobile menu pod pozycją Kontakt. */
@media (max-width: 768px) {
  .nav-socials { display: none; }
  /* Ikony przypięte do dołu — symetrycznie do PL/EN u góry (top: 4.75rem). */
  .mobile-socials {
    display: inline-flex; gap: 1rem;
    position: absolute; bottom: 4.75rem; left: 50%; transform: translateX(-50%);
  }
}

/* Przełącznik języka w mobile menu — wyśrodkowany u góry, zaraz pod paskiem nav.
   Widoczny dopiero od 600px w dół; powyżej zostaje na pasku. */
.mobile-lang { display: none; }
.mobile-lang.lang-switch { font-size: 0.95rem; }
@media (max-width: 600px) {
  .nav-right .lang-switch { display: none; }
  .mobile-lang {
    display: inline-flex;
    position: absolute;
    top: 4.75rem;
    left: 50%;
    transform: translateX(-50%);
  }
}