/* =========================================================================
   Department / Unit Details — modern content block
   Scoped under .dept-modern (content) and .dept-modern-side (sidebar) so it
   never touches header.php / footer.php or the existing govity.css theme.
   ========================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700&family=Public+Sans:wght@400;500;600;700;800&family=IBM+Plex+Mono:wght@500;600&display=swap');

.dept-modern, .dept-modern-side{
  --dm-paper:        #F1F3EC;
  --dm-paper-raised: #FFFFFF;
  --dm-ink:          #16231C;
  --dm-ink-soft:     #4C5A50;
  --dm-line:         #DCE1D3;

  --dm-forest:       #1B4332;
  --dm-forest-deep:  #0F2C20;
  --dm-forest-tint:  #E4EEE7;

  --dm-gold:         #C8952E;
  --dm-gold-deep:    #A87420;
  --dm-gold-tint:    #FBF1DC;

  --dm-brick:        #A23E2C;
  --dm-brick-tint:   #F7E9E4;

  --dm-font-display: "Fraunces", "Iowan Old Style", serif;
  --dm-font-body:    "Public Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --dm-font-mono:    "IBM Plex Mono", ui-monospace, monospace;

  --dm-radius-sm: 6px;
  --dm-radius-md: 10px;
  --dm-radius-lg: 16px;
  --dm-shadow: 0 1px 2px rgba(22,35,28,.06), 0 8px 24px -12px rgba(22,35,28,.14);
  --dm-ease: cubic-bezier(.22,.61,.36,1);

  font-family: var(--dm-font-body);
  color: var(--dm-ink);
}

@media (prefers-reduced-motion: reduce){
  .dept-modern *, .dept-modern-side *{ animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

.dept-modern *, .dept-modern *::before, .dept-modern *::after,
.dept-modern-side *, .dept-modern-side *::before, .dept-modern-side *::after{ box-sizing: border-box; }
.dept-modern a, .dept-modern-side a{ color: var(--dm-forest); text-decoration: none; }
.dept-modern :focus-visible, .dept-modern-side :focus-visible{ outline: 3px solid var(--dm-gold); outline-offset: 2px; border-radius: 4px; }

/* =========================================================================
   Main content card
   ========================================================================= */
.dept-modern{
  background: var(--dm-paper-raised);
  border: 1px solid var(--dm-line);
  border-radius: var(--dm-radius-lg);
  padding: clamp(22px, 4vw, 44px);
  box-shadow: var(--dm-shadow);
  line-height: 1.65;
}

.dept-modern__header{
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 0 0 22px;
}
.dept-modern__icon{
  flex: none;
  width: 56px; height: 56px;
  border-radius: 14px;
  background: linear-gradient(155deg, var(--dm-forest) 0%, var(--dm-forest-deep) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--dm-gold);
  font-size: 24px;
}
.dept-modern__icon span{ display: block; }
.dept-modern__eyebrow{
  display: block;
  font-family: var(--dm-font-mono);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--dm-gold-deep);
  margin: 0 0 4px;
}
.dept-modern__title{
  font-family: var(--dm-font-display);
  font-weight: 600;
  font-size: clamp(22px, 3vw, 30px);
  color: var(--dm-forest-deep);
  line-height: 1.15;
  margin: 0;
}

.dept-modern .lede{
  font-size: 16.5px;
  color: var(--dm-ink-soft);
  border-left: 3px solid var(--dm-gold);
  padding-left: 18px;
  margin: 0 0 28px;
}
.dept-modern p{ margin: 0 0 14px; color: var(--dm-ink); }

.dept-modern h2{
  font-family: var(--dm-font-display);
  font-weight: 600;
  font-size: 21px;
  color: var(--dm-forest-deep);
  margin: 38px 0 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.dept-modern h2::before{
  content: "";
  width: 20px; height: 2px;
  background: var(--dm-gold);
  flex: none;
}
.dept-modern h3.dept-modern__sub{
  font-family: var(--dm-font-display);
  font-weight: 600;
  font-size: 16.5px;
  color: var(--dm-forest);
  margin: 22px 0 10px;
}

/* ---- profile card (leader photo + role) ---- */
.dept-modern__profile-grid{
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 22px;
  margin: 6px 0 8px;
  align-items: start;
}
.dept-modern__profile-card{
  border: 1px solid var(--dm-line);
  border-radius: var(--dm-radius-md);
  overflow: hidden;
  background: var(--dm-paper);
}
.dept-modern__profile-img{
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  display: block;
  background: var(--dm-forest-tint);
  transition: transform .4s var(--dm-ease);
}
.dept-modern__profile-card:hover .dept-modern__profile-img{ transform: scale(1.03); }
.dept-modern__profile-role{
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-top: 1px solid var(--dm-line);
}
.dept-modern__profile-role .ic{
  flex: none;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--dm-gold-tint);
  color: var(--dm-gold-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
}
.dept-modern__profile-role .txt{
  font-size: 13.5px;
  font-weight: 700;
  color: var(--dm-forest-deep);
  line-height: 1.35;
}
.dept-modern__profile-role .txt small{
  display: block;
  font-weight: 500;
  color: var(--dm-ink-soft);
  font-size: 12px;
}

.dept-modern__points{
  border: 1px solid var(--dm-line);
  background: var(--dm-forest-tint);
  border-radius: var(--dm-radius-md);
  padding: 18px 20px;
  margin-bottom: 14px;
}
.dept-modern__points:last-child{ margin-bottom: 0; }
.dept-modern__points h3{
  font-family: var(--dm-font-display);
  font-weight: 600;
  font-size: 15.5px;
  color: var(--dm-forest-deep);
  margin: 0 0 8px;
}
.dept-modern__points p{ font-size: 14.5px; color: var(--dm-ink); margin: 0; }

/* ---- checklist (duties, points-list) ---- */
.dept-modern__checklist{
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.dept-modern__checklist li{
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14.5px;
  color: var(--dm-ink);
}
.dept-modern__checklist li .ic{
  flex: none;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--dm-gold);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  margin-top: 1px;
}

/* ---- numbered functions / objectives trail ---- */
.dept-modern .step-trail{
  list-style: none;
  margin: 0 0 8px;
  padding: 0;
  position: relative;
}
.dept-modern .step-trail::before{
  content: "";
  position: absolute;
  left: 15px; top: 6px; bottom: 6px;
  width: 2px;
  background-image: linear-gradient(to bottom, var(--dm-gold-tint) 0%, var(--dm-line) 12%, var(--dm-line) 88%, transparent 100%);
}
.dept-modern .step-trail__item{
  position: relative;
  padding: 0 0 20px 46px;
  min-height: 32px;
}
.dept-modern .step-trail__item:last-child{ padding-bottom: 4px; }
.dept-modern .step-trail__num{
  position: absolute;
  left: 0; top: 0;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--dm-forest);
  color: #fff;
  font-family: var(--dm-font-mono);
  font-weight: 600;
  font-size: 12.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 4px var(--dm-paper-raised);
  transition: background-color .2s var(--dm-ease), transform .2s var(--dm-ease);
}
.dept-modern .step-trail__item:hover .step-trail__num{
  background: var(--dm-gold-deep);
  transform: scale(1.06);
}
.dept-modern .step-trail__body{ padding-top: 4px; font-size: 14.5px; color: var(--dm-ink); }

/* ---- download resources ---- */
.dept-modern__download{
  margin-top: 32px;
  border: 1px solid var(--dm-line);
  border-radius: var(--dm-radius-md);
  overflow: hidden;
}
.dept-modern__download-head{
  padding: 14px 18px;
  background: var(--dm-forest-tint);
  font-family: var(--dm-font-mono);
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--dm-forest-deep);
  font-weight: 700;
}
.dept-modern__download-list{
  list-style: none;
  margin: 0;
  padding: 0;
}
.dept-modern__download-list li{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 18px;
  border-top: 1px solid var(--dm-line);
  transition: background-color .18s var(--dm-ease);
}
.dept-modern__download-list li:hover{ background: var(--dm-paper); }
.dept-modern__download-content{
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.dept-modern__download-icon{
  flex: none;
  width: 34px; height: 34px;
  border-radius: 8px;
  background: var(--dm-brick-tint);
  color: var(--dm-brick);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
}
.dept-modern__download-text{
  font-size: 14px;
  font-weight: 600;
  color: var(--dm-ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.dept-modern__download-btn{
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 999px;
  background: var(--dm-forest);
  color: #fff;
  font-size: 12.5px;
  font-weight: 700;
  transition: background-color .2s var(--dm-ease), transform .2s var(--dm-ease);
}
.dept-modern__download-btn:hover{ background: var(--dm-gold-deep); transform: translateY(-1px); color: #fff; }

/* ---- motion ---- */
.dept-modern.scroll-reveal, .dept-modern-side.scroll-reveal{
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .6s var(--dm-ease), transform .6s var(--dm-ease);
}
.dept-modern.scroll-reveal.is-visible, .dept-modern-side.scroll-reveal.is-visible{
  opacity: 1;
  transform: translateY(0);
}

/* ---- responsive (main) ---- */
@media (max-width: 760px){
  .dept-modern{ padding: 22px 18px; }
  .dept-modern__title{ font-size: 20px; }
  .dept-modern h2{ font-size: 18px; }
  .dept-modern__profile-grid{ grid-template-columns: 1fr; }
  .dept-modern__profile-card{ max-width: 240px; }
}

/* =========================================================================
   Sidebar — department / unit navigation
   ========================================================================= */
.dept-modern-side{ position: sticky; top: 24px; }

.dept-modern-side__panel{
  background: var(--dm-paper-raised);
  border: 1px solid var(--dm-line);
  border-radius: var(--dm-radius-lg);
  box-shadow: var(--dm-shadow);
  padding: 22px;
  margin-bottom: 18px;
}
.dept-modern-side__eyebrow{
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--dm-font-mono);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--dm-ink-soft);
  margin: 0 0 14px;
}
.dept-modern-side__eyebrow::before{
  content: "";
  width: 16px; height: 2px;
  background: var(--dm-gold);
  flex: none;
}
.dept-modern-side__list{
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.dept-modern-side__list a{
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: var(--dm-radius-sm);
  font-size: 14px;
  font-weight: 600;
  color: var(--dm-ink-soft);
  border-left: 2px solid transparent;
  transition: background-color .18s var(--dm-ease), color .18s var(--dm-ease), border-color .18s var(--dm-ease), padding-left .18s var(--dm-ease);
}
.dept-modern-side__list a::before{
  content: "";
  flex: none;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--dm-line);
  transition: background-color .18s var(--dm-ease), transform .18s var(--dm-ease);
}
.dept-modern-side__list a:hover{
  background: var(--dm-forest-tint);
  color: var(--dm-forest-deep);
  padding-left: 18px;
}
.dept-modern-side__list a:hover::before{ background: var(--dm-forest); }
.dept-modern-side__list a.is-active{
  background: var(--dm-gold-tint);
  color: var(--dm-gold-deep);
  border-left-color: var(--dm-gold);
}
.dept-modern-side__list a.is-active::before{
  background: var(--dm-gold);
  transform: scale(1.3);
}

.dept-modern-side__help{
  background: var(--dm-forest);
  border-radius: var(--dm-radius-lg);
  padding: 22px;
  color: #fff;
}
.dept-modern-side__help h4{
  font-family: var(--dm-font-display);
  font-weight: 600;
  font-size: 17px;
  margin: 0 0 8px;
  color: #fff;
}
.dept-modern-side__help p{
  font-size: 13.5px;
  color: rgba(255,255,255,.75);
  margin: 0 0 16px;
  line-height: 1.55;
}
.dept-modern-side__help a{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--dm-gold);
  transition: gap .2s var(--dm-ease), color .2s var(--dm-ease);
}
.dept-modern-side__help a:hover{ gap: 12px; color: #fff; }

@media (max-width: 980px){
  .dept-modern-side{ position: static; }
}
@media (max-width: 760px){
  .dept-modern-side__panel, .dept-modern-side__help{ padding: 18px; }
}
