/* ===================================
   BLOG CAROUSEL - PROFESSIONAL DESIGN
   =================================== */

/* Blog Section Container */
#blogue {
  background: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 100%);
  position: relative;
  overflow: hidden;
}

#blogue::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 30% 20%, rgba(150, 185, 207, 0.03) 0%, transparent 50%);
  pointer-events: none;
}

/* Blog Header */
.blog-header {
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
  z-index: 2;
}

.blog-header .eyebrow {
  display: inline-block;
  padding: 0.5rem 1.5rem;
  background: rgba(150, 185, 207, 0.1);
  border: 1px solid rgba(150, 185, 207, 0.2);
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 1.5rem;
}

.blog-header h2 {
  font-size: 3rem;
  font-weight: 700;
  background: linear-gradient(135deg, #ffffff 0%, #e0e0e0 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1rem;
}

.blog-subtitle {
  font-size: 1.2rem;
  color: var(--color-gray-light);
  max-width: 600px;
  margin: 0 auto;
}

/* Blog Carousel Container */
.blog-carousel {
  position: relative;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 4rem;
}

@media (max-width: 768px) {
  .blog-carousel {
    padding: 0 1rem !important;
    margin: 0 !important;
  }
}

.blog-carousel-container {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
}

@media (max-width: 768px) {
  .blog-carousel-container {
    border-radius: 0 !important;
    overflow: visible !important;
  }
}

.blog-carousel-track {
  display: flex;
  transition: transform 0.8s ease;
  gap: 2rem;
  padding: 1rem 0;
  width: auto;
  will-change: transform;
}

@media (max-width: 768px) {
  .blog-carousel-track {
    flex-direction: column !important;
    gap: 1.5rem !important;
    padding: 0 !important;
    width: 100% !important;
    transform: none !important;
  }
}

/* Blog Cards in Carousel - ALL IDENTICAL SIZES */
.blog-card {
  flex: 0 0 400px !important;
  width: 400px !important;
  min-width: 400px !important;
  max-width: 400px !important;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  backdrop-filter: blur(10px);
  cursor: pointer;
  height: 500px !important;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

/* Featured styling - SAME SIZE, different background only */
.blog-card.featured {
  background: rgba(150, 185, 207, 0.08);
  border-color: rgba(150, 185, 207, 0.2);
}

/* ===== MOBILE: SEM CARROSSEL - GRID VERTICAL ===== */
@media (max-width: 768px) {
  .blog-card {
    flex: 0 0 calc(100% - 2rem) !important;
    width: calc(100% - 2rem) !important;
    min-width: calc(100% - 2rem) !important;
    max-width: calc(100% - 2rem) !important;
    height: auto !important;
    margin: 0 1rem !important;
  }

  /* Mostrar apenas 5 cards (1 conjunto) em mobile */
  .blog-card:nth-child(n + 6) {
    display: none !important;
  }
}

/* ALL images same height */
.blog-image {
  position: relative;
  height: 200px !important;
  min-height: 200px !important;
  max-height: 200px !important;
  overflow: hidden;
  background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
  box-sizing: border-box;
}

/* ALL titles same size */
.blog-content h3 {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--color-white);
  line-height: 1.3;
  margin-bottom: 1rem;
  transition: color 0.3s ease;
}

.blog-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(150, 185, 207, 0.05) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.blog-card:hover::before {
  opacity: 1;
}

.blog-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: rgba(150, 185, 207, 0.3);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.blog-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  filter: brightness(0.9);
}

.blog-card:hover .blog-image img {
  transform: scale(1.08);
  filter: brightness(1);
}

/* Blog Content */
.blog-content {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.blog-date {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-accent);
  margin-bottom: 1rem;
  padding: 0.4rem 1rem;
  background: rgba(150, 185, 207, 0.1);
  border-radius: 20px;
  width: fit-content;
}

.blog-card:hover .blog-content h3 {
  color: var(--color-accent);
}

.blog-content p {
  color: var(--color-gray-light);
  line-height: 1.6;
  margin-bottom: 1rem;
  flex: 1;
  font-size: 0.9rem;
}

.blog-card.featured .blog-date::before {
  content: "⭐";
  margin-right: 0.5rem;
}

/* Carousel Navigation Arrows */
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  background: rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
  backdrop-filter: blur(10px);
}

@media (max-width: 768px) {
  .carousel-arrow {
    display: none !important;
  }
}

.carousel-arrow:hover {
  background: var(--color-accent);
  border-color: var(--color-accent);
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 8px 25px rgba(150, 185, 207, 0.3);
}

.carousel-arrow:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: translateY(-50%);
}

.carousel-arrow svg {
  width: 24px;
  height: 24px;
}

.carousel-prev {
  left: 0;
}

.carousel-next {
  right: 0;
}

/* Carousel Dots */
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 2rem;
  position: relative;
  z-index: 2;
}

@media (max-width: 768px) {
  .carousel-dots {
    display: none !important;
  }
}
}

.carousel-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.carousel-dot::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--color-accent);
  border-radius: 50%;
  transform: scale(0);
  transition: transform 0.3s ease;
}

.carousel-dot.active::after {
  transform: scale(1);
}

.carousel-dot:hover {
  transform: scale(1.2);
}



/* Responsive Design */
@media (max-width: 1200px) {
  .blog-carousel {
    padding: 0 3rem;
  }
  
  .blog-card,
  .blog-card.featured {
    flex: 0 0 350px;
    height: 480px;
  }
  
  .blog-image {
    height: 190px;
  }
}

@media (max-width: 768px) {
  .blog-carousel {
    padding: 0 1rem;
  }
  
  .blog-carousel-track {
    gap: 1.25rem;
  }
  
  .blog-card,
  .blog-card.featured {
    flex: 0 0 300px !important;
    width: 300px !important;
    min-width: 300px !important;
    max-width: 300px !important;
    height: 450px !important;
  }
  
  .blog-image {
    height: 180px !important;
  }
  
  .blog-content {
    padding: 1.25rem;
  }
  
  .blog-content h3 {
    font-size: 1.2rem;
  }
  
  .carousel-arrow {
    width: 40px;
    height: 40px;
  }
  
  .carousel-arrow svg {
    width: 20px;
    height: 20px;
  }
  
  .blog-header h2 {
    font-size: 2.5rem;
  }
}

@media (max-width: 480px) {
  .blog-carousel {
    padding: 0;
    overflow: hidden;
  }
  
  .blog-carousel-container {
    overflow: visible;
  }
  
  .blog-carousel-track {
    gap: 1rem;
    padding: 0 1rem;
  }
  
  .blog-card,
  .blog-card.featured {
    flex: 0 0 85vw !important;
    width: 85vw !important;
    max-width: 320px !important;
    min-width: 280px !important;
    height: 420px !important;
  }
  
  .blog-image {
    height: 160px !important;
  }
  
  .blog-content {
    padding: 1rem;
  }
  
  .blog-content h3 {
    font-size: 1.1rem;
    line-height: 1.4;
  }
  
  .blog-content p {
    font-size: 0.85rem;
  }
  
  .blog-date {
    font-size: 0.7rem;
    padding: 0.3rem 0.8rem;
  }
  
  .carousel-arrow {
    display: none;
  }
  
  .blog-header h2 {
    font-size: 2rem;
  }
  
  .blog-subtitle {
    font-size: 1rem;
  }
  
  .carousel-dots {
    margin-top: 1.5rem;
  }
  
  .carousel-dot {
    width: 10px;
    height: 10px;
  }
}

/* Touch/Swipe Support */
.blog-carousel-track {
  cursor: grab;
}

.blog-carousel-track:active {
  cursor: grabbing;
}

.blog-carousel-track.dragging {
  transition: none;
}

/* Loading State */
.blog-carousel.loading .blog-card {
  opacity: 0.5;
  pointer-events: none;
}

.blog-carousel.loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  border: 3px solid rgba(150, 185, 207, 0.2);
  border-top: 3px solid var(--color-accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  z-index: 100;
}

@keyframes spin {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Accessibility */
.carousel-arrow:focus,
.carousel-dot:focus {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* Performance Optimizations */
.blog-card {
  will-change: transform;
  backface-visibility: hidden;
}

.blog-image img {
  will-change: transform;
  backface-visibility: hidden;
}