/* ============================================
   FuseIoT — Hero Section
   Full-viewport hero with dark dashboard mockup
   Ref: 01-hero-section.md
   ============================================ */

.hero {
  height: 100vh;
  background: var(--bg-primary);
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  overflow: hidden;
}

/* --- Text above the dark frame --- */
.hero__text {
  width: 100%;
  padding-top: 110px;
}

/* Subtitle + CTA entrance (cascades after headline word-reveal) */
.hero__text .label {
  animation: heroLabelFadeIn 0.8s var(--ease-expo-out) 1s both;
}

.hero__text .pill {
  animation: heroPillFadeIn 0.8s var(--ease-expo-out) 1.2s both;
}

@keyframes heroLabelFadeIn {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 0.6; transform: translateY(0); }
}

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

/* --- Dark Container --- */
.hero__container {
  width: calc(100% - 10vw);
  height: 60vh;
  border-radius: var(--radius-container);
  background: #0A0A0F;
  margin-top: 2.5rem;
  position: relative;
  overflow: hidden;
}

/* --- Dark Frame (inner wrapper) --- */
.hero__dark-frame {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* ============================================
   Dashboard Mockup
   ============================================ */
.hero__dashboard {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  color: rgba(255, 255, 255, 0.7);
  font-size: 12px;
}

/* --- Top Bar (macOS dots) --- */
.hero__dashboard-topbar {
  height: 40px;
  display: flex;
  align-items: center;
  padding: 0 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
}

.hero__dashboard-dots {
  display: flex;
  gap: 8px;
}

.hero__dashboard-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.hero__dashboard-dot--red { background: #FF5F57; }
.hero__dashboard-dot--yellow { background: #FEBC2E; }
.hero__dashboard-dot--green { background: #28C840; }

.hero__dashboard-title {
  margin-left: 16px;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.5);
}

.hero__dashboard-topbar-spacer { flex: 1; }

/* --- Dashboard Body (sidebar + main) --- */
.hero__dashboard-body {
  display: flex;
  flex: 1;
  min-height: 0;
}

/* --- Sidebar --- */
.hero__dashboard-sidebar {
  width: 180px;
  background: rgba(255, 255, 255, 0.02);
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex-shrink: 0;
}

.hero__dashboard-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.4);
  font-size: 12px;
  cursor: default;
}

.hero__dashboard-nav-item--active {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.8);
}

.hero__dashboard-nav-icon {
  font-size: 10px;
  width: 16px;
  text-align: center;
}

.hero__dashboard-nav-label {
  font-size: 12px;
}

/* --- Main Content Area --- */
.hero__dashboard-main {
  flex: 1;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 0;
}

/* --- Chart --- */
.hero__dashboard-chart {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.hero__dashboard-chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  flex-shrink: 0;
}

.hero__dashboard-chart-title {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.8);
}

.hero__dashboard-chart-period {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.3);
}

.hero__dashboard-chart-bars {
  flex: 1;
  display: flex;
  align-items: flex-end;
  gap: 10px;
  min-height: 0;
}

.hero__dashboard-bar {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  height: var(--bar-height, 50%);
  background: var(--bar-color, var(--blue));
  border-radius: 6px 6px 0 0;
  min-height: 20px;
  position: relative;
  animation: bar-pulse 3s ease-in-out infinite alternate;
}

.hero__dashboard-bar-label {
  position: absolute;
  bottom: -20px;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.3);
}

@keyframes bar-pulse {
  0% { opacity: 0.7; }
  100% { opacity: 1; }
}

/* --- Widgets --- */
.hero__dashboard-widgets {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  flex-shrink: 0;
}

.hero__dashboard-widget {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hero__dashboard-widget-label {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.35);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hero__dashboard-widget-value {
  font-size: 18px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
}

.hero__dashboard-widget-bar {
  height: 3px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: hidden;
}

.hero__dashboard-widget-bar::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: var(--widget-fill, 50%);
  background: var(--widget-color, var(--blue));
  border-radius: 2px;
}

/* --- Bottom Bar --- */
.hero__bottom-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.hero__bottom-crosses {
  display: flex;
  gap: 80px;
}

.hero__scroll-label {
  color: var(--text-muted);
}

@media (max-width: 768px) {
  .hero__container {
    width: calc(100% - 4vw);
    height: 50vh;
    margin-top: 90px;
  }
  .hero__dashboard-sidebar {
    width: 0;
    padding: 0;
    overflow: hidden;
    border: none;
  }
  .hero__dashboard-widgets {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .hero__container {
    width: calc(100% - 40px);
    margin-top: 80px;
    height: 45vh;
    border-radius: 16px;
  }
}
