/* Z-Stride SJApi portal — site-specific styles (works alongside self-hosted Bootstrap + Tailwind utilities)
   Palette matched to the Z-Stride logo: near-black background, crimson-red accent, white type. */

:root,
[data-bs-theme="dark"] {
  --zs-bg: #050506;
  --zs-bg-elevated: #0b0b0d;
  --zs-border: #1e1e22;
  --zs-red: #d2352b;
  --zs-red-light: #ef5c4e;
  --zs-red-dark: #7a130f;
  --zs-text: #f4f4f5;
  --zs-text-dim: #9a9aa3;
  --zs-ok: #34d399;

  /* Reskin Bootstrap's own tokens to match the brand, without rebuilding it from source */
  --bs-body-bg: var(--zs-bg);
  --bs-body-color: var(--zs-text);
  --bs-border-color: var(--zs-border);
  --bs-border-color-translucent: var(--zs-border);
  --bs-primary: var(--zs-red);
  --bs-primary-rgb: 210, 53, 43;
  --bs-link-color: var(--zs-red-light);
  --bs-link-color-rgb: 239, 92, 78;
  --bs-link-hover-color: var(--zs-red);
  --bs-emphasis-color: #fff;
}

body {
  font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--zs-bg);
}

/* Navbar */
.brand-mark {
  border-radius: 8px;
  flex-shrink: 0;
  display: block;
}

.navbar-glass {
  position: relative;
  background-color: rgba(0, 0, 0, 0.78);
  border-bottom-color: var(--zs-border) !important;
}

.navbar-glass::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--zs-red-dark) 20%, var(--zs-red) 50%, var(--zs-red-dark) 80%, transparent);
  opacity: 0.55;
}

.navbar .nav-link {
  color: var(--zs-text-dim);
}

.navbar .nav-link:hover,
.navbar .nav-link:focus {
  color: var(--zs-text);
}

.navbar .nav-link.active {
  color: var(--zs-red-light);
}

/* Hero */
.hero-section {
  background:
    radial-gradient(circle at 15% 0%, rgba(210, 53, 43, 0.16), transparent 55%),
    radial-gradient(circle at 85% 10%, rgba(210, 53, 43, 0.08), transparent 50%);
}

.hero-logo {
  width: 100%;
  max-width: 380px;
  height: auto;
}

.hero-lead {
  max-width: 640px;
}

.status-badge {
  background-color: rgba(52, 211, 153, 0.12);
  color: var(--zs-ok);
  border: 1px solid rgba(52, 211, 153, 0.28);
  font-weight: 500;
  font-size: 0.8rem;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--zs-ok);
  box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.18);
  display: inline-block;
  /* pulse animation itself comes from Tailwind's tw:animate-pulse utility */
}

/* Buttons — reskin via Bootstrap 5.3's component-level CSS variables (no rebuild needed) */
.btn-primary {
  --bs-btn-color: #fff;
  --bs-btn-bg: var(--zs-red);
  --bs-btn-border-color: var(--zs-red);
  --bs-btn-hover-color: #fff;
  --bs-btn-hover-bg: var(--zs-red-light);
  --bs-btn-hover-border-color: var(--zs-red-light);
  --bs-btn-active-color: #fff;
  --bs-btn-active-bg: var(--zs-red-dark);
  --bs-btn-active-border-color: var(--zs-red-dark);
  --bs-btn-disabled-bg: var(--zs-red);
  --bs-btn-disabled-border-color: var(--zs-red);
  --bs-btn-focus-shadow-rgb: 210, 53, 43;
}

.btn-outline-secondary {
  --bs-btn-color: var(--zs-text-dim);
  --bs-btn-border-color: var(--zs-border);
  --bs-btn-hover-color: var(--zs-text);
  --bs-btn-hover-bg: rgba(255, 255, 255, 0.06);
  --bs-btn-hover-border-color: var(--zs-border);
  --bs-btn-active-color: var(--zs-text);
  --bs-btn-active-bg: rgba(255, 255, 255, 0.1);
  --bs-btn-active-border-color: var(--zs-border);
}

/* Feature cards */
.feature-card {
  background-color: var(--zs-bg-elevated);
  border-color: var(--zs-border);
  border-radius: 14px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

a.feature-card:hover {
  border-color: var(--zs-red);
  box-shadow: 0 10px 24px -12px rgba(210, 53, 43, 0.4);
}

.feature-card--soon {
  opacity: 0.88;
}

.feature-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: rgba(210, 53, 43, 0.14);
  color: var(--zs-red-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  margin-bottom: 14px;
}

/* Stack strip + footer */
.stack-strip {
  background: var(--zs-bg-elevated);
  border-color: var(--zs-border) !important;
}

footer {
  border-top: 1px solid var(--zs-border);
}

/* Page header (internal pages: Produk, Jadwal, Portal Stable) */
.page-header {
  background:
    radial-gradient(circle at 15% 0%, rgba(210, 53, 43, 0.14), transparent 55%);
  border-bottom: 1px solid var(--zs-border);
}

.eyebrow {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--zs-red-light);
  font-weight: 600;
}

.feature-icon-sm {
  width: 36px;
  height: 36px;
  font-size: 1rem;
  margin-bottom: 0;
}

/* Dummy-content marker — used while pages are still placeholders */
.dummy-tag {
  font-size: 0.72rem;
  letter-spacing: 0.4px;
  color: var(--zs-text-dim);
  border: 1px dashed var(--zs-border);
  border-radius: 999px;
  padding: 3px 10px;
}

/* Schedule status badges */
.badge-status-upcoming {
  background-color: rgba(154, 154, 163, 0.14);
  color: var(--zs-text-dim);
  border: 1px solid var(--zs-border);
}

.badge-status-live {
  background-color: rgba(210, 53, 43, 0.14);
  color: var(--zs-red-light);
  border: 1px solid rgba(210, 53, 43, 0.35);
}

.badge-status-live .status-dot {
  background: var(--zs-red-light);
  box-shadow: 0 0 0 3px rgba(239, 92, 78, 0.2);
}

.badge-status-done {
  background-color: rgba(52, 211, 153, 0.1);
  color: var(--zs-ok);
  border: 1px solid rgba(52, 211, 153, 0.25);
}

/* Filter chips (Jadwal Pertandingan) */
.filter-chip {
  --bs-btn-color: var(--zs-text-dim);
  --bs-btn-border-color: var(--zs-border);
  --bs-btn-hover-color: var(--zs-text);
  --bs-btn-hover-bg: rgba(255, 255, 255, 0.06);
  --bs-btn-hover-border-color: var(--zs-border);
  border-radius: 999px;
}

.filter-chip.active {
  --bs-btn-color: #fff;
  background-color: var(--zs-red) !important;
  border-color: var(--zs-red) !important;
}

/* Event / product cards */
.event-card,
.product-card {
  background-color: var(--zs-bg-elevated);
  border: 1px solid var(--zs-border);
  border-radius: 14px;
}

.product-card .product-icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background: rgba(210, 53, 43, 0.14);
  color: var(--zs-red-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}

/* Stable portal */
.stable-banner {
  background: var(--zs-bg-elevated);
  border: 1px solid var(--zs-border);
  border-radius: 16px;
}

/* Stable social links (Portal Stable banner) */
.social-link {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--zs-border);
  color: var(--zs-text-dim);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

.social-link:hover {
  color: #fff;
  border-color: var(--zs-red);
  background-color: var(--zs-red);
}

/* Stable directory cards (Beranda) — shortcut into each stable's portal */
.stable-card {
  background-color: var(--zs-bg-elevated);
  border: 1px solid var(--zs-border);
  border-radius: 14px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

a.stable-card:hover {
  border-color: var(--zs-red);
  box-shadow: 0 10px 24px -12px rgba(210, 53, 43, 0.4);
}

a.stable-card:hover .stable-card-arrow {
  color: var(--zs-red-light);
  transform: translateX(2px);
}

.stable-card-arrow {
  transition: transform 0.15s ease, color 0.15s ease;
}

.stable-avatar-sm {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--zs-red), var(--zs-red-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  font-size: 1.05rem;
  flex-shrink: 0;
}

.stable-avatar {
  width: 64px;
  height: 64px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--zs-red), var(--zs-red-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  font-size: 1.4rem;
  flex-shrink: 0;
}

/* Reskin Bootstrap nav-pills to the brand red instead of default blue */
.nav-pills {
  --bs-nav-pills-link-active-bg: var(--zs-red);
  --bs-nav-pills-link-active-color: #fff;
  gap: 6px;
}

.nav-pills .nav-link {
  color: var(--zs-text-dim);
  border: 1px solid transparent;
}

.nav-pills .nav-link:hover {
  color: var(--zs-text);
}

.nav-pills .nav-link.active {
  border-color: var(--zs-red);
}

/* Video placeholder (Live Streaming / Playback) */
.video-placeholder {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  background:
    linear-gradient(160deg, #131316, #0a0a0c);
  border: 1px solid var(--zs-border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.video-placeholder .play-btn {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(210, 53, 43, 0.9);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}

.video-thumb {
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  background: linear-gradient(160deg, #131316, #0a0a0c);
  border: 1px solid var(--zs-border);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--zs-text-dim);
  font-size: 1.3rem;
}

.video-thumb .duration-badge {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.75);
  color: var(--zs-text);
  font-size: 0.72rem;
  padding: 2px 6px;
  border-radius: 4px;
}

/* Tables (Starting Order / Live Scoring) */
.table-zs {
  --bs-table-bg: transparent;
  --bs-table-border-color: var(--zs-border);
  --bs-table-color: var(--zs-text);
  vertical-align: middle;
}

.table-zs thead th {
  color: var(--zs-text-dim);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  font-weight: 600;
  border-bottom-width: 1px;
}

/* Respect reduced-motion preference */
@media (prefers-reduced-motion: reduce) {
  .status-dot { animation: none; }
}
