/* ====== Base ====== */
body {
  font-family: 'Kanit', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: radial-gradient(circle at top, #020617 0, #020617 40%, #000 100%);
  color: #e5e7eb;
  margin: 0;
}

/* ====== Top Nav แบบ xcoptech ====== */
.top-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(18px);
  background: radial-gradient(circle at top left, rgba(15,23,42,0.96), rgba(15,23,42,0.98));
  border-bottom: 1px solid rgba(56,189,248,.16);
  padding: .8rem 0;
}

.logo-text {
  font-weight: 800;
  font-size: 1.4rem;
  letter-spacing: .03em;
  color: #e5e7eb;
  text-decoration: none;
}
.logo-text span {
  color: #38bdf8;
}

.nav-link {
  color: #cbd5f5 !important;
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .09em;
  position: relative;
  padding-bottom: .1rem;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.3rem;
  width: 0;
  height: 2px;
  background: linear-gradient(to right, #38bdf8, #22c55e);
  transition: width .16s ease;
}
.nav-link:hover::after {
  width: 100%;
}
.nav-link:hover {
  color: #e5e7eb !important;
}

/* ====== Layout ====== */
.front-main,
.admin-main {
  padding: 2.5rem 0 3rem;
  min-height: 80vh;
}

.hero {
  padding: 3rem 0 2rem;
}

/* ====== Cards / Shell ====== */
.hero-card,
.metric-card,
.admin-panel {
  background: radial-gradient(circle at top left, #020617, #020617 70%);
  border-radius: 1.25rem;
  padding: 1.6rem 1.8rem;
  border: 1px solid rgba(148,163,184,.28);
  box-shadow: 0 22px 60px rgba(0,0,0,.8);
}

.metric-card {
  padding: 1.2rem 1.5rem;
}

.metric-label {
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #9ca3af;
}

.metric-value {
  font-size: 1.6rem;
  font-weight: 700;
}

/* hero badge */
.badge-soft {
  font-size: .75rem;
  border-radius: 999px;
  padding: .25rem .7rem;
  border: 1px solid rgba(148,163,184,.5);
  background: rgba(15,23,42,.95);
}

/* Video shell (หน้า embed / หน้าแรก) */
.video-shell {
  background: radial-gradient(circle at top, #020617, #020617 80%);
  border-radius: 1.25rem;
  padding: .8rem;
  border: 1px solid rgba(56,189,248,.45);
  box-shadow: 0 20px 60px rgba(8,47,73,.9);
}

.video-shell video,
.video-shell iframe {
  width: 100%;
  border-radius: .8rem;
  border: none;
  background: #000;
}

/* ====== Link cards (หน้า front) ====== */
.card-link {
  background: radial-gradient(circle at top, #020617, #020617);
  border-radius: 1rem;
  border: 1px solid rgba(75,85,99,.7);
  padding: 1rem;
  text-decoration: none;
  display: block;
  color: inherit;
  transition: transform .13s ease, box-shadow .13s ease, border-color .13s ease, background .13s ease;
}
.card-link:hover {
  transform: translateY(-4px);
  border-color: rgba(56,189,248,.9);
  background: radial-gradient(circle at top, #020617, #020617 70%);
  box-shadow: 0 18px 50px rgba(8,47,73,.85);
}

/* ====== Footer ====== */
.site-footer {
  border-top: 1px solid rgba(31,41,55,.8);
  padding: 1rem 0;
  background: #020617;
}

/* ====== ADMIN THEME (ใกล้เคียง xcoptech) ====== */

.admin-body {
  background: radial-gradient(circle at top, #020617 0, #020617 40%, #020617 100%);
}

/* header title bar */
.admin-page-header {
  margin-bottom: 1.5rem;
}
.admin-page-title {
  font-size: 1.4rem;
  font-weight: 700;
}
.admin-page-sub {
  font-size: .85rem;
  color: #9ca3af;
}

/* table style */
.table-dark-neo {
  --bs-table-bg: #020617;
  --bs-table-striped-bg: #020617;
  --bs-table-striped-color: #e5e7eb;
  --bs-table-border-color: #111827;
  border-radius: .9rem;
  overflow: hidden;
  border: 1px solid rgba(55,65,81,.7);
}
.table-dark-neo thead {
  background: radial-gradient(circle at top, #020617, #020617 70%);
}
.table-dark-neo th {
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #9ca3af;
  border-bottom-width: 1px;
}
.table-dark-neo td {
  border-top-color: #111827;
  font-size: .85rem;
}

/* buttons */
.btn-primary {
  background: linear-gradient(to right, #38bdf8, #22c55e);
  border: none;
}
.btn-primary:hover {
  filter: brightness(1.05);
}
.btn-outline-light:hover {
  background: rgba(148,163,184,.1);
}

/* small xs button */
.btn-xs {
  padding: .1rem .45rem;
  font-size: .7rem;
}

/* pill badge */
.badge.bg-success,
.badge.bg-danger,
.badge.bg-secondary {
  border-radius: 999px;
  font-weight: 500;
  padding: .25rem .7rem;
}

/* form */
.form-control,
.form-select {
  background-color: #020617;
  border-color: #1f2937;
  color: #e5e7eb;
}
.form-control:focus,
.form-select:focus {
  border-color: #38bdf8;
  box-shadow: 0 0 0 .15rem rgba(56,189,248,.25);
  background-color: #020617;
}
.form-label {
  color: #9ca3af;
}

/* helper text */
.text-muted {
  color: #6b7280 !important;
}

/* spacing tweaks */
.admin-panel + .admin-panel {
  margin-top: 1.5rem;
}
