/* GS Consultoria — identidade visual */
:root {
  --primary: #0a2342;
  --secondary: #1a73e8;
  --accent: #f5a623;
  --bg-light: #f7f9fc;
  --text: #1c1c1e;
  --white: #ffffff;
  --gray-badge: #6b7280;
  --header-height: 72px;
  --radius: 12px;
  --shadow: 0 8px 32px rgba(10, 35, 66, 0.12);
  --shadow-hover: 0 20px 48px rgba(10, 35, 66, 0.18);
  --font-title: "Sora", system-ui, sans-serif;
  --font-body: "DM Sans", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg-light);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--secondary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: auto;
  z-index: 2000;
  padding: 0.75rem 1rem;
  background: var(--accent);
  color: var(--primary);
  font-weight: 700;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--primary);
  transition: box-shadow 0.25s ease;
}

.site-header.scrolled {
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
}

.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
  min-height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.logo-gs {
  color: var(--accent);
}

.logo-rest {
  color: var(--white);
  font-weight: 500;
  margin-left: 0.25rem;
}

.logo:hover {
  text-decoration: none;
}

.nav-main {
  display: none;
  align-items: center;
  gap: 2rem;
}

.nav-main a {
  color: rgba(255, 255, 255, 0.92);
  font-weight: 500;
  font-size: 0.95rem;
}

.nav-main a:hover {
  color: var(--accent);
  text-decoration: none;
}

.nav-cta {
  display: none;
}

@media (min-width: 1024px) {
  .nav-main,
  .nav-cta {
    display: flex;
  }

  .btn-menu {
    display: none;
  }
}

.btn-menu {
  width: 48px;
  height: 48px;
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 10px;
  color: var(--white);
}

.btn-menu span {
  display: block;
  width: 24px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition:
    transform 0.35s ease,
    opacity 0.25s ease;
}

.site-header.menu-open .btn-menu span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.site-header.menu-open .btn-menu span:nth-child(2) {
  opacity: 0;
}

.site-header.menu-open .btn-menu span:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

.mobile-panel {
  display: none;
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(10, 35, 66, 0.98);
  padding: 1.5rem;
  flex-direction: column;
  gap: 0.75rem;
  z-index: 999;
}

.site-header.menu-open .mobile-panel {
  display: flex;
}

.mobile-panel a {
  color: var(--white);
  font-weight: 600;
  font-size: 1.05rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.mobile-panel .btn-mobile-cta {
  margin-top: 0.5rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.75rem 1.35rem;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--accent);
  color: var(--primary);
  box-shadow: 0 4px 16px rgba(245, 166, 35, 0.35);
}

.btn-primary:hover {
  background: #ffb84d;
  color: var(--primary);
}

.btn-outline-light {
  background: transparent;
  color: var(--white);
  border: 2px solid rgba(255, 255, 255, 0.6);
}

.btn-outline-light:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--white);
}

.btn-secondary {
  background: var(--secondary);
  color: var(--white);
}

.btn-secondary:hover {
  background: #1557b0;
  color: var(--white);
}

.btn-whatsapp {
  background: #25d366;
  color: var(--white);
}

.btn-whatsapp:hover {
  background: #1ebe57;
  color: var(--white);
}

/* Hero */
.hero {
  position: relative;
  min-height: min(88vh, 720px);
  display: flex;
  align-items: center;
  padding: 3rem 1rem 4rem;
  overflow: hidden;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.35;
}

.hero-bg svg {
  width: 100%;
  height: 100%;
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
}

.hero-content {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}

.hero h1 {
  font-family: var(--font-title);
  font-size: clamp(1.75rem, 5vw, 2.75rem);
  font-weight: 700;
  color: var(--white);
  line-height: 1.15;
  margin: 0 0 1rem;
  opacity: 0;
  animation: fadeSlideUp 0.9s ease forwards;
  animation-delay: 0.1s;
}

.hero .subtitle {
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.92);
  margin: 0 0 2rem;
  opacity: 0;
  animation: fadeSlideUp 0.9s ease forwards;
  animation-delay: 0.35s;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  align-items: stretch;
  opacity: 0;
  animation: fadeSlideUp 0.9s ease forwards;
  animation-delay: 0.55s;
}

@media (min-width: 768px) {
  .hero-actions {
    flex-direction: row;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
  }
}

@media (min-width: 1024px) {
  .hero-content {
    margin: 0;
    text-align: left;
    max-width: 640px;
  }

  .hero-actions {
    justify-content: flex-start;
  }
}

@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Sections */
.section {
  padding: 4rem 1rem;
  scroll-margin-top: calc(var(--header-height) + 16px);
}

.section-inner {
  max-width: 1280px;
  margin: 0 auto;
}

.section-title {
  font-family: var(--font-title);
  font-size: clamp(1.6rem, 3.5vw, 2.1rem);
  font-weight: 700;
  color: var(--primary);
  margin: 0 0 0.5rem;
  text-align: center;
}

.section-lead {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 2.5rem;
  color: #4b5563;
}

/* Sobre */
#sobre .section-lead {
  text-align: left;
  margin-left: 0;
  margin-right: 0;
  max-width: none;
}

@media (min-width: 768px) {
  #sobre .section-title,
  #sobre .section-lead {
    text-align: center;
  }

  #sobre .section-lead {
    margin-left: auto;
    margin-right: auto;
  }
}

.cards-row {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .cards-row {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card-simple {
  background: var(--white);
  padding: 1.5rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid rgba(10, 35, 66, 0.06);
}

.card-simple h3 {
  font-family: var(--font-title);
  font-size: 1.1rem;
  margin: 0 0 0.5rem;
  color: var(--primary);
}

.card-simple p {
  margin: 0;
  font-size: 0.95rem;
  color: #4b5563;
}

.services-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}

@media (min-width: 480px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.service-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.5rem 1.5rem 2.5rem;
  box-shadow: var(--shadow);
  border: 1px solid rgba(10, 35, 66, 0.06);
  position: relative;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
  overflow: hidden;
}

.service-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--secondary), var(--accent));
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}

.service-card h3 {
  font-family: var(--font-title);
  font-size: 1.05rem;
  margin: 0 0 0.5rem;
  color: var(--primary);
}

.service-card p {
  margin: 0;
  font-size: 0.9rem;
  color: #4b5563;
}

.service-card .cnae-badge {
  position: absolute;
  bottom: 0.75rem;
  left: 1.5rem;
  right: 1.5rem;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--gray-badge);
  line-height: 1.3;
}

/* Formação */
#formacao {
  background: linear-gradient(180deg, var(--bg-light) 0%, #e8eef8 100%);
}

.formacao-grid {
  display: grid;
  gap: 2rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .formacao-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.check-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
}

.check-list li {
  padding: 0.5rem 0;
  padding-left: 1.75rem;
  position: relative;
  font-weight: 500;
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55rem;
  width: 17px;
  height: 17px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231A73E8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 12l6 6 10-13'/%3E%3C/svg%3E")
    center / contain no-repeat;
}
#numeros {
  background: var(--primary);
  color: var(--white);
  padding: 4rem 1rem;
  scroll-margin-top: calc(var(--header-height) + 16px);
}

#numeros .section-title {
  color: var(--white);
}

.stats-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr 1fr;
  max-width: 1000px;
  margin: 0 auto;
  text-align: center;
}

@media (min-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.stat-item {
  padding: 1rem;
}

.stat-value {
  font-family: var(--font-title);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  color: var(--accent);
  line-height: 1.1;
}

.stat-label {
  font-size: 0.95rem;
  opacity: 0.9;
  margin-top: 0.35rem;
}

/* Contato */
.contact-grid {
  display: grid;
  gap: 2rem;
}

@media (min-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr 1.1fr;
    align-items: start;
  }
}

.contact-block {
  background: var(--white);
  padding: 1.75rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.contact-block h3 {
  font-family: var(--font-title);
  margin: 0 0 1rem;
  color: var(--primary);
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.contact-list li {
  margin-bottom: 0.85rem;
  padding-left: 0;
}

.contact-list a {
  color: var(--secondary);
  font-weight: 500;
}

.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.35rem;
  color: var(--primary);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  font-family: var(--font-body);
  font-size: 1rem;
  background: var(--white);
}

.form-group input:focus-visible,
.form-group select:focus-visible,
.form-group textarea:focus-visible {
  border-color: var(--secondary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.25);
}

.form-group textarea {
  min-height: 120px;
  resize: vertical;
}

.form-error {
  color: #b91c1c;
  font-size: 0.85rem;
  margin-top: 0.25rem;
  display: none;
}

.form-group.invalid .form-error {
  display: block;
}

.form-group.invalid input,
.form-group.invalid select,
.form-group.invalid textarea {
  border-color: #b91c1c;
}

.form-note {
  margin-top: 1rem;
  text-align: center;
  font-size: 0.95rem;
  color: #4b5563;
}

.form-success {
  display: none;
  padding: 1rem;
  background: #ecfdf5;
  color: #065f46;
  border-radius: 10px;
  margin-bottom: 1rem;
  font-weight: 600;
}

.form-success.visible {
  display: block;
}

/* Footer */
.site-footer {
  position: relative;
  z-index: 3;
  background: var(--primary);
  color: rgba(255, 255, 255, 0.88);
  padding: 3rem 1rem 2rem;
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  gap: 2rem;
}

@media (min-width: 768px) {
  .footer-inner {
    grid-template-columns: 1.2fr 1fr 1fr;
  }
}

.footer-logo {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--white);
  margin-bottom: 0.35rem;
}

.footer-tagline {
  font-size: 0.95rem;
  opacity: 0.85;
  margin: 0;
}

.footer-col h4 {
  font-family: var(--font-title);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent);
  margin: 0 0 0.75rem;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.9);
}

.footer-links a:hover {
  color: var(--accent);
  text-decoration: none;
}

.footer-bottom {
  max-width: 1280px;
  margin: 2rem auto 0;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  text-align: center;
  font-size: 0.85rem;
  opacity: 0.85;
}

/* Legal pages */
.page-legal {
  padding: 2rem 1rem 4rem;
  scroll-margin-top: var(--header-height);
  position: relative;
  z-index: 0;
}

.page-legal-inner {
  max-width: 800px;
  margin: 0 auto;
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  position: relative;
  z-index: 2;
}

.page-legal h1 {
  font-family: var(--font-title);
  color: var(--primary);
  font-size: 1.85rem;
  margin: 0 0 0.25rem;
}

.page-meta {
  font-size: 0.9rem;
  color: #6b7280;
  margin-bottom: 2rem;
}

.page-legal h2 {
  font-family: var(--font-title);
  font-size: 1.15rem;
  color: var(--primary);
  margin: 2rem 0 0.75rem;
}

.page-legal p,
.page-legal li {
  color: #374151;
  font-size: 0.95rem;
}

.page-legal ul {
  padding-left: 1.25rem;
}

.page-legal .legal-header {
  border-bottom: 1px solid #e5e7eb;
  padding-bottom: 1.5rem;
  margin-bottom: 1.5rem;
}

/* Scroll animations */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 0.65s ease,
    transform 0.65s ease;
}

.animate-on-scroll.animate-in {
  opacity: 1;
  transform: translateY(0);
}

.delay-1 {
  transition-delay: 0.1s;
}

.delay-2 {
  transition-delay: 0.2s;
}

.delay-3 {
  transition-delay: 0.3s;
}

/* WhatsApp float */
.wa-float {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 1100;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 28px rgba(37, 211, 102, 0.45);
  transition: transform 0.2s ease;
}

.wa-float:hover {
  transform: scale(1.06);
  text-decoration: none;
}

.wa-float svg {
  width: 30px;
  height: 30px;
  fill: currentColor;
}

.wa-float::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid rgba(37, 211, 102, 0.5);
  animation: pulseWa 2s ease-out infinite;
}

@keyframes pulseWa {
  0% {
    transform: scale(1);
    opacity: 0.8;
  }
  100% {
    transform: scale(1.35);
    opacity: 0;
  }
}

/* ========== Tema espacial + animações + herói 3D ========== */
html.theme-space {
  --nebula-purple: rgba(105, 60, 180, 0.28);
  --nebula-blue: rgba(35, 120, 255, 0.2);
}

.space-bg-fixed {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(ellipse 100% 90% at 5% -5%, var(--nebula-purple) 0%, transparent 55%),
    radial-gradient(ellipse 90% 70% at 95% 85%, var(--nebula-blue) 0%, transparent 48%),
    radial-gradient(circle at 50% 100%, rgba(245, 166, 35, 0.08) 0%, transparent 40%),
    linear-gradient(178deg, #030510 0%, #0b1630 38%, #0a1a3d 100%);
  animation: nebulaPulse 18s ease-in-out infinite alternate;
}

@keyframes nebulaPulse {
  0% {
    opacity: 0.92;
    filter: saturate(100%);
  }
  100% {
    opacity: 1;
    filter: saturate(118%);
  }
}

.space-stars {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.55;
  background-image:
    radial-gradient(1px 1px at 8% 12%, rgba(255, 255, 255, 0.95), transparent),
    radial-gradient(1px 1px at 18% 55%, rgba(255, 255, 255, 0.75), transparent),
    radial-gradient(2px 2px at 32% 18%, rgba(200, 220, 255, 0.9), transparent),
    radial-gradient(1px 1px at 52% 42%, rgba(255, 255, 255, 0.6), transparent),
    radial-gradient(1px 1px at 66% 8%, rgba(255, 255, 255, 0.85), transparent),
    radial-gradient(1px 1px at 78% 66%, rgba(255, 255, 255, 0.5), transparent),
    radial-gradient(1px 1px at 88% 22%, rgba(255, 255, 255, 0.8), transparent),
    radial-gradient(1px 1px at 94% 90%, rgba(255, 255, 255, 0.55), transparent),
    radial-gradient(1px 1px at 12% 82%, rgba(255, 255, 255, 0.7), transparent),
    radial-gradient(1px 1px at 44% 88%, rgba(255, 230, 200, 0.65), transparent),
    radial-gradient(1px 1px at 38% 6%, rgba(255, 255, 255, 0.5), transparent);
  background-size: 100% 100%;
  animation: starsDrift 90s linear infinite;
}

@keyframes starsDrift {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(-2%, -3%, 0);
  }
}

html.theme-space body {
  background: transparent;
  color: #c9d5eb;
}

html.theme-space a {
  color: #74b4ff;
}

html.theme-space a:hover {
  color: #aed4ff;
}

html.theme-space .site-header {
  background:
    linear-gradient(180deg, rgba(14, 20, 45, 0.78), rgba(8, 12, 30, 0.68)),
    linear-gradient(
      118deg,
      rgba(245, 166, 35, 0.07) 0%,
      transparent 35%,
      rgba(74, 158, 255, 0.12) 100%
    );
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: none;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.055),
    0 1px rgba(74, 158, 255, 0.15);
}

html.theme-space .site-header::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(1px 1px at 8% 50%, rgba(255, 255, 255, 0.75), transparent),
    radial-gradient(1px 1px at 18% 30%, rgba(255, 255, 255, 0.45), transparent),
    radial-gradient(1px 1px at 52% 40%, rgba(180, 210, 255, 0.85), transparent),
    radial-gradient(1px 1px at 78% 60%, rgba(255, 255, 255, 0.4), transparent),
    radial-gradient(1px 1px at 92% 55%, rgba(255, 255, 255, 0.6), transparent);
  opacity: 0.45;
  animation: headerMicroStars 20s linear infinite;
}

@keyframes headerMicroStars {
  to {
    transform: translateY(-22px);
  }
}

html.theme-space .site-header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    transparent 4%,
    rgba(245, 166, 35, 0.45) 18%,
    rgba(74, 158, 255, 0.88) 50%,
    rgba(245, 166, 35, 0.45) 82%,
    transparent 96%
  );
  background-size: 200% 100%;
  animation: headerEdgeFlow 6s linear infinite;
  opacity: 0.9;
}

@keyframes headerEdgeFlow {
  from {
    background-position: 0% center;
  }
  to {
    background-position: 200% center;
  }
}

html.theme-space .site-header.scrolled {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 12px 40px rgba(0, 0, 35, 0.55),
    0 4px 0 rgba(74, 158, 255, 0.18);
}

html.theme-space .header-inner {
  position: relative;
  z-index: 1;
}

html.theme-space .logo {
  transition: transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1);
}

html.theme-space .logo:hover {
  text-decoration: none;
  transform: scale(1.03);
}

html.theme-space .logo:hover .logo-gs {
  text-shadow:
    0 0 20px rgba(245, 166, 35, 0.8),
    0 0 36px rgba(245, 166, 35, 0.4);
}

html.theme-space .logo:hover .logo-rest {
  color: #f8fbff;
}

html.theme-space .nav-main .nav-link {
  position: relative;
  color: rgba(232, 240, 255, 0.9);
  text-decoration: none;
  padding: 0.5rem 0.82rem;
  border-radius: 999px;
  transition:
    transform 0.22s ease,
    color 0.2s ease,
    box-shadow 0.25s ease,
    background 0.22s ease;
}

html.theme-space .nav-main .nav-link::after {
  content: "";
  position: absolute;
  left: 14%;
  right: 14%;
  bottom: 6px;
  height: 2px;
  border-radius: 99px;
  background: linear-gradient(90deg, transparent, var(--accent), var(--secondary), transparent);
  transform: scaleX(0);
  opacity: 0;
  transition:
    transform 0.3s ease,
    opacity 0.25s ease;
}

html.theme-space .nav-main .nav-link:hover {
  color: #fff;
  background: rgba(74, 158, 255, 0.12);
  box-shadow: 0 0 24px rgba(26, 115, 232, 0.15);
  transform: translateY(-2px);
}

html.theme-space .nav-main .nav-link:hover::after {
  transform: scaleX(1);
  opacity: 1;
}

html.theme-space .nav-main .nav-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

html.theme-space .nav-main .nav-link.nav-link--active {
  color: #fff;
  background: linear-gradient(
    155deg,
    rgba(74, 158, 255, 0.22) 0%,
    rgba(245, 166, 35, 0.12) 100%
  );
  box-shadow:
    0 0 0 1px rgba(245, 166, 35, 0.35),
    0 0 28px rgba(26, 115, 232, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

html.theme-space .nav-main .nav-link.nav-link--active::after {
  transform: scaleX(1);
  opacity: 0.95;
}

html.theme-space .nav-cta.nav-cta--space {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  transition:
    transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1),
    box-shadow 0.3s ease;
}

html.theme-space .nav-cta.nav-cta--space > span:last-child {
  position: relative;
  z-index: 2;
}

html.theme-space .nav-cta__pulse {
  position: absolute;
  inset: -2px;
  border-radius: var(--radius);
  z-index: 0;
  background: radial-gradient(
    ellipse 90% 80% at 50% 130%,
    rgba(245, 166, 35, 0.45),
    transparent 65%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
  animation: ctaGlow 2.75s ease-in-out infinite;
}

html.theme-space .nav-cta.nav-cta--space:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow:
    0 8px 28px rgba(245, 166, 35, 0.45),
    0 0 0 1px rgba(255, 255, 255, 0.12);
}

html.theme-space .nav-cta.nav-cta--space:hover .nav-cta__pulse {
  opacity: 0.9;
}

html.theme-space .nav-cta.nav-cta--space:active {
  transform: translateY(-1px) scale(1);
}

@keyframes ctaGlow {
  0%,
  100% {
    filter: hue-rotate(0deg);
  }
  50% {
    filter: hue-rotate(14deg);
  }
}

html.theme-space .btn-menu {
  border: 1px solid rgba(74, 158, 255, 0.32);
  background: rgba(8, 16, 40, 0.45);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition:
    transform 0.22s ease,
    box-shadow 0.28s ease,
    border-color 0.22s ease;
}

html.theme-space .btn-menu:hover {
  border-color: rgba(245, 166, 35, 0.55);
  box-shadow:
    0 0 20px rgba(26, 115, 232, 0.25),
    inset 0 1px rgba(255, 255, 255, 0.08);
  transform: scale(1.05);
}

html.theme-space .btn-menu:active {
  transform: scale(0.98);
}

html.theme-space .site-header.menu-open .btn-menu {
  border-color: rgba(245, 166, 35, 0.45);
}

html.theme-space .mobile-panel {
  background:
    radial-gradient(ellipse 140% 100% at 15% -10%, rgba(74, 158, 255, 0.15), transparent 55%),
    linear-gradient(180deg, rgba(5, 8, 20, 0.97), rgba(18, 36, 78, 0.96));
  -webkit-backdrop-filter: saturate(145%) blur(16px);
  backdrop-filter: saturate(145%) blur(16px);
  border-left: none;
}

html.theme-space .mobile-panel .mobile-nav-link {
  color: rgba(245, 248, 255, 0.95);
  text-decoration: none;
  padding: 0.85rem 0.85rem;
  padding-left: 1rem;
  margin: 0.15rem -0.5rem;
  border-radius: var(--radius);
  border-bottom: none;
  transition:
    transform 0.26s cubic-bezier(0.34, 1.56, 0.64, 1),
    padding-left 0.28s ease,
    background 0.25s ease,
    border-color 0.25s ease;
  border: 1px solid transparent;
}

html.theme-space .mobile-panel .mobile-nav-link:hover {
  background: rgba(74, 158, 255, 0.15);
  border-color: rgba(74, 158, 255, 0.3);
  padding-left: 1.35rem;
  transform: translateX(8px);
  color: #fff;
}

html.theme-space .mobile-panel .mobile-nav-link.mobile-nav-link--active {
  background: linear-gradient(90deg, rgba(245, 166, 35, 0.15), transparent 70%);
  border-color: rgba(245, 166, 35, 0.45);
}

html.theme-space .section-title {
  color: #f2f6ff;
  text-shadow:
    0 0 40px rgba(42, 120, 255, 0.28),
    0 2px 0 rgba(5, 8, 20, 0.45);
}

html.theme-space #numeros .section-title {
  text-shadow:
    0 0 32px rgba(245, 166, 35, 0.25),
    0 2px 0 rgba(0, 0, 0, 0.35);
}

html.theme-space .section-lead {
  color: #9eb3d6;
}

html.theme-space #formacao {
  background:
    radial-gradient(ellipse at 70% 0%, rgba(26, 115, 232, 0.12), transparent 50%),
    linear-gradient(185deg, #0d1830 0%, #141f3d 55%, #0f1a38 100%);
}

html.theme-space .card-simple,
html.theme-space .service-card,
html.theme-space .contact-block {
  background: rgba(250, 252, 255, 0.97);
  border: 1px solid rgba(74, 158, 255, 0.12);
}

html.theme-space .card-simple h3,
html.theme-space .service-card h3,
html.theme-space .contact-block h3 {
  color: var(--primary);
}

html.theme-space .card-simple p,
html.theme-space .service-card p {
  color: #4b5563;
}

html.theme-space .service-card:hover {
  border-color: rgba(245, 166, 35, 0.35);
  box-shadow:
    var(--shadow-hover),
    0 0 0 1px rgba(74, 158, 255, 0.15),
    0 24px 60px rgba(26, 115, 232, 0.15);
}

html.theme-space .page-legal-inner {
  border: 1px solid rgba(74, 158, 255, 0.12);
}

html.theme-space #contato input,
html.theme-space #contato select,
html.theme-space #contato textarea {
  border-color: #cbd5e1;
}

/* Hero espacial */
.hero-space {
  min-height: min(92vh, 760px);
  overflow: visible;
  background:
    radial-gradient(ellipse at 72% 45%, rgba(26, 115, 232, 0.22) 0%, transparent 55%),
    linear-gradient(160deg, #040913 0%, #0f2a5e 52%, var(--secondary) 100%);
}

.hero-bg--space {
  opacity: 0.85;
}

.hero-orbit {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(74, 158, 255, 0.2);
  pointer-events: none;
  z-index: 0;
}

.hero-orbit--a {
  width: min(520px, 90vw);
  height: min(520px, 90vw);
  left: -8%;
  top: 50%;
  transform: translateY(-50%);
  animation: orbitGlowA 14s ease-in-out infinite alternate;
}

.hero-orbit--b {
  width: min(320px, 55vw);
  height: min(320px, 55vw);
  right: 5%;
  top: -6%;
  border-color: rgba(245, 166, 35, 0.18);
  animation: orbitGlowB 22s ease-in-out infinite alternate-reverse;
}

@keyframes orbitGlowA {
  0% {
    opacity: 0.35;
    transform: translateY(-50%) rotate(0deg);
  }
  100% {
    opacity: 0.92;
    transform: translateY(-50%) rotate(18deg);
  }
}

@keyframes orbitGlowB {
  0% {
    opacity: 0.35;
    transform: rotate(-6deg);
  }
  100% {
    opacity: 0.85;
    transform: rotate(8deg);
  }
}

.hero-inner--space {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 2.25rem;
  position: relative;
  z-index: 2;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  padding: 0 1rem;
}

.hero-inner--space .hero-content {
  text-align: center;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(174, 212, 255, 0.95);
  background: rgba(8, 20, 45, 0.45);
  border: 1px solid rgba(74, 158, 255, 0.3);
  border-radius: 999px;
  padding: 0.45rem 0.95rem;
  margin: 0 0 1.25rem;
  opacity: 0;
  animation: fadeSlideUp 1s ease 0.05s forwards;
}

.hero-badge__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 14px var(--accent);
  animation: dotPulse 2.2s ease-in-out infinite;
}

@keyframes dotPulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.75;
    transform: scale(0.92);
  }
}

.hero-space h1 {
  text-shadow:
    0 0 52px rgba(26, 115, 232, 0.45),
    0 8px 32px rgba(0, 0, 25, 0.5);
}

.hero-hint {
  margin: 1.35rem 0 0;
  font-size: 0.82rem;
  color: rgba(180, 200, 230, 0.75);
  opacity: 0;
  animation: fadeSlideUp 1s ease 0.7s forwards;
}

.hero-hint__mob {
  display: none;
}

.hero-3d {
  flex: none;
  width: 100%;
  height: clamp(260px, 42vw, 420px);
  max-width: 520px;
  margin: 0 auto;
  border-radius: calc(var(--radius) + 4px);
  background: radial-gradient(circle at 40% 30%, rgba(26, 74, 120, 0.45), transparent 55%),
    rgba(6, 12, 28, 0.55);
  border: 1px solid rgba(74, 158, 255, 0.28);
  box-shadow:
    0 12px 48px rgba(0, 15, 40, 0.55),
    inset 0 0 72px rgba(0, 0, 15, 0.55),
    0 0 0 1px rgba(245, 166, 35, 0.12);
  overflow: hidden;
  touch-action: none;
}

.hero-3d canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

.hero-3d.hero-3d--fallback {
  background:
    radial-gradient(circle at 38% 40%, rgba(245, 166, 35, 0.4), transparent 52%),
    radial-gradient(circle at 62% 55%, rgba(26, 115, 232, 0.35), transparent 50%),
    radial-gradient(circle at 50% 50%, #1c4a92 0%, #0b1836 72%);
  animation: fallbackPulse 5s ease-in-out infinite alternate;
}

@keyframes fallbackPulse {
  from {
    box-shadow:
      inset 0 0 60px rgba(0, 0, 0, 0.5),
      0 0 40px rgba(26, 115, 232, 0.2);
  }
  to {
    box-shadow:
      inset 0 0 72px rgba(10, 20, 50, 0.55),
      0 0 56px rgba(245, 166, 35, 0.18);
  }
}

@media (min-width: 1024px) {
  .hero-inner--space {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 2.5rem;
  }

  .hero-inner--space .hero-content {
    flex: 1;
    text-align: left;
    margin: 0;
    max-width: 560px;
  }

  .hero-inner--space .hero-actions {
    justify-content: flex-start;
  }

  .hero-inner--space .hero-3d {
    flex: 1;
    max-width: none;
    width: clamp(340px, 44%, 560px);
    height: clamp(340px, 36vw, 460px);
    margin: 0;
  }

  .hero-hint__desk {
    display: inline;
  }

  .hero-hint__mob {
    display: none !important;
  }
}

@media (max-width: 1023px) {
  .hero-hint__desk {
    display: none;
  }

  .hero-hint__mob {
    display: inline !important;
  }
}


/* Ícones espaciais (SVG), sprite e cenário flutuante */
.space-sprite-sheet {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
  clip-path: inset(50%);
}

#main,
#legal-main {
  position: relative;
}

#main > :not(.space-floaties),
#legal-main > :not(.space-floaties) {
  position: relative;
  z-index: 3;
}

.space-icon {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  color: var(--secondary);
}

.card-simple .card-icon.space-icon {
  margin-bottom: 0.65rem;
}

.service-card > .service-icon.space-icon {
  margin-bottom: 0.5rem;
  display: block;
}

html.theme-space .space-icon {
  color: #4895ff;
}

.space-icon__svg {
  width: 44px;
  height: 44px;
  display: block;
}

.space-icon__svg--lg {
  width: 52px;
  height: 52px;
}

.space-icon__svg use {
  pointer-events: none;
}

.space-floaties {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: visible;
}

.space-floaties--page {
  opacity: 0.5;
}

.space-floaties--page .space-floaties__planetas {
  opacity: 0.55;
}

.space-floaties__galaxy {
  position: absolute;
  top: 8%;
  left: max(-140px, -12vw);
  width: min(380px, 58vw);
  height: auto;
  opacity: 0.42;
  animation: galaxySpin 220s linear infinite;
}

@keyframes galaxySpin {
  to {
    transform: rotate(360deg);
  }
}

.space-floaties__et {
  position: absolute;
  bottom: 12%;
  left: min(4vw, 1.75rem);
  width: clamp(76px, 11vw, 104px);
  height: auto;
  filter: drop-shadow(0 0 22px rgba(148, 219, 185, 0.22));
  animation: bobEt 11s ease-in-out infinite;
}

.space-floaties__nave {
  position: absolute;
  top: clamp(140px, 22vh, 220px);
  right: clamp(14px, 5vw, 56px);
  width: clamp(52px, 8vw, 76px);
  height: auto;
  animation: glideNave 14s ease-in-out infinite alternate;
}

.space-floaties__planetas {
  position: absolute;
  bottom: 16%;
  right: clamp(8px, 4vw, 40px);
  width: clamp(112px, 22vw, 160px);
  height: clamp(72px, 14vw, 104px);
  background:
    radial-gradient(circle at 18% 55%, rgba(210, 100, 100, 0.95) 0 13%, transparent 14%),
    radial-gradient(circle at 54% 32%, rgba(110, 180, 255, 0.95) 0 15%, transparent 16%),
    radial-gradient(circle at 82% 66%, rgba(245, 166, 35, 0.92) 0 11%, transparent 12%);
  opacity: 0.82;
  animation: bobPlanets 10s ease-in-out infinite alternate;
}

@keyframes bobEt {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-14px);
  }
}

@keyframes glideNave {
  from {
    transform: translate(-6px, -4px) rotate(-4deg);
  }
  to {
    transform: translate(10px, 10px) rotate(6deg);
  }
}

@keyframes bobPlanets {
  from {
    transform: scale(0.94);
    opacity: 0.68;
  }
  to {
    transform: scale(1);
    opacity: 0.9;
  }
}

@media (prefers-reduced-motion: reduce) {
  .space-bg-fixed,
  .space-stars {
    animation: none !important;
  }

  html.theme-space .site-header::before,
  html.theme-space .site-header::after {
    animation: none !important;
  }

  html.theme-space .nav-cta__pulse {
    animation: none !important;
  }

  html.theme-space .logo:hover {
    transform: none;
  }

  html.theme-space .nav-main .nav-link:hover {
    transform: none;
  }

  html.theme-space .mobile-panel .mobile-nav-link:hover {
    transform: none;
  }

  html.theme-space .nav-cta.nav-cta--space:hover {
    transform: none;
  }

  html.theme-space .btn-menu:hover {
    transform: none;
  }

  .space-floaties__galaxy,
  .space-floaties__et,
  .space-floaties__nave,
  .space-floaties__planetas {
    animation: none !important;
  }

  html.theme-space .hero-orbit--a,
  html.theme-space .hero-orbit--b {
    animation: none !important;
  }

  .hero-badge__dot {
    animation: none !important;
  }

  .hero-space h1,
  .subtitle,
  .hero-actions,
  .hero-badge,
  .hero-hint {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }

  .hero-3d.hero-3d--fallback {
    animation: none !important;
  }
}
