/* ==============================================
   Bank IFSC Finder — assets/style.css  v1.0.0
   ============================================== */

:root {
  --if-dark:   #0A0E1A;
  --if-card:   #111827;
  --if-text:   #F1F5FF;
  --if-muted:  #7B82A0;
  --if-border: rgba(255,255,255,0.08);
  --if-amber:  #FFB830;
  --if-sky:    #00C2FF;
  --if-green:  #22C55E;
  --if-coral:  #FF5252;
  --if-indigo: #4F46E5;
  --if-lime:   #A3E635;
  --if-rad:    14px;
}

.if-app *, .if-app *::before, .if-app *::after { box-sizing: border-box; }
.if-app { font-family: 'Segoe UI', system-ui, sans-serif; color: var(--if-text); line-height: 1.6; }
.if-app em { font-style: normal; }

/* ── HERO ── */
.if-hero {
  position: relative;
  background: var(--if-dark);
  border-radius: 24px;
  padding: 60px 28px 50px;
  text-align: center;
  overflow: hidden;
  margin-bottom: 28px;
}

.if-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: .2;
  animation: if-drift 10s ease-in-out infinite alternate;
}
.if-b1 { width:350px;height:350px;background:var(--if-indigo);top:-100px;left:-80px;animation-delay:0s; }
.if-b2 { width:260px;height:260px;background:var(--if-amber); top:20px;right:-60px;animation-delay:3s; }
.if-b3 { width:200px;height:200px;background:var(--if-sky);  bottom:-60px;left:45%;animation-delay:6s; }

@keyframes if-drift {
  from { transform: translate(0,0) scale(1); }
  to   { transform: translate(20px,28px) scale(1.1); }
}

.if-hero-inner { position: relative; z-index: 1; }

.if-badge {
  display: inline-block;
  background: rgba(255,184,48,.12);
  border: 1px solid rgba(255,184,48,.35);
  color: var(--if-amber);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: 5px 16px;
  border-radius: 100px;
  margin-bottom: 20px;
}

.if-h2 {
  font-size: clamp(1.9rem, 5.5vw, 3.8rem);
  font-weight: 900;
  line-height: 1.1;
  margin: 0 0 14px;
  color: var(--if-text);
}
.if-amber { color: var(--if-amber); }
.if-sky   { color: var(--if-sky); }

.if-sub {
  color: var(--if-muted);
  font-size: .95rem;
  max-width: 520px;
  margin: 0 auto 32px;
  line-height: 1.65;
}

/* ── TABS ── */
.if-tabs {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.if-tab {
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  color: var(--if-muted);
  font-size: .85rem;
  font-weight: 600;
  padding: 9px 22px;
  border-radius: 100px;
  cursor: pointer;
  transition: all .2s;
}
.if-tab:hover, .if-tab.if-tab-on {
  background: var(--if-indigo);
  border-color: var(--if-indigo);
  color: #fff;
}

.if-tab-pane { max-width: 620px; margin: 0 auto; }

/* ── SEARCH BOX ── */
.if-search-box {
  display: flex;
  align-items: center;
  background: rgba(255,255,255,.06);
  border: 1.5px solid rgba(255,255,255,.12);
  border-radius: 16px;
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
}
.if-search-box:focus-within {
  border-color: var(--if-sky);
  box-shadow: 0 0 0 3px rgba(0,194,255,.14);
}

.if-sicon { padding: 0 0 0 18px; font-size: 1.1rem; }

.if-input {
  flex: 1;
  background: transparent !important;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  color: var(--if-text) !important;
  font-size: 1rem !important;
  padding: 16px 12px !important;
  letter-spacing: .05em;
  font-weight: 600;
}
.if-input::placeholder { color: var(--if-muted); font-weight: 400; letter-spacing: 0; }

.if-hint {
  color: var(--if-muted);
  font-size: .78rem;
  margin-top: 10px;
  opacity: .7;
}

/* ── BUTTON ── */
.if-btn {
  background: linear-gradient(135deg, var(--if-amber), var(--if-indigo));
  border: none;
  color: #fff;
  font-weight: 700;
  font-size: .9rem;
  padding: 0 26px;
  height: 54px;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: opacity .2s, transform .1s;
  border-radius: 0;
}
.if-btn:hover   { opacity: .88; }
.if-btn:active  { transform: scale(.97); }
.if-btn:disabled { opacity: .35; cursor: not-allowed; }

/* browse btn standalone */
.if-browse-btn-wrap .if-btn {
  height: 46px;
  padding: 0 28px;
  border-radius: 12px;
}

/* ── BROWSE GRID ── */
.if-browse-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

@media (max-width: 580px) {
  .if-browse-grid { grid-template-columns: 1fr; }
}

.if-field-wrap { text-align: left; }

.if-label {
  display: block;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--if-muted);
  margin-bottom: 6px;
}

.if-sel {
  width: 100%;
  background: rgba(255,255,255,.06) !important;
  border: 1.5px solid rgba(255,255,255,.12) !important;
  border-radius: 11px !important;
  color: var(--if-text) !important;
  font-size: .9rem !important;
  padding: 11px 14px !important;
  outline: none !important;
  cursor: pointer;
  transition: border-color .2s, box-shadow .2s;
  appearance: auto;
}
.if-sel:focus {
  border-color: var(--if-sky) !important;
  box-shadow: 0 0 0 3px rgba(0,194,255,.12) !important;
}
.if-sel:disabled { opacity: .38; cursor: not-allowed; }
.if-sel option { background: #1a2035; }

/* ── STATS ── */
.if-stats {
  display: flex;
  justify-content: center;
  gap: 36px;
  margin-top: 38px;
  flex-wrap: wrap;
}
.if-stat { text-align: center; }
.if-sn {
  font-size: 1.7rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--if-amber), var(--if-sky));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.if-sl { color: var(--if-muted); font-size: .75rem; margin-top: 2px; }

/* ── STATUS ── */
.if-status {
  background: var(--if-card);
  border: 1px solid var(--if-border);
  border-radius: var(--if-rad);
  padding: 16px 22px;
  text-align: center;
  color: var(--if-muted);
  margin-bottom: 24px;
}
.if-status.if-loading::before {
  content: '';
  display: inline-block;
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,.15);
  border-top-color: var(--if-sky);
  border-radius: 50%;
  animation: if-spin .7s linear infinite;
  vertical-align: middle;
  margin-right: 10px;
}
@keyframes if-spin { to { transform: rotate(360deg); } }
.if-status.if-err { border-color: rgba(255,82,82,.35); color: var(--if-coral); }

/* ── RESULT CARD ── */
.if-result {
  background: var(--if-dark);
  border-radius: 20px;
  padding: 28px;
  animation: if-up .35s ease both;
}

@keyframes if-up {
  from { opacity:0; transform:translateY(14px); }
  to   { opacity:1; transform:translateY(0); }
}

/* Top bar */
.if-res-top {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.if-bank-logo {
  width: 58px; height: 58px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--if-indigo), #1e3a8a);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  flex-shrink: 0;
}

.if-res-meta { flex: 1; }
.if-res-bank { font-size: 1.2rem; font-weight: 900; color: var(--if-text); }
.if-res-branch { color: var(--if-muted); font-size: .9rem; margin-top: 3px; }

.if-ifsc-pill {
  background: linear-gradient(135deg, var(--if-amber), var(--if-indigo));
  color: #fff;
  font-family: 'Courier New', monospace;
  font-size: 1rem;
  font-weight: 700;
  padding: 8px 20px;
  border-radius: 10px;
  letter-spacing: .08em;
  cursor: pointer;
  border: none;
  transition: opacity .2s;
  position: relative;
}
.if-ifsc-pill:hover { opacity: .88; }
.if-copied {
  position: absolute;
  bottom: -28px;
  left: 50%;
  transform: translateX(-50%);
  font-size: .72rem;
  background: var(--if-green);
  color: #000;
  padding: 3px 10px;
  border-radius: 6px;
  white-space: nowrap;
  animation: if-fade 1.5s ease forwards;
}
@keyframes if-fade {
  0%   { opacity:1; }
  70%  { opacity:1; }
  100% { opacity:0; }
}

/* Detail grid */
.if-detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}

.if-detail-cell {
  background: rgba(255,255,255,.04);
  border: 1px solid var(--if-border);
  border-radius: 11px;
  padding: 12px 14px;
}
.if-dl { font-size: .65rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--if-muted); margin-bottom: 3px; }
.if-dv { font-size: .9rem; font-weight: 600; color: var(--if-text); word-break: break-word; }

/* Address block */
.if-address {
  background: rgba(255,255,255,.04);
  border: 1px solid var(--if-border);
  border-radius: 11px;
  padding: 14px 16px;
  margin-bottom: 18px;
}
.if-address-label { font-size: .65rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--if-muted); margin-bottom: 6px; }
.if-address-val   { font-size: .9rem; color: var(--if-text); line-height: 1.55; }

/* Services row */
.if-services {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.if-svc {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 9px;
  font-size: .8rem;
  font-weight: 700;
}
.if-svc-on  { background: rgba(34,197,94,.15);  color: var(--if-green); border: 1px solid rgba(34,197,94,.25); }
.if-svc-off { background: rgba(255,82,82,.1);   color: var(--if-coral); border: 1px solid rgba(255,82,82,.2); opacity: .55; }
.if-svc-dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.if-svc-on  .if-svc-dot { background: var(--if-green); }
.if-svc-off .if-svc-dot { background: var(--if-coral); }

/* Contact / MICR / SWIFT row */
.if-extra-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.if-extra-pill {
  background: rgba(255,255,255,.05);
  border: 1px solid var(--if-border);
  border-radius: 8px;
  padding: 7px 13px;
  font-size: .8rem;
  color: var(--if-muted);
}
.if-extra-pill span { color: var(--if-text); font-weight: 600; margin-left: 4px; }

/* ── RESPONSIVE ── */
@media (max-width: 600px) {
  .if-hero   { padding: 40px 14px 32px; }
  .if-stats  { gap: 20px; }
  .if-result { padding: 16px 12px; }
  .if-res-top { flex-direction: column; align-items: flex-start; }
}
