/* ===================================
   ESTILOS ESPECIFICOS - PAGINA BLOG
   =================================== */

/* ===================================
   HERO BLOG — Bold Editorial
   =================================== */
.blog-hero {
  background: #0e0e12;
  padding: 100px 20px 80px;
  text-align: center;
  color: #fff;
  position: relative;
  overflow: hidden;
  font-family: 'Montserrat', sans-serif;
}

/* Ambient orange glow */
.blog-hero::before {
  content: '';
  position: absolute;
  top: -20%;
  left: 50%;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(255,106,0,0.12) 0%, transparent 65%);
  transform: translateX(-50%);
  pointer-events: none;
}

/* Decorative geometric shapes */
.blog-hero__geo {
  position: absolute;
  pointer-events: none;
  border: 2px solid rgba(255,106,0,0.18);
  border-radius: 4px;
}

.blog-hero__geo--1 {
  width: 120px;
  height: 120px;
  top: 15%;
  left: 6%;
  transform: rotate(35deg);
  animation: blogGeoFloat 8s ease-in-out infinite;
}

.blog-hero__geo--2 {
  width: 60px;
  height: 60px;
  bottom: 18%;
  right: 8%;
  border-radius: 50%;
  border-color: rgba(255,106,0,0.14);
  animation: blogGeoFloat 6s ease-in-out 1s infinite reverse;
}

.blog-hero__geo--3 {
  width: 40px;
  height: 40px;
  top: 28%;
  right: 14%;
  transform: rotate(60deg);
  border-color: rgba(255,106,0,0.10);
  animation: blogGeoFloat 10s ease-in-out 0.5s infinite;
}

@keyframes blogGeoFloat {
  0%, 100% { transform: translateY(0) rotate(35deg); opacity: 1; }
  50%      { transform: translateY(-18px) rotate(40deg); opacity: 0.6; }
}

/* Inner container */
.blog-hero__inner {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
}

/* Title block — slide-up on load */
.blog-hero__title {
  margin: 0;
  line-height: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  animation: blogHeroSlideUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* "Blog" — huge outlined / stroke text */
.blog-hero__outline {
  display: block;
  font-size: clamp(72px, 12vw, 140px);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: transparent;
  -webkit-text-stroke: 2px rgba(255,106,0,0.55);
  paint-order: stroke fill;
  line-height: 0.9;
}

/* "Vem Pra Uno" — solid bold filled */
.blog-hero__filled {
  display: block;
  font-size: clamp(32px, 5.5vw, 62px);
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #ff6a00 30%, #ff9a40 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.15;
}

/* Subtitle */
.blog-hero__sub {
  font-size: clamp(14px, 1.6vw, 17px);
  font-weight: 400;
  color: rgba(255,255,255,0.5);
  margin: 24px 0 0;
  letter-spacing: 0.02em;
  animation: blogHeroSlideUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.15s both;
}

/* Decorative rule */
.blog-hero__rule {
  width: 60px;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, #ff6a00, #ff9a40);
  margin: 28px auto 0;
  animation: blogHeroSlideUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.3s both;
}

/* Slide-up animation */
@keyframes blogHeroSlideUp {
  from {
    opacity: 0;
    transform: translateY(36px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===================================
   POSTS GRID
   =================================== */
.blog-posts {
  padding: 80px 20px;
  background: #fafafa;
}

.blog-posts .container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
}

/* ===================================
   POST CARD
   =================================== */
.post-card {
  background: #fff;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.4s ease;
  display: flex;
  flex-direction: column;
}

.post-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

/* Imagem do post */
.post-image {
  position: relative;
  width: 100%;
  height: 240px;
  overflow: hidden;
}

.post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.post-card:hover .post-image img {
  transform: scale(1.1);
}

.post-category {
  position: absolute;
  top: 15px;
  left: 15px;
  background: var(--brand);
  color: #fff;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 12px rgba(255, 106, 0, 0.4);
}

/* Conteudo do post */
.post-content {
  padding: 30px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.post-title {
  font-size: 22px;
  font-weight: 700;
  color: #333;
  margin: 0 0 15px;
  line-height: 1.4;
  transition: color 0.3s ease;
}

.post-card:hover .post-title {
  color: var(--brand);
}

.post-excerpt {
  font-size: 15px;
  line-height: 1.7;
  color: #666;
  margin: 0 0 25px;
  flex: 1;
}

/* Meta informacoes */
.post-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 20px;
  border-top: 1px solid #eee;
}

.post-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.post-author img {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #f0f0f0;
}

.post-author > div {
  display: flex;
  flex-direction: column;
}

.author-name {
  font-size: 14px;
  font-weight: 700;
  color: #333;
  line-height: 1.2;
}

.post-date {
  font-size: 12px;
  color: #999;
  margin-top: 2px;
}

.read-more {
  font-size: 14px;
  font-weight: 700;
  color: var(--brand);
  text-decoration: none;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.read-more:hover {
  color: var(--brand-dark);
  transform: translateX(4px);
}

/* ===================================
   RESPONSIVO
   =================================== */
@media (max-width: 768px) {
  .blog-hero {
    padding: 70px 20px 60px;
  }

  .blog-hero__outline {
    -webkit-text-stroke-width: 1.5px;
  }

  .blog-hero__geo {
    display: none;
  }

  .blog-posts {
    padding: 60px 20px;
  }

  .blog-posts .container {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .post-image {
    height: 200px;
  }

  .post-content {
    padding: 25px;
  }

  .post-title {
    font-size: 20px;
  }

  .post-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }

  .read-more {
    align-self: flex-start;
  }
}

@media (max-width: 480px) {
  .blog-hero {
    padding: 56px 16px 48px;
  }

  .blog-hero__outline {
    -webkit-text-stroke-width: 1px;
  }

  .blog-hero__sub {
    margin-top: 16px;
  }

  .blog-hero__rule {
    margin-top: 20px;
  }

  .post-content {
    padding: 20px;
  }

  .post-title {
    font-size: 18px;
  }

  .post-excerpt {
    font-size: 14px;
  }
}

/* ===================================
   BLOG CAROUSEL
   =================================== */
.blog-carousel {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.blog-carousel-track {
  display: flex;
  height: 100%;
  transition: transform 0.4s ease;
}

.blog-carousel-track img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  flex-shrink: 0;
}

.blog-carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.45);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s;
  z-index: 2;
}

.post-image:hover .blog-carousel-arrow {
  opacity: 1;
}

.blog-carousel-arrow:hover {
  background: rgba(0,0,0,0.7);
}

.blog-carousel-arrow.prev {
  left: 10px;
}

.blog-carousel-arrow.next {
  right: 10px;
}

.blog-carousel-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 2;
}

.blog-carousel-dots .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s, transform 0.2s;
}

.blog-carousel-dots .dot.active {
  background: #fff;
  transform: scale(1.2);
}

/* Disable zoom hover when carousel is present */
.post-card:hover .post-image .blog-carousel-track img {
  transform: none;
}

/* Hide arrows on mobile (use swipe) */
@media (max-width: 768px) {
  .blog-carousel-arrow {
    display: none;
  }
}

/* ===================================
   POST MODAL
   =================================== */
.post-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(4px);
}

.post-modal-overlay.open {
  display: flex;
}

.post-modal {
  background: #fff;
  border-radius: 20px;
  width: 100%;
  max-width: 900px;
  max-height: 90vh;
  overflow: hidden;
  position: relative;
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
  animation: modalSlideIn 0.35s ease;
  display: flex;
  flex-direction: column;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.post-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 24px;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  line-height: 1;
}

.post-modal-close:hover {
  background: rgba(0, 0, 0, 0.85);
}

.post-modal-body {
  overflow-y: auto;
  flex: 1;
}

/* Modal Image */
.post-modal-image {
  width: 100%;
  height: 400px;
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}

.post-modal-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.post-modal-image:empty {
  display: none;
}

/* Modal Carousel */
.post-modal-carousel {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.post-modal-carousel-track {
  display: flex;
  height: 100%;
  transition: transform 0.4s ease;
}

.post-modal-carousel-track img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  flex-shrink: 0;
}

.post-modal-carousel .blog-carousel-arrow {
  opacity: 1;
  width: 42px;
  height: 42px;
}

/* Modal Content */
.post-modal-content {
  padding: 40px 45px 45px;
}

.post-modal-category {
  display: inline-block;
  background: var(--brand, #ff6a00);
  color: #fff;
  padding: 5px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}

.post-modal-category:empty {
  display: none;
}

.post-modal-title {
  font-size: 30px;
  font-weight: 800;
  color: #1e1e23;
  line-height: 1.3;
  margin: 0 0 20px;
}

.post-modal-meta {
  display: flex;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 1px solid #eee;
}

.post-modal-meta .post-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.post-modal-meta .post-author img {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #f0f0f0;
}

.post-modal-meta .author-name {
  font-size: 14px;
  font-weight: 700;
  color: #333;
  display: block;
}

.post-modal-meta .post-date {
  font-size: 13px;
  color: #999;
}

/* Post body content */
.post-modal-text {
  font-size: 16px;
  line-height: 1.8;
  color: #444;
}

.post-modal-text p {
  margin: 0 0 18px;
}

.post-modal-text h2,
.post-modal-text h3 {
  color: #1e1e23;
  margin: 30px 0 12px;
  font-weight: 700;
}

.post-modal-text h2 {
  font-size: 24px;
}

.post-modal-text h3 {
  font-size: 20px;
}

.post-modal-text ul,
.post-modal-text ol {
  margin: 0 0 18px;
  padding-left: 24px;
}

.post-modal-text li {
  margin-bottom: 8px;
}

.post-modal-text img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 16px 0;
}

.post-modal-text blockquote {
  border-left: 4px solid var(--brand, #ff6a00);
  margin: 20px 0;
  padding: 12px 20px;
  background: #fafafa;
  border-radius: 0 12px 12px 0;
  font-style: italic;
  color: #555;
}

.post-modal-text a {
  color: var(--brand, #ff6a00);
  text-decoration: underline;
}

/* Modal Responsive */
@media (max-width: 768px) {
  .post-modal-overlay {
    padding: 0;
  }

  .post-modal {
    border-radius: 0;
    max-height: 100vh;
    height: 100vh;
  }

  .post-modal-image {
    height: 250px;
  }

  .post-modal-content {
    padding: 25px 20px 30px;
  }

  .post-modal-title {
    font-size: 22px;
  }

  .post-modal-text {
    font-size: 15px;
  }

  .post-modal-close {
    top: 10px;
    right: 10px;
  }

  .post-modal-carousel .blog-carousel-arrow {
    display: flex;
  }
}

@media (max-width: 480px) {
  .post-modal-image {
    height: 200px;
  }

  .post-modal-title {
    font-size: 20px;
  }

  .post-modal-content {
    padding: 20px 16px 25px;
  }
}
