/* kalispro.uk home page: "on air" control room look with real tool logos.
   Loaded only on / and /pl/, after style.css (guides.py copies only the first stylesheet into guide pages). */

/* ---------- light theme: follows the system, the header button can force light or dark ---------- */
:root[data-theme="light"] {
  --bg: #f5f3ff; --bg-2: #ffffff;
  --glass: rgba(255, 255, 255, .62); --glass-2: rgba(255, 255, 255, .95);
  --line: rgba(45, 35, 130, .12); --line-2: rgba(45, 35, 130, .24);
  --text: #17153a; --muted: #57537c;
  --amber: #e68a00; --orange: #ee5a24; --violet: #6150e8; --teal: #0e9f93;
  --top-bg: rgba(245, 243, 255, .8); --shadow: rgba(40, 30, 110, .18); --hub-bg: #17153a;
  color-scheme: light;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f5f3ff; --bg-2: #ffffff;
    --glass: rgba(255, 255, 255, .62); --glass-2: rgba(255, 255, 255, .95);
    --line: rgba(45, 35, 130, .12); --line-2: rgba(45, 35, 130, .24);
    --text: #17153a; --muted: #57537c;
    --amber: #e68a00; --orange: #ee5a24; --violet: #6150e8; --teal: #0e9f93;
    --top-bg: rgba(245, 243, 255, .8); --shadow: rgba(40, 30, 110, .18); --hub-bg: #17153a;
    color-scheme: light;
  }
}
:root { --top-bg: rgba(9, 8, 24, .72); --shadow: rgba(0, 0, 0, .55); --hub-bg: #17153a; color-scheme: dark; }
body { background: var(--bg); }
.top { background: var(--top-bg); }
.glow { box-shadow: 0 40px 90px -45px color-mix(in srgb, var(--a2) 50%, transparent), 0 1px 0 var(--glass-2) inset; }

/* theme button in the header */
.theme-btn { display: inline-grid; place-items: center; width: 2.1rem; height: 2.1rem; padding: 0; border-radius: 50%; border: 1px solid var(--line-2); background: var(--glass); color: var(--text); cursor: pointer; flex: none; }
.theme-btn:hover { background: var(--glass-2); }
.theme-btn svg { width: 1.05rem; height: 1.05rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.theme-btn .sun { display: none; }
:root[data-theme="light"] .theme-btn .sun { display: block; }
:root[data-theme="light"] .theme-btn .moon { display: none; }
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .theme-btn .sun { display: block; }
  :root:not([data-theme="dark"]) .theme-btn .moon { display: none; }
}

/* small round tool logos used inline (nav, flow, notes) */
.mini { width: 1.6rem; height: 1.6rem; border-radius: 50%; object-fit: cover; flex: none; vertical-align: middle; }
.mini.sq { border-radius: 7px; }

/* ---------- hero: copy on the left, the "stage" with the logos on the right ---------- */
.onair { display: grid; grid-template-columns: 1.02fr .98fr; gap: 3rem; align-items: center; padding: 4rem 0 3.5rem; }
.onair h1 { font-size: clamp(2.4rem, 5.4vw, 4.3rem); }
.onair h1 em { font-style: normal; background: linear-gradient(100deg, var(--amber), var(--orange) 45%, var(--violet)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.badge.live i { background: #ff3b5c; box-shadow: 0 0 0 0 rgba(255, 59, 92, .6); animation: livepulse 1.8s infinite; }
.badge.live b { font-weight: 800; letter-spacing: .06em; color: #ff3b5c; }
@keyframes livepulse { 70% { box-shadow: 0 0 0 10px rgba(255, 59, 92, 0); } 100% { box-shadow: 0 0 0 0 rgba(255, 59, 92, 0); } }

.platforms { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; margin: 1.8rem 0 0; padding: 0; list-style: none; }
.platforms li { display: inline-flex; align-items: center; gap: .45rem; font-size: .85rem; font-weight: 600; padding: .3rem .75rem .3rem .3rem; border-radius: 999px; border: 1px solid var(--line); background: var(--glass); color: var(--text); }
.platforms img { width: 1.5rem; height: 1.5rem; border-radius: 7px; }
.platforms li.txt { padding-left: .75rem; color: var(--muted); }

/* the stage: K in the middle, three tools around it, platforms on a slow orbit */
.stage { position: relative; width: min(100%, 480px); aspect-ratio: 1; margin-inline: auto; }
.stage .orbit { position: absolute; inset: 6%; border-radius: 50%; }
.stage .orbit::before { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 1px dashed var(--line-2); animation: spin 120s linear infinite; }
.stage .orbit span { position: absolute; width: 11.4%; aspect-ratio: 1; transform: translate(-50%, -50%); }
.stage .orbit img { display: block; width: 100%; height: 100%; border-radius: 24%; box-shadow: 0 8px 22px -8px var(--shadow); animation: bob 5s ease-in-out infinite; }
.stage .orbit span:nth-child(2) img { animation-delay: -1.2s; }
.stage .orbit span:nth-child(3) img { animation-delay: -2.5s; }
.stage .orbit span:nth-child(4) img { animation-delay: -3.7s; }
@keyframes bob { 50% { transform: translateY(-8px) rotate(-4deg); } }
.stage .ring { position: absolute; inset: 22%; border-radius: 50%; border: 1px solid var(--line); }
.stage .beams { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.stage .beams line { stroke-width: 2; stroke-dasharray: 2 7; stroke-linecap: round; vector-effect: non-scaling-stroke; animation: flow 1.4s linear infinite; }
@keyframes flow { to { stroke-dashoffset: -18; } }
@keyframes spin { to { transform: rotate(360deg); } }

.hub { position: absolute; left: 50%; top: 50%; width: 21%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 26%; background: var(--hub-bg); display: grid; place-items: center; box-shadow: 0 0 0 6px color-mix(in srgb, var(--amber) 18%, transparent), 0 20px 50px -12px var(--shadow); z-index: 2; }
.hub svg { width: 64%; height: 64%; }
.hub::before, .hub::after { content: ""; position: absolute; inset: -6px; border-radius: 30%; border: 2px solid color-mix(in srgb, var(--amber) 55%, transparent); animation: radio 2.8s ease-out infinite; }
.hub::after { animation-delay: 1.4s; }
@keyframes radio { from { transform: scale(1); opacity: .9; } to { transform: scale(1.9); opacity: 0; } }

.node { position: absolute; width: 25%; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: .35rem; text-decoration: none; z-index: 3; transition: transform .25s; }
.node:hover { transform: translate(-50%, -50%) scale(1.06); }
.node .disc { width: 100%; aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 50% 38%, color-mix(in srgb, var(--c1) 45%, var(--bg-2)), color-mix(in srgb, var(--c2) 30%, var(--bg)) 72%); border: 2px solid color-mix(in srgb, var(--c1) 60%, transparent); box-shadow: 0 18px 40px -14px color-mix(in srgb, var(--c1) 70%, transparent); overflow: hidden; }
.node .disc img { width: 100%; height: 100%; object-fit: cover; }
.node.le .disc { border-radius: 28%; background: none; border: 0; }
.node b { font: 700 .82rem/1 var(--body); padding: .32rem .6rem; border-radius: 999px; background: var(--bg-2); border: 1px solid var(--line-2); color: var(--text); white-space: nowrap; }
.node.db { left: 50%; top: 20%; --c1: #ff9a3c; --c2: #ff5e3a; }
.node.dm { left: 23%; top: 67%; --c1: #2fd6c8; --c2: #127a72; }
.node.le { left: 77%; top: 67%; --c1: #8b7bff; --c2: #2fd6c8; }

/* ---------- tool cards with big logos ---------- */
.tools-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: .5rem 2rem; margin-bottom: 4.2rem; }
.tools-head h2 { margin: 0; }
.tools-head p { margin: 0; color: var(--muted); max-width: 28rem; }
.tools { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4.2rem 1.25rem; }
.tool { --a1: var(--c1); --a2: var(--c2); position: relative; display: flex; flex-direction: column; gap: .85rem; padding: 4.6rem 1.7rem 1.6rem; text-decoration: none; border-top: 3px solid var(--c1); transition: transform .25s, border-color .25s; }
.tool:hover { transform: translateY(-5px); }
.tool.db { --c1: #ff9a3c; --c2: #ff5e3a; }
.tool.dm { --c1: #2fd6c8; --c2: #ffb238; }
.tool.le { --c1: #8b7bff; --c2: #2fd6c8; }
.tool .big { position: absolute; top: -3.6rem; left: 1.4rem; width: 7.4rem; height: 7.4rem; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--c1) 55%, var(--bg-2)), color-mix(in srgb, var(--c2) 25%, var(--bg)) 75%); border: 3px solid var(--bg); box-shadow: 0 0 0 2px color-mix(in srgb, var(--c1) 70%, transparent), 0 22px 44px -16px color-mix(in srgb, var(--c1) 80%, transparent); overflow: hidden; }
.tool .big img { width: 100%; height: 100%; object-fit: cover; }
.tool.le .big { border-radius: 30%; background: none; border: 0; box-shadow: 0 22px 44px -16px color-mix(in srgb, var(--c1) 80%, transparent); }
.tool .kind { position: absolute; top: 1.1rem; right: 1.3rem; font: 700 .72rem/1 var(--body); letter-spacing: .08em; text-transform: uppercase; padding: .38rem .6rem; border-radius: 999px; color: var(--text); background: color-mix(in srgb, var(--c1) 18%, transparent); border: 1px solid color-mix(in srgb, var(--c1) 45%, transparent); }
.tool h2 { margin: 0; font-size: 2rem; }
.tool > p { margin: 0; color: var(--muted); }
.tool ul { margin: 0; padding: 0; list-style: none; display: grid; gap: .5rem; }
.tool li { position: relative; padding-left: 1.6rem; font-size: .97rem; }
.tool li::before { content: ""; position: absolute; left: 0; top: .3em; width: 1rem; height: 1rem; border-radius: 50%; background: linear-gradient(135deg, var(--c1), var(--c2)); -webkit-mask: radial-gradient(circle at 50% 50%, transparent 0 .22rem, #000 .24rem); mask: radial-gradient(circle at 50% 50%, transparent 0 .22rem, #000 .24rem); }
.tool .foot { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .8rem; }
.tool .with { display: flex; align-items: center; gap: .35rem; font-size: .78rem; color: var(--muted); }
.tool .with img { width: 1.55rem; height: 1.55rem; border-radius: 7px; }
.tool .with .t { font-weight: 700; font-size: .72rem; padding: .3rem .45rem; border: 1px solid var(--line-2); border-radius: 7px; color: var(--text); }
.tool .go { font-weight: 700; display: inline-flex; align-items: center; gap: .35rem; color: var(--text); }
.tool .go svg { width: 1rem; height: 1rem; fill: none; stroke: var(--c1); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; transition: transform .2s; }
.tool:hover .go svg { transform: translateX(4px); }
.tool .ver { font: 600 .75rem var(--mono); color: var(--muted); }

/* ---------- @nick page: text and a real phone screenshot ---------- */
.nick { display: grid; grid-template-columns: 1.15fr .85fr; gap: 3rem; align-items: center; }
.nick .head { margin-bottom: 1.6rem; }
.nick .head h2 code { font: inherit; background: linear-gradient(100deg, var(--amber), var(--violet)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.for { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin: 0 0 1.6rem; color: var(--muted); font-size: .95rem; }
.for span { display: inline-flex; align-items: center; gap: .4rem; padding: .25rem .65rem .25rem .25rem; border-radius: 999px; border: 1px solid var(--line); background: var(--glass); color: var(--text); font-weight: 600; }
.perks { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; margin: 0 0 1.6rem; padding: 0; list-style: none; }
.perks li { padding: 1rem 1.1rem; border-radius: 16px; border: 1px solid var(--line); background: var(--glass); }
.perks strong { display: flex; align-items: center; gap: .5rem; font-size: 1rem; margin-bottom: .25rem; }
.perks strong::before { content: ""; width: .55rem; height: .55rem; border-radius: 50%; background: var(--grad); flex: none; }
.perks span { display: block; color: var(--muted); font-size: .93rem; line-height: 1.5; }
.phone { justify-self: center; width: min(100%, 300px); aspect-ratio: 9 / 17; border-radius: 2.4rem; padding: .7rem; background: linear-gradient(160deg, #2a2752, #0d0c20); box-shadow: 0 0 0 1px var(--line-2), 0 50px 90px -40px var(--shadow), 0 30px 80px -30px color-mix(in srgb, var(--violet) 55%, transparent); transform: rotate(2.5deg); }
.phone img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 1.8rem; }

/* ---------- the stream, step by step, with the logos of the tools at work ---------- */
.flow { position: relative; margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.flow::before { content: ""; position: absolute; left: 8%; right: 8%; top: 2.05rem; height: 2px; background: linear-gradient(90deg, var(--amber), #ff3b5c 50%, var(--violet)); opacity: .55; }
.flow li { position: relative; padding: 0 .4rem; }
.flow .who { position: relative; display: flex; gap: .4rem; padding: .4rem; width: max-content; border-radius: 999px; background: var(--bg-2); border: 1px solid var(--line-2); margin-bottom: 1.1rem; box-shadow: 0 12px 30px -16px var(--shadow); }
.flow .who img { width: 3.2rem; height: 3.2rem; border-radius: 50%; object-fit: cover; }
.flow .who img.sq { border-radius: 26%; }
.flow .phase { display: inline-block; font: 800 .72rem/1 var(--body); letter-spacing: .1em; text-transform: uppercase; padding: .35rem .6rem; border-radius: 6px; margin-bottom: .6rem; color: #fff; background: var(--amber); }
.flow li:nth-child(2) .phase { background: #ff3b5c; }
.flow li:nth-child(3) .phase { background: var(--violet); }
.flow p { margin: 0; color: var(--muted); }

/* ---------- guides: a logo of the tool in front of each guide (from the link address, so guides.py can keep adding cards) ---------- */
#poradniki .guide-list a { position: relative; padding-left: 4.3rem; }
#poradniki .guide-list a::before { content: ""; position: absolute; left: 1rem; top: 1.1rem; width: 2.5rem; height: 2.5rem; border-radius: 50%; background: var(--hub-bg) center / cover no-repeat; box-shadow: 0 6px 16px -8px var(--shadow); }
#poradniki .guide-list a[href*="dogbyte.kalispro.uk"]::before { background-image: url(/dogbyte-logo.png); background-color: #ff8a3c; }
#poradniki .guide-list a[href*="dogmate.kalispro.uk"]::before { background-image: url(/dogmate-logo.png); background-color: #fff; }
#poradniki .guide-list a[href*="liveecho.kalispro.uk"]::before { background-image: url(/liveecho-logo.png); border-radius: 26%; }
#poradniki .guide-list a[href^="/"]::before { background-image: url(/favicon.svg); border-radius: 26%; }

/* ---------- about and support ---------- */
.about-me { display: flex; align-items: center; gap: .8rem; }
.about-me svg { width: 2.6rem; height: 2.6rem; flex: none; }
.socials { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .4rem; }
.socials a { display: inline-flex; align-items: center; gap: .45rem; padding: .3rem .75rem .3rem .3rem; border-radius: 999px; border: 1px solid var(--line-2); text-decoration: none; font-weight: 600; font-size: .9rem; }
.socials a:hover { background: var(--glass-2); }
.socials img { width: 1.5rem; height: 1.5rem; border-radius: 7px; }
.cta .coffee { display: flex; align-items: center; gap: 1rem; }
.cta .coffee img { width: 3.6rem; height: 3.6rem; border-radius: 16px; flex: none; transform: rotate(-6deg); box-shadow: 0 14px 30px -12px rgba(255, 200, 0, .6); }

/* ---------- smaller screens ---------- */
@media (max-width: 1100px) {
  .tools { grid-template-columns: 1fr 1fr; }
  .tools .tool:last-child { grid-column: 1 / -1; }
}
@media (max-width: 900px) {
  .onair { grid-template-columns: 1fr; gap: 2rem; padding: 2.2rem 0 2.5rem; }
  .stage { width: min(100%, 380px); }
  .tools { grid-template-columns: 1fr; }
  .tools .tool:last-child { grid-column: auto; }
  .nick { grid-template-columns: 1fr; gap: 2.5rem; }
  .flow { grid-template-columns: 1fr; gap: 1.6rem; }
  .flow::before { left: 2.05rem; right: auto; top: 2rem; bottom: 2rem; width: 2px; height: auto; background: linear-gradient(180deg, var(--amber), #ff3b5c 50%, var(--violet)); }
  .flow li { display: grid; grid-template-columns: auto 1fr; column-gap: 1rem; padding: 0; }
  .flow .who { grid-row: span 2; flex-direction: column; margin: 0; align-self: start; }
  .flow .phase { justify-self: start; }
}
@media (max-width: 560px) {
  .perks { grid-template-columns: 1fr; }
  .tool { padding: 4.4rem 1.25rem 1.3rem; }
  .tool .big { width: 6.6rem; height: 6.6rem; top: -3.2rem; left: 1.1rem; }
  .node b { font-size: .72rem; padding: .26rem .5rem; }
  .cta .coffee { align-items: flex-start; }
  .cta .coffee img { width: 3rem; height: 3rem; }
  #poradniki .guide-list { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .stage .orbit::before, .stage .orbit img, .stage .beams line, .hub::before, .hub::after, .badge.live i { animation: none; }
  .tool, .node { transition: none; }
}
