/* PeakSolution — style */
:root {
  color-scheme: dark;
  --bg: #080810;
  --surface: #12111d;
  --surface-2: #1a1729;
  --fg: #f0eff7;
  --muted: #aeadc2;
  --line: #ffffff14;
  --purple: #a544ff;
  --purple-soft: #c895ff;
  --blue: #36b9ff;
  --grad: linear-gradient(100deg, #c044ff, #7246ff 55%, #39caff);
  --radius: 14px;
  --header-h: 76px;
  --font: Inter, "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
  margin: 0;
  background:
    radial-gradient(ellipse at 92% 0%, #1b1039 0, transparent 40%),
    var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }

a:focus-visible, button:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
  border-radius: 6px;
}

.wrap { width: min(100% - 40px, 1240px); margin-inline: auto; }

.skip {
  position: absolute; left: 16px; top: -60px; z-index: 20;
  background: var(--fg); color: var(--bg); padding: 10px 16px; border-radius: 8px; font-weight: 600;
}
.skip:focus { top: 12px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: #080810d9;
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.nav { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: block; }
.logo { width: 180px; height: auto; display: block; }

nav { display: flex; align-items: center; gap: 30px; font-size: 15px; }
nav > a:not(.button) { color: var(--muted); position: relative; padding: 6px 0; transition: color .2s; }
nav > a:not(.button):hover, nav > a.active { color: var(--fg); }
nav > a:not(.button)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px;
  background: var(--grad); border-radius: 2px;
  transform: scaleX(0); transform-origin: left; transition: transform .25s;
}
nav > a.active::after { transform: scaleX(1); }

.menu {
  display: none; width: 44px; height: 44px; padding: 11px 10px;
  background: none; border: 1px solid var(--line); border-radius: 10px; cursor: pointer;
  flex-direction: column; justify-content: space-between;
}
.menu span { display: block; height: 2px; background: var(--fg); border-radius: 2px; transition: transform .25s, opacity .2s; }
.menu[aria-expanded="true"] span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.menu[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu[aria-expanded="true"] span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 24px;
  border: 1px solid #c17bff; border-radius: 10px;
  background: linear-gradient(115deg, #9a20ed, #4421aa);
  box-shadow: 0 0 24px #801deb36;
  color: #fff; font-weight: 650; font-size: 15px; line-height: 1.2;
  transition: transform .2s, box-shadow .2s, background-color .2s;
}
.button:hover { transform: translateY(-2px); box-shadow: 0 0 32px #a544ff70; }
.button.small { min-height: 40px; padding: 8px 18px; font-size: 14px; }
.button.ghost { background: #ffffff08; border-color: #ffffff38; box-shadow: none; }
.button.ghost:hover { border-color: var(--purple-soft); background: #a544ff14; }
.button.big { font-size: 17px; padding: 16px 28px; }

/* ---------- Hero ---------- */
.hero { position: relative; isolation: isolate; overflow: hidden; padding: 96px 0 40px; }
.hero-art {
  position: absolute; z-index: -1;
  top: 0; bottom: 0; right: -2%; width: min(62%, 980px);
  background: url("assets/hero.webp") 30% center / cover no-repeat;
  mask-image: linear-gradient(90deg, transparent 0%, #000 30%), linear-gradient(0deg, transparent 0%, #000 25%);
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 30%);
  -webkit-mask-composite: source-in; mask-composite: intersect;
  opacity: .95;
  transform: translate(var(--mx, 0), var(--my, 0)) scale(1.03);
  transition: transform .3s ease-out;
}
.hero::after { /* łagodne przejście w dół do sekcji */
  content: ""; position: absolute; inset: auto 0 0 0; height: 120px; z-index: -1;
  background: linear-gradient(0deg, var(--bg), transparent);
}
.hero-inner { min-height: 400px; display: flex; align-items: center; }
.hero-copy { max-width: 640px; }

h1 {
  font-size: clamp(44px, 6.4vw, 92px);
  line-height: .98;
  letter-spacing: -.045em;
  font-weight: 850;
  text-transform: uppercase;
  text-wrap: balance;
  /* gradient na całym nagłówku – nawiązanie do logo */
  background: linear-gradient(180deg, #ffffff 30%, #cdbdff 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 4px 24px #000c);
}
.lead {
  max-width: 34em; margin: 26px 0 32px;
  color: #d6d3e4; font-size: 18px; line-height: 1.6;
  text-shadow: 0 2px 8px #000;
}
.actions { display: flex; gap: 12px; flex-wrap: wrap; }

.stack {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line);
}
.stack li {
  font-size: 13px; color: var(--muted);
  padding: 6px 12px; border: 1px solid #ffffff1c; border-radius: 999px; background: #ffffff05;
}

/* ---------- Sections ---------- */
.section { padding: 88px 0; border-top: 1px solid var(--line); }
.section-head {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 24px 48px; align-items: end; margin-bottom: 40px;
}
h2 {
  font-size: clamp(30px, 3.6vw, 48px);
  line-height: 1.08; letter-spacing: -.035em; font-weight: 800;
  text-wrap: balance;
}
.section-head p { color: var(--muted); max-width: 46ch; font-size: 16px; }
h3 { font-size: 20px; line-height: 1.25; letter-spacing: -.01em; }

/* Oferta */
.services { display: grid; gap: 16px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tile {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; flex-direction: column;
  padding: 120px 22px 24px;
  border: 1px solid #6f4a9b66; border-radius: var(--radius);
  background: linear-gradient(160deg, var(--surface-2), #0c0c16);
  transition: border-color .25s;
}
.tile:hover { border-color: #b15aff; }
.tile img {
  position: absolute; inset: 0 0 auto 0; width: 100%; height: 190px; object-fit: cover;
  opacity: .5; z-index: -2;
  mask-image: linear-gradient(#000 30%, transparent);
  -webkit-mask-image: linear-gradient(#000 30%, transparent);
}
.symbol { font-size: 28px; color: #d080ff; line-height: 1; margin-bottom: 16px; }
.tile h3 { margin-bottom: 8px; }
.tile p { font-size: 15px; color: #cbc7da; }
.tile ul { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.tile li { font-size: 14px; color: var(--muted); padding-left: 18px; position: relative; }
.tile li::before {
  content: ""; position: absolute; left: 0; top: .62em; width: 7px; height: 7px;
  border-radius: 2px; background: var(--grad); transform: rotate(45deg);
}

/* Projekty */
.projects { display: grid; gap: 16px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.project {
  display: flex; flex-direction: column; overflow: hidden;
  border: 1px solid #6f4a9b66; border-radius: var(--radius);
  background: var(--surface);
  transition: border-color .25s;
}
.project:hover { border-color: #b15aff; }
.project img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 7; object-fit: cover; }
.project-body { display: flex; flex-direction: column; gap: 8px; padding: 22px; flex: 1; }
.tag { font-size: 13px; color: var(--purple-soft); }
.project p { font-size: 15px; color: #cbc7da; flex: 1; }
.more { align-self: flex-start; margin-top: 8px; font-size: 15px; font-weight: 600; color: var(--purple-soft); border-bottom: 1px solid #c895ff55; transition: color .2s, border-color .2s; }
.more:hover { color: #fff; border-color: #fff; }
.status { align-self: flex-start; margin-top: 8px; font-size: 13px; color: var(--muted); padding: 3px 10px; border: 1px dashed #ffffff30; border-radius: 999px; }

/* Proces */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; counter-reset: step; position: relative; }
.steps li { counter-increment: step; position: relative; padding: 56px 28px 0 0; }
.steps li::before {
  content: counter(step);
  position: absolute; top: 0; left: 0;
  width: 36px; height: 36px; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid #b15aff; background: var(--bg);
  font-weight: 700; font-size: 15px; color: var(--purple-soft);
}
.steps li::after { /* linia łącząca kroki */
  content: ""; position: absolute; top: 18px; left: 44px; right: 8px; height: 1px;
  background: linear-gradient(90deg, #b15aff88, #36b9ff33);
}
.steps li:last-child::after { display: none; }
.steps h3 { margin-bottom: 8px; }
.steps p { color: var(--muted); font-size: 15px; max-width: 30ch; }

/* O studiu */
.about .section-head { grid-template-columns: 1fr; margin-bottom: 32px; }
.about-body { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.about-lead { font-size: 20px; line-height: 1.55; color: #dedbea; max-width: 34em; }
.facts { display: grid; gap: 0; }
.facts > div { padding: 18px 0; border-top: 1px solid var(--line); }
.facts > div:last-child { border-bottom: 1px solid var(--line); }
.facts dt { font-weight: 700; margin-bottom: 4px; }
.facts dd { color: var(--muted); font-size: 15px; }

/* Kontakt */
.contact {
  margin-block: 24px 56px;
  border: 1px solid #9a55e6; border-radius: 20px;
  background: radial-gradient(ellipse at 90% 100%, #3b1674, transparent 65%), #0e0d19;
  padding: 48px;
  display: flex; gap: 32px; align-items: center; justify-content: space-between; flex-wrap: wrap;
}
.contact-copy { max-width: 560px; }
.contact-copy p { color: var(--muted); margin-top: 14px; }
.contact-actions { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.copy {
  background: none; border: 0; padding: 4px 0; cursor: pointer;
  color: var(--muted); font: inherit; font-size: 14px; text-decoration: underline; text-underline-offset: 3px;
}
.copy:hover { color: var(--fg); }
.copy-status { font-size: 14px; color: #8fe0b0; min-height: 1.4em; }

/* Stopka */
.site-footer {
  display: flex; justify-content: space-between; align-items: center; gap: 18px; flex-wrap: wrap;
  padding: 24px 0 40px; border-top: 1px solid var(--line);
  color: var(--muted); font-size: 14px;
}
.site-footer img { width: 120px; height: auto; }
.site-footer a:hover { color: var(--fg); }

/* ---------- Responsywność ---------- */
@media (max-width: 1100px) {
  .services { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 40px; }
  .steps li:nth-child(2)::after { display: none; }
  .hero-art { width: 75%; opacity: .7; }
}

@media (max-width: 860px) {
  :root { --header-h: 64px; }
  .logo { width: 150px; }
  .menu { display: flex; }
  nav {
    display: none; position: absolute; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 4px;
    padding: 12px 20px 24px; background: #0f0f1bf7; border-bottom: 1px solid var(--line);
  }
  nav.open { display: flex; }
  nav > a:not(.button) { padding: 12px 0; font-size: 17px; border-bottom: 1px solid var(--line); }
  nav > a:not(.button)::after { display: none; }
  nav .button { margin-top: 12px; }

  .hero { padding: 0 0 32px; }
  .hero-art {
    position: relative; display: block; width: 100%; right: 0; height: 52vw; max-height: 340px;
    background-position: center;
    mask-image: linear-gradient(#000 55%, transparent);
    -webkit-mask-image: linear-gradient(#000 55%, transparent);
    opacity: .9; transform: none;
  }
  .hero-inner { min-height: 0; margin-top: -24px; }
  .lead { font-size: 16px; }
  .stack { margin-top: 36px; }

  .section { padding: 64px 0; }
  .section-head { grid-template-columns: 1fr; margin-bottom: 28px; }
  .projects { grid-template-columns: 1fr; }
  .about-body { grid-template-columns: 1fr; gap: 28px; }
  .about-lead { font-size: 18px; }
  .contact { padding: 28px 22px; }
}

@media (max-width: 560px) {
  .wrap { width: min(100% - 32px, 1240px); }
  .services { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; row-gap: 28px; }
  .steps li { padding: 0 0 0 56px; }
  .steps li::after { display: none; }
  .actions .button { flex: 1 1 100%; }
  .button.big { font-size: 16px; width: 100%; }
  .contact-actions { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .hero-art { transform: none; }
}
