:root {
  --green: #1a8d5f;
  --green-soft: #e8f4ee;
  --ink: #14181f;
  --muted: #707a89;
  --faint: #9aa3b0;
  --line: #edf0f3;
  --bg: #f6f7f9;
  --card: #ffffff;
}

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

html,
body {
  min-height: 100%;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: max(20px, env(safe-area-inset-top)) 18px
    max(20px, env(safe-area-inset-bottom));
}

.receipt {
  width: 100%;
  max-width: 400px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.04),
    0 12px 36px rgba(16, 24, 40, 0.06);
  margin-top: 20px;
}

/* ---- Hero ---- */
.hero {
  text-align: center;
  padding: 44px 28px 30px;
}

.check {
  width: 64px;
  height: 64px;
  margin: 0 auto 22px;
  border-radius: 50%;
  background: var(--green-soft);
  display: grid;
  place-items: center;
  animation: pop 0.4s cubic-bezier(0.2, 0.9, 0.3, 1.3) both;
}

.check__svg {
  width: 34px;
  height: 34px;
}

.check__circle {
  display: none;
}

.check__mark {
  stroke: var(--green);
  stroke-width: 4.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 48;
  stroke-dashoffset: 48;
  animation: draw 0.4s ease-out 0.25s forwards;
}

.hero__title {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.hero__subtitle {
  margin-top: 7px;
  font-size: 0.93rem;
  color: var(--muted);
  font-weight: 450;
}

/* ---- Amount ---- */
.amount {
  text-align: center;
  padding: 14px 28px 4px;
  display: flex;
  justify-content: center;
  align-items: baseline;
  gap: 7px;
}

.amount__value {
  font-size: 2.6rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.amount__currency {
  font-size: 1rem;
  font-weight: 600;
  color: var(--faint);
}

.purpose {
  text-align: center;
  color: var(--muted);
  font-size: 0.92rem;
  padding: 0 28px 26px;
}

.purpose strong {
  color: var(--ink);
  font-weight: 600;
}

/* ---- Details ---- */
.details {
  padding: 6px 28px;
  border-top: 1px solid var(--line);
}

.row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.row:last-child {
  border-bottom: none;
}

.row__label {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 450;
}

.row__value {
  font-size: 0.9rem;
  font-weight: 600;
  text-align: right;
}

.row__value.mono {
  font-family: "SF Mono", ui-monospace, "Menlo", monospace;
  letter-spacing: 0.01em;
  font-size: 0.85rem;
}

.apple-pay {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.apple-pay__logo {
  width: 14px;
  height: 17px;
  fill: var(--ink);
  margin-right: 1px;
}

.apple-pay__text {
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.apple-pay__card {
  margin-left: 6px;
  color: var(--ink);
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--green);
}

.status__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
}

/* ---- Notice ---- */
.notice {
  margin: 22px 28px 6px;
  display: flex;
  gap: 11px;
  align-items: center;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 12px;
  padding: 13px 15px;
}

.notice__icon {
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
  fill: var(--faint);
}

.notice p {
  font-size: 0.86rem;
  line-height: 1.4;
}

.notice strong {
  font-weight: 650;
  color: var(--ink);
}

/* ---- Footer ---- */
.foot {
  padding: 20px 28px 26px;
  text-align: center;
  color: var(--faint);
}

.foot__secure {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--muted);
}

.foot__secure svg {
  width: 14px;
  height: 14px;
  fill: var(--faint);
}

.foot__id {
  margin-top: 7px;
  font-size: 0.76rem;
}

/* ---- Animations ---- */
@keyframes pop {
  from {
    transform: scale(0.5);
    opacity: 0;
  }
}

@keyframes draw {
  to {
    stroke-dashoffset: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  .check,
  .check__mark {
    animation: none !important;
  }
  .check__mark {
    stroke-dashoffset: 0;
  }
}
