/* =====================================================================
   Тема „3D принтиране" — maker / blueprint.
   Dark background with a blueprint grid, neon lime + filament orange,
   Unbounded + Rubik + JetBrains Mono, an animated CSS 3D printer.
   ===================================================================== */
html[data-theme="print3d"] {
  color-scheme: dark;
  --bg: #0d1014;
  --bg-alt: #11161c;
  --surface: #141920;
  --surface-2: #1b222c;
  --line: #263040;
  --input-bg: #0f141a;
  --text: #e6edf3;
  --muted: #9aa7b4;
  --faint: #6b7785;
  --accent: #b8f04a;
  --accent-strong: #c8ff5a;
  --accent-soft: rgba(184, 240, 74, 0.12);
  --on-accent: #0d1014;
  --accent-2: #ff7a1a;
  --on-accent-2: #0d1014;
  --price: #c8ff5a;
  --success: #7ddc4a;
  --danger: #ff6464;
  --warning: #ffb02e;
  --grad-accent: linear-gradient(90deg, #b8f04a, #ff7a1a);
  --glow: linear-gradient(rgba(184, 240, 74, 0.045) 1px, transparent 1px) 0 0 / 40px 40px, linear-gradient(90deg, rgba(184, 240, 74, 0.045) 1px, transparent 1px) 0 0 / 40px 40px;
  --header-bg: rgba(13, 16, 20, 0.88);
  --header-text: #e6edf3;
  --header-line: #263040;
  --nav-text: #9aa7b4;
  --nav-hover: #c8ff5a;
  --topbar-bg: #b8f04a;
  --topbar-text: #0d1014;
  --footer-bg: #090b0e;
  --footer-text: #e6edf3;
  --footer-muted: #8592a0;
  --footer-line: #1e2632;
  --radius: 10px;
  --radius-sm: 6px;
  --radius-btn: 6px;
  --shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.75);
  --shadow-accent: 0 0 0 1px rgba(184, 240, 74, 0.45), 0 12px 30px -12px rgba(184, 240, 74, 0.5);
  --font-display: 'Unbounded', system-ui, sans-serif;
  --font-body: 'Rubik', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
  --h-weight: 600;
  --h-tracking: -0.02em;
  --h-line: 1.12;
  --btn-transform: uppercase;
  --btn-tracking: 0.08em;
  --btn-weight: 600;
  --btn-size: 0.78rem;
  --btn-pad: 1.05em 1.6em;
  --eyebrow-color: #b8f04a;
  --eyebrow-tracking: 0.04em;
  --card-ratio: 1 / 1;
  --container: 1260px;
  --header-h: 70px;
}
html[data-theme="print3d"] .topbar { font-family: var(--font-mono); font-size: 0.74rem; font-weight: 600; }
html[data-theme="print3d"] .eyebrow { font-family: var(--font-mono); text-transform: none; font-weight: 500; font-size: 0.8rem; }
html[data-theme="print3d"] .eyebrow::before { content: '// '; opacity: 0.6; }
html[data-theme="print3d"] .btn { font-family: var(--font-mono); }
html[data-theme="print3d"] .btn-primary:hover { box-shadow: var(--shadow-accent); background: var(--accent-strong); }
html[data-theme="print3d"] .btn-ghost { border-color: #344156; }
html[data-theme="print3d"] .brand .logo { font-size: 1.25rem; font-weight: 700; letter-spacing: -0.02em; display: inline-flex; align-items: center; gap: 0.55rem; }
html[data-theme="print3d"] .brand .logo::before { content: ''; width: 1.15em; height: 1.15em; background: conic-gradient(from 30deg, #c8ff5a 0 120deg, #7aa82a 0 240deg, #a5dc3f 0); clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); flex: 0 0 auto; }
html[data-theme="print3d"] .brand .tag { font-family: var(--font-mono); letter-spacing: 0; text-transform: none; font-size: 0.7rem; }
@media (min-width: 961px) {
  html[data-theme="print3d"] .nav-links { gap: 0.9rem; }
  html[data-theme="print3d"] .nav-links > li > a { font-family: var(--font-mono); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.06em; }
  html[data-theme="print3d"] .nav-links > li + li::before { content: '/'; color: #344156; margin-right: 0.9rem; }
  html[data-theme="print3d"] .nav-links > li > a.active { color: var(--accent); }
}
html[data-theme="print3d"] .header-search input { font-family: var(--font-mono); font-size: 0.8rem; width: 190px; border-radius: 6px; }
html[data-theme="print3d"] .hdr-link, html[data-theme="print3d"] .cart-btn { font-family: var(--font-mono); font-size: 0.76rem; text-transform: uppercase; }

/* ---------- cards ---------- */
html[data-theme="print3d"] .pcard:hover { border-color: var(--accent); box-shadow: var(--shadow-accent); transform: translateY(-3px); }
html[data-theme="print3d"] .pcard-cat { font-family: var(--font-mono); text-transform: none; letter-spacing: 0; color: var(--faint); }
html[data-theme="print3d"] .pcard-cat::before { content: '# '; color: var(--accent); }
html[data-theme="print3d"] .pcard-title { font-family: var(--font-body); font-weight: 500; font-size: 1.02rem; }
html[data-theme="print3d"] .pcard-specs { display: flex; }
html[data-theme="print3d"] .chip { background: transparent; border-color: #344156; color: var(--accent); }
html[data-theme="print3d"] .pcard-short { color: var(--faint); }
html[data-theme="print3d"] .pcard-price .now { font-family: var(--font-mono); font-weight: 600; }
html[data-theme="print3d"] .badge { font-family: var(--font-mono); border-radius: 4px; letter-spacing: 0.02em; }
html[data-theme="print3d"] .badge.out { background: #1b222c; }
html[data-theme="print3d"] .stars { color: var(--accent-2); }
html[data-theme="print3d"] .stars .off { color: #344156; }

/* ---------- home ---------- */
.px-hero { padding: clamp(2.4rem, 6vw, 5rem) 0 clamp(2rem, 4vw, 3rem); position: relative; z-index: 1; }
.px-hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.px-code { display: inline-block; font-family: var(--font-mono); font-size: 0.82rem; color: var(--accent); border: 1px solid #2e3a4d; background: rgba(184, 240, 74, 0.06); padding: 0.35em 0.75em; border-radius: 4px; margin-bottom: 1.2rem; }
.px-hero h1 { font-size: clamp(2.3rem, 4.6vw, 4.2rem); line-height: 1.06; margin-bottom: 1.1rem; }
.px-hero p { color: var(--muted); font-size: 1.08rem; max-width: 33rem; margin-bottom: 1.8rem; }
.px-cta { display: flex; gap: 0.7rem; flex-wrap: wrap; margin-bottom: 1.8rem; }
.px-materials .features { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.px-materials .feature { display: inline-flex; align-items: baseline; gap: 0.45rem; padding: 0.45rem 0.8rem; border: 1px solid #2e3a4d; border-radius: 6px; text-align: left; background: rgba(20, 25, 32, 0.8); }
.px-materials .fv { font-family: var(--font-mono); font-size: 0.86rem; color: var(--accent); }
.px-materials .fl { font-size: 0.78rem; }
.px-materials .fi { display: none; }
@media (max-width: 900px) { .px-hero-grid { grid-template-columns: 1fr; } }

/* animated printer */
.px-printer { position: relative; width: min(470px, 100%); aspect-ratio: 1; justify-self: center; }
.pp-frame { position: absolute; left: 10%; right: 10%; top: 4%; bottom: 14%; border: 4px solid #2b3647; border-bottom: 0; border-radius: 14px 14px 0 0; background: linear-gradient(180deg, rgba(27, 34, 44, 0.6), rgba(13, 16, 20, 0.2)); }
.pp-frame::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 12%; background: #1b222c; border-bottom: 2px solid #2b3647; }
.pp-frame::after { content: ''; position: absolute; left: 8px; top: 3.5%; width: 34px; height: 5px; border-radius: 3px; background: var(--accent); box-shadow: 0 0 10px var(--accent); animation: ppblink 1.6s steps(2) infinite; }
.pp-gantry { position: absolute; left: 10%; right: 10%; height: 0; top: 71%; animation: ppgantry 9s steps(16) infinite; }
.pp-rail { position: absolute; left: -3%; right: -3%; top: -4px; height: 8px; border-radius: 4px; background: #3a475c; }
.pp-head { position: absolute; top: -26px; left: 18%; width: 54px; height: 36px; border-radius: 6px; background: #ff7a1a; box-shadow: inset 0 -6px 0 rgba(0, 0, 0, 0.25); animation: pphead 0.9s ease-in-out infinite alternate; }
.pp-head::after { content: ''; position: absolute; left: 50%; bottom: -12px; transform: translateX(-50%); border: 8px solid transparent; border-top: 12px solid #c9ced6; border-bottom: 0; }
.pp-head::before { content: ''; position: absolute; left: 50%; bottom: -15px; width: 6px; height: 6px; margin-left: -3px; border-radius: 50%; background: #c8ff5a; box-shadow: 0 0 10px 3px rgba(200, 255, 90, 0.8); }
.pp-print { position: absolute; left: 30%; right: 30%; bottom: 14%; top: 22%; clip-path: inset(100% 0 0 0); animation: ppbuild 9s steps(16) infinite; }
.pp-vase { position: absolute; inset: 0; clip-path: polygon(30% 100%, 70% 100%, 80% 74%, 64% 46%, 70% 18%, 78% 0, 22% 0, 30% 18%, 36% 46%, 20% 74%); background: repeating-linear-gradient(0deg, #b8f04a 0 7px, #8fc236 7px 9px); filter: drop-shadow(0 0 18px rgba(184, 240, 74, 0.35)); }
.pp-bed { position: absolute; left: 14%; right: 14%; bottom: 10%; height: 4%; border-radius: 4px; background: #2b3647; box-shadow: 0 -2px 0 rgba(184, 240, 74, 0.6), 0 8px 24px -6px rgba(184, 240, 74, 0.35); }
.pp-readout { position: absolute; left: 10%; right: 10%; bottom: 0; display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: 0.74rem; color: var(--muted); }
.pp-readout b { color: var(--accent); font-weight: 600; }
.pp-readout .cur::after { content: '▌'; color: var(--accent); animation: ppblink 1s steps(2) infinite; margin-left: 0.2rem; }
@keyframes ppbuild { 0% { clip-path: inset(100% 0 0 0); } 85%, 100% { clip-path: inset(0 0 0 0); } }
@keyframes ppgantry { 0% { top: 71%; } 85%, 100% { top: 19%; } }
@keyframes pphead { from { left: 12%; } to { left: calc(88% - 54px); } }
@keyframes ppblink { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .pp-print { animation: none; clip-path: none; }
  .pp-gantry { animation: none; top: 19%; }
  .pp-head, .pp-frame::after, .pp-readout .cur::after { animation: none; }
}

.px-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; counter-reset: s; }
.px-steps .step-card { position: relative; border: 1px dashed #344156; border-radius: 10px; padding: 1.5rem 1.4rem; background: rgba(20, 25, 32, 0.7); }
.px-steps .step-no { font-family: var(--font-mono); font-size: 2.2rem; font-weight: 600; color: var(--accent); line-height: 1; display: block; margin-bottom: 0.9rem; }
.px-steps h3 { font-size: 1.02rem; margin-bottom: 0.45rem; }
.px-steps p { color: var(--muted); font-size: 0.92rem; margin: 0; }
.px-steps .step-card + .step-card::before { content: '→'; position: absolute; left: -0.95rem; top: 50%; transform: translateY(-50%); font-family: var(--font-mono); color: var(--accent); background: var(--bg); padding: 0.2rem 0; }
@media (max-width: 800px) { .px-steps { grid-template-columns: 1fr; } .px-steps .step-card + .step-card::before { display: none; } }

.px-banner { padding: 1rem 0 2.5rem; position: relative; z-index: 1; }
.px-banner-inner { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 2rem; align-items: center; border: 1px dashed var(--accent); border-radius: 14px; padding: clamp(1.6rem, 4vw, 2.8rem); background: linear-gradient(135deg, rgba(184, 240, 74, 0.08), rgba(255, 122, 26, 0.06)); }
.px-banner-inner h2 { font-size: clamp(1.5rem, 3vw, 2.3rem); margin: 0.2rem 0 0.6rem; }
.px-banner-inner p { color: var(--muted); margin-bottom: 1.4rem; }
.px-banner-inner img { width: 100%; border-radius: 10px; border: 1px solid var(--line); }
@media (max-width: 800px) { .px-banner-inner { grid-template-columns: 1fr; } }

html[data-theme="print3d"] .px-cats { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
html[data-theme="print3d"] .px-cats .cat-tile { aspect-ratio: 4 / 3; border-color: var(--line); }
html[data-theme="print3d"] .px-cats .cat-tile:hover { border-color: var(--accent); }
html[data-theme="print3d"] .px-cats .cat-label { background: linear-gradient(transparent, rgba(9, 11, 14, 0.92)); }
html[data-theme="print3d"] .px-cats .cat-name { font-family: var(--font-display); font-size: 1rem; }
html[data-theme="print3d"] .px-cats .cat-count { font-family: var(--font-mono); color: var(--accent); opacity: 1; }

.px-story-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.px-story-media { aspect-ratio: 1; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); }
.px-story-media img { width: 100%; height: 100%; object-fit: cover; }
.px-list { list-style: none; padding: 0; margin: 1.4rem 0 1.8rem; display: grid; gap: 0.7rem; font-family: var(--font-mono); font-size: 0.9rem; }
.px-list li { display: flex; gap: 0.7rem; }
.px-list .mark { color: var(--accent); }
@media (max-width: 860px) { .px-story-grid { grid-template-columns: 1fr; } }

html[data-theme="print3d"] .review-card .who { font-family: var(--font-mono); font-size: 0.78rem; }
html[data-theme="print3d"] .newsletter { background: var(--surface); border: 1px solid var(--line); }
html[data-theme="print3d"] .section-head h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); }

/* ---------- product page ---------- */
html[data-theme="print3d"] .viewer { background: radial-gradient(circle at 50% 45%, #1e2733, #0d1014 72%); }
html[data-theme="print3d"] .viewer::before { content: ''; position: absolute; inset: 0; background: var(--glow); pointer-events: none; z-index: 0; }
html[data-theme="print3d"] .thumbs .thumb-3d { background: #11161c; }
html[data-theme="print3d"] .product-info h1 { font-size: clamp(1.6rem, 3vw, 2.4rem); }
html[data-theme="print3d"] .product-info .price .now { font-family: var(--font-mono); }
html[data-theme="print3d"] .specs td:last-child { font-family: var(--font-mono); color: var(--accent); }
html[data-theme="print3d"] .tab { font-family: var(--font-mono); }
html[data-theme="print3d"] .faq-q { font-family: var(--font-body); font-weight: 500; }
html[data-theme="print3d"] .footer-brand .logo::before { display: none; }

/* ---------- admin ---------- */
html[data-theme="print3d"] body.page-admin { --admin-side-bg: #090b0e; --admin-side-active-bg: rgba(184, 240, 74, 0.14); --admin-side-active: #c8ff5a; }
html[data-theme="print3d"] .admin-nav a { font-family: var(--font-body); }
html[data-theme="print3d"] .admin-brand .logo { font-size: 1.02rem; }
html[data-theme="print3d"] .admin-topbar h1 { font-size: 1.5rem; }
html[data-theme="print3d"] table.data th { font-family: var(--font-mono); letter-spacing: 0; }
html[data-theme="print3d"] .serp { background: #fff; }
