/**
 * PIRANOT — Hub Premium Stylesheet
 * Design moderno, glassmorphism, animações suaves
 * @version 31.4.0
 */

:root {
  --hub-gradient-primary: linear-gradient(135deg, #7c3aed 0%, #06b6d4 100%);
  --hub-gradient-secondary: linear-gradient(135deg, #f59e0b 0%, #ec4899 100%);
  --hub-glow: 0 0 20px rgba(124, 58, 237, 0.3);
}

/* ══════════════════════════════════════════════════════════════
   HERO SECTION — Glassmorphism + Particles
   ══════════════════════════════════════════════════════════════ */

.pira-hub-page {
  --hub-text: #1e293b;
  --hub-bg: #ffffff;
  --hub-border: rgba(226, 232, 240, 0.5);
  color: var(--hub-text);
}

.pira-hub-hero-premium {
  position: relative;
  overflow: hidden;
  padding: 80px 0 120px;
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
}

.pira-hub-hero__bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.pira-hub-hero__gradient {
  position: absolute;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.15) 0%, transparent 70%);
  top: -100px;
  right: -100px;
  animation: float 6s ease-in-out infinite;
}

.pira-hub-hero__gradient::after {
  content: '';
  position: absolute;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.1) 0%, transparent 70%);
  bottom: -150px;
  left: -150px;
  animation: float 8s ease-in-out infinite reverse;
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(20px); }
}

.pira-hub-hero__content {
  position: relative;
  z-index: 10;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
}

.pira-hub-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(124, 58, 237, 0.1);
  border: 1px solid rgba(124, 58, 237, 0.2);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: #6d28d9;
  margin-bottom: 24px;
  animation: slideDown 0.6s ease-out;
}

.pira-hub-hero__badge-dot {
  width: 6px;
  height: 6px;
  background: #6d28d9;
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.pira-hub-hero__title {
  font-family: var(--font-headline, 'Oswald', sans-serif);
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  background: var(--hub-gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 20px 0;
  animation: slideDown 0.7s ease-out 0.1s backwards;
}

.pira-hub-hero__title-icon {
  display: inline-block;
  font-size: 1.2em;
  margin-right: 12px;
  animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.pira-hub-hero__subtitle {
  font-size: 1.15rem;
  color: #64748b;
  line-height: 1.6;
  margin-bottom: 40px;
  animation: slideDown 0.7s ease-out 0.2s backwards;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* Search Bar */
.pira-hub-hero__search {
  animation: slideDown 0.7s ease-out 0.3s backwards;
  margin-bottom: 40px;
}

.pira-hub-hero__search-wrapper {
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border: 1px solid var(--hub-border);
  border-radius: 16px;
  padding: 8px 8px 8px 16px;
  max-width: 600px;
  margin: 0 auto;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.pira-hub-hero__search-wrapper:focus-within {
  border-color: #7c3aed;
  box-shadow: 0 10px 50px rgba(124, 58, 237, 0.15);
}

.pira-hub-hero__search-icon {
  font-size: 20px;
  margin-right: 12px;
  opacity: 0.6;
}

.pira-hub-hero__search-input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 16px;
  color: var(--hub-text);
  outline: none;
  font-family: var(--font-body);
}

.pira-hub-hero__search-input::placeholder {
  color: #94a3b8;
}

.pira-hub-hero__search-btn {
  background: var(--hub-gradient-primary);
  color: white;
  border: none;
  border-radius: 12px;
  padding: 10px 24px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 15px rgba(124, 58, 237, 0.25);
}

.pira-hub-hero__search-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(124, 58, 237, 0.35);
}

/* Stats */
.pira-hub-hero__stats {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 32px;
  animation: slideDown 0.7s ease-out 0.4s backwards;
  flex-wrap: wrap;
}

.pira-hub-hero__stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.pira-hub-hero__stat-num {
  font-size: 28px;
  font-weight: 800;
  background: var(--hub-gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.pira-hub-hero__stat-label {
  font-size: 13px;
  color: #94a3b8;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.pira-hub-hero__stat-divider {
  width: 1px;
  height: 40px;
  background: var(--hub-border);
}

/* Wave Separator */
.pira-hub-hero__wave {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 120px;
  animation: wave 3s ease-in-out infinite;
}

.pira-hub-hero__wave svg {
  width: 100%;
  height: 100%;
  display: block;
}

@keyframes wave {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(10px); }
}

/* ══════════════════════════════════════════════════════════════
   SERVICES GRID — Colorful Cards
   ══════════════════════════════════════════════════════════════ */

.pira-hub-services-section {
  padding: 80px 0;
  background: white;
}

.pira-hub-section-header {
  text-align: center;
  margin-bottom: 60px;
}

.pira-hub-section__eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #7c3aed;
  margin-bottom: 12px;
}

.pira-hub-section__title {
  font-family: var(--font-headline, 'Oswald', sans-serif);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 800;
  color: var(--hub-text);
  margin-bottom: 12px;
}

.pira-hub-section__desc {
  font-size: 1.05rem;
  color: #64748b;
  max-width: 600px;
  margin: 0 auto;
}

.pira-hub-services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 24px;
}

.pira-hub-service-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: white;
  border: 1px solid var(--hub-border);
  border-radius: 16px;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.pira-hub-service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--service-color, #7c3aed) 0%, rgba(124, 58, 237, 0.6) 100%);
  opacity: 0;
  transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 0;
}

.pira-hub-service-card:hover::before {
  opacity: 0.08;
}

.pira-hub-service-card__bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--service-color, #7c3aed) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.3s;
}

.pira-hub-service-card:hover {
  border-color: var(--service-color, #7c3aed);
  transform: translateY(-8px);
  box-shadow: 0 12px 32px rgba(124, 58, 237, 0.15);
}

.pira-hub-service-card__content {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1;
  position: relative;
  z-index: 1;
}

.pira-hub-service-card__icon {
  font-size: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  background: rgba(124, 58, 237, 0.1);
  border-radius: 12px;
  transition: all 0.3s;
}

.pira-hub-service-card:hover .pira-hub-service-card__icon {
  background: var(--service-color, #7c3aed);
  color: white;
  transform: scale(1.1);
}

.pira-hub-service-card__text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pira-hub-service-card__label {
  font-weight: 700;
  font-size: 16px;
  color: var(--hub-text);
}

.pira-hub-service-card__desc {
  font-size: 13px;
  color: #94a3b8;
}

.pira-hub-service-card__arrow {
  font-size: 20px;
  color: var(--service-color, #7c3aed);
  opacity: 0;
  transform: translateX(-8px);
  transition: all 0.3s;
  position: relative;
  z-index: 1;
}

.pira-hub-service-card:hover .pira-hub-service-card__arrow {
  opacity: 1;
  transform: translateX(0);
}

/* ══════════════════════════════════════════════════════════════
   MAIN CONTENT LAYOUT
   ══════════════════════════════════════════════════════════════ */

.pira-hub-wrap {
  background: #f8fafc;
  padding: 60px 0;
}

.pira-hub-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
}

.pira-hub-main {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

/* ══════════════════════════════════════════════════════════════
   FEEDS SECTION
   ══════════════════════════════════════════════════════════════ */

.pira-hub-section {
  background: white;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--hub-border);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.pira-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px;
  border-bottom: 1px solid var(--hub-border);
  gap: 16px;
}

.pira-section-header__left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pira-section-header__icon {
  font-size: 24px;
}

.pira-section-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--hub-text);
  margin: 0;
}

.pira-section-header__link {
  color: #7c3aed;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.3s;
}

.pira-section-header__link:hover {
  gap: 10px;
}

/* Feeds Tabs */
.pira-hub-feeds__tabs {
  display: flex;
  gap: 8px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--hub-border);
  overflow-x: auto;
  scroll-behavior: smooth;
}

.pira-hub-feeds__tab {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  color: #64748b;
  font-weight: 600;
  font-size: 14px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  flex-shrink: 0;
}

.pira-hub-feeds__tab:hover {
  background: rgba(124, 58, 237, 0.05);
  color: #7c3aed;
}

.pira-hub-feeds__tab.is-active {
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.1), rgba(6, 182, 212, 0.1));
  border-color: #7c3aed;
  color: #7c3aed;
}

.pira-hub-feeds__tab-icon {
  font-size: 16px;
}

/* Feed Grid */
.pira-hub-feed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  padding: 24px;
}

.pira-hub-feed-card {
  display: flex;
  flex-direction: column;
  background: white;
  border: 1px solid var(--hub-border);
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.pira-hub-feed-card:hover {
  border-color: #7c3aed;
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(124, 58, 237, 0.12);
}

.pira-hub-feed-card__thumb {
  width: 100%;
  height: 160px;
  overflow: hidden;
  background: linear-gradient(135deg, #f0f4f8, #e2e8f0);
}

.pira-hub-feed-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.pira-hub-feed-card:hover .pira-hub-feed-card__thumb img {
  transform: scale(1.05);
}

.pira-hub-feed-card__body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.pira-hub-feed-card__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #94a3b8;
}

.pira-hub-feed-card__source {
  font-weight: 600;
  color: #7c3aed;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.pira-hub-feed-card__title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--hub-text);
  margin: 0;
  transition: color 0.3s;
}

.pira-hub-feed-card:hover .pira-hub-feed-card__title {
  color: #7c3aed;
}

/* ══════════════════════════════════════════════════════════════
   NEWS CARDS
   ══════════════════════════════════════════════════════════════ */

.pira-hub-news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
  padding: 24px;
}

.pira-hub-news-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: white;
  border: 1px solid var(--hub-border);
}

.pira-hub-news-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
  border-color: #7c3aed;
}

.pira-hub-news-card__thumb {
  width: 100%;
  height: 160px;
  overflow: hidden;
  background: linear-gradient(135deg, #f0f4f8, #e2e8f0);
}

.pira-hub-news-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.pira-hub-news-card:hover .pira-hub-news-card__thumb img {
  transform: scale(1.08);
}

.pira-hub-news-card__body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

.pira-hub-news-card__title {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--hub-text);
  margin: 0;
  transition: color 0.3s;
}

.pira-hub-news-card:hover .pira-hub-news-card__title {
  color: #7c3aed;
}

/* ══════════════════════════════════════════════════════════════
   SIDEBAR
   ══════════════════════════════════════════════════════════════ */

.pira-hub-sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.pira-hub-widget {
  background: white;
  border: 1px solid var(--hub-border);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.pira-hub-widget__title {
  font-size: 16px;
  font-weight: 700;
  margin: 0 0 16px;
  color: var(--hub-text);
  padding-bottom: 12px;
  border-bottom: 2px solid #7c3aed;
}

.pira-hub-widget__list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.pira-hub-widget__item {
  padding: 10px 0;
  border-bottom: 1px solid var(--hub-border);
}

.pira-hub-widget__item:last-child {
  border-bottom: none;
}

.pira-hub-widget__link {
  display: block;
  color: #64748b;
  text-decoration: none;
  font-weight: 500;
  font-size: 14px;
  transition: all 0.3s;
}

.pira-hub-widget__link:hover {
  color: #7c3aed;
  padding-left: 4px;
}

/* ══════════════════════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════════════════════ */

@media (max-width: 1024px) {
  .pira-hub-layout {
    grid-template-columns: 1fr;
  }

  .pira-hub-sidebar {
    grid-column: 1;
    order: -1;
  }

  .pira-hub-services-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
  }
}

@media (max-width: 768px) {
  .pira-hub-hero-premium {
    padding: 60px 0 80px;
  }

  .pira-hub-hero__title {
    font-size: clamp(2rem, 5vw, 3rem);
  }

  .pira-hub-services-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
  }

  .pira-hub-service-card {
    flex-direction: column;
    text-align: center;
    padding: 16px;
  }

  .pira-hub-service-card__content {
    flex-direction: column;
  }

  .pira-hub-hero__stats {
    gap: 16px;
  }

  .pira-hub-feed-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .pira-hub-news-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .pira-hub-hero__search-wrapper {
    flex-direction: column;
  }

  .pira-hub-hero__search-input {
    width: 100%;
  }

  .pira-section-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 480px) {
  .pira-hub-hero-premium {
    padding: 40px 0 60px;
  }

  .pira-hub-hero__content {
    padding: 0 16px;
  }

  .pira-hub-section__title {
    font-size: 1.5rem;
  }

  .pira-hub-services-grid {
    grid-template-columns: 1fr;
  }

  .pira-hub-hero__stats {
    flex-direction: column;
    gap: 12px;
  }

  .pira-hub-hero__stat-divider {
    display: none;
  }
}

/* ══════════════════════════════════════════════════════════════
   DARK MODE (Opcional)
   ══════════════════════════════════════════════════════════════ */

@media (prefers-color-scheme: dark) {
  .pira-hub-page {
    --hub-text: #f1f5f9;
    --hub-bg: #0f172a;
    --hub-border: rgba(148, 163, 184, 0.1);
  }

  .pira-hub-hero-premium {
    background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%);
  }

  .pira-hub-service-card,
  .pira-hub-section,
  .pira-hub-widget {
    background: #1e293b;
  }

  .pira-hub-services-section {
    background: #0f172a;
  }

  .pira-hub-wrap {
    background: #0f172a;
  }
}
