/* =============================
       1) ZMIENNE KOLORYSTYKI / MOTYWU
       ============================= */
      :root {
        --blue: #2ea0ff;
        --green: #18e7b4;
        --bg: #f6f7f9;
        --text: #0c0c0d;
        --muted: #5b5b5f;
        --card: rgba(255, 255, 255, 0.7);
        --ring: 0 0 0 3px rgba(46, 160, 255, 0.25);
        --surface: color-mix(in oklab, var(--bg) 65%, transparent);
        --border: color-mix(in oklab, var(--text) 10%, transparent);
      }
      [data-theme="dark"] {
        --bg: #0b0c0f;
        --text: #f5f7fb;
        --muted: #c5c7cf;
        --card: rgba(255, 255, 255, 0.05);
        --surface: color-mix(in oklab, var(--bg) 65%, transparent);
        --border: color-mix(in oklab, var(--text) 12%, transparent);
      }

      * {
        box-sizing: border-box;
      }
      html,
      body {
        height: 100%;
      }
      body {
        margin: 0;
        font: 16px/1.6 system-ui, -apple-system, Segoe UI, Roboto, Ubuntu;
        color: var(--text);
        background: var(--bg);
      }
      a {
        color: inherit;
        text-decoration: none;
      }
      .container {
        max-width: 1150px;
        margin: auto;
        padding: 0 12px;
      }
      @media (min-width: 480px) {
        .container {
          padding: 0 16px;
        }
      }

      /* =============================
       2) PRZYCISKI
       ============================= */
      .btn {
        display: inline-flex;
        gap: 0.5rem;
        align-items: center;
        border: 0;
        border-radius: 14px;
        padding: 0.8rem 1.1rem;
        font-weight: 600;
        color: #fff;
        background: linear-gradient(90deg, var(--blue), #29c7e9, var(--green));
        box-shadow: 0 6px 24px rgba(41, 199, 233, 0.25);
        cursor: pointer;
      }
      .btn.ghost {
        background: transparent;
        color: inherit;
        border: 1px solid var(--border);
        box-shadow: none;
      }
      .btn:focus {
        outline: var(--ring);
      }

      /* =============================
       3) NAGŁÓWEK (sticky + przezroczysty + mobilne menu)
       ============================= */
      header {
        position: sticky;
        top: 0;
        backdrop-filter: saturate(1.1) blur(8px);
        background: var(--surface);
        border-bottom: 1px solid var(--border);
        z-index: 50;
      }
      .head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 10px 0;
        gap: 10px;
        flex-wrap: wrap;
      }
      nav {
        display: none;
      }
      nav a {
        padding: 0.6rem 0.4rem;
        margin: 0 0.25rem;
        border-radius: 10px;
        display: block;
      }
      nav a:hover {
        background: color-mix(in oklab, var(--text) 8%, transparent);
      }
      @media (min-width: 860px) {
        nav {
          display: flex;
          align-items: center;
        }
      }
      /* mobile menu panel */
      .menu-panel {
        position: absolute;
        right: 12px;
        top: 100%;
        background: var(--bg);
        border: 1px solid var(--border);
        border-radius: 14px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
        padding: 8px;
        display: none;
        min-width: min(92vw, 340px);
      }
      .header-open .menu-panel {
        display: block;
      }

      .brand {
        display: flex;
        align-items: center;
        gap: 0.6rem;
        min-width: 0;
      }
      .brand img {
        height: 40px;
        max-width: 60vw;
      }
      @media (min-width: 1024px) {
        .brand img {
          height: 44px;
          max-width: none;
        }
      }
      .logo-header {
        display: block;
      }

      .actions {
        display: flex;
        gap: 0.5rem;
        align-items: center;
        margin-left: auto;
      }
      .mobile-only {
        display: inline-flex;
      }
      @media (min-width: 860px) {
        .mobile-only {
          display: none;
        }
      }

      /* =============================
       4) HERO (glow + karta z logo pionowym)
       ============================= */
      .hero {
        position: relative;
        overflow: hidden;
      }
      .glow {
        position: absolute;
        inset: -20%;
        pointer-events: none;
        filter: blur(90px);
        opacity: 0.45;
        background: radial-gradient(
            600px 600px at 20% 15%,
            var(--blue),
            transparent 60%
          ),
          radial-gradient(480px 480px at 85% 40%, var(--green), transparent 60%);
      }
      .grid-hero {
        display: grid;
        gap: 28px;
        grid-template-columns: 1fr;
      }
      @media (min-width: 900px) {
        .grid-hero {
          grid-template-columns: 1.05fr 0.95fr;
        }
      }
      .kicker {
        text-transform: uppercase;
        letter-spacing: 0.18em;
        color: color-mix(in oklab, var(--text) 55%, transparent);
        font-size: 0.78rem;
      }
      h1 {
        margin: 0.2rem 0 1rem;
        font-size: clamp(28px, 6vw, 52px);
        line-height: 1.1;
      }
      .lead {
        color: color-mix(in oklab, var(--text) 70%, transparent);
        font-size: clamp(0.98rem, 2.5vw, 1.05rem);
      }

      .card {
        border: 1px solid var(--border);
        background: var(--card);
        border-radius: 22px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
      }
      .ratio {
        position: relative;
        width: 100%;
        padding-top: 62%;
      }
      .ratio > * {
        position: absolute;
        inset: 0;
      }
      .hero-logo {
        width: 100%;
        height: 100%;
        object-fit: contain;
        border-radius: 20px;
      }

      section {
        scroll-margin-top: 80px;
      }
      .section {
        padding: 56px 0;
      }
      @media (min-width: 900px) {
        .section {
          padding: 64px 0;
        }
      }
      .section h2 {
        font-size: clamp(22px, 4vw, 36px);
        margin: 0 0 18px;
      }

      /* =============================
       5) USŁUGI / CHIPS
       ============================= */
      .grid-4 {
        display: grid;
        gap: 16px;
        grid-template-columns: repeat(1, 1fr);
      }
      @media (min-width: 540px) {
        .grid-4 {
          grid-template-columns: repeat(2, 1fr);
        }
      }
      @media (min-width: 1024px) {
        .grid-4 {
          grid-template-columns: repeat(4, 1fr);
        }
      }
      .service {
        padding: 18px;
      }
      .service:hover {
        box-shadow: 0 10px 28px rgba(41, 199, 233, 0.18);
      }
      .chips {
        display: flex;
        flex-wrap: wrap;
        gap: 0.6rem;
        list-style: none;
        padding: 0;
        margin: 0;
      }
      .chip {
        font-size: 0.9rem;
        border: 1px solid color-mix(in oklab, var(--text) 14%, transparent);
        padding: 0.45rem 0.85rem;
        border-radius: 999px;
      }

      /* =============================
       6) REALIZACJE — ZDJĘCIA STRON (odświeżane co 24h)
       ============================= */
      .work-grid {
        display: grid;
        gap: 18px;
        grid-template-columns: 1fr;
      }
      @media (min-width: 860px) {
        .work-grid {
          grid-template-columns: repeat(2, 1fr);
        }
      }
      @media (min-width: 1240px) {
        .work-grid {
          grid-template-columns: repeat(3, 1fr);
        }
      }
      .work-shot {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border: 0;
        border-top: 1px solid var(--border);
        background: color-mix(in oklab, var(--text) 4%, transparent);
        display: block;
      }
      .shot-wrap {
        position: relative;
        width: 100%;
        padding-top: 62%;
        border-top: 1px solid var(--border);
      }
      .shot-wrap > img {
        position: absolute;
        inset: 0;
      }

      /* =============================
       7) KONTAKT — wyróżniony tekst + responsywny grid formularza
       ============================= */
      .highlight {
        font-weight: 700;
        font-size: 1.06rem;
        padding: 12px 16px;
        border-radius: 16px;
        color: var(--text);
        background: linear-gradient(
          90deg,
          color-mix(in oklab, var(--blue) 20%, transparent),
          color-mix(in oklab, var(--green) 20%, transparent)
        );
        border: 1px solid var(--border);
        box-shadow: 0 6px 24px rgba(41, 199, 233, 0.18);
      }
      .form-grid {
        display: grid;
        gap: 10px;
        grid-template-columns: 1fr;
      }
      @media (min-width: 640px) {
        .form-grid {
          grid-template-columns: 1fr 1fr;
        }
      }
      input[type="text"],
      textarea,
      input[type="email"] {
        width: 100%;
        border: 1px solid color-mix(in oklab, var(--text) 12%, transparent);
        background: color-mix(in oklab, var(--bg) 85%, transparent);
        color: inherit;
        border-radius: 14px;
        padding: 12px 14px;
      }
      input:focus,
      textarea:focus {
        outline: var(--ring);
      }

      /* =============================
       8) O NAS — responsywna siatka 1→2 kolumny
       ============================= */
      .grid-2 {
        display: grid;
        gap: 16px;
        grid-template-columns: 1fr;
      }
      @media (min-width: 860px) {
        .grid-2 {
          grid-template-columns: 1fr 1fr;
        }
      }

      /* =============================
       9) STOPKA
       ============================= */
      .footer {
        border-top: 1px solid var(--border);
        padding: 28px 0;
        color: color-mix(in oklab, var(--text) 65%, transparent);
        display: flex;
        gap: 16px;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
      }
      .logo-footer {
        height: 64px;
      }
      @media (min-width: 1024px) {
        .logo-footer {
          height: 80px;
        }
      }
      .notice {
        font-size: 0.95rem;
        color: color-mix(in oklab, var(--text) 70%, transparent);
      }

      /* =============================
       10) ANIMACJA IKONY MOTYWU (🌙/☀️)
       ============================= */
      #themeBtn {
        position: relative;
        width: 48px;
        height: 48px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 0;
      }
      #themeBtn span {
        font-size: 20px;
        display: inline-block;
        transition: transform 0.35s ease, opacity 0.25s ease;
      }
      #themeBtn.spin span {
        animation: spin 0.45s ease both;
      }
      @keyframes spin {
        from {
          transform: rotate(-180deg) scale(0.6);
          opacity: 0.2;
        }
        to {
          transform: rotate(0) scale(1);
          opacity: 1;
        }
      }

/* --- split from inline styles --- */

/* === nf-minfix: header-only tweaks === */
      #siteHeader {
        padding: 0 20px;
      }
      #siteHeader .head {
        flex-wrap: nowrap;
      }
      #siteHeader .brand .logo-header {
        height: 32px;
        width: auto;
        transition: height 0.25s ease;
      }
      #siteHeader.header-compact .brand .logo-header {
        height: 26px;
      }
      #siteHeader .menu-panel nav a + a {
        border-top: 1px solid rgba(135, 181, 255, 0.14);
      }
      /* responsive visibility only (no color/layout changes) */
      #siteHeader .nav-desktop {
        display: none;
      }
      #menuBtn.mobile-only {
        display: inline-flex;
      }
      @media (min-width: 860px) {
        #siteHeader .nav-desktop {
          display: flex;
        }
        #menuBtn.mobile-only {
          display: none;
        }
        #siteHeader .menu-panel {
          display: none !important;
        }
      }

/* --- split from inline styles --- */

/* 1) Header – odstępy i jedna linia */
      #siteHeader {
        position: sticky;
        top: 0;
        padding: 0 20px;
      }
      #siteHeader .head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: nowrap;
      }

      /* 2) Logo skaluje się proporcjonalnie i nie łamie linii */
      #siteHeader .brand .logo-header {
        height: 32px;
        width: auto;
        transition: height 0.25s;
      }
      #siteHeader.header-compact .brand .logo-header {
        height: 26px;
      }

      /* 3) Panel mobilny – bazowe reguły i stan .open */
      #siteHeader {
        z-index: 1000;
      } /* nad treścią */
      #siteHeader .menu-panel {
        position: absolute;
        right: 12px;
        top: 100%;
        display: none; /* ukryty domyślnie */
        z-index: 2000; /* ponad headerem/hero */
      }
      #siteHeader .menu-panel.open {
        display: block;
      }
      #siteHeader .menu-panel nav a + a {
        border-top: 1px solid rgba(135, 181, 255, 0.14); /* separator */
      }

      /* 4) Widoczność desktop vs mobile (nic o kolorach/layoutach strony) */
      #siteHeader .nav-desktop {
        display: none;
      }
      #menuBtn.mobile-only {
        display: inline-flex;
      }
      @media (min-width: 860px) {
        #siteHeader .nav-desktop {
          display: flex;
        }
        #menuBtn.mobile-only {
          display: none;
        }
        #siteHeader .menu-panel {
          display: none !important;
        }
      }

/* --- split from inline styles --- */

#siteHeader { z-index: 2000; }
#siteHeader.header-open .menu-panel { display: block !important; }
#siteHeader .menu-panel nav { display: block; }

/* --- split from inline styles --- */

/* Efekt hover dla pozycji menu (desktop i mobile) */
#siteHeader .nav-desktop a:hover,
#siteHeader .menu-panel nav a:hover {
  background: rgba(135,181,255,0.15);   /* delikatne podświetlenie tła */
  color: #87b5ff;                       /* lekki akcent koloru tekstu */
  transition: background .2s ease, color .2s ease;
  border-radius: 8px;
}

/* --- split from inline styles --- */

/* Responsywne skalowanie przycisku w nagłówku */
#siteHeader .actions .btn {
  padding: 0.7rem 1.1rem;
  font-size: 0.95rem;
}
@media (max-width: 900px) {
  #siteHeader .actions .btn {
    padding: 0.55rem 0.9rem;
    font-size: 0.88rem;
  }
}
@media (max-width: 600px) {
  #siteHeader .actions .btn {
    padding: 0.45rem 0.8rem;
    font-size: 0.82rem;
  }
}

/* --- split from inline styles --- */

/* Ujednolicenie WIELKOŚCI przycisku zmiany motywu (księżyc) */
#siteHeader #themeBtn {
  inline-size: clamp(36px, 5vw, 44px);  /* szerokość */
  block-size: clamp(36px, 5vw, 44px);   /* wysokość */
  padding: 0;                           /* ikona centralnie, bez zbędnego paddingu */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(14px, 2.6vw, 18px);  /* rozmiar ikony */
  line-height: 1;
  border-radius: 12px;
}
#siteHeader #themeIcon { font-size: inherit; line-height: 1; }

/* --- split from inline styles --- */

/* Responsywne skalowanie przycisków "Otwórz stronę" w sekcji realizacji */
#workGrid .btn {
  padding: 0.75rem 1.2rem;
  font-size: 0.95rem;
  border-radius: 14px;
}
@media (max-width: 1024px) {
  #workGrid .btn {
    padding: 0.65rem 1.05rem;
    font-size: 0.9rem;
  }
}
@media (max-width: 768px) {
  #workGrid .btn {
    padding: 0.55rem 0.9rem;
    font-size: 0.85rem;
  }
}
@media (max-width: 480px) {
  #workGrid .btn {
    padding: 0.45rem 0.8rem;
    font-size: 0.8rem;
  }
}

/* --- split from inline styles --- */

/* Sticky header tylko na desktopie; nie chowa się przy scrollu */
@media (min-width: 1024px) {
  #siteHeader {
    position: sticky;
    top: 0;
    z-index: 2000;
  }
  /* Jeśli jakiś skrypt dodaje .header-hide, na desktopie ignorujemy to */
  #siteHeader.header-hide {
    transform: none !important;
  }
}

/* --- split from inline styles --- */

/* Hero: wyrównanie kolumn do jednej linii na górze */
@media (min-width: 1024px) {
  #home .grid-hero { align-items: start; }
  #home .grid-hero > * { padding-top: 0 !important; }
  #home .grid-hero > :first-child,
  #home .grid-hero > :nth-child(2) { padding-top: 24px !important; }
}