/* ============================================================
   TEFA SMK Dr. Sutomo — Gaya Halaman Depan (style.css)
   ============================================================ */

:root {
  /* Palet warna diambil dari logo resmi SMK Dr. Sutomo:
     biru langit #6CC4E8, kuning #FFF500, hitam #1E1A17, merah #D92524 */
  --navy: #0F3A5F;
  --navy-2: #15507E;
  --navy-3: #1C6194;
  --blue: #1E88C7;
  --blue-dark: #1572AB;
  --sky: #6CC4E8;
  --gold: #FFC400;
  --gold-bright: #FFF500;
  --red: #D92524;
  --green: #16a34a;
  --bg: #F2F7FB;
  --white: #ffffff;
  --ink: #16324B;
  --muted: #5F7D99;
  --line: #DCE8F2;
  --shadow: 0 10px 30px rgba(15, 58, 95, .08);
  --shadow-lg: 0 18px 40px rgba(15, 58, 95, .16);
  --radius: 14px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 20px; }

/* ---------- Tombol ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; cursor: pointer; font-family: inherit; font-weight: 700;
  border-radius: 10px; padding: 12px 22px; font-size: .95rem; transition: .2s;
}
.btn-primary {
  background: linear-gradient(135deg, var(--blue), var(--blue-dark));
  color: #fff; box-shadow: 0 8px 20px rgba(30, 136, 199, .35); white-space: nowrap;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(30, 136, 199, .45); }
.btn-ghost { background: transparent; color: var(--navy); border: 2px solid var(--line); }
.btn-ghost:hover { border-color: var(--blue); color: var(--blue-dark); }
.btn-sm { padding: 8px 14px; font-size: .85rem; border-radius: 8px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: linear-gradient(90deg, var(--navy), var(--navy-2));
  box-shadow: 0 2px 18px rgba(0, 0, 0, .18);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 20px; }
.brand-logo {
  height: 54px; width: auto; background: #fff; border-radius: 12px;
  padding: 4px 6px; box-shadow: 0 2px 10px rgba(0, 0, 0, .25);
}
.main-nav { display: flex; align-items: center; gap: 6px; }
.main-nav a { color: #dbe4f0; font-weight: 600; font-size: .92rem; padding: 8px 12px; border-radius: 8px; transition: .2s; }
.main-nav a:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.main-nav .btn { color: #fff; }
.nav-toggle { display: none; background: none; border: 0; color: #fff; font-size: 1.6rem; cursor: pointer; padding: 4px 8px; }

/* ---------- Hero & Search ---------- */
.hero {
  background:
    radial-gradient(1000px 500px at 85% -10%, rgba(108, 196, 232, .30), transparent 60%),
    radial-gradient(800px 400px at -10% 110%, rgba(255, 244, 0, .12), transparent 60%),
    linear-gradient(160deg, var(--navy) 0%, var(--navy-2) 60%, var(--navy-3) 100%);
  color: #fff; padding: 84px 0 130px; text-align: center;
}
.hero-badge {
  display: inline-block; background: rgba(255, 196, 0, .12); border: 1px solid rgba(255, 196, 0, .5);
  color: var(--gold-bright); font-size: .85rem; font-weight: 700; padding: 8px 18px;
  border-radius: 999px; letter-spacing: .5px; margin-bottom: 22px;
}
.hero h1 { font-size: clamp(2rem, 4.5vw, 3.2rem); font-weight: 800; line-height: 1.15; }
.hero h1 span { color: var(--gold-bright); }
.hero-sub { max-width: 640px; margin: 18px auto 34px; color: #cfe0f0; }

.track-form { max-width: 760px; margin: 0 auto; }
.track-input-wrap {
  display: flex; gap: 10px; align-items: center; background: #fff;
  border-radius: 16px; padding: 10px; box-shadow: var(--shadow-lg);
}
.track-input-wrap svg { flex-shrink: 0; margin-left: 8px; color: var(--muted); }
.track-input-wrap input {
  flex: 1; min-width: 0; border: 0; outline: 0; font-size: 1rem;
  padding: 10px 6px; font-family: inherit; color: var(--ink); background: transparent;
}
.track-hint { margin-top: 14px; color: #9fb0c9; font-size: .85rem; }

/* ---------- Hasil Pelacakan ---------- */
.track-result { max-width: 860px; margin: 28px auto 0; text-align: left; }
.track-loading { color: #cfe0f5; text-align: center; }
.spinner {
  display: inline-block; width: 22px; height: 22px; border: 3px solid rgba(255, 255, 255, .25);
  border-top-color: var(--gold-bright); border-radius: 50%; animation: spin .8s linear infinite;
  vertical-align: middle; margin-right: 8px;
}
@keyframes spin { to { transform: rotate(360deg); } }
.track-error {
  background: rgba(217, 37, 36, .12); border: 1px solid rgba(217, 37, 36, .5);
  color: #ffc6c3; padding: 16px 20px; border-radius: 12px;
}
.track-card {
  background: #fff; color: var(--ink); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); overflow: hidden; animation: fadeUp .35s ease;
}
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.track-head {
  display: flex; justify-content: space-between; gap: 14px; align-items: flex-start;
  padding: 22px 24px; background: linear-gradient(135deg, var(--navy), var(--navy-2)); color: #fff;
}
.track-id { font-weight: 800; color: var(--gold-bright); letter-spacing: .5px; }
.track-head h3 { margin-top: 4px; font-size: 1.15rem; }
.track-head p { color: #b7c6dd; font-size: .88rem; }
.status-pill {
  background: linear-gradient(135deg, var(--blue), var(--blue-dark)); color: #fff;
  font-weight: 700; font-size: .8rem; padding: 6px 14px; border-radius: 999px; white-space: nowrap;
}
.status-pill.small { font-size: .72rem; padding: 3px 10px; }

/* ---------- Timeline Stepper ---------- */
.track-stepper { display: flex; padding: 30px 24px 14px; }
.step { flex: 1; text-align: center; position: relative; padding: 0 4px; }
.step::before {
  content: ''; position: absolute; top: 18px; left: calc(-50% + 18px);
  width: calc(100% - 18px); height: 3px; background: var(--line); z-index: 0;
}
.step:first-child::before { display: none; }
.step.done::before, .step.active::before { background: var(--green); }
.step-dot {
  position: relative; z-index: 1; width: 36px; height: 36px; border-radius: 50%; margin: 0 auto;
  background: #e7ecf3; color: var(--muted); font-weight: 800; font-size: .9rem;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 1px var(--line);
}
.step.done .step-dot { background: var(--green); color: #fff; box-shadow: 0 0 0 1px var(--green); }
.step.active .step-dot {
  background: var(--blue); color: #fff; box-shadow: 0 0 0 1px var(--blue), 0 0 0 7px rgba(30, 136, 199, .18);
}
.step-label { margin-top: 10px; font-size: .76rem; font-weight: 600; color: var(--muted); line-height: 1.25; }
.step.done .step-label, .step.active .step-label { color: var(--navy); font-weight: 700; }

/* ---------- Detail Transaksi ---------- */
.track-detail-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 14px; padding: 16px 24px 24px;
}
.track-detail-grid > div {
  background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px;
}
.track-detail-grid span {
  display: block; font-size: .7rem; color: var(--muted); font-weight: 700;
  text-transform: uppercase; letter-spacing: .5px; margin-bottom: 4px;
}
.track-detail-grid b { font-size: .92rem; word-break: break-word; }
.track-detail-grid .total { color: var(--blue-dark); font-size: 1.2rem; }
.span-2 { grid-column: span 2; }

/* ---------- Riwayat (Accordion) ---------- */
.history { border-top: 1px solid var(--line); }
.history summary {
  cursor: pointer; font-weight: 700; padding: 16px 24px; color: var(--navy);
  list-style: none; display: flex; align-items: center; gap: 8px;
}
.history summary::-webkit-details-marker { display: none; }
.history summary::after { content: '\25BE'; margin-left: auto; transition: .2s; color: var(--blue); }
.history[open] summary::after { transform: rotate(180deg); }
.history-list { padding: 0 24px 22px; display: grid; gap: 8px; }
.history-list li {
  display: grid; grid-template-columns: 1.2fr 1.6fr 1fr auto; gap: 10px; align-items: center;
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; font-size: .85rem;
}
.h-id { font-weight: 800; color: var(--navy); }
.h-cat, .h-date { color: var(--muted); }

/* ---------- Section Umum ---------- */
.section { padding: 76px 0; }
.section-alt { background: #fff; }
.section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; color: var(--navy); text-align: center;
}
.section-title::after {
  content: ''; display: block; width: 64px; height: 4px; border-radius: 4px;
  background: linear-gradient(90deg, var(--blue), var(--gold)); margin: 12px auto 0;
}
.section-sub { text-align: center; color: var(--muted); margin-top: 12px; margin-bottom: 40px; }
.empty-state { text-align: center; color: var(--muted); padding: 20px; }

/* ---------- Layanan ---------- */
.service-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; }
.service-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px 22px; box-shadow: var(--shadow); transition: .25s;
}
.service-card:hover {
  transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: rgba(30, 136, 199, .45);
}
.service-icon {
  width: 52px; height: 52px; border-radius: 14px; background: linear-gradient(135deg, var(--navy), var(--navy-3));
  color: var(--gold-bright); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: .9rem; margin-bottom: 16px;
}
.service-card h3 { font-size: 1.02rem; color: var(--navy); margin-bottom: 8px; }
.service-card p { color: var(--muted); font-size: .88rem; }

/* ---------- Pengumuman ---------- */
.announce-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 22px; }
.announce-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); transition: .25s; display: flex; flex-direction: column;
}
.announce-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.announce-img { height: 170px; background-size: cover; background-position: center; }
.announce-img-gradient { background: linear-gradient(135deg, var(--navy), var(--navy-3), var(--blue-dark)); }
.announce-body { padding: 20px 22px 24px; }
.announce-date { font-size: .75rem; color: var(--blue-dark); font-weight: 700; text-transform: uppercase; letter-spacing: .6px; }
.announce-body h3 { margin: 6px 0 8px; color: var(--navy); font-size: 1.05rem; }
.announce-body p { color: var(--muted); font-size: .88rem; }

/* ---------- Lokasi ---------- */
.location-wrap { display: grid; grid-template-columns: 1.1fr 1fr; gap: 26px; align-items: center; }
.map-frame { border: 0; width: 100%; height: 340px; border-radius: var(--radius); box-shadow: var(--shadow); }
.location-info h3 { font-size: 1.25rem; color: var(--navy); margin-bottom: 6px; }
.location-info > p { color: var(--muted); margin-bottom: 18px; }
.location-info ul { list-style: none; margin-bottom: 20px; }
.location-info li { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; color: var(--muted); font-size: .92rem; }
.location-info li svg { flex-shrink: 0; margin-top: 3px; }
.location-info li a { color: var(--blue-dark); font-weight: 700; }
.location-info li a:hover { text-decoration: underline; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: #c9d6ea; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 34px; padding: 52px 0 38px; }
.footer-brand img {
  height: 62px; width: auto; margin-bottom: 14px; background: #fff; border-radius: 12px;
  padding: 5px 8px; box-shadow: 0 2px 10px rgba(0, 0, 0, .25);
}
.footer-brand p { font-size: .88rem; max-width: 360px; }
.footer h4 { color: #fff; font-size: .95rem; margin-bottom: 14px; }
.footer .quick { display: block; padding: 5px 0; font-size: .9rem; color: #c9d6ea; }
.footer .quick:hover { color: var(--gold); }
.social-links { display: flex; gap: 10px; margin-top: 16px; }
.social-btn {
  width: 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .08); color: #fff; font-weight: 800; font-size: .78rem;
  border: 1px solid rgba(255, 255, 255, .15); transition: .2s;
}
.social-btn:hover { background: var(--blue); transform: translateY(-3px); }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding: 16px 0; text-align: center; font-size: .82rem; color: #8fa3bf; }

/* ---------- Responsif ---------- */
@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .main-nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; background: var(--navy-2);
    padding: 14px; gap: 4px; border-top: 1px solid rgba(255, 255, 255, .1);
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 12px 14px; }
  .main-nav .btn { justify-content: center; }
  .track-input-wrap { flex-direction: column; align-items: stretch; }
  .track-input-wrap input { text-align: center; }
  .location-wrap { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
  .history-list li { grid-template-columns: 1fr 1fr; }
  .track-stepper { flex-direction: column; gap: 10px; padding: 22px 24px 8px; }
  .step { display: flex; gap: 12px; align-items: center; text-align: left; }
  .step::before { display: none; }
  .step-dot { margin: 0; flex-shrink: 0; }
  .step-label { margin: 0; }
  .span-2 { grid-column: span 1; }
}
