/* ====================================
   TAB SYSTEM STYLES
==================================== */

.tab-container {
  background: white;
  border-radius: 1.5rem;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.tab-header {
  display: flex;
  background: #f9fafb;
  border-bottom: 1px solid #e5e7eb;
}

.tab-button {
  flex: 1;
  padding: 1rem 1.5rem;
  background: transparent;
  border: none;
  font-weight: 600;
  color: #6b7280;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.tab-button.active {
  background: white;
  color: #f97316;
}

.tab-button::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 3px;
  background: #f97316;
  transition: width 0.3s ease;
}

.tab-button.active::after {
  width: 100%;
}

.tab-button:hover:not(.active) {
  background: #f3f4f6;
  color: #f97316;
}

.tab-content {
  padding: 2rem;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
  animation: fadeInTab 0.3s ease-in;
}

@keyframes fadeInTab {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.file-upload {
  border: 2px dashed #d1d5db;
  border-radius: 1rem;
  padding: 2rem;
  text-align: center;
  transition: all 0.3s ease;
  cursor: pointer;
}

.file-upload:hover {
  border-color: #f97316;
  background: rgba(249, 115, 22, 0.05);
}

.file-upload.dragover {
  border-color: #f97316;
  background: rgba(249, 115, 22, 0.1);
}

.file-upload input[type="file"] {
  display: none;
}

.file-info {
  margin-top: 1rem;
  padding: 0.75rem;
  background: #f3f4f6;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  color: #6b7280;
}

/* CPF Mask Styles */
.cpf-input {
  font-family: monospace;
}

/* Header scroll effects */
header {
  transition: transform 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease;
}

header.header-scrolled {
  background: rgba(255, 255, 255, 0.98) !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
}

/* Header minimal state - faixa fina com apenas textos */
header.header-minimal {
  padding: 0.5rem 0 !important;
  background: rgba(255, 255, 255, 0.95) !important;
}

header.header-minimal .container {
  padding: 0.5rem 1rem !important;
}

header.header-minimal .nutriede-logo-css {
  display: none !important;
}

header.header-minimal .mobile-menu-btn {
  display: none !important;
}

header.header-minimal nav {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
}

header.header-minimal .nav-links {
  display: flex !important;
  gap: 2rem !important;
}

header.header-minimal .nav-links a {
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  color: #374151 !important;
  text-decoration: none !important;
  padding: 0.25rem 0 !important;
  transition: color 0.2s ease !important;
}

header.header-minimal .nav-links a:hover {
  color: #f97316 !important;
}

@media (max-width: 768px) {
  header.header-minimal .nav-links {
    gap: 1rem !important;
  }
  
  header.header-minimal .nav-links a {
    font-size: 0.75rem !important;
  }
}

/* ====================================
   ENHANCED GLASS BUTTONS
==================================== */

/* Enhanced Glass Button - Estilo inspirado na imagem */
.btn-glass-enhanced {
  background: rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #1f2937;
  padding: 1rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.08),
    0 4px 16px rgba(0, 0, 0, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    inset 0 -1px 0 rgba(0, 0, 0, 0.03);
  position: relative;
  overflow: hidden;
}

.btn-glass-enhanced::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s ease;
}

.btn-glass-enhanced:hover::before {
  left: 100%;
}

.btn-glass-enhanced:hover {
  background: rgba(255, 255, 255, 0.5);
  transform: translateY(-3px);
  box-shadow: 
    0 16px 50px rgba(0, 0, 0, 0.12),
    0 8px 25px rgba(0, 0, 0, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    inset 0 -1px 0 rgba(0, 0, 0, 0.05);
  border-color: rgba(255, 255, 255, 0.4);
}

.btn-glass-enhanced i {
  color: #1f2937;
  transition: all 0.3s ease;
}

.btn-glass-enhanced:hover i {
  transform: scale(1.1);
}

/* ====================================
   FULL WIDTH VIDEO SECTION
==================================== */

.video-container-full {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 aspect ratio (9/16 = 0.5625) */
  height: 0;
  background: #000;
  border-radius: 0;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

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

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

/* Desktop iframe styling */
@media (min-width: 1024px) {
  .video-container-full iframe {
    border-radius: 1rem;
  }
}

/* Desktop: Video mais alto para melhor visualização */
@media (min-width: 1024px) {
  .video-container-full {
    padding-bottom: 45%; /* Proporção mais ampla para desktop */
    max-height: 600px;
    margin: 0 2rem; /* Pequena margem lateral no desktop */
    border-radius: 1rem;
  }
}

/* Tablet: Proporção intermediária */
@media (min-width: 768px) and (max-width: 1023px) {
  .video-container-full {
    padding-bottom: 50%;
  }
}

/* Mobile: Proporção 16:9 padrão */
@media (max-width: 767px) {
  .video-container-full {
    padding-bottom: 56.25%;
    border-radius: 0.5rem;
  }
  
  .video-container-full iframe {
    border-radius: 0.5rem;
  }
}

/* Backup: Container com altura mínima caso o padding-bottom falhe */
.video-container {
  position: relative;
  width: 100%;
  height: 400px;
  background: #000;
}

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

/* ====================================
   CUSTOM VIDEO OVERLAY
==================================== */

.video-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 0;
}

/* Desktop wrapper styling */
@media (min-width: 1024px) {
  .video-wrapper {
    border-radius: 1rem;
  }
}

#video-overlay {
  background: rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  transition: all 0.3s ease;
  border-radius: 0;
}

/* Desktop overlay styling */
@media (min-width: 1024px) {
  #video-overlay {
    border-radius: 1rem;
  }
}

#video-overlay:hover {
  background: rgba(0, 0, 0, 0.1);
}

#video-overlay .bg-white {
  background: rgba(255, 255, 255, 0.95) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.12),
    0 4px 16px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

#video-overlay.playing {
  opacity: 0;
  pointer-events: none;
}

#video-overlay.paused {
  opacity: 1;
  pointer-events: all;
}

/* Play/Pause icon animation */
#play-icon, #pause-icon {
  transition: all 0.3s ease;
}

#video-overlay:hover #play-icon svg,
#video-overlay:hover #pause-icon svg {
  transform: scale(1.1);
}

/* Loading animation */
#loading-indicator {
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  border-radius: 1rem;
}

/* Video state classes */
.video-loading #video-overlay {
  pointer-events: none;
}

.video-loading #loading-indicator {
  display: flex !important;
}

/* Full-screen video optimization */
.video-container-full iframe {
  object-fit: cover; /* Garante que o vídeo preencha o container sem bordas pretas */
}

/* Desktop optimizations */
@media (min-width: 1024px) {
  .video-container-full {
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  }
  
  #video-overlay .bg-white {
    padding: 1.5rem !important;
  }
  
  #play-icon, #pause-icon {
    width: 4rem !important;
    height: 4rem !important;
  }
  
  #play-icon svg, #pause-icon svg {
    width: 2.5rem !important;
    height: 2.5rem !important;
  }
}

/* Tablet adjustments */
@media (min-width: 768px) and (max-width: 1023px) {
  #video-overlay .bg-white {
    padding: 1.25rem !important;
  }
  
  #play-icon, #pause-icon {
    width: 3rem !important;
    height: 3rem !important;
  }
  
  #play-icon svg, #pause-icon svg {
    width: 2rem !important;
    height: 2rem !important;
  }
}

/* Mobile adjustments */
@media (max-width: 767px) {
  #video-overlay .bg-white {
    padding: 1rem !important;
  }
  
  #play-icon, #pause-icon {
    width: 2.5rem !important;
    height: 2.5rem !important;
  }
  
  #play-icon svg, #pause-icon svg {
    width: 1.5rem !important;
    height: 1.5rem !important;
  }
  
  /* Better touch target for mobile */
  #video-overlay {
    -webkit-tap-highlight-color: transparent;
  }
  
  #video-overlay .bg-white {
    min-width: 80px;
    min-height: 80px;
  }
  
  .video-wrapper {
    border-radius: 0.5rem;
  }
  
  #video-overlay {
    border-radius: 0.5rem;
  }
}