/* ---------- Sekcja: pasek z logo + „Less noise” ---------- */

.sig-section {
    width: 100%;
    padding: 40px 0 110px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: hidden;
    /* od białego (pod paskiem logo) do jasnej zieleni (pod kartami) */
    background: linear-gradient(to bottom, #ffffff 0%, #ffffff 18%, #f1f7f0 60%, #eef5ec 100%);
}

/* ---------- Pasek z logo ---------- */

.sig-caption {
    margin: 0 20px;
    font-family: 'Inter', 'Inter Fallback', Arial, sans-serif;
    font-size: 13px;
    line-height: 20px;
    letter-spacing: -0.2px;
    color: #6b7671;
    text-align: center;
}

.sig-marquee {
    width: 100%;
    max-width: 1200px;
    margin-top: 22px;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
            mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
}

.sig-track {
    display: flex;
    width: max-content;
    animation: sig-scroll 40s linear infinite;
}

.sig-marquee:hover .sig-track { animation-play-state: paused; }

@keyframes sig-scroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

.sig-list {
    display: flex;
    align-items: center;
    gap: 56px;
    margin: 0;
    padding: 0 28px;          /* połowa gap → równy odstęp na łączeniu list */
    list-style: none;
    flex-shrink: 0;
}

.sig-list li {
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
    font-family: 'Inter', 'Inter Fallback', Arial, sans-serif;
    font-weight: 500;
    font-size: 16px;
    line-height: 24px;
    letter-spacing: -0.3px;
    color: #7d8783;
    transition: color 0.2s;
}

.sig-list img {
    width: 20px;
    height: 20px;
    object-fit: contain;
    filter: grayscale(1);
    opacity: 0.6;
    transition: filter 0.2s, opacity 0.2s;
}

.sig-list li:hover { color: #101c19; }
.sig-list li:hover img { filter: none; opacity: 1; }

/* ---------- Nagłówek ---------- */

.sig-head {
    margin-top: 90px;
    padding: 0 20px;
    max-width: 720px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.sig-lead {
    max-width: 440px;
}

/* ---------- Siatka kart (schodkowo) ---------- */

.sig-grid {
    width: 100%;
    max-width: 1100px;
    margin-top: 48px;
    padding: 0 20px;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    align-items: start;
}

.sig-card {
    padding: 16px 16px 22px;
    background: #ffffff;
    border: 1px solid #e5ece7;
    border-radius: 20px;
    box-shadow: 0 1px 2px rgba(16, 28, 25, 0.03);
    transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.4s;
}

/* 2. i 4. karta niżej */
.sig-card:nth-child(even) { margin-top: 24px; }

.sig-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 40px rgba(16, 28, 25, 0.08);
}

/* Zielony panel z wykresem i liczbą */
.sig-visual {
    padding: 18px 16px 18px;
    border-radius: 14px;
    background:
        radial-gradient(circle at 85% 15%, rgba(255, 255, 255, 0.9) 0%, transparent 45%),
        linear-gradient(160deg, #e6f4ea 0%, #d3ecdc 100%);
    text-align: center;
}

.sig-num {
    margin: 16px 0 0;
    font-family: 'Inter', 'Inter Fallback', Arial, sans-serif;
    font-weight: 500;
    font-size: 38px;
    line-height: 44px;
    letter-spacing: -1.4px;
    color: #101c19;
    font-variant-numeric: tabular-nums;
}

.sig-label {
    margin: 8px 0 0;
    font-family: 'Inter', 'Inter Fallback', Arial, sans-serif;
    font-weight: 500;
    font-size: 10.5px;
    line-height: 14px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    color: #4b5552;
}

.sig-title {
    margin: 22px 4px 0;
    font-family: 'Inter', 'Inter Fallback', Arial, sans-serif;
    font-weight: 500;
    font-size: 19px;
    line-height: 25px;
    letter-spacing: -0.5px;
    color: #101c19;
}

.sig-desc {
    margin: 10px 4px 0;
    font-family: 'Inter', 'Inter Fallback', Arial, sans-serif;
    font-size: 13px;
    line-height: 19px;
    color: #5f6a66;
}

/* ---------- Mini wizualizacje ---------- */

.sig-mini {
    position: relative;
    height: 112px;
    font-family: 'Inter', 'Inter Fallback', Arial, sans-serif;
    text-align: left;
}

.sig-small {
    display: block;
    font-size: 8px;
    letter-spacing: 0.4px;
    color: #6b7671;
}

/* 1: słupki */
.sig-bars {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    padding: 26px 10px 2px;          /* miejsce na etykietę nad słupkami */
    box-sizing: border-box;
}

.sig-bars i {
    flex: 1;
    height: var(--h);
    border-radius: 3px 3px 1px 1px;
    background: linear-gradient(to top, #8fd69e, #1f9d58);
    transform-origin: bottom;
    transform: scaleY(0);
    transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.sig-bars i:nth-of-type(1)  { transition-delay: 0.00s; }
.sig-bars i:nth-of-type(2)  { transition-delay: 0.05s; }
.sig-bars i:nth-of-type(3)  { transition-delay: 0.10s; }
.sig-bars i:nth-of-type(4)  { transition-delay: 0.15s; }
.sig-bars i:nth-of-type(5)  { transition-delay: 0.20s; }
.sig-bars i:nth-of-type(6)  { transition-delay: 0.25s; }
.sig-bars i:nth-of-type(7)  { transition-delay: 0.30s; }
.sig-bars i:nth-of-type(8)  { transition-delay: 0.35s; }
.sig-bars i:nth-of-type(9)  { transition-delay: 0.40s; }
.sig-bars i:nth-of-type(10) { transition-delay: 0.45s; }

.sig-chip {
    position: absolute;
    top: 0;
    right: 6px;
    padding: 3px 9px;
    border-radius: 999px;
    background: #ffffff;
    box-shadow: 0 4px 10px rgba(16, 28, 25, 0.06);
    font-size: 8.5px;
    font-weight: 500;
    color: #087443;
}

/* 2: linia */
.sig-line {
    padding: 10px 12px;
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 8px 18px rgba(16, 28, 25, 0.06);
    box-sizing: border-box;
}

.sig-price {
    display: block;
    margin-top: 2px;
    font-size: 15px;
    line-height: 20px;
    font-weight: 500;
    color: #101c19;
}

.sig-line svg {
    position: absolute;
    left: 6px;
    right: 8px;
    bottom: 10px;
    width: calc(100% - 14px);
    height: 58px;
}

.sig-path {
    vector-effect: non-scaling-stroke;   /* grubość linii stała przy każdej szerokości karty */
}

/* linia „rysuje się” od lewej: odsłaniamy wykres maską */
.sig-line svg {
    clip-path: inset(0 100% 0 0);
    transition: clip-path 1.4s cubic-bezier(0.45, 0, 0.2, 1) 0.2s;
}

/* kropka na końcu linii (HTML, żeby nie rozciągała się razem z wykresem) */
.sig-dot {
    position: absolute;
    right: 7px;
    top: 47px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #f2a45a;
    box-shadow: 0 0 0 3px rgba(242, 164, 90, 0.25);
    opacity: 0;
    transition: opacity 0.3s 1.5s;
}

.sig-signal {
    position: absolute;
    right: 10px;
    bottom: 8px;
    padding: 3px 9px;
    border-radius: 999px;
    background: #fdeedd;
    font-size: 8px;
    font-weight: 500;
    color: #b0611d;
}

/* 3: brief */
.sig-brief {
    margin: 0 4px;
    padding: 10px 12px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 8px 18px rgba(16, 28, 25, 0.06), 6px 8px 0 -2px #c7e3d1;
    box-sizing: border-box;
}

.sig-brief-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 9px;
}

.sig-brief-row i {
    width: 13px;
    height: 13px;
    flex-shrink: 0;
    border-radius: 3px;
}

.sig-brief-row span { flex: 1; display: grid; gap: 4px; }

.sig-brief-row em {
    display: block;
    height: 3px;
    border-radius: 2px;
    background: #dfe7e1;
}

.sig-ready {
    position: absolute;
    right: -6px;
    bottom: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    background: #0d5c37;
    color: #ffffff;
    font-size: 8px;
    font-weight: 600;
    transform: scale(0.6);
    opacity: 0;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.6s, opacity 0.3s 0.6s;
}

/* 4: hub */
.sig-hub-lines {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.sig-hub-lines line {
    stroke: #b9d3c1;
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
}

.sig-hub-center {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 46px;
    height: 46px;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: #12231c;
    color: #a8e6b0;
    font-size: 17px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 0 6px rgba(18, 35, 28, 0.08);
}

.sig-node {
    position: absolute;
    width: 24px;
    height: 24px;
    transform: translate(-50%, -50%);
    border-radius: 7px;
    background: #ffffff;
    box-shadow: 0 3px 8px rgba(16, 28, 25, 0.08);
    font-size: 11px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* pomarańczowa kropka „needs attention” */
.sig-node-alert::after {
    content: "";
    position: absolute;
    top: -4px;
    right: -4px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #f2a45a;
    box-shadow: 0 0 0 0 rgba(242, 164, 90, 0.6);
    animation: sig-pulse 2s ease-out infinite;
}

@keyframes sig-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(242, 164, 90, 0.6); }
    70%  { box-shadow: 0 0 0 8px rgba(242, 164, 90, 0); }
    100% { box-shadow: 0 0 0 0 rgba(242, 164, 90, 0); }
}

/* ---------- Animacje po pojawieniu się na ekranie ---------- */

/* Karty wjeżdżają po kolei (klasa is-ready dodawana z JS – bez JS wszystko jest widoczne) */
.sig-grid.is-ready .sig-card {
    opacity: 0;
    translate: 0 30px;
    transition: opacity 0.7s ease, translate 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.4s;
}

.sig-grid.is-ready .sig-card:nth-child(2) { transition-delay: 0.1s, 0.1s, 0s, 0s; }
.sig-grid.is-ready .sig-card:nth-child(3) { transition-delay: 0.2s, 0.2s, 0s, 0s; }
.sig-grid.is-ready .sig-card:nth-child(4) { transition-delay: 0.3s, 0.3s, 0s, 0s; }

.sig-grid.is-visible .sig-card { opacity: 1; translate: 0 0; }

/* Bez JS albo po pojawieniu: pełne wykresy */
.sig-grid:not(.is-ready) .sig-bars i,
.sig-grid.is-visible .sig-bars i   { transform: scaleY(1); }

.sig-grid:not(.is-ready) .sig-line svg,
.sig-grid.is-visible .sig-line svg { clip-path: inset(0 0 0 0); }

.sig-grid:not(.is-ready) .sig-dot,
.sig-grid.is-visible .sig-dot      { opacity: 1; }

.sig-grid:not(.is-ready) .sig-ready,
.sig-grid.is-visible .sig-ready    { transform: scale(1); opacity: 1; }

/* ---------- Responsywność ---------- */

@media (max-width: 1024px) {
    .sig-grid {
        grid-template-columns: repeat(2, 1fr);
        max-width: 640px;
    }

    .sig-card:nth-child(even) { margin-top: 24px; }
    .sig-card:nth-child(3)    { margin-top: -24px; }   /* zachowuje schodki w 2 kolumnach */
}

@media (max-width: 640px) {
    .sig-section { padding: 32px 0 70px; }

    .sig-list { gap: 36px; padding: 0 18px; }
    .sig-list li { font-size: 14px; }
    .sig-list img { width: 18px; height: 18px; }
    .sig-track { animation-duration: 30s; }

    .sig-head { margin-top: 60px; padding: 0 16px; }

    .sig-grid {
        grid-template-columns: 1fr;
        max-width: 420px;
        padding: 0 16px;
        gap: 14px;
    }

    .sig-card:nth-child(n) { margin-top: 0; }

    .sig-num { font-size: 34px; line-height: 40px; }
}

@media (prefers-reduced-motion: reduce) {
    .sig-track,
    .sig-node-alert::after { animation: none; }

    .sig-grid.is-ready .sig-card,
    .sig-bars i, .sig-line svg, .sig-dot, .sig-ready { transition: none; }
}