#globalSearchArea { position: relative; width: min(360px, 42vw); min-width: 0; }
.dash-topbar-right { display: flex; align-items: center; justify-content: flex-end; gap: 12px; min-width: 0; }
.access-locked .dash-sidebar, .access-locked .dash-topbar { display: none !important; }
.access-locked .dash-main { margin-left: 0; }
.access-lock-reason { margin: 0 0 24px; padding: 14px 16px; text-align: left; background: rgba(255, 26, 26, .08); border: 1px solid rgba(255, 26, 26, .32); border-radius: 8px; }
.access-lock-reason-warning { background: rgba(255, 170, 0, .08); border-color: rgba(255, 170, 0, .32); }
.access-lock-reason span { display: block; color: var(--text-dim); font: .7rem var(--font-mono); letter-spacing: .5px; text-transform: uppercase; margin-bottom: 7px; }
.access-lock-reason p { margin: 0; color: #fff; line-height: 1.5; overflow-wrap: anywhere; }
.dash-sidebar .dash-nav-item[data-view^="courses-"] { display: none !important; }
.dash-sidebar .sidebar-config-old { display: none !important; }
.dash-sidebar .sidebar-tools-old { display: none !important; }
.community-config { margin-top: 4px; border-top: 1px solid var(--border-subtle); border-radius: 0 !important; padding-top: 14px !important; }
.config-logout-section { display: flex; justify-content: center; margin: 28px auto 0; }
.config-logout-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; flex-shrink: 0; min-width: 190px; padding: 12px 18px; color: #ff8b8b; border: 1px solid rgba(255, 26, 26, .55); background: rgba(255, 26, 26, .1); }
.config-logout-btn:hover { color: #fff; background: rgba(255, 26, 26, .28); box-shadow: 0 0 18px rgba(255,26,26,.18); }
.courses-hub-header { max-width: 720px; margin-bottom: 28px; }
.courses-hub-kicker { color: var(--neon); font: 700 .72rem var(--font-mono); letter-spacing: 1.3px; }
.courses-hub-header h2 { margin: 9px 0; color: #fff; font: 700 clamp(1.6rem, 3vw, 2.25rem) var(--font-display); letter-spacing: 1px; }
.courses-hub-header p { margin: 0; color: var(--text-muted); line-height: 1.6; }
.course-category-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.course-category-card { min-height: 170px; padding: 22px; text-align: left; color: #fff; border: 1px solid var(--border-subtle); border-radius: 12px; background: linear-gradient(145deg, rgba(22, 18, 28, .98), rgba(8, 8, 10, .98)); cursor: pointer; transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
.course-category-card:hover { transform: translateY(-3px); border-color: rgba(255, 26, 26, .72); box-shadow: 0 12px 30px rgba(0, 0, 0, .35), 0 0 18px rgba(255, 26, 26, .16); }
.course-category-icon { display: block; width: 38px; height: 38px; margin-bottom: 22px; color: var(--neon); font: 700 1.6rem/38px var(--font-mono); text-align: center; border: 1px solid rgba(255, 26, 26, .35); border-radius: 8px; background: rgba(255, 26, 26, .08); }
.course-category-card strong, .course-category-card small { display: block; }
.course-category-card strong { font: 700 1rem var(--font-display); letter-spacing: .6px; }
.course-category-card small { margin-top: 8px; color: var(--text-muted); line-height: 1.45; }
.hype-btn { padding: 8px 15px !important; font-size: .92rem !important; min-height: 42px; }
.hype-btn .hype-count { font-size: .8rem !important; padding: 2px 7px !important; }
.projects-instagram-note { display: flex; align-items: center; gap: 14px; max-width: 760px; margin-top: 18px; padding: 15px 18px; color: #fff; text-decoration: none; border: 1px solid rgba(240, 148, 51, .48); border-radius: 10px; background: linear-gradient(100deg, rgba(240, 148, 51, .17), rgba(220, 39, 67, .18), rgba(188, 24, 136, .16)); box-shadow: 0 8px 26px rgba(188, 24, 136, .13); transition: transform .2s ease, box-shadow .2s ease; }
.projects-instagram-note:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(188, 24, 136, .25); }
.projects-instagram-note > span:nth-child(2) { flex: 1; }
.projects-instagram-note strong, .projects-instagram-note small { display: block; }
.projects-instagram-note strong { font-size: .94rem; }
.projects-instagram-note small { margin-top: 3px; color: rgba(255,255,255,.78); font-size: .8rem; }
.projects-instagram-note b { flex-shrink: 0; padding: 8px 10px; border-radius: 6px; background: rgba(0,0,0,.28); font: 700 .72rem var(--font-mono); letter-spacing: .3px; }
.projects-instagram-icon { flex: 0 0 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; font: 700 1.6rem var(--font-mono); background: rgba(0,0,0,.28); color: #fff; }
.global-search-input { width: 100%; background: rgba(0,0,0,.35); border: 1px solid var(--border-subtle); color: #fff; border-radius: 6px; padding: 9px 12px; font-family: var(--font-mono); }
.global-search-panel, .notification-tray { position: absolute; z-index: 30; top: calc(100% + 8px); right: 0; width: min(420px, 92vw); max-height: 420px; overflow: auto; background: #121012; border: 1px solid var(--border-neon); border-radius: 8px; box-shadow: 0 16px 42px rgba(0,0,0,.55); padding: 10px; }
.global-search-result, .notification-item { display: block; width: 100%; text-align: left; border: 0; border-bottom: 1px solid var(--border-subtle); background: transparent; color: var(--text-muted); padding: 12px; cursor: pointer; }
.global-search-result:hover, .notification-item.unread { background: rgba(255,26,26,.09); }
.global-search-result span { display: block; color: var(--neon); font: 700 .68rem var(--font-mono); text-transform: uppercase; margin-bottom: 4px; }
.global-search-result strong, .notification-item strong { color: #fff; display: block; }
.global-search-result small, .notification-item p, .notification-item time { display: block; margin-top: 5px; color: var(--text-dim); font-size: .78rem; }
.notification-toggle { position: relative; background: transparent; color: #fff; border: 1px solid var(--border-subtle); border-radius: 6px; padding: 8px; cursor: pointer; }
.notification-badge { position: absolute; right: -7px; top: -7px; min-width: 18px; height: 18px; align-items: center; justify-content: center; border-radius: 50%; background: var(--neon); color: #000; font: 700 .66rem var(--font-mono); }
.notification-empty, .search-empty { color: var(--text-dim); text-align: center; padding: 20px; font: .82rem var(--font-mono); }

@media (max-width: 1100px) and (min-width: 769px) {
  #globalSearchArea { width: 220px; }
  .dash-topbar { padding-inline: 22px; }
  .dash-title { font-size: 1rem; letter-spacing: 1px; }
}

@media (max-width: 768px) {
  .dash-topbar { align-items: center; flex-wrap: wrap; gap: 10px; padding: 12px 16px; }
  .dash-topbar-left { min-width: 0; flex: 1 1 auto; gap: 10px; }
  .dash-title { font-size: .96rem; letter-spacing: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .dash-topbar-right { width: 100%; gap: 8px; justify-content: flex-end; }
  #globalSearchArea { flex: 1; width: auto; }
  .global-search-input { min-width: 0; padding: 10px; font-size: .78rem; }
  .dash-user-info { display: none; }
  .dash-user { gap: 0; }
  .dash-avatar { width: 38px; height: 38px; }
  .notification-toggle { min-width: 38px; min-height: 38px; }
  .global-search-panel, .notification-tray { position: fixed; top: 116px; left: 12px; right: 12px; width: auto; max-height: min(60vh, 420px); }

  /* Painel administrativo pensado para toque: abas visíveis sem rolagem horizontal. */
  #view-admin-panel { min-width: 0; }
  #view-admin-panel .admin-tab-nav {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow: visible !important;
    white-space: normal !important;
    gap: 8px !important;
    margin-bottom: 20px !important;
    padding-bottom: 0 !important;
    border-bottom: 0 !important;
  }
  #view-admin-panel .admin-tab-btn {
    width: 100%;
    min-width: 0 !important;
    min-height: 54px !important;
    justify-content: center;
    padding: 9px 8px !important;
    font-size: .72rem !important;
    line-height: 1.15;
    white-space: normal !important;
    text-align: center;
  }
  #view-admin-panel .admin-tab-btn span { white-space: normal; }
  #view-admin-panel .admin-tab-btn:last-child { grid-column: span 2; }
  #view-admin-panel .admin-tab-content > div { width: 100%; box-sizing: border-box; padding: 18px !important; }
  #view-admin-panel .admin-action-btn { width: 100%; flex: 1 1 100% !important; min-height: 46px; }
  #view-admin-panel #userMgmtStatusFilters { flex-wrap: nowrap !important; }
  #view-admin-panel .user-mgmt-name-row, #view-admin-panel .user-mgmt-meta { flex-wrap: wrap; }
  .course-category-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .course-category-card { min-height: 150px; padding: 16px; }
  .course-category-icon { margin-bottom: 14px; }
  .hype-btn { padding: 8px 12px !important; font-size: .86rem !important; }
  .projects-instagram-note { align-items: flex-start; flex-wrap: wrap; gap: 10px; }
  .projects-instagram-note b { width: 100%; text-align: center; }
  .config-logout-section { margin-top: 22px; }
  .config-logout-btn { width: 100%; }
}

@media (max-width: 380px) {
  .dash-title { font-size: .83rem; }
  .dash-topbar { padding-inline: 12px; }
  #view-admin-panel .admin-tab-btn { font-size: .66rem !important; }
  .course-category-grid { grid-template-columns: 1fr; }
}
