/* ==========================================================================
   PROJETO OÁSIS NO SERTÃO — COMPONENTES UI (HEADER, SLIDER, SIDEBAR, FOOTER)
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. TOPBAR & HEADER
   -------------------------------------------------------------------------- */
/* Primeira barra do site (Top Bar com e-mail) - Fundo Preto */
.topbar {
  background-color: #000000;
  color: #ffffff;
  font-size: 0.875rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.topbar-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.topbar-info a {
  color: #ffffff;
  opacity: 0.95;
}

.topbar-info a:hover {
  opacity: 1;
  text-decoration: underline;
}

/* Segunda barra do site (Header com logo e menu) - Fundo #2e7255 e Texto Branco */
.site-header {
  background-color: #2e7255;
  color: #ffffff;
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
}


/* No arquivo css/components.css */

.site-logo {
  display: inline-block;
  background: #ffffff;
  padding: 2px 6px;
  border-radius: var(--radius-md);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease;
}

.site-logo img {
  width: 100px !important;  /* 1/4 da largura original de 220px */
  height: auto !important;
  object-fit: contain;
  display: block;
}

.site-logo:hover {
  transform: scale(1.02);
}

/* Main Navigation Menu (Desktop) - Texto Branco */
.main-nav {
  display: none;
}

@media (min-width: 992px) {
  .main-nav {
    display: flex;
    align-items: center;
  }

  .nav-list {
    display: flex;
    list-style: none;
    gap: 0.5rem;
  }

  .nav-item {
    position: relative;
  }

  .nav-link {
    display: block;
    padding: 0.6rem 1.1rem;
    color: #ffffff !important;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
  }

  .nav-link:hover,
  .nav-link.active {
    color: #ffffff !important;
    background-color: rgba(255, 255, 255, 0.18);
    text-decoration: none;
  }

  /* Submenu Dropdown */
  .has-dropdown:hover > .dropdown-menu,
  .has-dropdown:focus-within > .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    width: 260px;
    background: #2e7255;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(255, 255, 255, 0.2);
    list-style: none;
    padding: 0.5rem 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.2s ease;
    z-index: 1010;
  }

  .dropdown-link {
    display: block;
    padding: 0.6rem 1.25rem;
    color: #ffffff !important;
    font-size: 0.9rem;
    font-weight: 500;
  }

  .dropdown-link:hover {
    background-color: rgba(255, 255, 255, 0.18);
    color: #ffffff !important;
    text-decoration: none;
  }
}

/* Mobile Toggle Hamburger - Ícone Branco */
.mobile-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: var(--radius-sm);
  cursor: pointer;
}

@media (min-width: 992px) {
  .mobile-toggle {
    display: none;
  }
}

.mobile-toggle span {
  width: 100%;
  height: 2px;
  background-color: #ffffff;
  border-radius: 2px;
  transition: var(--transition);
}

/* Mobile Nav Drawer */
.mobile-nav-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 85%;
  max-width: 320px;
  height: 100vh;
  background: var(--bg-card);
  box-shadow: var(--shadow-lg);
  z-index: 2000;
  padding: 2rem 1.5rem;
  overflow-y: auto;
  transition: right 0.3s ease-in-out;
}

.mobile-nav-drawer.open {
  right: 0;
}

.mobile-nav-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1rem;
}

.mobile-close-btn {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-muted);
  width: 44px;
  height: 44px;
}

.mobile-menu-list {
  list-style: none;
}

.mobile-menu-item {
  margin-bottom: 0.5rem;
}

.mobile-menu-link {
  display: block;
  padding: 0.75rem;
  color: var(--text-main);
  font-weight: 600;
  border-radius: var(--radius-sm);
}

.mobile-submenu {
  list-style: none;
  padding-left: 1rem;
  margin-top: 0.25rem;
}

.mobile-submenu-link {
  display: block;
  padding: 0.5rem 0.75rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.mobile-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.4);
  z-index: 1999;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.mobile-backdrop.active {
  opacity: 1;
  visibility: visible;
}

/* --------------------------------------------------------------------------
   2. HERO CAROUSEL / SLIDER
   -------------------------------------------------------------------------- */
.hero-slider {
  position: relative;
  width: 100%;
  height: 400px;
  overflow: hidden;
  background-color: #111;
}

@media (min-width: 768px) {
  .hero-slider {
    height: 520px;
  }
}

.slider-track {
  display: flex;
  width: 100%;
  height: 100%;
  transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.slide-item {
  min-width: 100%;
  height: 100%;
  position: relative;
}

.slide-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.65) 100%);
  display: flex;
  align-items: flex-end;
  padding: 2.5rem 1.5rem;
}

.slide-content {
  max-width: 800px;
  color: #ffffff;
}

.slide-content h2 {
  color: #ffffff;
  font-size: 1.8rem;
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

@media (min-width: 768px) {
  .slide-content h2 {
    font-size: 2.4rem;
  }
}

.slide-content p {
  color: var(--bg-surface);
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

/* Slider Controls */
.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.85);
  color: var(--primary);
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.25rem;
  font-weight: bold;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  z-index: 10;
}

.slider-btn:hover {
  background: #ffffff;
  transform: translateY(-50%) scale(1.08);
}

.slider-prev { left: 1rem; }
.slider-next { right: 1rem; }

.slider-dots {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.5rem;
  z-index: 10;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  border: none;
  cursor: pointer;
  transition: var(--transition);
}

.dot.active {
  background: #ffffff;
  transform: scale(1.25);
  width: 24px;
  border-radius: 6px;
}

/* --------------------------------------------------------------------------
   3. SIDEBAR NAVIGATION WIDGET
   -------------------------------------------------------------------------- */
.sidebar {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  height: fit-content;
}

.sidebar-title {
  font-size: 1.15rem;
  color: var(--primary);
  padding-bottom: 0.75rem;
  margin-bottom: 1rem;
  border-bottom: 2px solid var(--primary-light);
}

.sidebar-menu {
  list-style: none;
}

.sidebar-item {
  margin-bottom: 0.35rem;
}

.sidebar-link {
  display: block;
  padding: 0.6rem 0.85rem;
  color: var(--text-main);
  font-size: 0.925rem;
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.sidebar-link:hover,
.sidebar-link.active {
  background-color: var(--bg-surface);
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  padding-left: 1.1rem;
}

.sidebar-subnav {
  list-style: none;
  padding-left: 1.25rem;
  margin-top: 0.25rem;
}

.sidebar-sublink {
  display: block;
  padding: 0.4rem 0.75rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.sidebar-sublink:hover,
.sidebar-sublink.active {
  color: var(--primary);
  text-decoration: none;
}

/* --------------------------------------------------------------------------
   4. BUTTONS & CALL TO ACTIONS
   -------------------------------------------------------------------------- */
.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  text-align: center;
  cursor: pointer;
  border: none;
  transition: var(--transition);
}

.btn-primary {
  background-color: var(--primary);
  color: var(--text-light);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  color: var(--text-light);
  text-decoration: none;
}

.btn-accent {
  background-color: var(--accent);
  color: var(--text-light);
}

.btn-accent:hover {
  background-color: var(--accent-hover);
  color: var(--text-light);
  text-decoration: none;
}

.btn-paypal {
  background-color: #0070ba;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  font-size: 1.1rem;
  box-shadow: var(--shadow-sm);
}

.btn-paypal:hover {
  background-color: #005ea6;
  color: #ffffff;
  text-decoration: none;
}

/* --------------------------------------------------------------------------
   5. IMAGE CARDS & GRID LAYOUTS
   -------------------------------------------------------------------------- */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
}

.grid-3 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.media-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.media-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.media-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.media-card-body {
  padding: 1.25rem;
}

.media-card-title {
  font-size: 1.1rem;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

/* --------------------------------------------------------------------------
   6. CONTACT FORM & INPUTS
   -------------------------------------------------------------------------- */
.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-main);
}

.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 1rem;
  background-color: var(--bg-card);
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(64, 145, 108, 0.2);
}

textarea.form-control {
  min-height: 140px;
  resize: vertical;
}

/* --------------------------------------------------------------------------
   7. FOOTER — Fundo #2e7255 e Fonte de Texto Branca
   -------------------------------------------------------------------------- */
.site-footer {
  background-color: #2e7255;
  color: #ffffff;
  padding: 3rem 0 1.5rem 0;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-bottom: 2.5rem;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.footer-col h4 {
  color: #ffffff;
  border-bottom: 2px solid rgba(255, 255, 255, 0.3);
  padding-bottom: 0.5rem;
  margin-bottom: 1rem;
}

.footer-col p, 
.footer-col a,
.footer-col strong {
  color: #ffffff !important;
  font-size: 0.925rem;
  opacity: 0.95;
}

.footer-col a:hover {
  color: #ffffff !important;
  opacity: 1;
  text-decoration: underline;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.4rem;
}

.footer-bottom,
.footer-bottom p,
.footer-bottom span,
.footer-bottom a {
  color: #d4af37 !important;
}

.footer-bottom a {
  font-weight: 700;
  text-decoration: underline;
}

.footer-bottom a:hover {
  color: #ffffff !important;
}

/* Imagens responsivas no corpo dos artigos */
.article-image {
  margin: 1.5rem 0;
  text-align: center;
}

.article-image img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  margin: 0 auto;
}

/* Container Responsivo para Vídeos do YouTube (Proporção 16:9) */
.video-container {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 */
  height: 0;
  margin: 1.5rem 0;
  overflow: hidden;
  border-radius: var(--radius-md);
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}