/* ==========================================================================
   DATABASE E-JOURNAL & LITERATUR ILMIAH - DEDICATED STYLESHEET
   Institut Kesehatan Karsa Husada Garut
   ========================================================================== */

.ejournal-section {
  padding: 3.5rem 0 5rem;
  background-color: var(--bg-body, #f8fafc);
}

/* Quick Stats Bar */
.ejournal-stats-bar {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.ejournal-stat-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: #ffffff;
  padding: 0.6rem 1.15rem;
  border-radius: 9999px;
  border: 1px solid var(--border-light, #e2e8f0);
  font-size: 0.825rem;
  color: var(--text-body, #334155);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.ejournal-stat-chip svg {
  color: #0284c7;
}

.ejournal-stat-chip strong {
  color: #0369a1;
  font-weight: 700;
}

/* Filter & Search Toolbar */
.filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.25rem;
  background: #ffffff;
  border: 1px solid var(--border-light, #e2e8f0);
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 2.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.category-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.tag-btn {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 0.45rem 0.95rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tag-btn:hover {
  background: #f1f5f9;
  color: #0f172a;
  border-color: #cbd5e1;
}

.tag-btn.active {
  background: #0284c7;
  border-color: #0284c7;
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.25);
}

.search-input-wrap {
  position: relative;
  min-width: 300px;
}

.search-input-wrap input {
  width: 100%;
  padding: 0.65rem 1rem 0.65rem 2.5rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 0.875rem;
  background: #ffffff;
  color: #1e293b;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search-input-wrap input:focus {
  border-color: #0284c7;
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

.search-input-wrap svg {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
}

/* Database Grid (3 Columns) */
.ejournal-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
  margin-bottom: 4rem;
}

.ejournal-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease;
  display: flex;
  flex-direction: column;
}

.ejournal-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 24px -6px rgba(0, 0, 0, 0.08), 0 4px 8px -2px rgba(0, 0, 0, 0.03);
  border-color: #0284c7;
}

/* Card Header Banner */
.ejournal-cover-wrap {
  padding: 1.5rem 1.5rem 1.25rem;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 125px;
  position: relative;
}

.ejournal-badge-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.ejournal-badge {
  background: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(6px);
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.ejournal-access-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.72rem;
  font-weight: 600;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.2);
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
}

.ejournal-cover-title {
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.35;
  color: #ffffff;
  margin: 0;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* Card Body */
.ejournal-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.ejournal-publisher-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8125rem;
  color: #0284c7;
  font-weight: 700;
  margin-bottom: 0.65rem;
}

.ejournal-category-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.85rem;
}

.category-pill {
  font-size: 0.6875rem;
  font-weight: 600;
  background: #f1f5f9;
  color: #475569;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
}

.ejournal-desc {
  font-size: 0.84rem;
  color: #475569;
  line-height: 1.55;
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

/* Guidance Box */
.ejournal-guide-box {
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  padding: 0.75rem 0.9rem;
  font-size: 0.75rem;
  color: #334155;
  line-height: 1.45;
  margin-bottom: 1.25rem;
  display: flex;
  gap: 0.5rem;
  align-items: flex-start;
}

.ejournal-guide-box svg {
  flex-shrink: 0;
  margin-top: 0.15rem;
  color: #0284c7;
}

/* Action Button */
.ejournal-actions {
  margin-top: auto;
  border-top: 1px solid #f1f5f9;
  padding-top: 1.15rem;
}

.btn-open-ejournal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.65rem 1.25rem;
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 700;
  border-radius: 8px;
  text-decoration: none;
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.25);
  transition: all 0.2s ease;
  border: none;
}

.btn-open-ejournal:hover {
  background: linear-gradient(135deg, #0369a1 0%, #075985 100%);
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35);
  transform: translateY(-1px);
  color: #ffffff;
}

/* Institutional Help & Procedure Section */
.ejournal-info-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 2.25rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
  margin-top: 2rem;
}

.ejournal-info-header {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #f1f5f9;
}

.ejournal-info-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: #f0f9ff;
  color: #0284c7;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ejournal-info-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 0.35rem;
}

.ejournal-info-subtitle {
  font-size: 0.875rem;
  color: #64748b;
  margin: 0;
}

.ejournal-steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.ejournal-step-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.5rem;
  position: relative;
}

.ejournal-step-number {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #0284c7;
  color: #ffffff;
  font-size: 0.8125rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.ejournal-step-content h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem;
}

.ejournal-step-content p {
  font-size: 0.8125rem;
  color: #475569;
  line-height: 1.6;
  margin: 0;
}

.ejournal-help-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  padding: 1.15rem 1.5rem;
  border-radius: 12px;
  font-size: 0.875rem;
  color: #334155;
  font-weight: 600;
}

.btn-help-contact {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #0284c7;
  color: #ffffff;
  padding: 0.5rem 1.15rem;
  border-radius: 8px;
  font-size: 0.8125rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-help-contact:hover {
  background: #0369a1;
  color: #ffffff;
}

/* Responsiveness */
@media (max-width: 1024px) {
  .ejournal-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .ejournal-steps-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .ejournal-grid {
    grid-template-columns: 1fr;
  }
  .filter-bar {
    flex-direction: column;
    align-items: stretch;
  }
  .search-input-wrap {
    min-width: 100%;
  }
  .ejournal-info-header {
    flex-direction: column;
    text-align: center;
  }
}
