/* Trapani Lab shared styles
   A light modernization that preserves the site's established visual identity. */
:root {
  --lab-purple: #880088;
  --lab-purple-dark: #660066;
  --page-background: #d8d8d8;
  --navbar-background: #343a40;
  --surface: #ffffff;
  --soft-surface: #eeeeee;
  --text: #212529;
  --muted: #6c757d;
  --border: #ced4da;
  --focus: rgba(136, 0, 136, 0.28);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  margin: 0;
  background: var(--page-background);
  color: var(--text);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

.skip-link {
  position: fixed;
  top: .5rem;
  left: .5rem;
  z-index: 2000;
  transform: translateY(-180%);
  padding: .55rem .8rem;
  border-radius: .25rem;
  background: #fff;
  color: #000;
  box-shadow: 0 .2rem .6rem rgba(0,0,0,.25);
}
.skip-link:focus { transform: translateY(0); }

.navbar {
  background-color: var(--navbar-background) !important;
  box-shadow: 0 2px 7px rgba(0,0,0,.18);
}
.navbar-brand { font-weight: 600; }
.navbar .nav-link { border-radius: .25rem; }
.navbar .nav-link:hover,
.navbar .nav-link:focus-visible { background: rgba(255,255,255,.08); }
.navbar .nav-link.active { font-weight: 600; }

main {
  flex: 1 0 auto;
  width: 100%;
  padding-top: 80px;
  padding-bottom: 60px;
}

.text-justify-custom,
.text-justify-sm { text-align: left; }
@media (min-width: 768px) {
  .text-justify-custom,
  .text-justify-sm { text-align: justify; }
}

.text-info,
h3.text-info,
h4.text-info,
h5.text-info { color: var(--lab-purple) !important; }

h4.text-info { font-weight: 600; }
a { text-underline-offset: .15em; }
a:focus-visible,
button:focus-visible,
.btn:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

img { max-width: 100%; height: auto; }
.img-thumbnail {
  border-color: var(--border);
  background: #fff;
}

.btn { border-radius: .3rem; }

.accordion {
  --bs-accordion-border-color: var(--border);
  --bs-accordion-btn-focus-box-shadow: 0 0 0 .2rem var(--focus);
  --bs-accordion-active-color: var(--lab-purple-dark);
  --bs-accordion-active-bg: #f3e8f3;
}
.accordion-item {
  overflow: hidden;
  margin-bottom: .65rem;
  border-radius: .35rem !important;
}
.accordion-button { font-weight: 500; }
.accordion-body { background: rgba(255,255,255,.78); }

.footer {
  flex-shrink: 0;
  background-color: var(--navbar-background);
  color: #fff;
}
.footer a {
  color: #adb5bd;
  text-decoration: none;
  transition: color .2s ease;
}
.footer a:hover,
.footer a:focus-visible { color: #fff; }

/* Existing page-specific patterns */
.content-links p { margin-bottom: .5rem; }
.member-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  margin-bottom: 10px;
}
.gallery-img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  margin-bottom: 10px;
}
.publication-list { padding-left: 1.5rem; }
.publication-list li {
  margin-bottom: 1.25rem;
  line-height: 1.6;
  text-align: left;
}
@media (min-width: 768px) { .publication-list li { text-align: justify; } }
.ugrad-author { color: #800080; font-weight: 500; }
.pub-note {
  display: inline-block;
  margin-top: .5rem;
  padding: .5rem .75rem;
  border-left: 3px solid #f0ad4e;
  border-radius: .25rem;
  background-color: #fcf8e3;
  font-size: .9em;
}
.figure-row {
  padding-bottom: 20px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
}
.figure-row:last-child { padding-bottom: 0; margin-bottom: 0; border-bottom: 0; }
dt.course-title {
  margin-top: 1.5rem;
  padding-bottom: .25rem;
  border-bottom: 1px solid #dee2e6;
  color: var(--lab-purple);
  font-size: 1.15em;
}
dd.course-desc { padding: .75rem 0 1rem; margin-bottom: 0; line-height: 1.6; }
.past-course-photo { margin-bottom: 2.5rem; }
.past-course-photo em { display: block; margin-bottom: .5rem; font-size: 1.1em; font-weight: 500; }
.spaced-list li { margin-bottom: .75rem; line-height: 1.6; }
.r15-content ul { margin-bottom: 1.5rem; }
.r15-content li { margin-bottom: .5rem; }

iframe { max-width: 100%; }

.github-callout {
  border-left: 4px solid var(--lab-purple) !important;
  background: rgba(255,255,255,.72) !important;
}
.github-callout .fa-github { color: var(--lab-purple); }

@media (max-width: 575.98px) {
  main { padding-top: 72px; padding-bottom: 40px; }
  .gallery-img { height: 220px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}
