/* Shared styling for legal/document pages (Privacy Policy, Cookies, Terms,
   Cookie Settings) opened as GLightbox iframe popups from the footer. */

body.legal-page {
  margin: 0;
  background-color: var(--background-color);
}

.legal-doc {
  max-width: 760px;
  margin: 0 auto;
  padding: 40px 24px 56px;
}

.legal-doc__header {
  text-align: center;
  margin-bottom: 32px;
}

.legal-doc__logo {
  height: 36px;
  margin-bottom: 16px;
}

.legal-doc__header h1 {
  font-family: var(--heading-font);
  color: var(--heading-color);
  margin-bottom: 6px;
}

.legal-doc__meta {
  color: var(--default-color);
  opacity: 0.7;
  font-size: 0.9rem;
  margin: 0;
}

.legal-doc__intro {
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 8px;
}

.legal-doc__body h2 {
  font-family: var(--heading-font);
  font-size: 1.15rem;
  color: var(--heading-color);
  margin-top: 30px;
  margin-bottom: 10px;
}

.legal-doc__body p,
.legal-doc__body li {
  line-height: 1.7;
}

.legal-doc__body ul {
  padding-left: 20px;
}

.legal-doc__table {
  width: 100%;
  border-collapse: collapse;
  margin: 12px 0 8px;
  font-size: 0.92rem;
}

.legal-doc__table th,
.legal-doc__table td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px;
  border: 1px solid #e6ebed;
}

.legal-doc__table th {
  background-color: var(--background-color);
  color: var(--heading-color);
  font-family: var(--heading-font);
}

.legal-doc__offices {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin: 10px 0;
  padding: 0;
  list-style: none;
}

.legal-doc__offices li {
  background-color: var(--background-color);
  border: 1px solid #e6ebed;
  border-radius: 8px;
  padding: 14px 16px;
}

.legal-doc__offices strong {
  display: block;
  color: var(--heading-color);
  margin-bottom: 4px;
}

.legal-doc__footer-note {
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid #e6ebed;
  font-size: 0.9rem;
  text-align: center;
}

/* Cookie preference controls */

.cookie-pref {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid #e6ebed;
}

.cookie-pref:last-of-type {
  border-bottom: none;
}

.cookie-pref__title {
  font-family: var(--heading-font);
  font-weight: 700;
  color: var(--heading-color);
  margin: 0;
}

.cookie-pref__desc {
  font-size: 0.9rem;
  opacity: 0.75;
  margin: 4px 0 0;
}

.switch {
  position: relative;
  width: 46px;
  height: 26px;
  flex: 0 0 auto;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.switch .slider {
  position: absolute;
  inset: 0;
  background-color: #ccd3d6;
  border-radius: 26px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.switch .slider::before {
  content: "";
  position: absolute;
  height: 20px;
  width: 20px;
  left: 3px;
  top: 3px;
  background-color: #fff;
  border-radius: 50%;
  transition: transform 0.2s ease;
}

.switch input:checked + .slider {
  background-color: var(--accent-color);
}

.switch input:checked + .slider::before {
  transform: translateX(20px);
}

.switch input:disabled + .slider {
  opacity: 0.6;
  cursor: not-allowed;
}

.cookie-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  flex-wrap: wrap;
  margin-top: 28px;
}

.btn-cookie {
  border: none;
  border-radius: 6px;
  padding: 10px 22px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
}

.btn-cookie--primary {
  background-color: var(--accent-color);
  color: #fff;
}

.btn-cookie--ghost {
  background-color: transparent;
  border: 1px solid #ccd3d6;
  color: var(--default-color);
}

.cookie-save-msg {
  display: none;
  text-align: center;
  margin-top: 16px;
  color: var(--accent-color);
  font-size: 0.9rem;
}

.cookie-save-msg.is-visible {
  display: block;
}
