/* ── Hero ───────────────────────────────────────────────────── */
/* section.hero beats Bootstrap's generic resets regardless of load order */
section.hero {
  background: var(--wcm-orange);
  min-height: 86vh;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center;
  text-align: center !important;
  padding: 60px 24px !important;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    -45deg,
    rgba(0,0,0,0.04) 0px,
    rgba(0,0,0,0.04) 1px,
    transparent 1px,
    transparent 14px
  );
  pointer-events: none;
}

/* Text-based logo (no SVG clipping issues) */
.hero__logo-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 32px;
  gap: 6px;
}

.hero__institution {
  font-family: var(--font-brand);
  font-size: clamp(1.1rem, 2.5vw, 1.6rem);
  font-weight: 700;
  color: white;
  letter-spacing: 0.15em;
}

.hero__divider {
  display: block;
  width: 80px;
  height: 1px;
  background: rgba(255,255,255,0.4);
  margin: 4px 0;
}

.hero__unit {
  font-family: var(--font-brand);
  font-size: clamp(0.85rem, 1.8vw, 1.1rem);
  color: rgba(255,255,255,0.75);
  letter-spacing: 0.1em;
}

.hero__title {
  font-family: var(--font-brand);
  font-size: clamp(2.2rem, 5.5vw, 3.8rem);
  color: white;
  margin: 0 0 32px;
  font-weight: 700;
  line-height: 1.1;
}

.hero__terminal {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--term-color, #c8ffc8);
  background: rgba(0,0,0,0.35);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 6px;
  padding: 12px 28px;
  margin-bottom: 36px;
  display: inline-block;
  min-width: 300px;
  text-align: left;
}

.hero__terminal .prompt { color: rgba(255,255,255,0.5); }
.hero__terminal .cursor {
  display: inline-block;
  width: 8px; height: 1em;
  background: var(--term-color, #c8ffc8);
  vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}

@keyframes blink { 0%,100% { opacity:1; } 50% { opacity:0; } }

.hero__ctas { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }
.hero--no-ctas { min-height: 68vh; padding: 44px 24px 52px; }

.btn-primary-wcm,
.btn-secondary-wcm {
  background: white;
  color: var(--wcm-red);
  border: 2px solid white;
  padding: 13px 32px;
  font-family: var(--font-brand);
  font-size: 1rem;
  font-weight: 700;
  border-radius: var(--radius);
  text-decoration: none;
  transition: all var(--transition);
  display: inline-block;
}

.btn-primary-wcm:hover,
.btn-secondary-wcm:hover {
  background: var(--wcm-red);
  border-color: var(--wcm-red);
  color: white;
  transform: translateY(-2px);
}

/* ── btn-primary-wcm in form/admin context (used with Bootstrap .btn) ── */
/* The hero version is used as a standalone <a>; forms use class="btn btn-primary-wcm".
   Override to match navbar-scale sizing instead of inheriting hero CTA dimensions.  */
.btn.btn-primary-wcm,
.btn.btn-secondary-wcm {
  padding: 5px 14px;
  font-size: 0.82rem;
  border-width: 1.5px;
  transform: none !important;
  background: var(--wcm-red);
  border-color: var(--wcm-red);
  color: #fff;
}
.btn.btn-primary-wcm:hover,
.btn.btn-secondary-wcm:hover {
  background: #a8000e;
  border-color: #a8000e;
  color: #fff;
  transform: none !important;
}

/* ── Infrastructure section ─────────────────────────────────── */
.infra-section { background: var(--surface-alt); }
.section-heading {
  font-family: var(--font-brand);
  color: var(--text-primary);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 8px;
}
.section-sub {
  color: var(--text-muted);
  margin-bottom: 48px;
  max-width: 560px;
}

.infra-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.infra-card {
  background: white;
  border-radius: 8px;
  padding: 32px 28px 24px;
  box-shadow: var(--shadow);
  border-top: 4px solid var(--wcm-red);
  transition: box-shadow var(--transition), transform var(--transition);
  display: flex;
  flex-direction: column;
}

.infra-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-4px);
}

.infra-card--storage { border-top-color: var(--wcm-orange); }
.infra-card--software { border-top-color: #555; }

.infra-card__header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.infra-card__icon {
  font-size: 2rem;
  color: var(--wcm-red);
}
.infra-card--storage .infra-card__icon { color: var(--wcm-orange); }
.infra-card--software .infra-card__icon { color: #555; }

.infra-card__title {
  font-family: "1898 Sans", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.3rem;
  color: var(--text-primary);
  margin: 0;
  font-style: normal;
  font-weight: 700;
  font-synthesis: none;
}

.infra-card__stats { flex: 1; margin-bottom: 20px; }

.stat-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}
.stat-row:last-child { border-bottom: none; }

.stat-num {
  font-family: "1898 Sans", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--wcm-red);
  white-space: nowrap;
  min-width: 80px;
  font-style: normal;
  font-synthesis: none;
  font-variant-numeric: lining-nums proportional-nums;
  font-feature-settings: "lnum" 1, "onum" 0, "pnum" 1, "tnum" 0;
}
.infra-card--storage .stat-num { color: var(--wcm-orange); }
.infra-card--software .stat-num { color: #444; font-size: 1rem; }

.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.3;
}

.infra-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 20px;
}

.infra-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  background: var(--surface-alt);
  color: #555;
  padding: 3px 10px;
  border-radius: 20px;
  border: 1px solid var(--border);
}

.infra-card__link {
  font-family: "1898 Sans", "Helvetica Neue", Arial, sans-serif;
  font-size: 0.9rem;
  color: var(--wcm-red);
  text-decoration: none;
  font-weight: 700;
  transition: color var(--transition);
  font-style: normal;
  font-synthesis: none;
}
.infra-card--storage .infra-card__link { color: var(--wcm-orange); }
.infra-card__link:hover { color: var(--wcm-red-dark); }
