/* =====================================================================
   gofordigitalindia.in — UI micro-components
   File: /assets/css/gfdi-components.css   (additive, no existing rule changed)
   Zero dependencies. Mobile-first. All boxes reserve their own space (CLS = 0).
   Load once in <head>:
   <link rel="stylesheet" href="/assets/css/gfdi-components.css?v=20261108">
   ===================================================================== */

:root {
  --gfdi-ink: #1d2733;
  --gfdi-muted: #5f6b7a;
  --gfdi-line: #e3e8ee;
  --gfdi-soft: #f4f8fc;
  --gfdi-brand: #0a5ea8;
  --gfdi-accent: #e8770a;
  --gfdi-ok: #15803d;
  --gfdi-wa: #128c7e;
  --gfdi-radius: 12px;
}

[class^="gfdi-"], [class*=" gfdi-"] { box-sizing: border-box; }

/* ---------- 1. Quick Snapshot Card ---------- */
.gfdi-snap {
  margin: 16px 0 20px;
  border: 1px solid var(--gfdi-line);
  border-left: 4px solid var(--gfdi-brand);
  border-radius: var(--gfdi-radius);
  background: var(--gfdi-soft);
  padding: 14px 14px 12px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--gfdi-ink);
}
.gfdi-snap__title {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 700;
  color: var(--gfdi-brand);
}
.gfdi-snap__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin: 0;
}
.gfdi-snap__row {
  display: grid;
  grid-template-columns: 42% 58%;
  gap: 8px;
  padding: 8px 0;
  border-top: 1px dashed var(--gfdi-line);
}
.gfdi-snap__row:first-child { border-top: 0; }
.gfdi-snap dt { margin: 0; font-weight: 600; color: var(--gfdi-muted); }
.gfdi-snap dd { margin: 0; font-weight: 600; word-break: break-word; }
.gfdi-snap__deadline dd { color: #b91c1c; }
.gfdi-snap__cta {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 12px;
  min-height: 48px;               /* thumb-friendly tap target */
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--gfdi-brand);
  color: #fff;
  text-align: center;
  font-weight: 700;
  text-decoration: none;
}
.gfdi-snap__cta:focus-visible { outline: 3px solid var(--gfdi-accent); outline-offset: 2px; }
.gfdi-snap__note { margin: 8px 0 0; font-size: 12.5px; color: var(--gfdi-muted); }
@media (min-width: 720px) {
  .gfdi-snap__grid { grid-template-columns: 1fr 1fr; column-gap: 24px; }
  .gfdi-snap__row:nth-child(2) { border-top: 0; }
}

/* ---------- 2. Document & Eligibility Checklist ---------- */
.gfdi-check {
  margin: 20px 0;
  border: 1px solid var(--gfdi-line);
  border-radius: var(--gfdi-radius);
  padding: 14px;
  background: #fff;
}
.gfdi-check__head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.gfdi-check__title { margin: 0; font-size: 16px; font-weight: 700; color: var(--gfdi-ink); }
.gfdi-check__count { font-size: 13px; font-weight: 700; color: var(--gfdi-muted); white-space: nowrap; }
.gfdi-check__bar { height: 8px; margin: 10px 0 6px; border-radius: 8px; background: var(--gfdi-line); overflow: hidden; }
.gfdi-check__fill { height: 100%; width: 0; background: var(--gfdi-ok); transition: width .25s ease; }
.gfdi-check__list { list-style: none; margin: 8px 0 0; padding: 0; }
.gfdi-check__item { border-top: 1px solid var(--gfdi-line); }
.gfdi-check__item:first-child { border-top: 0; }
.gfdi-check__label {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-height: 48px;
  padding: 12px 2px;
  cursor: pointer;
  font-size: 15px;
  line-height: 1.45;
}
.gfdi-check__label input {
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  margin: 1px 0 0;
  accent-color: var(--gfdi-ok);
}
.gfdi-check__hint { display: block; font-size: 12.5px; color: var(--gfdi-muted); }
.gfdi-check__label input:checked + span { color: var(--gfdi-ok); }
.gfdi-check__done {
  margin: 10px 0 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: #ecfdf3;
  color: var(--gfdi-ok);
  font-weight: 700;
  font-size: 14.5px;
}
.gfdi-check__done[hidden] { display: none; }
.gfdi-check__reset {
  margin-top: 8px; padding: 6px 0; border: 0; background: none;
  color: var(--gfdi-muted); font-size: 13px; text-decoration: underline; cursor: pointer;
}

/* ---------- 3. Related Tool Callout ---------- */
.gfdi-tool {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  padding: 12px 14px;
  border: 1px solid #fde3c8;
  border-radius: var(--gfdi-radius);
  background: #fff8f0;
  text-decoration: none;
  color: var(--gfdi-ink);
  min-height: 64px;
}
.gfdi-tool__icon {
  flex: 0 0 40px; width: 40px; height: 40px; border-radius: 10px;
  display: grid; place-items: center; background: var(--gfdi-accent); color: #fff; font-size: 20px;
}
.gfdi-tool__text { flex: 1; font-size: 15px; line-height: 1.4; }
.gfdi-tool__text strong { display: block; font-size: 15.5px; }
.gfdi-tool__go { font-weight: 700; color: var(--gfdi-accent); white-space: nowrap; }

/* ---------- 4. WhatsApp share ---------- */
.gfdi-wa {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 48px;
  margin: 18px 0;
  padding: 12px 16px;
  border: 0;
  border-radius: 10px;
  background: var(--gfdi-wa);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}
.gfdi-wa svg { width: 22px; height: 22px; flex: 0 0 22px; }
.gfdi-wa:focus-visible { outline: 3px solid var(--gfdi-accent); outline-offset: 2px; }

/* Floating button: fixed position, so it never shifts layout.
   Sits above the AdSense anchor ad (which uses the bottom ~60–100px). */
.gfdi-wa-float {
  position: fixed;
  right: 14px;
  bottom: calc(110px + env(safe-area-inset-bottom, 0px));
  z-index: 50;
  width: 52px; height: 52px;
  border: 0; border-radius: 50%;
  background: var(--gfdi-wa); color: #fff;
  box-shadow: 0 4px 14px rgba(0,0,0,.25);
  display: grid; place-items: center;
  cursor: pointer;
  transform: translateY(0); transition: transform .2s ease, opacity .2s ease;
}
.gfdi-wa-float svg { width: 28px; height: 28px; }
.gfdi-wa-float[data-hidden="true"] { opacity: 0; transform: translateY(20px); pointer-events: none; }

/* ---------- 5. Ad slots (CLS-safe) ---------- */
.gfdi-ad {
  display: block;
  margin: 24px auto;
  text-align: center;
  clear: both;
  /* Reserve the height of the unit BEFORE the ad loads. Fixed-size units => 0 shift. */
  min-height: 280px;              /* 300x250 / 336x280 + label */
  contain: layout;                /* the ad cannot push content around */
}
.gfdi-ad__label {
  display: block;
  height: 18px;
  margin: 0 0 4px;
  font-size: 11px;
  line-height: 18px;
  letter-spacing: .04em;
  color: var(--gfdi-muted);
  text-transform: uppercase;
}
.gfdi-ad ins.adsbygoogle { display: inline-block; width: 300px; height: 250px; }
@media (min-width: 380px) {
  .gfdi-ad { min-height: 302px; }
  .gfdi-ad ins.adsbygoogle { width: 336px; height: 280px; }
}
@media (min-width: 768px) {
  .gfdi-ad--wide { min-height: 112px; }
  .gfdi-ad--wide ins.adsbygoogle { width: 728px; height: 90px; }
}
/* If AdSense returns no ad, collapse only AFTER the page is idle (handled in JS, below the fold only). */
.gfdi-ad[data-collapsed="true"] { min-height: 0; margin: 0; }
.gfdi-ad[data-collapsed="true"] .gfdi-ad__label { display: none; }

/* ---------- 6. Trust blocks ---------- */
.gfdi-trust {
  margin: 20px 0;
  padding: 12px 14px;
  border-radius: var(--gfdi-radius);
  border: 1px solid #fecaca;
  background: #fff5f5;
  font-size: 14px;
  line-height: 1.55;
  color: #7f1d1d;
}
.gfdi-trust strong { color: #991b1b; }
.gfdi-verified {
  display: flex; flex-wrap: wrap; gap: 6px 14px;
  margin: 8px 0 14px; font-size: 13px; color: var(--gfdi-muted);
}
.gfdi-verified b { color: var(--gfdi-ink); }
.gfdi-official {
  display: flex; align-items: center; gap: 10px; min-height: 48px;
  margin: 10px 0; padding: 10px 14px; border-radius: 10px;
  border: 1px solid var(--gfdi-line); background: #fff; color: var(--gfdi-brand);
  font-weight: 700; text-decoration: none;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .gfdi-check__fill, .gfdi-wa-float { transition: none; }
}
