﻿:root {
  --bg: #f5ecdf;
  --paper: #fffaf2;
  --ink: #173421;
  --muted: #657568;
  --leaf: #285f3e;
  --leaf-2: #3d7d56;
  --peach: #efb5a8;
  --rose: #c85f50;
  --gold: #c89130;
  --line: rgba(40, 95, 62, 0.15);
  --shadow: 0 18px 42px rgba(43, 63, 47, 0.12);
  --display: "Noto Kufi Arabic", "Tajawal", sans-serif;
  --body: "Tajawal", "Noto Kufi Arabic", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at top right, rgba(219, 235, 217, 0.9), transparent 30%),
    radial-gradient(circle at bottom left, rgba(239, 181, 168, 0.52), transparent 30%),
    var(--bg);
  font-family: var(--body);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

.animated-backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.animated-backdrop::before,
.animated-backdrop::after {
  content: "";
  position: absolute;
  width: 70vmax;
  height: 70vmax;
  opacity: 0.32;
  filter: blur(2px);
  background:
    repeating-linear-gradient(
      135deg,
      transparent 0 28px,
      rgba(40, 95, 62, 0.08) 29px 30px,
      transparent 31px 58px
    );
}

.animated-backdrop::before {
  top: -35vmax;
  right: -24vmax;
  animation: backgroundSweep 18s linear infinite;
}

.animated-backdrop::after {
  left: -28vmax;
  bottom: -40vmax;
  background:
    repeating-linear-gradient(
      45deg,
      transparent 0 34px,
      rgba(200, 95, 80, 0.08) 35px 36px,
      transparent 37px 70px
    );
  animation: backgroundSweep 24s linear infinite reverse;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.page {
  width: min(1380px, 100%);
  margin: 0 auto;
  padding: clamp(14px, 2.4vw, 32px);
}

.product {
  display: grid;
  grid-template-columns: minmax(280px, 0.82fr) minmax(380px, 1.16fr) minmax(280px, 0.56fr);
  gap: clamp(14px, 1.8vw, 22px);
  align-items: start;
}

.gallery,
.details,
.checkout,
.modal-card {
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 250, 242, 0.92);
  box-shadow: var(--shadow);
}

.gallery {
  padding: 16px;
}

.gallery img {
  display: block;
  width: 100%;
  max-height: min(680px, calc(100vh - 96px));
  object-fit: contain;
  border-radius: 16px;
  background: #fff6ed;
}

.details {
  padding: clamp(18px, 2.4vw, 30px);
}

.eyebrow {
  display: inline-flex;
  margin: 0 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 12px;
  color: var(--leaf);
  background: rgba(219, 235, 217, 0.55);
  font-weight: 800;
  font-size: 0.92rem;
}

h1,
h2 {
  margin-top: 0;
  color: var(--ink);
  font-family: var(--display);
  line-height: 1.2;
  letter-spacing: 0;
}

h1 {
  margin-bottom: 14px;
  font-size: clamp(2rem, 3vw, 3.55rem);
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(1.45rem, 2vw, 2rem);
}

.lead,
.payment-note,
.benefits p,
.hint {
  color: var(--muted);
  line-height: 1.85;
}

.lead {
  margin: 0 0 18px;
  font-size: clamp(1rem, 1.15vw, 1.14rem);
}

.highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.highlights span {
  border-radius: 12px;
  padding: 9px 12px;
  color: #7d3c31;
  background: rgba(239, 181, 168, 0.3);
  font-weight: 800;
}

.benefits {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 24px;
}

.benefits article {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.58);
}

.benefits strong {
  display: block;
  margin-bottom: 5px;
  color: var(--leaf);
  font-family: var(--display);
}

.benefits p {
  margin: 0;
  font-size: 0.95rem;
}

.books {
  border-top: 1px solid var(--line);
  padding-top: 20px;
}

.books ol {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.books li {
  display: flex;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.6);
  font-weight: 800;
  line-height: 1.55;
}

.book-number {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  color: white;
  background: linear-gradient(135deg, var(--leaf), var(--leaf-2));
  font-weight: 900;
  direction: ltr;
}

.checkout {
  padding: 20px;
}

.badge {
  display: inline-flex;
  margin: 0 0 12px;
  border-radius: 999px;
  padding: 8px 12px;
  color: #7d3c31;
  background: rgba(239, 181, 168, 0.34);
  font-family: var(--display);
  font-weight: 800;
}

.price {
  display: grid;
  gap: 4px;
  margin-bottom: 12px;
}

.price span {
  color: var(--muted);
  font-weight: 800;
}

.price strong {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #b94c38;
  font-family: var(--display);
  font-size: clamp(2.4rem, 3.2vw, 3.2rem);
  line-height: 1;
}

.sar-symbol {
  display: inline-grid;
  place-items: center;
  min-width: 0.9em;
  height: 1em;
  border: 0;
  border-radius: 0;
  color: inherit;
  font-family: "Noto Kufi Arabic", "Tajawal", sans-serif;
  font-size: 0.86em;
  font-weight: 800;
  line-height: 1;
}

.sar-symbol::before {
  content: "⃁";
  transform: translateY(0.02em);
}

.payment-note {
  margin: 0 0 16px;
}

.buy-button,
.whatsapp-button {
  width: 100%;
  min-height: 54px;
  border: 0;
  border-radius: 14px;
  padding: 14px 18px;
  color: white;
  background: linear-gradient(135deg, var(--leaf), var(--leaf-2));
  font-family: var(--display);
  font-size: 1.05rem;
  font-weight: 900;
}

.trust {
  display: grid;
  gap: 9px;
  margin-top: 16px;
  color: var(--muted);
  font-weight: 800;
}

.trust span::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--leaf);
  margin-inline-end: 8px;
}

.support {
  display: grid;
  gap: 4px;
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px;
  color: var(--leaf);
  background: rgba(219, 235, 217, 0.45);
  text-decoration: none;
}

.support span {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 800;
}

.footer {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 0 20px 30px;
  color: var(--muted);
  font-weight: 800;
}

.footer a {
  color: var(--leaf);
  text-decoration: none;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
}

.modal.is-open {
  opacity: 1;
  visibility: visible;
}

@keyframes backgroundSweep {
  from {
    transform: translate3d(0, 0, 0) rotate(0deg);
  }
  to {
    transform: translate3d(6%, 4%, 0) rotate(360deg);
  }
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(24, 53, 37, 0.5);
}

.modal-card {
  position: relative;
  width: min(700px, 100%);
  max-height: min(90vh, 840px);
  overflow: auto;
  padding: 26px;
}

.close-button {
  position: absolute;
  top: 12px;
  inset-inline-end: 12px;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--ink);
  background: white;
  font-size: 1.35rem;
}

.modal-kicker {
  margin: 0 0 8px;
  color: var(--rose);
  font-family: var(--display);
  font-weight: 900;
}

.modal-card h2 {
  padding-inline-end: 44px;
}

.order-strip {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 16px 0;
  border: 1px solid rgba(200, 95, 80, 0.2);
  border-radius: 14px;
  padding: 12px 14px;
  color: #8c3c2f;
  background: rgba(239, 181, 168, 0.28);
  font-weight: 900;
}

.bank-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.bank-grid div,
.name-field {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 13px;
  background: rgba(255, 255, 255, 0.65);
}

.bank-grid span,
.name-field span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 800;
}

.bank-grid strong,
.copy-field {
  color: var(--ink);
  font-weight: 900;
  overflow-wrap: anywhere;
}

.copy-field {
  width: 100%;
  border: 0;
  padding: 0;
  text-align: inherit;
  background: transparent;
}

.name-field {
  display: block;
  margin-top: 12px;
}

.name-field input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px;
  color: var(--ink);
  background: white;
  outline: none;
}

.hint {
  margin: 14px 0;
}

@media (max-width: 1100px) {
  .product {
    grid-template-columns: minmax(240px, 0.82fr) minmax(320px, 1fr);
  }

  .checkout {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .page {
    padding: 12px;
  }

  .product {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .gallery {
    order: 1;
    padding: 10px;
  }

  .checkout {
    order: 2;
  }

  .details {
    order: 3;
    padding: 18px;
  }

  .gallery,
  .details,
  .checkout,
  .modal-card {
    border-radius: 18px;
  }

  .gallery img {
    max-height: 42vh;
    width: min(100%, 360px);
    margin-inline: auto;
  }

  h1 {
    font-size: clamp(1.8rem, 8vw, 2.5rem);
  }

  .lead {
    font-size: 1rem;
  }

  .benefits,
  .bank-grid {
    grid-template-columns: 1fr;
  }

  .highlights span {
    width: 100%;
  }

  .price {
    grid-template-columns: 1fr auto;
    align-items: end;
  }

  .price strong {
    font-size: 2.35rem;
  }

  .modal {
    align-items: end;
    padding: 0;
  }

  .modal-card {
    width: 100%;
    max-height: 88vh;
    border-radius: 22px 22px 0 0;
  }

  .footer {
    display: grid;
    justify-items: center;
    text-align: center;
  }
}
