/* Card Components & Badges */

/* Category Cards */
.grid-categories {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
  gap: 1.25rem;
  width: 100%;
  box-sizing: border-box;
}

.category-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: all 0.2s ease;
  cursor: pointer;
  position: relative;
  text-decoration: none;
  color: var(--text);
}

.category-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.cat-icon-wrap {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-light);
  color: var(--primary);
  font-size: 1.5rem;
}

.category-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
}

.category-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.cat-count-tag {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary);
  margin-top: auto;
}

/* Entity Cards (Banks, Cards, Schemes) */
.entity-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr));
  gap: 1.25rem;
  width: 100%;
  box-sizing: border-box;
}

.entity-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(1.15rem, 3vw, 1.5rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  position: relative;
  overflow: hidden;
  width: 100%;
  box-sizing: border-box;
  min-width: 0;
}

.entity-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.entity-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.5rem;
}

.entity-logo-box {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--primary);
}

.entity-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0.4rem 0 0.25rem;
  color: var(--text);
}

.entity-card-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.entity-card-specs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  background: var(--surface-subtle);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.85rem;
  font-size: 0.8rem;
  border: 1px solid var(--border);
}

.entity-card-specs div span:first-child {
  color: var(--text-muted);
  display: block;
  font-size: 0.725rem;
  text-transform: uppercase;
  font-weight: 600;
}

.entity-card-specs div span:last-child {
  font-weight: 700;
  color: var(--text);
}

/* Link Cards (Official vs Partner) */
.link-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.25rem;
}

.link-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.link-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.link-card.partner-style {
  border-top: 3px solid #d97706;
}

.link-card.official-style {
  border-top: 3px solid #059669;
}

.link-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.5rem;
}

.link-provider {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.link-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  justify-content: flex-end;
}

.link-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
  margin: 0.35rem 0 0.25rem;
}

.link-card-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.link-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  padding-top: 0.5rem;
  border-top: 1px dashed var(--border);
}

.link-disclosure-box {
  font-size: 0.75rem;
  color: #92400e;
  background: rgba(245, 158, 11, 0.08);
  border-left: 3px solid #d97706;
  padding: 0.4rem 0.6rem;
  border-radius: 2px;
  line-height: 1.4;
}

[data-theme="dark"] .link-disclosure-box {
  color: #fcd34d;
  background: rgba(245, 158, 11, 0.12);
}

.link-action-area {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: auto;
}

.link-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.55rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.15s ease;
  width: 100%;
  text-align: center;
  border: 1px solid transparent;
}

.link-btn-official {
  background: var(--primary);
  color: #fff;
}

.link-btn-official:hover {
  background: var(--primary-hover);
}

.link-btn-partner {
  background: #d97706;
  color: #fff;
}

.link-btn-partner:hover {
  background: #b45309;
}

.link-btn-placeholder {
  background: var(--surface-subtle);
  color: var(--text-muted);
  border: 1px dashed var(--border);
  cursor: default;
}

.link-btn-placeholder:hover {
  background: var(--surface-subtle);
  border-color: var(--text-muted);
}

/* Badges */
.badge-official {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.725rem;
  font-weight: 700;
  color: #065f46;
  background: #d1fae5;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

[data-theme="dark"] .badge-official {
  background: rgba(16, 185, 129, 0.2);
  color: #6ee7b7;
}

.badge-partner {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.725rem;
  font-weight: 700;
  color: #92400e;
  background: #fef3c7;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

[data-theme="dark"] .badge-partner {
  background: rgba(245, 158, 11, 0.2);
  color: #fcd34d;
}

.badge-affiliate {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.725rem;
  font-weight: 700;
  color: #0369a1;
  background: #e0f2fe;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

[data-theme="dark"] .badge-affiliate {
  background: rgba(56, 189, 248, 0.2);
  color: #7dd3fc;
}

.badge-cat {
  font-size: 0.725rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--surface-subtle);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

.badge-status {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
}

.badge-status.active { background: #dcfce7; color: #15803d; }
[data-theme="dark"] .badge-status.active { background: rgba(34, 197, 94, 0.2); color: #4ade80; }

.badge-status.placeholder { background: #fef3c7; color: #b45309; }
[data-theme="dark"] .badge-status.placeholder { background: rgba(245, 158, 11, 0.2); color: #fbbf24; }

.badge-status.inactive { background: #f1f5f9; color: #64748b; }
[data-theme="dark"] .badge-status.inactive { background: #334155; color: #94a3b8; }

.badge-status.needs-verification { background: #f3e8ff; color: #7e22ce; }
[data-theme="dark"] .badge-status.needs-verification { background: rgba(168, 85, 247, 0.2); color: #c084fc; }

/* Filter Pills */
.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.filter-pill {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.35rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  white-space: nowrap;
}

.filter-pill:hover {
  border-color: var(--primary);
  background: var(--surface);
}

.filter-pill.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 2px 4px rgba(2, 132, 199, 0.25);
}

.filter-count-badge {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.1rem 0.4rem;
  border-radius: 9999px;
  background: rgba(0, 0, 0, 0.08);
}

.filter-pill.active .filter-count-badge {
  background: rgba(255, 255, 255, 0.25);
  color: #fff;
}

/* 1500-2000 Words Comprehensive Guide Reader Styles */
.cc-read-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--border);
}

.btn-read-guide {
  flex: 1;
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.08), rgba(16, 185, 129, 0.08));
  border: 1px solid var(--primary);
  color: var(--primary);
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  transition: all 0.2s ease;
  text-align: center;
}

.btn-read-guide:hover {
  background: var(--primary);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.2);
}

.link-open-page {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  white-space: nowrap;
  transition: all 0.15s ease;
}

.link-open-page:hover {
  color: var(--primary);
  border-color: var(--primary);
  background: var(--surface-subtle);
}

/* Guide Reader Modal / Overlay */
.guide-reader-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(6px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.guide-reader-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.guide-reader-modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 100%;
  max-width: 860px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
  transform: translateY(20px) scale(0.98);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.guide-reader-overlay.active .guide-reader-modal {
  transform: translateY(0) scale(1);
}

.guide-reader-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.15rem 1.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--surface-subtle);
}

.guide-reader-title-area {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.guide-reader-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text);
  margin: 0;
}

.guide-reader-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.guide-reader-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.guide-reader-close-btn {
  background: none;
  border: 1px solid var(--border);
  color: var(--text);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.guide-reader-close-btn:hover {
  background: var(--danger);
  border-color: var(--danger);
  color: #fff;
}

.guide-reader-body {
  padding: 2rem 2.25rem;
  overflow-y: auto;
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--text);
}

.guide-reader-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border);
  background: var(--surface-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* Guide Content Elements */
.guide-meta-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.75rem;
  padding: 0.85rem 1.25rem;
  background: rgba(2, 132, 199, 0.08);
  border-left: 4px solid var(--primary);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.guide-word-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--primary);
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: 9999px;
}

.guide-verified-badge {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--success);
}

.guide-sec {
  margin-bottom: 2.25rem;
}

.guide-sec h2 {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 1rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--border);
}

.guide-sec h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin-top: 1.25rem;
  margin-bottom: 0.75rem;
}

.guide-sec p {
  margin-bottom: 1rem;
  color: var(--text);
}

.guide-highlight-box {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.25rem 1.5rem;
  margin: 1.25rem 0;
}

.guide-highlight-box ul {
  margin: 0;
  padding-left: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.guide-warning-box {
  background: rgba(239, 68, 68, 0.08);
  border-left: 4px solid var(--danger);
  padding: 1.25rem 1.5rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 1.25rem 0;
}

.guide-warning-box h4 {
  color: var(--danger);
  margin-bottom: 0.5rem;
  font-size: 1.05rem;
  font-weight: 700;
}

.guide-example-box {
  background: rgba(16, 185, 129, 0.08);
  border-left: 4px solid var(--success);
  padding: 1.25rem 1.5rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 1.25rem 0;
}

.guide-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.25rem 0;
  font-size: 0.95rem;
}

.guide-table th {
  background: var(--surface-subtle);
  color: var(--text);
  font-weight: 700;
  text-align: left;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
}

.guide-table td {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  color: var(--text);
}

.guide-table tr.highlight-row td {
  background: rgba(2, 132, 199, 0.08);
  font-weight: 700;
}

.guide-list {
  padding-left: 1.25rem;
  margin: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.guide-steps {
  padding-left: 1.25rem;
  margin: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.guide-pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin: 1.25rem 0;
}

@media (max-width: 700px) {
  .guide-pros-cons {
    grid-template-columns: 1fr;
  }
}

.guide-pros {
  background: rgba(16, 185, 129, 0.06);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-sm);
  padding: 1.25rem;
}

.guide-pros h4 {
  color: var(--success);
  margin-bottom: 0.75rem;
  font-weight: 700;
}

.guide-pros ul, .guide-cons ul {
  padding-left: 1.25rem;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.guide-cons {
  background: rgba(239, 68, 68, 0.06);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-sm);
  padding: 1.25rem;
}

.guide-cons h4 {
  color: var(--danger);
  margin-bottom: 0.75rem;
  font-weight: 700;
}

.guide-faq-item {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.15rem 1.25rem;
  margin-bottom: 1rem;
}

.guide-faq-item h4 {
  color: var(--primary);
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.guide-faq-item p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
}

