/* 05 hero — the headline is the first screen. */

:root {
  --bg: #fefefe;
  --ink: #000000;
  --muted: #7d7c78;
  --line: #e0dfdd;
  --wrap: 76rem;
  --font: Inter, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mark: Arial, "Liberation Sans", "Helvetica Neue", Helvetica, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html { scroll-behavior: auto; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: 0.75rem;
  z-index: 20;
  padding: 0.55rem 0.75rem;
  background: var(--ink);
  color: var(--bg);
  text-decoration: none;
  border-radius: 6px;
  transform: translateY(-160%);
}

.skip-link:focus { transform: none; }

.wrap {
  width: min(100% - 2.5rem, var(--wrap));
  margin-inline: auto;
}

/* First screen: header, headline, then the small lines */
.top {
  height: 100vh;
  height: 100svh;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.site-header {
  flex: 0 0 auto;
  padding-top: max(0.85rem, env(safe-area-inset-top));
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  padding-bottom: 0.35rem;
}

.wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: 0.22em;
  color: var(--ink);
  text-decoration: none;
  font-family: var(--mark);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.24em;
  line-height: 1;
  flex-shrink: 0;
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 1.15rem 1.5rem;
  min-width: 0;
}

.header-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.35rem 1.15rem;
}

.header-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: -0.011em;
}

.header-nav a:hover { color: var(--ink); }

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
  flex-shrink: 0;
}

.lang-switch button {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  line-height: 1;
  padding: 0.35rem 0.4rem;
  cursor: pointer;
}

.lang-switch button.is-active {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 0.28em;
  text-decoration-thickness: 1px;
}

.hero {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding-bottom: max(0.85rem, env(safe-area-inset-bottom));
}

.hero-frame {
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  align-content: stretch;
}

.hero-lockup {
  --face: 168px;
  --gap: clamp(0.85rem, 2vw, 2.25rem);
  container-type: size;
  container-name: lockup;
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--face);
  column-gap: var(--gap);
  align-items: end;
  min-height: 0;
  padding-bottom: 0.15rem;
}

.hero-title {
  --fit: 1;
  margin: 0;
  min-width: 0;
  font-weight: 500;
  letter-spacing: -0.05em;
  line-height: 0.88;
  text-wrap: pretty;
  font-size: calc(
    min(
      (100cqh / 5.05),
      ((100cqw - var(--face) - var(--gap)) / 7.15)
    ) * var(--fit)
  );
  transform-origin: 0% 100%;
  animation: settle 0.95s var(--ease) both;
}

@keyframes settle {
  from { transform: translateY(-0.065em) scale(1.042); }
  to { transform: translateY(0) scale(1); }
}

html[lang="pl"] .hero-title { --fit: 0.9; }

.hero-face {
  width: 168px;
  height: 168px;
  justify-self: end;
  align-self: end;
}

.hero-under {
  padding-top: clamp(0.7rem, 1.6svh, 1.15rem);
  max-width: 38rem;
}

.eyebrow,
.hero-lead,
.hero-actions {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.4;
  letter-spacing: -0.011em;
}

.eyebrow { color: var(--muted); }

.hero-lead {
  margin-top: 0.2rem;
  color: var(--ink);
}

.hero-actions { margin-top: 0.7rem; }

.hero-actions a {
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
}

.hero-actions a:hover { text-decoration-thickness: 2px; }

/* Face — geometry from the live page. Colors only are shifted to warm ink. */
.face-stage {
  position: relative;
  width: 168px;
  height: 168px;
  display: grid;
  place-items: center;
  overflow: visible;
}

.face-rig {
  width: 132px;
  height: 132px;
  transform-origin: 50% 60%;
  z-index: 1;
}

.face-orb {
  position: relative;
  width: 132px;
  height: 132px;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 28%,
    #f3efe8 0%,
    #cfc4b4 12%,
    #6a5e52 38%,
    #2c241c 68%,
    #140f0c 100%);
  box-shadow:
    0 16px 34px rgba(48, 32, 18, 0.14),
    inset 0 0 16px rgba(255, 244, 230, 0.22),
    inset 8px 10px 14px rgba(255, 248, 240, 0.3),
    inset -10px -14px 18px rgba(20, 12, 8, 0.55);
  transform-origin: 50% 62%;
  cursor: pointer;
}

.face-orb::before {
  content: "";
  position: absolute;
  top: 10%;
  left: 16%;
  width: 38%;
  height: 20%;
  border-radius: 50%;
  background: linear-gradient(160deg, rgba(255, 250, 242, 0.88), rgba(255, 248, 240, 0.08) 70%, transparent);
  pointer-events: none;
}

.face-eyes {
  position: absolute;
  left: 50%;
  top: 46%;
  width: 58px;
  height: 28px;
  margin-left: -29px;
  margin-top: -14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 2;
}

.face-eye {
  width: 11px;
  height: 26px;
  border-radius: 999px;
  background: #fffaf3;
  box-shadow: inset 0 -1px 0 rgba(60, 40, 20, 0.2);
  flex: 0 0 auto;
}

.face-shadow {
  position: absolute;
  left: 50%;
  bottom: 10px;
  width: 78px;
  height: 12px;
  margin-left: -39px;
  border-radius: 50%;
  background: rgba(48, 32, 18, 0.12);
  filter: blur(2px);
  z-index: 0;
}

.face-line {
  margin: 0.35rem 0 0;
  max-width: 16rem;
  text-align: center;
  color: #7a6e62;
  font-size: 0.95rem;
  min-height: 1.5em;
}

.face-spray {
  position: absolute;
  left: 50%;
  top: 68%;
  width: 0;
  height: 0;
  z-index: 3;
  pointer-events: none;
}

.face-drop {
  position: absolute;
  width: 5px;
  height: 8px;
  margin: -4px 0 0 -2px;
  border-radius: 40%;
  background: #5c4a3a;
  animation: face-drop 620ms cubic-bezier(0.12, 0.7, 0.2, 1) forwards;
}

@keyframes face-drop {
  0% { opacity: 0; transform: translate(0, 0) scale(0.35); }
  18% { opacity: 0.95; }
  100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(0.25); }
}

/* Below the fold */
.section {
  padding: clamp(3.5rem, 8vw, 6rem) 0;
  border-top: 1px solid var(--line);
}

.section-head { margin-bottom: 1.75rem; max-width: 36rem; }

.section-head h2,
.section-cta h2 {
  margin: 0 0 0.4rem;
  font-size: clamp(1.45rem, 2.2vw, 1.85rem);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.15;
}

.section-lead,
.section-cta p {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  letter-spacing: -0.011em;
}

.steps {
  list-style: none;
  margin: 0;
  padding: 1.35rem 0 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.25rem, 3vw, 2.5rem);
  border-top: 1px solid var(--line);
}

.step { margin: 0; min-width: 0; }

.step-num {
  display: block;
  margin-bottom: 0.7rem;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
}

.step h3,
.include-card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.step p,
.include-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.98rem;
  letter-spacing: -0.011em;
}

.include-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
}

.include-card {
  display: grid;
  grid-template-columns: minmax(11rem, 16rem) minmax(0, 1fr);
  gap: 1rem 2rem;
  padding: 1.15rem 0;
  border-bottom: 1px solid var(--line);
}

.include-card h3 { margin: 0; }

.section-cta .cta-inner { max-width: 36rem; }

.section-cta p { margin: 0 0 1.25rem; }

.btn {
  display: inline-block;
  padding: 0.8rem 1.05rem;
  background: var(--ink);
  color: var(--bg);
  text-decoration: none;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: -0.011em;
}

.btn:hover { background: #1c1c1c; }

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2.75rem 0 2.25rem;
}

.footer-inner {
  display: grid;
  gap: 1.75rem;
}

.footer-wordmark { margin: 0 0 0.85rem; }

.footer-mark {
  width: min(260px, 70vw);
  height: auto;
}

.footer-tag,
.footer-address,
.footer-copy {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.footer-name {
  margin: 0.85rem 0 0.15rem;
  font-size: 0.95rem;
}

.footer-address { line-height: 1.45; }

.footer-cols {
  display: flex;
  flex-wrap: wrap;
  gap: 2.25rem;
}

.footer-label {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.footer-cols p { margin: 0; }

.footer-cols a {
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.footer-copy { font-size: 0.875rem; }

@media (max-width: 800px) {
  .steps { grid-template-columns: 1fr; gap: 1.35rem; }
  .include-card { grid-template-columns: 1fr; gap: 0.35rem; }
}

@media (max-width: 720px) {
  .wrap { width: min(100% - 1.75rem, var(--wrap)); }

  .header-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "mark lang"
      "nav nav";
    align-items: center;
    column-gap: 0.75rem;
    row-gap: 0.4rem;
  }

  .header-tools {
    display: contents;
  }

  .wordmark { grid-area: mark; }

  .lang-switch { grid-area: lang; }

  .header-nav {
    grid-area: nav;
    justify-content: flex-start;
    gap: 0.3rem 0.85rem;
  }

  .header-nav a { font-size: 0.8rem; }

  .wordmark { font-size: 0.72rem; letter-spacing: 0.18em; }

  .hero-lockup {
    --face: 104px;
    --gap: 0.65rem;
    grid-template-columns: minmax(0, 1fr) 104px;
  }

  .hero-face {
    zoom: calc(104 / 168);
  }

  .hero-title {
    font-size: calc(
      min(
        (100cqh / 8.7),
        ((100cqw - var(--face) - var(--gap)) / 3.85)
      ) * var(--fit)
    );
  }

  html[lang="pl"] .hero-title { --fit: 0.88; }

  .hero-under { padding-top: 0.55rem; }

  .eyebrow,
  .hero-lead,
  .hero-actions {
    font-size: 0.8125rem;
    line-height: 1.35;
  }

  .hero-actions { margin-top: 0.5rem; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-title {
    animation: none;
    transform: none;
  }

  .face-drop { animation: none; }
}
