/* Презентации проектов — тёмное стекло, крупная типографика */
html.pz-lock { overflow: hidden; }
.pz { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 16px; --pc: #7c5cff; --pc-t: color-mix(in srgb, var(--pc) 70%, #fff); --pc-s: color-mix(in srgb, var(--pc) 14%, transparent); --pc-l: color-mix(in srgb, var(--pc) 38%, transparent); }
.pz[hidden] { display: none; }
.pz-scrim { position: absolute; inset: 0; background: rgba(4, 4, 6, 0.55); backdrop-filter: blur(18px) saturate(120%); opacity: 0; transition: opacity .5s var(--ease); }
.pz-dialog {
  position: relative; display: flex; flex-direction: column; width: min(1180px, 100%); height: min(760px, calc(100svh - 32px));
  border: 1px solid rgba(255,255,255,0.12); border-radius: 26px; background: rgba(11, 11, 14, 0.82); backdrop-filter: blur(24px);
  box-shadow: 0 60px 140px -40px rgba(0,0,0,0.8); overflow: hidden;
  opacity: 0; transform: translateY(30px) scale(0.975); transition: opacity .55s var(--ease), transform .7s var(--ease);
}
.pz.open .pz-scrim { opacity: 1; }
.pz.open .pz-dialog { opacity: 1; transform: none; }
.pz.out .pz-dialog { opacity: 0; transform: translateY(16px) scale(0.985); transition-duration: .35s; }
.pz.swap .pz-view, .pz.swap .pz-top { opacity: 0; transform: translateY(8px); }
.pz-view, .pz-top { transition: opacity .25s ease, transform .3s ease; }
.pz-glow { position: absolute; inset: 0; pointer-events: none; background: radial-gradient(700px 380px at 90% -10%, color-mix(in srgb, var(--pc) 26%, transparent), transparent 70%), radial-gradient(500px 300px at -5% 110%, color-mix(in srgb, var(--pc) 12%, transparent), transparent 70%); transition: background .6s; }

.pz-top { position: relative; z-index: 2; display: flex; align-items: center; gap: 14px; padding: 18px 24px; border-bottom: 1px solid rgba(255,255,255,0.07); }
.pz-num { font-family: var(--mono); font-size: 12px; padding: 3px 8px; border-radius: 7px; background: var(--pc-s); color: var(--pc-t); }
.pz-title { flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-weight: 600; letter-spacing: -0.01em; }
.pz-count { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.pz-x { width: 36px; height: 36px; border-radius: 50%; border: 1px solid rgba(255,255,255,0.14); background: none; cursor: pointer; color: var(--muted); transition: color .2s, border-color .2s, transform .4s var(--ease); }
.pz-x:hover { color: #fff; border-color: rgba(255,255,255,0.35); transform: rotate(90deg); }

.pz-view { position: relative; z-index: 1; flex: 1; min-height: 0; overflow: hidden; }
.pz-track { display: flex; height: 100%; transition: transform .8s var(--ease); will-change: transform; }
.pz-slide { flex: 0 0 100%; min-width: 0; height: 100%; overflow-x: hidden; overflow-y: auto; padding: 38px clamp(22px, 4vw, 56px) 28px; display: flex; flex-direction: column; }
.pz-slide.on .a { animation: pzIn .9s var(--ease) both; animation-delay: calc(var(--i, 0) * 80ms + 180ms); }
@keyframes pzIn { from { opacity: 0; transform: translateY(20px); filter: blur(8px); } }

.pz-kick { font-family: var(--mono); font-size: 12px; letter-spacing: 0.03em; text-transform: uppercase; color: var(--pc-t); }
.pz-h1 { margin: 16px 0 0; font-family: var(--display); font-weight: 700; font-size: clamp(48px, 7.4vw, 112px); line-height: 0.88; letter-spacing: -0.055em; background: linear-gradient(180deg, #fff 35%, #8f95a0); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pz-h2 { margin: 10px 0 0; font-family: var(--display); font-weight: 600; font-size: clamp(30px, 3.6vw, 52px); line-height: 1; letter-spacing: -0.045em; background: linear-gradient(180deg, #fff 35%, #a1a6b0); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pz-lead { margin: 22px 0 0; max-width: 620px; font-size: 18px; line-height: 1.6; color: #c3c6cd; }
.pz-shead { margin-bottom: 30px; }

/* обзор */
.pz-cover { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 40px; }
.pz-orb { position: relative; width: clamp(180px, 20vw, 260px); aspect-ratio: 1; display: grid; place-items: center; }
.pz-orb i { position: absolute; inset: 0; border-radius: 50%; border: 1px solid var(--pc-l); animation: pzSpin 24s linear infinite; }
.pz-orb i:nth-child(2) { inset: 16%; border-style: dashed; animation-duration: 15s; animation-direction: reverse; }
.pz-orb i::after { content: ''; position: absolute; top: -4px; left: calc(50% - 4px); width: 8px; height: 8px; border-radius: 50%; background: var(--pc); box-shadow: 0 0 14px var(--pc); }
.pz-orb span { position: relative; display: grid; place-items: center; width: 42%; aspect-ratio: 1; border-radius: 30%; font-size: clamp(40px, 4.4vw, 60px); line-height: 1; background: linear-gradient(145deg, color-mix(in srgb, var(--pc) 32%, #111), color-mix(in srgb, var(--pc) 8%, #0b0b0e)); border: 1px solid var(--pc-l); box-shadow: 0 0 70px -10px color-mix(in srgb, var(--pc) 70%, transparent); }
.pz-orb .ae { width: 62%; height: 62%; }
@keyframes pzSpin { to { transform: rotate(360deg); } }
.pz-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin-top: 30px; border-top: 1px solid rgba(255,255,255,0.1); }
.pz-stats div { padding: 18px 18px 0 0; }
.pz-stats b { display: block; font-family: var(--display); font-weight: 600; font-size: clamp(30px, 3.4vw, 48px); letter-spacing: -0.05em; line-height: 1; background: linear-gradient(120deg, #fff 30%, var(--pc)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pz-stats span { display: block; margin-top: 8px; font-size: 13px; color: var(--muted); }

/* возможности */
.pz-feats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 28px; }
.pz-feats.wide { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pz-feats > div { position: relative; padding: 18px 0 22px; border-top: 1px solid rgba(255,255,255,0.1); }
.pz-feats > div::before { content: ''; position: absolute; left: 0; top: -1px; width: 0; height: 1px; background: var(--pc); transition: width .6s var(--ease); }
.pz-feats > div:hover::before { width: 100%; }
.pz-idx { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.pz-fi { float: right; font-size: 20px; opacity: 0.85; }
.pz-feats h4 { margin: 14px 0 6px; font-family: var(--display); font-weight: 600; font-size: 21px; letter-spacing: -0.03em; }
.pz-feats p { margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--muted); }

/* процесс */
.pz-flow { flex: 1; display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); gap: 22px; margin: 0; padding: 0; list-style: none; align-content: center; }
.pz-flow li { position: relative; padding-top: 18px; border-top: 1px solid rgba(255,255,255,0.12); }
.pz-flow li::before { content: ''; position: absolute; left: 0; top: -1px; height: 1px; width: 0; background: linear-gradient(90deg, var(--pc), transparent); }
.pz-slide.on .pz-flow li::before { animation: pzLine 1s var(--ease) forwards; animation-delay: calc(var(--i) * 120ms + 300ms); }
@keyframes pzLine { to { width: 100%; } }
.pz-big { display: block; font-family: var(--display); font-weight: 700; font-size: clamp(48px, 5.4vw, 84px); line-height: 1; letter-spacing: -0.06em; color: transparent; -webkit-text-stroke: 1px var(--pc-l); transition: color .4s; }
.pz-flow li:hover .pz-big { color: var(--pc-s); -webkit-text-stroke-color: var(--pc); }
.pz-flow h4 { margin: 16px 0 6px; font-family: var(--display); font-weight: 600; font-size: 20px; letter-spacing: -0.03em; }
.pz-flow p { margin: 0; font-size: 14px; line-height: 1.6; color: var(--muted); }

/* интерфейс */
.pz-chat { flex: 1 0 auto; display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 380px); gap: 48px; }
.pz-chat-info { align-self: center; }
.pz-points { margin: 24px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.pz-points li { display: flex; gap: 12px; font-size: 15px; color: #d2d5db; }
.pz-points li::before { content: '→'; color: var(--pc-t); }
/* макет чата: по высоте содержимого — сообщения видны целиком (не влезает в экран — крутится слайд); текст не выделяется */
.tg { --tg-bg: #0e1621; --tg-head: #17212b; --tg-in: #182533; --tg-out: #2b5278; --tg-text: #f1f5f9; --tg-sub: #7f91a4; --tg-btn: rgba(35, 52, 70, 0.92); --tg-link: #6ab3f3; display: flex; flex-direction: column; align-self: center; border: 1px solid rgba(255,255,255,0.1); border-radius: 22px; background: var(--tg-bg); overflow: hidden; box-shadow: 0 30px 80px -30px color-mix(in srgb, var(--pc) 45%, #000); user-select: none; -webkit-user-select: none; }
.tg-head { display: flex; align-items: center; gap: 10px; padding: 11px 14px; background: var(--tg-head); }
.tg-ava { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--pc), color-mix(in srgb, var(--pc) 45%, #000)); font-size: 17px; }
.tg-ava .ae { width: 24px; height: 24px; }
.tg-name { color: var(--tg-text); font-size: 14px; font-weight: 600; line-height: 1.3; }
.tg-sub { color: var(--tg-sub); font-size: 12px; line-height: 1.3; }
.tg-body { display: flex; flex-direction: column; gap: 6px; padding: 14px 10px 12px; background-image: radial-gradient(rgba(241,245,249,0.06) 1px, transparent 1.5px); background-size: 18px 18px; }
.msg { display: flex; flex-direction: column; gap: 4px; max-width: 88%; }
.msg.user { align-self: flex-end; }
.pz-slide.on .msg { animation: pzMsg .5s var(--ease) both; animation-delay: calc(var(--m) * 380ms + 400ms); }
@keyframes pzMsg { from { opacity: 0; transform: translateY(10px) scale(0.97); } }
.bubble { padding: 7px 11px 6px; border-radius: 14px 14px 14px 5px; background: var(--tg-in); color: var(--tg-text); font-size: 13px; line-height: 1.45; overflow-wrap: anywhere; }
.msg.user .bubble { border-radius: 14px 14px 5px 14px; background: var(--tg-out); }
.bubble b { font-weight: 600; }
.bubble code { color: var(--tg-link); font-family: var(--mono); font-size: 12px; }
.bubble .mention { color: var(--tg-link); font-weight: 500; }
.bubble blockquote { margin: 5px 0; padding: 3px 8px; border-left: 3px solid var(--tg-link); border-radius: 4px; background: rgba(106,179,243,0.12); }
.bubble time { float: right; position: relative; top: 5px; margin-left: 10px; color: var(--tg-sub); font-size: 10.5px; }
.bubble.media { padding: 4px 4px 6px; }
.banner { display: flex; align-items: center; justify-content: center; gap: 16px; width: 250px; max-width: 100%; aspect-ratio: 1920 / 530; border-radius: 11px; background: #000; font-size: 26px; }
.banner span { animation: pzBob 1.6s ease-in-out infinite; animation-delay: calc(var(--k) * 0.18s); }
@keyframes pzBob { 50% { transform: translateY(-4px) scale(1.12); } }
.banner-cap { padding: 5px 7px 0; color: var(--tg-sub); font-size: 11.5px; }
.kb { display: grid; gap: 4px; }
.kb-row { display: flex; gap: 4px; }
.kb-btn { flex: 1; min-width: 0; padding: 7px 8px; border-radius: 8px; background: var(--tg-btn); color: #fff; font-size: 12.5px; font-weight: 500; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kb-btn.primary { background: #3a86e8; }
.kb-btn.success { background: #2fa565; }
.kb-btn.danger { background: #e0484d; }
.ae { display: inline-block; width: 1.35em; height: 1.35em; vertical-align: -0.32em; object-fit: contain; }
.kb-btn .ae { width: 1.3em; height: 1.3em; margin-right: 0.15em; }

/* технологии */
.pz-stackgrid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 36px; align-items: start; }
.code-win { border: 1px solid rgba(255,255,255,0.1); border-radius: 16px; background: rgba(255,255,255,0.025); overflow: hidden; }
.code-bar { display: flex; align-items: center; gap: 6px; padding: 11px 14px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.code-bar i { width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,0.16); }
.code-bar i:first-child { background: var(--pc); }
.code-bar span { margin-left: 8px; font-family: var(--mono); font-size: 12px; color: var(--muted); }
.tree { display: grid; grid-template-columns: max-content minmax(0, 1fr); column-gap: 20px; padding: 14px 18px 16px; font-family: var(--mono); font-size: 12.8px; line-height: 1.95; overflow-x: auto; }
.tree-row { display: contents; }
.tree-row > span:first-child { white-space: pre; }
.tree-pre { color: var(--faint); }
.tree-name.dir { color: var(--pc-t); font-weight: 500; }
.tree-c { color: var(--muted); }
.tree-c:not(:empty)::before { content: '# '; opacity: 0.6; }
.layers { display: grid; gap: 6px; padding: 18px; }
.layer { display: flex; gap: 8px; }
.layer div { flex: 1; padding: 11px 8px; border: 1px solid rgba(255,255,255,0.1); border-radius: 10px; font-size: 13px; font-weight: 600; text-align: center; }
.layer:first-child div { border-color: var(--pc-l); background: var(--pc-s); color: var(--pc-t); }
.layer-arrow { text-align: center; color: var(--pc-t); }
.pz-sub { margin: 0 0 12px; font-family: var(--mono); font-size: 11.5px; text-transform: uppercase; color: var(--muted); }
.pz-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 26px; }
.pz-chips span { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--pc-l); background: var(--pc-s); color: var(--pc-t); font-size: 12.5px; }
.pz-notes { margin: 0; padding: 0; list-style: none; display: grid; gap: 14px; }
.pz-notes li { position: relative; padding-left: 20px; font-size: 14.5px; line-height: 1.6; color: #c3c6cd; }
.pz-notes li::before { content: ''; position: absolute; left: 2px; top: 0.62em; width: 7px; height: 7px; border-radius: 2px; background: var(--pc); transform: rotate(45deg); }

/* навигация */
.pz-nav { position: relative; z-index: 2; display: flex; align-items: center; gap: 16px; padding: 16px 24px 18px; border-top: 1px solid rgba(255,255,255,0.07); }
.pz-btn { height: 44px; min-width: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid rgba(255,255,255,0.14); background: rgba(255,255,255,0.03); color: var(--fg); font: 600 14px 'Inter', sans-serif; cursor: pointer; transition: border-color .2s, background-color .2s, opacity .2s, transform .3s var(--ease); }
.pz-btn:hover:not(:disabled) { border-color: rgba(255,255,255,0.35); transform: translateY(-1px); }
.pz-btn:disabled { opacity: 0.3; cursor: default; }
.pz-next { background: var(--pc); border-color: transparent; color: #0a0a0a; }
.pz-mid { flex: 1; display: grid; gap: 8px; justify-items: center; }
.pz-bars { display: flex; gap: 6px; width: min(360px, 100%); }
.pz-bars button { flex: 1; height: 14px; padding: 0; border: 0; background: none; cursor: pointer; display: flex; align-items: center; }
.pz-bars button::before { content: ''; width: 100%; height: 3px; border-radius: 3px; background-color: rgba(255,255,255,0.12); background-image: linear-gradient(var(--pc), var(--pc)); background-repeat: no-repeat; background-size: 0% 100%; transition: background-size .5s var(--ease); }
.pz-bars button.on::before, .pz-bars button.done::before { background-size: 100% 100%; }
.pz-label { font-family: var(--mono); font-size: 11.5px; text-transform: uppercase; color: var(--muted); }

@media (max-width: 860px) {
  .pz { padding: 0; }
  .pz-dialog { height: 100svh; border-radius: 0; border: 0; }
  .pz-slide { padding: 26px 18px 20px; }
  .pz-cover { grid-template-columns: minmax(0, 1fr); gap: 10px; flex: 0 0 auto; }
  .pz-orb { order: -1; width: 150px; }
  .pz-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pz-feats, .pz-feats.wide { grid-template-columns: minmax(0, 1fr); }
  .pz-flow { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .pz-chat { grid-template-columns: minmax(0, 1fr); gap: 24px; flex: 0 0 auto; }
  .pz-stackgrid { grid-template-columns: minmax(0, 1fr); }
  .tree { font-size: 11.5px; column-gap: 12px; }
  .pz-next span { display: none; }
}
@media (prefers-reduced-motion: reduce) { .pz-slide.on .a, .pz-slide.on .msg { animation: none; } .pz-orb i { animation: none; } }
