/* =========================================
   1. PENGATURAN WARNA OTOMATIS (ROOT)
   ========================================= */
:root {
  /* --- UBAH WARNA DI SINI --- */

  /* Warna Utama (Merah/Pink): Digunakan untuk tombol, harga, logo, dan hover */
  --primary-color: #ff4757;

  /* Warna Kedua (Dark Blue/Grey): Digunakan untuk Footer dan Judul yang tebal */
  --secondary-color: #2f3542;

  /* Warna Aksen (Hijau): Digunakan untuk Profil dan ikon kontak */
  --accent-green: #27ae60;

  /* Warna Latar Belakang Halaman */
  --bg-color: #f9f9f9;
  --bg-secondary: #f4f4f4;

  /* Warna Teks */
  --text-dark: #333333;
  --text-grey: #57606f;
  --text-light-grey: #999999;

  /* Warna Elemen Lain */
  --white: #ffffff;
  --border-color: #dddddd;
  --shadow-color: rgba(0, 0, 0, 0.05);
}

/* =========================================
   2. RESET & GLOBAL
   ========================================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", "Segoe UI", sans-serif; /* Menggabungkan font */
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-color);
}

/* =========================================
   3. NAVBAR
   ========================================= */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 7%;
  background: var(--white);
  box-shadow: 0 2px 15px var(--shadow-color);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.logo {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--secondary-color);
}

.logo span {
  color: var(--primary-color);
}

.search-bar {
  display: flex;
  flex: 0.5;
  background: #f1f2f6;
  border-radius: 50px;
  padding: 5px 15px;
}

.search-bar input {
  width: 100%;
  background: transparent;
  border: none;
  outline: none;
  padding: 8px;
}

.search-bar button {
  background: transparent;
  border: none;
  color: #747d8c;
  cursor: pointer;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 30px;
  align-items: center;
}

.nav-links a {
  text-decoration: none;
  color: var(--secondary-color);
  font-weight: 500;
  transition: 0.3s;
}

.nav-links a.active,
.nav-links a:hover {
  color: var(--primary-color);
}

.badge {
  background: var(--primary-color);
  color: var(--white);
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 50%;
  position: relative;
  top: -10px;
  left: -8px;
}

/* =========================================
   4. HERO SECTION
   ========================================= */
.hero {
  height: 80vh;
  display: flex;
  align-items: center;
  background: var(--white);
  padding: 0 7%;
}

.hero-content {
  flex: 1;
}
.hero-content h1 {
  font-size: 3.5rem;
  line-height: 1.2;
  margin: 15px 0;
  color: var(--secondary-color);
}

.hero-content h1 span {
  color: var(--primary-color);
}
.hero-content p {
  color: var(--text-grey);
  margin-bottom: 30px;
  font-size: 1.1rem;
}

.btn-primary {
  background: var(--primary-color);
  color: var(--white);
  padding: 12px 30px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
}

.btn-secondary {
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
  margin-left: 15px;
  padding: 11px 30px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
}

.hero-image {
  flex: 1;
  text-align: right;
}
.hero-image img {
  width: 85%;
  border-radius: 20px;
  box-shadow: 20px 20px 0 var(--primary-color);
}

/* =========================================
   5. FEATURES & CONTENT
   ========================================= */
.features {
  display: flex;
  justify-content: space-around;
  padding: 40px 7%;
  background: var(--white);
  margin: 20px 7%;
  border-radius: 15px;
  box-shadow: 0 10px 30px var(--shadow-color);
}

.feature-item {
  text-align: center;
}
.feature-item i {
  font-size: 2rem;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.container {
  padding: 60px 7%;
}
.section-header {
  text-align: center;
  margin-bottom: 40px;
}
.section-title {
  font-size: 2rem;
  color: var(--secondary-color);
  margin-bottom: 30px;
  text-align: center;
}

/* =========================================
   6. PRODUK CARD
   ========================================= */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.product-card {
  background: var(--white);
  border-radius: 15px;
  overflow: hidden;
  transition: 0.4s;
  box-shadow: 0 4px 15px var(--shadow-color);
}

.product-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.product-image {
  height: 300px;
  position: relative;
  background: #eee;
}
.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tag {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--primary-color);
  color: var(--white);
  padding: 5px 10px;
  font-size: 12px;
  border-radius: 3px;
}

.product-info {
  padding: 20px;
  text-align: center;
}
.product-info h3 {
  font-size: 1.1rem;
  margin-bottom: 10px;
  color: #444;
}

.price {
  color: var(--primary-color);
  font-weight: bold;
  margin-bottom: 15px;
}

.price span {
  color: var(--text-light-grey);
  text-decoration: line-through;
  font-weight: normal;
  font-size: 0.9rem;
  margin-left: 10px;
}

.btn-add {
  width: 100%;
  padding: 10px;
  background: transparent;
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
  font-weight: bold;
  cursor: pointer;
  border-radius: 5px;
  transition: 0.3s;
  margin-top: 15px;
}

.btn-add:hover {
  background: var(--primary-color);
  color: var(--white);
}

/* =========================================
   7. FOOTER
   ========================================= */
.footer {
  background: var(--secondary-color);
  color: var(--white);
  padding: 60px 7% 20px;
  text-align: center;
  margin-top: 50px;
}

.newsletter h3 {
  margin-bottom: 20px;
}
.newsletter {
  text-align: center;
  margin-bottom: 40px;
}

.subscribe-box {
  display: flex;
  justify-content: center;
  max-width: 500px;
  margin: 20px auto 0;
}

.subscribe-box input {
  flex: 1;
  padding: 12px;
  width: 300px;
  border-radius: 5px 0 0 5px;
  border: none;
}

.subscribe-box button {
  padding: 12px 25px;
  background: var(--primary-color);
  color: var(--white);
  border: none;
  border-radius: 0 5px 5px 0;
  cursor: pointer;
}

.footer-bottom {
  border-top: 1px solid var(--text-grey);
  padding-top: 20px;
  text-align: center;
  font-size: 14px;
}

/* =========================================
   8. HALAMAN PROFIL
   ========================================= */
.profile-card {
  background: var(--white);
  max-width: 600px;
  margin: 50px auto;
  padding: 30px;
  border-radius: 15px;
  box-shadow: 0 10px 25px var(--shadow-color);
  text-align: center;
}

.profile-img {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  border: 5px solid var(--accent-green);
  margin-bottom: 20px;
}

.profile-header h2 {
  color: var(--secondary-color);
  margin-bottom: 5px;
}
.role {
  color: var(--accent-green);
  font-weight: bold;
  margin-bottom: 20px;
}

.profile-body {
  text-align: left;
  color: #555;
  line-height: 1.6;
}
.profile-body h3 {
  margin: 20px 0 10px 0;
  color: var(--secondary-color);
  border-bottom: 2px solid var(--bg-secondary);
  padding-bottom: 5px;
}

.contact-info ul {
  list-style: none;
  padding: 0;
}
.contact-info li {
  margin-bottom: 10px;
}
.contact-info i {
  color: var(--accent-green);
  width: 25px;
}

.social-media {
  text-align: center;
  margin-top: 30px;
}
.social-media a {
  font-size: 24px;
  color: var(--secondary-color);
  margin: 0 10px;
  transition: 0.3s;
}
.social-media a:hover {
  color: var(--accent-green);
}

/* =========================================
   9. KERANJANG (CART)
   ========================================= */
.cart-container {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  margin-top: 20px;
}

.cart-items {
  flex: 3;
  background: var(--white);
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 5px 15px var(--shadow-color);
}

.cart-items table {
  width: 100%;
  border-collapse: collapse;
}

.cart-items th {
  text-align: left;
  padding: 10px;
  color: var(--white);
  background: var(--primary-color);
  border-radius: 5px;
}

.cart-items td {
  padding: 20px 10px;
  border-bottom: 1px solid #eee;
}

.cart-info {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  align-items: center;
}
.cart-info img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 5px;
}
.cart-info p {
  font-weight: bold;
  margin-bottom: 5px;
}

.remove-link {
  color: var(--primary-color);
  font-size: 12px;
}
.cart-items input {
  width: 50px;
  padding: 5px;
  border: 1px solid #ccc;
  border-radius: 5px;
}

.cart-summary {
  flex: 1;
  background: var(--white);
  padding: 25px;
  border-radius: 10px;
  height: fit-content;
  box-shadow: 0 5px 15px var(--shadow-color);
}

.cart-summary h3 {
  margin-bottom: 20px;
  color: var(--secondary-color);
}
.summary-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 15px;
  font-size: 14px;
  color: #555;
}
.summary-item.total {
  font-size: 18px;
  font-weight: bold;
  color: var(--primary-color);
  margin-top: 10px;
}

.btn-checkout {
  width: 100%;
  padding: 12px;
  background: var(--primary-color);
  color: var(--white);
  border: none;
  border-radius: 25px;
  cursor: pointer;
  font-weight: bold;
  margin-top: 15px;
  transition: 0.3s;
}

.btn-checkout:hover {
  background: #e84118;
} /* Anda bisa buat variabel gelap untuk ini jika mau */

/* =========================================
   10. LOGIN & DAFTAR (AUTH)
   ========================================= */
.auth-container {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 80vh;
  padding: 20px;
}

.auth-box {
  background: var(--white);
  padding: 40px;
  width: 100%;
  max-width: 400px;
  border-radius: 15px;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.auth-box h2 {
  color: var(--secondary-color);
  margin-bottom: 10px;
}
.auth-box p {
  color: #777;
  margin-bottom: 30px;
  font-size: 14px;
}

.input-group {
  position: relative;
  margin-bottom: 20px;
}

.input-group i {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--primary-color);
}

.input-group input {
  width: 100%;
  padding: 12px 12px 12px 40px;
  border: 1px solid var(--border-color);
  border-radius: 50px;
  outline: none;
  background: var(--bg-color);
}

.btn-login {
  width: 100%;
  padding: 12px;
  background: var(--secondary-color);
  color: var(--white);
  border: none;
  border-radius: 50px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.3s;
}

.btn-login:hover {
  background: var(--primary-color);
}

.auth-links {
  margin-top: 20px;
  display: flex;
  justify-content: space-between;
  font-size: 12px;
}
.auth-links a {
  text-decoration: none;
  color: #555;
}
.auth-links a:hover {
  color: var(--primary-color);
}

/* =========================================
   11. RESPONSIVE DESIGN (MEDIA QUERIES)
   ========================================= */
.menu-toggle {
  display: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--secondary-color);
}

@media (max-width: 768px) {
  .cart-container {
    flex-direction: column;
  }
  .cart-items {
    overflow-x: auto;
  }

  .navbar {
    padding: 1rem 5%;
    position: relative;
  }
  .search-bar {
    display: none;
  }
  .menu-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--white);
    box-shadow: 0 5px 10px var(--shadow-color);
    padding: 20px 0;
    text-align: center;
  }

  .nav-links.active {
    display: flex;
  }
  .nav-links li {
    margin: 15px 0;
  }

  .hero {
    flex-direction: column-reverse;
    height: auto;
    padding: 40px 5%;
    text-align: center;
  }
  .hero-content h1 {
    font-size: 2.5rem;
  }
  .hero-btns {
    display: flex;
    flex-direction: column;
    gap: 15px;
  }
  .btn-secondary {
    margin-left: 0;
  }

  .hero-image {
    width: 100%;
    text-align: center;
    margin-bottom: 30px;
  }
  .hero-image img {
    width: 100%;
    max-width: 350px;
  }

  .features {
    flex-direction: column;
    gap: 30px;
    margin: 20px 5%;
    padding: 30px;
  }
  .product-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
  }
  .product-image {
    height: 200px;
  }

  .profile-card {
    margin: 20px auto;
    padding: 20px;
    width: 90%;
  }
  .auth-container {
    height: auto;
    padding: 50px 20px;
  }

  .subscribe-box {
    flex-direction: column;
  }
  .subscribe-box input {
    width: 100%;
    border-radius: 5px;
    margin-bottom: 10px;
  }
  .subscribe-box button {
    width: 100%;
    border-radius: 5px;
  }
}

@media (max-width: 480px) {
  .hero-content h1 {
    font-size: 2rem;
  }
  .product-grid {
    grid-template-columns: 1fr;
  }
}
