/* ====== FONT GOOGLE ====== */
@import url("https://fonts.googleapis.com/css2?family=Ibarra+Real+Nova:wght@400;500;600;700&family=Poppins:wght@400;500;600;700;800&display=swap");

/* ====== WARNA DAN PENGATURAN GLOBAL ====== */
:root {
  --brand-color: #512810;
  --button-color: #a86a2d;
  --button-hover: #8b5522;
  --background-start: #fef5d7;
  --background-end: #f0dabc;
  --surface: #ffffff;
}

/* ====== RESET STYLE ====== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  font-family: "Poppins", sans-serif;
  color: var(--brand-color);
  background: linear-gradient(
    90deg,
    var(--background-start) 0%,
    var(--background-end) 100%
  );
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  border: none;
  background: none;
  font: inherit;
  cursor: pointer;
}

.container {
  width: 100%;
  margin: 0;
}

/* ====== HEADER SECTION ====== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  width: 100%;
  background: #ffffff;
}

.site-header .container.header-inner {
  width: 100%;
  max-width: none;
  height: 127px;
  margin: 0;
  padding: 0 60px;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

/* ====== LOGO KIRI ====== */
.brand-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.brand-logo img {
  width: 120px;
  height: auto;
}

/* ====== NAVIGASI UTAMA ====== */
.site-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
}

.nav-list {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 34px;
}

/* Posisi menu dibuat sama seperti Home GW Gessang */
.nav-list li:nth-child(1) {
  transform: translateX(-125px);
}

.nav-list li:nth-child(2) {
  transform: translateX(-75px);
}

.nav-list li:nth-child(3) {
  transform: translateX(-25px);
}

.nav-list li:nth-child(4) {
  transform: translateX(25px);
}

.nav-list li:nth-child(5) {
  transform: translateX(75px);
}

.nav-list li:nth-child(6) {
  transform: translateX(125px);
}

.nav-list a {
  position: relative;
  color: var(--brand-color);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.25;
  text-transform: uppercase;
  white-space: nowrap;
  transition: color 0.3s ease;
}

/* Garis bawah saat menu disentuh mouse */
.nav-list a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -9px;
  width: 0;
  height: 1px;
  background: var(--brand-color);
  transition: width 0.3s ease;
}

.nav-list a:hover,
.nav-list a:focus-visible {
  color: var(--button-color);
}

.nav-list a:hover::after {
  width: 100%;
}

/* Menu Personal Colour dibuat dua baris */
.nav-list li:nth-child(3) a {
  display: block;
  width: 240px;
  text-align: center;
  white-space: normal;
}

.nav-list li:nth-child(3) a::after {
  left: 50%;
  transform: translateX(-50%);
}

.nav-list li:nth-child(3) a:hover::after {
  width: 90%;
}

/* Menu aktif */
.nav-list a.active {
  color: var(--brand-color);
  font-weight: 800;
}

.nav-list a.active::after {
  width: 100%;
}

/* ====== ICON KANAN HEADER ====== */
.header-actions {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-shrink: 0;
}

.header-icons {
  display: flex;
  align-items: center;
  gap: 30px;
}

.header-icons a,
.search-btn,
.home-account-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: transparent;
  transition: transform 0.2s ease;
}

.header-icons a:hover,
.search-btn:hover,
.home-account-btn:hover {
  transform: translateY(-2px);
}

.header-icons img,
.home-account-btn img {
  width: 38px;
  height: 38px;
  object-fit: contain;
}

/* ====== BADGE ANGKA WISHLIST ====== */

.wishlist-link {
  position: relative;
}

.wishlist-count-badge {
  position: absolute;
  top: -8px;
  right: -9px;

  min-width: 20px;
  height: 20px;
  padding: 0 5px;

  display: flex;
  align-items: center;
  justify-content: center;

  background: #e84c3d;
  border: 2px solid #ffffff;
  border-radius: 100px;

  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;

  pointer-events: none;
}

.wishlist-count-badge:not(.is-hidden) {
  animation: shoppingWishlistBadgePop 0.3s ease;
}

@keyframes shoppingWishlistBadgePop {
  0% {
    transform: scale(0.5);
  }

  70% {
    transform: scale(1.2);
  }

  100% {
    transform: scale(1);
  }
}

/* ====== BADGE ANGKA KERANJANG ====== */

/* Posisi ikon keranjang */
.cart-link {
  position: relative;
}

/* Angka jumlah produk */
.cart-count-badge {
  position: absolute;
  top: -8px;
  right: -9px;

  min-width: 20px;
  height: 20px;
  padding: 0 5px;

  display: flex;
  align-items: center;
  justify-content: center;

  background: #e84c3d;
  border: 2px solid #ffffff;
  border-radius: 100px;

  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;

  pointer-events: none;
}

/* Animasi badge */
.cart-count-badge:not(.is-hidden) {
  animation: shoppingCartBadgePop 0.3s ease;
}

@keyframes shoppingCartBadgePop {
  0% {
    transform: scale(0.5);
  }

  70% {
    transform: scale(1.2);
  }

  100% {
    transform: scale(1);
  }
}

/* ====== TOMBOL HAMBURGER ====== */
.menu-toggle {
  display: none;
  width: 30px;
  height: 22px;
  flex-direction: column;
  justify-content: space-between;
}

.menu-toggle span {
  display: block;
  height: 3px;
  border-radius: 999px;
  background: var(--brand-color);
}

/* ====== KOTAK PENCARIAN ====== */
.search-box {
  position: fixed;
  top: 105px;
  right: 70px;
  z-index: 999;

  display: none;
  align-items: center;
  gap: 12px;

  width: 360px;
  height: 54px;
  padding: 0 18px;

  background: #ffffff;
  border: 2px solid var(--brand-color);
  border-radius: 100px;
}

.search-box.active {
  display: flex;
}

.search-box input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  font-family: "Poppins", sans-serif;
  font-size: 15px;
  color: var(--brand-color);
}

.search-box button {
  font-size: 28px;
  color: var(--brand-color);
}

/* ====== DROPDOWN AKUN ====== */
.home-account-dropdown {
  position: fixed;
  top: 145px;
  right: 48px;
  z-index: 1100;

  display: none;
  width: 375px;
  padding: 34px 25px 32px;

  background: #ffffff;
  border-radius: 24px;
  box-shadow:
    7px 8px 0 rgba(255, 238, 191, 0.65),
    0 12px 30px rgba(81, 40, 16, 0.08);
}

.home-account-dropdown.active {
  display: block;
}

/* ====== NAMA AKUN ATAU LOGIN / SIGN UP ====== */
.home-account-user {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 19px;
  color: var(--brand-color);
}

.home-account-user img {
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  object-fit: contain;
}

.home-account-user-data {
  min-width: 0;
}

.home-account-user strong {
  color: var(--brand-color);
  font-size: 23px;
  font-weight: 800;
  line-height: 1.2;
}

.home-account-user-data p {
  margin: 2px 0 0;
  color: var(--brand-color);
  font-size: 16px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.home-account-user:hover strong {
  color: var(--button-color);
}

/* ====== MENU DI DALAM DROPDOWN AKUN ====== */
.home-account-menu {
  width: 100%;
  min-height: 56px;

  display: flex;
  align-items: center;
  gap: 18px;

  color: var(--brand-color);
  font-size: 23px;
  font-weight: 500;
  transition: color 0.3s ease;
}

.home-account-menu:hover {
  color: var(--button-color);
}

.home-account-menu img {
  width: 31px;
  height: 31px;
  flex-shrink: 0;
  object-fit: contain;
}

button.home-account-menu {
  border: none;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.is-hidden {
  display: none !important;
}

/* ====== ISI HALAMAN KOSONG ====== */
.page-content {
  min-height: calc(100vh - 127px);
  background: linear-gradient(
    90deg,
    var(--background-start) 0%,
    var(--background-end) 100%
  );
}

/* ====== RESPONSIVE LAPTOP ====== */
@media (max-width: 1350px) {
  .site-header .container.header-inner {
    position: relative;
    height: 95px;
    padding: 0 48px;
  }

  .brand-logo img {
    width: 90px;
  }

  /* Menu desktop disembunyikan */
  .site-nav {
    display: none;
  }

  /* Menu tampil setelah hamburger diklik */
  .site-nav.is-open {
    position: absolute;
    top: 95px;
    right: 48px;
    left: auto;
    z-index: 999;

    display: flex;
    width: auto;
    padding: 18px 26px;

    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 12px 30px rgba(81, 40, 16, 0.18);
  }

  .site-nav.is-open .nav-list {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
  }

  /* Posisi menu desktop dikembalikan normal */
  .site-nav.is-open .nav-list li:nth-child(1),
  .site-nav.is-open .nav-list li:nth-child(2),
  .site-nav.is-open .nav-list li:nth-child(3),
  .site-nav.is-open .nav-list li:nth-child(4),
  .site-nav.is-open .nav-list li:nth-child(5),
  .site-nav.is-open .nav-list li:nth-child(6) {
    transform: none;
  }

  .site-nav.is-open .nav-list a {
    display: block;
    width: auto;
    padding: 0;
    background: transparent;
    color: var(--brand-color);
    font-size: 16px;
    font-weight: 400;
    text-align: center;
    white-space: nowrap;
  }

  .site-nav.is-open .nav-list li:nth-child(3) a {
    width: 230px;
    line-height: 1.3;
    white-space: normal;
  }

  .site-nav.is-open .nav-list a.active {
    font-weight: 800;
  }

  .menu-toggle {
    display: flex;
  }

  .header-icons {
    gap: 18px;
  }

  .header-icons img,
  .home-account-btn img {
    width: 28px;
    height: 28px;
  }

  .home-account-dropdown {
    top: 112px;
    right: 48px;
    width: 390px;
    padding: 36px 28px 34px;
  }

  .home-account-user img {
    width: 48px;
    height: 48px;
  }

  .home-account-user strong {
    font-size: 24px;
  }

  .home-account-menu {
    min-height: 60px;
    font-size: 23px;
  }

  .page-content {
    min-height: calc(100vh - 95px);
  }
}

/* ====== RESPONSIVE TABLET ====== */
@media (max-width: 900px) {
  .site-header .container.header-inner {
    height: 92px;
    padding: 0 24px;
    gap: 15px;
  }

  .brand-logo img {
    width: 78px;
  }

  .site-nav.is-open {
    top: 92px;
    left: 20px;
    right: 20px;
    width: auto;
    padding: 20px;
    border-radius: 20px;
  }

  .site-nav.is-open .nav-list {
    align-items: stretch;
    justify-content: flex-start;
    gap: 10px;
  }

  .site-nav.is-open .nav-list a {
    width: 100%;
    padding: 12px 14px;
    background: var(--background-start);
    border-radius: 12px;
    font-size: 14px;
    text-align: center;
    white-space: normal;
  }

  .site-nav.is-open .nav-list li:nth-child(3) a {
    width: 100%;
  }

  .header-icons {
    gap: 12px;
  }

  .header-icons img,
  .home-account-btn img {
    width: 24px;
    height: 24px;
  }

  .home-account-dropdown {
    top: 108px;
    right: 24px;
    width: min(390px, calc(100% - 48px));
  }

  .page-content {
    min-height: calc(100vh - 92px);
  }
}

/* ====== RESPONSIVE MOBILE ====== */
@media (max-width: 520px) {
  .site-header .container.header-inner {
    height: 82px;
    padding: 0 15px;
    gap: 8px;
  }

  .brand-logo img {
    width: 66px;
  }

  .site-nav.is-open {
    top: 82px;
    left: 12px;
    right: 12px;
    padding: 15px;
  }

  .site-nav.is-open .nav-list {
    gap: 8px;
  }

  .site-nav.is-open .nav-list a {
    padding: 10px 12px;
    font-size: 12px;
  }

  .header-icons {
    gap: 10px;
  }

  .header-icons img,
  .home-account-btn img {
    width: 22px;
    height: 22px;
  }

  .menu-toggle {
    width: 27px;
    height: 20px;
  }

  .search-box {
    top: 92px;
    left: 15px;
    right: 15px;
    width: auto;
  }

  .home-account-dropdown {
    top: 95px;
    right: 15px;
    left: 15px;
    width: auto;
    padding: 28px 22px 26px;
  }

  .home-account-user {
    gap: 12px;
    margin-bottom: 16px;
  }

  .home-account-user img {
    width: 44px;
    height: 44px;
  }

  .home-account-user strong {
    font-size: 21px;
  }

  .home-account-menu {
    min-height: 55px;
    gap: 16px;
    font-size: 20px;
  }

  .home-account-menu img {
    width: 28px;
    height: 28px;
  }

  .page-content {
    min-height: calc(100vh - 82px);
  }
}

/* ====== HALAMAN SHOPPING CART ====== */
.shopping-cart-section {
  width: 100%;
  min-height: calc(100vh - 127px);
  padding: 55px 80px 85px;
}

.shopping-cart-title {
  margin-bottom: 55px;
  color: var(--brand-color);
  font-size: 34px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
}

/* ====== KOTAK UTAMA KERANJANG ====== */
.shopping-cart-card {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  overflow: hidden;

  background: var(--surface);
  border-radius: 38px;
}

/* ====== HEADER TABEL KERANJANG ====== */
.cart-header {
  min-height: 130px;
  display: grid;
  grid-template-columns: 2.2fr 0.85fr 1fr 0.55fr;
  align-items: center;

  padding: 0 58px;
  border-bottom: 1px solid var(--brand-color);

  color: var(--brand-color);
  font-size: 22px;
  font-weight: 800;
}

.cart-header div:nth-child(2),
.cart-header div:nth-child(3),
.cart-header div:nth-child(4) {
  text-align: center;
}

/* ====== BARIS PRODUK ====== */
.cart-item {
  min-height: 300px;
  display: grid;
  grid-template-columns: 2.2fr 0.85fr 1fr 0.55fr;
  align-items: center;

  padding: 45px 58px;
  border-bottom: 1px solid var(--brand-color);
}

/* ====== INFORMASI PRODUK ====== */
.cart-product {
  display: flex;
  align-items: center;
  gap: 28px;
}

.cart-product-image {
  width: 170px;
  height: 215px;
  flex-shrink: 0;

  object-fit: cover;
  border-radius: 28px;
}

.cart-product-info {
  min-width: 0;
}

.cart-product-info h2 {
  margin-bottom: 24px;

  color: var(--brand-color);
  font-size: 19px;
  font-weight: 700;
  line-height: 1.5;
}

.cart-product-detail {
  display: flex;
  align-items: center;
  gap: 65px;
  margin-bottom: 28px;

  color: var(--brand-color);
  font-size: 17px;
  font-weight: 400;
}

.cart-product-info p {
  color: var(--brand-color);
  font-size: 17px;
  font-weight: 400;
}

/* ====== JUMLAH PRODUK ====== */
.cart-quantity {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 25px;
}

.quantity-btn {
  width: 47px;
  height: 47px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  background: var(--button-color);
  border-radius: 9px;

  color: #ffffff;
  font-size: 28px;
  font-weight: 500;
  line-height: 1;

  transition:
    background 0.3s ease,
    transform 0.2s ease;
}

.quantity-btn:hover {
  background: var(--button-hover);
  transform: translateY(-2px);
}

.plus-btn {
  border-radius: 50%;
}

.quantity-number {
  min-width: 18px;

  color: var(--brand-color);
  font-size: 20px;
  font-weight: 500;
  text-align: center;
}

/* ====== SUBTOTAL PRODUK ====== */
.cart-item-subtotal {
  color: var(--brand-color);
  font-size: 27px;
  font-weight: 400;
  text-align: center;
  white-space: nowrap;
}

/* ====== TOMBOL HAPUS PRODUK ====== */
.cart-action {
  display: flex;
  align-items: center;
  justify-content: center;
}

.delete-item-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  transition: transform 0.2s ease;
}

.delete-item-btn:hover {
  transform: translateY(-2px);
}

.delete-item-btn svg {
  width: 37px;
  height: 37px;
  fill: var(--brand-color);
}

/* ====== BAGIAN BAWAH KERANJANG ====== */
.cart-footer {
  min-height: 270px;
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  align-items: start;
  gap: 60px;

  padding: 55px 58px 65px;
}

/* ====== TOMBOL DELETE ALL ====== */
.delete-all-btn {
  width: fit-content;
  min-height: 66px;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;

  padding: 0 14px;

  border: 3px solid var(--button-color);
  border-radius: 9px;

  color: var(--brand-color);
  font-size: 24px;
  font-weight: 800;

  transition:
    background 0.3s ease,
    color 0.3s ease;
}

.delete-all-btn:hover {
  background: var(--brand-color);
  color: #ffffff;
}

.delete-all-btn svg {
  width: 38px;
  height: 38px;
  fill: currentColor;
}

/* ====== RINGKASAN KERANJANG ====== */
.cart-summary {
  width: 100%;
  padding-top: 40px;
}

.cart-summary-text {
  display: flex;
  align-items: center;
  justify-content: space-between;

  margin-bottom: 8px;

  color: var(--brand-color);
  font-size: 17px;
  font-weight: 700;
}

.checkout-btn {
  width: 100%;
  min-height: 65px;

  display: flex;
  align-items: center;
  justify-content: center;

  background: var(--button-color);
  border-radius: 8px;

  color: #ffffff;
  font-size: 23px;
  font-weight: 700;

  transition:
    background 0.3s ease,
    transform 0.2s ease;
}

.checkout-btn:hover {
  background: var(--button-hover);
  transform: translateY(-2px);
}

/* ====== RESPONSIVE SHOPPING CART LAPTOP ====== */
@media (max-width: 1350px) {
  .shopping-cart-section {
    min-height: calc(100vh - 95px);
    padding: 50px 45px 70px;
  }

  .shopping-cart-card {
    border-radius: 32px;
  }

  .cart-header,
  .cart-item {
    grid-template-columns: 2fr 0.8fr 1fr 0.5fr;
    padding-left: 40px;
    padding-right: 40px;
  }

  .cart-product-image {
    width: 145px;
    height: 190px;
  }

  .cart-product {
    gap: 22px;
  }

  .cart-product-detail {
    gap: 35px;
  }

  .cart-item-subtotal {
    font-size: 23px;
  }

  .cart-footer {
    padding-left: 40px;
    padding-right: 40px;
  }
}

/* ====== RESPONSIVE SHOPPING CART TABLET ====== */
@media (max-width: 900px) {
  .shopping-cart-section {
    min-height: calc(100vh - 92px);
    padding: 40px 24px 60px;
  }

  .shopping-cart-title {
    margin-bottom: 35px;
    font-size: 29px;
  }

  .shopping-cart-card {
    overflow: visible;
    background: transparent;
    border-radius: 0;
  }

  .cart-header {
    display: none;
  }

  .cart-item {
    position: relative;

    min-height: auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 28px;

    margin-bottom: 25px;
    padding: 28px;

    background: #ffffff;
    border: none;
    border-radius: 25px;
  }

  .cart-product {
    padding-right: 45px;
  }

  .cart-quantity {
    justify-content: flex-start;
  }

  .cart-item-subtotal {
    text-align: left;
  }

  .cart-action {
    position: absolute;
    top: 30px;
    right: 28px;
  }

  .cart-footer {
    min-height: auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 25px;

    padding: 28px;

    background: #ffffff;
    border-radius: 25px;
  }

  .cart-summary {
    padding-top: 0;
  }
}

/* ====== RESPONSIVE SHOPPING CART MOBILE ====== */
@media (max-width: 520px) {
  .shopping-cart-section {
    min-height: calc(100vh - 82px);
    padding: 32px 15px 50px;
  }

  .shopping-cart-title {
    margin-bottom: 28px;
    font-size: 25px;
  }

  .cart-item {
    padding: 22px 18px;
  }

  .cart-product {
    align-items: flex-start;
    gap: 16px;
    padding-right: 35px;
  }

  .cart-product-image {
    width: 105px;
    height: 140px;
    border-radius: 18px;
  }

  .cart-product-info h2 {
    margin-bottom: 15px;
    font-size: 14px;
    line-height: 1.5;
  }

  .cart-product-detail {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    margin-bottom: 15px;
    font-size: 13px;
  }

  .cart-product-info p {
    font-size: 13px;
  }

  .cart-quantity {
    gap: 18px;
  }

  .quantity-btn {
    width: 42px;
    height: 42px;
    font-size: 25px;
  }

  .quantity-number {
    font-size: 18px;
  }

  .cart-item-subtotal {
    font-size: 21px;
  }

  .delete-item-btn svg {
    width: 30px;
    height: 30px;
  }

  .cart-action {
    top: 23px;
    right: 18px;
  }

  .cart-footer {
    padding: 22px 18px;
  }

  .delete-all-btn {
    width: 100%;
    min-height: 58px;
    font-size: 20px;
  }

  .delete-all-btn svg {
    width: 32px;
    height: 32px;
  }

  .cart-summary-text {
    gap: 15px;
    font-size: 13px;
  }

  .checkout-btn {
    min-height: 58px;
    font-size: 19px;
  }
}

/* ====== PILIH PRODUK CART ====== */

.cart-products-heading {
  display: flex;
  align-items: center;
  gap: 15px;
}

.cart-select {
  position: relative;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  flex-shrink: 0;
  cursor: pointer;
}

.cart-select input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.cart-checkmark {
  width: 25px;
  height: 25px;

  display: flex;
  align-items: center;
  justify-content: center;

  border: 2px solid var(--button-color);
  border-radius: 6px;

  background: #ffffff;

  transition:
    background 0.2s ease,
    transform 0.2s ease;
}

.cart-select input:checked + .cart-checkmark {
  background: var(--button-color);
}

.cart-select input:checked + .cart-checkmark::after {
  content: "✓";

  color: #ffffff;
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
}

.cart-item-select {
  margin-right: -10px;
}