/* Ad containers + site legal footer (matches Last War Tools theme) */

.lw-ad-slot {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 980px;
  margin: 12px auto 8px;
  padding: 8px 16px;
  min-height: 90px;
  box-sizing: border-box;
}

.lw-ad-slot--banner {
  min-height: 100px;
}

.lw-ad-slot ins.adsbygoogle {
  display: block;
  width: 100%;
  max-width: 728px;
  margin: 0 auto;
}

.lw-ad-slot:empty {
  display: none;
  min-height: 0;
  padding: 0;
  margin: 0;
}

/* Align bottom chrome with .page width */
.site-legal-bar,
.support-bar {
  max-width: 980px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 16px;
  padding-right: 16px;
  box-sizing: border-box;
}

.site-legal-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 18px auto 14px;
  padding: 14px 18px;
  border-radius: 14px;
  border: 1px solid var(--line-soft, #37506a);
  background: linear-gradient(
    135deg,
    rgba(116, 192, 252, 0.1) 0%,
    rgba(8, 16, 25, 0.72) 100%
  );
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.24);
  font-size: 0.88rem;
  color: var(--muted, #91a4b8);
}

.site-legal-bar nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
}

/* Standalone support bar removed — link lives in footer nav */
.support-bar {
  display: none !important;
}

/* Pill links (also used when main site CSS is not loaded) */
.site-legal-bar nav .page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 13px;
  border: 1px solid var(--line, #2b3d51);
  border-radius: 999px;
  background: rgba(8, 16, 25, 0.66);
  color: var(--muted, #91a4b8);
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  transition:
    border-color 140ms ease,
    color 140ms ease,
    box-shadow 140ms ease;
}

.site-legal-bar nav .page-link:hover,
.site-legal-bar nav .page-link:focus-visible {
  color: var(--text, #e4edf7);
  border-color: rgba(116, 192, 252, 0.42);
  outline: none;
}

.site-legal-bar nav .page-link--support {
  border-color: rgba(255, 146, 43, 0.45);
  background: rgba(255, 146, 43, 0.1);
  color: #ffd8a8;
}

.site-legal-bar nav .page-link--support:hover,
.site-legal-bar nav .page-link--support:focus-visible {
  color: #ffe8cc;
  border-color: rgba(255, 146, 43, 0.8);
  background: rgba(255, 146, 43, 0.2);
}

/* Cookie / ads consent — same panel + buttons as the rest of the site */
.lw-cookie-notice {
  position: fixed;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 12000;
  width: calc(100% - 32px);
  max-width: 520px;
  margin: 0;
  padding: 16px 18px;
  border-radius: 14px;
  border: 1px solid var(--line-soft, #37506a);
  background: linear-gradient(180deg, var(--panel, #111c28) 0%, var(--panel-2, #162434) 100%);
  color: var(--text, #e4edf7);
  font-family: "Bahnschrift", "Trebuchet MS", "Segoe UI", Tahoma, sans-serif;
  font-size: 0.88rem;
  line-height: 1.5;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}

.lw-cookie-notice p {
  margin: 0 0 12px;
  color: var(--muted, #91a4b8);
}

.lw-cookie-notice__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.lw-cookie-notice__actions .action-button {
  margin: 0;
}

.lw-cookie-notice__actions .action-button--quiet {
  background: transparent;
  border-color: var(--line-soft, #37506a);
  color: var(--muted, #91a4b8);
  text-decoration: none;
}

.lw-cookie-notice__actions .action-button--quiet:hover,
.lw-cookie-notice__actions .action-button--quiet:focus-visible {
  border-color: rgba(116, 192, 252, 0.55);
  color: var(--text, #e4edf7);
  text-decoration: none;
}

.lw-cookie-notice.is-hidden {
  display: none;
}

@media (max-width: 600px) {
  .site-legal-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .site-legal-bar nav {
    width: 100%;
  }

  .lw-cookie-notice {
    bottom: max(12px, env(safe-area-inset-bottom, 12px));
    width: calc(100% - 24px);
  }
}
