/* MahjongWaysPinoy - Production CSS Engine (430px Mobile App Shell) */
:root {
  --bg: #0b1e15;
  --shell-bg: #0f291e;
  --surface: #143829;
  --surface-card: #1a4734;
  --surface-hover: #225a43;
  --border: rgba(16, 185, 129, 0.22);
  --border-gold: rgba(245, 158, 11, 0.35);
  --text: #f8fafc;
  --text-muted: #94a3b8;
  --emerald: #10b981;
  --emerald-dark: #047857;
  --gold: #f59e0b;
  --gold-light: #fbbf24;
  --gold-glow: rgba(245, 158, 11, 0.25);
  --red: #ef4444;
  --radius: 14px;
  --radius-sm: 8px;
  --font-main: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

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

img, picture, svg, video {
  max-width: 100%;
  height: auto;
  display: block;
}

body {
  background-color: var(--bg);
  background-image: radial-gradient(circle at 50% 0%, #174230 0%, #0b1e15 80%);
  display: flex;
  justify-content: center;
  font-family: var(--font-main);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

.app-shell {
  width: 100%;
  max-width: 430px;
  background: var(--shell-bg);
  min-height: 100vh;
  padding-bottom: 84px;
  position: relative;
  box-shadow: 0 0 50px rgba(0, 0, 0, 0.85);
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  box-sizing: border-box;
}

main {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow-x: hidden;
}
}

/* 1. Header */
.hdr {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 31, 22, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(16, 185, 129, 0.2);
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 54px;
}

.hdr-brand {
  display: flex;
  align-items: center;
  flex-shrink: 1;
  min-width: 0;
}

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

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

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

.btn-hdr-login {
  padding: 6px 13px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-hdr-login:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.32);
  color: #fff;
}

.btn-hdr-reg {
  padding: 6px 15px;
  background: linear-gradient(135deg, #FFDF00, #F59E0B);
  border: none;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 800;
  color: #0b1e15;
  white-space: nowrap;
  box-shadow: 0 2px 10px rgba(245, 158, 11, 0.4);
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-hdr-reg:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.6);
  filter: brightness(1.05);
}

@media (max-width: 360px) {
  .hdr {
    padding: 6px 8px;
  }
  .hdr-logo {
    max-width: 160px;
    height: 34px;
  }
  .btn-hdr-login {
    padding: 5px 10px;
    font-size: 0.78rem;
  }
  .btn-hdr-reg {
    padding: 5px 12px;
    font-size: 0.78rem;
  }
}

/* 2. Breadcrumbs */
.breadcrumbs {
  padding: 10px 16px 0;
  font-size: 0.75rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.breadcrumbs a {
  color: var(--emerald);
  text-decoration: underline;
}

/* 3. Hero & Banners */
.hero-box {
  padding: 16px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  text-align: center;
}

.hero-img-wrap {
  width: 100%;
  max-width: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  margin-bottom: 14px;
  background: var(--surface);
  aspect-ratio: 430 / 240;
  box-sizing: border-box;
}

.hero-img {
  width: 100%;
  max-width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.feature-img-card {
  width: 100%;
  max-width: 100%;
  margin: 18px 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  box-sizing: border-box;
}

.feature-img-card img {
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  aspect-ratio: 430 / 240;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.feature-img-card:hover img {
  transform: scale(1.02);
}

.feature-img-caption {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: 9px 12px;
  background: rgba(10, 31, 22, 0.95);
  border-top: 1px solid rgba(16, 185, 129, 0.15);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  letter-spacing: 0.3px;
  line-height: 1.4;
}
}

h1.page-title {
  font-size: 1.45rem;
  font-weight: 900;
  line-height: 1.25;
  color: #fff;
  margin-bottom: 10px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.5);
}

.badge-tag {
  display: inline-block;
  padding: 4px 10px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid var(--emerald);
  border-radius: 12px;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--emerald);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* 4. Expert Insight Callout */
.expert-insight {
  margin: 12px 16px;
  padding: 12px 14px;
  background: rgba(16, 185, 129, 0.08);
  border-left: 3px solid var(--emerald);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.8rem;
  color: #cbd5e1;
  font-style: italic;
}

.expert-insight strong {
  color: var(--gold-light);
  font-style: normal;
}

/* 5. TL;DR Direct Answer Capsule */
.tldr {
  margin: 12px 16px;
  padding: 14px 16px;
  background: linear-gradient(145deg, rgba(20, 56, 41, 0.8), rgba(26, 71, 52, 0.9));
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  font-size: 0.86rem;
  line-height: 1.5;
  box-shadow: inset 0 0 15px rgba(245, 158, 11, 0.05);
}

.tldr-title {
  color: var(--gold-light);
  font-weight: 800;
  font-size: 0.85rem;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* 6. Main CTA Button */
.cta-box {
  padding: 14px 16px;
  text-align: center;
}

.btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px 20px;
  background: linear-gradient(135deg, #fcd34d 0%, #f59e0b 50%, #d97706 100%);
  color: #0b1e15;
  font-size: 1.05rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: var(--radius);
  border: none;
  box-shadow: 0 4px 18px rgba(245, 158, 11, 0.45);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 700;
  border-radius: var(--radius);
  margin-top: 8px;
  transition: background 0.2s ease;
}

.btn-subtext {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 6px;
  display: block;
}

/* 7. Content Sections */
.content-body {
  padding: 0 16px 20px;
  font-size: 0.92rem;
  color: #e2e8f0;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow-x: hidden;
}

.content-body h2 {
  font-size: 1.18rem;
  font-weight: 800;
  color: var(--gold-light);
  margin: 22px 0 10px;
  line-height: 1.35;
  display: flex;
  align-items: center;
  gap: 8px;
}

.content-body h3 {
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--emerald);
  margin: 16px 0 8px;
}

.content-body p {
  margin-bottom: 12px;
  line-height: 1.6;
}

.content-body ul, .content-body ol {
  margin: 8px 0 14px 20px;
}

.content-body li {
  margin-bottom: 6px;
}

/* 8. Numbered Process Steps */
.steps {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 14px 0;
}

.step-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.step-num {
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: #0b1e15;
  font-weight: 900;
  font-size: 0.85rem;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.step-content strong {
  display: block;
  font-size: 0.9rem;
  color: #fff;
  margin-bottom: 2px;
}

.step-content span {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* 9. Bespoke Data Tables */
.table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin: 16px 0;
  background: var(--surface);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  text-align: left;
}

.data-table th {
  background: rgba(4, 120, 87, 0.4);
  color: var(--gold-light);
  font-weight: 800;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.data-table td {
  padding: 9px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  color: #cbd5e1;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.02);
}

/* 10. Game & Category Cards */
.card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 14px 0;
}

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

.game-card-img {
  width: 100%;
  aspect-ratio: 300 / 200;
  object-fit: cover;
  display: block;
  background: #091a12;
}

.game-card-body {
  padding: 8px 10px 10px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.game-card-title {
  font-size: 0.84rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-card-meta {
  font-size: 0.72rem;
  color: var(--emerald);
  font-weight: 700;
  margin-bottom: 6px;
}

.game-card-btn {
  margin-top: auto;
  padding: 5px 8px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: #0b1e15;
  font-size: 0.72rem;
  font-weight: 800;
  text-align: center;
  border-radius: 4px;
}

/* 11. Rotating Sibling Guides Grid */
.related-guides-box {
  margin: 20px 0;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.related-guides-title {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--gold-light);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.related-links-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
}

.related-link-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: var(--surface-card);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  color: #e2e8f0;
  transition: all 0.15s ease;
}

.related-link-pill:hover {
  border-color: var(--emerald);
  color: var(--gold-light);
}

.related-link-arrow {
  color: var(--emerald);
  font-weight: 900;
}

/* 12. Accordion FAQ */
.faq-box {
  margin: 20px 0;
}

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

.faq-item summary {
  padding: 12px 14px;
  font-size: 0.88rem;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 1.1rem;
  color: var(--gold-light);
  font-weight: 900;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item[open] summary {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  background: var(--surface-card);
}

.faq-answer {
  padding: 12px 14px;
  font-size: 0.82rem;
  color: #cbd5e1;
  line-height: 1.55;
  background: rgba(11, 30, 21, 0.5);
}

/* 13. Player Safeguards Trust Bar */
.compliance-trust-bar {
  margin: 24px 0 16px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: var(--radius-sm);
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.compliance-trust-bar a {
  color: #ddd;
  text-decoration: underline;
  margin: 0 4px;
}

/* 14. Footer */
.ftr {
  padding: 20px 16px 10px;
  text-align: center;
  font-size: 0.74rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  background: #091a12;
}

.ftr-disclaimer {
  line-height: 1.5;
  margin-bottom: 12px;
}

.ftr-badges {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.ftr-badge {
  padding: 4px 8px;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 0.68rem;
  color: var(--emerald);
  font-weight: 700;
}

/* 15. Fixed Bottom Navigation */
.bottom-nav {
  position: fixed;
  bottom: 0;
  width: 100%;
  max-width: 430px;
  background: rgba(11, 30, 21, 0.98);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  height: 64px;
  z-index: 1000;
  box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.5);
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-muted);
  width: 20%;
  height: 100%;
  gap: 3px;
  transition: color 0.15s ease;
}

.nav-item svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.nav-item.active, .nav-item:hover {
  color: var(--gold-light);
}

.nav-item.nav-special {
  color: #0b1e15;
}

.nav-item.nav-special .nav-special-pill {
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 12px var(--gold-glow);
  margin-top: -16px;
}

