/* =================================================================== */
/* STREAB CLOUD PANEL LAYOUT - camada unica de tema e responsividade
/* =================================================================== */

#streab-nuvem-scope {
  --streab-ui-bg: #eef1f6;
  --streab-ui-bg-2: #e2e8f0;
  --streab-ui-surface: rgba(255, 255, 255, 0.86);
  --streab-ui-surface-solid: #ffffff;
  --streab-ui-soft: #f5f7fb;
  --streab-ui-line: rgba(15, 23, 42, 0.08);
  --streab-ui-line-strong: rgba(15, 23, 42, 0.14);
  --streab-ui-ink: #0d1117;
  --streab-ui-muted: #697386;
  --streab-ui-blue: #4ea7ff;
  --streab-ui-violet: #7568f6;
  --streab-ui-mint: #1fc7b6;
  --streab-ui-amber: #ffb72c;
  --streab-ui-shadow: 0 24px 70px rgba(15, 23, 42, 0.12);
  --streab-ui-shadow-sm: 0 12px 32px rgba(15, 23, 42, 0.09);
  --streab-radius-xl: 28px;
  --streab-radius-lg: 18px;
  --streab-radius-md: 12px;
  --bg-color: var(--streab-ui-bg);
  --card-bg: var(--streab-ui-surface-solid);
  --card-bg-hover: var(--streab-ui-soft);
  --text-primary: var(--streab-ui-ink);
  --text-secondary: var(--streab-ui-muted);
  --border-color: var(--streab-ui-line);
  width: 100vw;
  max-width: 100vw;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 8%, rgba(255, 183, 44, 0.18), transparent 26%),
    radial-gradient(circle at 82% 0%, rgba(78, 167, 255, 0.22), transparent 28%),
    linear-gradient(135deg, #f8fafc 0%, #eef2f7 45%, #e7ecf4 100%);
}

#streab-nuvem-scope[data-streab-theme="dark"] {
  --streab-ui-bg: #0d1117;
  --streab-ui-bg-2: #151a23;
  --streab-ui-surface: rgba(24, 29, 39, 0.88);
  --streab-ui-surface-solid: #171c26;
  --streab-ui-soft: #202736;
  --streab-ui-line: rgba(255, 255, 255, 0.09);
  --streab-ui-line-strong: rgba(255, 255, 255, 0.16);
  --streab-ui-ink: #f8fafc;
  --streab-ui-muted: #a8b2c4;
  --streab-ui-shadow: 0 26px 80px rgba(0, 0, 0, 0.38);
  --streab-ui-shadow-sm: 0 16px 44px rgba(0, 0, 0, 0.28);
  background:
    radial-gradient(circle at 18% 8%, rgba(255, 183, 44, 0.11), transparent 25%),
    radial-gradient(circle at 82% 0%, rgba(117, 104, 246, 0.18), transparent 28%),
    linear-gradient(135deg, #090d14 0%, #101721 52%, #121722 100%);
}

#streab-nuvem-scope,
#streab-nuvem-scope * {
  box-sizing: border-box;
  letter-spacing: 0;
}

html:has(#streab-nuvem-scope),
body:has(#streab-nuvem-scope) {
  overflow: hidden;
}

/* Shell ------------------------------------------------------------- */

#streab-main-interface {
  display: flex;
  gap: 18px;
  width: 100%;
  height: 100dvh;
  min-width: 0;
  padding: 18px;
  overflow: hidden;
  background: transparent;
}

#streab-sidebar,
#streab-main-content {
  border: 1px solid rgba(255, 255, 255, 0.62);
  box-shadow: var(--streab-ui-shadow);
}

#streab-nuvem-scope[data-streab-theme="dark"] #streab-sidebar,
#streab-nuvem-scope[data-streab-theme="dark"] #streab-main-content {
  border-color: var(--streab-ui-line);
}

#streab-main-content {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  overflow: hidden auto;
  border-radius: var(--streab-radius-xl);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.68), rgba(255, 255, 255, 0.42) 320px, rgba(238, 242, 247, 0.76));
  backdrop-filter: blur(24px) saturate(140%);
  -webkit-backdrop-filter: blur(24px) saturate(140%);
}

#streab-nuvem-scope[data-streab-theme="dark"] #streab-main-content {
  background:
    linear-gradient(180deg, rgba(24, 29, 39, 0.86), rgba(15, 23, 42, 0.78) 360px, rgba(13, 17, 23, 0.86));
}

.painel-container {
  max-width: 1680px;
  min-width: 0;
  padding: 0 32px 52px;
}

#painel-principal-container,
#videos-container,
#hero-and-header-container,
#mindmaps-section {
  min-width: 0;
  max-width: 100%;
}

#painel-principal-container {
  background:
    linear-gradient(to right, rgba(15, 23, 42, 0.028) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 23, 42, 0.024) 1px, transparent 1px);
  background-size: 48px 48px;
}

#streab-nuvem-scope[data-streab-theme="dark"] #painel-principal-container {
  background:
    linear-gradient(to right, rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
  background-size: 48px 48px;
}

/* Sidebar ----------------------------------------------------------- */

#streab-sidebar {
  width: 292px;
  max-width: min(292px, calc(100vw - 28px));
  flex: 0 0 292px;
  padding: 16px;
  border-radius: var(--streab-radius-xl);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(247, 249, 252, 0.72));
  backdrop-filter: blur(26px) saturate(145%);
  -webkit-backdrop-filter: blur(26px) saturate(145%);
}

#streab-nuvem-scope[data-streab-theme="dark"] #streab-sidebar {
  background:
    linear-gradient(180deg, rgba(23, 28, 38, 0.9), rgba(13, 17, 23, 0.76));
}

.sidebar-profile {
  height: auto;
  min-height: 96px;
  margin: 0 0 18px;
  padding: 14px;
  border: 1px solid var(--streab-ui-line);
  border-radius: var(--streab-radius-lg);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(245, 247, 251, 0.74));
  box-shadow: var(--streab-ui-shadow-sm);
}

#streab-nuvem-scope[data-streab-theme="dark"] .sidebar-profile {
  background:
    linear-gradient(135deg, rgba(32, 39, 54, 0.92), rgba(23, 28, 38, 0.72));
}

.profile-avatar {
  border: 4px solid #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.14);
}

.profile-name,
.main-header-title,
.carousel-row h2.carousel-title,
.carousel-title,
.video-card-content h3,
.catalogo-card-title {
  letter-spacing: 0;
}

.profile-plan {
  border-radius: 999px;
  background: rgba(117, 104, 246, 0.12);
  color: var(--streab-ui-violet);
}

.profile-plan.plan-premium {
  background: linear-gradient(135deg, #ffe8a3, #ffbd3d);
  color: #4c3200;
}

.sidebar-nav li a,
.sidebar-nav li a:link,
.sidebar-nav li a:visited,
.sidebar-footer .footer-link {
  min-height: 48px;
  padding: 10px 76px 10px 12px;
  border: 1px solid transparent;
  border-left: 0;
  border-radius: 14px;
  color: var(--streab-ui-muted);
}

.sidebar-nav li a i:first-child,
.sidebar-footer .footer-link i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.05);
  color: var(--streab-ui-ink);
}

.sidebar-nav li a:hover,
.sidebar-nav li a.ativa,
.sidebar-nav li a.ativa:link,
.sidebar-nav li a.ativa:visited,
.sidebar-footer .footer-link:hover {
  background: rgba(255, 255, 255, 0.7);
  border-color: var(--streab-ui-line);
  color: var(--streab-ui-ink);
}

#streab-nuvem-scope[data-streab-theme="dark"] .sidebar-nav li a:hover,
#streab-nuvem-scope[data-streab-theme="dark"] .sidebar-footer .footer-link:hover {
  background: rgba(255, 255, 255, 0.07);
}

.sidebar-nav li a.ativa,
.sidebar-nav li a.ativa:link,
.sidebar-nav li a.ativa:visited {
  background: #0d1117;
  color: #ffffff;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.16);
}

.sidebar-nav li a.ativa i:first-child {
  background: linear-gradient(135deg, var(--streab-ui-blue), var(--streab-ui-violet));
  color: #ffffff;
}

.courses-title {
  padding: 14px 8px 8px;
  letter-spacing: 0;
}

.sidebar-delete-btn,
.sidebar-add-module-btn {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--streab-ui-line);
}

#streab-nuvem-scope[data-streab-theme="dark"] .sidebar-delete-btn,
#streab-nuvem-scope[data-streab-theme="dark"] .sidebar-add-module-btn {
  background: rgba(15, 23, 42, 0.78);
}

.streab-sidebar-theme-toggle {
  display: grid;
  gap: 10px;
  width: 100%;
  margin: 0 0 14px;
  padding: 12px;
  border: 1px solid var(--streab-ui-line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--streab-ui-ink);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  cursor: pointer;
  text-align: left;
}

#streab-nuvem-scope[data-streab-theme="dark"] .streab-sidebar-theme-toggle {
  background: rgba(255, 255, 255, 0.07);
}

.streab-theme-toggle-copy {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-size: 0.9rem;
  font-weight: 800;
}

.streab-theme-toggle-copy i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.06);
  color: var(--streab-ui-ink);
}

#streab-nuvem-scope[data-streab-theme="dark"] .streab-theme-toggle-copy i {
  background: rgba(255, 255, 255, 0.08);
  color: #f8fafc;
}

.streab-theme-switch-track {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 34px;
  padding: 3px;
  border: 1px solid var(--streab-ui-line);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.05);
  overflow: hidden;
}

#streab-nuvem-scope[data-streab-theme="dark"] .streab-theme-switch-track {
  background: rgba(0, 0, 0, 0.22);
}

.streab-theme-switch-option {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--streab-ui-muted);
  font-size: 0.74rem;
  font-weight: 800;
}

.streab-theme-switch-thumb {
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 3px;
  z-index: 1;
  width: calc(50% - 3px);
  border-radius: 999px;
  background: #ffffff;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.14);
  transition: transform 0.22s ease, background 0.22s ease;
}

.streab-sidebar-theme-toggle[data-streab-theme-state="dark"] .streab-theme-switch-thumb {
  transform: translateX(100%);
  background: #0d1117;
}

.streab-sidebar-theme-toggle[data-streab-theme-state="light"] .streab-theme-switch-option:first-child,
.streab-sidebar-theme-toggle[data-streab-theme-state="dark"] .streab-theme-switch-option:nth-child(2) {
  color: var(--streab-ui-ink);
}

#streab-nuvem-scope[data-streab-theme="dark"] .streab-sidebar-theme-toggle[data-streab-theme-state="dark"] .streab-theme-switch-option:nth-child(2) {
  color: #ffffff;
}

/* Header and filters ----------------------------------------------- */

.main-header-sticky {
  height: auto;
  min-height: 96px;
  margin: 0 -32px 28px;
  padding: 18px 32px;
  border-bottom: 1px solid var(--streab-ui-line);
  border-radius: var(--streab-radius-xl) var(--streab-radius-xl) 0 0;
  overflow: visible;
  background: rgba(248, 250, 252, 0.72);
  backdrop-filter: blur(22px) saturate(145%);
  -webkit-backdrop-filter: blur(22px) saturate(145%);
}

#streab-nuvem-scope[data-streab-theme="dark"] .main-header-sticky {
  background: rgba(15, 23, 42, 0.68);
}

.main-header-sticky::after {
  left: 32px;
  right: 32px;
  background: linear-gradient(90deg, transparent, rgba(78, 167, 255, 0.45), rgba(255, 183, 44, 0.26), transparent);
}

.main-header-sticky .header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  width: 100%;
  min-width: 0;
  height: auto;
}

.main-header-title {
  flex: 1 1 280px;
  min-width: 180px;
  max-width: none;
  color: var(--streab-ui-ink);
  font-size: clamp(1.8rem, 2.55vw, 2.85rem);
  font-weight: 800;
}

#filtros-e-busca-container {
  display: flex;
  flex: 1 1 680px;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: nowrap;
  gap: 12px;
  min-width: 0;
  max-width: 820px;
  margin-bottom: 0;
  overflow: visible;
}

.busca-global-wrapper {
  flex: 1 1 320px;
  min-width: 220px;
  max-width: 420px;
}

#input-busca-global,
.custom-select-wrapper .select-selected,
#btn-select-mode,
.streab-theme-toggle {
  height: 50px;
  border: 1px solid var(--streab-ui-line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--streab-ui-ink);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

#input-busca-global {
  width: 100%;
  min-width: 0;
  max-width: none;
}

#streab-nuvem-scope[data-streab-theme="dark"] #input-busca-global,
#streab-nuvem-scope[data-streab-theme="dark"] .custom-select-wrapper .select-selected,
#streab-nuvem-scope[data-streab-theme="dark"] #btn-select-mode,
#streab-nuvem-scope[data-streab-theme="dark"] .streab-theme-toggle {
  background: rgba(23, 28, 38, 0.84);
}

#input-busca-global::placeholder {
  color: #7e8798;
}

#input-busca-global:focus,
.custom-select-wrapper.open .select-selected {
  border-color: rgba(78, 167, 255, 0.55);
  box-shadow: 0 0 0 4px rgba(78, 167, 255, 0.14), 0 14px 30px rgba(15, 23, 42, 0.08);
}

.filtro-grupo {
  flex: 0 1 auto;
  min-width: 0;
  flex-wrap: nowrap;
}

.custom-select-wrapper {
  flex: 0 1 180px;
  min-width: 156px;
}

.custom-select-wrapper .select-selected {
  width: 100%;
  min-width: 0;
}

.custom-select-wrapper .select-items {
  border: 1px solid var(--streab-ui-line);
  border-radius: 16px;
  background: var(--streab-ui-surface-solid);
  box-shadow: var(--streab-ui-shadow-sm);
}

.custom-select-wrapper .select-items div:hover {
  background: rgba(78, 167, 255, 0.12);
  color: var(--streab-ui-ink);
}

#btn-select-mode,
.streab-theme-toggle {
  flex: 0 0 auto;
  min-width: 104px;
  white-space: nowrap;
}

/* Hero and QR ------------------------------------------------------- */

.hero-section {
  min-height: 340px;
  height: min(40vh, 430px);
  margin-top: 6px;
  margin-bottom: 30px;
  padding: clamp(28px, 4.5vw, 58px);
  border: 1px solid rgba(255, 255, 255, 0.58);
  border-radius: var(--streab-radius-xl);
  box-shadow: var(--streab-ui-shadow);
  isolation: isolate;
}

#streab-nuvem-scope[data-streab-theme="dark"] .hero-section {
  border-color: var(--streab-ui-line);
}

.hero-section::before {
  inset: 12px;
  border-color: rgba(255, 255, 255, 0.18);
  border-radius: 22px;
}

.hero-background {
  filter: saturate(1.1) contrast(1.02) brightness(0.92);
}

.hero-background::after {
  background:
    linear-gradient(90deg, rgba(7, 10, 16, 0.92) 0%, rgba(7, 10, 16, 0.6) 48%, rgba(7, 10, 16, 0.08) 100%),
    linear-gradient(0deg, rgba(7, 10, 16, 0.48), rgba(7, 10, 16, 0.05) 58%);
}

.hero-content {
  width: min(640px, 62%);
  max-width: 640px;
}

#hero-title {
  display: -webkit-box;
  max-width: 720px;
  overflow: hidden;
  color: #ffffff;
  font-size: clamp(2.15rem, 3.45vw, 3.75rem);
  line-height: 1.04;
  text-overflow: ellipsis;
  text-shadow: 0 4px 15px rgba(0, 0, 0, 0.8);
  word-break: break-word;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

#hero-subtitle {
  max-width: 520px;
  color: rgba(255, 255, 255, 0.78);
  text-shadow: 0 4px 15px rgba(0, 0, 0, 0.8);
}

#hero-play-button {
  min-height: 50px;
  padding: 0 24px;
  border-radius: 999px;
  background: #ffffff;
  color: #080b10;
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.18);
}

#hero-play-button:hover {
  background: rgba(255, 255, 255, 0.82);
  transform: scale(1.05);
}

.header-actions {
  top: 18px;
  right: 18px;
  z-index: 25;
}

.qr-widget {
  width: 128px;
  border-radius: 22px;
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 22px 52px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

#streab-nuvem-scope[data-streab-theme="dark"] .qr-widget {
  background: rgba(23, 28, 38, 0.72);
}

#qrcode-display-widget {
  width: 104px;
  height: 104px;
  border-radius: 18px;
}

#qrcode-display-widget canvas,
#qrcode-display-widget img {
  max-width: 88px;
  max-height: 88px;
}

/* Cards and content ------------------------------------------------- */

.carousel-row {
  margin-bottom: 26px;
  padding-top: 18px;
}

.carousel-row::before,
.carousel-row h2.carousel-title::after,
.carousel-title::after {
  display: none;
}

.carousel-row h2.carousel-title,
.carousel-title {
  color: var(--streab-ui-ink);
  font-size: clamp(1.25rem, 1.65vw, 1.65rem);
  font-weight: 800;
}

.videos-grid,
.videos-grid.is-grid-view {
  max-width: 100%;
}

.videos-grid {
  gap: 18px;
  margin: 0 -6px -8px;
  padding: 14px 6px 30px;
  -webkit-mask-image: linear-gradient(to right, transparent, black 20px, black calc(100% - 20px), transparent);
  mask-image: linear-gradient(to right, transparent, black 20px, black calc(100% - 20px), transparent);
}

.video-card-wrapper {
  width: 318px;
  max-width: calc(100vw - 48px);
}

.video-card,
.catalogo-card,
.empty-state-container,
.streab-modal-content,
.bulk-actions-bar {
  border: 1px solid var(--streab-ui-line);
  border-radius: var(--streab-radius-lg);
  background: var(--streab-ui-surface-solid);
  box-shadow: var(--streab-ui-shadow-sm);
}

.video-thumb-container {
  border-radius: var(--streab-radius-lg) var(--streab-radius-lg) 0 0;
  background: linear-gradient(135deg, rgba(78, 167, 255, 0.16), rgba(255, 183, 44, 0.12));
}

.video-thumb-container::after {
  height: 66%;
  background: linear-gradient(to top, rgba(6, 10, 18, 0.82), rgba(6, 10, 18, 0.05));
}

.video-card-title-static {
  right: 16px;
  bottom: 14px;
  left: 16px;
  color: #ffffff;
  font-size: 15px;
}

.video-card-content {
  z-index: 5;
  padding: 14px;
  border-top: 1px solid var(--streab-ui-line);
  border-radius: 0 0 var(--streab-radius-lg) var(--streab-radius-lg);
  background: rgba(255, 255, 255, 0.96);
}

#streab-nuvem-scope[data-streab-theme="dark"] .video-card-content {
  background: rgba(23, 28, 38, 0.97);
}

.card-icon-btn {
  position: relative;
  z-index: 8;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  background: rgba(255, 255, 255, 0.86);
  color: #0d1117;
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.12);
}

.btn-play-circle {
  background: #0d1117;
  color: #ffffff;
}

.card-icon-btn.favorited {
  color: #d99100;
}

.video-card .card-actions-bottom button {
  position: relative;
  z-index: 8;
  min-height: 34px;
  border: 1px solid var(--streab-ui-line);
  border-radius: 999px;
  background: var(--streab-ui-soft);
  color: var(--streab-ui-ink);
  pointer-events: auto;
}

.card-actions-top,
.card-actions-bottom {
  position: relative;
  z-index: 8;
  pointer-events: auto;
}

@media (hover: hover) {
  .video-card:hover {
    transform: translateY(-6px) scale(1.06);
    box-shadow: 0 28px 66px rgba(15, 23, 42, 0.22), 0 0 0 1px rgba(78, 167, 255, 0.22);
  }

  #streab-nuvem-scope[data-streab-theme="dark"] .video-card:hover {
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.48), 0 0 0 1px rgba(78, 167, 255, 0.28);
  }
}

.carousel-nav {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  color: var(--streab-ui-ink);
  box-shadow: var(--streab-ui-shadow-sm);
}

.carousel-nav:hover,
.card-icon-btn:hover,
.streab-theme-toggle:hover,
#btn-select-mode:hover {
  border-color: transparent;
  background: linear-gradient(135deg, var(--streab-ui-blue), var(--streab-ui-violet));
  color: #ffffff;
}

.catalogo-grid {
  gap: 18px;
}

.catalogo-card {
  overflow: hidden;
  aspect-ratio: 1.35 / 1;
}

.catalogo-card:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 24px 54px rgba(15, 23, 42, 0.2);
}

.catalogo-card-overlay {
  padding: 48px 18px 18px;
  background:
    linear-gradient(to top, rgba(6, 10, 18, 0.9), rgba(6, 10, 18, 0.18), transparent);
}

/* Modals, empty states and misc ------------------------------------ */

.streab-modal-overlay {
  background: rgba(15, 23, 42, 0.42);
  backdrop-filter: blur(10px) saturate(110%);
  -webkit-backdrop-filter: blur(10px) saturate(110%);
}

#streab-generic-modal {
  align-items: center;
  justify-content: center;
  padding: 18px;
}

#streab-generic-modal .streab-modal-content {
  width: min(520px, calc(100vw - 36px));
  max-width: 520px;
  max-height: min(720px, calc(100dvh - 36px));
  overflow: auto;
  padding: 32px;
  border: 1px solid var(--streab-ui-line-strong);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--streab-ui-ink);
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.22);
  text-align: center;
}

#streab-generic-modal.show .streab-modal-content {
  transform: scale(1);
}

#streab-nuvem-scope[data-streab-theme="dark"] #streab-generic-modal .streab-modal-content {
  background: rgba(23, 28, 38, 0.98);
  color: #f8fafc;
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.46);
}

#streab-generic-modal .streab-modal-content h2,
#streab-generic-modal #modal-title {
  margin: 0 42px 22px;
  color: inherit;
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.2;
}

#streab-generic-modal #modal-body {
  color: inherit;
}

.streab-modal-content input[type="text"],
.streab-modal-content textarea,
.streab-modal-content select,
#conteudo-atribuir-curso .tag-curso-modal {
  border: 1px solid var(--streab-ui-line);
  border-radius: 14px;
  background: #f8fafc;
  color: var(--streab-ui-ink);
}

#streab-nuvem-scope[data-streab-theme="dark"] .streab-modal-content input[type="text"],
#streab-nuvem-scope[data-streab-theme="dark"] .streab-modal-content textarea,
#streab-nuvem-scope[data-streab-theme="dark"] .streab-modal-content select,
#streab-nuvem-scope[data-streab-theme="dark"] #conteudo-atribuir-curso .tag-curso-modal {
  border-color: rgba(255, 255, 255, 0.12);
  background: #111827;
  color: #f8fafc;
}

#streab-generic-modal .streab-modal-content input[type="text"],
#streab-generic-modal .streab-modal-content textarea,
#streab-generic-modal .streab-modal-content select {
  width: 100%;
  min-height: 50px;
  margin: 0 0 16px;
  padding: 0 16px;
  color: var(--streab-ui-ink);
  font-size: 0.98rem;
}

#streab-nuvem-scope[data-streab-theme="dark"] #streab-generic-modal .streab-modal-content input[type="text"],
#streab-nuvem-scope[data-streab-theme="dark"] #streab-generic-modal .streab-modal-content textarea,
#streab-nuvem-scope[data-streab-theme="dark"] #streab-generic-modal .streab-modal-content select {
  color: #f8fafc;
}

#streab-generic-modal .streab-modal-content input::placeholder,
#streab-generic-modal .streab-modal-content textarea::placeholder {
  color: #7e8798;
  opacity: 1;
}

.streab-modal-content .btn-principal,
.bulk-actions-bar button,
.empty-state-cta {
  border-radius: 999px;
  background: #0d1117;
  color: #ffffff;
}

.btn-fechar-modal {
  background: rgba(255, 255, 255, 0.84);
  color: var(--streab-ui-ink);
}

#streab-generic-modal .btn-fechar-modal {
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border: 1px solid var(--streab-ui-line);
  background: #f8fafc;
  color: var(--streab-ui-ink);
}

#streab-nuvem-scope[data-streab-theme="dark"] #streab-generic-modal .btn-fechar-modal {
  background: #202736;
  color: #f8fafc;
}

#streab-generic-modal .btn-fechar-modal:hover {
  background: #0d1117;
  color: #ffffff;
  transform: rotate(90deg);
}

#conteudo-atribuir-curso {
  gap: 10px;
  max-height: min(420px, 52dvh);
  padding-right: 2px;
}

#conteudo-atribuir-curso .tag-curso-modal {
  padding: 13px 15px;
  color: var(--streab-ui-ink);
  text-align: left;
}

#conteudo-atribuir-curso .tag-curso-modal span {
  color: var(--streab-ui-muted);
}

#conteudo-atribuir-curso .tag-curso-modal:hover,
#conteudo-atribuir-curso .tag-curso-modal:focus {
  border-color: rgba(78, 167, 255, 0.55);
  background: rgba(78, 167, 255, 0.12);
  color: var(--streab-ui-ink);
}

#streab-nuvem-scope[data-streab-theme="dark"] #conteudo-atribuir-curso .tag-curso-modal:hover,
#streab-nuvem-scope[data-streab-theme="dark"] #conteudo-atribuir-curso .tag-curso-modal:focus {
  background: rgba(78, 167, 255, 0.18);
  color: #f8fafc;
}

.streab-toast {
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.88);
  color: var(--streab-ui-ink);
  box-shadow: var(--streab-ui-shadow-sm);
}

#streab-nuvem-scope[data-streab-theme="dark"] .streab-toast {
  background: rgba(23, 28, 38, 0.9);
}

.empty-state-container {
  max-width: 760px;
  margin: 52px auto;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(245, 247, 251, 0.82));
}

#streab-nuvem-scope[data-streab-theme="dark"] .empty-state-container {
  background:
    linear-gradient(135deg, rgba(32, 39, 54, 0.95), rgba(23, 28, 38, 0.82));
}

.empty-state-icon {
  color: var(--streab-ui-blue);
  text-shadow: none;
}

.skeleton-container {
  background: transparent;
}

.skeleton-card,
.skeleton-placeholder,
.skeleton-card .thumb,
.skeleton-card .line {
  background: rgba(255, 255, 255, 0.64);
}

#streab-nuvem-scope[data-streab-theme="dark"] .skeleton-card,
#streab-nuvem-scope[data-streab-theme="dark"] .skeleton-placeholder,
#streab-nuvem-scope[data-streab-theme="dark"] .skeleton-card .thumb,
#streab-nuvem-scope[data-streab-theme="dark"] .skeleton-card .line {
  background: rgba(255, 255, 255, 0.08);
}

.curso-modulos-accordion {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.modulo-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 16px;
  border: 1px solid var(--streab-ui-line);
  border-radius: var(--streab-radius-md);
  background: var(--streab-ui-soft);
  color: var(--streab-ui-ink);
  cursor: pointer;
  text-align: left;
}

.modulo-toggle:hover,
.modulo-toggle.active {
  border-color: var(--streab-ui-blue);
  background: rgba(78, 167, 255, 0.12);
}

.modulo-toggle-title {
  color: var(--streab-ui-ink);
  font-size: 1.1rem;
  font-weight: 700;
}

.modulo-toggle-icon {
  color: var(--streab-ui-muted);
  transition: transform 0.25s ease;
}

.modulo-toggle.active .modulo-toggle-icon {
  transform: rotate(180deg);
}

.modulo-videos-panel {
  max-height: 0;
  margin-left: 15px;
  padding: 0 10px;
  overflow: hidden;
  border-left: 2px solid var(--streab-ui-line);
  transition: max-height 0.3s ease-in-out;
}

/* Mindmaps bridge --------------------------------------------------- */

#mindmaps-section:not([hidden]) {
  display: block;
  margin-top: 0;
}

#painel-principal-container:has(#mindmaps-section:not([hidden])) .main-header-sticky {
  position: sticky;
  z-index: 2;
  width: auto;
  margin-right: -32px;
  margin-left: -32px;
  padding-right: 32px;
  padding-left: 32px;
  margin-bottom: 0;
  border-bottom-color: rgba(15, 23, 42, 0.08);
  box-shadow: 0 18px 34px rgba(15, 23, 42, 0.08);
}

#streab-nuvem-scope[data-streab-theme="dark"] #painel-principal-container:has(#mindmaps-section:not([hidden])) .main-header-sticky {
  border-bottom-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.28);
}

#mindmaps-section:not([hidden]) {
  width: calc(100% + 64px);
  max-width: none;
  margin-right: -32px;
  margin-left: -32px;
  padding: 28px 32px 0;
  background: transparent;
}

#streab-nuvem-scope[data-streab-theme="dark"] #mindmaps-section:not([hidden]) {
  background: transparent;
}

#streab-main-content:has(#mindmaps-section:not([hidden])) {
  position: relative;
  overflow: hidden;
}

#streab-main-content:has(#mindmaps-section:not([hidden]))::before {
  content: "";
  position: absolute;
  top: 96px;
  right: 0;
  left: 0;
  height: 260px;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.1), rgba(15, 23, 42, 0.02) 92px, transparent 180px),
    linear-gradient(to right, rgba(15, 23, 42, 0.028) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 23, 42, 0.024) 1px, transparent 1px);
  background-size: auto, 48px 48px, 48px 48px;
  background-position: left top;
}

#streab-nuvem-scope[data-streab-theme="dark"] #streab-main-content:has(#mindmaps-section:not([hidden]))::before {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.018) 92px, transparent 180px),
    linear-gradient(to right, rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
  background-size: auto, 48px 48px, 48px 48px;
}

#streab-main-content:has(#mindmaps-section:not([hidden])) .painel-container {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: none;
  height: 100%;
  margin: 0;
  padding-bottom: 18px;
  background: transparent;
}

#streab-nuvem-scope[data-streab-theme="dark"] #streab-main-content:has(#mindmaps-section:not([hidden])) .painel-container {
  background: transparent;
}

#painel-principal-container:has(#mindmaps-section:not([hidden])) {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  height: 100%;
  min-height: 0;
  overflow: hidden;
  background: transparent;
}

#mindmaps-section:not([hidden]) .mindmaps-shell {
  height: 100%;
  min-height: 0;
}

#mindmaps-section:not([hidden]) .mindmaps-workbench {
  min-width: 0;
}

#mindmaps-section:not([hidden]) .mindmaps-editor-header,
#mindmaps-section:not([hidden]) .mindmaps-toolbar,
#mindmaps-section:not([hidden]) .mindmaps-editor-footer {
  min-width: 0;
}

#mindmaps-section:not([hidden]) .mindmaps-toolbar {
  justify-content: flex-end;
}

/* Responsive -------------------------------------------------------- */

@media (max-width: 1800px) {
  #mindmaps-section:not([hidden]) .mindmaps-shell {
    grid-template-columns: minmax(250px, 300px) minmax(0, 1fr);
    gap: 14px;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-header {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  #mindmaps-section:not([hidden]) .mindmaps-title-input {
    flex: 1 1 100%;
  }

  #mindmaps-section:not([hidden]) .mindmaps-toolbar {
    width: 100%;
    justify-content: flex-start;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-grid {
    grid-template-columns: minmax(300px, 34%) 8px minmax(0, 1fr);
  }

  #mindmaps-section:not([hidden]) .mindmaps-resize-handle {
    display: block;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-pane {
    min-height: 0;
    border-bottom: 1px solid var(--streab-ui-line);
  }

  #mindmaps-section:not([hidden]) .mindmaps-preview-pane {
    min-height: 0;
  }
}

@media (min-width: 992px) and (max-width: 1480px) {
  .main-header-sticky .header-content {
    align-items: flex-start;
    flex-direction: column;
  }

  .main-header-title,
  #filtros-e-busca-container {
    flex: 0 0 auto !important;
  }

  #filtros-e-busca-container {
    width: 100%;
    max-width: none;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .busca-global-wrapper {
    max-width: min(100%, 520px);
  }

  #mindmaps-section:not([hidden]) .mindmaps-shell {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 0;
  }

  #mindmaps-section:not([hidden]) .mindmaps-library {
    max-height: 260px;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  #mindmaps-section:not([hidden]) .mindmaps-resize-handle {
    display: none;
  }
}

@media (max-width: 991px) {
  html:has(#streab-nuvem-scope),
  body:has(#streab-nuvem-scope),
  html,
  body,
  body.page-template-default,
  body.streab-streaming-template {
    height: auto !important;
    min-height: 100% !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }

  #streab-nuvem-scope {
    position: relative !important;
    inset: auto !important;
    width: 100vw !important;
    height: auto !important;
    min-height: 100svh !important;
    overflow-x: hidden !important;
    overflow-y: visible !important;
    touch-action: pan-y;
    overscroll-behavior-y: auto;
  }

  #streab-main-interface {
    display: block;
    height: auto !important;
    min-height: 100dvh !important;
    overflow: visible !important;
    padding: 0;
  }

  #streab-main-content {
    border: 0;
    border-radius: 0;
    overflow: visible !important;
  }

  #mindmaps-section:not([hidden]) {
    width: 100%;
    margin-right: 0;
    margin-left: 0;
    padding: 18px 0 0;
  }

  #streab-sidebar {
    border-radius: 0 24px 24px 0;
    box-shadow: 20px 0 60px rgba(15, 23, 42, 0.2);
  }

  .painel-container {
    padding: 0 16px 38px;
  }

  .main-header-sticky {
    margin: 0 -16px 20px;
    padding: 76px 16px 16px;
    border-radius: 0;
  }

  .main-header-sticky .header-content {
    align-items: stretch;
    flex-direction: column;
  }

  .main-header-title,
  #filtros-e-busca-container {
    flex: 0 0 auto !important;
  }

  #filtros-e-busca-container,
  .filtro-grupo {
    width: 100%;
    max-width: none;
    flex-wrap: wrap;
  }

  .busca-global-wrapper,
  #input-busca-global,
  .custom-select-wrapper,
  .custom-select-wrapper .select-selected {
    width: 100%;
    min-width: 0;
    max-width: none;
  }

  .busca-global-wrapper,
  .filtro-grupo,
  .filtro-grupo .custom-select-wrapper,
  #btn-select-mode,
  .streab-theme-toggle {
    flex: 0 0 auto !important;
  }

  .filtro-grupo .custom-select-wrapper {
    flex: 1 1 auto !important;
  }

  #btn-select-mode,
  .streab-theme-toggle {
    flex: 1 1 auto !important;
  }

  .hero-section {
    min-height: 330px;
    border-radius: 24px;
  }

  .hero-content {
    width: 100%;
    max-width: 100%;
  }

  #hero-title {
    font-size: clamp(1.85rem, 8vw, 2.45rem);
  }
}

@media (max-width: 768px) {
  .main-header-sticky {
    min-height: 0;
    margin-bottom: 16px;
    padding-top: 82px;
    padding-bottom: 14px;
  }

  #filtros-e-busca-container {
    gap: 12px;
  }

  .busca-global-wrapper {
    flex-basis: auto !important;
    height: auto;
  }

  .filtro-grupo {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    flex-basis: auto !important;
  }

  .filtro-grupo .custom-select-wrapper {
    flex: initial;
  }

  .streab-theme-toggle {
    flex-basis: auto !important;
    width: min(180px, 100%);
    margin-inline: auto;
  }

  #input-busca-global,
  .custom-select-wrapper .select-selected,
  #btn-select-mode,
  .streab-theme-toggle {
    height: 48px;
  }

  #hero-and-header-container {
    margin-top: 0;
    margin-bottom: 18px;
  }

  .header-actions,
  .qr-widget {
    display: none !important;
  }

  .hero-section {
    min-height: 0 !important;
    height: auto !important;
    padding: 18px !important;
    aspect-ratio: 16 / 9;
  }

  .hero-section::before {
    inset: 8px;
  }

  #hero-title {
    max-width: 76%;
    font-size: clamp(1.35rem, 5.8vw, 2rem);
    line-height: 1.08;
    -webkit-line-clamp: 2;
  }

  #hero-subtitle {
    margin-top: 8px;
    margin-bottom: 14px;
    font-size: 0.9rem;
  }

  #hero-play-button {
    min-height: 42px;
    padding: 0 18px;
    font-size: 0.95rem;
  }

  .videos-grid,
  .videos-grid.is-grid-view {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin: 0;
    padding: 0 0 20px;
    overflow-x: hidden;
    mask-image: none;
    -webkit-mask-image: none;
  }

  .videos-grid .video-card-wrapper,
  .video-card-wrapper {
    width: 100%;
  }

  .video-card {
    transform: none;
  }

  .video-card-content {
    position: relative;
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }

  .video-card-title-static,
  .video-thumb-container::after {
    display: none;
  }
}

@media (max-width: 520px) {
  .main-header-title {
    flex: 0 0 auto !important;
    font-size: 1.65rem;
  }

  .main-header-sticky {
    min-height: 0;
    margin-bottom: 12px;
    padding: 76px 14px 12px;
  }

  .filtro-grupo {
    grid-template-columns: 1fr;
  }

  #btn-select-mode,
  .streab-theme-toggle {
    width: 100%;
  }

  .hero-section {
    min-height: 0 !important;
    padding: 14px !important;
    aspect-ratio: 4 / 3;
  }

  #hero-play-button {
    width: auto;
    justify-content: center;
  }

  #streab-generic-modal {
    align-items: flex-start;
    padding: 14px;
    padding-top: max(14px, env(safe-area-inset-top));
  }

  #streab-generic-modal .streab-modal-content {
    width: 100%;
    max-height: calc(100dvh - 28px);
    padding: 24px 18px 20px;
    border-radius: 16px;
  }

  #streab-generic-modal .streab-modal-content h2,
  #streab-generic-modal #modal-title {
    margin: 0 40px 18px;
    font-size: 1.12rem;
  }

  #streab-generic-modal .btn-fechar-modal {
    top: 12px;
    right: 12px;
  }
}

/* Final modal reset: keep generic dialogs independent from legacy glass styles. */
#streab-generic-modal.streab-modal-overlay {
  background: rgba(15, 23, 42, 0.46) !important;
  backdrop-filter: blur(8px) saturate(110%) !important;
  -webkit-backdrop-filter: blur(8px) saturate(110%) !important;
}

#streab-generic-modal .streab-modal-content {
  width: min(520px, calc(100vw - 36px)) !important;
  max-width: 520px !important;
  max-height: calc(100dvh - 36px) !important;
  overflow: auto !important;
  padding: 32px !important;
  border: 1px solid rgba(15, 23, 42, 0.12) !important;
  border-radius: 18px !important;
  background: #ffffff !important;
  color: #0d1117 !important;
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.24) !important;
  text-align: center !important;
}

#streab-generic-modal[data-streab-theme="dark"] .streab-modal-content {
  border-color: rgba(255, 255, 255, 0.14) !important;
  background: #171c26 !important;
  color: #f8fafc !important;
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.5) !important;
}

#streab-generic-modal #modal-title,
#streab-generic-modal .streab-modal-content h2 {
  margin: 0 42px 22px !important;
  color: inherit !important;
  font-size: 1.35rem !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
}

#streab-generic-modal #modal-body {
  color: inherit !important;
}

#streab-generic-modal .streab-modal-content input[type="text"],
#streab-generic-modal .streab-modal-content textarea,
#streab-generic-modal .streab-modal-content select {
  width: 100% !important;
  min-height: 50px !important;
  margin: 0 0 16px !important;
  padding: 0 16px !important;
  border: 1px solid rgba(15, 23, 42, 0.14) !important;
  border-radius: 14px !important;
  background: #f8fafc !important;
  color: #0d1117 !important;
  font-size: 0.98rem !important;
}

#streab-generic-modal[data-streab-theme="dark"] .streab-modal-content input[type="text"],
#streab-generic-modal[data-streab-theme="dark"] .streab-modal-content textarea,
#streab-generic-modal[data-streab-theme="dark"] .streab-modal-content select {
  border-color: rgba(255, 255, 255, 0.14) !important;
  background: #0f172a !important;
  color: #f8fafc !important;
}

#streab-generic-modal .streab-modal-content input::placeholder,
#streab-generic-modal .streab-modal-content textarea::placeholder {
  color: #7e8798 !important;
  opacity: 1 !important;
}

#streab-generic-modal .streab-modal-content .btn-principal {
  min-height: 50px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: #0d1117 !important;
  color: #ffffff !important;
}

#streab-generic-modal[data-streab-theme="dark"] .streab-modal-content .btn-principal {
  background: #ffffff !important;
  color: #0d1117 !important;
}

#streab-generic-modal .btn-fechar-modal {
  top: 16px !important;
  right: 16px !important;
  width: 36px !important;
  height: 36px !important;
  border: 1px solid rgba(15, 23, 42, 0.12) !important;
  border-radius: 999px !important;
  background: #f8fafc !important;
  color: #0d1117 !important;
}

#streab-generic-modal[data-streab-theme="dark"] .btn-fechar-modal {
  border-color: rgba(255, 255, 255, 0.14) !important;
  background: #202736 !important;
  color: #f8fafc !important;
}

#streab-generic-modal #conteudo-atribuir-curso .tag-curso-modal {
  border: 1px solid rgba(15, 23, 42, 0.12) !important;
  background: #f8fafc !important;
  color: #0d1117 !important;
}

#streab-generic-modal[data-streab-theme="dark"] #conteudo-atribuir-curso .tag-curso-modal {
  border-color: rgba(255, 255, 255, 0.14) !important;
  background: #0f172a !important;
  color: #f8fafc !important;
}

@media (max-width: 520px) {
  #streab-generic-modal .streab-modal-content {
    width: calc(100vw - 28px) !important;
    max-height: calc(100dvh - 28px) !important;
    padding: 24px 18px 20px !important;
  }

  #streab-generic-modal #modal-title,
  #streab-generic-modal .streab-modal-content h2 {
    margin: 0 40px 18px !important;
    font-size: 1.12rem !important;
  }
}

/* Final mindmaps fit: keep the editor footer and canvas controls visible. */
@media (min-width: 992px) {
  #streab-main-content:has(#mindmaps-section:not([hidden])) {
    position: relative !important;
    overflow: hidden !important;
  }

  #streab-main-content:has(#mindmaps-section:not([hidden]))::before {
    content: "" !important;
    position: absolute !important;
    top: 96px !important;
    right: 0 !important;
    left: 0 !important;
    height: 260px !important;
    pointer-events: none !important;
    background:
      linear-gradient(180deg, rgba(15, 23, 42, 0.1), rgba(15, 23, 42, 0.02) 92px, transparent 180px),
      linear-gradient(to right, rgba(15, 23, 42, 0.028) 1px, transparent 1px),
      linear-gradient(to bottom, rgba(15, 23, 42, 0.024) 1px, transparent 1px) !important;
    background-size: auto, 48px 48px, 48px 48px !important;
    background-position: left top !important;
  }

  #streab-nuvem-scope[data-streab-theme="dark"] #streab-main-content:has(#mindmaps-section:not([hidden]))::before {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.018) 92px, transparent 180px),
      linear-gradient(to right, rgba(255, 255, 255, 0.035) 1px, transparent 1px),
      linear-gradient(to bottom, rgba(255, 255, 255, 0.028) 1px, transparent 1px) !important;
    background-size: auto, 48px 48px, 48px 48px !important;
    background-position: left top !important;
  }

  #streab-main-content:has(#mindmaps-section:not([hidden])) .painel-container {
    position: relative !important;
    z-index: 1 !important;
    width: 100% !important;
    max-width: none !important;
    height: 100% !important;
    margin: 0 !important;
    padding-bottom: 18px !important;
    overflow: hidden !important;
    background: transparent !important;
  }

  #streab-nuvem-scope[data-streab-theme="dark"] #streab-main-content:has(#mindmaps-section:not([hidden])) .painel-container {
    background: transparent !important;
  }

  #painel-principal-container:has(#mindmaps-section:not([hidden])) {
    display: block !important;
    height: 100% !important;
    overflow: hidden !important;
    background: transparent !important;
  }

  #mindmaps-section:not([hidden]) {
    height: calc(100dvh - 174px) !important;
    min-height: 0 !important;
    max-height: calc(100dvh - 174px) !important;
    overflow: hidden !important;
    background: transparent !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-shell {
    height: 100% !important;
    min-height: 0 !important;
    max-height: 100% !important;
    grid-template-columns: minmax(250px, 300px) minmax(0, 1fr) !important;
    overflow: hidden !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-library,
  #mindmaps-section:not([hidden]) .mindmaps-workbench,
  #mindmaps-section:not([hidden]) .mindmaps-editor-grid,
  #mindmaps-section:not([hidden]) .mindmaps-editor-pane,
  #mindmaps-section:not([hidden]) .mindmaps-preview-pane,
  #mindmaps-section:not([hidden]) .mindmaps-preview-canvas {
    min-height: 0 !important;
    max-height: 100% !important;
    overflow: hidden !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-workbench {
    grid-template-rows: auto minmax(0, 1fr) !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-grid {
    height: 100% !important;
    grid-template-columns: minmax(300px, 34%) 8px minmax(0, 1fr) !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-pane {
    display: flex !important;
    flex-direction: column !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-body {
    flex: 1 1 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-host,
  #mindmaps-section:not([hidden]) .mindmaps-textarea {
    min-height: 0 !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-footer {
    flex: 0 0 auto !important;
    min-height: 48px !important;
    padding: 8px 10px !important;
    overflow: visible !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-editor-footer .mindmaps-button {
    min-height: 34px !important;
    font-size: 0.76rem !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-panzoom-toolbar {
    right: 14px !important;
    bottom: 14px !important;
  }
}

@media (min-width: 992px) and (max-height: 900px) {
  #mindmaps-section:not([hidden]) {
    height: calc(100dvh - 192px) !important;
    max-height: calc(100dvh - 192px) !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-library-header,
  #mindmaps-section:not([hidden]) .mindmaps-editor-header {
    padding-top: 9px !important;
    padding-bottom: 9px !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-search {
    padding-top: 9px !important;
    padding-bottom: 9px !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-button,
  #mindmaps-section:not([hidden]) .mindmaps-icon-button,
  #mindmaps-section:not([hidden]) .mindmaps-select,
  #mindmaps-section:not([hidden]) .mindmaps-switch {
    min-height: 34px !important;
  }

  #mindmaps-section:not([hidden]) .mindmaps-icon-button {
    width: 34px !important;
  }
}

/* Final mobile sidebar and bulk action polish. */
.bulk-actions-bar {
  max-width: min(720px, calc(100vw - 28px)) !important;
  padding: 12px 14px !important;
  border: 1px solid rgba(15, 23, 42, 0.1) !important;
  border-radius: 18px !important;
  background: rgba(255, 255, 255, 0.94) !important;
  color: #0d1117 !important;
  box-shadow: 0 24px 64px rgba(15, 23, 42, 0.18) !important;
  backdrop-filter: blur(18px) saturate(135%) !important;
  -webkit-backdrop-filter: blur(18px) saturate(135%) !important;
}

#streab-nuvem-scope[data-streab-theme="dark"] ~ .bulk-actions-bar {
  border-color: rgba(255, 255, 255, 0.12) !important;
  background: rgba(23, 28, 38, 0.94) !important;
  color: #f8fafc !important;
}

.bulk-actions-bar .count {
  min-width: 38px !important;
  min-height: 38px !important;
  padding: 0 12px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  border-radius: 12px !important;
  background: linear-gradient(135deg, var(--streab-ui-blue), var(--streab-ui-violet)) !important;
  color: #ffffff !important;
}

.bulk-actions-bar span:not(.count) {
  color: inherit !important;
  font-weight: 800 !important;
  white-space: nowrap !important;
}

.bulk-actions-bar button {
  min-height: 42px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: #0d1117 !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  white-space: nowrap !important;
}

.bulk-actions-bar button.btn-cancelar {
  border: 1px solid rgba(15, 23, 42, 0.12) !important;
  background: #ffffff !important;
  color: #0d1117 !important;
}

#streab-nuvem-scope[data-streab-theme="dark"] ~ .bulk-actions-bar button {
  background: #ffffff !important;
  color: #0d1117 !important;
}

#streab-nuvem-scope[data-streab-theme="dark"] ~ .bulk-actions-bar button.btn-cancelar {
  border-color: rgba(255, 255, 255, 0.16) !important;
  background: #0d1117 !important;
  color: #ffffff !important;
}

@media (max-width: 991px) {
  #streab-sidebar {
    height: 100svh !important;
    max-height: 100svh !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
    -webkit-overflow-scrolling: touch !important;
  }

  #streab-sidebar::-webkit-scrollbar {
    width: 8px;
  }

  #streab-sidebar::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.24);
  }

  #streab-nuvem-scope[data-streab-theme="dark"] #streab-sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.28);
  }

  .bulk-actions-bar {
    left: 14px !important;
    right: 14px !important;
    bottom: 14px !important;
    width: auto !important;
    max-width: none !important;
    justify-content: center !important;
    gap: 10px !important;
    transform: translateY(200%) !important;
  }

  .bulk-actions-bar.show {
    transform: translateY(0) !important;
  }
}

@media (max-width: 560px) {
  .bulk-actions-bar {
    align-items: stretch !important;
    flex-wrap: wrap !important;
  }

  .bulk-actions-bar .count {
    flex: 0 0 38px !important;
  }

  .bulk-actions-bar span:not(.count) {
    flex: 1 1 calc(100% - 52px) !important;
    align-self: center !important;
  }

  .bulk-actions-bar button {
    flex: 1 1 calc(50% - 6px) !important;
  }
}
