* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --background: #0f3b72;
  --surface: rgba(22, 76, 139, 0.78);
  --surface-light: rgba(255, 255, 255, 0.11);
  --border: rgba(255, 255, 255, 0.19);
  --text: #ffffff;
  --muted: #d6e5f7;
  --blue: #5e9cff;
  --purple: #42a7ff;
  --orange: #ffad4d;
  --green: #50dfa7;
  --red: #ff7587;
}

body {
  min-height: 100vh;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 10% 5%, rgba(104, 190, 255, 0.52) 0%, transparent 34%),
    radial-gradient(circle at 92% 18%, rgba(255, 169, 73, 0.28) 0%, transparent 33%),
    radial-gradient(circle at 45% 100%, rgba(27, 126, 214, 0.24) 0%, transparent 42%),
    linear-gradient(145deg, #0f3c73 0%, #1765a7 48%, #0b376b 100%);
  background-attachment: fixed;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.cart-page {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  padding: 0 7% 80px;
}

.background-glow {
  position: fixed;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  filter: blur(105px);
  opacity: 0.32;
  pointer-events: none;
}

.glow-one {
  top: -160px;
  right: -80px;
  background: #79b0ff;
}

.glow-two {
  bottom: -190px;
  left: -80px;
  background: #ffad4d;
  opacity: 0.22;
}

.navbar {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 100px;
}

.navbar-brand img {
  display: block;
  width: 115px;
  max-height: 75px;
  object-fit: contain;
}

.navigation-links {
  display: flex;
  align-items: center;
  gap: 12px;
}

.navigation-links a {
  color: var(--text);
  text-decoration: none;
  padding: 11px 17px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.05);
  transition: background 0.2s ease, transform 0.2s ease;
}

.navigation-links a:hover {
  background: var(--surface-light);
  transform: translateY(-2px);
}

.cart-header {
  position: relative;
  z-index: 1;
  max-width: 720px;
  margin: 55px auto 45px;
  text-align: center;
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  color: #d9e6ff;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cart-header h1 {
  margin-bottom: 15px;
  font-size: clamp(38px, 5vw, 62px);
  line-height: 1.05;
}

.cart-header p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.checkout-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(380px, 0.85fr);
  gap: 28px;
  max-width: 1220px;
  margin: 0 auto;
  align-items: start;
}

.section-card {
  padding: 30px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 28px;
  background: linear-gradient(145deg, rgba(43, 87, 161, 0.78), rgba(18, 72, 137, 0.74));
  box-shadow:
    0 25px 70px rgba(8, 21, 59, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(22px);
}

.card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.card-heading span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.card-heading h2 {
  margin-top: 5px;
  font-size: 25px;
}

.card-heading > i {
  color: var(--green);
  font-size: 22px;
}

.cart-items {
  display: grid;
  gap: 18px;
  padding: 25px 0;
}

.cart-item {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 17px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.055));
  box-shadow: 0 12px 30px rgba(4, 17, 51, 0.13);
}

.cart-item-image {
  width: 104px;
  height: 104px;
  padding: 8px;
  border-radius: 17px;
  background: rgba(255, 255, 255, 0.12);
  object-fit: contain;
}

.cart-item-info h3 {
  margin-bottom: 7px;
  font-size: 19px;
}

.cart-item-info p {
  margin-bottom: 15px;
  color: var(--muted);
}

.quantity-control {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 6px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.06);
}

.quantity-control button {
  display: grid;
  place-items: center;
  width: 31px;
  height: 31px;
  border: 0;
  border-radius: 9px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.11);
  cursor: pointer;
}

.quantity-control button:hover {
  background: var(--blue);
}

.quantity-control span {
  min-width: 25px;
  text-align: center;
  font-weight: 800;
}

.cart-item-price {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 20px;
}

.cart-item-price strong {
  font-size: 20px;
}

.remove-button {
  border: 0;
  color: #ffd0d6;
  background: transparent;
  cursor: pointer;
}

.remove-button:hover {
  color: var(--red);
}

.order-summary {
  display: grid;
  gap: 14px;
  padding-top: 23px;
  border-top: 1px solid var(--border);
}

.order-summary > div {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  color: var(--muted);
}

.order-summary strong {
  color: var(--text);
  text-align: right;
}

.summary-total {
  margin-top: 8px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  font-size: 21px;
}

.summary-total strong {
  font-size: 25px;
}

.empty-cart {
  padding: 55px 20px;
  text-align: center;
}

.empty-cart i {
  margin-bottom: 17px;
  color: var(--blue);
  font-size: 45px;
}

.empty-cart h3 {
  margin-bottom: 10px;
  font-size: 24px;
}

.empty-cart p {
  margin-bottom: 25px;
  color: var(--muted);
}

.empty-cart a {
  display: inline-block;
  padding: 13px 22px;
  border-radius: 13px;
  color: #17203a;
  font-weight: 800;
  text-decoration: none;
  background: linear-gradient(135deg, var(--orange), #ffc46b);
}

.checkout-form {
  position: sticky;
  top: 25px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-top: 25px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-group label {
  font-size: 14px;
  font-weight: 700;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 13px;
  outline: none;
  color: var(--text);
  background: rgba(255, 255, 255, 0.12);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.form-group input,
.form-group select {
  height: 49px;
  padding: 0 14px;
}

.form-group textarea {
  min-height: 105px;
  padding: 13px 14px;
  resize: vertical;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(255, 255, 255, 0.58);
}

.form-group select option {
  color: #111827;
  background: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: #91bdff;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: 0 0 0 4px rgba(108, 166, 255, 0.2);
}

.form-group small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.terms-row {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  margin: 22px 0;
  color: var(--muted);
  line-height: 1.5;
  cursor: pointer;
}

.terms-row input {
  width: 17px;
  height: 17px;
  margin-top: 3px;
  accent-color: var(--blue);
}

.checkout-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  min-height: 56px;
  border: 0;
  border-radius: 16px;
  color: #17203a;
  font-weight: 800;
  background: linear-gradient(135deg, #ff9d3d, #ffc46b);
  box-shadow: 0 15px 35px rgba(255, 157, 61, 0.28);
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.checkout-button:hover:not(:disabled) {
  transform: translateY(-3px);
  box-shadow: 0 20px 42px rgba(255, 157, 61, 0.36);
}

.checkout-button:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.checkout-error {
  margin-bottom: 18px;
  padding: 13px 15px;
  border: 1px solid rgba(255, 107, 125, 0.35);
  border-radius: 13px;
  color: #ffd2d8;
  background: rgba(255, 107, 125, 0.12);
  line-height: 1.5;
}

.secure-note {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.secure-note i {
  margin-top: 3px;
  color: var(--green);
}

@media (max-width: 980px) {
  .checkout-layout {
    grid-template-columns: 1fr;
  }

  .checkout-form {
    position: static;
  }
}

@media (max-width: 650px) {
  .cart-page {
    padding: 0 18px 50px;
  }

  .navbar {
    min-height: 85px;
  }

  .navbar-brand img {
    width: 90px;
  }

  .navigation-links a:first-child {
    display: none;
  }

  .navigation-links a {
    padding: 10px 13px;
    font-size: 13px;
  }

  .cart-header {
    margin: 35px auto 30px;
  }

  .section-card {
    padding: 20px;
    border-radius: 21px;
  }

  .cart-item {
    grid-template-columns: 75px minmax(0, 1fr);
  }

  .cart-item-image {
    width: 75px;
    height: 75px;
  }

  .cart-item-price {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .form-group.full-width {
    grid-column: auto;
  }
}