
:root{
  --bg:#faf8f6;
  --card:#ffffff;

  --text:#231f20;
  --muted:#6b6466;

  --line:#e6dfdb;

  /* Faculty color (primary UI color) */
  --primary:#f18700;
  --primary-dark:#d97200;

  /* School accent color */
  --accent:#f04e23;

  --shadow:0 8px 24px rgba(35,31,32,.08);

  --radius:18px;
  --radius-sm:12px;

  --container:1280px;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  font-family:Inter,Segoe UI,Arial,sans-serif;
  background:var(--bg);
  color:var(--text);
  line-height:1.55;
}
a{color:var(--primary);text-decoration:none}
a:hover{text-decoration:underline}
img{max-width:100%;display:block}
.container{
  width:min(calc(100% - 2rem), var(--container));
  margin-inline:auto;
}
.site-header{
  background:linear-gradient(180deg,#fff4e8 0%, #faf8f6 100%);
  border-top:4px solid var(--primary);
  border-bottom:1px solid var(--line);
  padding:1.2rem 0 1.6rem;
}
.topbar{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:1rem;
}
.site-eyebrow{
  font-size:.82rem;
  letter-spacing:.06em;
  text-transform:uppercase;
  color:var(--muted);
  margin-bottom:.25rem;
}
.site-header h1,
.detail-title{
  margin:.1rem 0 .35rem;
  line-height:1.15;
  font-size:clamp(1.9rem,3vw,2.8rem);
}
.site-intro{
  margin:0;
  color:var(--muted);
  max-width:72ch;
}
.primary-nav{
  display:flex;
  align-items:center;
  gap:.6rem;
  flex-wrap:wrap;
  margin-top:1.2rem;
}
.nav-spacer{
  flex:1;
}
.nav-archive{
  padding:.6rem 1.2rem;
  border-radius:999px;
  background:var(--primary);
  color:#fff;
  font-weight:700;
  text-decoration:none;
  border:1px solid var(--primary);
}
.nav-archive:hover{
  background:var(--primary-dark);
  border-color:var(--primary-dark);
  text-decoration:none;
}
.nav-link{
  display:inline-flex;
  align-items:center;
  padding:.75rem 1rem;
  border:1px solid var(--line);
  border-radius:999px;
  background:#fff;
  color:var(--text);
  text-decoration:none;
  font-weight:600;
}
.nav-link.active{
  background:var(--primary);
  color:#fff;
  border-color:var(--primary);
}
.stats-grid{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:.9rem;
  margin-top:1.2rem;
}
.stat-box{
  background:#fff;
  border:1px solid var(--line);
  border-radius:var(--radius-sm);
  padding:1rem 1.1rem;
  box-shadow:var(--shadow);
}
.stat-number{
  display:block;
  font-size:1.5rem;
  font-weight:800;
}
.stat-label{
  color:var(--muted);
  font-size:.9rem;
}
.page-layout{
  display:grid;
  grid-template-columns:320px minmax(0,1fr);
  gap:1.2rem;
  padding:1.2rem 0 2.2rem;
  align-items:start;
}
.sidebar{
  min-width:0;
}
.sticky-panel{
  position:sticky;
  top:1rem;
}
.panel{
  background:var(--card);
  border:1px solid var(--line);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  padding:1rem;
  margin-bottom:1rem;
}
.panel h2{
  margin:.2rem 0 1rem;
  font-size:1.05rem;
}
.field-label{
  display:block;
  margin:.85rem 0 .35rem;
  font-weight:600;
  font-size:.95rem;
}
.text-input,
.select-input{
  width:100%;
  border:1px solid #d9d0cb;
  border-radius:12px;
  background:#fff;
  min-height:44px;
  padding:.75rem .85rem;
  font:inherit;
}
.toggle-row{
  display:flex;
  gap:.5rem;
  margin-top:1rem;
}
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.45rem;
  min-height:42px;
  border-radius:12px;
  border:1px solid transparent;
  padding:.65rem 1rem;
  font:inherit;
  font-weight:700;
  cursor:pointer;
  text-decoration:none;
}
.btn:hover{text-decoration:none}
.btn-primary{
  background:var(--primary);
  color:#fff;
}
.btn-primary:hover{
  background:var(--primary-dark);
}
.btn-secondary{
  background:#fff;
  border-color:var(--line);
  color:var(--text);
}
.btn-light{
  background:#f6f1ed;
  color:var(--text);
}
.btn-full{width:100%;margin-top:.9rem}
.filter-summary{
  margin-top:.95rem;
  font-size:.95rem;
  color:var(--muted);
}
.grouped-nav-panel{margin-top:1rem}
.grouped-anchor-list{
  list-style:none;
  padding:0;
  margin:0;
  display:grid;
  gap:.35rem;
}
.grouped-anchor-list a{
  display:flex;
  justify-content:space-between;
  gap:.8rem;
  padding:.55rem .7rem;
  border-radius:10px;
  color:var(--text);
}
.grouped-anchor-list a.active,
.grouped-anchor-list a:hover{
  background:#fff1e2;
  color:var(--primary-dark);
  text-decoration:none;
}
.content-area{
  min-width:0;
}
.cards-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(280px,1fr));
  gap:1rem;
}
.grouped-grid{
  grid-template-columns:repeat(auto-fit,minmax(280px,1fr));
}
.topic-card{
  background:var(--card);
  border:1px solid var(--line);
  border-radius:var(--radius);
  overflow:hidden;
  box-shadow:var(--shadow);
  display:flex;
  flex-direction:column;
  min-height:100%;
}
.card-image-wrap{
  background:#f8f1ea;
}
.card-image{
  width:100%;
  height:220px;
  object-fit:contain;
}
.card-body{
  padding:1rem;
  display:flex;
  flex-direction:column;
  gap:.6rem;
  flex:1;
}
.card-title{
  margin:0;
  line-height:1.25;
  font-size:1.1rem;
}
.meta-row{
  color:var(--muted);
  font-size:.93rem;
}
.meta-label{
  font-weight:700;
  color:var(--text);
}
.card-summary{
  margin:0;
  color:var(--text);
  display:-webkit-box;
  -webkit-line-clamp:4;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.tag-row{
  display:flex;
  gap:.4rem;
  flex-wrap:wrap;
}
.tag{
  display:inline-flex;
  align-items:center;
  border:1px solid #f3d6b5;
  background:#fff4e6;
  color:#7a3e00;
  border-radius:999px;
  padding:.28rem .7rem;
  font-size:.82rem;
}
.card-actions{
  margin-top:auto;
  padding-top:.2rem;
}
.list-wrap{
  background:#fff;
  border:1px solid var(--line);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  overflow:auto;
}
.topic-table{
  width:100%;
  border-collapse:collapse;
  min-width:920px;
}
.topic-table th,
.topic-table td{
  padding:.9rem .95rem;
  border-bottom:1px solid var(--line);
  vertical-align:top;
  text-align:left;
}
.topic-table th{
  background:#faf4ee;
  position:sticky;
  top:0;
  z-index:1;
}
.empty-state{
  background:#fff;
  border:1px dashed #d8ccc4;
  border-radius:16px;
  padding:1.6rem;
  text-align:center;
  color:var(--muted);
}
.hidden{display:none !important}
.site-footer{
  border-top:1px solid var(--line);
  padding:1rem 0 2rem;
  color:var(--muted);
}
.grouped-sections{
  display:block;
}
.group-section{
  margin-bottom:1.2rem;
}
.group-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  margin:0 0 .75rem;
}
.group-header h2{
  margin:0;
}
.group-count{
  color:var(--muted);
  font-size:.92rem;
}
.breadcrumbs{
  color:var(--muted);
  margin-bottom:.4rem;
  font-size:.95rem;
}
.crumb-sep{padding:0 .3rem}
.detail-layout{
  padding:1.2rem 0 2rem;
}
.detail-card{
  background:#fff;
  border:1px solid var(--line);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  padding:1.1rem;
}
.detail-subtitle{
  color:var(--muted);
  font-weight:600;
}
.detail-image-wrap{
  margin-bottom:1rem;
  background:#f8f1ea;
  border-radius:16px;
  overflow:hidden;
}
.detail-image{
  width:100%;
  max-height:520px;
  object-fit:contain;
}
.info-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:.85rem;
  margin-bottom:1rem;
}
.info-block{
  background:#fcf7f2;
  border:1px solid var(--line);
  border-radius:14px;
  padding:.9rem;
}
.info-label{
  font-size:.85rem;
  color:var(--muted);
  margin-bottom:.2rem;
  font-weight:700;
}
.info-value{
  font-weight:600;
}
.detail-section{
  margin-top:1rem;
}
.detail-section h2{
  margin:.15rem 0 .55rem;
  font-size:1.15rem;
}
.rich-text{
  background:#fff;
}
.detail-links{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:1rem;
  flex-wrap:wrap;
  margin-top:1.2rem;
}
.detail-links-left{
  display:flex;
  gap:.6rem;
  flex-wrap:wrap;
}
.detail-links-right{
  display:flex;
  justify-content:flex-end;
  align-items:flex-start;
  margin-left:auto;
}
.detail-availability-link{
  white-space:nowrap;
}
.program-section{
  margin-bottom:2rem;
}
.program-grid{
  margin-top:.6rem;
}
.topic-pager{
  margin-top:1.2rem;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:.8rem;
}
.pager-link{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:.85rem;
  background:#fff4e8;
  border:1px solid #f3d6b5;
  border-radius:16px;
  padding:1rem;
  color:var(--text);
}
.pager-link:hover{
  background:#ffe9cc;
  text-decoration:none;
}
.pager-label{
  display:block;
  color:var(--muted);
  font-size:.84rem;
}
.pager-title{
  display:block;
  font-weight:700;
}
.pager-prev{text-align:left}
.pager-next{text-align:right}
.archive-page{
  padding:2rem 0;
}
.archive-list{
  display:grid;
  gap:.6rem;
  padding-left:1.2rem;
}
.back-to-top{
  position:fixed;
  right:1.2rem;
  bottom:1.2rem;
  width:52px;
  height:52px;
  border:none;
  border-radius:999px;
  background:var(--primary);
  color:#fff;
  font-size:1.35rem;
  font-weight:700;
  box-shadow:var(--shadow);
  cursor:pointer;
  z-index:999;
  transition:opacity .2s ease, transform .2s ease;
}
.back-to-top:hover{
  background:var(--primary-dark);
}
.back-to-top.hidden{
  display:none !important;
}
.footer-inner{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:0.8rem;
  text-align:center;
}
.archive-btn{
  padding:0.8rem 1.4rem;
  font-size:1rem;
}
.footer-credits{
  margin:0;
  font-size:.9rem;
  color:var(--muted);
}
@media (max-width: 1100px){
  .page-layout{grid-template-columns:1fr}
  .sticky-panel{position:static}
}
@media (max-width: 760px){
  .stats-grid{grid-template-columns:repeat(2,1fr)}
  .topic-pager{grid-template-columns:1fr}
  .detail-links{flex-direction:column}
  .detail-links-left,
  .detail-links-right{
    width:100%;
  }
  .detail-links-right{
    justify-content:flex-start;
  }
}
