/* IFSC Code Finder — hero & tool widget */
.ifsc-page {
  --ifsc-navy: #061a31;
  --ifsc-navy-2: #0b2947;
  --ifsc-coral: #f45f58;
  --ifsc-coral-dark: #d94a44;
  --ifsc-ink: #10243a;
  --ifsc-muted: #5c6f82;
  --ifsc-line: #d9e2ea;
  --ifsc-green: #16825c;
  --ifsc-green-soft: #eaf7f1;
  --ifsc-amber: #9e650f;
  --ifsc-amber-soft: #fff7e8;
  --ifsc-red: #bd3f39;
  --ifsc-red-soft: #fff0ef;
  --ifsc-shadow: 0 24px 70px rgba(4, 24, 46, 0.18);
}

.ifsc-page .hero-tool {
  position: relative;
  min-height: calc(100svh - 58px);
  display: flex;
  align-items: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 92% 8%, rgba(54, 107, 155, 0.36), transparent 32%),
    linear-gradient(135deg, var(--ifsc-navy) 0%, #081f39 58%, #0b2d50 100%);
  color: #fff;
}

.ifsc-page .grid-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.22;
  pointer-events: none;
  color: #fff;
}

.ifsc-page .page-shell {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1850px;
  margin-inline: auto;
  padding-block: 36px 36px;
  padding-inline: clamp(24px, 5vw, 96px);
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.25fr);
  gap: clamp(34px, 5vw, 72px);
  align-items: center;
}

.ifsc-page .kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #ffaaa6;
  font-size: 0.69rem;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.ifsc-page .kicker:before {
  content: "";
  width: 28px;
  height: 2px;
  background: var(--ifsc-coral);
}

.ifsc-page .intro h1 {
  max-width: 520px;
  margin: 0;
  font-size: clamp(2.55rem, 4.8vw, 4.8rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
  font-weight: 800;
  text-align: left;
  word-spacing: normal;
}

.ifsc-page .intro h1 span {
  color: #ff817a;
}

.ifsc-page .intro-copy {
  max-width: 545px;
  margin: 19px 0 0;
  color: #c8d6e4;
  font-size: 0.94rem;
  line-height: 1.68;
}

.ifsc-page .proof {
  display: flex;
  flex-wrap: wrap;
  gap: 11px 18px;
  margin-top: 21px;
  color: #c6d5e3;
  font-size: 0.72rem;
  font-weight: 650;
}

.ifsc-page .proof span {
  display: flex;
  align-items: center;
  gap: 7px;
}

.ifsc-page .proof svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: #57dda1;
  stroke-width: 2.4;
}

.ifsc-page .scope-note {
  margin-top: 23px;
  padding: 13px 15px;
  max-width: 550px;
  border-left: 3px solid var(--ifsc-coral);
  background: rgba(255, 255, 255, 0.07);
  color: #bdccda;
  font-size: 0.68rem;
  line-height: 1.55;
}

.ifsc-page .tool {
  min-width: 0;
  max-width: 100%;
  min-height: 610px;
  background: #fff;
  color: var(--ifsc-ink);
  box-shadow: var(--ifsc-shadow);
  border-top: 4px solid var(--ifsc-coral);
  display: grid;
  grid-template-rows: auto auto 1fr auto auto;
}

.ifsc-page .tool-head {
  padding: 16px 18px 14px;
  border-bottom: 1px solid var(--ifsc-line);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.ifsc-page .tool-head small {
  display: block;
  color: var(--ifsc-coral-dark);
  font-size: 0.61rem;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 3px;
}

.ifsc-page .tool-head h2 {
  margin: 0;
  font-size: 1.1rem;
  letter-spacing: -0.025em;
  color: var(--ifsc-ink);
  text-align: left;
}

.ifsc-page .live-badge {
  padding: 7px 9px;
  background: var(--ifsc-green-soft);
  color: var(--ifsc-green);
  font-size: 0.59rem;
  font-weight: 850;
  align-self: flex-start;
  white-space: nowrap;
}

.ifsc-page .search-pane {
  padding: 18px;
  border-bottom: 1px solid var(--ifsc-line);
  background: #f8fafb;
}

.ifsc-page .search-label {
  display: block;
  margin-bottom: 6px;
  color: var(--ifsc-muted);
  font-size: 0.54rem;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.ifsc-page .search-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.ifsc-page .search-input {
  height: 47px;
  width: 100%;
  border: 1px solid #cbd6df;
  padding: 0 14px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 800;
  font-size: 0.88rem;
  outline: none;
  border-radius: 0;
  color: var(--ifsc-ink);
  background: #fff;
}

.ifsc-page .search-input:focus {
  border-color: var(--ifsc-coral);
  box-shadow: 0 0 0 3px rgba(244, 95, 88, 0.1);
}

.ifsc-page .search-btn {
  min-width: 120px;
  border: 1px solid var(--ifsc-coral);
  background: var(--ifsc-coral);
  color: #fff;
  font-weight: 800;
  font-size: 0.72rem;
  padding: 0 18px;
  cursor: pointer;
}

.ifsc-page .search-btn:hover {
  background: var(--ifsc-coral-dark);
}

.ifsc-page .search-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.ifsc-page .search-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 7px;
  color: var(--ifsc-muted);
  font-size: 0.52rem;
}

.ifsc-page .search-meta button {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ifsc-coral-dark);
  font-weight: 800;
  cursor: pointer;
}

.ifsc-page .result-pane {
  padding: 18px;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.ifsc-page .empty-state {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 300px;
  padding: 30px;
  color: var(--ifsc-muted);
}

.ifsc-page .empty-icon {
  width: 66px;
  height: 66px;
  margin-bottom: 14px;
  border: 1px solid var(--ifsc-line);
  display: grid;
  place-items: center;
  background: #f8fafb;
}

.ifsc-page .empty-icon svg {
  width: 32px;
  height: 32px;
  fill: none;
  stroke: var(--ifsc-navy-2);
  stroke-width: 1.7;
}

.ifsc-page .empty-state h3 {
  margin: 0;
  color: var(--ifsc-ink);
  font-size: 0.94rem;
}

.ifsc-page .empty-state p {
  max-width: 390px;
  margin: 7px auto 0;
  font-size: 0.65rem;
  line-height: 1.55;
}

.ifsc-page .error-state {
  display: none;
  padding: 12px;
  border: 1px solid #efc9c6;
  background: var(--ifsc-red-soft);
  color: var(--ifsc-red);
  font-size: 0.62rem;
  line-height: 1.5;
  margin-bottom: 10px;
}

.ifsc-page .branch-result {
  display: none;
}

.ifsc-page .branch-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.ifsc-page .bank-kicker {
  color: var(--ifsc-coral-dark);
  font-size: 0.54rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ifsc-page .branch-top h3 {
  margin: 4px 0 0;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
  color: var(--ifsc-ink);
  text-align: left;
}

.ifsc-page .ifsc-chip {
  padding: 8px 10px;
  background: var(--ifsc-navy-2);
  color: #fff;
  font-size: 0.67rem;
  font-weight: 850;
  letter-spacing: 0.07em;
  white-space: nowrap;
}

.ifsc-page .details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 14px;
}

.ifsc-page .detail {
  padding: 10px;
  border: 1px solid var(--ifsc-line);
  background: #fff;
}

.ifsc-page .detail.full {
  grid-column: 1 / -1;
}

.ifsc-page .detail small {
  display: block;
  color: var(--ifsc-muted);
  font-size: 0.47rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 800;
}

.ifsc-page .detail strong {
  display: block;
  margin-top: 4px;
  font-size: 0.66rem;
  line-height: 1.45;
  word-break: break-word;
  color: var(--ifsc-ink);
}

.ifsc-page .networks {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  margin-top: 10px;
}

.ifsc-page .network {
  padding: 8px 4px;
  border: 1px solid var(--ifsc-line);
  text-align: center;
  color: var(--ifsc-muted);
  font-size: 0.49rem;
  font-weight: 850;
  line-height: 1.3;
}

.ifsc-page .network.yes {
  border-color: #c6e6d7;
  background: var(--ifsc-green-soft);
  color: var(--ifsc-green);
}

.ifsc-page .network.no {
  background: #f5f6f7;
  color: #929da7;
}

.ifsc-page .result-note {
  margin-top: 10px;
  padding: 9px 10px;
  border: 1px solid #eed5a8;
  background: var(--ifsc-amber-soft);
  color: #76500f;
  font-size: 0.52rem;
  line-height: 1.45;
}

.ifsc-page .actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 10px;
}

.ifsc-page .actions button,
.ifsc-page .actions a {
  min-height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ifsc-line);
  background: #fff;
  color: var(--ifsc-ink);
  text-decoration: none;
  font-size: 0.57rem;
  font-weight: 800;
  cursor: pointer;
}

.ifsc-page .actions a {
  grid-column: 1 / -1;
  background: var(--ifsc-coral);
  border-color: var(--ifsc-coral);
  color: #fff;
}

.ifsc-page .actions a:hover {
  background: var(--ifsc-coral-dark);
  color: #fff;
}

.ifsc-page .history {
  padding: 11px 18px;
  border-top: 1px solid var(--ifsc-line);
  background: #f8fafb;
}

.ifsc-page .history-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.ifsc-page .history-head strong {
  font-size: 0.57rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ifsc-ink);
}

.ifsc-page .history-head button {
  border: 0;
  background: transparent;
  color: var(--ifsc-coral-dark);
  font-size: 0.51rem;
  font-weight: 800;
  cursor: pointer;
}

.ifsc-page .history-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 7px;
}

.ifsc-page .history-item {
  border: 1px solid var(--ifsc-line);
  background: #fff;
  padding: 6px 8px;
  color: var(--ifsc-ink);
  font-size: 0.53rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  cursor: pointer;
}

.ifsc-page .tool-foot {
  padding: 10px 18px;
  border-top: 1px solid var(--ifsc-line);
  display: flex;
  justify-content: space-between;
  gap: 14px;
  color: var(--ifsc-muted);
  font-size: 0.5rem;
}

.ifsc-page .tool-foot strong {
  color: var(--ifsc-ink);
}

@media (max-width: 1040px) {
  .ifsc-page .hero-tool {
    min-height: auto;
  }

  .ifsc-page .page-shell {
    grid-template-columns: 1fr;
    padding-block: 42px;
    padding-inline: clamp(24px, 5vw, 96px);
  }

  .ifsc-page .intro h1,
  .ifsc-page .intro-copy {
    max-width: 760px;
  }
}

@media (max-width: 680px) {
  .ifsc-page .page-shell {
    padding-inline: clamp(16px, 4vw, 24px);
    padding-block: 25px;
    gap: 26px;
  }

  .ifsc-page .intro h1 {
    font-size: 2.3rem;
  }

  .ifsc-page .intro-copy {
    font-size: 0.85rem;
  }

  .ifsc-page .scope-note {
    display: none;
  }

  .ifsc-page .search-row {
    grid-template-columns: 1fr;
  }

  .ifsc-page .search-btn {
    height: 43px;
  }

  .ifsc-page .details-grid {
    grid-template-columns: 1fr;
  }

  .ifsc-page .detail.full {
    grid-column: auto;
  }

  .ifsc-page .networks {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 460px) {
  .ifsc-page .intro h1 {
    font-size: 2rem;
  }

  .ifsc-page .tool-head,
  .ifsc-page .search-pane,
  .ifsc-page .result-pane {
    padding-left: 13px;
    padding-right: 13px;
  }

  .ifsc-page .live-badge {
    display: none;
  }

  .ifsc-page .branch-top {
    flex-direction: column;
  }

  .ifsc-page .actions {
    grid-template-columns: 1fr;
  }

  .ifsc-page .actions a {
    grid-column: auto;
  }

  .ifsc-page .tool-foot {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ifsc-page * {
    animation: none !important;
    transition: none !important;
  }
}
