/* ═══════════════════════════════════════
   NCS Site Manager v2 — Frontend Styles
   ADA Compliant · Accessible
   ═══════════════════════════════════════ */

/* ── ENROLLMENT PILL ── */
.ncs-sm-enrollment-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 1.6rem 0.55rem 0.65rem;
  border-radius: 9999px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.15);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-family: -apple-system, BlinkMacSystemFont, 'Inter', 'Segoe UI', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.4;
  color: rgba(255,255,255,0.9);
}

/* Dot — color set via inline style from admin */
.ncs-sm-pill-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  animation: ncs-sm-pulse 2s ease infinite;
}
@keyframes ncs-sm-pulse {
  0%,100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.85); }
}
@media (prefers-reduced-motion: reduce) {
  .ncs-sm-pill-dot { animation: none; }
}

/* Highlighted sub-pill (first part before separator) */
.ncs-sm-pill-highlight {
  display: inline-block;
  padding: 0.2rem 0.75rem;
  background: rgba(212,168,71,0.2);
  border-radius: 9999px;
  color: #e8c55a;
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
}

/* Remaining text */
.ncs-sm-pill-text {
  color: rgba(255,255,255,0.85);
  font-weight: 500;
  letter-spacing: 0.1em;
}

/* Link inside pill */
.ncs-sm-pill-link {
  margin-left: 0.5rem;
  font-weight: 700;
  text-decoration: none;
  color: #e8c55a;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.ncs-sm-pill-link:hover,
.ncs-sm-pill-link:focus { border-bottom-color: currentColor; }

/* Light background variant */
.ncs-sm-enrollment-pill.ncs-sm-on-light {
  background: rgba(26,31,46,0.06);
  border-color: rgba(26,31,46,0.1);
  color: #1a1f2e;
  backdrop-filter: none;
}
.ncs-sm-enrollment-pill.ncs-sm-on-light .ncs-sm-pill-highlight {
  background: rgba(212,168,71,0.15);
  color: #8B6914;
}
.ncs-sm-enrollment-pill.ncs-sm-on-light .ncs-sm-pill-text { color: #4b5563; }
.ncs-sm-enrollment-pill.ncs-sm-on-light .ncs-sm-pill-link { color: #8B6914; }

/* Style variants — affect highlight sub-pill background */
.ncs-sm-style-urgent .ncs-sm-pill-highlight {
  background: rgba(239,68,68,0.15);
  color: #fca5a5;
}
.ncs-sm-style-success .ncs-sm-pill-highlight {
  background: rgba(34,197,94,0.15);
  color: #86efac;
}
.ncs-sm-style-urgent {
  border-color: rgba(239,68,68,0.2);
  background: rgba(239,68,68,0.08);
}

/* ── ENROLLMENT BAR (Sticky Bottom) ── */
.ncs-sm-enrollment-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 9990;
  border-top: 1px solid rgba(0,0,0,0.1);
  font-family: -apple-system, BlinkMacSystemFont, 'Inter', 'Segoe UI', sans-serif;
}
.ncs-sm-bar-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0.55rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.ncs-sm-bar-text {
  font-size: 0.82rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.ncs-sm-enrollment-bar .ncs-sm-pill-highlight {
  padding: 0.15rem 0.6rem;
  font-size: 0.68rem;
}
.ncs-sm-enrollment-bar .ncs-sm-pill-text {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
}
.ncs-sm-bar-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}
.ncs-sm-bar-link {
  font-size: 0.72rem;
  font-weight: 600;
  text-decoration: none;
  transition: opacity 0.2s;
}
.ncs-sm-bar-link:hover,
.ncs-sm-bar-link:focus { opacity: 0.8; }
.ncs-sm-bar-close {
  width: 28px; height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  cursor: pointer;
  border-radius: 4px;
  transition: background 0.2s;
  padding: 0;
}
.ncs-sm-bar-close:hover,
.ncs-sm-bar-close:focus { background: rgba(255,255,255,0.1); }
.ncs-sm-bar-close:focus-visible { outline: 2px solid #e8c55a; outline-offset: 2px; }

/* Bar color themes */
.ncs-sm-enrollment-bar.ncs-sm-style-default { background: #1a1f2e; color: #fff; }
.ncs-sm-enrollment-bar.ncs-sm-style-default .ncs-sm-bar-link { color: #e8c55a; }
.ncs-sm-enrollment-bar.ncs-sm-style-default .ncs-sm-bar-close { color: #9ca3af; }

.ncs-sm-enrollment-bar.ncs-sm-style-gold { background: #d4a847; color: #1a1f2e; }
.ncs-sm-enrollment-bar.ncs-sm-style-gold .ncs-sm-pill-highlight { background: rgba(26,31,46,0.15); color: #1a1f2e; }
.ncs-sm-enrollment-bar.ncs-sm-style-gold .ncs-sm-bar-link { color: #1a1f2e; font-weight: 700; }
.ncs-sm-enrollment-bar.ncs-sm-style-gold .ncs-sm-bar-close { color: #1a1f2e; }

.ncs-sm-enrollment-bar.ncs-sm-style-success { background: #3d6b50; color: #fff; }
.ncs-sm-enrollment-bar.ncs-sm-style-success .ncs-sm-bar-link { color: #bbf7d0; }
.ncs-sm-enrollment-bar.ncs-sm-style-success .ncs-sm-bar-close { color: rgba(255,255,255,0.6); }

.ncs-sm-enrollment-bar.ncs-sm-style-urgent { background: #b91c1c; color: #fff; }
.ncs-sm-enrollment-bar.ncs-sm-style-urgent .ncs-sm-bar-link { color: #fecaca; }
.ncs-sm-enrollment-bar.ncs-sm-style-urgent .ncs-sm-bar-close { color: rgba(255,255,255,0.6); }

/* ── SPONSORS ── */
.ncs-sm-sponsors-wrap { max-width: 1120px; margin: 0 auto; }
.ncs-sm-tier-section { margin-bottom: 3rem; }
.ncs-sm-tier-header { text-align: center; margin-bottom: 1.5rem; }
.ncs-sm-tier-title { font-family: 'Source Serif 4', Georgia, serif; font-weight: 500; color: #1a1f2e; margin: 0 0 0.15rem; }
.ncs-sm-tier-subtitle { font-size: 0.68rem; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: #8B6914; margin: 0; }
.ncs-sm-tier-divider { width: 60px; height: 2px; background: #d4a847; margin: 0 auto 1.75rem; border: none; }
.ncs-sm-sponsor-card {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 1.75rem 1.25rem; background: #fff; border: 1px solid #e5e7eb; border-radius: 14px;
  transition: box-shadow 0.2s, border-color 0.2s; text-align: center; text-decoration: none; min-height: 140px;
}
.ncs-sm-sponsor-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.06); border-color: #d1d5db; }
.ncs-sm-sponsor-card:focus-visible { outline: 2px solid #8B6914; outline-offset: 2px; }
.ncs-sm-sponsor-logo { max-width: 180px; max-height: 100px; width: auto; height: auto; object-fit: contain; margin-bottom: 0.75rem; }
.ncs-sm-sponsor-name { font-family: 'Source Serif 4', Georgia, serif; font-size: 0.85rem; font-weight: 500; color: #1a1f2e; }
.ncs-sm-sponsor-text { font-family: 'Source Serif 4', Georgia, serif; font-size: 1.15rem; font-weight: 500; color: #1a1f2e; }
.ncs-sm-sponsor-sublabel { font-size: 0.68rem; color: #9ca3af; margin-top: 0.2rem; }

.ncs-sm-sponsors-champion { display: grid; grid-template-columns: repeat(var(--ncs-sm-cols,2),1fr); gap: 1.5rem; max-width: 700px; margin: 0 auto; }
.ncs-sm-sponsors-champion .ncs-sm-sponsor-logo { max-width: 200px; max-height: 120px; }
.ncs-sm-sponsors-gold { display: flex; justify-content: center; gap: 1.5rem; max-width: 500px; margin: 0 auto; flex-wrap: wrap; }
.ncs-sm-sponsors-gold .ncs-sm-sponsor-card { flex: 0 1 280px; }
.ncs-sm-sponsors-silver, .ncs-sm-sponsors-bronze { display: grid; grid-template-columns: repeat(var(--ncs-sm-cols,4),1fr); gap: 1rem; }
.ncs-sm-sponsors-silver .ncs-sm-sponsor-card, .ncs-sm-sponsors-bronze .ncs-sm-sponsor-card { padding: 1.25rem 1rem; min-height: 120px; }
.ncs-sm-sponsors-silver .ncs-sm-sponsor-logo, .ncs-sm-sponsors-bronze .ncs-sm-sponsor-logo { max-width: 130px; max-height: 70px; }
.ncs-sm-sponsors-silver .ncs-sm-sponsor-name, .ncs-sm-sponsors-bronze .ncs-sm-sponsor-name { font-size: 0.75rem; }

@media (max-width: 768px) {
  .ncs-sm-sponsors-champion { grid-template-columns: 1fr; max-width: 320px; }
  .ncs-sm-sponsors-silver, .ncs-sm-sponsors-bronze { grid-template-columns: repeat(2,1fr); }
  .ncs-sm-bar-inner { flex-wrap: wrap; gap: 0.5rem; }
  .ncs-sm-bar-text { font-size: 0.75rem; }
  .ncs-sm-enrollment-pill { font-size: 0.72rem; padding: 0.45rem 1.2rem 0.45rem 0.5rem; gap: 0.5rem; }
}
