/* ITINS — strona główna. Paleta w :root */
:root {
    --bg: #05070d;
    --text: #f2f5fb;
    --muted: #8b93a7;
    --line: rgba(255, 255, 255, .08);
    --glass: rgba(255, 255, 255, .035);
    /* kolory z gradientu logo */
    --brand-1: #3b82f6;
    --brand-2: #8b5cf6;
    --brand-3: #00e5ff;
    --radius: 24px;
    --display: "Space Grotesk", system-ui, sans-serif;
    --body: "Inter", system-ui, sans-serif;
    --mono: "JetBrains Mono", ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--body);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }

/* ---------- Tło ---------- */
.bg { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.blob {
    position: absolute; width: 46vmax; height: 46vmax; border-radius: 50%;
    filter: blur(90px); opacity: .35; mix-blend-mode: screen;
    animation: drift 22s ease-in-out infinite alternate;
}
.blob-1 { background: var(--brand-1); top: -18vmax; left: -12vmax; }
.blob-2 { background: var(--brand-2); bottom: -22vmax; right: -14vmax; animation-delay: -7s; }
.blob-3 { background: var(--brand-3); top: 30%; left: 45%; width: 28vmax; height: 28vmax; opacity: .18; animation-delay: -14s; }
@keyframes drift {
    0%   { transform: translate(0, 0) scale(1); }
    50%  { transform: translate(6vmax, 4vmax) scale(1.1); }
    100% { transform: translate(-4vmax, 6vmax) scale(.95); }
}
.grid {
    position: absolute; inset: 0;
    background-image:
        linear-gradient(var(--line) 1px, transparent 1px),
        linear-gradient(90deg, var(--line) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 20%, transparent 75%);
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 20%, transparent 75%);
}
.noise {
    position: absolute; inset: 0; opacity: .06;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Układ ---------- */
.stage {
    position: relative; z-index: 1;
    min-height: 100vh; min-height: 100dvh;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: clamp(36px, 6vh, 64px);
    padding: 48px 20px;
}

.brand { margin: 0; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 10px; animation: rise .9s cubic-bezier(.2, .7, .2, 1) both; }
.brand-logo {
    display: block;
    /* skaluje się z szerokością ekranu, a na niskich ekranach (telefon poziomo) z wysokością */
    width: min(400px, 68vw, 60vh);
    max-width: 100%;
    height: auto;
    aspect-ratio: 275 / 132;
    filter: drop-shadow(0 10px 40px rgba(59, 130, 246, .35));
}
.brand-sub {
    font-family: var(--mono); font-weight: 400; font-size: .8rem;
    text-transform: uppercase; letter-spacing: .32em; color: var(--muted);
}

/* ---------- Panele ---------- */
.panels {
    width: 100%; max-width: 1180px;
    display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 18px;
}
.panel {
    --accent: var(--brand-1);
    --x: 50%; --y: 50%;
    position: relative; isolation: isolate; overflow: hidden;
    min-height: 340px; padding: 26px;
    display: flex; flex-direction: column; justify-content: space-between; gap: 28px;
    border-radius: var(--radius);
    background: var(--glass);
    border: 1px solid var(--line);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    transition: transform .45s cubic-bezier(.2, .7, .2, 1), border-color .3s;
    animation: rise .9s cubic-bezier(.2, .7, .2, 1) both;
    animation-delay: calc(.15s + var(--i, 0) * .09s);
}
/* gradientowa ramka w kolorze akcentu */
.panel::before {
    content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; z-index: -1;
    background: linear-gradient(160deg, color-mix(in srgb, var(--accent) 70%, transparent), transparent 45%);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor; mask-composite: exclude;
    opacity: .5; transition: opacity .3s;
}
/* poświata za kursorem */
.panel-glow {
    position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity .35s;
    background: radial-gradient(420px circle at var(--x) var(--y), color-mix(in srgb, var(--accent) 28%, transparent), transparent 60%);
}
.panel:hover, .panel:focus-visible { transform: translateY(-6px); border-color: transparent; }
.panel:hover::before, .panel:focus-visible::before { opacity: 1; }
.panel:hover .panel-glow, .panel:focus-visible .panel-glow { opacity: 1; }
.panel:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

.panel-top { display: flex; align-items: center; justify-content: space-between; }
.panel-num { font-family: var(--mono); font-size: .8rem; color: var(--muted); letter-spacing: .1em; }
.panel-arrow {
    width: 44px; height: 44px; border-radius: 50%;
    display: grid; place-items: center;
    border: 1px solid var(--line); color: var(--text);
    transition: background .3s, color .3s, transform .45s cubic-bezier(.2, .7, .2, 1), border-color .3s;
}
.panel:hover .panel-arrow { background: var(--accent); border-color: var(--accent); color: #05070d; transform: rotate(45deg); }

.panel-body { display: flex; flex-direction: column; gap: 10px; flex: 1; padding-top: clamp(8px, 4vh, 48px); }
.panel-name {
    font-family: var(--display); font-weight: 700;
    font-size: clamp(2rem, 3.4vw, 2.75rem); line-height: 1; letter-spacing: -.03em;
}
.panel-desc { color: var(--muted); font-size: .98rem; line-height: 1.55; max-width: 32ch; }

.panel-host {
    font-family: var(--mono); font-size: .8rem; color: var(--muted);
    padding-top: 18px; border-top: 1px solid var(--line);
    display: flex; align-items: center; gap: 8px;
}
.panel-host::before {
    content: ""; width: 7px; height: 7px; border-radius: 50%;
    background: var(--accent); box-shadow: 0 0 12px var(--accent);
}

.empty { position: relative; color: var(--muted); font-family: var(--mono); letter-spacing: .2em; text-transform: uppercase; }

@keyframes rise {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: none; }
}

/* ---------- Responsywność ---------- */
@media (max-width: 900px) {
    .panels { grid-template-columns: 1fr; max-width: 520px; }
    .panel { min-height: 0; gap: 22px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
}
