/* Darul Ihsan · Give page: choose a giving option, its Zeffy form opens inline.
   Shared by the English and Bangla Give pages; colours come from each page's theme tokens. */
.give-app { --give-ease: cubic-bezier(0.23, 1, 0.32, 1); margin: 8px 0 12px; }
.give-head h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(24px, 2.4vw, 30px); margin: 0 0 4px; color: var(--green-ink, var(--green)); }
.give-head p { color: var(--muted); margin: 0 0 18px; font-size: 15px; }

.give-options { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.give-option { position: relative; display: flex; gap: 12px; align-items: flex-start; width: 100%; min-height: 76px; padding: 14px 16px; text-align: left; font: inherit; color: var(--ink); background: var(--white, #fffdf8); border: 1px solid var(--line); border-radius: 16px; cursor: pointer; transition: border-color 150ms ease, background-color 150ms ease, transform 160ms var(--give-ease), box-shadow 150ms ease; touch-action: manipulation; -webkit-user-select: none; user-select: none; }
.give-option:active { transform: scale(0.98); }
.give-option[aria-checked="true"] { border-color: var(--green); box-shadow: inset 0 0 0 1px var(--green); background: var(--paper, #f8f6ee); }
.give-option:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.give-icon { flex-shrink: 0; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; background: var(--paper-2, #eff0e3); color: var(--green-ink, var(--green)); transition: background-color 150ms ease, color 150ms ease; }
.give-icon svg { width: 22px; height: 22px; }
.give-option[aria-checked="true"] .give-icon { background: var(--green); color: #fff; }
.give-text { display: grid; gap: 2px; min-width: 0; }
.give-text b { font-weight: 600; font-size: 15px; line-height: 1.3; }
.give-text small { color: var(--muted); font-size: 13px; line-height: 1.45; }
.give-badge { justify-self: start; margin-top: 6px; font-size: 11px; font-weight: 600; letter-spacing: 0.02em; padding: 2px 8px; border-radius: 999px; background: var(--paper-2, #eff0e3); color: var(--gold-text, #75601f); }
@media (hover: hover) and (pointer: fine) { .give-option:hover { border-color: var(--green-3, var(--green)); } }

.give-panel { margin-top: 18px; scroll-margin-top: 120px; }
/* The frame follows the height the Zeffy form reports (donate.js);
   .is-fixed is the fallback when the form never reports it. Cream matches Zeffy's gold theme. */
/* Same border, radius and surface as the option cards above it (.give-option) */
.give-form { position: relative; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); background: var(--white, #fffdf8); min-height: 420px; }
.give-form iframe { display: block; width: 100%; height: 420px; border: 0; background: #fdf9ee; transition: opacity 240ms var(--give-ease), height 200ms var(--give-ease), filter 240ms var(--give-ease); }
.give-form.is-sized { min-height: 0; }
.give-form.is-fixed iframe { height: 760px !important; }
/* The Umrah package already chosen on the application: only Zeffy's Continue button shows, until checkout */
.give-form.give-one-item:not(.is-fixed) { min-height: 0; height: 48px; }
.give-form.give-one-item:not(.is-fixed) iframe { height: 236px !important; min-height: 0 !important; margin-top: -160px; } /* Continue sits near the bottom of the frame */
.give-reshow { display: block; min-height: 44px; margin-bottom: 8px; padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }
:has(> .give-form.give-one-item) > .give-reshow { display: none; }
.give-form.is-loading iframe { opacity: 0; position: absolute; inset: 0; }
.give-form:not(.is-loading) .give-skeleton, .give-form:not(.is-loading) .give-loading { display: none; }
.give-loading { text-align: center; color: #55665a; font-size: 14px; margin: 0 0 24px; }
.give-secure { font-size: 13px; color: var(--muted); margin: 10px 2px 0; }
.give-tip { font-size: 13px; color: var(--muted); margin: 14px 2px 0; max-width: 70ch; }

/* Skeleton while the form loads (and as the preview of a not-yet-connected option) */
.give-skeleton { display: grid; gap: 14px; padding: 28px; }
.give-skeleton span { display: block; height: 44px; border-radius: 12px; background: linear-gradient(90deg, #eef0e8 0%, #f7f8f2 40%, #eef0e8 80%); background-size: 200% 100%; animation: give-shimmer 1.4s linear infinite; }
.give-skeleton span.short { width: 55%; }
.give-skeleton span.tall { height: 120px; }
@keyframes give-shimmer { to { background-position: -200% 0; } }

.give-demo { padding: 26px; border: 1px dashed var(--gold); border-radius: 20px; background: var(--white, #fffdf8); }
.give-demo h4 { font-family: var(--serif); font-weight: 400; font-size: 24px; margin: 6px 0 8px; color: var(--green-ink, var(--green)); }
.give-demo p { color: var(--muted); margin: 0 0 10px; }
.give-demo a { color: var(--green-ink, var(--green)); font-weight: 600; text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 3px; }
.give-demo-badge { display: inline-block; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 999px; background: var(--paper-2, #eff0e3); color: var(--gold-text, #75601f); }
.give-skeleton-demo { padding: 14px 0 0; opacity: 0.7; }
.give-error { border-style: solid; border-color: #a8382c55; }

/* Dark theme: the card around the form follows the page; the Zeffy form itself stays light */
:root[data-theme="dark"] .give-option { background: var(--white); color: var(--ink); }
:root[data-theme="dark"] .give-option[aria-checked="true"] { background: var(--paper-2); border-color: #6fbf86; box-shadow: inset 0 0 0 1px #6fbf86; }
:root[data-theme="dark"] .give-skeleton span { background: linear-gradient(90deg, #183a26 0%, #1f4830 40%, #183a26 80%); background-size: 200% 100%; }
/* Dark theme shows the dark-green copy of each Zeffy form (darkUrl); the frame matches its background */
:root[data-theme="dark"] .give-form, :root[data-theme="dark"] .give-form iframe { background: #00662e; border-color: #285039; }
:root[data-theme="dark"] .give-form.is-loading { background: #00662e; }
/* .zeffy-tint (set in donate.js): Zeffy's darkest green is #00662e, brighter than the site's panels,
   so in the dark theme the frame is toned down to sit with the option cards (#183a26). Remove the class to undo. */
:root[data-theme="dark"] .give-form.zeffy-tint, :root[data-theme="dark"] .give-form.zeffy-tint iframe { background: #183a26; border-color: var(--line); }
:root[data-theme="dark"] .give-form.zeffy-tint:not(.is-loading) .zeffy-tint-layer { -webkit-backdrop-filter: url(#zeffy-dark); backdrop-filter: url(#zeffy-dark); }
/* Light theme: a gradient map (SVG filter #zeffy-light, built in donate.js) on a click-through layer
   over the form turns Zeffy's gold form into the card cream with forest-green buttons, text kept sharp.
   Browsers that can't do it simply show Zeffy's gold form. */
.zeffy-tint-layer { position: absolute; inset: 0; pointer-events: none; }
:root:not([data-theme="dark"]) .give-form.zeffy-tint:not(.is-loading) .zeffy-tint-layer { -webkit-backdrop-filter: url(#zeffy-light); backdrop-filter: url(#zeffy-light); }
:root[data-theme="dark"] .give-loading { color: var(--muted); }

@media (max-width: 680px) {
  .give-options { grid-template-columns: 1fr; }
  .give-demo { padding: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .give-skeleton span { animation: none; }
  .give-option, .give-form iframe { transition: none; }
}

/* ---------- Promo code and order summary (Pay tuition form, 2026-11-11) ---------- */
.promo-row { display: flex; gap: 8px; align-items: stretch; }
.promo-row input { flex: 1 1 auto; min-width: 0; text-transform: uppercase; letter-spacing: 0.04em; }
.promo-row input::placeholder { text-transform: none; letter-spacing: 0; }
.promo-row .button { flex: 0 0 auto; min-height: 48px; }
.field .optional { font-weight: 400; color: var(--muted); }
.promo-msg { margin: 0; font-size: 13px; font-weight: 500; min-height: 0; }
.promo-msg:empty { display: none; }
.promo-msg.is-ok { color: var(--green-ink); }
.promo-msg.is-bad { color: #a8382c; }
:root[data-theme="dark"] .promo-msg.is-bad { color: #f0a597; }
.promo-applied { display: inline-flex; align-items: center; gap: 8px; }
.promo-remove { min-height: 32px; padding: 0 4px; border: 0; background: none; font: inherit; font-size: 13px; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

.order-summary { font-family: inherit; font-size: 15px; color: var(--ink); margin-top: 0; }
.summary-card { border: 1px solid var(--line); border-radius: 16px; background: var(--white, #fffdf8); padding: 16px 18px; }
.summary-card h3 { font-family: var(--serif); font-weight: 400; font-size: 20px; margin: 0 0 10px; color: var(--green-ink); }
.summary-rows { display: grid; gap: 8px; margin: 0; }
.summary-rows > div { display: flex; justify-content: space-between; gap: 16px; align-items: baseline; }
.summary-rows dt { color: var(--muted); min-width: 0; }
.summary-rows dd { margin: 0; font-variant-numeric: tabular-nums; white-space: nowrap; }
.summary-rows .is-discount dt, .summary-rows .is-discount dd { color: var(--green-ink); }
.summary-rows .is-total { border-top: 1px solid var(--line); padding-top: 10px; margin-top: 2px; }
.summary-rows .is-total dt, .summary-rows .is-total dd { color: var(--ink); font-weight: 700; font-size: 17px; }
.summary-note { margin: 10px 0 0; font-size: 13px; color: var(--muted); }

/* ---------- Umrah room builder (Pay for Umrah, 2026-11-11) ---------- */
.room-builder { display: grid; gap: 18px; margin: 18px 0 8px; }
.rb-card { border: 1px solid var(--line); border-radius: 16px; background: var(--white, #fffdf8); padding: 18px; }
.rb-card > h3 { font-family: var(--serif); font-weight: 400; font-size: 22px; margin: 0 0 4px; color: var(--green-ink); }
.rb-card > p.rb-sub { margin: 0 0 14px; color: var(--muted); font-size: 14px; }
.rb-types { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; border: 0; padding: 0; margin: 0 0 16px; }
.rb-types legend { font-size: 14px; font-weight: 600; margin-bottom: 8px; padding: 0; }
.rb-type { position: relative; display: grid; gap: 2px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); cursor: pointer; transition: border-color 150ms ease, box-shadow 150ms ease; }
.rb-type input { position: absolute; opacity: 0; pointer-events: none; }
.rb-type b { font-weight: 600; font-size: 15px; }
.rb-type small { color: var(--muted); font-size: 13px; }
.rb-type .rb-price { font-variant-numeric: tabular-nums; color: var(--green-ink); font-weight: 600; font-size: 15px; }
.rb-type:has(input:checked) { border-color: var(--green); box-shadow: inset 0 0 0 1px var(--green); }
.rb-type:has(input:focus-visible) { outline: 2px solid var(--gold); outline-offset: 3px; }
@media (hover: hover) and (pointer: fine) { .rb-type:hover { border-color: var(--green-3, var(--green)); } }
.rb-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; }
.rb-count { display: grid; gap: 6px; }
.rb-count > span { font-size: 14px; font-weight: 600; }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); }
.stepper button { width: 44px; height: 44px; border: 0; background: none; color: var(--green-ink); font-size: 22px; line-height: 1; border-radius: 50%; cursor: pointer; touch-action: manipulation; }
.stepper button:disabled { opacity: 0.35; cursor: default; }
.stepper button:focus-visible { outline: 2px solid var(--gold); outline-offset: 1px; }
.stepper output { min-width: 40px; text-align: center; font-weight: 700; font-size: 18px; font-variant-numeric: tabular-nums; }
.rb-line-preview { font-variant-numeric: tabular-nums; color: var(--muted); font-size: 14px; }
.rb-line-preview b { color: var(--ink); font-size: 18px; }
.rb-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.rb-empty { color: var(--muted); font-size: 14px; margin: 0; }
.rb-rooms { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.rb-rooms li { display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.rb-rooms li.is-editing { background: var(--paper); border-radius: 10px; padding-left: 10px; padding-right: 10px; }
.rb-room-name { font-weight: 600; }
.rb-room-math { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }
.rb-room-total { grid-row: 1 / span 2; grid-column: 2; align-self: center; font-variant-numeric: tabular-nums; font-weight: 600; }
.rb-room-tools { grid-column: 1 / -1; display: flex; gap: 14px; }
.rb-room-tools button { min-height: 36px; padding: 0; border: 0; background: none; font: inherit; font-size: 14px; color: var(--green-ink); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.rb-grand { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding-top: 14px; font-weight: 700; font-size: 18px; font-variant-numeric: tabular-nums; }
.rb-grand small { display: block; font-weight: 400; font-size: 13px; color: var(--muted); }
.rb-details { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; margin-top: 16px; }
.rb-actions [hidden] { display: none; }
.rb-details .field { align-content: start; }
.rb-status { margin: 10px 0 0; font-size: 14px; }
.rb-status:empty { display: none; }
.rb-status.is-bad { color: #a8382c; }
:root[data-theme="dark"] .rb-status.is-bad { color: #f0a597; }
.give-app[data-give-wait]:has(.give-panel:empty) { display: none; }

/* ---------- Give page: other ways to give (2026-11-11) ---------- */
.give-ways { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; margin-top: 18px; }
.give-way { display: flex; flex-direction: column; gap: 10px; padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--white, #fffdf8); }
.give-way h3 { font-family: var(--serif); font-weight: 400; font-size: 22px; line-height: 1.2; margin: 0; color: var(--ink); }
.give-way p { margin: 0; font-size: 14px; line-height: 1.6; color: var(--muted); flex: 1 1 auto; }
.give-way .button { align-self: flex-start; }
@media (max-width: 520px) {
  .rb-card { padding: 16px 14px; }
  .rb-actions .button { flex: 1 1 100%; justify-content: center; }
}
/* Promo code folded under a small link (2026-11-11) */
.promo-toggle { justify-self: start; min-height: 40px; padding: 0; border: 0; background: none; font: inherit; font-size: 14px; font-weight: 600; color: var(--green-ink); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.promo-toggle:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 4px; }
.promo-box { display: grid; gap: 6px; }
.promo-box[hidden], .promo-toggle[hidden], .promo[hidden] { display: none; }
