.gift-cart-page {
  min-height: 100vh;
  padding: calc(var(--site-header-h) + 2rem) 0 4rem;
}

.gift-cart-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
  margin-bottom: 1.15rem;
  color: var(--text-dim);
  font-size: 0.78rem;
}

.gift-cart-breadcrumb a {
  color: var(--text-muted);
  text-decoration: none;
}

.gift-cart-breadcrumb a:hover {
  color: var(--accent);
}

.gift-cart-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.gift-cart-head h1 {
  margin-bottom: 0.45rem;
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4vw, 3.25rem);
  line-height: 1.05;
}

.gift-cart-head p {
  max-width: 680px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.gift-cart-head__count {
  flex: 0 0 auto;
  padding: 0.4rem 0.65rem;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
  background: rgba(var(--accent-rgb), 0.06);
  border: 1px solid rgba(var(--accent-rgb), 0.18);
  border-radius: 7px;
}

.gift-cart-message {
  margin-bottom: 1rem;
  padding: 0.8rem 0.9rem;
  font-size: 0.88rem;
  border: 1px solid;
  border-radius: 8px;
}

.gift-cart-message--success {
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.055);
  border-color: rgba(var(--accent-rgb), 0.2);
}

.gift-cart-message--error {
  color: #ffdce3;
  background: rgba(255, 77, 106, 0.07);
  border-color: rgba(255, 77, 106, 0.22);
}

.gift-cart-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(310px, 360px);
  gap: 1.25rem;
  align-items: start;
}

.gift-cart-items__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.gift-cart-items__bar h2 {
  font-size: 1rem;
  font-weight: 800;
}

.gift-cart-clear {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  padding: 0.35rem;
  color: var(--text-dim);
  font: inherit;
  font-size: 0.78rem;
  background: transparent;
  border: 0;
  cursor: pointer;
}

.gift-cart-clear svg {
  width: 1rem;
  height: 1rem;
}

.gift-cart-clear:hover {
  color: #ff8da1;
}

.gift-cart-items__list {
  display: grid;
  gap: 0.65rem;
}

.gift-cart-item {
  display: grid;
  grid-template-columns: 5.25rem minmax(0, 1fr) auto 2.25rem;
  align-items: center;
  gap: 0.9rem;
  min-width: 0;
  padding: 0.7rem;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.gift-cart-item__media {
  display: block;
  width: 5.25rem;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--bg-elevated);
  border-radius: 7px;
}

.gift-cart-item__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gift-cart-item__copy {
  display: grid;
  min-width: 0;
  gap: 0.08rem;
}

.gift-cart-item__copy span {
  overflow: hidden;
  color: var(--accent);
  font-size: 0.68rem;
  font-weight: 800;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.gift-cart-item__copy h3 {
  overflow: hidden;
  font-size: 1rem;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.gift-cart-item__copy small {
  color: var(--text-dim);
  font-size: 0.76rem;
  font-variant-numeric: tabular-nums;
}

.gift-cart-item__price {
  color: var(--text);
  font-size: 0.95rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.gift-cart-item__remove {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 7px;
  cursor: pointer;
}

.gift-cart-item__remove svg {
  width: 1rem;
  height: 1rem;
}

.gift-cart-item__remove:hover {
  color: #ff8da1;
  background: rgba(255, 77, 106, 0.06);
  border-color: rgba(255, 77, 106, 0.25);
}

.gift-cart-summary {
  position: sticky;
  top: calc(var(--site-header-h) + 1rem);
  padding: 1.1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.gift-cart-summary__title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--border);
}

.gift-cart-summary__title span {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.gift-cart-summary__title strong {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-variant-numeric: tabular-nums;
}

.gift-cart-summary__details {
  display: grid;
  gap: 0.45rem;
  padding: 0.85rem 0;
}

.gift-cart-summary__details div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.8rem;
}

.gift-cart-summary__details dt {
  color: var(--text-dim);
}

.gift-cart-summary__details dd {
  color: var(--text-muted);
  font-weight: 700;
}

.gift-cart-summary__notice {
  margin-bottom: 1rem;
  padding: 0.7rem;
  color: var(--text-muted);
  font-size: 0.75rem;
  line-height: 1.45;
  background: rgba(var(--accent-rgb), 0.045);
  border-left: 2px solid var(--accent);
}

.gift-cart-checkout {
  display: grid;
  gap: 0.75rem;
}

.gift-cart-checkout > label:first-child {
  display: grid;
  gap: 0.38rem;
}

.gift-cart-checkout label > span {
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.gift-cart-checkout input[type="text"] {
  width: 100%;
  min-height: 2.8rem;
  padding: 0 0.8rem;
  color: var(--text);
  font: inherit;
  font-size: 1rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 8px;
  outline: 0;
}

.gift-cart-checkout input[type="text"]:focus {
  border-color: rgba(var(--accent-rgb), 0.5);
  box-shadow: 0 0 0 3px rgba(var(--accent-rgb), 0.07);
}

.gift-cart-checkout__toggle {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  cursor: pointer;
}

.gift-cart-checkout__toggle input {
  accent-color: var(--accent);
}

.gift-cart-checkout__error {
  color: #ff9aac;
  font-size: 0.75rem;
}

.gift-cart-auth {
  display: grid;
  gap: 0.7rem;
}

.gift-cart-auth > strong {
  font-size: 0.92rem;
}

.gift-cart-auth p {
  color: var(--text-muted);
  font-size: 0.78rem;
  line-height: 1.45;
}

.gift-cart-auth__register {
  color: var(--text-muted);
  font-size: 0.78rem;
  text-align: center;
  text-decoration: none;
}

.gift-cart-auth__register:hover {
  color: var(--accent);
}

.gift-cart-empty {
  display: grid;
  justify-items: center;
  max-width: 560px;
  margin: 3.5rem auto 0;
  padding: 2rem 1rem;
  text-align: center;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.gift-cart-empty__icon {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  margin-bottom: 0.9rem;
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.06);
  border: 1px solid rgba(var(--accent-rgb), 0.18);
  border-radius: 8px;
}

.gift-cart-empty__icon svg {
  width: 1.45rem;
  height: 1.45rem;
}

.gift-cart-empty h2 {
  margin-bottom: 0.35rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
}

.gift-cart-empty p {
  max-width: 430px;
  margin-bottom: 1rem;
  color: var(--text-muted);
  font-size: 0.88rem;
}

@media (max-width: 760px) {
  .gift-cart-page {
    padding: calc(var(--site-header-h) + 1rem) 0 2.5rem;
  }

  .gift-cart-head {
    display: grid;
    gap: 0.75rem;
  }

  .gift-cart-head h1 {
    font-size: 2rem;
  }

  .gift-cart-head__count {
    width: fit-content;
  }

  .gift-cart-layout {
    grid-template-columns: 1fr;
  }

  .gift-cart-item {
    grid-template-columns: 4.4rem minmax(0, 1fr) 2.15rem;
    gap: 0.7rem;
  }

  .gift-cart-item__media {
    grid-row: span 2;
    width: 4.4rem;
  }

  .gift-cart-item__price {
    grid-column: 2;
    font-size: 0.88rem;
  }

  .gift-cart-item form {
    grid-column: 3;
    grid-row: 1 / span 2;
  }

  .gift-cart-item__remove {
    width: 2.15rem;
    height: 2.15rem;
  }

  .gift-cart-summary {
    position: static;
  }
}
