/* =========================================================
   TUBARÃO MOTORS — Header, Navegação, Footer
   ========================================================= */

/* --- Barra superior (topbar) --- */
.topbar {
  background: var(--bg-void);
  border-bottom: 1px solid var(--border-subtle);
  font-size: var(--fs-2xs);
  color: var(--text-muted);
}

.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: var(--sp-2);
  gap: var(--sp-4);
}

.topbar__left {
  display: flex;
  align-items: center;
  gap: var(--sp-5);
}

.topbar__item {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
}

.topbar__item .icon {
  width: 14px;
  height: 14px;
  color: var(--shark-400);
}

.topbar__social {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
}

.topbar__social a {
  color: var(--text-muted);
  transition: color var(--dur-fast) var(--ease-out);
}

.topbar__social a:hover {
  color: var(--shark-400);
}

.topbar__social .icon {
  width: 15px;
  height: 15px;
}

@media (max-width: 720px) {
  .topbar__left .topbar__item:last-child {
    display: none;
  }
}

/* --- Header principal --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(5, 7, 13, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
  transition: box-shadow var(--dur-base) var(--ease-out);
}

.site-header.is-scrolled {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-6);
  padding-block: var(--sp-3);
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  flex-shrink: 0;
}

.brand img {
  height: 42px;
  width: auto;
}

.brand__text {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  line-height: 1;
  text-transform: uppercase;
  color: var(--text-primary);
}

.brand__text span {
  display: block;
  color: var(--shark-400);
  font-size: 0.7em;
}

/* --- Navegação principal --- */
.main-nav {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
}

.main-nav a {
  display: inline-block;
  padding: 0.6rem 0.9rem;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  transition: color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out);
  position: relative;
}

.main-nav a:hover {
  color: var(--text-primary);
  background: var(--bg-surface-hover);
}

.main-nav a.is-active {
  color: #fff;
}

.main-nav a.is-active::after {
  content: '';
  position: absolute;
  left: 0.9rem;
  right: 0.9rem;
  bottom: 0.3rem;
  height: 2px;
  background: var(--shark-400);
  border-radius: var(--radius-pill);
}

.header__actions {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  flex-shrink: 0;
}

/* --- Botão hamburger (mobile) --- */
.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-medium);
  color: var(--text-primary);
  flex-shrink: 0;
}

.nav-toggle .icon {
  width: 22px;
  height: 22px;
}

.nav-toggle[aria-expanded="true"] .icon-menu {
  display: none;
}
.nav-toggle:not([aria-expanded="true"]) .icon-close {
  display: none;
}

@media (max-width: 960px) {
  .main-nav {
    position: fixed;
    inset: 0;
    top: 0;
    background: var(--bg-void);
    flex-direction: column;
    justify-content: center;
    align-items: stretch;
    padding: var(--sp-9) var(--sp-6);
    gap: var(--sp-2);
    transform: translateX(100%);
    transition: transform var(--dur-slow) var(--ease-out);
    z-index: 250;
  }

  .main-nav.is-open {
    transform: translateX(0);
  }

  .main-nav a {
    font-family: var(--font-display);
    font-size: var(--fs-xl);
    text-transform: uppercase;
    padding: var(--sp-4) var(--sp-2);
    border-bottom: 1px solid var(--border-subtle);
    border-radius: 0;
  }

  .main-nav a.is-active::after {
    display: none;
  }

  .main-nav__close {
    position: absolute;
    top: var(--sp-5);
    right: var(--sp-6);
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-medium);
    border-radius: var(--radius-md);
  }

  .main-nav__close .icon {
    width: 22px;
    height: 22px;
  }

  .header__actions .btn-primary-label {
    display: none;
  }

  .nav-toggle {
    display: inline-flex;
  }
}

@media (min-width: 961px) {
  .main-nav__close {
    display: none;
  }
}

.nav-scrim {
  display: none;
}

.nav-scrim.is-visible {
  display: block;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 240;
}

body.nav-open {
  overflow: hidden;
}

/* --- Footer --- */
.site-footer {
  background: var(--bg-base);
  border-top: 1px solid var(--border-subtle);
  padding-top: var(--sp-10);
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: var(--sp-8);
  padding-bottom: var(--sp-9);
}

.footer__brand .brand {
  margin-bottom: var(--sp-4);
}

.footer__desc {
  color: var(--text-secondary);
  font-size: var(--fs-sm);
  max-width: 32ch;
  margin-bottom: var(--sp-5);
}

.footer__social {
  display: flex;
  gap: var(--sp-3);
}

.footer__social a {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: all var(--dur-fast) var(--ease-out);
}

.footer__social a:hover {
  border-color: var(--shark-400);
  color: var(--shark-400);
  background: rgba(20, 129, 255, 0.08);
}

.footer__social .icon {
  width: 17px;
  height: 17px;
}

.footer__title {
  font-family: var(--font-display);
  font-size: var(--fs-sm);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: var(--sp-4);
}

.footer__list {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}

.footer__list a,
.footer__list span {
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  transition: color var(--dur-fast) var(--ease-out);
}

.footer__list a:hover {
  color: var(--shark-400);
}

.footer__list li {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-2);
}

.footer__list .icon {
  width: 16px;
  height: 16px;
  color: var(--shark-400);
  margin-top: 0.2em;
  flex-shrink: 0;
}

.footer__bottom {
  border-top: 1px solid var(--border-subtle);
  padding-block: var(--sp-5);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  font-size: var(--fs-2xs);
  color: var(--text-muted);
  flex-wrap: wrap;
}

.footer__bottom-links {
  display: flex;
  gap: var(--sp-5);
}

.footer__bottom-links a:hover {
  color: var(--shark-400);
}

.footer__credits {
  border-top: 1px solid var(--border-subtle);
  padding-block: var(--sp-3);
  text-align: center;
  font-size: 0.7rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.footer__credits a {
  color: var(--text-muted);
  text-decoration: underline;
  text-decoration-color: transparent;
  transition: color var(--dur-fast) var(--ease-out), text-decoration-color var(--dur-fast) var(--ease-out);
}

.footer__credits a:hover {
  color: var(--shark-400);
  text-decoration-color: var(--shark-400);
}

@media (max-width: 900px) {
  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .footer__grid {
    grid-template-columns: 1fr;
    gap: var(--sp-6);
  }

  .footer__bottom {
    flex-direction: column;
    text-align: center;
  }
}

/* --- Botão flutuante WhatsApp --- */
.whatsapp-float {
  position: fixed;
  bottom: var(--sp-5);
  right: var(--sp-5);
  z-index: 150;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #1fb855;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 10px 30px rgba(31, 184, 85, 0.5);
  transition: transform var(--dur-base) var(--ease-out);
  animation: float-pulse 2.6s ease-in-out infinite;
}

.whatsapp-float:hover {
  transform: scale(1.08);
}

.whatsapp-float .icon {
  width: 30px;
  height: 30px;
  fill: currentColor;
  stroke: none;
}

@keyframes float-pulse {
  0%, 100% { box-shadow: 0 10px 30px rgba(31, 184, 85, 0.5); }
  50% { box-shadow: 0 10px 30px rgba(31, 184, 85, 0.85), 0 0 0 8px rgba(31, 184, 85, 0.12); }
}

@media (max-width: 560px) {
  .whatsapp-float {
    width: 52px;
    height: 52px;
    bottom: var(--sp-4);
    right: var(--sp-4);
  }
  .whatsapp-float .icon {
    width: 26px;
    height: 26px;
  }
}

/* --- Breadcrumb --- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--fs-xs);
  color: var(--text-muted);
  flex-wrap: wrap;
}

.breadcrumb a:hover {
  color: var(--shark-400);
}

.breadcrumb .icon {
  width: 12px;
  height: 12px;
}

.page-hero {
  padding-block: var(--sp-8) var(--sp-6);
  background: var(--bg-base);
  border-bottom: 1px solid var(--border-subtle);
}

.page-hero__title {
  font-size: var(--fs-3xl);
  text-transform: uppercase;
  margin-top: var(--sp-3);
}

.page-hero__sub {
  color: var(--text-secondary);
  font-size: var(--fs-md);
  margin-top: var(--sp-3);
  max-width: 60ch;
}

@media (max-width: 720px) {
  .page-hero__title {
    font-size: var(--fs-2xl);
  }
}
