/* Support & Resources — Resource Bank (TES-inspired catalog) */

.hub-rb-hero {
  background: linear-gradient(135deg, var(--corp-midnight, #0f1f4d) 0%, #1a3278 55%, #243d8f 100%);
  color: #fff;
  padding: 2rem 1.5rem 2.5rem;
  margin: 0 0 1.5rem;
  border-radius: 0 0 12px 12px;
  position: relative;
  overflow: hidden;
}

.hub-rb-hero::after {
  content: "";
  position: absolute;
  top: -20%;
  right: -5%;
  width: 42%;
  max-width: 280px;
  aspect-ratio: 1;
  background: conic-gradient(
    from 200deg,
    #c4f542 0deg 55deg,
    #f4a4c8 55deg 110deg,
    #9b8cff 110deg 165deg,
    #5ec8f8 165deg 220deg,
    #ffe566 220deg 280deg,
    transparent 280deg
  );
  opacity: 0.35;
  clip-path: polygon(50% 0%, 100% 38%, 82% 100%, 18% 100%, 0% 38%);
}

.hub-rb-hero-inner {
  position: relative;
  z-index: 1;
  max-width: 52rem;
}

.hub-rb-hero-kicker {
  font-size: 0.7rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: #c4f542;
  margin: 0 0 0.5rem;
  font-weight: 700;
}

.hub-rb-hero h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  color: #fff;
}

.hub-rb-hero-lead {
  margin: 0 0 1.25rem;
  font-size: 1rem;
  opacity: 0.92;
  max-width: 36rem;
}

.hub-rb-search-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: stretch;
}

.hub-rb-search {
  flex: 1 1 12rem;
  min-width: 0;
  display: flex;
  align-items: center;
  background: #fff;
  border-radius: 6px;
  padding: 0 0.75rem;
}

.hub-rb-search input {
  flex: 1;
  border: none;
  padding: 0.75rem 0.5rem;
  font-size: 1rem;
  background: transparent;
  color: #1a1a2e;
}

.hub-rb-search input:focus {
  outline: 2px solid var(--corp-deep-blue, #2563eb);
  outline-offset: 2px;
}

.hub-rb-search-btn {
  flex: 0 0 auto;
  white-space: nowrap;
}

.hub-rb-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.hub-rb-count {
  font-size: 0.85rem;
  color: var(--corp-stone, #5c6478);
}

.hub-rb-gate {
  padding: 1rem 1.25rem;
  background: var(--corp-pale, #f4f6fb);
  border: 1px solid rgba(15, 31, 77, 0.12);
  border-radius: 8px;
  margin-bottom: 1.25rem;
}

.hub-rb-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(11.5rem, 1fr));
  gap: 1rem;
}

@media (min-width: 900px) {
  .hub-rb-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

.hub-rb-card {
  background: #fff;
  border: 1px solid rgba(15, 31, 77, 0.1);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.hub-rb-card:hover {
  box-shadow: 0 8px 24px rgba(15, 31, 77, 0.12);
  transform: translateY(-2px);
}

.hub-rb-card-thumb {
  aspect-ratio: 4 / 3;
  background: linear-gradient(145deg, #e8ecf8 0%, #d0d8ef 100%);
  background-size: cover;
  background-position: center;
}

.hub-rb-card-thumb--pdf {
  background: linear-gradient(145deg, #fde8e8 0%, #f5c4c4 100%);
}

.hub-rb-card-thumb--docx {
  background: linear-gradient(145deg, #e8f0fd 0%, #b8d4f8 100%);
}

.hub-rb-card-thumb--pptx {
  background: linear-gradient(145deg, #fff4e0 0%, #ffd9a8 100%);
}

.hub-rb-card-thumb--image {
  background: linear-gradient(145deg, #e8f8ef 0%, #b8e8d0 100%);
}

.hub-rb-card-body {
  padding: 0.85rem 0.9rem 1rem;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 0.35rem;
}

.hub-rb-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.hub-rb-card-category {
  color: var(--corp-stone, #5c6478);
  font-weight: 600;
}

.hub-rb-card-badge {
  font-weight: 700;
  color: var(--corp-deep-blue, #2563eb);
}

.hub-rb-card-title {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.35;
  font-weight: 600;
  color: var(--corp-midnight, #0f1f4d);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hub-rb-card-desc {
  margin: 0;
  font-size: 0.72rem;
  color: var(--corp-stone, #5c6478);
  line-height: 1.4;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hub-rb-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem;
}

.hub-rb-card-tag {
  font-size: 0.6rem;
  padding: 0.1rem 0.35rem;
  background: rgba(15, 31, 77, 0.06);
  border-radius: 3px;
}

.hub-rb-card-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.68rem;
  margin-top: 0.25rem;
}

.hub-rb-card-author {
  color: var(--corp-deep-blue, #2563eb);
  text-decoration: none;
  font-weight: 600;
}

.hub-rb-card-author:hover {
  text-decoration: underline;
}

.hub-rb-card-lang {
  text-transform: uppercase;
  color: var(--corp-stone, #5c6478);
}

.hub-rb-card-actions {
  margin-top: 0.5rem;
}

.hub-rb-card-dl {
  width: 100%;
  font-size: 0.72rem;
  padding: 0.4rem 0.5rem;
}

.hub-rb-card-locked {
  font-size: 0.65rem;
  color: var(--corp-stone, #5c6478);
  line-height: 1.3;
}

.hub-rb-pager {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: center;
  margin-top: 1.5rem;
}

.hub-rb-pager-btn {
  min-width: 2.25rem;
  padding: 0.35rem 0.5rem;
  border: 1px solid rgba(15, 31, 77, 0.2);
  background: #fff;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.85rem;
}

.hub-rb-pager-btn.is-active {
  background: var(--corp-midnight, #0f1f4d);
  color: #fff;
  border-color: var(--corp-midnight, #0f1f4d);
}

.hub-rb-upload {
  padding: 1.25rem;
  background: rgba(15, 31, 77, 0.04);
  border: 1px solid rgba(15, 31, 77, 0.1);
  border-radius: 10px;
  margin-bottom: 1.5rem;
}

.hub-rb-upload-title {
  margin: 0 0 0.35rem;
  font-size: 1.1rem;
}

.hub-rb-upload-lead {
  margin: 0 0 1rem;
  font-size: 0.9rem;
}

.hub-rb-upload-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem 1rem;
}

.hub-rb-upload-grid label {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.8rem;
  font-weight: 600;
}

.hub-rb-span-2 {
  grid-column: 1 / -1;
}

.hub-rb-req {
  color: #c0392b;
}

.hub-rb-topic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr));
  gap: 0.35rem;
  max-height: 12rem;
  overflow-y: auto;
  padding: 0.5rem;
  background: #fff;
  border: 1px solid rgba(15, 31, 77, 0.12);
  border-radius: 6px;
}

.hub-rb-tag-check {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 400;
  font-size: 0.75rem;
}

.hub-rb-file-hint {
  font-weight: 400;
  font-size: 0.72rem;
  color: var(--corp-stone, #5c6478);
}

.hub-rb-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 2rem;
}

.hub-rb-grid--profile {
  margin-top: 0.75rem;
}

@media (max-width: 640px) {
  .hub-rb-upload-grid {
    grid-template-columns: 1fr;
  }
  .hub-rb-span-2 {
    grid-column: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hub-rb-card:hover {
    transform: none;
  }
}
