/* ============================================================
   DESIGN TOKENS & COLOR SYSTEM
   ============================================================ */

:root {
  /* Brand Colors */
  --accent: #2ecc71;
  --accent-soft: rgba(46, 204, 113, 0.12);
  --accent-hover: #3ce383;
  --danger: #ff4d6a;

  /* Background Colors */
  --bg-body: #040509;
  --bg-elevated: #0b0d14;
  --bg-card: #111322;
  --bg-header: #060713;
  --bg-footer: #060713;

  /* Text Colors */
  --text-main: #f5f7ff;
  --text-muted: #a3a7c2;

  /* Border Colors */
  --border-subtle: #23263a;

  /* Spacing & Layout */
  --radius-lg: 18px;
  --radius-full: 999px;

  /* Effects */
  --shadow-soft: 0 18px 40px rgba(0, 0, 0, 0.6);

  /* Sizes */
  --header-height-desktop: 70px;
  --header-height-mobile: 60px;
  --mobile-footer-height: 64px;

  /* Animations */
  --transition-fast: 0.18s ease-out;
}

/* ============================================================
   GLOBAL RESET & BASE STYLES
   ============================================================ */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: radial-gradient(circle at top, #101327 0, #040509 55%);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: #2ecc71;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

/* ============================================================
   HEADER & NAVIGATION
   ============================================================ */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height-desktop);
  z-index: 1000;
  background: linear-gradient(to bottom, rgba(5, 6, 15, 0.96), rgba(5, 6, 15, 0.88));
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(55, 65, 81, 0.65);
}

.header-inner {
  max-width: 1120px;
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  gap: 16px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-logo img {
  width: 200px;
  height: 60px;
  object-fit: cover;
}

.brand-logo-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-logo-text span:first-child {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.brand-logo-text span:last-child {
  font-size: 11px;
  color: var(--text-muted);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 13px;
}

.main-nav a {
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--text-muted);
  transition: background var(--transition-fast), color var(--transition-fast), transform var(--transition-fast);
}

.main-nav a[aria-current="page"] {
  color: var(--text-main);
  background: var(--accent-soft);
  border: 1px solid rgba(46, 204, 113, 0.4);
}

.main-nav a:hover {
  color: var(--text-main);
  background: rgba(148, 163, 184, 0.08);
  transform: translateY(-1px);
}

.header-cta {
  display: flex;
  gap: 8px;
  align-items: center;
}

.btn-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 14px;
  font-size: 12px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(148, 163, 184, 0.4);
  color: var(--text-main);
  background: rgba(15, 23, 42, 0.75);
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
  white-space: nowrap;
}

.btn-pill--accent {
  border-color: rgba(46, 204, 113, 0.8);
  background: linear-gradient(135deg, #22c55e, #4ade80);
  color: #020617;
  font-weight: 600;
  box-shadow: 0 10px 25px rgba(34, 197, 94, 0.45);
}

.btn-pill:hover {
  transform: translateY(-1px);
  border-color: rgba(148, 163, 184, 0.8);
  background: rgba(15, 23, 42, 0.95);
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.65);
}

.btn-pill--accent:hover {
  background: linear-gradient(135deg, var(--accent-hover), #86efac);
  box-shadow: 0 14px 30px rgba(34, 197, 94, 0.6);
}

/* Hamburger button */

.header-mobile-toggle {
  display: none;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.55);
  background: rgba(15, 23, 42, 0.9);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.hamburger-icon {
  width: 22px;
  height: 22px;
}

.hamburger-icon .line {
  stroke: var(--text-muted);
  stroke-width: 1.8;
  stroke-linecap: round;
  transition: transform 0.2s ease-out, opacity 0.2s ease-out, stroke 0.2s ease-out;
}

/* animasi ketika open */
.header-mobile-toggle.is-open .line1 {
  transform-origin: 12px 7px;
  transform: translateY(5px) rotate(45deg);
}

.header-mobile-toggle.is-open .line2 {
  opacity: 0;
}

.header-mobile-toggle.is-open .line3 {
  transform-origin: 12px 17px;
  transform: translateY(-5px) rotate(-45deg);
}

/* ============================================================
   BREADCRUMB NAVIGATION
   ============================================================ */

.breadcrumb-nav {
  position: sticky;
  top: var(--header-height-desktop);
  z-index: 999;
  background: linear-gradient(to bottom, rgba(11, 13, 20, 0.96), rgba(11, 13, 20, 0.88));
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(55, 65, 81, 0.4);
}

.breadcrumb-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 8px 16px;
}

.breadcrumb-list {
  display: flex;
  align-items: center;
  list-style: none;
  font-size: 12px;
  gap: 4px;
}

.breadcrumb-item {
  display: flex;
  align-items: center;
}

.breadcrumb-item a {
  color: var(--text-muted);
  padding: 4px 8px;
  border-radius: 6px;
  transition: color var(--transition-fast), background var(--transition-fast);
}

.breadcrumb-item a:hover {
  color: var(--text-main);
  background: rgba(46, 204, 113, 0.08);
}

.breadcrumb-item[aria-current="page"] {
  color: var(--text-main);
  padding: 4px 8px;
}

.breadcrumb-item:not(:last-child)::after {
  content: "/";
  display: inline-block;
  margin: 0 2px;
  color: var(--text-muted);
  opacity: 0.5;
}

@media (max-width: 900px) {
  .breadcrumb-nav {
    top: var(--header-height-mobile);
  }
}

/* ============================================================
   SCROLL TO TOP BUTTON
   ============================================================ */

.scroll-to-top {
  position: fixed;
  bottom: 70px;
  right: 30px;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, #22c55e, #4ade80);
  border: none;
  color: #020617;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 998;
  box-shadow: 0 10px 28px rgba(34, 197, 94, 0.5);
  transition: opacity var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
}

.scroll-to-top svg {
  width: 20px;
  height: 20px;
}

.scroll-to-top:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(34, 197, 94, 0.65);
}

.scroll-to-top.show {
  display: flex;
  animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================
   LAYOUT & GRID
   ============================================================ */

.page-wrapper {
  max-width: 1120px;
  margin: 0 auto;
  padding: calc(var(--header-height-desktop) + 18px) 16px 32px;
}

main {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.grid-2 {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1.3fr);
  gap: 20px;
  align-items: stretch;
}

@media (max-width: 900px) {
  .grid-2 {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ============================================================
   HERO SECTION
   ============================================================ */

.hero-card {
  background: radial-gradient(circle at top left, #1d283a 0, #0b0d14 45%, #050814 100%);
  border-radius: 24px;
  padding: 18px 18px 20px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  box-shadow: var(--shadow-soft);
  position: relative;
  overflow: hidden;
}

.hero-card--compact {
  padding: 16px 16px 18px;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.4);
  color: var(--text-muted);
  margin-bottom: 10px;
}

.hero-pill span.dot {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.8);
}

.hero-title {
  font-size: 24px;
  line-height: 1.25;
  font-weight: 700;
  margin-bottom: 8px;
}

.hero-title--small {
  font-size: 20px;
}

.hero-subtitle {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 18px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  border: none;
  background: linear-gradient(135deg, #22c55e, #4ade80);
  color: #020617;
  cursor: pointer;
  box-shadow: 0 14px 28px rgba(34, 197, 94, 0.55);
  transition: background var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--accent-hover), #a7f3d0);
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(34, 197, 94, 0.7);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 16px;
  border-radius: var(--radius-full);
  font-size: 13px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  color: var(--text-muted);
  background: rgba(15, 23, 42, 0.7);
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast), transform var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
}

.btn-ghost:hover {
  background: rgba(15, 23, 42, 0.95);
  color: var(--text-main);
  border-color: rgba(148, 163, 184, 0.9);
  transform: translateY(-1px);
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 11px;
  color: var(--text-muted);
}

.hero-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid rgba(51, 65, 85, 0.9);
}

.hero-meta-dot {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #22c55e;
}

/* ============================================================
   SIDEBAR & CARD COMPONENTS
   ============================================================ */

.side-card {
  background: var(--bg-elevated);
  border-radius: 20px;
  border: 1px solid var(--border-subtle);
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.side-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.side-card-header h2 {
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.badge-green {
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(22, 163, 74, 0.18);
  color: #bbf7d0;
  border: 1px solid rgba(74, 222, 128, 0.4);
}

.brand-banner {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.3);
}

.quick-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  color: var(--text-muted);
}

.quick-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.quick-list span.label {
  color: var(--text-muted);
}

.quick-list span.value {
  color: var(--text-main);
  font-weight: 500;
}

.quick-links a {
  font-weight: 500;
}

/* ============================================================
   CONTENT SECTIONS
   ============================================================ */

.section {
  background: var(--bg-card);
  border-radius: 18px;
  border: 1px solid var(--border-subtle);
  padding: 16px 16px 18px;
}

.section+.section {
  margin-top: 6px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.section-title {
  font-size: 15px;
  font-weight: 600;
}

.section-kicker {
  font-size: 11px;
  color: var(--text-muted);
}

.section p {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.section ul {
  list-style: disc;
  margin-left: 18px;
  margin-top: 4px;
  font-size: 13px;
  color: var(--text-muted);
}

.section ul li+li {
  margin-top: 4px;
}

/* ============================================================
   FAQ ACCORDION
   ============================================================ */

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

details.faq-item {
  background: #050815;
  border-radius: 14px;
  border: 1px solid rgba(55, 65, 81, 0.9);
  padding: 8px 10px;
  font-size: 13px;
}

details.faq-item summary {
  cursor: pointer;
  list-style: none;
  font-weight: 500;
  color: var(--text-main);
}

details.faq-item[open] {
  border-color: rgba(250, 250, 250, 0.24);
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.9);
}

details.faq-item summary::-webkit-details-marker {
  display: none;
}

details.faq-item p {
  margin-top: 6px;
  font-size: 13px;
  color: var(--text-muted);
}

/* ============================================================
   FOOTER
   ============================================================ */

.site-footer {
  margin-top: 18px;
  padding: 12px 0 6px;
  font-size: 11px;
  color: var(--text-muted);
  border-top: 1px solid rgba(31, 41, 55, 0.85);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-links a {
  color: var(--text-muted);
  font-size: 11px;
}

.footer-links a:hover {
  color: var(--text-main);
}

/* ============================================================
   MOBILE FIXED FOOTER
   ============================================================ */

.mobile-cta-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--mobile-footer-height);
  background: linear-gradient(to top, rgba(2, 6, 23, 0.98), rgba(15, 23, 42, 0.98));
  border-top: 1px solid rgba(55, 65, 81, 0.95);
  display: none;
  z-index: 999;
}

.mobile-cta-inner {
  max-width: 1120px;
  margin: 0 auto;
  height: 100%;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.mobile-cta-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 11px;
  color: var(--text-muted);
  cursor: pointer;
  text-decoration: none;
  transition: background var(--transition-fast), color var(--transition-fast), transform var(--transition-fast);
}

.nav-icon {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.mobile-cta-btn .label {
  font-weight: 500;
  font-size: 11px;
}

.mobile-cta-btn--login .label {
  color: #e5e7eb;
}

.mobile-cta-btn--register .label {
  color: #bbf7d0;
}

.mobile-cta-btn--bonus .label {
  color: #fde68a;
}

.mobile-cta-btn:hover {
  background: rgba(15, 23, 42, 0.9);
  transform: translateY(-1px);
}

/* ============================================================
   RESPONSIVE DESIGN
   ============================================================ */

@media (max-width: 900px) {
  .site-header {
    height: var(--header-height-mobile);
  }

  .page-wrapper {
    padding-top: calc(var(--header-height-mobile) + 14px);
    padding-bottom: calc(var(--mobile-footer-height) + 18px);
  }

  .main-nav {
    display: none;
  }

  .main-nav.nav-open {
    position: absolute;
    top: 100%;
    right: 16px;
    background: rgba(15, 23, 42, 0.98);
    border-radius: 14px;
    border: 1px solid rgba(51, 65, 85, 0.9);
    padding: 8px 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  .header-cta {
    display: none;
  }

  .header-mobile-toggle {
    display: inline-flex;
  }

  .mobile-cta-bar {
    display: block;
  }
}

/* ============================================================
   BRANDS GRID - CASINO/CATEGORY LISTING
   ============================================================ */

.brands-grid-simple {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 30px;
}

.brand-grid-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
  cursor: pointer;
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.brand-grid-item:hover {
  transform: translateY(-4px);
  opacity: 0.95;
}

.brand-grid-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
  background: #f5f5f5;
}

.brand-grid-name {
  text-align: center;
  font-weight: 500;
  font-size: 14px;
  color: var(--text-dark);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Responsive grid untuk tablet dan mobile */
@media (max-width: 900px) {
  .brands-grid-simple {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
  }
}

@media (max-width: 640px) {
  .brands-grid-simple {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .brand-grid-name {
    font-size: 12px;
  }
}

/* ============================================================
   PAGINATION
   ============================================================ */

.pagination-wrapper {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(55, 65, 81, 0.4);
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pagination-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: rgba(15, 23, 42, 0.8);
  color: var(--text-main);
  cursor: pointer;
  font-size: 12px;
  font-weight: 500;
  transition: background var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast);
  white-space: nowrap;
}

.pagination-btn:hover:not(:disabled) {
  background: rgba(15, 23, 42, 0.95);
  border-color: rgba(148, 163, 184, 0.6);
  transform: translateY(-1px);
}

.pagination-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.pagination-btn svg {
  width: 16px;
  height: 16px;
  stroke-width: 2;
}

.pagination-btn--text {
  display: none;
}

.pagination-pages {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  flex-wrap: wrap;
}

.pagination-page-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: rgba(15, 23, 42, 0.8);
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast),
    transform var(--transition-fast);
}

.pagination-page-btn:hover {
  background: rgba(15, 23, 42, 0.95);
  border-color: rgba(148, 163, 184, 0.6);
  color: var(--text-main);
  transform: translateY(-1px);
}

.pagination-page-btn.active {
  background: linear-gradient(135deg, #22c55e, #4ade80);
  border-color: rgba(46, 204, 113, 0.8);
  color: #020617;
  font-weight: 600;
  box-shadow: 0 8px 16px rgba(34, 197, 94, 0.3);
}

/* Added ellipsis styling for smart pagination */
.pagination-ellipsis {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 600;
}

.pagination-info {
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
}

/* Mobile-specific pagination styles */
@media (max-width: 640px) {
  .pagination-wrapper {
    gap: 12px;
    margin-top: 14px;
    padding-top: 12px;
  }

  .pagination {
    gap: 6px;
  }

  .pagination-btn {
    padding: 7px 10px;
    font-size: 11px;
  }

  .pagination-btn svg {
    width: 14px;
    height: 14px;
  }

  .pagination-page-btn {
    width: 32px;
    height: 32px;
    font-size: 11px;
  }

  /* Mobile ellipsis sizing */
  .pagination-ellipsis {
    width: 32px;
    height: 32px;
    font-size: 12px;
  }

  .pagination-info {
    font-size: 11px;
  }
}

@media (max-width: 480px) {
  .pagination-btn--text {
    display: none;
  }

  .pagination-btn {
    padding: 6px 8px;
  }
}

@media (min-width: 641px) {
  .pagination-btn--text {
    display: inline;
  }
}

/* ============================================================
   RESPONSIVE DESIGN
   ============================================================ */