/* Reset & base */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #020617;
  color: #e5e7eb;
  line-height: 1.7;
}

/* Layout helpers */
main {
  position: relative;
  z-index: 1;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 7vw;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.logo {
  font-weight: 700;
  letter-spacing: 0.16em;
  font-size: 1rem;
  text-transform: uppercase;
  color: #e5e7eb;
}

.main-nav a {
  margin-left: 24px;
  font-size: 0.9rem;
  text-decoration: none;
  color: #cbd5f5;
  position: relative;
  padding-bottom: 4px;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #3b82f6, #22c55e);
  transition: width 0.25s ease;
}

.main-nav a:hover::after {
  width: 100%;
}

/* Hero with parallax feel */
.hero {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 80px 7vw;
  color: #f9fafb;
  overflow: hidden;
  background:
    radial-gradient(circle at 10% 20%, rgba(56, 189, 248, 0.18), transparent 55%),
    radial-gradient(circle at 80% 0%, rgba(59, 130, 246, 0.25), transparent 55%),
    radial-gradient(circle at 0% 100%, rgba(34, 197, 94, 0.18), transparent 55%),
    #020617;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background-image: url("images/twoje_tlo.jpg");
  background-size: cover;
  background-position: center;
  backround-repeat: no-repeat;
  opacity: 0.3;
  transform: translateY(-8vh);
  filter: grayscale(15%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  max-width: 640px;
  z-index: 1;
}

.hero h1 {
  font-size: clamp(2.4rem, 4vw, 3.2rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.hero p {
  font-size: 1rem;
  color: #cbd5f5;
  margin-bottom: 28px;
  max-width: 520px;
}

/* Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 24px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: radial-gradient(circle at 0 0, rgba(59, 130, 246, 0.4), rgba(37, 99, 235, 0.9));
  color: #f9fafb;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.9);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 1);
  background: radial-gradient(circle at 0 0, rgba(59, 130, 246, 0.6), rgba(37, 99, 235, 1));
}

.btn-full {
  width: 100%;
}

/* Sections */
.section {
  padding: 72px 7vw;
  max-width: 1120px;
  margin: 0 auto;
}

.section-header {
  margin-bottom: 32px;
}

.section-header h2 {
  font-size: 1.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #e5e7eb;
  margin-bottom: 8px;
}

.section-header p {
  color: #9ca3af;
  max-width: 520px;
  font-size: 0.98rem;
}

/* Grid */
.grid {
  display: grid;
  gap: 24px;
}

.about-grid {
  grid-template-columns: minmax(0, 2fr) minmax(0, 1.4fr);
}

.services-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.portfolio-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.contact-grid {
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
}

/* Cards */
.card {
  background: radial-gradient(circle at top left, rgba(30, 64, 175, 0.35), rgba(15, 23, 42, 0.98));
  border-radius: 18px;
  padding: 22px 22px 20px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow:
    0 18px 45px rgba(15, 23, 42, 0.9),
    0 0 0 1px rgba(15, 23, 42, 0.9) inset;
}

.card h3 {
  font-size: 1.05rem;
  margin-bottom: 10px;
  color: #e5e7eb;
}

.card p {
  font-size: 0.95rem;
  color: #d1d5db;
}

/* Lists */
.list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.list li {
  font-size: 0.95rem;
  color: #d1d5db;
  margin-bottom: 8px;
}

.list li span {
  color: #9ca3af;
  font-weight: 500;
}

/* Services */
.service-card p + p {
  margin-top: 10px;
}

.brands a,
.brands a:visited {
  color: #93c5fd;
  text-decoration: none;
}

.brands a:hover {
  text-decoration: underline;
}

/* Portfolio */
.project-image-wrapper {
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 14px;
}

.project-image-wrapper img {
  display: block;
  width: 100%;
  height: auto;
  transform: scale(1.02);
  transition: transform 0.4s ease;
}

.project-card:hover .project-image-wrapper img {
  transform: scale(1.06);
}

.project-card-content h3 {
  margin-bottom: 8px;
}

.project-link a,
.project-link a:visited {
  font-size: 0.9rem;
  color: #93c5fd;
  text-decoration: none;
}

.project-link a:hover {
  text-decoration: underline;
}

/* Contact */
.contact-form label {
  display: block;
  font-size: 0.85rem;
  color: #9ca3af;
  margin-bottom: 4px;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  margin-bottom: 14px;
  padding: 9px 11px;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.9);
  color: #e5e7eb;
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 1px rgba(59, 130, 246, 0.6);
  background: rgba(15, 23, 42, 1);
}

.contact-info h3 {
  margin-bottom: 10px;
}

/* Footer */
.site-footer {
  border-top: 1px solid rgba(148, 163, 184, 0.3);
  padding: 18px 7vw 26px;
  text-align: center;
  font-size: 0.85rem;
  color: #9ca3af;
  background: radial-gradient(circle at top, rgba(30, 64, 175, 0.4), #020617);
}

.back-to-top {
  display: inline-block;
  margin-top: 6px;
  font-size: 0.8rem;
  color: #93c5fd;
  text-decoration: none;
}

.back-to-top:hover {
  text-decoration: underline;
}

/* Fade-in animation */
.fade-in {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */
@media (max-width: 900px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .main-nav a {
    margin-left: 0;
    margin-right: 18px;
  }

  .hero {
    padding: 72px 6vw 64px;
  }

  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .section {
    padding: 56px 6vw;
  }

  .hero {
    min-height: 60vh;
  }

  .hero h1 {
    font-size: 2.1rem;
  }

  .hero p {
    font-size: 0.95rem;
  }
}
