/* ============================================
   RESET E BASE - OTIMIZADO
   ============================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  height: 100%;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #0a1628 !important;
  color: #fff !important;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Remover elementos do tema */
.header, 
header.header,
.navbar,
.header-logo-fixed,
.old-header,
.navigation,
.page-header,
header,
nav {
  display: none !important;
}

body > h1:first-of-type,
body > h2:first-of-type,
.page-title,
.main-title,
body > img,
body > a > img,
.footer-logo,
footer img,
.bottom-logo {
  display: none !important;
}

/* ============================================
   LOADING OVERLAY - OTIMIZADO
   ============================================ */
#page-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #0a1628;
  z-index: 99999;
  display: flex !important;
  align-items: center;
  justify-content: center;
  transition: opacity 0.3s ease;
}

#page-overlay.incoming {
  opacity: 1;
  pointer-events: all;
}

.loader-wrapper-outer,
.loader-wrapper-inner {
  display: flex;
  align-items: center;
  justify-content: center;
}

.lds-double-ring {
  display: inline-block;
  width: 80px;
  height: 80px;
  position: relative;
}

.lds-double-ring div {
  box-sizing: border-box;
  display: block;
  position: absolute;
  width: 64px;
  height: 64px;
  margin: 8px;
  border: 8px solid #2563eb;
  border-radius: 50%;
  animation: lds-ring 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
  border-color: #2563eb transparent transparent transparent;
}

.lds-double-ring div:nth-child(1) {
  animation-delay: -0.45s;
}

.lds-double-ring div:nth-child(2) {
  animation-delay: -0.3s;
}

.lds-double-ring div:nth-child(3) {
  animation-delay: -0.15s;
}

@keyframes lds-ring {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ============================================
   LOGO - OTIMIZADO
   ============================================ */
.simple-logo {
  position: fixed;
  top: 25px;
  left: 35px;
  z-index: 1000;
  transition: all 0.3s ease;
}

.simple-logo a {
  display: flex;
  align-items: center;
  text-decoration: none;
  transition: transform 0.2s ease;
}

.simple-logo a:hover {
  transform: scale(1.05);
}

.simple-logo img {
  height: 55px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
}

.simple-logo.scrolled {
  top: 18px;
}

.simple-logo.scrolled img {
  height: 48px;
}

.page-content {
  padding-top: 120px;
}

/* ============================================
   BACKGROUND - SIMPLIFICADO
   ============================================ */
.bg-simple {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  background: 
    radial-gradient(circle at 20% 20%, rgba(59, 130, 246, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(37, 99, 235, 0.15) 0%, transparent 50%);
}

/* ============================================
   MAIN - OTIMIZADO
   ============================================ */
.page-main {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 0;
}

.page-container {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  width: 100%;
}

/* ============================================
   INTRO SECTION - OTIMIZADO
   ============================================ */
.intro-section {
  text-align: center;
  margin-bottom: 60px;
}

.intro-section h1 {
  font-size: 3.5rem;
  font-weight: 800;
  background: linear-gradient(135deg, #60a5fa 0%, #3b82f6 50%, #2563eb 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 20px;
  line-height: 1.2;
}

.intro-section p {
  font-size: 1.25rem;
  color: rgba(255, 255, 255, 0.7);
  max-width: 600px;
  margin: 0 auto;
}

/* ============================================
   SERVICE SELECTOR - OTIMIZADO
   ============================================ */
.service-selector {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  padding: 50px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.selector-head {
  text-align: center;
  margin-bottom: 40px;
}

.selector-head h3 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: #fff;
}

.selector-desc {
  color: rgba(255, 255, 255, 0.6);
  font-size: 1.05rem;
}

/* ============================================
   SERVICE GRID - OTIMIZADO
   ============================================ */
.service-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.service-box {
  background: rgba(255, 255, 255, 0.03);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 30px 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.service-box:hover {
  transform: translateY(-6px);
  border-color: rgba(59, 130, 246, 0.5);
  background: rgba(59, 130, 246, 0.1);
  box-shadow: 0 8px 24px rgba(59, 130, 246, 0.3);
}

.service-box.selected {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  border-color: #3b82f6;
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 12px 32px rgba(59, 130, 246, 0.5);
}

.service-box i {
  font-size: 3rem;
  margin-bottom: 15px;
  display: block;
  transition: transform 0.2s ease;
  color: #60a5fa;
}

.service-box:hover i {
  transform: scale(1.1);
}

.service-box.selected i {
  color: #fff !important;
  animation: iconPulse 0.5s ease;
}

@keyframes iconPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

.service-box p {
  font-size: 1.05rem;
  font-weight: 600;
  color: #fff;
  margin: 0;
}

.popular-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 12px;
  text-transform: uppercase;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
}

/* ============================================
   NEXT BUTTON - OTIMIZADO
   ============================================ */
.btn-next {
  width: 100%;
  padding: 18px;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 14px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 1.15rem;
  font-weight: 700;
  cursor: not-allowed;
  transition: all 0.2s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-family: inherit;
}

.btn-next.active {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  border-color: transparent;
  color: #fff;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(59, 130, 246, 0.4);
}

.btn-next.active:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(59, 130, 246, 0.6);
}

.btn-next i {
  margin-left: 10px;
  transition: transform 0.2s ease;
}

.btn-next.active:hover i {
  transform: translateX(5px);
}

.note-text {
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.95rem;
  margin-top: 20px;
  font-weight: 400;
}

/* ============================================
   WHATSAPP - OTIMIZADO
   ============================================ */
.whatsapp-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.5);
  z-index: 1000;
  transition: all 0.2s ease;
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 24px rgba(37, 211, 102, 0.7);
}

.whatsapp-btn i {
  color: #fff;
  font-size: 2rem;
}

/* ============================================
   POPUP - OTIMIZADO
   ============================================ */
.popup-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.75);
  z-index: 9999;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(4px);
}

.popup-box {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  padding: 40px 30px;
  max-width: 450px;
  width: 90%;
  border-radius: 20px;
  text-align: center;
  position: relative;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  animation: popupShow 0.3s ease;
  border: 1px solid rgba(59, 130, 246, 0.3);
  color: #0a1628;
}

@keyframes popupShow {
  from {
    transform: scale(0.9);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.popup-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  color: #fff;
  border: none;
  font-size: 20px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
  font-family: inherit;
}

.popup-close:hover {
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  transform: rotate(90deg);
}

/* ============================================
   FOOTER - OTIMIZADO
   ============================================ */
.page-footer {
  position: relative;
  z-index: 1;
  padding: 40px 0;
  text-align: center;
}

.footer-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  max-width: 400px;
  margin: 0 auto;
  padding: 0 20px;
}

.footer-img {
  height: 50px;
  width: auto;
  max-width: 200px;
  object-fit: contain;
}

.footer-info {
  text-align: center;
}

.footer-brand {
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 6px;
}

.footer-copy {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.6);
  margin: 0;
}

/* ============================================
   RESPONSIVE - OTIMIZADO
   ============================================ */
@media (min-width: 768px) {
  .service-list {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 24px;
  }
  
  .intro-section h1 {
    font-size: 4.5rem;
  }
}

@media (max-width: 767px) {
  .page-main {
    padding: 30px 0;
  }

  .page-container {
    padding: 15px;
  }

  .intro-section {
    margin-bottom: 40px;
  }

  .intro-section h1 {
    font-size: 2.5rem;
  }

  .intro-section p {
    font-size: 1.1rem;
  }

  .service-selector {
    padding: 30px 20px;
    border-radius: 20px;
  }

  .selector-head h3 {
    font-size: 1.6rem;
  }

  .service-list {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
  }

  .service-box {
    padding: 25px 15px;
  }

  .service-box i {
    font-size: 2.5rem;
  }

  .btn-next {
    padding: 16px;
    font-size: 1rem;
  }

  .whatsapp-btn {
    width: 56px;
    height: 56px;
    bottom: 24px;
    right: 24px;
  }

  .whatsapp-btn i {
    font-size: 1.8rem;
  }

  .popup-box {
    padding: 32px 24px;
  }

  .simple-logo {
    top: 20px;
    left: 20px;
  }

  .simple-logo img {
    height: 50px;
    max-width: 200px;
  }

  .simple-logo.scrolled {
    top: 15px;
  }

  .simple-logo.scrolled img {
    height: 42px;
  }

  .page-content {
    padding-top: 100px;
  }
}

@media (max-width: 480px) {
  .intro-section h1 {
    font-size: 2rem;
  }

  .intro-section p {
    font-size: 1rem;
  }

  .service-selector {
    padding: 25px 15px;
  }

  .selector-head h3 {
    font-size: 1.4rem;
  }

  .service-list {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 12px;
  }

  .service-box {
    padding: 20px 12px;
  }

  .service-box i {
    font-size: 2.2rem;
  }

  .simple-logo img {
    height: 45px;
    max-width: 170px;
  }

  .simple-logo.scrolled img {
    height: 38px;
  }

  .footer-img {
    height: 45px;
  }

  .footer-brand {
    font-size: 1.05rem;
  }

  .footer-copy {
    font-size: 0.85rem;
  }

  .footer-box {
    gap: 15px;
    padding: 0 15px;
  }

  .page-footer {
    padding: 25px 0;
  }
}

/* ============================================
   PERFORMANCE - WILL-CHANGE
   ============================================ */
.service-box,
.btn-next,
.whatsapp-btn {
  will-change: transform;
}

/* ============================================
   ACESSIBILIDADE
   ============================================ */
button:focus-visible,
a:focus-visible {
  outline: 2px solid #60a5fa;
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}