/* Ark Productions — cookie banner, footer cookie links and the Cookie Policy page.
   Only loaded when GA4_MEASUREMENT_ID is set; uses the tokens from site.css. */

/* ---------- Banner ---------- */
.cc-banner {
  position: fixed; z-index: 400; left: 12px; right: 12px; bottom: 12px;
  display: grid; gap: 16px;
  padding: 20px 20px 18px;
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  background:
    radial-gradient(90% 130% at 0% 0%, rgb(227 6 19 / 0.18), transparent 60%),
    rgb(20 20 23 / 0.96);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  backdrop-filter: saturate(140%) blur(14px);
  box-shadow: 0 24px 60px -18px rgb(0 0 0 / 0.85);
  color: var(--text);
  animation: cc-in 0.45s var(--ease);
}
.cc-banner[hidden] { display: none; }
.cc-banner:focus { outline: none; }
.cc-banner:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }
@keyframes cc-in { from { opacity: 0; transform: translateY(18px); } }
@media (min-width: 640px) {
  .cc-banner { left: 24px; right: auto; bottom: 24px; width: min(480px, 100% - 48px); padding: 24px 24px 22px; }
}
/* keep clear of the maintenance preview bar */
.preview-bar ~ .cc-banner { bottom: 64px; }

.cc-title {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.22em; text-transform: uppercase; color: var(--red);
}
.cc-title::before { content: ''; width: 28px; height: 2px; background: currentColor; border-radius: 2px; }
.cc-text { margin-top: 10px; font-size: 0.92rem; line-height: 1.55; color: var(--text-muted); }
.cc-text a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.cc-text a:hover { color: var(--red-hover); }
.cc-status { margin-top: 8px; font-size: 0.85rem; font-weight: 600; color: var(--text); }
.cc-status[hidden] { display: none; }

/* Accept and Reject look exactly the same (equal prominence). */
.cc-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cc-btn {
  --btn-pad: 0.75rem 1rem;
  font-size: 0.8rem;
  border-color: var(--line-strong); background: rgb(255 255 255 / 0.06); color: var(--text);
}
.cc-btn:hover { border-color: var(--red); background: var(--red); color: #fff; }

.cc-close {
  position: absolute; top: 12px; right: 12px;
  display: grid; place-items: center; width: 36px; height: 36px; padding: 0;
  border: 1px solid var(--line-strong); border-radius: 50%; background: none; cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s;
}
.cc-close[hidden] { display: none; }
.cc-close:hover { background: var(--red); border-color: var(--red); }

/* ---------- Footer links ---------- */
.legal-links { display: inline-flex; flex-wrap: wrap; justify-content: center; gap: 4px 16px; margin-left: 10px; }
.legal-links a,
.legal-links button {
  padding: 0; border: 0; background: none; cursor: pointer;
  font: inherit; color: var(--text-muted);
  text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px;
  transition: color 0.2s, text-decoration-color 0.2s;
}
.legal-links a:hover,
.legal-links button:hover { color: var(--text); text-decoration-color: currentColor; }
@media (max-width: 899px) {
  .legal-links { display: flex; margin: 8px 0 0; }
}

/* ---------- Cookie Policy page ---------- */
.policy { max-width: 820px; padding-bottom: clamp(56px, 8vw, 96px); color: #c9c9d1; }
.policy > * + * { margin-top: 1em; }
.policy h2 {
  margin-top: 2.2em;
  font-size: clamp(1.15rem, 2.2vw, 1.4rem); font-weight: 800; line-height: 1.2;
  letter-spacing: 0.01em; text-transform: uppercase; color: var(--text);
}
.policy h2:first-child { margin-top: 0; }
.policy strong { color: var(--text); }
.policy a { color: var(--text); text-decoration: underline; text-decoration-color: var(--red); text-underline-offset: 3px; }
.policy a:hover { color: var(--red-hover); }
.policy code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.88em;
  padding: 0.1em 0.4em; border-radius: 6px; background: var(--bg-elev-2); color: var(--text); white-space: nowrap;
}
.policy-contacts { display: flex; flex-wrap: wrap; gap: 10px 28px; }
.policy-contacts a { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; text-decoration: none; }
.policy-contacts .icon { color: var(--red); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--bg-elev); }
.policy table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 0.92rem; }
.policy th,
.policy td { padding: 12px 16px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.policy tbody tr:last-child td { border-bottom: 0; }
.policy th { font-size: 0.74rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-dim); }
.policy-actions { margin-top: 2.2em; }
.policy-meta { font-size: 0.88rem; color: var(--text-dim); }
