:root {
  --green: #2EC4B6;
  --gold: #FFBE0B;
  --muted: #6b7280;
  --bg: #f9fafa;
}

body {
  font-family: 'Open Sans', sans-serif;
  background: var(--bg);
  color: #333;
  margin: 0;
  overflow-x: hidden;
}

header {
  position: sticky;
  top: 0;
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(10px);
  padding: 10px 5%;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

header .logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  color: var(--green);
}
header .logo img {
  width: 36px;
  height: 36px;
}

nav a {
  margin: 0 10px;
  color: #333;
  text-decoration: none;
  font-weight: 500;
}
nav a:hover {
  color: var(--green);
}
.toggle-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
  color: var(--muted);
}

.hero {
  position: relative;
  height: 420px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.hero .overlay {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(46,196,182,0.45);
}
.hero-content {
  position: relative;
  z-index: 2;
  color: white;
}
.hero h1 {
  font-size: 42px;
  margin: 0;
}
.hero p {
  font-size: 16px;
  margin-bottom: 20px;
}
.btn-primary {
  background: var(--gold);
  color: #fff;
  padding: 10px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
}

.cards {
  padding: 60px 5%;
  text-align: center;
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(260px,1fr));
  gap: 20px;
  margin-top: 20px;
}
.card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  overflow: hidden;
  transition: transform 0.2s ease;
}
.card:hover { transform: translateY(-5px); }
.card img { width: 100%; height: 180px; object-fit: cover; }
.card h3 { font-size: 18px; margin: 10px; }
.card p { font-size: 14px; color: var(--muted); margin: 0 10px 10px; }
.read-more {
  display: inline-block;
  margin: 0 0 15px;
  color: var(--green);
  font-weight: 600;
  text-decoration: none;
}
footer {
  background: #111;
  color: #ccc;
  padding: 20px 10px;
  text-align: center;
  font-size: 13px;
}

/* Dark mode */
body.dark-mode {
  background: #121212;
  color: #ddd;
}
body.dark-mode header {
  background: rgba(20,20,20,0.9);
}
body.dark-mode .card {
  background: #1e1e1e;
  color: #ddd;
}
body.dark-mode footer {
  background: #000;
  color: #aaa;
}

/* CSS detail artikel */
.article-detail {
  max-width: 800px;
  margin: 50px auto;
  text-align: left;
}

.article-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.article-meta {
  color: #777;
  margin-bottom: 20px;
}

.article-main-image {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  border-radius: 10px;
  margin: 20px 0;
  border: 1px solid #ddd;
}

.article-content {
  font-size: 1.1rem;
  line-height: 1.7;
  margin-top: 20px;
}

.back-home {
  display: inline-block;
  margin-top: 25px;
  color: #007bff;
  font-weight: bold;
  text-decoration: none;
}

/* BASE LAYOUT */
body {
    font-family: "Source Sans Pro", sans-serif;
    background: #fafafa;
    margin: 0;
    padding: 0;
}

/* HEADER DISESUAIKAN DENGAN LANDING */
/* header {
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(10px);
    padding: 12px 5%;
    border-bottom: 1px solid #e5e5e5;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 10;
} */

/* HEADER KONSISTEN DENGAN LANDING */
header {
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(10px);
    padding: 12px 5%;      /* ruang kiri-kanan */
    border-bottom: 1px solid #e5e5e5;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 10;
}

/* FLEXBOX: LOGO DI KIRI — TOMBOL KEMBALI DIPAKSA KE KANAN */
header .container {
    display: flex;
    justify-content: space-between; 
    align-items: center;
    width: 100%;
}

header .logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

header .logo img {
    height: 40px;
}

header .logo span {
    font-size: 20px;
    font-weight: 700;
    color: #2EC4B6;
}

/* TOMBOL KEMBALI LEBIH KECIL & TEPAT DI SEBELAH KANAN */
.btn-back {
    margin-left: auto;   /* memastikan tombol menempel ke sisi kanan */
    font-size: 13px;
    padding: 5px 12px;
    border-radius: 5px;
    border: 1px solid #aaa;
    background: #f7f7f7;
    color: #333;
    text-decoration: none;
    transition: 0.2s;
    white-space: nowrap;
}

.btn-back:hover {
    background: #e2e2e2;
    border-color: #888;
}

/* ARTICLE DETAIL CONTENT */
.article-detail {
    max-width: 850px;
    margin: 40px auto;
    background: #fff;
    padding: 25px 30px;
    border-radius: 12px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.06);
}

.article-title {
    font-size: 32px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 10px;
    line-height: 1.3;
}

.article-meta {
    color: #777;
    font-size: 14px;
    margin-bottom: 20px;
}

.article-main-image {
    width: 100%;
    max-height: 430px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 25px;
    border: 1px solid #ddd;
}

.article-content {
    font-size: 18px;
    color: #333;
    line-height: 1.7;
}

.article-content img {
    max-width: 100%;
    border-radius: 10px;
    margin: 20px 0;
}

/* LINK KEMBALI KE BERANDA */
.back-home {
    display: inline-block;
    margin-top: 40px;
    text-decoration: none;
    font-size: 16px;
    color: #004aad;
}

.back-home:hover {
    text-decoration: underline;
}

footer {
    text-align: center;
    padding: 20px 0;
    margin-top: 40px;
    color: #666;
    font-size: 14px;
}