/**
 * AI Innovation Hub - Custom styles
 * Complements Bootstrap; load after Bootstrap CSS.
 */

:root {
  /*
     * CUNY brand palette (official specs: PMS / CMYK / RGB / HEX)
     * Blue PMS 286 C | Indigo PMS 2768 C | Azure PMS 285 C | Deep Cyan PMS 305 C
     * Sky PMS 7451 C | Lemonade PMS 803 C | Cream — digital placeholder
     */
  --cuny-blue: #0033a1;
  --cuny-indigo: #011d49;
  --cuny-azure: #1f5cff;
  --cuny-deep-cyan: #00afef;
  --cuny-sky: #a3c9ff;
  --cuny-lemonade: #ffee1d;
  --cuny-cream: #faf7f0;

  /* App semantics (map to brand) */
  --ai-hub-primary: var(--cuny-blue);
  --ai-hub-dark: var(--cuny-indigo);
  --ai-hub-accent: var(--cuny-lemonade);
  /* Section / hero fallback: Sky-tinted wash on white */
  --ai-hub-light-bg: #ffffff;
}

body {
  font-family: "Libre Franklin", sans-serif;
  color: var(--ai-hub-dark);
  background-color: #fff;
}

/* Hero: light background image; CUNY blue typography (:root tokens) */
.ai-hub-hero {
  position: relative;
  overflow: hidden;
  width: 100%;
  color: var(--ai-hub-dark);
  padding: 1.75rem 0 2rem;
  min-height: 14rem;
  --hero-font-base: clamp(0.52rem, 0.3rem + 1.05vw, 1.5rem);
}

.ai-hub-hero .container {
  position: relative;
  z-index: 1;
}

.ai-hub-hero__layout {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
}

.ai-hub-hero__top {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
  gap: clamp(0.1rem, 1.1vw, 0.5rem);
}

.ai-hub-hero__graphic-wrap {
  flex: 0 1 auto;
}

.ai-hub-hero__head-block {
  flex: 0 1 auto;
  min-width: 0;
  width: min(100%, 960px);
  text-align: center;
}

.ai-hub-hero__bottom {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: clamp(0.6rem, 2.8vw, 2rem);
  width: 100%;
  text-align: center;
}

.ai-hub-hero__events {
  flex: 0 0 auto;
  min-width: 0;
  max-width: min(100%, 960px);
  text-align: center;
}

.ai-hub-hero__qr-aside {
  flex: 0 1 auto;
}

.ai-hub-hero__graphic {
  display: block;
  width: clamp(110px, 25vw, 220px);
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}

@media (min-width: 576px) {
  .ai-hub-hero__graphic {
    width: clamp(125px, 24vw, 240px);
    margin-left: auto;
    margin-right: auto;
  }
}

@media (min-width: 992px) {
  .ai-hub-hero__graphic {
    width: clamp(160px, 18vw, 380px);
  }
}
.ai-hub-hero__headline {
  font-size: calc(var(--hero-font-base) * 2.6);
  font-weight: 800;
  line-height: 0.92;
  color: var(--ai-hub-primary);
  letter-spacing: 0.02em;
}

.ai-hub-hero__headline-line + .ai-hub-hero__headline-line {
  margin-top: 0.01rem;
}

.ai-hub-hero__subtitle {
  font-size: calc(var(--hero-font-base) * 1.55);
  font-weight: 700;
  color: var(--cuny-deep-cyan);
  letter-spacing: clamp(0.08em, 0.28vw, 0.24em);
  text-transform: uppercase;
}

.ai-hub-hero__tagline {
  font-size: calc(var(--hero-font-base) * 0.75);
  font-weight: 100;
  color: var(--ai-hub-primary);
  letter-spacing: clamp(0.08em, 0.22vw, 0.2em);
  text-transform: uppercase;
}

.ai-hub-hero__event-line {
  font-size: calc(var(--hero-font-base) * 1.5);
  line-height: 1.12;
  font-weight: 600;
  color: var(--cuny-blue);
}

.ai-hub-hero__cta {
  font-size: calc(var(--hero-font-base) * 1.8);
  font-weight: 600;
  color: var(--cuny-deep-cyan);
  letter-spacing: clamp(0.04em, 0.32vw, 0.1em);
  text-transform: uppercase;
}

.ai-hub-hero__qr {
  width: clamp(85px, 18vw, 160px);
  max-width: 100%;
  height: auto;
  display: inline-block;
}

.ai-hub-section {
  padding: 2.5rem 0;
}

.ai-hub-card {
  border: none;
  box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.08);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.ai-hub-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 0.5rem 1.25rem rgba(0, 0, 0, 0.12);
}

.ai-hub-tracks-intro {
  font-size: 0.95rem;
}

.ai-hub-tracks-intro,
.ai-hub-tracks-intro *,
.ai-hub-section-intro,
.ai-hub-section-intro * {
  color: inherit;
  text-align: inherit;
}

.ai-hub-tracks-intro p:last-child,
.ai-hub-section-intro p:last-child {
  margin-bottom: 0;
}

.ai-hub-track-title {
  font-size: 1.15rem;
  line-height: 1.25;
}

.ai-hub-track-description {
  font-size: 0.9rem;
  line-height: 1.5;
}

.ai-hub-date-title {
  font-size: 1.1rem;
  line-height: 1.3;
}

.ai-hub-date-text {
  font-size: 0.95rem;
  line-height: 1.45;
}

.ai-hub-date-text:last-child {
  margin-bottom: 0;
}

/* Goals muted intro text: force muted color even with rich-text tags */
.ai-hub-goals-muted-text,
.ai-hub-goals-muted-text p,
.ai-hub-goals-muted-text div,
.ai-hub-goals-muted-text span,
.ai-hub-goals-muted-text strong,
.ai-hub-goals-muted-text b,
.ai-hub-goals-muted-text em,
.ai-hub-goals-muted-text i,
.ai-hub-goals-muted-text a,
.ai-hub-goals-muted-text li {
  color: var(--bs-secondary-color) !important;
}

/* Testimonials */
.ai-hub-testimonial
{
    background: #f8f9fa;
    border-left: 4px solid var(--bs-primary, #0d6efd);
    border-radius: 0.5rem;
    padding: 1.5rem;
}

.ai-hub-testimonial-quote
{
    font-style: italic;
    font-size: 0.97rem;
    line-height: 1.7;
    color: #333;
    margin: 0;
}

.ai-hub-testimonial-quote p:last-child
{
    margin-bottom: 0;
}

.ai-hub-testimonial-caption
{
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    border-top: 1px solid #dee2e6;
    padding-top: 0.75rem;
}

.ai-hub-testimonial-name
{
    font-weight: 600;
    font-size: 0.95rem;
    color: #212529;
}

.ai-hub-testimonial-role
{
    font-size: 0.85rem;
    color: #6c757d;
}

.ai-hub-footer {
  background-color: var(--cuny-blue);
  border-top: 3px solid var(--cuny-deep-cyan);
  color: rgba(255, 255, 255, 0.85);
  padding: 1rem 0;
}

.ai-hub-footer a {
  color: rgba(255, 255, 255, 0.9);
}

.ai-hub-footer a:hover {
  color: #fff;
}

.list-icon {
  color: var(--ai-hub-primary);
  margin-right: 0.5rem;
  flex-shrink: 0;
  line-height: 1.4;
}

/* Notification bell dropdown - fixed width, text wraps inside */
.notification-dropdown {
  width: 320px;
  max-height: 320px;
  overflow-y: auto;
  overflow-x: hidden;
  padding-left: 0.2rem;
  padding-right: 0.2rem;
}
.notification-dropdown li {
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}
.notification-dropdown li:last-child {
  border-bottom: none;
}
.notification-item {
  white-space: normal;
  word-wrap: break-word;
  overflow-wrap: break-word;
  word-break: break-word;
  line-height: 1.4;
  width: 100%;
  box-sizing: border-box;
  display: block;
  padding-left: 1rem;
  position: relative;
  border-radius: 0.35rem;
}
.notification-item::before {
  content: "";
  position: absolute;
  left: 0.3rem;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--ai-hub-primary);
}
.notification-item:hover {
  background-color: var(--ai-hub-light-bg);
  transform: translateY(+1%);
  transform: translateX(+1%);
  box-shadow: 0 1.5rem 1.25rem rgba(0, 0, 0, 0.12);
}
/* End of Notification bell dropdown - fixed width, text wraps inside */

/* Slightly larger badges for team roles */
.badge.badge-lg {
  font-size: 0.875rem;
  padding: 0.35em 0.65em;
}
/* Same width for Team lead, Member, Invitation pending */
.badge.badge-role {
  min-width: 8.5rem;
  display: inline-block;
  text-align: center;
}

/* Navbar: CUNY Blue + Indigo hover */
.navbar-light .navbar-brand {
  color: var(--ai-hub-primary);
}

.navbar-light .navbar-nav .nav-link {
  color: var(--ai-hub-primary);
}

.navbar-light .navbar-nav .nav-link:hover,
.navbar-light .navbar-brand:hover {
  color: var(--cuny-indigo);
}

.navbar-light .navbar-nav .nav-link.active {
  color: var(--ai-hub-primary);
  font-weight: bold;
}
/* End of Change the color of the navbar to CUNY Colors */

/* Red dot on hamburger when user has notifications */
.navbar-toggler-notification-dot {
  position: absolute;
  top: 0.25rem;
  right: 0.25rem;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #dc3545;
}

/* Notification bell - desktop: open below; mobile: open above */
@media (min-width: 992px) {
  .navbar-notification-dropdown-parent.dropup .navbar-notification-dropdown {
    top: 100% !important;
    bottom: auto !important;
    margin-top: 0.125rem;
    margin-bottom: 0;
  }
}

/* Notification bell - prevent expansion on mobile */
@media (max-width: 991.98px) {
  .navbar-notification-bell-link {
    flex-shrink: 0;
    width: 2.25rem;
    min-width: 2.25rem;
    max-width: 2.25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.25rem !important;
  }
  .navbar-notification-bell-link svg {
    width: 25px;
    height: 20px;
    flex-shrink: 0;
  }
  /* Notification dropdown: relative position so it does not expand the navbar */
  .navbar-collapse .navbar-notification-dropdown {
    position: fixed !important;
    top: 0.5rem !important;
    right: 0.5rem !important;
    left: auto !important;
    bottom: auto !important;
    margin: 0 !important;
    transform: none !important;
  }
}

/* Navbar mobile - overlay menu in a box, does not push content down */
@media (max-width: 991.98px) {
  .navbar .container {
    position: relative;
  }
  .navbar-collapse {
    position: absolute;
    top: 100%;
    right: 0.5rem;
    left: auto;
    width: max-content;
    min-width: -webkit-fill-available;
    margin-top: 0.25rem;
    padding: 1rem;
    background: #fff;
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(0, 0, 0, 0.08);
    z-index: 1050;
    max-height: calc(100vh - 5rem);
    overflow-y: auto;
  }
  .navbar-collapse .navbar-nav {
    margin-left: 0 !important;
    margin-right: 0 !important;
    align-items: flex-end !important;
    width: auto;
  }
  .navbar-collapse .nav-item {
    width: auto;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
  .navbar-collapse .nav-link {
    padding: 0.5rem 0;
    text-align: right;
  }
  .navbar-collapse .nav-item.dropdown .nav-link,
  .navbar-collapse .nav-item.dropup .nav-link {
    display: inline-flex;
    align-items: center;
    padding-left: 0;
  }
  .navbar-collapse .nav-item.ms-3 {
    margin-left: 0 !important;
  }
}
/* End of Navbar mobile - overlay menu in a box, does not push content down */

/* Password change - x trigger next to label, criteria in hover popover */
.password-criteria-trigger {
  cursor: help;
  font-size: 1rem;
  line-height: 1;
  font-weight: bold;
  -webkit-user-select: none;
  user-select: none;
  color: #dc3545;
}
.password-criteria-popover {
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 0.25rem;
  padding: 0.5rem 0.75rem;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 0.375rem;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  z-index: 1050;
  min-width: 14rem;
  font-size: 0.875rem;
}
.password-criterion {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.25rem;
}
.password-criterion:last-child {
  margin-bottom: 0;
}
.password-criterion .criterion-icon {
  display: inline-block;
  width: 1.1em;
  font-weight: bold;
}
.password-criterion.criterion-met .criterion-icon {
  color: #198754;
}
.password-criterion.criterion-unmet .criterion-icon {
  color: #dc3545;
}
.password-criterion.criterion-met .criterion-text {
  color: #198754;
}
.password-criterion.criterion-unmet .criterion-text {
  color: #6c757d;
}

/* ------------------------------------------------------------------ */
/*  Avatar UI                                                         */
/* ------------------------------------------------------------------ */
.ai-hub-avatar-preview {
  width: 96px;
  height: 96px;
  border-radius: 9999px;
  background: var(--ai-hub-light-bg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}
.ai-hub-avatar-preview-sm {
  width: 72px;
  height: 72px;
}
.ai-hub-avatar-image {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  overflow: hidden;
}
.ai-hub-avatar-image-grid {
  width: 64px;
  height: 64px;
  border-radius: 9999px;
  flex-shrink: 0;
}
.ai-hub-avatar-placeholder {
  width: 100%;
  height: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  background: rgba(0, 51, 161, 0.08);
  color: var(--ai-hub-primary);
  font-weight: 800;
  font-size: 1.1rem;
  text-transform: uppercase;
}
.ai-hub-avatar-option {
  cursor: pointer;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  border: 1px solid rgba(0, 0, 0, 0.12);
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.15s ease;
  overflow: hidden;
  text-align: center;
}
.ai-hub-avatar-option:hover {
  border-color: rgba(0, 51, 161, 0.35);
  box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.06);
}
.ai-hub-avatar-option-selected {
  border: 2px solid var(--ai-hub-primary);
  box-shadow: 0 0 0 0.1rem rgba(0, 51, 161, 0.15);
}
.ai-hub-avatar-option .ai-hub-avatar-image-grid {
  margin: 0 auto;
}
.ai-hub-avatar-radio {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
