/* ==========================================================================
   Components — buttons, badges, eyebrow, stamps, passport data page, visa cards
   ========================================================================== */

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 24px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background-color 0.3s, color 0.3s;
}

.btn svg {
  width: 18px;
  height: 18px;
  transition: transform 0.3s var(--ease);
}

.btn:hover svg {
  transform: translateX(3px);
}

.btn--navy {
  background: linear-gradient(135deg, var(--navy-700), var(--navy-900));
  color: var(--gold-300);
  box-shadow: inset 0 0 0 1px rgba(201, 163, 82, 0.6), 0 10px 24px -12px rgba(15, 26, 58, 0.7);
}

.btn--navy:hover {
  transform: translateY(-2px);
  box-shadow: inset 0 0 0 1px var(--gold-500), 0 16px 30px -12px rgba(15, 26, 58, 0.75);
}

.btn--ghost {
  color: var(--navy-800);
  background: rgba(255, 255, 255, 0.55);
  box-shadow: inset 0 0 0 1px var(--line);
}

.btn--ghost:hover {
  transform: translateY(-2px);
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(20, 34, 74, 0.3);
}

.btn--gold {
  background: linear-gradient(135deg, var(--gold-300), var(--gold-500));
  color: var(--navy-900);
}

.btn--gold:hover {
  transform: translateY(-2px);
}

/* ---------- Badge / eyebrow ---------- */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  background: rgba(180, 50, 63, 0.08);
  color: var(--stamp-red);
  box-shadow: inset 0 0 0 1px rgba(180, 50, 63, 0.3);
}

.badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  animation: blink 1.8s ease-in-out infinite;
}

.badge--gold {
  background: rgba(201, 163, 82, 0.12);
  color: var(--gold-300);
  box-shadow: inset 0 0 0 1px rgba(201, 163, 82, 0.4);
}

@keyframes blink {
  50% {
    opacity: 0.25;
  }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--teal-600);
}

.eyebrow::before,
.eyebrow--center::after {
  content: "";
  width: 32px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}

/* Iridescent text, echoing the logo lettering */
.text-iridescent {
  background: linear-gradient(100deg, var(--navy-700) 0%, var(--teal-600) 35%, var(--navy-600) 55%, var(--violet-500) 80%, var(--navy-800) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- Immigration stamp ---------- */

.stamp {
  --stamp-color: var(--stamp-red);
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 10px 18px;
  border: 3px solid var(--stamp-color);
  border-radius: 10px;
  color: var(--stamp-color);
  text-align: center;
  text-transform: uppercase;
  transform: rotate(-9deg);
  mix-blend-mode: multiply;
  -webkit-mask: url("../images/stamp-texture.svg") 0 0 / 320px 320px;
  mask: url("../images/stamp-texture.svg") 0 0 / 320px 320px;
  pointer-events: none;
  user-select: none;
}

.stamp::before {
  content: "";
  position: absolute;
  inset: 4px;
  border: 1.5px solid var(--stamp-color);
  border-radius: 6px;
}

.stamp__small {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.26em;
}

.stamp__big {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.05;
}

.stamp--round {
  width: 150px;
  height: 150px;
  justify-content: center;
  padding: 0;
  border-radius: 50%;
}

.stamp--round::before {
  border-radius: 50%;
  inset: 6px;
}

.stamp--round .stamp__big {
  font-size: 1.05rem;
}

.stamp--blue {
  --stamp-color: var(--stamp-blue);
}

.stamp--teal {
  --stamp-color: var(--teal-600);
}

.js .stamp.reveal {
  opacity: 0;
  transform: rotate(-9deg) scale(1.6);
}

.js .stamp.reveal.is-visible {
  opacity: 0.9;
  transform: rotate(-9deg) scale(1);
  transition: opacity 0.25s ease-out 0.35s, transform 0.45s cubic-bezier(0.5, 0, 0.6, 1.6) 0.35s;
}

/* ---------- Passport data page (inner pages) ---------- */

.passport {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(500px 300px at 0% 0%, rgba(156, 195, 230, 0.4), transparent 70%),
    radial-gradient(500px 300px at 100% 100%, rgba(233, 166, 189, 0.35), transparent 70%),
    radial-gradient(400px 300px at 60% 30%, rgba(168, 216, 208, 0.25), transparent 70%),
    url("../images/guilloche.svg"),
    #fbf8f2;
  background-size: auto, auto, auto, 480px 240px, auto;
  box-shadow: var(--shadow-lg), inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}

/* Gold inner hairline frame */
.passport::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(201, 163, 82, 0.45);
  border-radius: calc(var(--radius-lg) - 8px);
  pointer-events: none;
}

/* Faint rosette watermark */
.passport::after {
  content: "";
  position: absolute;
  right: -60px;
  top: 50%;
  width: 380px;
  height: 380px;
  background: var(--navy-600);
  opacity: 0.07;
  transform: translateY(-55%);
  -webkit-mask: url("../images/rosette.svg") center / contain no-repeat;
  mask: url("../images/rosette.svg") center / contain no-repeat;
  pointer-events: none;
}

.passport__head {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding: 26px clamp(22px, 4vw, 48px) 18px;
  border-bottom: 1px dashed rgba(20, 34, 74, 0.18);
}

.passport__issuer {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 14px;
}

.passport__issuer-hindi {
  font-family: var(--font-hindi);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--navy-700);
}

.passport__issuer-en {
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  color: var(--navy-800);
}

.passport__no {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  color: var(--stamp-red);
}

.passport__body {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: clamp(24px, 4vw, 48px);
  padding: clamp(24px, 4vw, 44px) clamp(22px, 4vw, 48px);
}

.passport__photo {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.passport__photo-frame {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 5;
  border-radius: 12px;
  overflow: hidden;
  background:
    linear-gradient(160deg, rgba(31, 50, 112, 0.92), rgba(15, 26, 58, 0.98)),
    var(--navy-900);
  box-shadow: inset 0 0 0 1px rgba(201, 163, 82, 0.5), var(--shadow);
  color: var(--gold-300);
}

.passport__photo-frame::before {
  content: "";
  position: absolute;
  inset: -20%;
  background: var(--gold-500);
  opacity: 0.16;
  -webkit-mask: url("../images/rosette.svg") center / contain no-repeat;
  mask: url("../images/rosette.svg") center / contain no-repeat;
  animation: spin 80s linear infinite;
}

.passport__photo-frame svg {
  position: relative;
  width: 42%;
  height: auto;
  stroke-width: 1.3;
}

/* Holographic shimmer sweep across the "photo" */
.passport__photo-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(79, 176, 182, 0.25) 45%, rgba(233, 166, 189, 0.22) 52%, transparent 65%);
  background-size: 250% 100%;
  animation: holo 6s ease-in-out infinite;
}

@keyframes holo {
  0%,
  100% {
    background-position: 100% 0;
  }
  50% {
    background-position: 0 0;
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.passport__signature {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  line-height: 1;
  text-align: center;
  color: var(--navy-700);
  opacity: 0.75;
}

.passport__details {
  position: relative;
  min-width: 0;
}

.passport__title {
  margin-top: 14px;
  font-size: clamp(1.8rem, 5vw, 3.2rem);
  letter-spacing: 0.02em;
}

.passport__lead {
  margin-top: 14px;
  max-width: 52ch;
  font-size: 1rem;
  color: var(--ink-soft);
}

.passport__fields {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px 24px;
  margin: 28px 0 0;
}

.passport__fields div {
  min-width: 0;
}

.passport__fields dt {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.passport__fields dt .hindi {
  text-transform: none;
  letter-spacing: 0;
}

.passport__fields dd {
  margin: 4px 0 0;
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--navy-900);
}

.passport__fields dd.is-status {
  color: var(--stamp-red);
}

.passport .stamp {
  position: absolute;
  right: clamp(16px, 5vw, 64px);
  top: clamp(8px, 2vw, 28px);
  z-index: 2;
}

.passport__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

/* Machine-readable zone */
.passport__mrz {
  position: relative;
  z-index: 1;
  padding: 18px clamp(22px, 4vw, 48px) 26px;
  border-top: 1px solid rgba(20, 34, 74, 0.12);
  background: rgba(255, 255, 255, 0.5);
  font-family: var(--font-mono);
  /* 44-character MRZ lines must never wrap: each glyph advances ~0.66em
     (0.6em mono + letter-spacing), so 44 chars ≈ 29em of the card width. */
  font-size: min(1.1rem, calc((100vw - 2 * var(--gutter) - 2 * clamp(22px, 4vw, 48px)) / 30));
  font-weight: 500;
  line-height: 1.55;
  letter-spacing: 0.06em;
  color: var(--navy-900);
  white-space: pre;
  overflow: hidden;
}

.passport__mrz span {
  display: block;
}

/* Perforated serial number down the right edge */
.passport__perf {
  position: absolute;
  right: 22px;
  top: 50%;
  z-index: 1;
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.4em;
  writing-mode: vertical-rl;
  transform: translateY(-50%);
  color: transparent;
  -webkit-text-stroke: 1px rgba(20, 34, 74, 0.22);
  pointer-events: none;
}

@media (max-width: 860px) {
  .passport__body {
    grid-template-columns: 150px 1fr;
  }

  .passport__fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .passport__perf {
    display: none;
  }
}

@media (max-width: 600px) {
  .passport__body {
    grid-template-columns: 1fr;
  }

  .passport__photo {
    flex-direction: row;
    align-items: center;
  }

  .passport__photo-frame {
    width: 96px;
    flex-shrink: 0;
  }

  .passport__signature {
    text-align: left;
  }

  .passport .stamp {
    top: auto;
    right: 18px;
    bottom: 18px;
    transform: rotate(-9deg) scale(0.78);
  }

  .js .passport .stamp.reveal.is-visible {
    transform: rotate(-9deg) scale(0.78);
  }

  .passport__body {
    padding-bottom: 120px;
  }

  .passport__actions .btn {
    flex: 1 1 100%;
  }
}

/* ---------- Visa cards (home page section links) ---------- */

.visa-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 18px;
}

/* Explicit steps (not auto-fit) so five cards never leave a lone orphan row */
@media (max-width: 1100px) {
  .visa-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .visa-card {
    grid-column: span 2;
  }

  .visa-card:nth-child(4) {
    grid-column: 2 / span 2;
  }
}

@media (max-width: 760px) {
  .visa-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .visa-card,
  .visa-card:nth-child(4) {
    grid-column: auto;
    min-height: 200px;
    padding: 18px;
  }

  .visa-card:last-child {
    grid-column: 1 / -1;
  }
}

.visa-card {
  --accent: var(--stamp-red);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 230px;
  padding: 22px;
  overflow: hidden;
  border-radius: var(--radius);
  background:
    url("../images/guilloche.svg"),
    rgba(255, 255, 255, 0.72);
  background-size: 480px 240px, auto;
  box-shadow: var(--shadow-sm), inset 0 0 0 1px rgba(255, 255, 255, 0.8);
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.visa-card::before {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1.5px dashed color-mix(in srgb, var(--accent) 45%, transparent);
  border-radius: 10px;
  pointer-events: none;
}

.visa-card:hover {
  transform: translateY(-6px) rotate(-0.6deg);
  box-shadow: var(--shadow);
}

.visa-card__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
}

.visa-card__icon {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  color: var(--accent);
  box-shadow: inset 0 0 0 4px rgba(255, 255, 255, 0.9), inset 0 0 0 5px color-mix(in srgb, var(--accent) 50%, transparent);
}

.visa-card__icon svg {
  width: 24px;
  height: 24px;
}

.visa-card__title {
  font-size: 1.2rem;
  letter-spacing: 0.06em;
}

.visa-card__meta {
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.visa-card__meta svg {
  width: 18px;
  height: 18px;
  color: var(--navy-800);
  transition: transform 0.3s var(--ease);
}

.visa-card:hover .visa-card__meta svg {
  transform: translateX(4px);
}

.visa-card--red {
  --accent: var(--stamp-red);
}
.visa-card--blue {
  --accent: var(--stamp-blue);
}
.visa-card--teal {
  --accent: var(--teal-600);
}
.visa-card--violet {
  --accent: var(--violet-500);
}
.visa-card--gold {
  --accent: var(--gold-600);
}

/* Icon defaults (inline Lucide-style line icons) */
.icon {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
