/* ============================================================
   JQK Bet Brasil — style.css
   Cream paper / amber / clay palette, humanist sans-serif
   ============================================================ */

/* --- Reset & base ------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Segoe UI', Optima, Candara, 'Noto Sans', sans-serif;
  background: #F5ECD7;
  color: #2C1A0E;
  line-height: 1.65;
  overflow-x: hidden;
  max-width: 100vw;
}

img { display: block; max-width: 100%; height: auto; }
a { color: #8B3A2A; text-decoration: underline; }
a:hover { color: #C97B2E; }

/* --- Site wrapper ------------------------------------------ */
.site-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* --- Header ------------------------------------------------ */
.site-header {
  background: #2C1A0E;
  color: #F5ECD7;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0 1rem;
  height: 60px;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: #F5ECD7;
  text-decoration: none;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  white-space: nowrap;
  flex-shrink: 0;
}

.brand-mark { border-radius: 4px; }

/* Nav toggle (mobile) */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: transparent;
  border: 1px solid rgba(245,236,215,0.3);
  border-radius: 6px;
  cursor: pointer;
  padding: 8px;
  flex-shrink: 0;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: #F5ECD7;
  border-radius: 2px;
  transition: transform 0.2s, opacity 0.2s;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Primary nav */
.primary-nav {
  flex: 1;
  overflow: hidden;
}

.primary-nav > p {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.5rem;
  align-items: center;
}

.primary-nav > p > a {
  color: #F5ECD7;
  text-decoration: none;
  font-size: 0.82rem;
  padding: 0.3rem 0.45rem;
  border-radius: 4px;
  white-space: nowrap;
  min-height: 44px;
  display: flex;
  align-items: center;
  transition: background 0.15s;
}

.primary-nav > p > a:hover {
  background: rgba(201,123,46,0.25);
  color: #F5ECD7;
}

/* Mobile nav CTA inside the collapsed nav */
.nav-cta-mobile {
  display: none;
  gap: 0.5rem;
  padding: 0.75rem 0;
}

/* Header CTA buttons (always visible) */
.header-cta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
  margin-left: auto;
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 1rem;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: opacity 0.15s, background 0.15s;
}

.cta-signup {
  background: #C97B2E;
  color: #fff;
  border: 2px solid #C97B2E;
}

.cta-signup:hover { opacity: 0.88; color: #fff; }

.cta-login {
  background: transparent;
  color: #F5ECD7;
  border: 2px solid #C97B2E;
}

.cta-login:hover { background: rgba(201,123,46,0.15); color: #F5ECD7; }

/* --- Stage label ------------------------------------------- */
.stage-label {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 3px;
  padding: 0.15rem 0.55rem;
  margin-bottom: 0.5rem;
}

.stage-awareness  { background: #e8f4e8; color: #2a6e2a; }
.stage-consideration { background: #fff3e0; color: #8B3A2A; }
.stage-decision   { background: #fdecea; color: #8B3A2A; }

/* --- Eyebrow ----------------------------------------------- */
.eyebrow {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #C97B2E;
  margin-bottom: 0.35rem;
}

/* --- Byline ------------------------------------------------ */
.byline {
  font-size: 0.85rem;
  color: #6b4c30;
  margin: 0.4rem 0 0.75rem;
}

.byline time { font-style: normal; }

/* --- Page desc --------------------------------------------- */
.page-desc {
  font-size: 1.05rem;
  color: #4a2f17;
  margin-top: 0.5rem;
  max-width: 65ch;
}

/* --- Hand-drawn divider ------------------------------------ */
.divider {
  border: none;
  height: 2px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='6'%3E%3Cpath d='M0 3 Q75 0 150 3 Q225 6 300 3' stroke='%23C97B2E' stroke-width='1.5' fill='none'/%3E%3C/svg%3E") repeat-x center;
  margin: 1.5rem 0;
  opacity: 0.6;
}

/* ============================================================
   HOME layout
   ============================================================ */
.main-home { flex: 1; }

/* Hero */
.home-hero {
  background: linear-gradient(135deg, #2C1A0E 0%, #4a2a10 100%);
  color: #F5ECD7;
  padding: 3rem 1.25rem 2.5rem;
}

.home-hero-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
}

.home-hero-text h1 {
  font-size: clamp(1.5rem, 3.5vw, 2.4rem);
  line-height: 1.25;
  color: #F5ECD7;
  margin-bottom: 0.75rem;
}

.home-hero-text .byline { color: #d4b896; }
.home-hero-text .page-desc { color: #e8d8c0; }

.home-hero-figure {
  border-radius: 12px;
  overflow: hidden;
}

.home-hero-figure img {
  width: 100%;
  height: auto;
  border-radius: 12px;
}

/* Home body */
.home-body-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.25rem;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 2.5rem;
  align-items: start;
}

.home-content-col figure {
  margin: 1.25rem 0;
  border-radius: 8px;
  overflow: hidden;
}

/* Child cards (home) */
.child-cards {
  margin-top: 2rem;
}

.child-list {
  list-style: none;
  padding: 0;
  counter-reset: child-counter;
  display: grid;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.child-list li {
  counter-increment: child-counter;
  background: #fff8ef;
  border: 1px solid #e8d4b8;
  border-radius: 8px;
  padding: 0.85rem 1rem 0.85rem 3rem;
  position: relative;
}

.child-list li::before {
  content: counter(child-counter, decimal-leading-zero);
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  font-weight: 700;
  color: #C97B2E;
  font-size: 0.9rem;
}

.child-list li a {
  display: block;
  font-weight: 600;
  font-size: 0.95rem;
  color: #8B3A2A;
  text-decoration: none;
  margin-bottom: 0.2rem;
  min-height: 44px;
  display: flex;
  align-items: center;
}

.child-list li a:hover { color: #C97B2E; text-decoration: underline; }

.child-list li small {
  display: block;
  font-size: 0.8rem;
  color: #6b4c30;
  line-height: 1.45;
}

/* Home sidebar */
.home-sidebar { position: sticky; top: 72px; }

/* ============================================================
   SERVICE layout
   ============================================================ */
.main-service { flex: 1; }

.page-intro-section {
  background: #2C1A0E;
  color: #F5ECD7;
  padding: 2.25rem 1.25rem 2rem;
  display: flex;
  gap: 2rem;
  align-items: flex-start;
  justify-content: center;
}

.page-intro-section > * { max-width: 700px; }

.page-intro-section.no-hero { justify-content: flex-start; }

.page-hero-figure {
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
  max-width: 280px;
}

.page-intro-text h1 {
  font-size: clamp(1.35rem, 3vw, 2rem);
  line-height: 1.3;
  color: #F5ECD7;
  margin-bottom: 0.4rem;
}

.page-intro-text .byline { color: #d4b896; }
.page-intro-text .page-desc { color: #e8d8c0; }

.deco-aside {
  display: none;
}

.service-body-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.25rem;
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 2.5rem;
  align-items: start;
}

.content-body { min-width: 0; }

.content-body figure {
  margin: 1.25rem 0;
  border-radius: 8px;
  overflow: hidden;
}

/* ============================================================
   CASES layout
   ============================================================ */
.main-cases { flex: 1; }

.cases-intro-section {
  background: #2C1A0E;
  color: #F5ECD7;
  padding: 2.25rem 1.25rem 2rem;
}

.cases-intro-inner {
  max-width: 820px;
  margin: 0 auto;
}

.cases-intro-inner h1 {
  font-size: clamp(1.35rem, 3vw, 2rem);
  color: #F5ECD7;
  margin-bottom: 0.4rem;
}

.cases-intro-inner .byline { color: #d4b896; }
.cases-intro-inner .page-desc { color: #e8d8c0; }

.cases-body-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.25rem;
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 2.5rem;
  align-items: start;
}

.cases-content { min-width: 0; }

.cases-figure-row {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin: 1.25rem 0;
}

.cases-figure-row figure {
  flex: 1 1 200px;
  border-radius: 8px;
  overflow: hidden;
}

/* ============================================================
   FAQ layout
   ============================================================ */
.main-faq { flex: 1; }

.faq-hero {
  background: #2C1A0E;
  color: #F5ECD7;
  padding: 2.25rem 1.25rem 2rem;
  text-align: center;
}

.faq-hero h1 {
  font-size: clamp(1.35rem, 3vw, 2rem);
  color: #F5ECD7;
  margin-bottom: 0.4rem;
}

.faq-hero .byline { color: #d4b896; }
.faq-hero .page-desc { color: #e8d8c0; max-width: 60ch; margin: 0.5rem auto 0; }

.faq-body-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.25rem;
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 2.5rem;
  align-items: start;
}

.faq-content { min-width: 0; }

/* ============================================================
   ABOUT layout
   ============================================================ */
.main-about { flex: 1; }

.about-hero {
  background: #2C1A0E;
  color: #F5ECD7;
  padding: 2.5rem 1.25rem 2rem;
  text-align: center;
}

.about-hero h1 {
  font-size: clamp(1.35rem, 3vw, 2rem);
  color: #F5ECD7;
  margin-bottom: 0.4rem;
}

.about-body-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.25rem;
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 2.5rem;
  align-items: start;
}

.about-content { min-width: 0; }

.author-card {
  background: #fff8ef;
  border: 1px solid #e8d4b8;
  border-radius: 10px;
  padding: 1.5rem;
  margin: 1.75rem 0;
}

.author-card h2 {
  font-size: 1.2rem;
  color: #8B3A2A;
  margin-bottom: 0.25rem;
}

.author-card .author-credentials {
  font-size: 0.85rem;
  color: #6b4c30;
  margin-bottom: 0.75rem;
  font-style: italic;
}

.author-card .author-bio {
  font-size: 0.95rem;
  color: #2C1A0E;
  line-height: 1.65;
}

/* ============================================================
   CONTACT layout
   ============================================================ */
.main-contact { flex: 1; }

.contact-hero {
  background: #2C1A0E;
  color: #F5ECD7;
  padding: 2.25rem 1.25rem 2rem;
  text-align: center;
}

.contact-hero h1 {
  font-size: clamp(1.35rem, 2.5vw, 1.9rem);
  color: #F5ECD7;
  margin-bottom: 0.4rem;
}

.contact-body-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.25rem;
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 2.5rem;
  align-items: start;
}

.contact-content { min-width: 0; }

/* ============================================================
   PRIVACY layout
   ============================================================ */
.main-privacy { flex: 1; }

.privacy-hero {
  background: #2C1A0E;
  color: #F5ECD7;
  padding: 2.25rem 1.25rem 2rem;
}

.privacy-hero-inner { max-width: 820px; margin: 0 auto; }

.privacy-hero-inner h1 {
  font-size: clamp(1.25rem, 2.5vw, 1.9rem);
  color: #F5ECD7;
  margin-bottom: 0.4rem;
}

.privacy-body-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.25rem;
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 2.5rem;
  align-items: start;
}

.privacy-content { min-width: 0; }

/* ============================================================
   Shared sidebar
   ============================================================ */
.sidebar {
  background: #fff8ef;
  border: 1px solid #e8d4b8;
  border-radius: 10px;
  padding: 1.25rem;
  position: sticky;
  top: 72px;
}

.sidebar-heading {
  font-size: 1rem;
  color: #8B3A2A;
  margin-bottom: 0.75rem;
}

.sidebar-toc {
  list-style: none;
  padding: 0;
  margin-bottom: 1.25rem;
}

.sidebar-toc li { border-bottom: 1px solid #e8d4b8; }

.sidebar-toc li:last-child { border-bottom: none; }

.sidebar-toc a {
  display: flex;
  align-items: center;
  min-height: 44px;
  font-size: 0.88rem;
  color: #8B3A2A;
  text-decoration: none;
  padding: 0.35rem 0;
}

.sidebar-toc a:hover { color: #C97B2E; text-decoration: underline; }

.sidebar-author {
  border-top: 1px solid #e8d4b8;
  padding-top: 1rem;
  margin-top: 1rem;
}

.sidebar-author strong {
  display: block;
  font-size: 0.9rem;
  color: #2C1A0E;
  margin-bottom: 0.2rem;
}

.author-cred {
  font-size: 0.78rem;
  color: #6b4c30;
  line-height: 1.4;
}

/* ============================================================
   Content body typography
   ============================================================ */
.content-body h2,
.home-content-col h2,
.cases-content h2,
.faq-content h2,
.about-content h2,
.contact-content h2,
.privacy-content h2 {
  font-size: 1.3rem;
  color: #8B3A2A;
  margin: 1.75rem 0 0.5rem;
  line-height: 1.3;
}

.content-body h3,
.home-content-col h3,
.cases-content h3,
.faq-content h3,
.about-content h3,
.contact-content h3,
.privacy-content h3 {
  font-size: 1.1rem;
  color: #2C1A0E;
  margin: 1.25rem 0 0.4rem;
}

.content-body p,
.home-content-col p,
.cases-content p,
.faq-content p,
.about-content p,
.contact-content p,
.privacy-content p {
  margin-bottom: 1rem;
}

.content-body ul,
.content-body ol,
.home-content-col ul,
.home-content-col ol {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}

.content-body li,
.home-content-col li {
  margin-bottom: 0.35rem;
}

.content-body a,
.home-content-col a,
.cases-content a,
.faq-content a,
.about-content a,
.contact-content a,
.privacy-content a {
  color: #8B3A2A;
  text-decoration: underline;
}

.content-body a:hover,
.home-content-col a:hover { color: #C97B2E; }

.content-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.25rem 0;
  font-size: 0.9rem;
  overflow-x: auto;
  display: block;
}

.content-body table th,
.content-body table td {
  padding: 0.55rem 0.75rem;
  border: 1px solid #ddd;
  text-align: left;
}

.content-body table th {
  background: #C97B2E;
  color: #fff;
}

.content-body table tr:nth-child(even) { background: #fff8ef; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  background: #2C1A0E;
  color: #d4b896;
  text-align: center;
  padding: 1.5rem 1.25rem;
}

.site-footer p {
  font-size: 0.85rem;
  margin-bottom: 0.4rem;
}

.site-footer a {
  color: #C97B2E;
  text-decoration: underline;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0 0.25rem;
}

.site-footer a:hover { color: #F5ECD7; }

.responsible-gambling {
  display: block;
  font-size: 0.78rem;
  color: #a08060;
  margin-top: 0.5rem;
  line-height: 1.5;
}

/* ============================================================
   Utilities
   ============================================================ */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 0;
  background: #C97B2E;
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 200;
  text-decoration: none;
  border-radius: 0 0 6px 0;
}

.skip-link:focus { top: 0; }

/* ============================================================
   MOBILE  ≤ 768px
   ============================================================ */
@media (max-width: 768px) {
  /* Header collapses nav */
  .nav-toggle { display: flex; }
  .header-inner { height: 60px; }

  .primary-nav {
    display: none;
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: #2C1A0E;
    padding: 0.75rem 1rem 1rem;
    border-top: 1px solid rgba(201,123,46,0.3);
    z-index: 99;
  }

  .primary-nav.is-open { display: block; }

  .primary-nav > p {
    flex-direction: column;
    gap: 0;
  }

  .primary-nav > p > a {
    font-size: 0.9rem;
    padding: 0.6rem 0.5rem;
    border-bottom: 1px solid rgba(245,236,215,0.08);
    min-height: 44px;
    white-space: normal;
  }

  .nav-cta-mobile {
    display: flex;
    padding: 0.75rem 0 0;
  }

  /* Header CTA still visible on mobile */
  .header-cta { margin-left: auto; }
  .header-cta .cta { font-size: 0.75rem; padding: 0 0.6rem; min-height: 40px; }

  /* Two-column → one column */
  .home-hero-inner,
  .home-body-section,
  .service-body-section,
  .cases-body-section,
  .faq-body-section,
  .about-body-section,
  .contact-body-section,
  .privacy-body-section {
    grid-template-columns: 1fr;
  }

  .sidebar,
  .home-sidebar { position: static; }

  .page-intro-section {
    flex-direction: column;
  }

  .page-hero-figure { max-width: 100%; }

  /* Tables scroll horizontally without causing page scroll */
  .content-body table {
    display: block;
    overflow-x: auto;
    max-width: 100%;
    -webkit-overflow-scrolling: touch;
  }

  /* Ensure nothing overflows viewport */
  .content-body,
  .home-content-col,
  .cases-content,
  .faq-content,
  .about-content,
  .contact-content,
  .privacy-content {
    max-width: 100%;
    overflow-x: hidden;
    word-break: break-word;
  }

  pre, code {
    white-space: pre-wrap;
    word-break: break-word;
    max-width: 100%;
    overflow-x: hidden;
  }

  .home-hero { padding: 2rem 1rem 1.75rem; }

  h1 { font-size: 1.3rem; }

  .child-list li a { font-size: 0.88rem; }
}

@media (max-width: 480px) {
  .header-cta .cta { padding: 0 0.5rem; font-size: 0.72rem; }
  .brand { font-size: 0.9rem; }
}

/* Wide screens */
@media (min-width: 1200px) {
  .home-hero { padding: 4rem 2rem 3rem; }
  .home-hero-text h1 { font-size: 2.5rem; }
}

a[data-cta],button[aria-controls]{min-height:44px;min-width:44px;box-sizing:border-box}main p a{text-decoration:underline}.tbl-scroll{overflow-x:auto;max-width:100%}