
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #fff5fa;
  color: #594958;
  font-family: Arial, sans-serif;
}

/* 상단 헤더 */
.header {
  background: #f7d5e7;
  padding: 20px;
}

.header-inner {
  max-width: 1100px;
  margin: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo h1 {
  color: #a65e89;
  margin: 0;
  font-size: 32px;
}

.logo p {
  margin-bottom: 0;
  color: #8d6a80;
}

button {
  border: none;
  border-radius: 10px;
  padding: 11px 16px;
  background: #d994b9;
  color: white;
  cursor: pointer;
  font-size: 14px;
}

button:hover {
  background: #bd76a0;
}

.cart-button {
  font-weight: bold;
  font-size: 15px;
}

.cart-button span {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-width: 23px;
  height: 23px;
  margin-left: 5px;
  background: white;
  color: #a65e89;
  border-radius: 50%;
}

/* 전체 화면 */
main {
  max-width: 1100px;
  margin: 25px auto;
  padding: 0 18px;
}

section {
  background: white;
  border-radius: 18px;
  padding: 25px;
  margin-bottom: 25px;
  box-shadow: 0 4px 12px #eedce7;
}

h2 {
  color: #a65e89;
}

/* 메인 배너 */
.main-banner {
  text-align: center;
  background: linear-gradient(135deg, #fce4ef, #eee1fa);
  padding: 45px 20px;
}

.main-banner h2 {
  font-size: 27px;
}

.main-banner p {
  color: #886c82;
}

/* 필터 */
.filter-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.filter-grid label {
  display: block;
  margin-bottom: 8px;
  font-weight: bold;
  color: #936b85;
}

select,
input,
textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #e8cddd;
  border-radius: 9px;
  background: #fffafd;
  color: #594958;
}

select:focus,
input:focus,
textarea:focus {
  outline: 2px solid #e6b5d1;
}

/* 요약 영역 */
.summary-section {
  display: flex;
  justify-content: space-around;
  text-align: center;
  background: #fff0f7;
  flex-wrap: wrap;
  gap: 15px;
}

.summary-item p {
  color: #987b91;
}

.summary-item strong {
  font-size: 22px;
  color: #a65e89;
}

/* 상품 목록 */
.product-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.product-card {
  background: #fff8fc;
  border: 1px solid #f0dce9;
  border-radius: 15px;
  padding: 15px;
  text-align: center;
  transition: transform 0.2s;
}

.product-card:hover {
  transform: translateY(-4px);
}

.product-image {
  width: 100%;
  height: 190px;
  object-fit: cover;
  border-radius: 12px;
  background: #f5e5ef;
}

.product-card h3 {
  color: #a65e89;
}

.product-card p {
  font-size: 14px;
}

.product-price {
  font-size: 18px !important;
  font-weight: bold;
  color: #a65e89;
}

.product-card button {
  margin: 4px 2px;
}

.review-link {
  background: #bba4d5;
}

/* 구매 내역 */
.order-section {
  display: none;
}

.order-item {
  background: #fff8fc;
  border: 1px solid #f0dce9;
  border-radius: 12px;
  padding: 15px;
  margin-bottom: 12px;
}

.cancel-order-button {
  background: #999;
}

/* 구매 후기 */
.review-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.review-form textarea {
  min-height: 90px;
  resize: vertical;
}

.review-item {
  padding: 15px;
  margin-top: 12px;
  border-radius: 12px;
  background: #fff7fb;
  border: 1px solid #f0dce9;
}

.review-item h4 {
  margin: 0 0 8px;
  color: #a65e89;
}

/* 팝업 */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(70, 45, 65, 0.45);
  justify-content: center;
  align-items: center;
  padding: 15px;
  z-index: 100;
}

.modal-content {
  position: relative;
  background: white;
  width: 100%;
  max-width: 450px;
  max-height: 85vh;
  overflow-y: auto;
  padding: 28px;
  border-radius: 18px;
  text-align: center;
}

.close-button {
  position: absolute;
  right: 15px;
  top: 15px;
  background: #f3e5ed;
  color: #966b84;
}

.cart-item {
  border-bottom: 1px solid #eedce8;
  padding: 15px 0;
  text-align: left;
}

.quantity-control {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
}

.quantity-control button {
  padding: 6px 12px;
}

.remove-button,
.sub-button {
  background: #aaa;
}

.cart-total {
  margin: 20px 0;
  font-size: 18px;
}

.cart-total strong {
  color: #a65e89;
}

.main-button {
  width: 100%;
  margin-top: 10px;
  font-size: 16px;
}

.sub-button {
  width: 100%;
  margin-top: 8px;
}

/* 하단 */
footer {
  text-align: center;
  background: #f7d5e7;
  color: #89677d;
  padding: 30px 15px;
  line-height: 1.8;
}

footer h3 {
  color: #a65e89;
}

/* 모바일 */
@media (max-width: 700px) {
  .header-inner {
    flex-direction: column;
    gap: 18px;
  }

  .product-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .filter-grid {
    grid-template-columns: 1fr;
  }

  .summary-section {
    flex-direction: column;
  }
}

@media (max-width: 450px) {
  .product-list {
    grid-template-columns: 1fr;
  }

  .main-banner h2 {
    font-size: 21px;
  }
}
