/* =============================================================
   assets/css/style.css  —  SPMB SMK Ma'arif Batu
   Desain: Institutional / Authoritative + Modern Warmth
   ============================================================= */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@700;900&family=Plus+Jakarta+Sans:wght@300;400;500;600;700&display=swap');

/* ---------- CSS Variables ---------- */
:root {
  --green-deep:  #1a4731;
  --green-mid:   #2d6a4f;
  --green-light: #52b788;
  --gold:        #c9a84c;
  --gold-light:  #e8c96e;
  --cream:       #fdf8f0;
  --cream-dark:  #f4ece0;
  --text-dark:   #1c1c1e;
  --text-mid:    #3d4451;
  --text-light:  #6b7280;
  --white:       #ffffff;
  --red:         #d62828;
  --shadow-sm:   0 2px 8px rgba(26,71,49,.10);
  --shadow-md:   0 6px 24px rgba(26,71,49,.15);
  --shadow-lg:   0 16px 48px rgba(26,71,49,.20);
  --radius:      12px;
  --radius-sm:   8px;
  --transition:  .25s cubic-bezier(.4,0,.2,1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: 'Plus Jakarta Sans', sans-serif;
  background: var(--cream);
  color: var(--text-dark);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--green-mid); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--green-deep); }

/* ---------- Utility ---------- */
.container  { max-width: 1160px; margin: 0 auto; padding: 0 1.5rem; }
.text-center{ text-align: center; }
.d-flex     { display: flex; }
.align-center { align-items: center; }
.gap-1  { gap: .5rem; }
.gap-2  { gap: 1rem; }
.gap-3  { gap: 1.5rem; }
.mt-1   { margin-top: .5rem; }
.mt-2   { margin-top: 1rem; }
.mt-3   { margin-top: 1.5rem; }
.mb-2   { margin-bottom: 1rem; }
.hidden { display: none !important; }

/* ---------- Navbar ---------- */
.navbar {
  background: var(--green-deep);
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 2px 16px rgba(0,0,0,.25);
}
.navbar-inner {
  display: flex; align-items: center;
  justify-content: space-between;
  padding: .85rem 1.5rem;
  max-width: 1160px; margin: 0 auto;
}
.navbar-brand {
  display: flex; align-items: center; gap: .9rem;
}
.navbar-logo {
  width: 44px; height: 44px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem; font-weight: 900;
  color: var(--green-deep); flex-shrink: 0;
}
.navbar-title { color: var(--white); }
.navbar-title strong {
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem; line-height: 1.2;
}
.navbar-title span {
  font-size: .72rem; color: rgba(255,255,255,.65);
  letter-spacing: .04em;
}
.navbar-nav { display: flex; align-items: center; gap: .25rem; }
.navbar-nav a {
  color: rgba(255,255,255,.80);
  padding: .45rem .9rem;
  border-radius: var(--radius-sm);
  font-size: .88rem; font-weight: 500;
  transition: all var(--transition);
}
.navbar-nav a:hover, .navbar-nav a.active {
  background: rgba(255,255,255,.12);
  color: var(--white);
}
.navbar-toggle {
  display: none;
  background: none; border: none;
  cursor: pointer; padding: .5rem;
  flex-direction: column; gap: 5px;
}
.navbar-toggle span {
  display: block; width: 24px; height: 2px;
  background: var(--white); border-radius: 2px;
  transition: all var(--transition);
}

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(135deg, var(--green-deep) 0%, var(--green-mid) 60%, #3a8a6a 100%);
  padding: 5rem 0 4rem;
  position: relative; overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(circle at 80% 20%, rgba(201,168,76,.15) 0%, transparent 50%),
    url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero-content {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1fr auto;
  align-items: center; gap: 3rem;
}
.hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 5vw, 3.2rem);
  color: var(--white); line-height: 1.2;
  margin-bottom: 1rem;
}
.hero h1 em {
  font-style: normal; color: var(--gold-light);
}
.hero p {
  color: rgba(255,255,255,.80);
  font-size: 1.05rem; max-width: 520px;
  margin-bottom: 2rem;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: .5rem;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.20);
  color: var(--gold-light);
  font-size: .82rem; font-weight: 600;
  padding: .35rem .85rem; border-radius: 100px;
  margin-bottom: 1.2rem;
  letter-spacing: .05em; text-transform: uppercase;
}
.hero-badge::before { content: '●'; font-size: .5rem; }
.hero-stats {
  display: flex; gap: 2rem; margin-top: 1rem;
}
.hero-stat strong {
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: 2rem; color: var(--gold-light); line-height: 1;
}
.hero-stat span { font-size: .78rem; color: rgba(255,255,255,.65); }
.hero-card {
  background: rgba(255,255,255,.08);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: var(--radius);
  padding: 1.75rem;
  min-width: 240px;
}
.hero-card h3 {
  color: var(--gold-light);
  font-family: 'Playfair Display', serif;
  font-size: 1rem; margin-bottom: 1rem;
}
.hero-card-stat {
  display: flex; justify-content: space-between;
  align-items: center;
  padding: .5rem 0;
  border-bottom: 1px solid rgba(255,255,255,.08);
  font-size: .85rem; color: rgba(255,255,255,.80);
}
.hero-card-stat:last-child { border-bottom: none; }
.hero-card-stat strong { color: var(--white); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .7rem 1.6rem;
  border-radius: var(--radius-sm);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 600; font-size: .9rem;
  border: 2px solid transparent;
  cursor: pointer; transition: all var(--transition);
  text-decoration: none; line-height: 1;
}
.btn-primary {
  background: var(--gold); color: var(--green-deep);
  border-color: var(--gold);
}
.btn-primary:hover {
  background: var(--gold-light); color: var(--green-deep);
  transform: translateY(-1px); box-shadow: var(--shadow-md);
}
.btn-outline {
  background: transparent; color: var(--white);
  border-color: rgba(255,255,255,.4);
}
.btn-outline:hover {
  background: rgba(255,255,255,.1); color: var(--white);
}
.btn-green {
  background: var(--green-mid); color: var(--white);
  border-color: var(--green-mid);
}
.btn-green:hover {
  background: var(--green-deep); color: var(--white);
  transform: translateY(-1px); box-shadow: var(--shadow-md);
}
.btn-danger {
  background: var(--red); color: var(--white);
  border-color: var(--red);
}
.btn-sm { padding: .45rem 1rem; font-size: .82rem; }
.btn-lg { padding: .9rem 2.2rem; font-size: 1rem; }
.btn-block { width: 100%; justify-content: center; }

/* ---------- Section ---------- */
.section { padding: 4rem 0; }
.section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--green-deep);
  margin-bottom: .5rem;
}
.section-sub {
  color: var(--text-light);
  font-size: .95rem; max-width: 560px;
}
.section-header { margin-bottom: 2.5rem; }
.divider {
  width: 60px; height: 4px;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  border-radius: 2px; margin: .75rem 0 1rem;
}

/* ---------- Cards ---------- */
.card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(26,71,49,.06);
  overflow: hidden;
  transition: box-shadow var(--transition), transform var(--transition);
}
.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.card-body { padding: 1.75rem; }
.card-header {
  padding: 1.2rem 1.75rem;
  background: var(--cream-dark);
  border-bottom: 1px solid rgba(26,71,49,.08);
  font-weight: 600; color: var(--green-deep);
  display: flex; align-items: center; gap: .6rem;
}

/* ---------- Jurusan Grid ---------- */
.jurusan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}
.jurusan-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.75rem;
  border: 1px solid rgba(26,71,49,.08);
  border-left: 4px solid var(--green-light);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  display: flex; align-items: center; gap: 1.1rem;
}
.jurusan-card:hover {
  border-left-color: var(--gold);
  box-shadow: var(--shadow-md);
  transform: translateX(3px);
}
.jurusan-icon {
  width: 52px; height: 52px; flex-shrink: 0;
  background: var(--cream-dark);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
}
.jurusan-info h4 {
  font-size: .95rem; font-weight: 700;
  color: var(--green-deep); line-height: 1.3;
}
.jurusan-info .kode {
  font-size: .75rem; color: var(--gold);
  font-weight: 700; letter-spacing: .08em;
}

/* ---------- Form ---------- */
.form-section {
  background: var(--white);
  border-radius: var(--radius);
  margin-bottom: 1.75rem;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(26,71,49,.07);
}
.form-section-header {
  padding: 1rem 1.75rem;
  background: linear-gradient(135deg, var(--green-deep), var(--green-mid));
  color: var(--white);
  font-weight: 700; font-size: 1rem;
  display: flex; align-items: center; gap: .6rem;
}
.form-section-body { padding: 1.75rem; }
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}
.form-group { display: flex; flex-direction: column; gap: .4rem; }
.form-group.full { grid-column: 1 / -1; }
.form-label {
  font-size: .85rem; font-weight: 600;
  color: var(--text-mid);
}
.form-label .req { color: var(--red); margin-left: 2px; }
.form-control {
  width: 100%;
  padding: .65rem 1rem;
  border: 1.5px solid #dde3e0;
  border-radius: var(--radius-sm);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: .9rem; color: var(--text-dark);
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}
.form-control:focus {
  border-color: var(--green-light);
  box-shadow: 0 0 0 3px rgba(82,183,136,.15);
}
.form-control.is-invalid { border-color: var(--red); }
.form-control:disabled { background: var(--cream-dark); cursor: not-allowed; }
select.form-control { cursor: pointer; }
textarea.form-control { resize: vertical; min-height: 90px; }
.form-hint  { font-size: .78rem; color: var(--text-light); }
.form-error { font-size: .78rem; color: var(--red); font-weight: 500; }

/* Radio/Checkbox custom */
.radio-group { display: flex; flex-wrap: wrap; gap: .75rem; }
.radio-item  {
  display: flex; align-items: center; gap: .45rem;
  cursor: pointer; font-size: .88rem;
}
.radio-item input[type="radio"],
.radio-item input[type="checkbox"] {
  accent-color: var(--green-mid);
  width: 1rem; height: 1rem; cursor: pointer;
}

/* ---------- Alert / Flash ---------- */
.alert {
  padding: .9rem 1.25rem;
  border-radius: var(--radius-sm);
  font-size: .9rem; margin-bottom: 1.25rem;
  display: flex; align-items: flex-start; gap: .6rem;
  border: 1px solid transparent;
}
.alert-success { background: #d4edda; color: #155724; border-color: #c3e6cb; }
.alert-danger   { background: #f8d7da; color: #721c24; border-color: #f5c6cb; }
.alert-warning  { background: #fff3cd; color: #856404; border-color: #ffeeba; }
.alert-info     { background: #d1ecf1; color: #0c5460; border-color: #bee5eb; }

/* ---------- Badge ---------- */
.badge {
  display: inline-flex; align-items: center;
  padding: .28rem .7rem;
  border-radius: 100px;
  font-size: .75rem; font-weight: 700;
  letter-spacing: .03em;
}
.badge-success  { background: #d4edda; color: #155724; }
.badge-danger   { background: #f8d7da; color: #721c24; }
.badge-warning  { background: #fff3cd; color: #856404; }
.badge-info     { background: #d1ecf1; color: #0c5460; }
.badge-secondary{ background: #e2e3e5; color: #383d41; }

/* ---------- Table ---------- */
.table-wrapper { overflow-x: auto; }
table.data-table {
  width: 100%; border-collapse: collapse;
  font-size: .88rem;
}
.data-table th {
  background: var(--green-deep);
  color: var(--white); padding: .8rem 1rem;
  text-align: left; font-weight: 600;
  white-space: nowrap;
}
.data-table td {
  padding: .75rem 1rem;
  border-bottom: 1px solid rgba(26,71,49,.07);
  vertical-align: middle;
}
.data-table tr:hover td { background: #f7faf8; }
.data-table tr:last-child td { border-bottom: none; }

/* ---------- Stepper ---------- */
.stepper {
  display: flex; justify-content: center;
  margin-bottom: 2.5rem;
}
.stepper-item {
  display: flex; flex-direction: column; align-items: center;
  flex: 1; max-width: 180px; position: relative;
}
.stepper-item::before {
  content: '';
  position: absolute; top: 20px; left: 50%; right: -50%;
  height: 2px; background: #dde3e0; z-index: 0;
}
.stepper-item:last-child::before { display: none; }
.stepper-num {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: #dde3e0; color: var(--text-light);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .9rem;
  position: relative; z-index: 1;
  transition: all var(--transition);
  margin-bottom: .5rem;
}
.stepper-item.active   .stepper-num { background: var(--green-mid);  color: var(--white); }
.stepper-item.done     .stepper-num { background: var(--green-deep); color: var(--white); }
.stepper-item.active::before        { background: var(--green-light); }
.stepper-item.done::before          { background: var(--green-deep); }
.stepper-label { font-size: .75rem; text-align: center; color: var(--text-light); }
.stepper-item.active .stepper-label { color: var(--green-mid); font-weight: 600; }

/* ---------- Stats Cards ---------- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1.25rem;
  margin-bottom: 2rem;
}
.stat-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.4rem 1.5rem;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--green-light);
  border-top: 1px solid rgba(26,71,49,.06);
}
.stat-card.green  { border-left-color: var(--green-mid);  }
.stat-card.gold   { border-left-color: var(--gold);       }
.stat-card.red    { border-left-color: var(--red);        }
.stat-card.teal   { border-left-color: #0d9488;           }
.stat-card-label  { font-size: .78rem; color: var(--text-light); margin-bottom: .3rem; }
.stat-card-value  {
  font-family: 'Playfair Display', serif;
  font-size: 2rem; line-height: 1; color: var(--green-deep);
}

/* ---------- Admin Sidebar ---------- */
.admin-layout { display: flex; min-height: 100vh; }
.sidebar {
  width: 250px; flex-shrink: 0;
  background: var(--green-deep);
  display: flex; flex-direction: column;
  position: sticky; top: 0; height: 100vh;
}
.sidebar-brand {
  padding: 1.5rem 1.25rem 1rem;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.sidebar-brand-logo {
  width: 40px; height: 40px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Playfair Display', serif;
  font-weight: 900; color: var(--green-deep);
  margin-bottom: .6rem;
}
.sidebar-brand-name {
  font-family: 'Playfair Display', serif;
  font-size: .95rem; color: var(--white); line-height: 1.3;
}
.sidebar-brand-sub { font-size: .7rem; color: rgba(255,255,255,.5); }
.sidebar-nav { padding: 1rem .75rem; flex: 1; overflow-y: auto; }
.sidebar-nav-item {
  display: flex; align-items: center; gap: .75rem;
  padding: .65rem 1rem;
  color: rgba(255,255,255,.7);
  border-radius: var(--radius-sm);
  font-size: .88rem; font-weight: 500;
  transition: all var(--transition);
  margin-bottom: .2rem;
}
.sidebar-nav-item:hover, .sidebar-nav-item.active {
  background: rgba(255,255,255,.12);
  color: var(--white);
}
.sidebar-nav-item.active { background: var(--gold); color: var(--green-deep); font-weight: 700; }
.sidebar-nav-item svg { width: 18px; height: 18px; flex-shrink: 0; }
.sidebar-label {
  font-size: .68rem; text-transform: uppercase;
  letter-spacing: .1em; color: rgba(255,255,255,.35);
  padding: 1rem 1rem .3rem;
}
.sidebar-footer {
  padding: 1rem .75rem;
  border-top: 1px solid rgba(255,255,255,.08);
}
.admin-main { flex: 1; display: flex; flex-direction: column; overflow-x: hidden; }
.admin-topbar {
  background: var(--white);
  padding: 1rem 2rem;
  border-bottom: 1px solid rgba(26,71,49,.08);
  display: flex; align-items: center; justify-content: space-between;
  box-shadow: var(--shadow-sm);
}
.admin-topbar-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem; color: var(--green-deep);
}
.admin-topbar-user {
  display: flex; align-items: center; gap: .75rem;
  font-size: .85rem; color: var(--text-mid);
}
.admin-content { padding: 2rem; flex: 1; }

/* ---------- Pagination ---------- */
.pagination {
  display: flex; gap: .4rem; align-items: center;
  justify-content: center; flex-wrap: wrap;
  margin-top: 1.5rem;
}
.page-btn {
  min-width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border: 1.5px solid #dde3e0;
  border-radius: var(--radius-sm);
  font-size: .85rem; color: var(--text-mid);
  cursor: pointer; transition: all var(--transition);
  background: var(--white); text-decoration: none;
}
.page-btn:hover { border-color: var(--green-light); color: var(--green-mid); }
.page-btn.active {
  background: var(--green-mid);
  border-color: var(--green-mid);
  color: var(--white); font-weight: 700;
}
.page-btn.disabled { opacity: .4; pointer-events: none; }

/* ---------- Footer ---------- */
.footer {
  background: var(--green-deep);
  color: rgba(255,255,255,.75);
  padding: 2.5rem 0 1.5rem;
  margin-top: 4rem;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr;
  gap: 2.5rem; margin-bottom: 2rem;
}
.footer h4 {
  color: var(--gold-light);
  font-family: 'Playfair Display', serif;
  margin-bottom: .75rem; font-size: 1rem;
}
.footer p, .footer li { font-size: .85rem; line-height: 1.7; }
.footer ul { list-style: none; }
.footer ul li a { color: rgba(255,255,255,.65); transition: color var(--transition); }
.footer ul li a:hover { color: var(--gold-light); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 1.2rem;
  text-align: center;
  font-size: .78rem; color: rgba(255,255,255,.4);
}

/* ---------- Pengumuman ---------- */
.notice-bar {
  background: var(--gold);
  padding: .6rem 0;
}
.notice-bar-inner {
  max-width: 1160px; margin: 0 auto;
  padding: 0 1.5rem;
  display: flex; align-items: center; gap: 1rem;
  font-size: .85rem; color: var(--green-deep);
}
.notice-bar strong { font-weight: 700; white-space: nowrap; }

/* ---------- Print ---------- */
@media print {
  .navbar, .footer, .btn, .sidebar { display: none !important; }
  body { font-size: 12px; }
  .card { box-shadow: none; border: 1px solid #ccc; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1200px) {
  .hero-card1 {
    display: none !important;
  }
}

@media (max-width: 900px) {
  .hero-content { grid-template-columns: 1fr; }
  .hero-card    { display: none; }
  .footer-grid  { grid-template-columns: 1fr; }
  .sidebar      { width: 220px; }
  .admin-content{ padding: 1.25rem; }
}
@media (max-width: 680px) {
  .navbar-nav   { display: none; }
  .navbar-nav.open { display: flex; flex-direction: column; width: 100%; }
  .navbar-toggle{ display: flex; }
  .navbar-inner { flex-wrap: wrap; }
  .hero { padding: 3rem 0 2.5rem; }
  .hero h1 { font-size: 1.8rem; }
  .hero-stats   { flex-wrap: wrap; gap: 1rem; }
  .admin-layout { flex-direction: column; }
  .sidebar      { width: 100%; height: auto; position: static; }
  .stepper      { display: none; }
  .form-grid    { grid-template-columns: 1fr; }
  .stats-grid   { grid-template-columns: repeat(2,1fr); }
}
