/* =========================================================================
   TechVero Block Theme Compatibility Layer
   Bridges WordPress core blocks to the original TechVero component classes.
   ========================================================================= */

.wp-site-blocks > * { margin-block-start: 0; }
.wp-site-blocks { min-height: 100vh; overflow-x: clip; }
.wp-block-group, .wp-block-columns, .wp-block-column { box-sizing: border-box; }
.wp-block-group.tv-site-main { position: relative; z-index: 1; }

/* Header as real editable block template part */
.wp-block-group.tv-header { margin: 0; }
.wp-block-group.tv-header .tv-header__inner { min-height: 64px; }
.tv-header__brand { display: inline-flex; align-items: center; gap: 12px; }
.tv-header__brand .wp-block-site-title { margin: 0; }
.tv-header__brand .wp-block-site-title a {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--tv-font-head); font-weight: 800; font-size: 1.25rem;
  color: var(--tv-ink); letter-spacing: -.01em; text-decoration: none;
}
.tv-header__brand .wp-block-site-title a::before {
  content: ""; width: 14px; height: 14px; border-radius: 5px;
  background: var(--tv-grad); box-shadow: 0 4px 12px rgba(91,74,230,.5);
  display: inline-block;
}
.tv-header__brand .wp-block-site-logo img { max-height: 40px; width: auto; }
.tv-nav.wp-block-navigation { flex: none; }
.tv-nav .wp-block-navigation__container { gap: 6px; }
.tv-nav .wp-block-navigation-item__content {
  display: inline-block; padding: 9px 14px; border-radius: 10px;
  color: var(--tv-body); font-weight: 500; font-size: .95rem;
  transition: color .2s, background .2s;
}
.tv-nav .wp-block-navigation-item__content:hover,
.tv-nav .wp-block-navigation-item.current-menu-item > .wp-block-navigation-item__content {
  color: var(--tv-primary); background: var(--tv-primary-soft);
}
.tv-nav .wp-block-navigation__responsive-container.is-menu-open {
  background: #fff; padding: 32px;
}
.tv-nav .wp-block-navigation__responsive-container-open,
.tv-nav .wp-block-navigation__responsive-container-close { color: var(--tv-ink); }

/* Core buttons with TechVero classes */
.wp-block-button.tv-btn {
  --b: var(--tv-primary);
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--tv-font-head); font-weight: 600; font-size: .95rem; line-height: 1;
  padding: 14px 24px; border-radius: 999px; border: 1.5px solid transparent;
  cursor: pointer; transition: transform .25s var(--tv-ease), box-shadow .25s var(--tv-ease), background .25s var(--tv-ease), color .25s var(--tv-ease);
  white-space: nowrap; text-decoration: none;
}
.wp-block-button.tv-btn .wp-block-button__link {
  display: inline-flex; align-items: center; gap: .5em;
  padding: 0; margin: 0; background: transparent; color: inherit;
  border: 0; border-radius: inherit; box-shadow: none; text-decoration: none;
  font-family: inherit; font-weight: inherit; font-size: inherit; line-height: inherit;
}
.wp-block-button.tv-btn--primary { background: var(--tv-grad); color: #fff; box-shadow: 0 10px 26px rgba(91,74,230,.32); }
.wp-block-button.tv-btn--primary:hover { color:#fff; transform: translateY(-2px); box-shadow: 0 16px 34px rgba(91,74,230,.42); }
.wp-block-button.tv-btn--ghost { background: rgba(255,255,255,.6); color: var(--tv-ink); border-color: var(--tv-line); backdrop-filter: blur(6px); }
.wp-block-button.tv-btn--ghost:hover { color: var(--tv-primary); transform: translateY(-2px); border-color: var(--tv-primary); }
.wp-block-button.tv-btn--sm { padding: 11px 18px; font-size: .85rem; }
.wp-block-buttons.tv-hero__actions,
.wp-block-buttons.tv-cta-band__actions { margin-top: 30px; }

/* Block content defaults */
.tv-section-head > .wp-block-heading,
.tv-section-head > p { margin-left: auto; margin-right: auto; }
.tv-section-head--left > .wp-block-heading,
.tv-section-head--left > p { margin-left: 0; margin-right: 0; }
.tv-feature > *, .tv-service > *, .tv-review > * { position: relative; }
.tv-feature p, .tv-service p, .tv-review p { margin-bottom: 0; }
.tv-feature .wp-block-heading, .tv-service .wp-block-heading { margin-bottom: 10px; }
.tv-about__copy .wp-block-heading { font-size: clamp(1.8rem, 4vw, 3rem); font-weight: 800; }
.tv-about__copy .wp-block-list { margin: 24px 0 30px; }
.tv-about__copy .wp-block-list li { margin-bottom: 12px; }
.tv-page-body .wp-block-post-content { margin-inline: auto; }
.tv-page-body .wp-block-post-content > * { max-width: 760px; margin-left: auto; margin-right: auto; }
.tv-page-body .wp-block-post-content > .alignwide { max-width: var(--tv-maxw); }
.tv-page-body .wp-block-post-content > .alignfull { max-width: none; }

/* Query/blog cards */
.tv-blog .wp-block-post-template { display: grid; grid-template-columns: repeat(3,1fr); gap: var(--tv-gap); padding: 0; }
.tv-blog .wp-block-post { background:#fff; border:1px solid var(--tv-line); border-radius: var(--tv-radius); overflow:hidden; box-shadow: var(--tv-shadow-sm); }
.tv-blog .wp-block-post-featured-image img { aspect-ratio: 16/10; object-fit: cover; width: 100%; }
.tv-blog .wp-block-post-title, .tv-blog .wp-block-post-excerpt { padding-inline: 22px; }
.tv-blog .wp-block-post-title { font-size: 1.2rem; padding-top: 22px; }
.tv-blog .wp-block-post-excerpt { padding-bottom: 22px; }

/* Footer blocks */
.wp-block-group.tv-footer { margin: 0; }
.tv-footer .wp-block-site-title { margin: 0; }
.tv-footer .wp-block-site-title a,
.tv-footer .tv-logo--light { color: #fff; font-family: var(--tv-font-head); font-weight: 800; font-size: 1.25rem; text-decoration: none; }
.tv-footer .wp-block-site-title a::before,
.tv-footer .tv-logo--light::before {
  content:""; width:14px; height:14px; border-radius:5px; background:var(--tv-grad);
  display:inline-block; margin-right:10px; box-shadow:0 4px 12px rgba(91,74,230,.5);
}
.tv-footer .wp-block-list { list-style: none; padding: 0; margin: 0; }
.tv-footer .wp-block-list li { margin: 0; }
.tv-footer .wp-block-button.tv-btn { margin-top: 16px; }
.tv-footer a { text-decoration: none; }

/* Custom template helpers */
.tv-404 { min-height: 50vh; display: grid; place-items: center; text-align: center; }
.tv-404 .wp-block-search { max-width: 520px; margin-inline: auto; }

@media (max-width: 1024px) {
  .tv-blog .wp-block-post-template { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 860px) {
  .tv-nav.wp-block-navigation { margin-left: auto; }
  .tv-header__cta { display: none; }
}
@media (max-width: 640px) {
  .tv-blog .wp-block-post-template { grid-template-columns: 1fr; }
  .tv-header__inner { gap: 12px; }
  .tv-nav .wp-block-navigation-item__content { font-size: 1.05rem; }
}


/* TechVero Block Pro: editor-safe block markup adjustments */
.tv-stat p,
.tv-feature__icon,
.tv-service__num,
.tv-stars,
.tv-avatar,
.tv-review__who h4,
.tv-review__who p { margin: 0; }
.tv-feature__icon { line-height: 1; }
.tv-service__num { display: block; }
.tv-review__who h4 { font-size: .92rem; color: var(--tv-ink); }
.tv-review__who p:not(.tv-avatar) { color: var(--tv-muted); font-size: .8rem; line-height: 1.2; }
.tv-stars { letter-spacing: .06em; color: var(--tv-gold); }
.tv-grad-a { background: linear-gradient(135deg,#5b4ae6,#7c5cff); }
.tv-grad-b { background: linear-gradient(135deg,#19b8e8,#5b4ae6); }
.tv-grad-c { background: linear-gradient(135deg,#16c08a,#19b8e8); }
.tv-grad-d { background: linear-gradient(135deg,#7c5cff,#b06cff); }
.tv-grad-e { background: linear-gradient(135deg,#f6a609,#ff7a59); }
.tv-grad-f { background: linear-gradient(135deg,#5b4ae6,#19b8e8); }
.block-editor-block-list__layout .tv-dash,
.block-editor-block-list__layout .tv-service,
.block-editor-block-list__layout .tv-feature,
.block-editor-block-list__layout .tv-review,
.block-editor-block-list__layout .tv-cta-band__inner { transform: none !important; }

/* Moving testimonial marquee: Social Proof section */
.tv-proof__marquee {
  width: 100%;
  overflow: hidden;
  position: relative;
  margin-top: clamp(28px, 4vw, 52px);
  padding: 8px 0 24px;
}

.tv-proof__marquee::before,
.tv-proof__marquee::after {
  content: "";
  position: absolute;
  top: 0;
  width: 110px;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.tv-proof__marquee::before {
  left: 0;
  background: linear-gradient(to right, var(--tv-bg), transparent);
}

.tv-proof__marquee::after {
  right: 0;
  background: linear-gradient(to left, var(--tv-bg), transparent);
}

.tv-proof__track {
  display: flex;
  gap: var(--tv-gap);
  width: max-content;
  animation: tv-proof-marquee-left 34s linear infinite;
  will-change: transform;
}

.tv-proof__marquee:hover .tv-proof__track {
  animation-play-state: paused;
}

.tv-proof__track .tv-review {
  width: 390px;
  min-height: 230px;
  flex: 0 0 auto;
}

@keyframes tv-proof-marquee-left {
  from {
    transform: translate3d(0, 0, 0);
  }

  to {
    transform: translate3d(-50%, 0, 0);
  }
}

@media (max-width: 768px) {
  .tv-proof__marquee::before,
  .tv-proof__marquee::after {
    width: 45px;
  }

  .tv-proof__track {
    gap: 20px;
    animation-duration: 24s;
  }

  .tv-proof__track .tv-review {
    width: 300px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tv-proof__track {
    animation: none;
  }

  .tv-proof__marquee {
    overflow-x: auto;
  }
}
