/* VERSÃO FINAL ATUALIZADA - SERVIÇOS MODERNO */
:root {
  --bronze: #d4a017;
  --bronze-dark: #b8860b;
  --bronze-light: #f4d03f;
  --bronze-glow: rgba(212, 160, 23, 0.3);
  --bg-dark: #0a0a0a;
  --bg-darker: #000000;
  --text-light: #ffffff;
  --text-gray: #b0b0b0;
}

/* SEÇÃO PRINCIPAL */
.servicos-section {
  padding: 80px 20px;
  background: #111111;
  position: relative;
  overflow: hidden;
}

/* BORDA DOURADA NO TOPO - MAIS ESTICADA */
.servicos-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--bronze-dark) 15%,
    var(--bronze) 30%,
    var(--bronze-light) 50%,
    var(--bronze) 70%,
    var(--bronze-dark) 85%,
    transparent 100%
  );
  z-index: 1;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* CABEÇALHO */
.servicos-header {
  text-align: center;
  margin-bottom: 60px;
  position: relative;
}

.servicos-titulo {
  font-size: 3rem;
  font-weight: 800;
  color: var(--text-light);
  margin-bottom: 15px;
  line-height: 1.2;
}

/* CORREÇÃO AQUI: graditude-text (igual ao seu HTML) */
.graditude-text {
  background: linear-gradient(
    90deg,
    var(--bronze-light),
    #ffd700,
    var(--bronze)
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  position: relative;
  font-weight: 900;
  text-shadow: 0 4px 20px rgba(244, 208, 63, 0.3);
}

.servicos-subtitulo {
  color: var(--text-gray);
  font-size: 1.2rem;
  max-width: 500px;
  margin: 0 auto;
  line-height: 1.6;
  font-weight: 300;
  letter-spacing: 0.5px;
}

/* CARROSSEL */
.carrossel-html {
  max-width: 1100px;
  margin: 0 auto;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.8);
  border: 1px solid rgba(212, 160, 23, 0.1);
}

/* BORDA DOURADA NO CARROSSEL - MAIS ESTICADA */
.carrossel-html::before {
  content: "";
  position: absolute;
  top: -1px;
  left: -1px;
  right: -1px;
  bottom: -1px;
  background: linear-gradient(
    45deg,
    transparent,
    var(--bronze-glow),
    var(--bronze-light),
    var(--bronze-glow),
    transparent
  );
  border-radius: 21px;
  z-index: -1;
  animation: borderPulse 3s infinite;
  background-size: 200% 200%;
}

@keyframes borderPulse {
  0%,
  100% {
    opacity: 0.3;
    background-position: 0% 0%;
  }
  50% {
    opacity: 0.8;
    background-position: 100% 100%;
  }
}

.carrossel-wrapper {
  position: relative;
  width: 100%;
  height: 600px;
  overflow: hidden;
}

/* SLIDES */
.carrossel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1;
}

.carrossel-slide.active {
  opacity: 1;
  z-index: 2;
}

.carrossel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 8s ease;
  filter: brightness(1.05) contrast(1.05);
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

.carrossel-slide.active img {
  transform: scale(1.05);
}

/* OVERLAY ELEGANTE */
.slide-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.95) 0%,
    rgba(0, 0, 0, 0.8) 30%,
    rgba(0, 0, 0, 0.5) 60%,
    transparent 100%
  );
  padding: 50px 40px 30px;
  z-index: 3;
}

.slide-conteudo {
  max-width: 600px;
}

.slide-conteudo h3 {
  color: var(--text-light);
  font-size: 2.2rem;
  font-weight: 700;
  margin-bottom: 8px;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.slide-conteudo p {
  color: var(--bronze-light);
  font-size: 1.1rem;
  font-weight: 400;
  opacity: 0.95;
}

/* BOTÕES DE NAVEGAÇÃO (ESCONDIDOS POR PADRÃO) */
.nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 1px solid rgba(212, 160, 23, 0.3);
  background: rgba(0, 0, 0, 0.5);
  color: var(--bronze-light);
  font-size: 24px;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  backdrop-filter: blur(5px);
  display: none; /* Escondido por padrão */
}

.nav-btn:hover {
  background: var(--bronze);
  color: var(--bg-dark);
  border-color: var(--bronze);
  transform: translateY(-50%) scale(1.1);
}

.prev-btn {
  left: 25px;
}
.next-btn {
  right: 25px;
}

/* INDICADORES - POSICIONAMENTO DESKTOP */
.carrossel-indicators {
  position: absolute;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
  padding: 10px 15px;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 25px;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(212, 160, 23, 0.1);
  max-width: 90%;
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: thin;
  scrollbar-color: var(--bronze) transparent;
}

/* Scrollbar personalizada */
.carrossel-indicators::-webkit-scrollbar {
  height: 4px;
}

.carrossel-indicators::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 2px;
}

.carrossel-indicators::-webkit-scrollbar-thumb {
  background: var(--bronze);
  border-radius: 2px;
}

.carrossel-indicators::-webkit-scrollbar-thumb:hover {
  background: var(--bronze-light);
}

/* Indicadores individuais */
.indicator {
  width: 10px;
  height: 10px;
  min-width: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(212, 160, 23, 0.2);
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

/* Indicador ativo */
.indicator.active {
  background: var(--bronze);
  transform: scale(1.3);
  box-shadow: 0 0 10px var(--bronze-glow);
  animation: pulseIndicator 2s infinite;
}

@keyframes pulseIndicator {
  0%,
  100% {
    box-shadow: 0 0 5px var(--bronze-glow);
  }
  50% {
    box-shadow: 0 0 15px var(--bronze-glow);
  }
}

.indicator:hover:not(.active) {
  background: var(--bronze-dark);
  transform: scale(1.2);
}

/* EFEITO DE LOADING SUAVE */
.carrossel-slide::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #111 25%, #222 50%, #111 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
  z-index: 0;
  opacity: 0;
}

.carrossel-slide.active::before {
  animation: none;
  opacity: 0;
}

@keyframes loading {
  0% {
    background-position: 200% 0;
    opacity: 0.3;
  }
  100% {
    background-position: -200% 0;
    opacity: 0.3;
  }
}

/* ANIMAÇÃO DE ENTRADA */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.servicos-header {
  animation: fadeIn 0.8s ease-out;
}

.carrossel-html {
  animation: fadeIn 0.8s ease-out 0.2s both;
}

/* DESKTOP GRANDE */
@media (min-width: 1400px) {
  .carrossel-wrapper {
    max-height: 700px;
  }

  .nav-btn {
    display: flex;
    opacity: 0.6;
  }

  .nav-btn:hover {
    opacity: 1;
  }
}

/* RESPONSIVIDADE */
@media (max-width: 1200px) {
  .carrossel-wrapper {
    height: 550px;
  }
}

@media (max-width: 992px) {
  .servicos-section {
    padding: 60px 20px;
  }

  .servicos-titulo {
    font-size: 2.5rem;
  }

  .carrossel-wrapper {
    height: 500px;
  }

  .slide-conteudo h3 {
    font-size: 1.8rem;
  }
}

/* MOBILE - CENTRALIZADO E AJUSTADO */
@media (max-width: 768px) {
  .servicos-section {
    padding: 50px 15px;
  }

  .servicos-titulo {
    font-size: 2.2rem;
    text-align: center;
  }

  .servicos-subtitulo {
    font-size: 1.1rem;
    padding: 0 10px;
    text-align: center;
  }

  .carrossel-wrapper {
    height: 450px;
    border-radius: 15px;
    position: relative;
    padding-bottom: 60px;
  }

  .carrossel-html {
    border-radius: 15px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.7);
    overflow: visible;
  }

  .slide-overlay {
    padding: 25px 15px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(
      to top,
      rgba(0, 0, 0, 0.98) 0%,
      rgba(0, 0, 0, 0.85) 40%,
      rgba(0, 0, 0, 0.6) 80%,
      rgba(0, 0, 0, 0.3) 100%
    );
    bottom: 0;
  }

  .slide-conteudo {
    max-width: 100%;
    text-align: center;
  }

  .slide-conteudo h3 {
    font-size: 1.6rem;
    line-height: 1.3;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
  }

  .slide-conteudo p {
    font-size: 1rem;
    line-height: 1.4;
    max-width: 90%;
    margin: 0 auto;
  }

  .nav-btn {
    display: none;
  }

  /* INDICADORES NO MOBILE - ABAIXO DA FOTO */
  .carrossel-indicators {
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    bottom: auto;
    transform: translateX(-50%);
    padding: 10px 15px;
    gap: 10px;
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(212, 160, 23, 0.3);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    max-width: 85%;
  }

  .indicator {
    width: 12px;
    height: 12px;
    min-width: 12px;
  }

  .indicator.active {
    transform: scale(1.5);
  }

  .carrossel-wrapper {
    cursor: grab;
    user-select: none;
  }

  .carrossel-wrapper:active {
    cursor: grabbing;
  }
}

/* AJUSTES ESPECÍFICOS PARA TELAS PEQUENAS */
@media (max-width: 576px) {
  .servicos-titulo {
    font-size: 1.8rem;
  }

  .servicos-subtitulo {
    font-size: 1rem;
  }

  .carrossel-wrapper {
    height: 380px;
    padding-bottom: 55px;
  }

  .slide-overlay {
    padding: 20px 12px 15px;
  }

  .slide-conteudo h3 {
    font-size: 1.4rem;
  }

  .slide-conteudo p {
    font-size: 0.9rem;
  }

  .carrossel-indicators {
    top: calc(100% + 8px);
    padding: 8px 12px;
    gap: 8px;
  }

  .indicator {
    width: 10px;
    height: 10px;
    min-width: 10px;
  }

  .indicator.active {
    transform: scale(1.4);
  }
}

/* MELHORIA EXTREMA MOBILE */
@media (max-width: 400px) {
  .servicos-section {
    padding: 40px 10px;
  }

  .servicos-titulo {
    font-size: 1.6rem;
  }

  .servicos-subtitulo {
    font-size: 0.95rem;
  }

  .carrossel-wrapper {
    height: 320px;
    padding-bottom: 50px;
  }

  .slide-overlay {
    padding: 15px 10px 12px;
  }

  .slide-conteudo h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
  }

  .slide-conteudo p {
    font-size: 0.85rem;
    line-height: 1.3;
  }

  .carrossel-indicators {
    top: calc(100% + 5px);
    padding: 6px 10px;
    gap: 6px;
    max-width: 80%;
  }

  .indicator {
    width: 8px;
    height: 8px;
    min-width: 8px;
  }

  .indicator.active {
    transform: scale(1.3);
  }
}

/* Para muitos indicadores */
.carrossel-indicators.many-indicators {
  gap: 6px;
  padding: 8px 12px;
}

.carrossel-indicators.many-indicators .indicator {
  width: 8px;
  height: 8px;
  min-width: 8px;
}

/* MELHORIA DE PERFORMANCE */
@media (prefers-reduced-motion: reduce) {
  .carrossel-slide {
    transition: opacity 0.3s ease;
  }

  .carrossel-slide.active img {
    transform: none;
  }

  .indicator.active {
    animation: none;
  }

  .carrossel-html::before {
    animation: none;
  }

  .servicos-header,
  .carrossel-html {
    animation: none;
  }
}

/* MELHORIA DE ACESSIBILIDADE */
.indicator:focus {
  outline: 2px solid var(--bronze-light);
  outline-offset: 2px;
}

.nav-btn:focus {
  outline: 2px solid var(--bronze-light);
  outline-offset: 2px;
}
