/* --- VARIABEL & GAYA GLOBAL --- */
:root {
  --primary-color: #3a5a40; /* Hijau Tua */
  --secondary-color: #a3b18a; /* Hijau Muda */
  --accent-color: #dad7cd; /* Krem */
  --light-color: #f8f9fa; /* Warna background terang */
  --dark-color: #343a40; /* Warna teks gelap */
  --white-color: #ffffff;
  --font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-family);
  line-height: 1.6;
  background-color: var(--light-color);
  color: var(--dark-color);
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

h1,
h2,
h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
}

p {
  margin-bottom: 1rem;
}

a {
  text-decoration: none;
  color: var(--primary-color);
}

ul {
  list-style: none;
}

.text-center {
  text-align: center;
}

/* --- HEADER & NAVIGASI --- */
.main-header {
  background-color: var(--white-color);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.main-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary-color);
}

.main-nav ul {
  display: flex;
}

.main-nav a {
  padding: 0.5rem 1rem;
  color: var(--dark-color);
  font-weight: 500;
  transition: color 0.3s ease;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--primary-color);
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--primary-color);
  cursor: pointer;
}

/* --- MAIN CONTENT & SECTIONS --- */
main {
  padding: 2rem 0;
  min-height: 80vh;
}

.page-section {
  display: none; /* Sembunyikan semua section secara default */
}

.page-section.active {
  display: block; /* Tampilkan section yang aktif */
}

.subtitle {
  font-size: 1.2rem;
  color: var(--secondary-color);
}

.description {
  max-width: 800px;
  margin: 1rem auto 2rem;
}

/* --- BERANDA STYLES --- */
.icon-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin: 3rem 0;
  justify-items: center;
}

.icon-item {
  background: var(--white-color);
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  width: 500px;
  display: block;
}

.icon-item i {
  font-size: 3rem;
  color: var(--secondary-color);
  margin-bottom: 1rem;
}

.cta-buttons {
  margin-top: 2rem;
  text-align: center;
}

.cta-buttons .btn {
  margin: 0.5rem;
}

/* --- KATALOG PRODUK STYLES --- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.product-card {
  background: var(--white-color);
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.product-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.card-content {
  padding: 1.5rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.card-content h3 {
  margin-top: 0;
}

.specs ul {
  padding-left: 20px;
  list-style-type: disc;
  color: var(--secondary-color);
}

.specs ul li {
  margin-bottom: 0.5rem;
}

.specs ul li strong {
  color: var(--dark-color);
}

.add-to-cart {
  margin-top: auto; /* Dorong tombol ke bawah */
}

/* --- KERANJANG STYLES --- */
#cart-items-container {
  background: var(--accent-color);
  padding: 1.5rem;
  border-radius: 8px;
  margin-bottom: 2rem;
}

.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--white-color);
  padding: 1rem;
  border-bottom: 1px solid #ddd;
}

.cart-item:last-child {
  border-bottom: none;
}

.cart-item-details {
  flex-grow: 1;
}

.cart-item-actions button {
  background: none;
  border: none;
  color: #dc3545;
  cursor: pointer;
  margin-left: 10px;
}

.cart-summary {
  background: var(--white-color);
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

/* --- BERITA STYLES --- */
.news-list {
  margin-top: 2rem;
}

.news-item {
  background: var(--white-color);
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  margin-bottom: 1.5rem;
}

.news-meta {
  font-size: 0.9rem;
  color: #6c757d;
  margin-bottom: 1rem;
}

.news-full-content {
  display: none; /* Sembunyikan konten penuh secara default */
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
}

/* --- BUTTON STYLES --- */
.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 5px;
  font-size: 1rem;
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background-color: var(--primary-color);
  color: var(--white-color);
}

.btn-primary:hover {
  background-color: #2c4533;
}

.btn-secondary {
  background-color: var(--secondary-color);
  color: var(--white-color);
  display: block;
  margin: 0 auto;
  width: 300px;
}

.btn-secondary:hover {
  background-color: #8b9c73;
}

.btn-success {
  background-color: #28a745;
  color: var(--white-color);
}

.btn-success:hover {
  background-color: #218838;
}

.btn-link {
  background: none;
  color: var(--primary-color);
}
