/* ==========================================================================
   TIK Computers — дизайн система
   Модерен B2B ИТ сайт. Цветовете по-долу са извлечени директно от логото
   (assets/logo.png) — синьото на текста и златното на стрелката отдолу.
   ========================================================================== */

:root {
  /* --- Марка / акцентни цветове (извлечени от logo.png) --- */
  --brand-blue: #0b4a91;
  --brand-blue-dark: #072f5f;
  --brand-orange: #ffc700;
  --brand-orange-dark: #d9a600;

  --radius: 14px;
  --radius-sm: 8px;
  --container: 1180px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, .06), 0 1px 1px rgba(15, 23, 42, .04);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, .10);
  --shadow-lg: 0 20px 48px rgba(15, 23, 42, .16);

  --font-sans: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;

  /* --- Светла тема (по подразбиране) --- */
  --bg: #ffffff;
  --bg-alt: #f5f7fb;
  --bg-inset: #eef1f8;
  --surface: #ffffff;
  --border: #e2e6ef;
  --text: #101828;
  --text-muted: #4b5468;
  --text-faint: #6b7280;
  --link: var(--brand-blue);
  --accent: var(--brand-orange);
  --header-bg: rgba(255, 255, 255, .92);
}

:root[data-theme="dark"] {
  --bg: #0b0f1a;
  --bg-alt: #10162614;
  --bg-alt: #101626;
  --bg-inset: #151d30;
  --surface: #131b2c;
  --border: #232f47;
  --text: #eef1f8;
  --text-muted: #b7c0d4;
  --text-faint: #8a93aa;
  --link: #6fa1ff;
  --accent: #ff9f45;
  --header-bg: rgba(11, 15, 26, .88);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b0f1a;
    --bg-alt: #101626;
    --bg-inset: #151d30;
    --surface: #131b2c;
    --border: #232f47;
    --text: #eef1f8;
    --text-muted: #b7c0d4;
    --text-faint: #8a93aa;
    --link: #6fa1ff;
    --accent: #ff9f45;
    --header-bg: rgba(11, 15, 26, .88);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; padding: 0; }

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
ul, ol { padding-left: 1.25em; }
h1, h2, h3, h4 { line-height: 1.2; letter-spacing: -.01em; margin: 0 0 .5em; font-weight: 700; }
p { margin: 0 0 1em; color: var(--text-muted); }

.container { max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.section { padding: clamp(48px, 7vw, 96px) 0; }
.section-alt { background: var(--bg-alt); }
.section-head { max-width: 720px; margin: 0 auto clamp(28px, 4vw, 48px); text-align: center; }
.section-head.left { margin-left: 0; text-align: left; }
.eyebrow {
  display: inline-block; font-size: .8rem; font-weight: 700; letter-spacing: .06em;
  text-transform: uppercase; color: var(--brand-blue); background: color-mix(in srgb, var(--brand-blue) 10%, transparent);
  padding: 4px 12px; border-radius: 999px; margin-bottom: 14px;
}
:root[data-theme="dark"] .eyebrow, @supports not (color: color-mix(in srgb, red, blue)) { }

h1 { font-size: clamp(2rem, 4vw, 3.1rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.4rem); }
.lede { font-size: clamp(1.05rem, 2vw, 1.2rem); color: var(--text-muted); }

/* Skip link */
.skip-link {
  position: absolute; left: -999px; top: 0; background: var(--brand-blue); color: #fff;
  padding: 10px 16px; z-index: 200; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* --- Header ---
   Забележка: backdrop-filter е на ::before, не директно на .site-header — ако е на
   самия .site-header, той се превръща в containing block за position:fixed деца
   (мобилното меню по-долу) и то се "хваща" вътре в хедъра вместо да покрие екрана. */
.site-header {
  position: sticky; top: 0; z-index: 100; border-bottom: 1px solid var(--border); isolation: isolate;
}
.site-header::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--header-bg); backdrop-filter: saturate(160%) blur(10px);
}
.header-inner { display: flex; align-items: center; gap: 20px; padding: 12px 20px; max-width: var(--container); margin: 0 auto; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.15rem; color: var(--text); border-radius: 10px; transition: background-color .2s ease; }
/* Логото е нарисувано за светъл фон (тъмносиньо + златно) — в тъмна тема
   получава бяла "плочка" зад себе си, за да остане четливо, вместо да се
   слива с тъмния хедър/футър. */
:root[data-theme="dark"] .brand { background: #ffffff; padding: 6px 12px; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand { background: #ffffff; padding: 6px 12px; }
}
.brand:hover { text-decoration: none; }
.brand-logo { height: 30px; width: auto; display: block; }

.nav { display: flex; align-items: center; gap: 2px; margin-left: 10px; flex: 1; }
.nav > details, .nav > a.nav-link {
  position: relative; font-weight: 600; font-size: .96rem; color: var(--text);
}
.nav > a.nav-link { padding: 10px 12px; border-radius: var(--radius-sm); }
.nav > a.nav-link:hover { background: var(--bg-alt); text-decoration: none; }
.nav summary {
  list-style: none; cursor: pointer; padding: 10px 12px; border-radius: var(--radius-sm);
  display: flex; align-items: center; gap: 6px; user-select: none;
}
.nav summary::-webkit-details-marker { display: none; }
.nav summary:hover { background: var(--bg-alt); }
.nav summary .car { transition: transform .15s ease; font-size: .7em; }
.nav details[open] summary .car { transform: rotate(180deg); }

.mega {
  position: absolute; top: calc(100% + 8px); left: 0; min-width: 300px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); padding: 10px; z-index: 50;
}
.mega .grp { padding: 8px 10px 10px; }
.mega .grp + .grp { border-top: 1px solid var(--border); }
.mega .grp-title { font-size: .74rem; text-transform: uppercase; letter-spacing: .05em; color: var(--text-faint); margin-bottom: 6px; font-weight: 700; }
.mega a { display: block; padding: 7px 8px; border-radius: 8px; color: var(--text); font-size: .92rem; font-weight: 500; }
.mega a:hover { background: var(--bg-alt); text-decoration: none; color: var(--brand-blue); }

.header-actions { display: flex; align-items: center; gap: 10px; }
.theme-toggle {
  border: 1px solid var(--border); background: var(--surface); width: 38px; height: 38px; border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer; color: var(--text);
}
.nav-toggle { display: none; border: 1px solid var(--border); background: var(--surface); width: 40px; height: 40px; border-radius: 10px; cursor: pointer; }

/* --- Buttons --- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; border-radius: 999px; font-weight: 700; font-size: .96rem;
  border: 1px solid transparent; cursor: pointer; white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--brand-blue); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--brand-blue-dark); }
/* Златният акцент от логото е твърде светъл за бял текст (лош контраст) —
   използваме тъмен, брандовия синьо-черен текст върху него вместо бяло. */
.btn-accent { background: var(--brand-orange); color: #14213d; font-weight: 800; }
.btn-accent:hover { background: var(--brand-orange-dark); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { background: var(--bg-alt); }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.btn-outline-light:hover { background: rgba(255,255,255,.12); }
.btn-sm { padding: 8px 16px; font-size: .86rem; }
.btn-block { width: 100%; }

/* --- Hero --- */
.hero {
  padding: clamp(56px, 9vw, 108px) 0 clamp(40px, 6vw, 72px);
  background: radial-gradient(1200px 600px at 85% -10%, color-mix(in srgb, var(--brand-blue) 14%, transparent), transparent 60%), var(--bg);
  position: relative; overflow: hidden; isolation: isolate;
}
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px; background: var(--bg-inset); border: 1px solid var(--border);
  padding: 6px 14px; border-radius: 999px; font-size: .84rem; font-weight: 600; margin-bottom: 18px; color: var(--text-muted);
}
/* Иконата вътре е "гол" inline SVG без width/height — без това правило браузърът
   ѝ дава default intrinsic размер 300×150px, което раздува целия badge (и бута
   останалото съдържание на hero-а надолу — точно "празното място" на мобилни). */
.hero-badge svg { width: 16px; height: 16px; flex: none; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 28px; }
.hero-visual {
  background: linear-gradient(145deg, var(--brand-blue), var(--brand-blue-dark));
  border-radius: var(--radius); aspect-ratio: 4/3.2; position: relative; overflow: hidden; box-shadow: var(--shadow-lg);
}
.hero-visual svg { width: 100%; height: 100%; }

/* --- Trust bar --- */
.trust-bar { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--bg-alt); }
.trust-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px; padding: 26px 0; }
.stat { text-align: center; min-width: 120px; }
.stat b { display: block; font-size: 1.7rem; font-weight: 800; color: var(--brand-blue); }
.stat span { font-size: .84rem; color: var(--text-faint); }
.logos { display: flex; gap: 22px; flex-wrap: wrap; align-items: center; opacity: .75; font-weight: 700; color: var(--text-faint); font-size: .9rem; }

/* --- Cluster / cards --- */
.clusters { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.cluster-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px;
  box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 12px;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.cluster-card .ic {
  width: 44px; height: 44px; border-radius: 12px; background: color-mix(in srgb, var(--brand-blue) 12%, transparent);
  display: flex; align-items: center; justify-content: center; color: var(--brand-blue); position: relative;
}
.cluster-card ul { list-style: none; padding: 0; margin: 4px 0 8px; display: flex; flex-direction: column; gap: 6px; }
.cluster-card ul a { font-size: .92rem; font-weight: 600; color: var(--text); }
.cluster-card ul a:hover { color: var(--brand-blue); }
.cluster-card ul li::before { content: "›"; color: var(--brand-orange); font-weight: 800; margin-right: 6px; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }

.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-sm);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.hero-services .card { text-align: left; }
.card .ic { width: 40px; height: 40px; border-radius: 10px; background: color-mix(in srgb, var(--brand-orange) 14%, transparent); color: var(--brand-orange); display: flex; align-items: center; justify-content: center; margin-bottom: 12px; position: relative; }

/* Хов ефект — леко повдигане + сияние в брандовия цвят (техно усещане) */
.card:hover, .cluster-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--brand-blue) 35%, var(--border));
  box-shadow: 0 16px 32px -12px color-mix(in srgb, var(--brand-blue) 28%, transparent), var(--shadow-sm);
}

/* Пулсиращ ореол зад всяка икона в кръгче — навсякъде по сайта */
.ic::before {
  content: ""; position: absolute; inset: -6px; border-radius: inherit;
  background: currentColor; opacity: 0; animation: icon-pulse 3.2s ease-in-out infinite;
}
.ic { z-index: 0; }
.ic svg { position: relative; z-index: 1; }
@keyframes icon-pulse {
  0%, 100% { opacity: 0; transform: scale(.85); }
  50% { opacity: .16; transform: scale(1.25); }
}

/* --- Process --- */
.process { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; counter-reset: step; }
.process .step { position: relative; padding: 22px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.process .step .num {
  width: 34px; height: 34px; border-radius: 50%; background: var(--brand-blue); color: #fff; font-weight: 800;
  display: flex; align-items: center; justify-content: center; margin-bottom: 12px; font-size: .95rem;
}

/* --- Pricing --- */
.pricing-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; align-items: stretch; }
.plan { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 30px 26px; display: flex; flex-direction: column; box-shadow: var(--shadow-sm); position: relative; }
.plan.featured {
  border: 1px solid transparent; box-shadow: var(--shadow-lg); transform: translateY(-6px);
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    conic-gradient(from var(--border-angle, 0deg), var(--brand-blue), var(--brand-orange), var(--brand-blue)) border-box;
  animation: rotate-border 5s linear infinite;
}
@property --border-angle { syntax: '<angle>'; inherits: false; initial-value: 0deg; }
@keyframes rotate-border { to { --border-angle: 360deg; } }
.plan .badge { position: absolute; top: -13px; left: 50%; transform: translateX(-50%); background: var(--brand-blue); color: #fff; font-size: .76rem; font-weight: 800; padding: 5px 14px; border-radius: 999px; white-space: nowrap; }
.plan .price { font-size: 2.3rem; font-weight: 800; margin: 10px 0 2px; }
.plan .price small { font-size: 1rem; font-weight: 600; color: var(--text-faint); }
.plan .price-alt { font-size: .84rem; color: var(--text-faint); margin-bottom: 18px; }
.plan ul { list-style: none; padding: 0; margin: 0 0 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.plan ul li { display: flex; gap: 8px; align-items: flex-start; font-size: .92rem; color: var(--text-muted); }
.plan ul li.no { opacity: .45; }
.plan ul li .chk { color: #16a34a; flex: none; font-weight: 800; }
.plan ul li .x { color: var(--text-faint); flex: none; }

.compare-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); }
table.compare { width: 100%; border-collapse: collapse; min-width: 620px; background: var(--surface); }
table.compare th, table.compare td { padding: 12px 16px; border-bottom: 1px solid var(--border); text-align: left; font-size: .92rem; }
table.compare th { background: var(--bg-alt); font-weight: 700; }
table.compare td:not(:first-child), table.compare th:not(:first-child) { text-align: center; }
table.compare tbody tr:last-child td { border-bottom: none; }

/* --- Testimonials --- */
.testi { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 14px; }
.testi .stars { color: var(--brand-orange); letter-spacing: 2px; }
.testi .who { display: flex; align-items: center; gap: 12px; margin-top: 6px; }
.testi .avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--bg-inset); display: flex; align-items: center; justify-content: center; font-weight: 800; color: var(--brand-blue); flex: none; }
.testi .who b { display: block; font-size: .92rem; }
.testi .who span { font-size: .82rem; color: var(--text-faint); }

/* --- FAQ --- */
.faq-list { display: flex; flex-direction: column; gap: 10px; max-width: 820px; margin: 0 auto; }
.faq-item { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.faq-item summary { list-style: none; cursor: pointer; padding: 16px 20px; font-weight: 700; display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-size: 1.3rem; color: var(--brand-blue); flex: none; }
.faq-item[open] summary::after { content: "−"; }
.faq-item .a { padding: 0 20px 18px; color: var(--text-muted); margin: 0; }

/* --- CTA band --- */
.cta-band {
  background: linear-gradient(135deg, var(--brand-blue), var(--brand-blue-dark));
  color: #fff; border-radius: var(--radius); padding: clamp(32px, 5vw, 56px); text-align: center;
}
.cta-band h2, .cta-band p { color: #fff; }
.cta-band p { opacity: .9; }
.cta-band .hero-cta { justify-content: center; }

/* --- Footer --- */
.site-footer { background: var(--bg-inset); border-top: 1px solid var(--border); padding: 56px 0 24px; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr; gap: 28px; margin-bottom: 36px; }
.footer-grid h4 { font-size: .84rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-faint); margin-bottom: 12px; }
.footer-grid ul { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.footer-grid a { color: var(--text-muted); font-size: .92rem; }
.footer-grid a:hover { color: var(--brand-blue); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding-top: 22px; border-top: 1px solid var(--border); font-size: .84rem; color: var(--text-faint); }
.footer-bottom a { color: var(--text-faint); }
.social { display: flex; gap: 10px; margin-top: 12px; }
.social a { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; color: var(--text-muted); }

/* --- Breadcrumbs --- */
.breadcrumbs { font-size: .84rem; color: var(--text-faint); padding: 16px 0; }
.breadcrumbs a { color: var(--text-faint); }
.breadcrumbs .sep { margin: 0 6px; }

/* --- Page hero (service pages) --- */
.page-hero { padding: clamp(36px, 6vw, 64px) 0 clamp(24px, 4vw, 40px); }
.page-hero .lede { max-width: 760px; }
.badge-note { display: inline-block; background: var(--bg-inset); border: 1px solid var(--border); border-radius: 999px; padding: 6px 14px; font-size: .82rem; font-weight: 700; color: var(--brand-blue); margin-bottom: 14px; }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.check-list { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.check-list li { display: flex; gap: 10px; align-items: flex-start; }
.check-list li::before { content: "✓"; color: #16a34a; font-weight: 800; flex: none; }
.num-list { list-style: none; padding: 0; counter-reset: n; display: flex; flex-direction: column; gap: 16px; }
.num-list li { display: flex; gap: 14px; }
.num-list li::before { counter-increment: n; content: counter(n); width: 30px; height: 30px; border-radius: 50%; background: var(--brand-blue); color: #fff; font-weight: 800; font-size: .88rem; display: flex; align-items: center; justify-content: center; flex: none; }

.callout { background: var(--bg-inset); border-left: 4px solid var(--brand-orange); border-radius: 0 var(--radius) var(--radius) 0; padding: 18px 22px; }
.callout p:last-child { margin: 0; }

.results-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 18px; }
.results-strip .r { text-align: center; padding: 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.results-strip .r b { display: block; font-size: 1.6rem; color: var(--brand-blue); }
.results-strip .r span { font-size: .84rem; color: var(--text-faint); }

/* --- Forms --- */
.form-field { margin-bottom: 16px; display: flex; flex-direction: column; gap: 6px; }
.form-field label { font-weight: 600; font-size: .9rem; }
.form-field input, .form-field textarea, .form-field select {
  border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 11px 14px; font: inherit;
  background: var(--surface); color: var(--text); width: 100%;
}
.form-field input:focus, .form-field textarea:focus, .form-field select:focus { outline: 2px solid var(--brand-blue); outline-offset: 1px; }
.form-check { display: flex; gap: 10px; align-items: flex-start; font-size: .86rem; color: var(--text-muted); margin-bottom: 18px; }
.form-check input { margin-top: 4px; }
.hp-field { position: absolute; left: -9999px; opacity: 0; }
.form-msg { display: none; padding: 12px 16px; border-radius: var(--radius-sm); font-size: .9rem; margin-bottom: 16px; }
.form-msg.ok { display: block; background: #dcfce7; color: #166534; }
.form-msg.err { display: block; background: #fee2e2; color: #991b1b; }

/* --- Blog --- */
.post-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; }
.post-card .thumb { aspect-ratio: 16/9; background: linear-gradient(135deg, var(--brand-blue), var(--brand-orange)); }
.post-card .body { padding: 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.post-card .meta { font-size: .78rem; color: var(--text-faint); }
article.prose { max-width: 760px; margin: 0 auto; }
article.prose h2 { margin-top: 1.6em; }
article.prose h3 { margin-top: 1.2em; }
.author-box { display: flex; gap: 14px; align-items: center; background: var(--bg-alt); border-radius: var(--radius); padding: 18px 22px; margin-top: 40px; }
.author-box .avatar { width: 52px; height: 52px; border-radius: 50%; background: var(--brand-blue); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; flex: none; }

/* --- Portal --- */
.portal-hero { text-align: center; padding: clamp(50px, 8vw, 90px) 0; }
.qr-box { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; display: inline-flex; flex-direction: column; align-items: center; gap: 14px; box-shadow: var(--shadow-md); }

/* --- Sticky mobile CTA --- */
.sticky-cta { display: none; }

/* ==========================================================================
   ТЕХНО ВИЗУАЛНИ ЕФЕКТИ — grid фон, светещи сфери, мрежова диаграма в hero-a,
   pulse индикатори за "на живо" мониторинг. Всичко е чист CSS/SVG — без
   външни изображения, за да остане сайтът бърз и самодостатъчен.
   ========================================================================== */

/* Blueprint/grid фон — прилага се на hero, page-hero, CTA лентата */
.tech-grid-bg { position: relative; isolation: isolate; }
.tech-grid-bg::before {
  content: ""; position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background-image:
    linear-gradient(color-mix(in srgb, var(--brand-blue) 10%, transparent) 1px, transparent 1px),
    linear-gradient(90deg, color-mix(in srgb, var(--brand-blue) 10%, transparent) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse 75% 65% at 50% 0%, black 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 0%, black 30%, transparent 100%);
}
.cta-band.tech-grid-bg::before {
  background-image:
    linear-gradient(rgba(255,255,255,.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.12) 1px, transparent 1px);
  mask-image: radial-gradient(ellipse 80% 100% at 50% 50%, black 20%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 100% at 50% 50%, black 20%, transparent 100%);
}

/* Меки, бавно плаващи светещи сфери — декоративни, зад съдържанието */
.glow-orb {
  position: absolute; border-radius: 50%; filter: blur(64px); z-index: -1; pointer-events: none;
  animation: orb-float 11s ease-in-out infinite;
}
.glow-orb.blue { background: color-mix(in srgb, var(--brand-blue) 55%, transparent); opacity: .55; }
.glow-orb.orange { background: color-mix(in srgb, var(--brand-orange) 55%, transparent); opacity: .4; animation-delay: -4s; }
@keyframes orb-float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(18px, -22px) scale(1.08); }
}

/* --- Мрежова диаграма в hero-a (виж build.py → hero_network_svg) --- */
.hero-visual { position: relative; }
.hero-visual .flow-lines path {
  stroke-dasharray: 5 11; animation: dash-flow 1.8s linear infinite;
}
.hero-visual .flow-lines path:nth-child(2) { animation-delay: .25s; }
.hero-visual .flow-lines path:nth-child(3) { animation-delay: .5s; }
.hero-visual .flow-lines path:nth-child(4) { animation-delay: .75s; }
.hero-visual .flow-lines path:nth-child(5) { animation-delay: 1s; }
@keyframes dash-flow { to { stroke-dashoffset: -32; } }

.hero-visual .node-halo { animation: node-pulse 2.8s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.hero-visual .node-halo:nth-of-type(2) { animation-delay: .35s; }
.hero-visual .node-halo:nth-of-type(3) { animation-delay: .7s; }
.hero-visual .node-halo:nth-of-type(4) { animation-delay: 1.05s; }
.hero-visual .node-halo:nth-of-type(5) { animation-delay: 1.4s; }
@keyframes node-pulse { 0%, 100% { opacity: .12; transform: scale(.85); } 50% { opacity: .5; transform: scale(1.2); } }

.hero-visual .hub-ring {
  transform-box: fill-box; transform-origin: center; animation: hub-ring-out 2.6s ease-out infinite;
}
@keyframes hub-ring-out { 0% { opacity: .55; transform: scale(1); } 100% { opacity: 0; transform: scale(1.7); } }

/* --- "На живо" индикатор — точка с ping ефект, до статистики/статуси --- */
.pulse-dot {
  position: relative; width: 9px; height: 9px; border-radius: 50%; background: #22c55e;
  display: inline-block; flex: none; box-shadow: 0 0 0 0 rgba(34, 197, 94, .5);
}
.pulse-dot::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%; background: #22c55e;
  animation: pulse-ring 1.8s cubic-bezier(.4, 0, .2, 1) infinite;
}
@keyframes pulse-ring { 0% { transform: scale(1); opacity: .65; } 100% { transform: scale(2.6); opacity: 0; } }
.live-badge { display: inline-flex; align-items: center; gap: 8px; }

/* Радар ефект за видеонаблюдение картата — концентрични разширяващи се пръстени */
.ic.radar::after {
  content: ""; position: absolute; inset: -8px; border-radius: 50%; border: 2px solid currentColor;
  opacity: 0; animation: radar-ping 2.4s ease-out infinite;
}
@keyframes radar-ping { 0% { opacity: .5; transform: scale(.7); } 100% { opacity: 0; transform: scale(1.9); } }

/* Прекратяване на всички декоративни анимации при заявка за намалено движение */
@media (prefers-reduced-motion: reduce) {
  .glow-orb, .plan.featured, .ic::before, .hero-visual .flow-lines path,
  .hero-visual .node-halo, .hero-visual .hub-ring, .pulse-dot::after, .ic.radar::after {
    animation: none !important;
  }
}

/* ==========================================================================
   Responsive — три нива: десктоп (>1024px) → таблет (641–1024px) → телефон (≤640px)
   ========================================================================== */

/* --- Ниво 1: таблет и по-малко — навигацията вече не се събира на един ред
   (лого + 6 елемента + 2 dropdown-а + бутони), затова минава на off-canvas
   меню тук вместо едва на телефонна ширина. Важи и за iPad портрет (768px)
   и landscape (1024px). --- */
@media (max-width: 1024px) {
  .nav {
    display: none; position: fixed; inset: 62px 0 0 0; background: var(--bg);
    overflow-y: auto; flex-direction: column; align-items: stretch; padding: 12px 16px 24px;
    border-top: 1px solid var(--border); z-index: 95;
  }
  .nav.open { display: flex; }
  .nav > a.nav-link, .nav summary { width: 100%; }
  .mega { position: static; box-shadow: none; border: none; padding: 4px 0 4px 14px; margin-top: 4px; width: 100%; min-width: 0; }
  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .header-actions .btn-primary.portal-btn span.full { display: none; }
  .header-inner { flex-wrap: nowrap; }
}

/* --- Ниво 2: таблет ширини — по-плътни решетки вместо десктопските 3–5 колони --- */
@media (max-width: 980px) {
  .clusters, .grid-3, .grid-4, .process { grid-template-columns: 1fr 1fr; }
  .pricing-grid { grid-template-columns: 1fr; }
  .plan.featured { transform: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero-grid, .two-col { grid-template-columns: 1fr; }
  .hero-visual { max-width: 480px; margin: 0 auto; }
  table.compare { min-width: 560px; }
}

/* --- Ниво 3: телефон — всичко в една колона, sticky CTA лента отдолу --- */
@media (max-width: 640px) {
  .sticky-cta {
    display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 90; gap: 10px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: var(--surface); border-top: 1px solid var(--border); box-shadow: 0 -6px 20px rgba(0,0,0,.08);
  }
  .sticky-cta .btn { flex: 1; }
  body { padding-bottom: 68px; }
  .clusters, .grid-3, .grid-4, .process, .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .trust-inner { justify-content: center; text-align: center; }
  .header-inner { padding: 10px 14px; gap: 10px; }
  .brand-logo { height: 24px; }
  .hero-cta, .cta-band .hero-cta { flex-direction: column; align-items: stretch; }
  .hero-cta .btn, .cta-band .hero-cta .btn { width: 100%; }
  .plan.featured { order: -1; }
  table.compare { min-width: 480px; font-size: .84rem; }
  table.compare th, table.compare td { padding: 9px 10px; }
}

/* --- Много малки телефони --- */
@media (max-width: 380px) {
  .container { padding: 0 14px; }
  .qr-box svg { width: 140px; height: 140px; }
}

.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.section > .container > .cta-band { margin-top: 8px; }
.mt-lg { margin-top: 48px; }
.text-center { text-align: center; }
.small-note { font-size: .82rem; color: var(--text-faint); }
