/* ── UH Brand Colors ── */
:root {
  --uh-black:    #1a1a1a;
  --uh-blue:     #003b6c;
  --uh-blue-dark:#005c99;
  --uh-white:    #ffffff;
  --uh-gray-light: #f5f5f5;
  --uh-gray:     #f0f0f0;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'HelsinkiGrotesk', Arial, sans-serif;
  color: var(--uh-black);
  background: var(--uh-white);
}

/* ── Top Bar ── */
.uh-topbar {
  background-color: var(--uh-black);
  color: var(--uh-white);
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 3px solid var(--uh-blue);
  display: flex;
  justify-content: center;
}


.uh-topbar-inner {
  max-width: 1200px;
  width: 100%;          /* ← add this line */
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  position: relative;
}


.uh-topbar-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--uh-white);
}

.uh-topbar-logo {
  height: 40px;
  filter: brightness(0) invert(1);
}

.uh-topbar-title {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  max-width: 280px;
}

/* ── Navigation ── */
.uh-nav {
  /* desktop: visible by default */
}

.uh-nav-list {
  display: flex;
  list-style: none;
  gap: 0.25rem;
  align-items: center;
}

.uh-nav-link {
  display: block;
  padding: 0.5rem 1rem;
  color: var(--uh-white);
  text-decoration: none;
  font-size: 0.95rem;
  border-radius: 2px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

.uh-nav-link:hover {
  background-color: var(--uh-blue);
}

/* ── Dropdown ── */
.uh-nav-dropdown {
  position: relative;
  list-style: none;
}

.uh-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--uh-white);
  border-top: 3px solid var(--uh-blue);
  min-width: 200px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  list-style: none;
  z-index: 200;
}

.uh-dropdown-menu li a {
  display: block;
  padding: 0.65rem 1rem;
  color: var(--uh-black);
  text-decoration: none;
  font-size: 0.9rem;
  border-bottom: 1px solid var(--uh-gray);
}

.uh-dropdown-menu li a:hover {
  background-color: var(--uh-gray-light);
  color: var(--uh-blue);
}

.uh-nav-dropdown:hover .uh-dropdown-menu,
.uh-nav-dropdown:focus-within .uh-dropdown-menu {
  display: block;
}

/* ── Main Content ── */
.uh-main {
  min-height: calc(100vh - 64px - 120px);
}

/* ── Footer ── */
.uh-footer {
  background-color: var(--uh-black);
  color: var(--uh-white);
  padding: 2rem 0;
  margin-top: 4rem;
}

.uh-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.uh-footer-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 700;
  font-size: 0.9rem;
}

.uh-footer-links {
  display: flex;
  gap: 1.5rem;
}

.uh-footer-links a {
  color: var(--uh-white);
  text-decoration: none;
  font-size: 0.9rem;
  opacity: 0.8;
}

.uh-footer-links a:hover { opacity: 1; }

.uh-footer-copy {
  font-size: 0.8rem;
  opacity: 0.6;
}

/* ── Profile Layout ── */
.uh-profile-wrap {
  display: flex;
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0 2rem;
  gap: 2rem;
  align-items: flex-start;
}

/* ── Sidebar ── */
.uh-profile-sidebar {
  width: 240px;
  flex-shrink: 0;
  position: sticky;
  top: 80px;
}

.uh-profile-card {
  background: var(--uh-gray-light);
  border-top: 4px solid var(--uh-blue);
  padding: 1.5rem 1rem;
  text-align: center;
  margin-bottom: 1rem;
}

.uh-profile-avatar img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 0.75rem;
}

.uh-profile-avatar-placeholder {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: var(--uh-blue);
  color: white;
  font-size: 3rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 0.75rem;
}

.uh-profile-name {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
  color: var(--uh-black);
}

.uh-profile-role {
  font-size: 0.85rem;
  color: #555;
  margin-bottom: 0.5rem;
}

.uh-profile-phone {
  font-size: 0.8rem;
  color: var(--uh-blue);
  text-decoration: none;
  word-break: break-all;
  display: block;
  margin-top: 0.25rem;
}

.uh-profile-phone:hover {
  text-decoration: underline;
}

.uh-profile-email {
  font-size: 0.8rem;
  color: var(--uh-blue);
  text-decoration: none;
  word-break: break-all;
}

.uh-profile-email:hover { text-decoration: underline; }

.uh-profile-website a {
  font-size: 0.8rem;
  color: var(--uh-blue);
  text-decoration: none;
  word-break: break-all;
}

.uh-profile-website a:hover { text-decoration: underline; }

.uh-profile-website-item a {
  font-size: 0.8rem;
  color: var(--uh-blue);
  text-decoration: none;
  word-break: break-all;
  display: block;
  margin-top: 0.15rem;
}

.uh-profile-website-item a:hover {
  text-decoration: underline;
}

/* ── Sidebar Nav ── */
.uh-profile-nav ul {
  list-style: none;
  border-top: 2px solid var(--uh-blue);
}

.uh-profile-nav-link {
  display: block;
  padding: 0.65rem 1rem;
  color: var(--uh-black);
  text-decoration: none;
  font-size: 0.95rem;
  border-bottom: 1px solid var(--uh-gray);
  transition: background 0.15s;
}

.uh-profile-nav-link:hover {
  background: var(--uh-gray-light);
  color: var(--uh-blue);
}

.uh-profile-nav-link.active {
  background: var(--uh-blue);
  color: white;
  font-weight: 700;
}

/* ── Profile Content ── */
.uh-profile-content {
  flex: 1;
  min-width: 0;
}

.uh-profile-content h1 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--uh-gray);
  color: var(--uh-black);
}

.uh-profile-content h2 {
  font-size: 1.3rem;
  margin: 1.5rem 0 0.75rem;
  color: var(--uh-black);
}

.uh-profile-content p {
  line-height: 1.7;
  margin-bottom: 1rem;
  color: #333;
}

.uh-profile-content ul {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}

.uh-profile-content ul li {
  line-height: 1.7;
  margin-bottom: 0.25rem;
}

/* ── Hero ── */
.uh-hero {
  background-color: var(--uh-black);
  background-image: linear-gradient(135deg, #1a1a1a 0%, #107eab 100%);
  color: var(--uh-white);
  padding: 5rem 2rem;
  text-align: center;
}

.uh-hero-inner {
  max-width: 800px;
  margin: 0 auto;
}

.uh-hero h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  line-height: 1.2;
}

.uh-hero p {
  font-size: 1.2rem;
  opacity: 0.85;
}

/* ── Sections ── */
.uh-section {
  padding: 4rem 0;
}

.uh-section-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.uh-section-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--uh-black);
  margin-bottom: 2rem;
  padding-bottom: 0.5rem;
  border-bottom: 3px solid var(--uh-blue);
  display: inline-block;
}

.uh-section-body p {
  font-size: 1rem;
  line-height: 1.8;
  color: #333;
  margin-bottom: 1rem;
}

/* ── Staff Grid (responsive) ── */
.uh-staff-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

@media (max-width: 900px) {
  .uh-staff-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .uh-staff-grid {
    grid-template-columns: 1fr;
  }
}

.uh-staff-card {
  background: var(--uh-gray-light);
  border: 1px solid var(--uh-gray);
  border-top: 3px solid var(--uh-blue);
  text-decoration: none;
  color: var(--uh-black);
  text-align: center;
  padding: 1.5rem 1rem;
  transition: box-shadow 0.2s, transform 0.2s;
}

.uh-staff-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
  transform: translateY(-2px);
}

.uh-staff-card-photo {
  margin-bottom: 0.75rem;
}

.uh-staff-card-photo img {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
}

.uh-staff-card-initial {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: var(--uh-blue);
  color: white;
  font-size: 2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

.uh-staff-card-info h3 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
  line-height: 1.3;
}

.uh-staff-card-info p {
  font-size: 0.8rem;
  color: #666;
}

/* ── Blog / News Posts ── */
.uh-post-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  max-width: 800px;
}

.uh-post-item {
  border-left: 4px solid var(--uh-blue);
  padding-left: 1.25rem;
}

.uh-post-date {
  font-size: 0.8rem;
  color: #888;
  display: block;
  margin-bottom: 0.25rem;
}

.uh-post-item h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  color: var(--uh-black);
}

.uh-post-item p {
  font-size: 0.95rem;
  color: #555;
  line-height: 1.6;
}

/* ── Content list styling ── */
.uh-section-body ul,
.uh-section-body ol {
  margin: 0 0 1rem 1.5rem;
  padding: 0;
  list-style-position: outside;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.8;
}

.uh-section-body li {
  margin: 0.25rem 0;
}

.uh-profile-content ul,
.uh-profile-content ol {
  margin: 0 0 1rem 1.5rem;
  padding: 0;
  list-style-position: outside;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.7;
}

.uh-profile-content li {
  margin: 0.25rem 0;
}

/* ── Highlights carousel ── */
.uh-highlights-carousel {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.uh-highlights-slider {
  overflow: hidden;
  flex: 1;
  display: flex;
}

.uh-highlight-card {
  flex: 0 0 100%;
  display: flex;
  justify-content: center;
}

.uh-highlight-image-wrap {
  position: relative;
  width: 100%;
  max-width: 700px;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  overflow: hidden;
  background: #ccc;
}

.uh-highlight-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.uh-highlight-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.65), rgba(0,0,0,0.05));
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1rem;
}

.uh-highlight-overlay h3 {
  font-size: 1rem;
  margin: 0 0 0.25rem;
}

.uh-highlight-overlay p {
  font-size: 0.9rem;
  margin: 0 0 0.5rem;
}

.uh-highlight-link {
  align-self: flex-start;
  font-size: 0.85rem;
  color: #fff;
  text-decoration: underline;
}

.uh-highlights-arrow {
  background: var(--uh-black);
  border: none;
  color: #fff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}

/* Spacing between headings and body text */
.uh-section-body h2 {
  margin-top: 2rem;
  margin-bottom: 0.5rem;
}

.uh-section-body p {
  margin-top: 0;
  margin-bottom: 1rem;
}

/* ── Staff desktop vs mobile items ── */
.uh-nav-item-desktop { display: block; }
.uh-nav-item-mobile { display: none; }

/* ── Hamburger toggle ── */
.uh-nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.8rem;
  cursor: pointer;
  color: var(--uh-white);
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .uh-topbar-title { display: none; }

  .uh-hero h1 { font-size: 1.8rem; }

  .uh-footer-inner {
    flex-direction: column;
    text-align: center;
  }

  .uh-footer-links {
    justify-content: center;
  }

  /* Staff: hide dropdown, show simple link */
  .uh-nav-item-desktop { display: none; }
  .uh-nav-item-mobile { display: block; }

  /* Hamburger on mobile */
  .uh-nav-toggle {
    display: block;
  }

  .uh-nav {
    display: none;
    position: absolute;
    top: 64px; /* matches .uh-topbar-inner height */
    left: 0;
    right: 0;
    background: var(--uh-black);
    border-bottom: 1px solid #ddd;
  }

  .uh-nav.uh-nav-open {
    display: block;
  }

  .uh-nav-list {
    flex-direction: column;
    gap: 0;
  }

  .uh-nav-list li {
    border-top: 1px solid #333;
  }

  .uh-nav-link {
    display: block;
    padding: 12px 16px;
  }

  /* ── Profile: stack sidebar above content on mobile ── */
  .uh-profile-wrap {
    flex-direction: column;
    gap: 1.5rem;
    padding: 0 1rem;
  }

  .uh-profile-sidebar {
    width: 100%;
    position: static;
  }

  /* Card stays vertical on mobile, but full-width and left-aligned */
  .uh-profile-card {
    display: block;              /* back to block layout */
    text-align: center;            /* left-align text instead of center */
    padding: 1.25rem 1rem;
  }

  .uh-profile-avatar img,
  .uh-profile-avatar-placeholder {
    width: 96px;
    height: 96px;
    margin: 0 auto 0.75rem;      /* centered image, then text below */
  }

  .uh-profile-content {
    width: 100%;
  }

}

/* Force staff cards to always show on Ubuntu/all browsers */
.uh-staff-card {
  background: #f8f9fa !important;     /* darker gray, more visible */
  border: 1px solid #dee2e6 !important;
  border-top: 3px solid var(--uh-blue) !important;
  box-shadow: 
    0 2px 8px rgba(0,0,0,0.15),    /* stronger base shadow */
    0 1px 4px rgba(0,0,0,0.08) !important;  /* inner glow */
  text-decoration: none;
  color: var(--uh-black);
  text-align: center;
  padding: 1.5rem 1rem;
  margin-bottom: 1rem;                 /* breathing room for shadow */
  transition: all 0.2s ease;
  position: relative;                  /* ensure shadow layers correctly */
  z-index: 1;
}

.uh-staff-card:hover {
  box-shadow: 
    0 8px 24px rgba(0,0,0,0.20),    /* bigger hover shadow */
    0 2px 8px rgba(0,0,0,0.12) !important;
  transform: translateY(-4px);
}


/* ── Teaching / Course List ── */
.uh-course-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.uh-course-item {
  border-left: 4px solid var(--uh-blue);
  padding: 0.75rem 1rem;
  background: var(--uh-gray-light);
}

.uh-course-header {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
  flex-wrap: wrap;
}

.uh-course-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--uh-blue);
  text-decoration: none;
}

.uh-course-name:hover { text-decoration: underline; }

.uh-course-code {
  font-size: 0.8rem;
  color: #555;
  font-family: monospace;
}

.uh-course-meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: #666;
}

.uh-course-credits { color: var(--uh-blue); font-weight: 600; }
.uh-course-dates   { color: #555; }
.uh-course-lang    { color: #888; font-style: italic; }

