:root {
  --primary: #0d9488;        /* Emerald Teal */
  --primary-hover: #0f766e;
  --bg-light: #f8fafc;
  --surface: #ffffff;
  --text-dark: #0f172a;
  --text-muted: #64748b;
  --border: #e2e8f0;
  --accent: #f59e0b;         /* Amber/Gold Rating */
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Plus Jakarta Sans', sans-serif; }
body { background: var(--bg-light); color: var(--text-dark); }
.container { max-width: 1240px; margin: 0 auto; padding: 0 20px; }

/* NAVBAR */
/* Bug sebelumnya: "sticky;" bukan properti CSS yang valid, jadi navbar tidak pernah
   benar-benar sticky. Sudah diperbaiki jadi "position: sticky;". */
.navbar { background: var(--surface); height: 70px; display: flex; justify-content: space-between; align-items: center; padding: 0 5%; border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 100; }
.brand { display: flex; align-items: center; gap: 8px; font-size: 22px; color: var(--text-dark); }
.brand-icon { font-size: 26px; }
.brand-name strong { color: var(--primary); }
.nav-menu { display: flex; gap: 30px; }
.nav-menu a { text-decoration: none; color: var(--text-muted); font-weight: 500; font-size: 14px; transition: 0.2s; }
.nav-menu a:hover { color: var(--primary); }
.btn-primary-soft { background: #ccfbf1; color: var(--primary-hover); padding: 9px 18px; border-radius: 20px; text-decoration: none; font-weight: 600; font-size: 14px; border: none; cursor: pointer; }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.user-greeting { font-size: 14px; font-weight: 600; color: var(--text-dark); }
.btn-logout { background: #fee2e2; color: #b91c1c; }

/* HERO SECTION */
.hero-section { background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%); color: white; padding: 70px 20px 90px; text-align: center; }
.hero-badge { display: inline-block; background: rgba(13, 148, 136, 0.2); color: #2dd4bf; border: 1px solid rgba(45, 212, 191, 0.3); padding: 6px 16px; border-radius: 30px; font-size: 13px; font-weight: 600; margin-bottom: 20px; }
.hero-section h1 { font-size: 38px; font-weight: 700; max-width: 750px; margin: 0 auto 15px; line-height: 1.3; }
.hero-section p { color: #94a3b8; max-width: 600px; margin: 0 auto 40px; font-size: 15px; }

/* MAIN SEARCH CARD FLOATING */
.main-search-card { max-width: 950px; margin: 0 auto; background: var(--surface); padding: 15px 20px; border-radius: 16px; box-shadow: 0 20px 25px -5px rgba(0,0,0,0.2); display: grid; grid-template-columns: 1fr 1fr 1fr auto; gap: 15px; align-items: center; text-align: left; }
.search-field label { display: block; font-size: 11px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; margin-bottom: 4px; }
.search-field input, .search-field select { width: 100%; border: 1px solid var(--border); border-radius: 8px; padding: 10px; font-size: 14px; outline: none; background: #fff; }
.btn-search-main { background: var(--primary); color: white; border: none; padding: 14px 28px; border-radius: 10px; font-weight: 600; cursor: pointer; height: 100%; }

/* TAGS FILTER */
.filter-tags-section { margin-top: 40px; margin-bottom: 20px; }
.tags-wrapper { display: flex; align-items: center; gap: 10px; }
.tag-title { font-size: 13px; font-weight: 600; color: var(--text-muted); }
.tag-btn { background: white; border: 1px solid var(--border); padding: 8px 16px; border-radius: 20px; font-size: 13px; cursor: pointer; transition: 0.2s; }
.tag-btn.active, .tag-btn:hover { background: var(--primary); color: white; border-color: var(--primary); }

/* MAIN CONTENT & CARDS */
.main-layout { padding-bottom: 60px; }
.results-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.btn-toggle-view { background: white; border: 1px solid var(--border); padding: 8px 16px; border-radius: 8px; cursor: pointer; font-weight: 600; }
.map-box { margin-bottom: 30px; border-radius: 12px; overflow: hidden; border: 1px solid var(--border); }
#map { height: 350px; }

.school-cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.card-item { background: white; border: 1px solid var(--border); border-radius: 14px; overflow: hidden; transition: 0.2s; display: flex; flex-direction: column; }
.card-item:hover { box-shadow: 0 10px 15px -3px rgba(0,0,0,0.05); }
.card-banner { height: 160px; position: relative; background: #cbd5e1; }
.card-banner img { width: 100%; height: 100%; object-fit: cover; }
.card-type-badge { position: absolute; top: 12px; right: 12px; background: rgba(15, 23, 42, 0.8); color: white; font-size: 11px; padding: 4px 10px; border-radius: 6px; font-weight: 600; }
.card-content { padding: 18px; flex: 1; display: flex; flex-direction: column; }
.card-title { font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.card-meta { font-size: 13px; color: var(--text-muted); margin-bottom: 12px; }
.card-features { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 15px; }
.feature-chip { background: #f1f5f9; color: #475569; font-size: 11px; padding: 3px 8px; border-radius: 4px; }
.card-footer { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.btn-compare { background: transparent; border: 1px dashed var(--primary); color: var(--primary); padding: 6px 12px; border-radius: 6px; font-size: 12px; cursor: pointer; font-weight: 600; }

/* MODAL PERBANDINGAN */
.modal-compare { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.6); z-index: 200; justify-content: center; align-items: center; }
.modal-content { background: white; padding: 30px; border-radius: 16px; max-width: 800px; width: 90%; max-height: 80vh; overflow-y: auto; }
.modal-header { display: flex; justify-content: space-between; margin-bottom: 20px; }
.close-modal { cursor: pointer; font-size: 24px; font-weight: bold; }
.compare-table { width: 100%; border-collapse: collapse; }
.compare-table th, .compare-table td { border: 1px solid var(--border); padding: 12px; text-align: left; font-size: 14px; }
.compare-table th { background: var(--bg-light); }

/* FORM AUTH (login.html) - sebelumnya tidak ada style khusus, ditambahkan agar rapi */
.auth-card { max-width: 380px; margin: 80px auto; background: var(--surface); padding: 30px; border-radius: 16px; box-shadow: 0 20px 25px -5px rgba(0,0,0,0.1); text-align: center; }
.auth-card h2 { margin-bottom: 20px; }
.auth-card form { display: flex; flex-direction: column; gap: 12px; }
.auth-card input { border: 1px solid var(--border); border-radius: 8px; padding: 10px; font-size: 14px; outline: none; }
.auth-card button[type="submit"] { background: var(--primary); color: white; border: none; padding: 12px; border-radius: 8px; font-weight: 600; cursor: pointer; margin-top: 6px; }
.auth-card button[type="submit"]:disabled { opacity: 0.6; cursor: not-allowed; }
.auth-card p { margin-top: 14px; font-size: 13px; }
.auth-card a { color: var(--primary); }
