/* =========================================================
   bestnokyccasinoaustralia.com — main stylesheet
   ========================================================= */

:root {
  /* Palette: deep eucalyptus teal + galah pink + reef aqua */
  --bg: #0f3d42;
  --bg-deep: #0b2f33;
  --surface-soft: rgba(255, 255, 255, 0.05);
  --text: #e4f2ef;
  --muted: #a4c6c0;
  --heading: #ffffff;
  --accent: #e8337f;        /* galah pink */
  --accent-hover: #ff4f9a;
  --aqua: #5ee6c8;          /* reef aqua */
  --border: rgba(255, 255, 255, 0.12);

  --font-body: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-head: "Unbounded", "Manrope", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;

  --container: 1180px;
  --content: 880px;
  --header-h: 72px;
}

/* ---------- Reset / base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

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

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.7;
  color: var(--text);
  background-color: var(--bg);
  background-image:
    radial-gradient(900px 520px at 0% 0%, rgba(94, 230, 200, 0.14), transparent 60%),
    radial-gradient(800px 480px at 100% 20%, rgba(232, 51, 127, 0.12), transparent 60%),
    linear-gradient(180deg, #11454a 0%, var(--bg) 45%, var(--bg-deep) 100%);
  overflow-x: clip; /* keeps the sticky header working, unlike overflow:hidden */
}

img, svg, video { max-width: 100%; height: auto; }
a { color: inherit; }

:focus-visible {
  outline: 3px solid var(--aqua);
  outline-offset: 3px;
  border-radius: 6px;
}

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

/* ---------- Header buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 22px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease, transform .2s ease;
}

.btn--ghost {
  color: var(--aqua);
  border: 2px solid var(--aqua);
  background: transparent;
}
.btn--ghost:hover { background: var(--aqua); color: var(--bg-deep); }

.btn--primary {
  color: #fff;
  border: 2px solid var(--accent);
  background: var(--accent);
  letter-spacing: .03em;
  box-shadow: 0 8px 22px rgba(232, 51, 127, 0.35);
}
.btn--primary:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  transform: translateY(-2px);
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 47, 51, 0.88);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: var(--header-h);
}

.header__logo { display: inline-flex; flex-shrink: 0; }
.header__logo img { display: block; width: auto; height: 40px; }

.header__actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* =========================================================
   MAIN — content styles (plain tags, no wrappers needed)
   ========================================================= */
main {
  flex: 1 0 auto;
  width: calc(100% - 40px);
  max-width: var(--content);
  min-width: 0;
  margin: 40px auto 56px;
  padding: 52px 60px;
  background: linear-gradient(180deg, rgba(22, 86, 93, 0.78), rgba(19, 73, 79, 0.78));
  border: 1px solid var(--border);
  border-radius: 28px;
  box-shadow: 0 30px 70px rgba(4, 22, 25, 0.35);
  overflow-wrap: break-word;
  word-wrap: break-word;
}

main > :first-child { margin-top: 0; }
main > :last-child { margin-bottom: 0; }

/* Headings */
main h1, main h2, main h3, main h4, main h5, main h6 {
  font-family: var(--font-head);
  color: var(--heading);
  line-height: 1.25;
  font-weight: 700;
  margin: 1.7em 0 .6em;
}
main h1 {
  font-size: clamp(28px, 4.6vw, 44px);
  line-height: 1.15;
  margin-top: 0;
  margin-bottom: .55em;
}
main h2 { font-size: clamp(22px, 3.2vw, 30px); }
main h2::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  margin-top: 14px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--aqua), var(--accent));
}
main h3 { font-size: clamp(19px, 2.4vw, 23px); }
main h4 { font-size: 19px; }
main h5 { font-size: 17px; }
main h6 { font-size: 15px; color: var(--muted); }

/* Text */
main p { margin: 0 0 1.15em; }

main a:not([class]) {
  color: var(--aqua);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color .2s ease;
}
main a:not([class]):hover { color: #fff; }

main strong, main b { color: #fff; font-weight: 700; }
main em, main i { font-style: italic; }
main small { font-size: .85em; color: var(--muted); }
main mark {
  background: rgba(94, 230, 200, 0.2);
  color: #fff;
  padding: 0 .25em;
  border-radius: 4px;
}

/* Lists */
main ul,
main ol {
  margin: 0 0 1.3em;
  padding: 0;
  list-style: none;
}
main li {
  position: relative;
  padding-left: 32px;
  margin-bottom: .55em;
}
main li > ul,
main li > ol { margin: .55em 0 0; }

main ul > li::before {
  content: "";
  position: absolute;
  left: 8px;
  top: .7em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--aqua);
  box-shadow: 0 0 0 4px rgba(94, 230, 200, 0.16);
}

main ol { counter-reset: list; }
main ol > li { counter-increment: list; }
main ol > li::before {
  content: counter(list);
  position: absolute;
  left: 0;
  top: .22em;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 23px;
  height: 23px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
}

/* Quotes, rules, code */
main blockquote {
  margin: 28px 0;
  padding: 20px 24px;
  border-left: 4px solid var(--aqua);
  border-radius: 0 16px 16px 0;
  background: var(--surface-soft);
  font-style: italic;
  color: #fff;
}
main blockquote p:last-child { margin-bottom: 0; }

main hr {
  height: 1px;
  margin: 36px 0;
  border: 0;
  background: var(--border);
}

main code {
  padding: .15em .4em;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.25);
  font-size: .9em;
}
main pre {
  max-width: 100%;
  margin: 24px 0;
  padding: 18px;
  overflow-x: auto;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.3);
}
main pre code { padding: 0; background: none; }

/* Images & media */
main img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 30px auto;
  border-radius: 18px;
}
main figure { margin: 30px 0; }
main figure img { margin: 0 auto; }
main figcaption {
  margin-top: 10px;
  text-align: center;
  font-size: 14px;
  color: var(--muted);
}
main iframe,
main video {
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 30px 0;
  border: 0;
  border-radius: 18px;
}
main iframe { height: auto; aspect-ratio: 16 / 9; }

/* Tables */
main table {
  width: 100%;
  margin: 30px 0;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  font-size: 15px;
  line-height: 1.5;
  background: rgba(11, 47, 51, 0.45);
}
main caption {
  caption-side: top;
  padding: 0 0 10px;
  text-align: left;
  font-size: 14px;
  color: var(--muted);
}
main th,
main td {
  padding: 14px 16px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--border);
}
main th {
  background: rgba(94, 230, 200, 0.14);
  color: #fff;
  font-weight: 700;
}
main tr:last-child > td { border-bottom: 0; }
main tbody tr:nth-child(even) > td { background: rgba(255, 255, 255, 0.03); }
main tbody tr:hover > td { background: rgba(94, 230, 200, 0.07); }

/* Centered CTA button (content template) */
main .btn-cta {
  position: relative;
  display: block;
  width: fit-content;
  max-width: 100%;
  margin: 36px auto;
  padding: 17px 44px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-head);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: .02em;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 12px 30px rgba(232, 51, 127, 0.4), inset 0 -3px 0 rgba(0, 0, 0, 0.18);
  transition: transform .2s ease, background-color .2s ease, box-shadow .2s ease;
}
main .btn-cta::after {
  content: "";
  position: absolute;
  top: 0;
  left: -60%;
  width: 40%;
  height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-20deg);
  animation: cta-shine 3.6s ease-in-out infinite;
}
main .btn-cta:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(232, 51, 127, 0.5), inset 0 -3px 0 rgba(0, 0, 0, 0.18);
}
@keyframes cta-shine {
  0%, 60% { left: -60%; }
  100% { left: 130%; }
}

/* ---------- Showcase (casino list) ---------- */
.showcase {
  display: grid;
  gap: 16px;
  margin: 34px 0 40px;
}

.casino-card {
  position: relative;
  display: grid;
  grid-template-columns: 44px 170px 1fr auto;
  align-items: center;
  gap: 20px;
  padding: 18px 22px;
  background: rgba(11, 47, 51, 0.6);
  border: 1px solid var(--border);
  border-radius: 20px;
}

.casino-card--top {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent), 0 14px 34px rgba(232, 51, 127, 0.18);
}
.casino-card__badge {
  position: absolute;
  top: -11px;
  left: 22px;
  padding: 2px 12px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.6;
}

.casino-card__rank {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid var(--aqua);
  color: var(--aqua);
  font-family: var(--font-head);
  font-size: 18px;
  font-weight: 700;
}

.casino-card__logo {
  display: block;
  width: 170px;
  height: 68px;
  margin: 0;
  padding: 8px;
  object-fit: contain;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
}

.casino-card__body { min-width: 0; }
.casino-card__name {
  margin: 0 0 4px;
  font-size: 18px;
}
.casino-card__desc {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--muted);
}

.casino-card__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 26px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  font-size: 15px;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .2s ease, transform .2s ease;
}
.casino-card__btn:hover { background: var(--accent-hover); transform: translateY(-2px); }

/* ---------- Author box ---------- */
.author {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 22px;
  align-items: start;
  margin: 44px 0 0;
  padding: 26px 28px;
  background: rgba(11, 47, 51, 0.55);
  border: 1px solid var(--border);
  border-left: 4px solid var(--aqua);
  border-radius: 20px;
}
.author__avatar {
  display: block;
  width: 96px;
  height: 96px;
  margin: 0;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--aqua);
}
.author__info { min-width: 0; }
.author__label {
  margin: 0 0 2px;
  font-size: 14px;
  font-weight: 700;
  color: var(--aqua);
}
.author__name {
  margin: 0 0 10px;
  font-family: var(--font-head);
  font-size: 20px;
  line-height: 1.3;
  color: #fff;
}
.author__text {
  margin: 0;
  font-style: italic;
}

/* ---------- 404 ---------- */
main.error-page {
  text-align: center;
  padding-top: 64px;
  padding-bottom: 64px;
}
.error-page .error-page__code {
  max-width: none;
  margin: 0 0 10px;
  font-family: var(--font-head);
  font-size: clamp(96px, 22vw, 180px);
  font-weight: 700;
  line-height: 1;
  color: var(--aqua);
  text-shadow: 6px 6px 0 var(--accent);
}
main.error-page p {
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
  color: var(--muted);
}

/* ---------- Footer ---------- */
.site-footer {
  padding: 40px 0 32px;
  background: var(--bg-deep);
  border-top: 1px solid var(--border);
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
}
.footer__inner { display: grid; gap: 24px; }

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
}
.footer__nav a {
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}
.footer__nav a:hover { color: var(--aqua); }

.footer__orgs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.footer__orgs-title {
  margin: 0 6px 0 0;
  font-weight: 700;
  color: #fff;
}
.footer__orgs ul {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.footer__orgs a {
  display: inline-block;
  padding: 7px 15px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: border-color .2s ease, color .2s ease;
}
.footer__orgs a:hover { border-color: var(--aqua); color: var(--aqua); }

.footer__text {
  margin: 0;
  padding-top: 22px;
  border-top: 1px solid var(--border);
}

/* ---------- Popup ---------- */
.popup {
  position: fixed;
  left: 50%;
  bottom: 20px;
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 14px;
  width: calc(100% - 32px);
  max-width: 560px;
  padding: 14px 52px 14px 14px;
  background: #0d363b;
  border: 1px solid rgba(94, 230, 200, 0.4);
  border-radius: 20px;
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.45);
  opacity: 0;
  transform: translate(-50%, calc(100% + 40px));
  transition: transform .45s cubic-bezier(.2, .9, .3, 1.15), opacity .3s ease;
}
.popup[hidden] { display: none; }
.popup.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}
.popup__logo {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  object-fit: contain;
  border-radius: 12px;
}
.popup__text {
  flex: 1;
  min-width: 0;
  margin: 0;
  font-size: 14px;
  line-height: 1.45;
  color: #fff;
}
.popup__btn {
  flex-shrink: 0;
  padding: 10px 20px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .2s ease;
}
.popup__btn:hover { background: var(--accent-hover); }
.popup__close {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.popup__close:hover { background: rgba(255, 255, 255, 0.18); }

/* ---------- Back to top ---------- */
.to-top {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 150;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--aqua);
  color: var(--bg-deep);
  cursor: pointer;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.35);
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px);
  transition: opacity .25s ease, visibility .25s ease, transform .25s ease, bottom .3s ease, background-color .2s ease;
}
.to-top svg { width: 22px; height: 22px; }
.to-top:hover { background: #fff; }
.to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 900px) {
  /* lift the arrow above the popup when they would overlap */
  body.popup-open .to-top { bottom: calc(var(--popup-offset, 0px) + 32px); }

  .casino-card { grid-template-columns: 44px 150px 1fr; }
  .casino-card__logo { width: 150px; height: 60px; }
  .casino-card__btn { grid-column: 1 / -1; width: 100%; }
}

@media (max-width: 768px) {
  body { font-size: 16px; }

  main {
    width: calc(100% - 24px);
    margin: 20px auto 32px;
    padding: 30px 22px;
    border-radius: 20px;
  }

  /* Tables: scroll sideways inside their own box, never widen the page */
  main table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 12px;
  }
  main th,
  main td { min-width: 130px; }
  main th { white-space: nowrap; }

  main img { margin: 24px auto; border-radius: 14px; }
}

@media (max-width: 640px) {
  .casino-card {
    grid-template-columns: 40px 1fr;
    gap: 14px;
    padding: 22px 16px 16px;
  }
  .casino-card__rank { width: 40px; height: 40px; font-size: 16px; }
  .casino-card__logo { width: 140px; height: 56px; }
  .casino-card__body { grid-column: 1 / -1; }

  .author {
    grid-template-columns: 64px 1fr;
    gap: 16px;
    padding: 20px 18px;
  }
  .author__avatar { width: 64px; height: 64px; }
}

@media (max-width: 480px) {
  :root { --header-h: 62px; }

  .container { padding: 0 12px; }
  .header__inner { gap: 10px; }
  .header__logo img { height: 30px; }
  .header__actions { gap: 6px; }
  .btn { padding: 9px 13px; font-size: 12.5px; }

  main {
    width: calc(100% - 16px);
    margin: 12px auto 24px;
    padding: 26px 16px;
  }
  main .btn-cta { width: 100%; padding: 16px 20px; font-size: 16px; }

  .popup {
    flex-wrap: wrap;
    bottom: 12px;
    width: calc(100% - 20px);
    padding: 14px 46px 14px 14px;
  }
  .popup__logo { width: 40px; height: 40px; }
  .popup__btn { width: 100%; }

  .to-top { right: 14px; bottom: 14px; width: 46px; height: 46px; }
}

@media (max-width: 360px) {
  .header__logo img { height: 26px; }
  .btn { padding: 8px 10px; font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}


/* ---------- Note under the casino list ---------- */
main .showcase-note {
  margin: -22px 0 34px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--muted);
}

/* ---------- Notice box (legal status) ---------- */
main .notice {
  margin: 28px 0;
  padding: 22px 26px;
  background: rgba(232, 51, 127, 0.08);
  border: 1px solid rgba(232, 51, 127, 0.55);
  border-radius: 18px;
}
main .notice > :last-child { margin-bottom: 0; }

@media (max-width: 768px) {
  main .notice { padding: 18px 16px; border-radius: 14px; }
  main th { white-space: normal; }
}
