body { font-size: 16px; min-height: 100vh; display: flex; flex-direction: column; }
html, body { height: 100%; overflow-y: scroll; overflow-x: hidden; }
#messages-block .error { color: #c91235; }
#content { flex: 1 0 auto; overflow-y: visible; padding-top: 110px; padding-bottom: 80px; }
#footer { flex-shrink: 0; position: relative; }
#footer { background-color: #404040; }
#footer, #footer a { color: #ffffff; text-decoration: none; }
.navbar { background-color: #c91235; }
#offcanvasNavbar.offcanvas { --bs-offcanvas-bg: #c91235; --bs-offcanvas-color: #ffffff; }
.btn-marist{ background:#C91235 !important; color:#fff !important; border:1px solid #C91235 !important; border-radius:.25rem !important; padding:.5rem 1rem !important; }
.btn-marist:hover{ background:#A0102A !important; border-color:#A0102A !important; color:#fff !important; }
:root{--marist-red:#C91235;--marist-red-dark:#A0102A;}
#er-root, #mc-root, #vw-root{--marist-red:#C91235;--marist-red-dark:#A0102A;}
#er-root .bg-\[\#C91235\], #mc-root .bg-\[\#C91235\], #vw-root .bg-\[\#C91235\], #bio-root .bg-\[\#C91235\]{background-color:var(--marist-red)!important;color:#fff!important;}
#er-root .hover\:bg-\[\#A0102A\]:hover, #mc-root .hover\:bg-\[\#A0102A\]:hover, #vw-root .hover\:bg-\[\#A0102A\]:hover, #bio-root .hover\:bg-\[\#A0102A\]:hover, #er-root .hover\:bg-red-800:hover, #mc-root .hover\:bg-red-800:hover, #vw-root .hover\:bg-red-800:hover{background-color:var(--marist-red-dark)!important;color:#fff!important;}
#er-root .text-white, #mc-root .text-white, #vw-root .text-white{color:#fff!important;}
#er-root .w-full, #mc-root .w-full, #vw-root .w-full{width:100%!important;}
#er-root .flex, #mc-root .flex, #vw-root .flex{display:flex!important;}
#er-root .items-center, #mc-root .items-center, #vw-root .items-center{align-items:center!important;}
#er-root .justify-between, #mc-root .justify-between, #vw-root .justify-between{justify-content:space-between!important;}
#er-root .px-3, #mc-root .px-3, #vw-root .px-3{padding-left:.75rem!important;padding-right:.75rem!important;}
#er-root .px-4, #mc-root .px-4, #vw-root .px-4{padding-left:1rem!important;padding-right:1rem!important;}
#er-root .py-2, #mc-root .py-2, #vw-root .py-2{padding-top:.5rem!important;padding-bottom:.5rem!important;}
#er-root .py-3, #mc-root .py-3, #vw-root .py-3{padding-top:.75rem!important;padding-bottom:.75rem!important;}
#er-root .font-semibold, #mc-root .font-semibold, #vw-root .font-semibold{font-weight:600!important;}
#er-root .rounded, #mc-root .rounded, #vw-root .rounded{border-radius:.25rem!important;}
#er-root .rounded-t, #mc-root .rounded-t, #vw-root .rounded-t{border-top-left-radius:.25rem!important;border-top-right-radius:.25rem!important;}
#er-root .border, #mc-root .border, #vw-root .border{border:1px solid #e5e7eb!important;}
#er-root .bg-white, #mc-root .bg-white, #vw-root .bg-white{background:#fff!important;}

#home-hero{ position:relative; display:flex; align-items:center; justify-content:center; min-height:calc(100vh - 180px); padding:24px 12px; background:#f7f7f7; }
#home-hero .admin-quick{ position:absolute; top:12px; right:12px; }
#home-hero .home-card{ background:#fff; border-radius:8px; padding:24px; text-align:center; width:100%; max-width:720px; box-shadow:0 35px 80px -30px rgba(0,0,0,.25); }
#home-hero .home-card h1{ margin:0 0 12px; color:#C91235; font-size:clamp(28px,3vw,36px); }
#home-hero .home-card p{ margin:0 0 16px; color:#333; }

.ballot-wrap{padding-top: 2.5rem;padding-bottom:2rem;}
.ballot-title{color:var(--marist-red);font-weight:700;font-size:1.75rem;text-align:center;margin-top:0 ;}
.section-title{color:var(--marist-red);font-weight:700;font-size:1.25rem;margin:1.5rem 0 .75rem;}
.pos-card{background:#fff;border:1px solid #e5e7eb;border-radius:.5rem;overflow:hidden;margin-bottom:1rem;box-shadow:0 1px 2px rgba(0,0,0,.04);}
.pos-card>header{background:var(--marist-red);color:#fff;font-weight:600;padding:.75rem 1rem;}
.pos-card .pos-body{padding:.75rem 1rem 1rem;}
.choice{display:block;border:1px solid #e5e7eb;border-radius:.375rem;padding:.5rem .75rem;margin:.375rem 0;cursor:pointer;}
.choice:hover{background:#fafafa;}
.choice input{margin-right:.5rem;}
.muted{color:#6b7280;font-size:.95rem;}
.sticky-submit{position:sticky;bottom:0;background:linear-gradient(#fff,rgba(255,255,255,.96));padding:.75rem 0 1rem;text-align:center;border-top:1px solid #e5e7eb;margin-top:1rem;}
.collapsible{ overflow: hidden; transition: max-height .25s ease, opacity .2s ease; will-change: max-height; }
.collapsible[data-open="0"]{ opacity: 0; }
.collapsible[data-open="1"]{ opacity: 1; }

.mc-rel{ position: relative; }
.mc-suggest{ position: absolute; left: 0; right: 0; top: 100%; margin-top: .25rem; max-height: 12rem; overflow: auto; background: #fff; border: 1px solid #e5e7eb; border-radius: .375rem; box-shadow: 0 10px 24px rgba(0,0,0,.12); z-index: 1000; }

.center-wrap { min-height: calc(100vh - 180px); display: flex; align-items: center; justify-content: center; padding: 24px 12px; background: #f7f7f7; }

/* Navbar contrast only */
.navbar .navbar-brand, .navbar .navbar-text, .navbar .dropdown-toggle, .navbar .nav-link, .navbar-dark .navbar-brand, .navbar-dark .navbar-text, .navbar-dark .navbar-nav .nav-link, .navbar-dark .dropdown-toggle { color: #ffffff !important; opacity: 1 !important; }
.navbar .nav-link:hover, .navbar .nav-link:focus, .navbar .dropdown-toggle:hover, .navbar .dropdown-toggle:focus { color: #ffffff !important; text-decoration: underline; }
.navbar .dropdown-toggle::after { color: #ffffff !important; border-top-color: currentColor; }
.navbar a:focus-visible { outline: 2px solid #ffffff; outline-offset: 2px; }

.ballot-wrap { padding-bottom: 6rem; }
html, body { overflow-y: scroll !important; overflow-x: hidden !important; }
#content, .ballot-wrap, .container, .page-content, .main-content { overflow: visible !important; max-height: none !important; }

/* === Manage Candidates Scroll Section === */
#mc-root { max-height: 80vh; overflow-y: auto; padding-right: 0.5rem; scrollbar-width: thin; }
#mc-root::-webkit-scrollbar { width: 8px; }
#mc-root::-webkit-scrollbar-thumb { background-color: #c91235; border-radius: 4px; }
#mc-root::-webkit-scrollbar-thumb:hover { background-color: #A0102A; }

#mc-root { display: flex; flex-direction: column; max-height: calc(100vh - 180px); overflow-y: auto; overflow-x: hidden; padding: 1rem; padding-bottom: 4rem; box-sizing: border-box; }
#mc-root > *:last-child { margin-bottom: 2rem; }

/* === Nested scroll just for Representatives section === */
#mc-sec-reps { max-height: 55vh; overflow-y: auto; padding-right: 0.5rem; scrollbar-width: thin; }
#mc-sec-reps::-webkit-scrollbar { width: 8px; }
#mc-sec-reps::-webkit-scrollbar-thumb { background-color: #c91235; border-radius: 4px; }
#mc-sec-reps::-webkit-scrollbar-thumb:hover { background-color: #A0102A; }

/* === Nested scroll just for Class Officers section === */
#mc-sec-years { max-height: 55vh; overflow-y: auto; padding-right: 0.5rem; scrollbar-width: thin; }
#mc-sec-years::-webkit-scrollbar { width: 8px; }
#mc-sec-years::-webkit-scrollbar-thumb { background-color: #c91235; border-radius: 4px; }
#mc-sec-years::-webkit-scrollbar-thumb:hover { background-color: #A0102A; }

/* === Extra scroll inside each Class Year block === */
#mc-sec-years .mc-card .collapsible { max-height: 50vh; overflow-y: auto; padding-right: 0.5rem; scrollbar-width: thin; }
#mc-sec-years .mc-card .collapsible::-webkit-scrollbar { width: 8px; }
#mc-sec-years .mc-card .collapsible::-webkit-scrollbar-thumb { background-color: #c91235; border-radius: 4px; }
#mc-sec-years .mc-card .collapsible::-webkit-scrollbar-thumb:hover { background-color: #A0102A; }

.home-wrap { max-width: 980px; margin: 0 auto; padding: 2rem 1rem 4rem; }
.home-heading { display:flex; align-items:flex-end; justify-content:space-between; gap:1rem; }
.home-title { margin:0; color:#C91235; font-weight:800; letter-spacing:.2px; }
.home-sub { margin:.25rem 0 0; color:#667085; font-size:.95rem; }
.view-all { font-size:.85rem; }
.home-cta { display:flex; align-items:center; justify-content:center; margin-top:2.25rem; }
.btn-marist-solid { background:#C91235; color:#fff; border:0; padding:.65rem 1rem; border-radius:.5rem; font-weight:600; }
.btn-marist-solid:hover { filter:brightness(.95); color:#fff; }
.home-admin { position:relative; top:-.5rem; margin-bottom:.5rem; }
.home-admin a { font-size:.875rem; }

/* small screens */
@media (max-width: 576px) {
  .home-wrap { padding: 1.25rem .75rem 3rem; }
}

/* === Public Candidate Bios: list layout (image left, text right) === */
.cbp-list{
  max-width: 1200px;
  margin: 0 auto;
  padding:0 clamp(16px,4vw,72px);
  display:flex;
  flex-direction:column;
  gap:2rem;
  box-sizing:border-box;
}

.cbp-section-list{
  width:100%;
  display:grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  align-items:start;
}

.cbp-section-title{
  color:#C91235;
  font-weight:800;
  font-size:.9rem;
  letter-spacing:.08em;
  text-transform:uppercase;
  margin: 0;
  line-height:1.3;
  text-align:left;
  justify-self:start;
  padding-left: 0;
  align-self: start;
}

.cbp-cards{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 340px));
  gap:1.5rem;
  width:100%;
  min-width:0;

  justify-content: center;
}

.cbp-bio-row{
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:.75rem;
  padding:1rem;
  display:flex;
  flex-direction:column;
  gap:.75rem;
  min-width:0;

  box-shadow:0 4px 16px rgba(0,0,0,.06);
  transition:transform .12s ease, box-shadow .12s ease;
}

.cbp-bio-row:hover{
  transform:translateY(-2px);
  box-shadow:0 10px 28px rgba(0,0,0,.10);
}

.cbp-bio-photo{
  width:100%;
  aspect-ratio: 3 / 2;
  overflow:hidden;
  border-radius:.5rem;
}

.cbp-bio-photo img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  border-radius:0;
  object-position:center 20%;
}


.cbp-bio-content{
  min-width:0;
}

.cbp-bio-name{
  margin:0;
  font-size:1.05rem;
  font-weight:700;
  color:#111827;
}

.cbp-bio-position{
  margin:.1rem 0 0;
  font-size:.85rem;
  color:#6b7280;
}

.cbp-bio-text{
  margin:.35rem 0 0;
  font-size:.9rem;
  line-height:1.5;
  white-space:pre-wrap;
  overflow-wrap:anywhere;
  word-break:break-word;
}

.cbp-bio-empty{
  font-style:italic;
}

.cbp-bio-expand{ margin-top:.35rem; }

.cbp-bio-summary{
  cursor:pointer;
  list-style:none;
}

.cbp-bio-summary::-webkit-details-marker{ display:none; }

.cbp-bio-preview{
  font-size:.9rem;
  line-height:1.5;
  white-space:pre-wrap;
  overflow-wrap:anywhere;
  word-break:break-word;

  display:-webkit-box;
  -webkit-line-clamp:4;
  -webkit-box-orient:vertical;
  overflow:hidden;
}

.cbp-bio-full{ display: none; margin-top: .5rem; }
.cbp-bio-expand[open] .cbp-bio-preview{ display:none; }
.cbp-bio-expand[open] .cbp-bio-full { display: block;}

.cbp-readmore{
  display:inline-block;
  margin-top:.25rem;
  font-weight:600;
  color:#0a5372;
  text-decoration:underline;
}
.cbp-readmore::after{ content:"Read more"; }
.cbp-bio-expand[open] .cbp-readmore::after{ content:"Read less"; }




/*@media (max-width:1200px){
  .cbp-cards{
    grid-template-columns:repeat(2,minmax(260px,1fr));
  }
}*/

@media (max-width:768px){
  .cbp-section-list{
    grid-template-columns:1fr;
  }
}
  /*.cbp-cards{
    grid-template-columns:1fr;
  }
}*/




@media (max-width:640px){
  .cbp-list{
    padding:0 16px;
  }
  .cbp-bio-photo img{
    height:auto;
    max-height:220px;
  }
}

.btn-marist-solid{
  background:#C91235;
  color:#fff;
  border:0;
  padding:.65rem 1rem;
  border-radius:.5rem;
  font-weight:600;
}

.btn-marist-solid:hover{
  background:#A0102A;
  color:#fff;
}

#bio-root{
  max-width:1100px;
  margin:0 auto;
}

#bio-root .bio-card{
  border:1px solid #e5e7eb;
  border-radius:.5rem;
  background:#f9fafb;
  padding:1rem 1.25rem;
  box-shadow:0 1px 3px rgba(0,0,0,.06);
  margin-bottom:.75rem;
}

#bio-root .bio-card-header{
  margin-bottom:.75rem;
}

#bio-root .bio-card-title{
  margin:0;
  font-size:1rem;
  font-weight:600;
  color:#111827;
}

#bio-root .bio-card-body{
  display:flex;
  gap:1.25rem;
  align-items:flex-start;
  flex-wrap:wrap;
}

#bio-root .bio-photo-col{
  flex:0 0 220px;
  max-width:220px;
}

#bio-root .bio-fields-col{
  flex:1 1 260px;
  min-width:260px;
}

#bio-root .bio-label{
  display:block;
  font-size:.875rem;
  font-weight:500;
  color:#374151;
  margin-bottom:.25rem;
}

#bio-root .bio-input{
  width:100%;
  border:1px solid #d1d5db;
  border-radius:.375rem;
  padding:.35rem .5rem;
  font-size:.875rem;
  background:#fff;
}

#bio-root .bio-photo-preview{
  width:160px;
  height:160px;
  object-fit:cover;
  border-radius:.5rem;
  border:1px solid #e5e7eb;
}

#bio-root .bio-textarea{
  width:100%;
  min-height:90px;
  border:1px solid #d1d5db;
  border-radius:.375rem;
  padding:.5rem .6rem;
  font-size:.9rem;
  resize:vertical;
  background:#fff;
}

#bio-root .bio-actions{
  margin-top:.75rem;
  text-align:right;
}

@media (max-width:640px){
  #bio-root .bio-card-body{
    flex-direction:column;
  }
  #bio-root .bio-photo-col,
  #bio-root .bio-fields-col{
    max-width:100%;
    flex:1 1 auto;
  }
  #bio-root .bio-photo-preview{
    width:100%;
    max-width:220px;
    height:auto;
  }
}

