/* ============================================================
   HALMEONI · SHARED DESIGN TOKENS + BASE
   Wspólny system dla landing #1 (ebook) i landing #2 (urządzenie).
   Reguły page-specific zostają w inline <style> każdej strony.

   Editorial mood — referencje: Aesop, Sulwhasoo, Apartamento, The Gentlewoman.
   ============================================================ */

/* ---------- design tokens ---------- */

:root {
  --paper:        #F4EFE6;
  --paper-warm:   #EBE4D7;
  --paper-dark:   #2C2522;
  --ink:          #2C2522;
  --ink-soft:     #5A4F48;
  --ink-paper:    #E9DFCC; /* tekst na ciemnym tle */
  --accent-red:   #B5322A;
  --rule:         #C9BCAD;

  --serif-display: 'Cormorant Garamond', 'EB Garamond', Georgia, serif;
  --serif-body:    'Lora', 'Source Serif Pro', Georgia, serif;
  --sans-label:    'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --serif-kr:      'Noto Serif KR', 'Source Han Serif', serif;

  --container: 1140px;
  --measure: 640px;
  --measure-narrow: 520px;

  --space-section: 144px;
  --space-section-mobile: 88px;
}

/* ---------- reset + base ---------- */

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif-body);
  font-size: 18px;
  line-height: 1.7;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  background-image:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.035 0'/></filter><rect width='200' height='200' filter='url(%23n)'/></svg>");
  background-repeat: repeat;
}

@media (max-width: 768px) {
  body { font-size: 17px; line-height: 1.65; }
}

::selection { background: var(--accent-red); color: var(--paper); }

/* ---------- typography ---------- */

h1, h2, h3, h4 {
  font-family: var(--serif-display);
  font-weight: 500;
  color: var(--ink);
  margin: 0;
  letter-spacing: -0.005em;
}

h1 { font-size: clamp(2.4rem, 5.6vw, 4.5rem); line-height: 1.05; }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.75rem); line-height: 1.15; margin-bottom: 1.5rem; }
h3 { font-size: clamp(1.5rem, 2.4vw, 2.1rem); line-height: 1.2; }

p { margin: 0 0 1.2rem; text-wrap: pretty; }
p:last-child { margin-bottom: 0; }

em, i { font-style: italic; }

.eyebrow {
  font-family: var(--sans-label);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0 0 1.6rem;
  display: flex;
  align-items: center;
  gap: 0.9rem;
}
.eyebrow .kr {
  font-family: var(--serif-kr);
  font-size: 1.25rem;
  letter-spacing: 0.05em;
  font-weight: 500;
  color: var(--ink);
  text-transform: none;
}
.eyebrow .dot {
  width: 4px; height: 4px; background: var(--ink-soft); border-radius: 50%;
  display: inline-block;
}

.caption {
  font-family: var(--serif-body);
  font-style: italic;
  font-size: 0.95rem;
  color: var(--ink-soft);
  line-height: 1.5;
  margin-top: 0.8rem;
}

.rule {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 0;
}

/* ---------- layout primitives ---------- */

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}
@media (max-width: 768px) { .container { padding: 0 22px; } }

section {
  padding: var(--space-section) 0;
}
@media (max-width: 768px) {
  section { padding: var(--space-section-mobile) 0; }
}

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

/* ---------- buttons ---------- */

.cta {
  display: inline-block;
  font-family: var(--sans-label);
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--paper);
  background: var(--ink);
  padding: 20px 42px;
  border: 1px solid var(--ink);
  border-radius: 0;
  transition: background 220ms ease, color 220ms ease, border-color 220ms ease;
  cursor: pointer;
}
.cta:hover, .cta:focus-visible {
  background: var(--accent-red);
  border-color: var(--accent-red);
  color: var(--paper);
  outline: none;
}
.cta--inverse {
  color: var(--ink);
  background: var(--paper);
  border-color: var(--paper);
}
.cta--inverse:hover, .cta--inverse:focus-visible {
  background: var(--accent-red);
  border-color: var(--accent-red);
  color: var(--paper);
}
.cta--ghost {
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--ink);
}
.cta--ghost:hover, .cta--ghost:focus-visible {
  background: var(--ink);
  color: var(--paper);
}
.microcopy {
  font-family: var(--serif-body);
  font-style: italic;
  font-size: 0.9rem;
  color: var(--ink-soft);
  margin-top: 1rem;
}

/* ---------- shared component: pull-quote ---------- */

.pull-quote {
  max-width: 720px;
  margin: 4.5rem auto;
  text-align: center;
  padding: 2.4rem 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.pull-quote blockquote {
  font-family: var(--serif-display);
  font-style: italic;
  font-size: clamp(1.4rem, 2.6vw, 1.95rem);
  line-height: 1.35;
  color: var(--ink);
  margin: 0 0 1.4rem;
  font-weight: 400;
}
.pull-quote cite {
  font-family: var(--serif-body);
  font-style: normal;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  text-transform: uppercase;
}

/* ---------- shared component: testimonial card ---------- */

.testimonial {
  max-width: 580px;
  margin: 0 auto 4.5rem;
  text-align: left;
}
.testimonial:last-child { margin-bottom: 0; }
.testimonial blockquote {
  font-family: var(--serif-body);
  font-style: italic;
  font-size: 1.08rem;
  line-height: 1.7;
  color: var(--ink);
  margin: 0 0 1.4rem;
  padding-left: 1.4rem;
  border-left: 2px solid var(--accent-red);
}
.testimonial cite {
  font-style: normal;
  font-family: var(--sans-label);
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding-left: 1.4rem;
}
.testimonial cite strong {
  color: var(--ink);
  font-weight: 500;
}

/* ---------- shared component: FAQ accordion ---------- */

.faq__inner { max-width: 760px; margin: 0 auto; }
.faq h2 { text-align: center; margin-bottom: 3.4rem; }
.faq details {
  border-top: 1px solid var(--rule);
  padding: 0;
}
.faq details:last-of-type { border-bottom: 1px solid var(--rule); }
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 1.6rem 48px 1.6rem 0;
  font-family: var(--serif-display);
  font-size: 1.3rem;
  font-style: italic;
  font-weight: 500;
  color: var(--ink);
  position: relative;
  line-height: 1.4;
  transition: color 200ms ease;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--accent-red); }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 1.5rem;
  font-family: var(--serif-display);
  font-size: 1.6rem;
  font-style: normal;
  color: var(--ink-soft);
  transition: transform 220ms ease, color 220ms ease;
  line-height: 1;
}
.faq details[open] summary::after {
  content: "×";
  color: var(--accent-red);
}
.faq details p {
  padding: 0 0 1.8rem;
  max-width: 64ch;
  color: var(--ink-soft);
  font-size: 1rem;
  line-height: 1.7;
}

/* ============================================================
   MASTHEAD · cienki magazynowy header
   Inspiracja: Apartamento, The Gentlewoman.
   Współdzielony między landing #1 i #2.
   ============================================================ */

.masthead {
  border-bottom: 1px solid var(--rule);
  padding: 18px 0;
  background: var(--paper);
  position: relative;
  z-index: 5;
}
.masthead__row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-family: var(--sans-label);
  font-size: 0.72rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.masthead__brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--ink-soft);
  text-decoration: none;
}
.masthead__brand .kr {
  font-family: var(--serif-kr);
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--ink);
  text-transform: none;
  line-height: 1;
}
.masthead__brand .dot {
  width: 3px; height: 3px; background: var(--ink-soft); border-radius: 50%;
  display: inline-block;
}
.masthead__issue {
  font-family: var(--serif-body);
  font-style: italic;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--ink-soft);
}
.masthead__issue strong {
  color: var(--ink);
  font-weight: 500;
}

@media (max-width: 540px) {
  .masthead__row { font-size: 0.65rem; }
  .masthead__brand .kr { font-size: 0.95rem; }
  .masthead__issue { font-size: 0.78rem; }
  .masthead__issue .hide-xs { display: none; }
}

/* ============================================================
   FOOTER · współdzielony między landing #1 i #2
   ============================================================ */

footer {
  background: var(--paper);
  padding: 56px 0 40px;
  border-top: 1px solid var(--rule);
}
.footer__row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 32px;
  align-items: center;
  font-family: var(--sans-label);
  font-size: 0.82rem;
  color: var(--ink-soft);
  letter-spacing: 0.05em;
}
.footer__row a {
  color: var(--ink-soft);
  text-decoration: none;
  transition: color 200ms ease;
}
.footer__row a:hover { color: var(--accent-red); }
.footer__row .center { display: flex; gap: 1.4rem; justify-content: center; flex-wrap: wrap; }
.footer__row .right { text-align: right; }
.footer__legal {
  max-width: 720px;
  margin: 2.6rem auto 0;
  padding: 1.8rem 32px 0;
  border-top: 1px solid var(--rule);
  font-family: var(--serif-body);
  font-style: italic;
  font-size: 0.82rem;
  line-height: 1.65;
  color: var(--ink-soft);
  text-align: center;
}
.footer__cross {
  margin-top: 1.6rem;
  font-family: var(--serif-body);
  font-style: italic;
  font-size: 0.85rem;
  text-align: center;
  color: var(--ink-soft);
}
.footer__cross a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--rule);
  transition: border-color 200ms ease, color 200ms ease;
}
.footer__cross a:hover {
  color: var(--accent-red);
  border-color: var(--accent-red);
}
@media (max-width: 768px) {
  .footer__row {
    grid-template-columns: 1fr;
    gap: 1rem;
    text-align: center;
  }
  .footer__row .center, .footer__row .right { text-align: center; justify-content: center; }
}

/* ---------- focus states ---------- */

a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent-red);
  outline-offset: 4px;
}

/* ---------- print ---------- */

@media print {
  .sticky-cta, .final .cta, .hero__cta-row { display: none; }
  body { background: white; color: black; }
}
