/* ==========================================================================
   Design System — paleta Iris
   ========================================================================== */

:root {
  /* Kolory */
  --forest:      #1A3A2A;
  --burgundy:    #6B1D2A;
  --earth:       #5C3D2E;
  --cream:       #F5E6D3;
  --ink:         #1C1410;
  --gold:        #C4956A;

  /* Pochodne */
  --forest-light: #224a36;
  --cream-dark:   #E8D5BF;
  --burgundy-soft: #8A2E3D;

  /* Fonty */
  --font-heading: 'Cormorant Garamond', Georgia, serif;
  --font-body:    'Inter', -apple-system, sans-serif;

  /* Przestrzeń */
  --space-xs:  0.5rem;
  --space-sm:  1rem;
  --space-md:  2rem;
  --space-lg:  4rem;
  --space-xl:  6rem;
  --space-2xl: 8rem;

  /* Layout */
  --max-width:   1100px;
  --narrow-width: 640px;

  /* Animacja */
  --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ==========================================================================
   Reset & Base
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.7;
  color: var(--cream);
  background-color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Grain overlay — analog film texture */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 999;
  opacity: 0.4;
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.02em;
}

/* Accessibility — focus states */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -100px;
  left: var(--space-sm);
  background: var(--burgundy);
  color: var(--cream);
  padding: 0.5rem 1rem;
  border-radius: 4px;
  z-index: 200;
  font-size: 0.85rem;
  transition: top 0.3s var(--ease);
}

.skip-link:focus {
  top: var(--space-sm);
}

a {
  color: var(--gold);
  text-decoration: none;
  transition: color 0.3s var(--ease);
}

a:hover {
  color: var(--cream);
}

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

/* ==========================================================================
   Layout
   ========================================================================== */

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-md);
}

.container--narrow {
  max-width: var(--narrow-width);
}

.section {
  padding: var(--space-xl) 0;
}

.section--light {
  background: linear-gradient(180deg, var(--cream) 0%, var(--cream-dark) 100%);
  color: var(--ink);
}

.section--dark {
  background-color: var(--forest);
  color: var(--cream);
}

.section--warm {
  background-color: var(--ink);
  color: var(--cream);
}

.section__title {
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: var(--space-md);
  text-align: center;
}

.section--light .section__title {
  color: var(--forest);
}

.section__subtitle {
  text-align: center;
  font-style: italic;
  font-family: var(--font-heading);
  font-size: 1.15rem;
  opacity: 0.85;
  margin-bottom: var(--space-lg);
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* ==========================================================================
   Nawigacja
   ========================================================================== */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(28, 20, 16, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(196, 149, 106, 0.1);
  transition: background 0.4s var(--ease);
}

.nav--scrolled {
  background: rgba(28, 20, 16, 0.95);
  border-bottom-color: rgba(196, 149, 106, 0.15);
}

.nav__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav__logo {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 500;
  color: var(--cream);
  letter-spacing: 0.04em;
}

.nav__logo:hover {
  color: var(--gold);
}

.nav__links {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  list-style: none;
}

.nav__links a {
  color: var(--cream);
  font-size: 0.9rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  opacity: 0.8;
  transition: opacity 0.3s var(--ease);
  position: relative;
}

.nav__links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--gold);
  transition: width 0.3s var(--ease);
}

.nav__links a:hover {
  opacity: 1;
  color: var(--cream);
}

.nav__links a:hover::after {
  width: 100%;
}

.nav__cta {
  background: var(--burgundy);
  padding: 0.5rem 1.2rem;
  border-radius: 4px;
  opacity: 1 !important;
}

.nav__cta:hover {
  background: var(--burgundy-soft);
}

/* Hamburger */
.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--cream);
  transition: all 0.3s var(--ease);
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--space-xl) var(--space-md);
  background: linear-gradient(
    165deg,
    var(--ink) 0%,
    #162e22 40%,
    var(--forest) 100%
  );
  position: relative;
  overflow: hidden;
}

/* Subtle radial glow — warmth */
.hero::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 140%;
  height: 140%;
  background: radial-gradient(ellipse at 50% 60%, rgba(107, 29, 42, 0.08) 0%, transparent 60%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 180px;
  background: linear-gradient(180deg, transparent 0%, var(--cream) 75%);
  clip-path: polygon(0 35%, 100% 0%, 100% 100%, 0 100%);
  pointer-events: none;
}

.hero__content {
  max-width: 700px;
}

.hero__heading {
  font-size: clamp(2.4rem, 7vw, 4.6rem);
  font-weight: 400;
  color: var(--cream);
  margin-bottom: var(--space-md);
  line-height: 1.15;
}

.hero__sub {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  font-weight: 300;
  color: var(--gold);
  margin-bottom: var(--space-lg);
  letter-spacing: 0.05em;
}

/* ==========================================================================
   Przyciski
   ========================================================================== */

.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  padding: 0.85rem 2rem;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s var(--ease);
  text-align: center;
}

.btn--primary {
  background: var(--burgundy);
  color: var(--cream);
}

.btn--primary:hover {
  background: var(--burgundy-soft);
  color: var(--cream);
  transform: translateY(-1px);
}

.btn--secondary {
  background: var(--gold);
  color: var(--ink);
}

.btn--secondary:hover {
  background: var(--cream);
  color: var(--ink);
  transform: translateY(-1px);
}

.btn--outline {
  background: transparent;
  color: var(--gold);
  border: 1px solid var(--gold);
}

.btn--outline:hover {
  background: var(--gold);
  color: var(--ink);
  transform: translateY(-1px);
}

.btn--full {
  width: 100%;
}

/* ==========================================================================
   O mnie
   ========================================================================== */

.about {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  align-items: center;
  margin-top: var(--space-lg);
}

.about__text p {
  margin-bottom: var(--space-sm);
  font-size: 1.15rem;
  line-height: 1.85;
  color: var(--earth);
}

.about__text p:first-child {
  font-family: var(--font-heading);
  font-style: italic;
  font-size: 1.4rem;
  font-weight: 500;
  color: var(--forest);
  padding-left: 1rem;
  border-left: 2px solid var(--burgundy);
  line-height: 1.5;
}

.about__placeholder {
  width: 100%;
  aspect-ratio: 3/4;
  background:
    linear-gradient(135deg, var(--forest) 0%, var(--earth) 50%, var(--ink) 100%);
  border-radius: 8px;
  opacity: 0.5;
  position: relative;
}

.about__placeholder::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 8px;
  border: 1px solid rgba(196, 149, 106, 0.15);
}

/* ==========================================================================
   Oferta
   ========================================================================== */

.offers {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-md);
  margin-top: var(--space-lg);
}

.offer {
  background: rgba(245, 230, 211, 0.05);
  border: 1px solid rgba(196, 149, 106, 0.15);
  border-radius: 8px;
  padding: var(--space-md);
  transition: border-color 0.3s var(--ease), transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.offer:hover {
  border-color: rgba(196, 149, 106, 0.35);
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.25);
}

.offer--featured {
  grid-column: 1 / -1;
  background: rgba(196, 149, 106, 0.08);
  border-color: var(--gold);
  position: relative;
}

.offer__badge {
  display: inline-block;
  background: var(--burgundy);
  color: var(--cream);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  padding: 0.3rem 0.8rem;
  border-radius: 3px;
  margin-bottom: var(--space-sm);
}

.offer__title {
  font-size: 1.6rem;
  margin-bottom: var(--space-xs);
  color: var(--cream);
}

.offer__desc {
  font-size: 0.95rem;
  line-height: 1.7;
  opacity: 0.85;
  margin-bottom: var(--space-sm);
}

.offer__details {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space-md);
  margin-bottom: var(--space-md);
  font-size: 0.85rem;
  opacity: 0.7;
}

.offer__details li::before {
  content: '·';
  margin-right: 0.4rem;
  color: var(--gold);
}

.offer__soon {
  display: inline-block;
  font-family: var(--font-heading);
  font-style: italic;
  color: var(--gold);
  font-size: 0.95rem;
  margin-top: var(--space-xs);
}

.offer--probono {
  border-style: dashed;
  border-color: rgba(196, 149, 106, 0.25);
}

/* ==========================================================================
   Formularz
   ========================================================================== */

.form {
  margin-top: var(--space-md);
}

.form__group {
  margin-bottom: var(--space-sm);
}

.form__label {
  display: block;
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  margin-bottom: 0.3rem;
  color: var(--gold);
}

.form__input,
.form__textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 300;
  color: var(--cream);
  background: rgba(245, 230, 211, 0.06);
  border: 1px solid rgba(196, 149, 106, 0.2);
  border-radius: 4px;
  padding: 0.75rem 1rem;
  transition: border-color 0.3s var(--ease);
}

.form__input:focus,
.form__textarea:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(245, 230, 211, 0.1);
}

.form__textarea {
  resize: vertical;
  min-height: 120px;
}

/* Honeypot — ukryty dla botów */
.form__honeypot {
  display: none;
}

.contact-info {
  text-align: center;
  margin-top: var(--space-lg);
  font-size: 0.9rem;
  opacity: 0.6;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
  text-align: center;
  padding: var(--space-md) 0;
  font-size: 0.8rem;
  opacity: 0.4;
  border-top: 1px solid rgba(196, 149, 106, 0.08);
}

/* ==========================================================================
   Animacje — fade-in na scroll
   ========================================================================== */

.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   Responsywność
   ========================================================================== */

@media (max-width: 768px) {
  .nav__links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: rgba(28, 20, 16, 0.95);
    flex-direction: column;
    padding: var(--space-md);
    gap: var(--space-sm);
    border-bottom: 1px solid rgba(196, 149, 106, 0.1);
  }

  .nav__links.active {
    display: flex;
    animation: slideDown 0.35s var(--ease);
  }

  @keyframes slideDown {
    from { opacity: 0; transform: translateY(-12px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  .nav__toggle {
    display: flex;
  }

  .nav__cta {
    text-align: center;
    width: 100%;
    display: block;
  }

  .about {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }

  .about__image {
    order: -1;
  }

  .about__placeholder {
    aspect-ratio: 16/9;
  }

  .offers {
    grid-template-columns: 1fr;
  }

  .offer--featured {
    grid-column: auto;
  }

  .section {
    padding: var(--space-lg) 0;
  }

  .hero {
    min-height: 85vh;
  }
}

@media (max-width: 480px) {
  html {
    font-size: 15px;
  }

  .hero__heading {
    font-size: 2rem;
  }

  .nav__inner {
    padding: 0 var(--space-sm);
  }

  .container {
    padding: 0 var(--space-sm);
  }
}

/* ==========================================================================
   Subtelny separator między sekcjami - dodatkowy oddech
   ========================================================================== */

.section + .section {
  border-top: 1px solid rgba(196, 149, 106, 0.06);
}

/* ==========================================================================
   Anchor offset dla fixed nav (CSS-first, selektywnie)
   - tylko sekcje, nie wszystkie [id] (skip-link target nie traci celu)
   ========================================================================== */

section[id],
header[id] {
  scroll-margin-top: 80px;
}

/* ==========================================================================
   Accessibility - prefers-reduced-motion (WCAG 2.3.3)
   - wyłącza animacje, transform i smooth scroll
   - content widoczny od razu (fade-in nie blokuje)
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }

  .fade-in {
    opacity: 1 !important;
    transform: none !important;
  }

  .btn:hover,
  .offer:hover,
  .btn--primary:hover,
  .btn--secondary:hover,
  .btn--outline:hover {
    transform: none !important;
  }
}
