/* Shared mechanics for every design variant. Theme files set the look. */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; overflow-x: hidden; -webkit-font-smoothing: antialiased; }
body.menu-open { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
section[id] { scroll-margin-top: 90px; }

/* Tabs */
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fade-up .45s ease both; }

/* Testimonials */
.testimonial { display: none; }
.testimonial.active { display: block; animation: fade-up .45s ease both; }

/* Mobile nav */
.mobile-nav {
  position: fixed; inset: 0; z-index: 40;
  display: flex; flex-direction: column; justify-content: center; gap: 10px;
  padding: 100px 32px 40px;
  opacity: 0; visibility: hidden; transition: opacity .3s ease, visibility .3s;
}
.mobile-nav.open { opacity: 1; visibility: visible; }
.menu-toggle {
  display: none; position: relative; z-index: 50;
  width: 44px; height: 44px; padding: 0; border: 0; background: none; cursor: pointer;
}
.menu-toggle span {
  position: absolute; left: 10px; width: 24px; height: 2px; background: currentColor;
  transition: transform .3s ease, opacity .3s ease;
}
.menu-toggle span:nth-child(1) { top: 14px; }
.menu-toggle span:nth-child(2) { top: 21px; }
.menu-toggle span:nth-child(3) { top: 28px; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
@media (max-width: 960px) {
  .desktop-nav { display: none !important; }
  .menu-toggle { display: block; }
}

/* Form */
.hp-field { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.form-status { min-height: 1.4em; font-size: .95rem; }
.form-status[data-state="success"] { color: var(--ok, #1a7f37); }
.form-status[data-state="error"] { color: var(--err, #c62828); }
button[disabled] { opacity: .6; cursor: progress; }

/* Progress bars */
.progress-track span { display: block; height: 100%; width: var(--value); }

/* Reveal on scroll */
[data-reveal] { opacity: 0; transform: translateY(28px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1); }
[data-reveal].is-visible { opacity: 1; transform: none; }

@keyframes fade-up { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes marquee { to { transform: translateX(-50%); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  [data-reveal] { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}
