/* ==========================================================
   Molinowe Meble – strona tymczasowa
   Kolorystyka i fonty zgodne z wizytówką (Tinos + Montserrat)
   ========================================================== */

:root {
  --brown: #5e391d;
  --brown-dark: #43270f;
  --ink: #272626;
  --muted: #6f6660;
  --beige: #dfcdb8;
  --beige-soft: #f3ebe1;
  --paper: #ffffff;
  --taupe: #a89c94;

  --serif: "Tinos", "Times New Roman", Times, serif;
  --sans: "Montserrat", "Segoe UI", Arial, sans-serif;

  --ease: cubic-bezier(.22, .8, .24, 1);
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }

a { color: inherit; }

/* ---------- HERO ---------- */

.hero {
  position: relative;
  padding-top: clamp(28px, 6vh, 64px);
}

.brand {
  position: relative;
  z-index: 2;
  width: fit-content;
  max-width: calc(100% - 32px);
  margin: 0 auto;
  padding: 0 clamp(24px, 6vw, 64px) clamp(20px, 3vw, 28px);
  background: var(--paper);
  border-radius: 0 0 44px 44px;
  text-align: center;
}

.brand__logo {
  width: clamp(150px, 30vw, 250px);
  margin: 0 auto;
  animation: logo-in 1.1s var(--ease) both;
}

.brand__name {
  margin: 10px 0 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.3rem, 7vw, 4.2rem);
  line-height: 1.05;
  letter-spacing: .03em;
  color: var(--ink);
  animation: fade-up .9s var(--ease) .35s both;
}

.brand__rule {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin: 12px auto 10px;
  width: min(78%, 360px);
}

.brand__rule span {
  flex: 1;
  height: 2px;
  background: var(--brown);
  transform-origin: center;
  animation: grow 1s var(--ease) .65s both;
}

.brand__rule span:first-child { transform-origin: right; }
.brand__rule span:last-child  { transform-origin: left; }

.brand__rule i {
  width: 18px;
  height: 2px;
  background: var(--brown);
  animation: fade-in .6s ease .6s both;
}

.brand__tagline {
  margin: 0;
  font-weight: 700;
  font-size: clamp(.68rem, 1.9vw, .95rem);
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--brown);
  animation: fade-up .9s var(--ease) .8s both;
}

.hero__photo {
  position: relative;
  z-index: 1;
  margin-top: clamp(-70px, -7vw, -44px);
  height: clamp(280px, 52vh, 580px);
  overflow: hidden;
  background: var(--beige-soft);
}

.hero__photo::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("img/kuchnia.jpg") center 62% / cover no-repeat;
  animation: ken-burns 22s ease-in-out infinite alternate, fade-in 1.4s ease both;
}

.hero__photo::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 30%;
  background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,.9));
  pointer-events: none;
}

/* ---------- INTRO ---------- */

.intro {
  max-width: 760px;
  margin: 0 auto;
  padding: clamp(24px, 5vw, 48px) 16px clamp(36px, 6vw, 64px);
  text-align: center;
}

.intro > * { animation: fade-up .9s var(--ease) both; }
.intro > :nth-child(1) { animation-delay: 1.0s; }
.intro > :nth-child(2) { animation-delay: 1.1s; }
.intro > :nth-child(3) { animation-delay: 1.2s; }
.intro > :nth-child(4) { animation-delay: 1.35s; }
.intro > :nth-child(5) { animation-delay: 1.5s; }

.intro__area {
  margin: 0;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.05rem, 2.6vw, 1.3rem);
  color: var(--muted);
}

.intro__title {
  display: inline-block;
  margin: 18px 0 0;
  padding: 10px 28px;
  background: var(--beige);
  border-radius: 999px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.15rem, 3.2vw, 1.6rem);
  line-height: 1.35;
  color: var(--ink);
}

.intro__text {
  max-width: 600px;
  margin: 22px auto 0;
  color: var(--muted);
  font-size: clamp(.95rem, 2.2vw, 1.02rem);
}

/* ---------- SOCIAL BUTTONS ---------- */

.social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-top: 32px;
}

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-width: 190px;
  padding: 14px 26px;
  border: 2px solid var(--brown);
  border-radius: 999px;
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .06em;
  text-decoration: none;
  overflow: hidden;
  isolation: isolate;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), color .35s ease, background-color .35s ease;
}

.btn svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
  transition: transform .45s var(--ease);
}

/* połysk przesuwający się po najechaniu */
.btn::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.28) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform .7s var(--ease);
}

.btn--fb {
  background: var(--brown);
  color: #fff;
}

.btn--ig {
  background: transparent;
  color: var(--brown);
}

.btn:hover,
.btn:focus-visible {
  transform: translateY(-3px);
  box-shadow: 0 12px 26px -12px rgba(94, 57, 29, .55);
}

.btn:hover::after,
.btn:focus-visible::after { transform: translateX(120%); }

.btn:hover svg,
.btn:focus-visible svg { transform: scale(1.15) rotate(-6deg); }

.btn--fb:hover,
.btn--fb:focus-visible { background: var(--brown-dark); border-color: var(--brown-dark); }

.btn--ig:hover,
.btn--ig:focus-visible { background: var(--brown); color: #fff; }

.btn:focus-visible { outline: 3px solid var(--beige); outline-offset: 3px; }

.social__hint {
  margin: 16px 0 0;
  font-size: .85rem;
  color: var(--taupe);
}

/* ---------- GALLERY ---------- */

.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  padding: 0 10px;
}

.gallery figure {
  margin: 0;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 6px;
  background: var(--beige-soft);
  animation: fade-up .9s var(--ease) both;
}

.gallery figure:nth-child(1) { animation-delay: 1.5s; }
.gallery figure:nth-child(2) { animation-delay: 1.6s; }
.gallery figure:nth-child(3) { animation-delay: 1.7s; }
.gallery figure:nth-child(4) { animation-delay: 1.8s; }

.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.2s var(--ease), filter .6s ease;
  filter: saturate(.92);
}

.gallery figure:hover img {
  transform: scale(1.06);
  filter: saturate(1.05);
}

/* przeglądarki z animacjami sterowanymi przewijaniem – zdjęcia wjeżdżają przy scrollu */
@supports (animation-timeline: view()) {
  .gallery figure:nth-child(n) {
    animation: fade-up linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 60%;
  }
}

/* ---------- CONTACT ---------- */

.contact {
  padding: clamp(40px, 7vw, 72px) 16px 8px;
  text-align: center;
}

.contact__name {
  margin: 0 0 8px;
  font-weight: 700;
  font-size: clamp(1.3rem, 3.4vw, 1.7rem);
  color: var(--ink);
}

.contact__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 28px;
  font-size: 1.02rem;
}

.contact__list b { color: var(--brown); }

.contact__list a {
  text-decoration: none;
  background: linear-gradient(var(--brown), var(--brown)) left bottom / 0 1px no-repeat;
  transition: background-size .4s var(--ease), color .3s ease;
}

.contact__list a:hover,
.contact__list a:focus-visible {
  color: var(--brown);
  background-size: 100% 1px;
}

/* ---------- FOOTER ---------- */

.footer {
  padding: 40px 16px 32px;
  text-align: center;
}

.footer__notice {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 8px 18px;
  background: var(--beige-soft);
  border-radius: 999px;
  font-size: .82rem;
  color: var(--muted);
}

.footer__dot {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brown);
  animation: pulse 2.2s ease-in-out infinite;
}

.footer__copy {
  margin: 16px 0 0;
  font-size: .75rem;
  color: var(--taupe);
}

/* ---------- KEYFRAMES ---------- */

@keyframes fade-up {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: none; }
}

@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes logo-in {
  from { opacity: 0; transform: translateY(-14px) scale(.92); }
  to   { opacity: 1; transform: none; }
}

@keyframes grow {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

@keyframes ken-burns {
  from { transform: scale(1); }
  to   { transform: scale(1.08) translate(-1%, -1%); }
}

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(94, 57, 29, .45); }
  50%      { box-shadow: 0 0 0 6px rgba(94, 57, 29, 0); }
}

/* ---------- RESPONSYWNOŚĆ ---------- */

@media (max-width: 760px) {
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .brand { border-radius: 0 0 32px 32px; }
}

@media (max-width: 420px) {
  .btn { width: 100%; }
  .intro__title { padding: 12px 20px; border-radius: 28px; }
  .brand__tagline { letter-spacing: .18em; }
}

/* ---------- OGRANICZENIE RUCHU ---------- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
