/* ===========================================================
   KIP Kuliah — Universitas Sawerigading Makassar
   Token system
   =========================================================== */
:root{
  --bg: #FAF7F1;
  --surface: #F1EADA;
  --ink: #1B2A3C;
  --ink-soft: #5B6672;
  --accent: #C1832E;
  --accent-deep: #8C5F1F;
  --good: #2E6E58;
  --line: #DED4BE;
  --navy: #16273B;
  --navy-soft: #223349;
  --max: clamp(760px, 62vw, 940px);
  --max-wide: clamp(920px, 82vw, 1400px);
}

*{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

body{
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3{
  font-family: 'Fraunces', Georgia, serif;
  color: var(--ink);
  line-height: 1.15;
  margin: 0 0 0.5em;
  font-weight: 600;
}

h1{ font-size: clamp(2rem, 5vw, 2.9rem); }
h2{ font-size: clamp(1.5rem, 3.4vw, 1.9rem); margin-top: 0; }
h3{ font-size: 1.15rem; }

p{ margin: 0 0 1em; }
a{ color: var(--accent-deep); }
a:focus-visible, button:focus-visible, summary:focus-visible{
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.wrap{ max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* ---------- Header / nav ---------- */
header.site{
  background: var(--navy);
  color: #F3EFE4;
  border-bottom: 3px solid var(--accent);
}
header.site .wrap{
  max-width: var(--max-wide);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding-top: 18px;
  padding-bottom: 18px;
  gap: 12px;
}
.brand{
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #F3EFE4;
}
.brand img{
  width: 40px;
  height: 40px;
  object-fit: contain;
  flex-shrink: 0;
}
.brand .brand-text{
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.brand strong{
  font-family: 'Fraunces', serif;
  font-size: 1.15rem;
  font-weight: 600;
}
.brand span{
  font-size: 0.8rem;
  color: #B9C3D0;
}
nav.main{
  display: flex;
  flex-wrap: wrap;
  gap: 4px 2px;
}
nav.main a{
  color: #DCE2EA;
  text-decoration: none;
  font-size: 0.93rem;
  padding: 7px 11px;
  border-radius: 3px;
}
nav.main a:hover{ background: var(--navy-soft); color: #fff; }
nav.main a[aria-current="page"]{
  color: #fff;
  background: var(--navy-soft);
  box-shadow: inset 0 -2px 0 var(--accent);
}

/* ---------- Hero ---------- */
.hero{
  background: var(--navy);
  color: #F3EFE4;
}
.hero .wrap{
  max-width: var(--max-wide);
  padding-top: 56px;
  padding-bottom: 56px;
}
.hero-grid{
  display: flex;
  align-items: center;
  gap: 40px;
}
.hero-text{ flex: 1 1 auto; min-width: 0; }
.hero-photo{
  width: 240px;
  height: 240px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--accent);
  flex-shrink: 0;
}
@media (max-width: 720px){
  .hero-grid{ flex-direction: column-reverse; text-align: center; }
  .hero-photo{ width: 180px; height: 180px; }
  .hero-text .eyebrow-line{ margin-left: auto; margin-right: auto; }
  .hero .cta-row{ justify-content: center; }
}
.hero .eyebrow-line{
  width: 46px;
  height: 3px;
  background: var(--accent);
  margin-bottom: 22px;
}
.hero h1{ color: #fff; max-width: 15ch; }
.hero p.lede{
  color: #C9D2DD;
  font-size: 1.1rem;
  max-width: 46ch;
  margin-top: 14px;
}
.hero .cta-row{
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}
.btn{
  display: inline-block;
  padding: 11px 20px;
  border-radius: 3px;
  text-decoration: none;
  font-size: 0.96rem;
  font-weight: 600;
  border: 1px solid transparent;
}
.btn.primary{
  background: var(--accent);
  color: #1B2A3C;
}
.btn.primary:hover{ background: #D6963F; }
.btn.ghost{
  color: #F3EFE4;
  border-color: #47566B;
}
.btn.ghost:hover{ border-color: var(--accent); color: var(--accent); }

/* ---------- Sections ---------- */
main{ padding: 52px 0 20px; }
section{ margin-bottom: 52px; }
section > h2{
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 22px;
}

.lead{
  font-size: 1.08rem;
  color: var(--ink-soft);
  max-width: 62ch;
}

/* quick-info blocks on beranda */
.quick-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.quick-grid > div{
  background: var(--surface);
  padding: 20px 18px;
}
.quick-grid .num{
  font-family: 'Fraunces', serif;
  font-size: 1.7rem;
  color: var(--accent-deep);
  display: block;
  margin-bottom: 4px;
}
.quick-grid .label{
  color: var(--ink-soft);
  font-size: 0.92rem;
}

/* info block (bordered, not shadowed) */
.block{
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 22px 24px;
  margin-bottom: 16px;
}
.block h3{ margin-bottom: 8px; }
.block p:last-child{ margin-bottom: 0; }

/* timeline — only for genuine sequences */
.timeline{
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 2px solid var(--line);
}
.timeline li{
  position: relative;
  padding: 2px 0 26px 26px;
}
.timeline li::before{
  content: attr(data-step);
  position: absolute;
  left: -19px;
  top: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--accent);
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.timeline li strong{ display: block; margin-bottom: 3px; }
.timeline li p{ color: var(--ink-soft); margin: 0; }

/* checklist for documents */
ul.doclist{ padding-left: 0; list-style: none; }
ul.doclist li{
  padding: 10px 0 10px 30px;
  border-bottom: 1px solid var(--line);
  position: relative;
}
ul.doclist li:last-child{ border-bottom: none; }
ul.doclist li::before{
  content: "";
  position: absolute;
  left: 0;
  top: 15px;
  width: 12px;
  height: 12px;
  border: 2px solid var(--good);
}

/* FAQ */
details.faq{
  border-bottom: 1px solid var(--line);
  padding: 16px 0;
}
details.faq summary{
  cursor: pointer;
  font-family: 'Fraunces', serif;
  font-size: 1.05rem;
  font-weight: 600;
  list-style: none;
}
details.faq summary::-webkit-details-marker{ display: none; }
details.faq summary::before{
  content: "+";
  display: inline-block;
  width: 1.1em;
  color: var(--accent-deep);
}
details.faq[open] summary::before{ content: "–"; }
details.faq p{ margin: 10px 0 0 1.6em; color: var(--ink-soft); }

/* note / disclaimer */
.note{
  border-left: 3px solid var(--accent);
  background: var(--surface);
  padding: 14px 18px;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

/* contact */
.contact-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px,1fr));
  gap: 16px;
}

table.simple{
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 8px;
}
table.simple th, table.simple td{
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  font-size: 0.95rem;
}
table.simple th{ color: var(--ink-soft); font-weight: 600; width: 40%; }

/* ---------- Footer ---------- */
footer.site{
  background: var(--navy);
  color: #B9C3D0;
  margin-top: 40px;
}
footer.site .wrap{
  max-width: var(--max-wide);
  padding-top: 30px;
  padding-bottom: 30px;
  font-size: 0.88rem;
}
footer.site a{ color: #DCE2EA; }

@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
}

@media (max-width: 560px){
  nav.main{ gap: 2px; }
  nav.main a{ padding: 6px 8px; font-size: 0.88rem; }
  .hero .wrap{ padding-top: 40px; padding-bottom: 40px; }
}

/* ---------- Breadcrumb ---------- */
.breadcrumb{
  max-width: var(--max-wide);
  padding-top: 14px;
  padding-bottom: 0;
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.breadcrumb a{ color: var(--ink-soft); text-decoration: none; }
.breadcrumb a:hover{ color: var(--accent-deep); text-decoration: underline; }
.breadcrumb span{ margin: 0 4px; }

/* ---------- Zebra tables ---------- */
table.simple tr:nth-child(even) th,
table.simple tr:nth-child(even) td{
  background: var(--surface);
}

/* ---------- Back to top ---------- */
.back-to-top{
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: var(--navy);
  color: var(--accent);
  font-size: 1.2rem;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity .2s ease, transform .2s ease;
  z-index: 40;
}
.back-to-top.show{
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.back-to-top:hover{ background: var(--navy-soft); }
@media (prefers-reduced-motion: reduce){
  .back-to-top{ transition: none; }
}

/* ---------- Sambutan ---------- */
.sambutan-block{
  display: flex;
  gap: 28px;
  align-items: flex-start;
  margin-bottom: 8px;
}
.sambutan-block.reverse{ flex-direction: row-reverse; }
.sambutan-photo{
  width: 160px;
  height: 200px;
  object-fit: cover;
  object-position: top center;
  border: 1px solid var(--line);
  background: var(--surface);
  flex-shrink: 0;
}
.sambutan-text h2{ margin-bottom: 10px; }
.sambutan-text p{ color: var(--ink-soft); }
.sambutan-sign{ color: var(--ink) !important; margin-top: 14px; }
@media (max-width: 620px){
  .sambutan-block, .sambutan-block.reverse{
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .sambutan-photo{ width: 140px; height: 175px; }
}

/* ---------- WhatsApp link ---------- */
a.wa-link{
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--good);
  font-weight: 600;
  text-decoration: none;
}
a.wa-link:hover{ text-decoration: underline; }

/* ---------- News preview list (Beranda) ---------- */
.news-preview-list{
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
}
.news-preview-item{
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: var(--ink);
  background: var(--surface);
}
.news-preview-item:last-child{ border-bottom: none; }
.news-preview-item:hover{ background: var(--bg); }
.news-preview-item img{
  width: 84px;
  height: 64px;
  object-fit: cover;
  object-position: top center;
  flex-shrink: 0;
  border: 1px solid var(--line);
}
.news-preview-text{ min-width: 0; }
.news-preview-text h3{
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.98rem;
  margin: 2px 0 0;
  color: var(--ink);
}
.news-preview-text .slide-date{ font-size: 0.78rem; }
@media (max-width: 480px){
  .news-preview-item img{ width: 60px; height: 46px; }
}

/* ---------- Tracer Study ---------- */
.tracer-list{
  border: 1px solid var(--line);
}
.tracer-row{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 22px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
  text-decoration: none;
  color: var(--ink);
  transition: background-color .2s ease, padding-left .2s ease;
}
.tracer-row:last-child{ border-bottom: none; }
.tracer-row:hover{
  background: var(--bg);
  padding-left: 28px;
}
.tracer-name{
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 1.02rem;
}
.tracer-cta{
  font-size: 0.88rem;
  color: var(--accent-deep);
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
}
@media (max-width: 520px){
  .tracer-row{ flex-direction: column; align-items: flex-start; gap: 6px; padding: 14px 18px; }
}
/* ---------- Berita ---------- */
.berita-item{
  border: 1px solid var(--line);
  background: var(--surface);
  margin-bottom: 28px;
}
.berita-photo{
  width: 100%;
  aspect-ratio: 16 / 8;
  object-fit: contain;
  background: var(--bg);
  display: block;
  border-bottom: 1px solid var(--line);
}
.berita-body{ padding: 22px 26px 26px; }
.berita-body h2{ margin: 6px 0 12px; font-size: 1.35rem; }
.berita-body p{ color: var(--ink-soft); }
.berita-body p:last-child{ margin-bottom: 0; }
@media (max-width: 560px){
  .berita-body{ padding: 18px 18px 22px; }
}
/* ---------- Slider (Pengumuman & Kegiatan) ---------- */
.slider{
  position: relative;
  border: 1px solid var(--line);
  background: var(--surface);
}
.slider-viewport{ overflow: hidden; }
.slider-track{
  display: flex;
  transition: transform .45s ease;
}
@media (prefers-reduced-motion: reduce){
  .slider-track{ transition: none; }
}
.slide{
  min-width: 100%;
  display: flex;
  flex-direction: column;
}
.slide-photo.placeholder{
  aspect-ratio: 16 / 7;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-soft);
  font-size: 0.85rem;
  background: repeating-linear-gradient(
    45deg, var(--bg), var(--bg) 10px, var(--surface) 10px, var(--surface) 20px
  );
  border-bottom: 1px dashed var(--line);
}
img.slide-photo{
  aspect-ratio: 16 / 7;
  width: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  border-bottom: 1px solid var(--line);
}
img.slide-photo.contain{
  object-fit: contain;
  background: var(--surface);
}
.slide-caption{ padding: 20px 24px 24px; }
.slide-date{
  display: inline-block;
  font-size: 0.82rem;
  color: var(--accent-deep);
  font-weight: 600;
  margin-bottom: 6px;
}
.slide-caption h3{ margin-bottom: 8px; }
.slide-caption p{ color: var(--ink-soft); margin: 0; }

.slider-btn{
  position: absolute;
  top: calc(50% - 90px);
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}
.slider-btn:hover{ background: var(--accent); color: var(--navy); border-color: var(--accent); }
.slider-btn.prev{ left: 12px; }
.slider-btn.next{ right: 12px; }

.slider-dots{
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 14px 0 18px;
}
.slider-dots button{
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--line);
  cursor: pointer;
  padding: 0;
}
.slider-dots button.active{ background: var(--accent-deep); }

@media (max-width: 560px){
  .slider-btn{ top: calc(50% - 60px); width: 30px; height: 30px; font-size: 1.1rem; }
  .slide-caption{ padding: 16px 18px 20px; }
}

/* ===========================================================
   Full-bleed section bands
   =========================================================== */
main .wrap > section{
  position: relative;
}
main .wrap > section:nth-of-type(even){
  padding: 44px 0 48px;
}
main .wrap > section:nth-of-type(even)::before{
  content: "";
  position: absolute;
  top: 0; bottom: 0;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  background: var(--surface);
  z-index: -1;
}

/* Bigger, more immersive hero */
.hero .wrap{
  padding-top: 68px;
  padding-bottom: 68px;
}
@media (min-width: 860px){
  .hero{ display: flex; align-items: center; min-height: 74vh; }
  .hero .wrap{ padding-top: 40px; padding-bottom: 40px; }
}

/* ===========================================================
   Scroll-reveal animation
   =========================================================== */
.reveal{
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .6s ease, transform .6s ease;
}
.reveal.is-visible{
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce){
  .reveal{ opacity: 1; transform: none; transition: none; }
}

/* ===========================================================
   Livelier hover interactions
   =========================================================== */
.block, .berita-item, .quick-grid > div, .news-preview-item, .sambutan-block{
  transition: transform .25s ease, border-color .25s ease, background-color .25s ease;
}
.block:hover, .berita-item:hover{
  transform: translateY(-4px);
  border-color: var(--accent);
}
.quick-grid > div{ transition: background-color .2s ease, transform .2s ease; }
.quick-grid > div:hover{
  background: var(--bg);
  transform: translateY(-2px);
}
.news-preview-item{ transition: background-color .2s ease, padding-left .2s ease; }
.news-preview-item:hover{ padding-left: 24px; }
.timeline li::before{ transition: transform .2s ease, background-color .2s ease; }
.timeline li:hover::before{
  transform: scale(1.14);
  background: var(--accent-deep);
}
.btn{ transition: background-color .2s ease, border-color .2s ease, transform .15s ease, color .2s ease; }
.btn:active{ transform: scale(0.97); }
nav.main a{ transition: background-color .15s ease, color .15s ease; }
.sambutan-photo{ transition: transform .3s ease; }
.sambutan-block:hover .sambutan-photo{ transform: scale(1.03); }

