/* ============================================================
   Best Online Casino Australia — v2 LIGHT theme stylesheet
   ============================================================ */

:root {
  --bg:            #f5f7fa;
  --surface:       #ffffff;
  --surface-2:     #eef1f6;
  --border:        #e2e6ec;
  --text:          #17202e;
  --text-muted:    #5c6775;
  --primary:       #0e8f66;   /* emerald */
  --primary-dark:  #0b7554;
  --accent:        #c98a12;   /* gold */
  --accent-soft:   #fbf3df;
  --warn:          #d94f4f;
  --radius:        14px;
  --radius-sm:     9px;
  --shadow:        0 6px 20px rgba(23, 32, 46, .08);
  --shadow-lg:     0 14px 40px rgba(23, 32, 46, .12);
  --max:           1120px;
  --header-h:      66px;
  --font:          -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
}

.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: 20px; }

a { color: var(--primary-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 { line-height: 1.25; color: #0f1826; }
h2 { font-size: clamp(1.45rem, 3vw, 2.05rem); margin-top: 0; }
h3 { font-size: 1.16rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  height: var(--header-h);
  background: rgba(255,255,255,.9);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 100%; }

.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; color: #0f1826; }
.brand:hover { text-decoration: none; }
.brand-mark {
  display: grid; place-items: center;
  width: 34px; height: 34px; border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff; font-weight: 800; font-size: .85rem;
}
.brand-text { font-size: 1.05rem; letter-spacing: .2px; }
.brand-accent { color: var(--primary); }

.main-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.main-nav a {
  display: block; padding: 8px 12px; border-radius: var(--radius-sm);
  color: var(--text-muted); font-size: .92rem; font-weight: 500;
}
.main-nav a:hover, .main-nav a.active { color: var(--primary-dark); background: var(--surface-2); text-decoration: none; }

/* ---------- Nav dropdown (About Us) ---------- */
.has-dropdown { position: relative; }
.dropdown-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  font: inherit; cursor: pointer;
  padding: 8px 12px; border-radius: var(--radius-sm);
  color: var(--text-muted); font-size: .92rem; font-weight: 500;
  background: transparent; border: none;
}
.dropdown-toggle:hover, .has-dropdown.open .dropdown-toggle { color: var(--primary-dark); background: var(--surface-2); }
.dropdown-toggle .caret { font-size: .7rem; transition: transform .2s; }
.has-dropdown.open .dropdown-toggle .caret { transform: rotate(180deg); }
.dropdown-menu {
  position: absolute; top: calc(100% + 6px); right: 0; min-width: 240px;
  list-style: none; margin: 0; padding: 6px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  opacity: 0; visibility: hidden; transform: translateY(-6px); transition: .18s;
  z-index: 120;
}
.has-dropdown:hover .dropdown-menu,
.has-dropdown.open .dropdown-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown-menu li a {
  display: block; padding: 10px 12px; border-radius: var(--radius-sm);
  color: var(--text); font-size: .92rem; font-weight: 500;
}
.dropdown-menu li a:hover { background: var(--surface-2); color: var(--primary-dark); text-decoration: none; }

.nav-toggle {
  display: none; flex-direction: column; gap: 5px;
  width: 42px; height: 42px; padding: 10px;
  background: transparent; border: 1px solid var(--border); border-radius: var(--radius-sm);
  cursor: pointer;
}
.nav-toggle span { display: block; height: 2px; background: var(--text); border-radius: 2px; transition: .25s; }
.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); }

/* ---------- Hero ---------- */
.hero { padding: 48px 0 26px; background: linear-gradient(180deg, #eaf5f0 0%, var(--bg) 70%); }
.eyebrow { text-transform: uppercase; letter-spacing: 2px; font-size: .75rem; color: var(--primary-dark); font-weight: 700; margin: 0 0 10px; }
.hero h1 { font-size: clamp(1.9rem, 5vw, 3rem); margin: 0 0 22px; }
.hero h1 .year { color: var(--primary); }

.byline { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.author-avatar { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; border: 3px solid #fff; box-shadow: var(--shadow); }
.byline-name { display: block; font-weight: 600; color: #0f1826; }
.byline-role { display: block; font-size: .85rem; color: var(--text-muted); }

.hero-figure { margin: 0 0 24px; }
.hero-figure img { width: 100%; height: auto; border-radius: var(--radius); box-shadow: var(--shadow-lg); display: block; }

.lead { font-size: 1.16rem; color: #33404f; }

/* ---------- Top-10 casino widget ---------- */
.cw-widget { margin: 4px 0 30px; }
.cw-casino-list { display: grid; gap: 12px; }

.cw-casino-card {
  display: grid;
  grid-template-columns: 44px 100px minmax(0, 1.3fr) minmax(0, 1.6fr) auto;
  align-items: center;
  gap: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 18px 12px 12px;
  box-shadow: var(--shadow);
  transition: border-color .2s, transform .12s, box-shadow .2s;
}
.cw-casino-card:hover { border-color: rgba(14,143,102,.5); transform: translateY(-2px); box-shadow: var(--shadow-lg); }

.cw-rank {
  display: grid; place-items: center;
  width: 34px; height: 34px; border-radius: 9px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff; font-weight: 800; font-size: 1rem;
}
.cw-casino-card:nth-child(1) .cw-rank,
.cw-casino-card:nth-child(2) .cw-rank,
.cw-casino-card:nth-child(3) .cw-rank { background: linear-gradient(135deg, #e0a400, var(--accent)); }

.cw-card-image {
  height: 62px; border-radius: var(--radius-sm); overflow: hidden;
  background: #fff; border: 1px solid var(--border);
  display: grid; place-items: center; padding: 6px;
}
.cw-card-image img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }

.cw-card-content { min-width: 0; }
.cw-info h3 { margin: 0 0 4px; font-size: 1.04rem; color: #0f1826; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cw-stars { color: var(--accent); font-size: .95rem; letter-spacing: 1px; line-height: 1; }
.cw-half-star { opacity: .3; }

.cw-offers { min-width: 0; }
.cw-bonus-text { color: #33404f; font-size: .93rem; font-weight: 500; line-height: 1.4; }

.cw-actions { display: flex; justify-content: flex-end; }
.cw-btn {
  display: inline-block; padding: 12px 30px; border-radius: var(--radius-sm);
  font-weight: 700; font-size: .93rem; text-align: center; white-space: nowrap;
  transition: transform .12s, filter .12s, box-shadow .2s;
}
.cw-btn:hover { text-decoration: none; transform: translateY(-1px); }
.cw-btn-primary { background: var(--primary); color: #fff; box-shadow: 0 4px 12px rgba(14,143,102,.28); }
.cw-btn-primary:hover { background: var(--primary-dark); }

@media (max-width: 720px) {
  .cw-casino-card {
    grid-template-columns: 38px 64px 1fr;
    grid-template-areas:
      "rank image content"
      "rank offers offers"
      "rank actions actions";
    column-gap: 12px; row-gap: 10px;
  }
  .cw-rank { grid-area: rank; align-self: start; margin-top: 2px; }
  .cw-card-image { grid-area: image; height: 48px; }
  .cw-card-content { grid-area: content; align-self: center; }
  .cw-offers { grid-area: offers; }
  .cw-actions { grid-area: actions; justify-content: stretch; }
  .cw-actions .cw-btn { flex: 1; }
}

/* ---------- Layout ---------- */
.layout { padding-bottom: 40px; }
.article > section { padding: 34px 0; border-top: 1px solid var(--border); }
.article > section:first-child { border-top: none; }
.article p { color: #33404f; }
.note { border-left: 4px solid var(--primary); padding: 12px 18px; background: #eaf5f0; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; color: #23415c; }
.disclaimer { font-style: italic; color: var(--text-muted); font-size: .92rem; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); margin: 20px 0; box-shadow: var(--shadow); -webkit-overflow-scrolling: touch; background: var(--surface); }
table { width: 100%; border-collapse: collapse; min-width: 560px; font-size: .94rem; }
thead th { background: var(--surface-2); color: #0f1826; text-align: left; padding: 13px 15px; font-weight: 700; white-space: nowrap; }
tbody td { padding: 12px 15px; border-top: 1px solid var(--border); color: #33404f; }
tbody tr:nth-child(even) { background: #fafbfc; }
tbody tr:hover { background: #eef7f3; }
.rank { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--primary); color: #fff; font-weight: 800; font-size: .85rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; padding: 10px 18px; border-radius: var(--radius-sm);
  background: var(--primary); color: #fff; font-weight: 700; font-size: .9rem;
  border: none; cursor: pointer; transition: transform .12s, background .12s; white-space: nowrap;
}
.btn:hover { background: var(--primary-dark); transform: translateY(-1px); text-decoration: none; }
.btn-sm { padding: 6px 14px; font-size: .82rem; }

/* ---------- Cards ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin-top: 20px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.card h3 { margin: 0 0 8px; color: #0f1826; }
.card p { margin: 0; color: var(--text-muted); font-size: .95rem; }
.card-warn { border-color: rgba(217,79,79,.35); background: #fdf4f4; }
.card-warn h3 { color: var(--warn); }

/* ---------- Reviews ---------- */
.review { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px 24px; margin-bottom: 14px; box-shadow: var(--shadow); }
.review h3 { margin: 0 0 8px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.review p { margin: 0 0 10px; color: #33404f; }
.review p:last-child { margin-bottom: 0; }
.tag { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; padding: 3px 10px; border-radius: 20px; background: var(--accent-soft); color: var(--accent); border: 1px solid rgba(201,138,18,.28); }
.review-watch { border-color: rgba(201,138,18,.4); background: #fffdf8; }

/* ---------- Figures ---------- */
.figure { margin: 24px 0; text-align: center; }
.figure img { max-width: 100%; height: auto; border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.figure-narrow img { max-width: 400px; }
figcaption { margin-top: 10px; font-size: .88rem; color: var(--text-muted); }

/* ---------- Steps ---------- */
.steps { counter-reset: step; list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 14px; }
.steps li { position: relative; padding: 18px 18px 18px 62px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); color: #33404f; box-shadow: var(--shadow); }
.steps li::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 16px; top: 16px;
  width: 32px; height: 32px; display: grid; place-items: center;
  background: var(--primary); color: #fff; border-radius: 9px; font-weight: 800;
}

/* ---------- FAQ ---------- */
.faq-list { display: grid; gap: 10px; margin-top: 20px; }
.faq-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.faq-item summary {
  cursor: pointer; padding: 17px 46px 17px 20px; position: relative;
  font-weight: 600; color: #0f1826; list-style: none; user-select: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%);
  font-size: 1.4rem; color: var(--primary); transition: transform .2s;
}
.faq-item[open] summary::after { content: "−"; }
.faq-item summary:hover { background: var(--surface-2); }
.faq-body { padding: 0 20px 18px; }
.faq-body p { margin: 0; color: var(--text-muted); }

/* ---------- Responsible gambling banner ---------- */
.rg-banner { background: #0f1826; color: #d7dde5; padding: 44px 0; }
.rg-banner h2 { color: #fff; }
.rg-banner p { color: #b6c0cc; }
.rg-help { list-style: none; padding: 0; margin: 18px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.rg-help li { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); border-radius: var(--radius-sm); padding: 13px 16px; color: #e4e9ef; font-size: .95rem; }

/* ---------- Footer ---------- */
.site-footer { background: #0f1826; border-top: 1px solid rgba(255,255,255,.08); padding-top: 46px; }
.footer-grid { display: grid; grid-template-columns: 1.7fr repeat(4, 1fr); gap: 28px; }
.site-footer .brand { color: #fff; }
.site-footer .brand-accent { color: var(--primary); }
.footer-about { color: #97a2b0; font-size: .9rem; margin: 14px 0; }
.age-badge { display: inline-grid; place-items: center; width: 40px; height: 40px; border: 2px solid var(--warn); border-radius: 50%; color: #ff8080; font-weight: 800; margin: 0; }
.footer-col h4 { margin: 0 0 12px; color: #fff; font-size: .95rem; }
.footer-col ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.footer-col ul li { color: #97a2b0; font-size: .9rem; }
.footer-col ul li a { color: #97a2b0; }
.footer-col ul li a:hover { color: var(--primary); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.08); margin-top: 36px; padding: 20px 0; }
.footer-bottom p { margin: 0; color: #6c7683; font-size: .82rem; text-align: center; }

/* ---------- Back to top ---------- */
.back-to-top {
  position: fixed; right: 22px; bottom: 22px; z-index: 90;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--primary); color: #fff; border: none; cursor: pointer;
  font-size: 1.3rem; font-weight: 700; box-shadow: var(--shadow-lg);
  opacity: 0; visibility: hidden; transform: translateY(10px); transition: .25s;
}
.back-to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top:hover { background: var(--primary-dark); }

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .nav-toggle { display: flex; }
  .main-nav {
    position: fixed; inset: var(--header-h) 0 auto 0;
    background: var(--surface); border-bottom: 1px solid var(--border);
    max-height: 0; overflow: hidden; transition: max-height .3s ease;
    box-shadow: var(--shadow);
  }
  .main-nav.open { max-height: 420px; }
  .main-nav ul { flex-direction: column; gap: 0; padding: 8px; }
  .main-nav a { padding: 12px; border-radius: var(--radius-sm); }

  /* dropdown becomes inline accordion on mobile */
  .dropdown-toggle { width: 100%; justify-content: space-between; }
  .dropdown-menu {
    position: static; opacity: 1; visibility: visible; transform: none;
    box-shadow: none; border: none; background: transparent;
    min-width: 0; max-height: 0; overflow: hidden; padding: 0; transition: max-height .25s;
  }
  .has-dropdown.open .dropdown-menu { max-height: 340px; padding: 2px 0 6px 12px; }
  .dropdown-menu li a { color: var(--text-muted); }
}
@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
  .hero { padding-top: 32px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
