/* ─── Site footer ───────────────────────────────────────── */
.site-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 16px;
  font-size: 13px;
  color: var(--text-secondary, #64748b);
  background: rgba(255, 255, 255, 0.92);
  border-top: 1px solid var(--border-color, #e2e8f0);
}

.site-footer--fixed {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
}

.site-footer a {
  color: var(--primary, #3b82f6);
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

.site-footer__sep {
  color: var(--text-muted, #94a3b8);
}

/* ─── Cookie banner ─────────────────────────────────────── */
.cookie-banner {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  max-width: 720px;
  margin: 0 auto;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  background: #1e293b;
  color: #f8fafc;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
  z-index: 1000;
  font-size: 14px;
  line-height: 1.5;
}

.cookie-banner__text {
  flex: 1;
  min-width: 200px;
}

.cookie-banner__actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.cookie-banner__btn {
  padding: 8px 16px;
  border-radius: 8px;
  border: none;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.cookie-banner__btn--accept {
  background: #3b82f6;
  color: #fff;
}

.cookie-banner__btn--decline {
  background: transparent;
  color: #cbd5e1;
  border: 1px solid #475569;
}

.cookie-banner__btn:hover {
  opacity: 0.92;
}

body.has-site-footer {
  padding-bottom: 48px;
}

body.has-cookie-banner {
  padding-bottom: 120px;
}

body.has-site-footer.has-cookie-banner {
  padding-bottom: 168px;
}

body.has-site-footer .cookie-banner {
  bottom: 56px;
}

/* ─── Legal consent checkbox ────────────────────────────── */
.legal-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 16px 0 0;
  cursor: pointer;
  text-align: left;
}

.legal-consent input[type='checkbox'] {
  margin-top: 3px;
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.legal-consent__text {
  font-size: 13px;
  color: #64748b;
  line-height: 1.5;
}

.legal-consent__text a {
  color: #3b82f6;
  text-decoration: none;
}

.legal-consent__text a:hover {
  text-decoration: underline;
}

.legal-consent-error {
  margin-top: 8px;
  font-size: 13px;
  color: #dc2626;
}

/* ─── Legal document pages ──────────────────────────────── */
.legal-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg-primary, #f8fafc);
}

.legal-page__main {
  flex: 1;
  padding: var(--spacing-2xl, 32px) var(--spacing-lg, 16px);
  display: flex;
  justify-content: center;
}

.legal-container {
  max-width: 800px;
  width: 100%;
}

.legal-title {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.legal-meta {
  font-size: 14px;
  color: var(--text-secondary, #64748b);
  margin-bottom: var(--spacing-lg, 24px);
}

.legal-body {
  font-size: 15px;
  color: var(--text-primary, #1e293b);
  line-height: 1.75;
  padding: var(--spacing-xl, 24px);
  background: var(--bg-secondary, #fff);
  border: 1px solid var(--border-color, #e2e8f0);
  border-radius: var(--border-radius, 12px);
}

.legal-body h2 {
  font-size: 17px;
  font-weight: 700;
  margin: 24px 0 12px;
  color: #1e293b;
}

.legal-body h2:first-child {
  margin-top: 0;
}

.legal-body p {
  margin: 0 0 12px;
}

.legal-body p:last-child {
  margin-bottom: 0;
}

.legal-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 14px;
}

.legal-body th,
.legal-body td {
  border: 1px solid var(--border-color, #e2e8f0);
  padding: 10px 12px;
  vertical-align: top;
  text-align: left;
}

.legal-body th {
  background: #f1f5f9;
  font-weight: 600;
}

.legal-back {
  display: inline-block;
  margin-top: var(--spacing-lg, 24px);
  color: var(--primary, #3b82f6);
  text-decoration: none;
  font-weight: 500;
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  cursor: pointer;
}

.legal-back:hover {
  text-decoration: underline;
}
