:root {
  --background: #0b0d10;
  --background-soft: #12151a;
  --text: #f3f3f1;
  --text-muted: #a5a8ad;
  --line: rgba(255, 255, 255, 0.14);
  --accent: #d9b46f;

  --page-width: 1280px;
  --header-height: 82px;
}

/* Reset */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
}

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  font-size: 17px;
  line-height: 1.7;
}

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

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

/* Wspólny kontener */

.site-header,
main,
footer {
  width: min(
    calc(100% - 48px),
    var(--page-width)
  );
  margin-inline: auto;
}

/* Nagłówek */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;

  min-height: var(--header-height);

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;

  background:
    linear-gradient(
      to bottom,
      rgba(11, 13, 16, 0.96),
      rgba(11, 13, 16, 0.82)
    );

  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 46px;
  height: 46px;

  border: 1px solid var(--line);
  border-radius: 50%;

  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.12em;

  transition:
    border-color 200ms ease,
    color 200ms ease,
    transform 200ms ease;
}

.logo:hover {
  color: var(--accent);
  border-color: var(--accent);
  transform: rotate(-6deg);
}

nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

nav a {
  position: relative;
  color: var(--text-muted);
  font-size: 14px;
  letter-spacing: 0.04em;
  transition: color 200ms ease;
}

nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -8px;

  width: 100%;
  height: 1px;

  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 200ms ease;
}

nav a:hover {
  color: var(--text);
}

nav a:hover::after {
  transform: scaleX(1);
}

/* Sekcja startowa */

.hero {
  min-height: calc(100vh - var(--header-height));

  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;

  padding-block: 100px;
  border-bottom: 1px solid var(--line);
}

.section-label {
  margin: 0 0 22px;

  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;

  max-width: 1000px;

  font-size: clamp(64px, 11vw, 158px);
  font-weight: 700;
  line-height: 0.84;
  letter-spacing: -0.065em;
}

.hero h1 span {
  display: block;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.7);
}

.hero-description {
  max-width: 640px;
  margin: 46px 0 0;

  color: var(--text-muted);
  font-size: clamp(18px, 2vw, 25px);
  line-height: 1.5;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  min-height: 52px;
  margin-top: 40px;
  padding: 12px 26px;

  border: 1px solid var(--accent);

  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;

  transition:
    background-color 200ms ease,
    color 200ms ease,
    transform 200ms ease;
}

.button:hover {
  background: var(--accent);
  color: #0b0d10;
  transform: translateY(-2px);
}

/* Sekcje treści */

.content-section {
  display: grid;
  grid-template-columns: minmax(70px, 0.25fr) minmax(0, 1fr);
  gap: clamp(30px, 6vw, 110px);

  min-height: 70vh;
  padding-block: clamp(100px, 12vw, 180px);

  border-bottom: 1px solid var(--line);
}

.section-number {
  margin: 4px 0 0;

  color: var(--text-muted);
  font-size: 14px;
  letter-spacing: 0.14em;
}

.content-section > div {
  max-width: 900px;
}

.content-section h2 {
  max-width: 850px;
  margin: 0 0 34px;

  font-size: clamp(42px, 6vw, 88px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.045em;
}

.content-section > div > p:not(.section-label) {
  max-width: 720px;
  margin: 0;

  color: var(--text-muted);
  font-size: clamp(18px, 2vw, 23px);
}

/* Projekty */

article {
  display: grid;
  grid-template-columns: minmax(220px, 0.55fr) minmax(0, 1fr);
  gap: 40px;

  margin-top: 0;
  padding-block: 36px;

  border-top: 1px solid var(--line);
}

article:last-of-type {
  border-bottom: 1px solid var(--line);
}

article h3 {
  margin: 0;

  font-size: clamp(23px, 3vw, 34px);
  font-weight: 500;
  line-height: 1.2;
}

article p {
  margin: 0;
  color: var(--text-muted);
}

/* Kontakt */

#kontakt a {
  display: inline-block;
  margin-top: 36px;

  color: var(--text);
  font-size: clamp(22px, 3vw, 38px);
  line-height: 1.2;

  border-bottom: 1px solid var(--accent);

  transition:
    color 200ms ease,
    border-color 200ms ease;
}

#kontakt a:hover {
  color: var(--accent);
  border-color: transparent;
}

/* Stopka */

footer {
  min-height: 120px;

  display: flex;
  align-items: center;
  justify-content: flex-end;

  color: var(--text-muted);
  font-size: 13px;
  letter-spacing: 0.05em;
}

/* Widok mobilny */

@media (max-width: 800px) {
  :root {
    --header-height: 70px;
  }

  .site-header,
  main,
  footer {
    width: min(
      calc(100% - 30px),
      var(--page-width)
    );
  }

  nav {
    gap: 16px;
    overflow-x: auto;
  }

  nav a {
    white-space: nowrap;
    font-size: 12px;
  }

  .hero {
    min-height: calc(100svh - var(--header-height));
    padding-block: 70px;
  }

  .hero h1 {
    font-size: clamp(58px, 18vw, 100px);
  }

  .hero-description {
    margin-top: 32px;
  }

  .content-section {
    grid-template-columns: 1fr;
    gap: 28px;

    min-height: auto;
    padding-block: 90px;
  }

  .content-section h2 {
    font-size: clamp(40px, 12vw, 66px);
  }

  article {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  footer {
    justify-content: flex-start;
  }
}

@media (max-width: 560px) {
  .logo {
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
  }

  nav a:nth-child(2),
  nav a:nth-child(3) {
    display: none;
  }

  .hero h1 {
    letter-spacing: -0.075em;
  }
}

/* Ograniczenie animacji zgodnie z ustawieniami użytkownika */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
