/* Ph90 Signature Grey Mobile App-Shell Design System */
:root {
  /* Signature Grey Casino Palette (Signature Grey Casino Architecture) */
  --backdrop: #1a1a1a;
  --bg: #2b2b2b;
  --surface: #383838;
  --surface2: #444444;
  --surface-border: #4d4d4d;
  --text: #f0f0f0;
  --muted: #a0a0aa;
  
  /* Brand Accents */
  --primary-purple: #4b0082;
  --purple-glow: #7008b0;
  --gold: #ffd700;
  --gold-end: #fdb931;
  --gold-gradient: linear-gradient(135deg, #ffd700 0%, #fdb931 50%, #ff8c00 100%);
  --cta-shadow: 0 4px 15px rgba(255, 215, 0, 0.35);

  /* Provider Colorway Badges */
  --jili-badge-bg: #e11d48;
  --jili-badge-text: #fff;
  --fc-badge-bg: #d97706;
  --fc-badge-text: #fff;
  --pp-badge-bg: #ea580c;
  --pp-badge-text: #fff;
  --pg-badge-bg: #8b5cf6;
  --pg-badge-text: #fff;
  --live-badge-bg: #2563eb;
  --live-badge-text: #fff;

  /* Typography & Layout */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-heading: 'Outfit', 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 9999px;
  --max-shell-width: 430px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  background-color: var(--backdrop);
  margin: 0;
  padding: 0;
  width: 100%;
  min-height: 100vh;
  scrollbar-gutter: stable;
  overflow-y: scroll;
}

/* Custom sleek dark scrollbar to eliminate visual asymmetry on Windows */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--backdrop);
}
::-webkit-scrollbar-thumb {
  background: #383838;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #4d4d4d;
}

body {
  background-color: var(--backdrop);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
  padding: 0;
  margin: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  overflow-x: hidden;
}

/* 430px Centered Mobile Shell */
.app-shell {
  width: 100%;
  max-width: var(--max-shell-width);
  min-height: 100vh;
  margin-left: auto;
  margin-right: auto;
  background-color: var(--bg);
  box-shadow: 0 0 35px rgba(0, 0, 0, 0.9);
  position: relative;
  display: flex;
  flex-direction: column;
  padding-bottom: 75px; /* space for fixed bottom nav */
  box-sizing: border-box;
}

/* Sticky Header */
.hdr {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(43, 43, 43, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--surface-border);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.hdr-brand {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.hdr-logo {
  height: 38px;
  width: auto;
  object-fit: contain;
}

.hdr-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hdr-btn {
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  text-decoration: none;
  transition: transform 0.15s ease, opacity 0.15s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.hdr-btn:active {
  transform: scale(0.96);
}

.hdr-btn-login {
  background: var(--surface2);
  color: var(--text);
  border: 1px solid var(--surface-border);
}

.hdr-btn-register {
  background: var(--gold-gradient);
  color: #1a1a1a;
  font-weight: 700;
  box-shadow: var(--cta-shadow);
}

/* Top Notification Marquee */
.notification-ticker {
  background: var(--surface);
  border-bottom: 1px solid var(--surface-border);
  padding: 6px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--muted);
  overflow: hidden;
}

.ticker-icon {
  color: var(--gold);
  flex-shrink: 0;
  font-size: 14px;
}

.ticker-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text);
  font-weight: 500;
}

/* Hero Container with Immersive Background Layer */
.hero-container {
  position: relative;
  background-size: cover;
  background-position: center;
  padding: 24px 18px;
  border-bottom: 1px solid var(--surface-border);
  overflow: hidden;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, rgba(30, 7, 62, 0.82) 0%, rgba(43, 43, 43, 0.95) 100%);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
}

/* <h1> Strictly First Heading */
h1.hero-title {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  line-height: 1.25;
  margin-bottom: 8px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.hero-subtitle {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px;
  line-height: 1.5;
}

.hero-featured-img {
  width: 100%;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.5);
  display: block;
  object-fit: cover;
  border: 1px solid var(--surface-border);
}

/* Dual CTA Button Pairs (Header, Hero & In-Content Pill Design) */
.cta-pair, .cta-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 18px 0;
  width: 100%;
}

.btn, .btn-gold, .btn-ghost, .btn-primary, .btn-secondary {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 13.5px;
  padding: 10px 16px;
  border-radius: var(--radius-pill); /* Signature pill shape from Image 2 */
  text-decoration: none !important;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, opacity 0.15s ease;
  box-sizing: border-box;
}

.btn:active, .btn-gold:active, .btn-ghost:active, .btn-primary:active, .btn-secondary:active {
  transform: scale(0.97);
}

/* Secondary Button (Dark Grey Pill like Login in Image 2) */
.btn-ghost, .btn-secondary {
  order: 1;
  background: var(--surface2);
  color: #ffffff !important;
  border: 1px solid var(--surface-border);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.btn-ghost:hover, .btn-secondary:hover {
  background: #505050;
  color: #ffffff !important;
}

/* Primary Button (Gold Gradient Pill like Register in Image 2) */
.btn-gold, .btn-primary {
  order: 2;
  background: var(--gold-gradient);
  color: #1a1a1a !important;
  font-weight: 800;
  border: none;
  box-shadow: var(--cta-shadow);
}

.btn-gold:hover, .btn-primary:hover {
  box-shadow: 0 6px 20px rgba(255, 215, 0, 0.45);
  color: #1a1a1a !important;
}

/* Filter Chips (Studio Category Tabs) */
.filter-bar {
  padding: 12px 16px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  background: var(--surface);
  border-bottom: 1px solid var(--surface-border);
}

.filter-bar::-webkit-scrollbar {
  display: none;
}

.chip {
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
  background: var(--surface2);
  color: var(--muted);
  border: 1px solid var(--surface-border);
  transition: all 0.2s ease;
}

.chip.active, .chip:hover {
  background: var(--gold-gradient);
  color: #1a1a1a;
  border-color: var(--gold);
}

/* 3x2 Interactive Game Grid */
.game-section {
  padding: 16px;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

h2.section-title {
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 6px;
}

.grid-3x2 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.game-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--surface-border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.game-card:active {
  transform: scale(0.97);
}

.game-thumb-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1/1;
  overflow: hidden;
}

.game-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.provider-badge {
  position: absolute;
  top: 4px;
  left: 4px;
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: var(--radius-pill);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.badge-jili { background: var(--jili-badge-bg); color: var(--jili-badge-text); }
.badge-fc { background: var(--fc-badge-bg); color: var(--fc-badge-text); }
.badge-pp { background: var(--pp-badge-bg); color: var(--pp-badge-text); }
.badge-pg { background: var(--pg-badge-bg); color: var(--pg-badge-text); }
.badge-live { background: var(--live-badge-bg); color: var(--live-badge-text); }

.game-info {
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.game-name {
  font-size: 11px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
}

.game-rtp {
  font-size: 10px;
  color: #4ade80;
  text-align: center;
  font-weight: 600;
}

/* Dual Buttons on Each Placecard */
.card-actions {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: auto;
}

.btn-card-play {
  background: var(--gold-gradient);
  color: #1a1a1a;
  font-size: 10px;
  font-weight: 700;
  padding: 5px 0;
  border-radius: var(--radius-sm);
  text-decoration: none;
  text-align: center;
}

.btn-card-guide {
  background: var(--surface2);
  color: var(--text);
  font-size: 10px;
  font-weight: 600;
  padding: 4px 0;
  border-radius: var(--radius-sm);
  text-decoration: none;
  text-align: center;
  border: 1px solid var(--surface-border);
}

/* Content Article Body & Semantic Styles */
.content-body {
  padding: 16px;
  background: var(--bg);
}

.content-body h2 {
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  margin: 22px 0 10px 0;
  border-left: 3px solid var(--gold);
  padding-left: 8px;
}

.content-body h3 {
  font-size: 15px;
  font-weight: 700;
  color: #fde047;
  margin: 16px 0 8px 0;
}

.content-body p {
  font-size: 14px;
  color: #e4e4e7;
  margin-bottom: 14px;
  line-height: 1.6;
}

.content-body ul, .content-body ol {
  margin-left: 18px;
  margin-bottom: 14px;
}

.content-body li {
  font-size: 14px;
  color: #e4e4e7;
  margin-bottom: 6px;
}

.content-body a {
  color: var(--gold);
  text-decoration: underline;
}

.content-body a.btn,
.content-body a.btn-gold,
.content-body a.btn-ghost,
.content-body a.btn-primary,
.content-body a.btn-secondary,
.content-body .cta-group a {
  text-decoration: none !important;
}

.contextual-img-wrap {
  margin: 16px 0;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--surface-border);
}

.contextual-img {
  width: 100%;
  display: block;
  object-fit: cover;
}

.img-caption {
  font-size: 11px;
  color: var(--muted);
  padding: 6px 10px;
  background: var(--surface);
  text-align: center;
}

/* Tables */
.table-wrap {
  width: 100%;
  overflow-x: auto;
  margin: 18px 0;
  border-radius: var(--radius-md);
  border: 1px solid var(--surface-border);
  background: var(--surface);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

table, .data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  text-align: left;
}

thead {
  background: #333333;
}

th {
  background: #333333;
  color: var(--gold);
  font-weight: 700;
  font-size: 12.5px;
  padding: 11px 14px;
  border-bottom: 2px solid var(--surface-border);
  letter-spacing: 0.3px;
}

tbody tr {
  transition: background 0.15s ease;
}

tbody tr:nth-child(even) td {
  background: rgba(255, 255, 255, 0.02);
}

tbody tr:nth-child(odd) td {
  background: transparent;
}

tbody tr:hover td {
  background: rgba(255, 215, 0, 0.05);
}

td {
  padding: 10px 14px;
  border-top: 1px solid var(--surface-border);
  color: #e4e4e7;
  font-size: 13px;
  line-height: 1.5;
  vertical-align: middle;
}

td strong {
  color: #ffffff;
  font-weight: 700;
}

td a {
  color: var(--gold) !important;
  text-decoration: underline;
  font-weight: 600;
}

td a:hover {
  color: #ffffff !important;
}

/* 2-Column Parameter Tables */
table.col-2 th:last-child,
table.col-2 td:last-child {
  text-align: right;
  color: #d4d4d8;
}

table.col-2 th:first-child,
table.col-2 td:first-child {
  text-align: left;
}

/* Hub Spoke Directory Grid & Cards */
.spoke-directory-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 18px 0 24px 0;
}

.spoke-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  text-decoration: none !important;
  color: var(--text) !important;
  transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
  box-sizing: border-box;
}

.spoke-card:hover {
  background: #3e3e3e;
  border-color: var(--gold);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(255, 215, 0, 0.2);
}

.spoke-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.spoke-card-title {
  font-size: 14.5px;
  font-weight: 700;
  color: #ffffff;
  font-family: var(--font-heading);
  line-height: 1.3;
}

.spoke-card:hover .spoke-card-title {
  color: var(--gold);
}

.spoke-badge {
  background: rgba(255, 215, 0, 0.15);
  color: var(--gold);
  border: 1px solid rgba(255, 215, 0, 0.4);
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}

.spoke-card-desc {
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.5;
  margin: 0 0 10px 0 !important;
}

.spoke-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--gold);
}

.spoke-arrow {
  font-size: 14px;
  transition: transform 0.15s ease;
}

.spoke-card:hover .spoke-arrow {
  transform: translateX(4px);
}

/* FAQ Accordion */
.faq-block {
  margin: 18px 0;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  overflow: hidden;
}

.faq-q {
  padding: 12px 14px;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-q::after {
  content: '▼';
  font-size: 10px;
  color: var(--gold);
  transition: transform 0.2s ease;
}

.faq-item.open .faq-q::after {
  transform: rotate(180deg);
}

.faq-a {
  padding: 0 14px 12px 14px;
  font-size: 13px;
  color: #d4d4d8;
  display: none;
}

.faq-item.open .faq-a {
  display: block;
}

/* Mandatory Compliance Block (21+ & PAGCOR Notice) */
.compliance-footer {
  background: #202020;
  border-top: 2px solid #581c87;
  padding: 20px 16px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
}

.age-badge {
  display: inline-block;
  background: #dc2626;
  color: #fff;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-size: 11px;
  margin-bottom: 8px;
}

.compliance-links {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.compliance-links a {
  color: var(--gold);
  font-size: 11px;
  text-decoration: underline;
}

/* Fixed 5-Tab Bottom Navigation */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  max-width: var(--max-shell-width);
  height: 60px;
  background: rgba(35, 35, 35, 0.98);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--surface-border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 200;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.5);
  box-sizing: border-box;
  padding: 0 4px;
}

.bnav-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 2px;
  text-decoration: none;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  flex: 1;
  height: 100%;
  padding: 4px 0;
  box-sizing: border-box;
  transition: color 0.15s ease;
}

.bnav-tab:hover, .bnav-tab.active {
  color: var(--gold);
}

.bnav-icon {
  font-size: 20px;
  line-height: 1.2;
  display: block;
}

.bnav-tab span:last-child {
  font-size: 11px;
  line-height: 1.2;
  display: block;
  white-space: nowrap;
}

/* 21+ Age Gate Modal (Accessible, non-heading compliant) */
.age-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.age-modal-box {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-lg);
  max-width: 360px;
  width: 100%;
  padding: 24px 20px;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.9);
}

.modal-title {
  font-size: 18px;
  font-weight: 800;
  color: #fff;
  margin: 10px 0 8px 0;
}

.modal-desc {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
  margin-bottom: 20px;
}

.modal-btns {
  display: flex;
  gap: 10px;
}

/* Responsive Callout & Guide Cards (replacing ugly monospace code boxes) */
.callout-card {
  background: linear-gradient(145deg, #323232 0%, #282828 100%);
  border: 1px solid var(--surface-border);
  border-left: 4px solid var(--gold);
  border-radius: var(--radius-md);
  padding: 16px 16px;
  margin: 18px 0;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45);
  box-sizing: border-box;
  overflow: hidden;
  word-wrap: break-word;
  white-space: normal;
}

.callout-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.callout-icon {
  font-size: 16px;
  line-height: 1;
}

.callout-title {
  color: var(--gold);
  font-weight: 700;
  font-size: 13.5px;
  line-height: 1.3;
  letter-spacing: 0.3px;
}

.callout-content {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.callout-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  line-height: 1.55;
  color: #e4e4e7;
}

.callout-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  background: var(--gold-gradient);
  color: #1a1a1a;
  font-weight: 800;
  font-size: 11px;
  border-radius: var(--radius-pill);
  flex-shrink: 0;
  margin-top: 2px;
}

.callout-bullet {
  color: var(--gold);
  font-weight: bold;
  font-size: 14px;
  line-height: 1.4;
  flex-shrink: 0;
}

.callout-text {
  flex: 1;
  word-break: break-word;
}

.callout-lead {
  color: #ffffff;
  font-weight: 700;
  margin-right: 4px;
}

.callout-desc {
  color: #d4d4d8;
}

.callout-p {
  font-size: 13px;
  line-height: 1.6;
  color: #d4d4d8;
  margin: 0;
}
