/* Weissenburg Dev — premium reading system for privacy policies and terms */
:root {
  --doc-bg: #090a0d;
  --doc-surface: #0f1116;
  --doc-surface-2: #13161c;
  --doc-surface-3: #171a21;
  --doc-text: #f3f0e9;
  --doc-copy: #b0b2b8;
  --doc-muted: #777a83;
  --doc-line: rgba(255,255,255,.095);
  --doc-line-strong: rgba(255,255,255,.16);
  --doc-gold: #d6ba78;
  --doc-gold-soft: #f0d99d;
  --doc-accent: 214,186,120;
  --doc-width: 1240px;
  --doc-copy-width: 790px;
  --doc-radius: 24px;
  --doc-shadow: 0 30px 90px rgba(0,0,0,.34);
}

.document-body.doc-lune { --doc-accent: 173,194,218; }
.document-body.doc-qibla { --doc-accent: 138,185,168; }
.document-body.doc-facturemate { --doc-accent: 214,186,120; }
.document-body.doc-terms { --doc-accent: 196,156,103; }

.document-body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 78% -12%, rgba(var(--doc-accent),.075), transparent 29rem),
    linear-gradient(180deg, #0b0c10 0%, var(--doc-bg) 32rem, var(--doc-bg) 100%);
  color: var(--doc-text);
}

.document-body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .18;
  background-image:
    linear-gradient(rgba(255,255,255,.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.018) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(180deg, #000 0, transparent 45rem);
}

.document-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(9,10,13,.80);
  backdrop-filter: blur(24px) saturate(135%);
  -webkit-backdrop-filter: blur(24px) saturate(135%);
  border-bottom: 1px solid rgba(255,255,255,.07);
}

.document-header-shell {
  width: min(var(--doc-width), calc(100% - 48px));
  min-height: 78px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 26px;
}

.document-header .brand {
  min-width: max-content;
}

.document-header .brand-copy strong {
  color: #eeece5;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .04em;
}

.document-header .brand-copy small {
  color: #666971;
  font-size: 9px;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.document-route-nav {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 5px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 999px;
  background: rgba(255,255,255,.025);
}

.document-route-nav a {
  position: relative;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 0 13px;
  border-radius: 999px;
  color: #858890;
  font-size: 10px;
  font-weight: 670;
  letter-spacing: .055em;
  transition: color .2s ease, background .2s ease;
}

.document-route-nav a:hover {
  color: #e9e6df;
  background: rgba(255,255,255,.045);
}

.document-route-nav a[aria-current="page"] {
  color: #f5f1e7;
  background: rgba(var(--doc-accent),.12);
  box-shadow: inset 0 0 0 1px rgba(var(--doc-accent),.18);
}

.document-back {
  justify-self: end;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px 0 11px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 999px;
  color: #a4a6ad;
  font-size: 11px;
  font-weight: 600;
  transition: transform .2s ease, color .2s ease, border-color .2s ease, background .2s ease;
}

.document-back:hover {
  transform: translateY(-1px);
  color: #f2eee6;
  border-color: rgba(var(--doc-accent),.32);
  background: rgba(var(--doc-accent),.055);
}

.document-back-arrow {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,.045);
  color: rgb(var(--doc-accent));
  font-size: 15px;
  line-height: 1;
}

.document-mobile-menu {
  display: none;
  position: relative;
  justify-self: end;
}

.document-mobile-menu summary {
  list-style: none;
  min-height: 40px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 13px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 999px;
  color: #b7b9bf;
  font-size: 11px;
  font-weight: 650;
  cursor: pointer;
}
.document-mobile-menu summary::-webkit-details-marker { display: none; }
.document-mobile-menu[open] summary { color: #fff; border-color: rgba(var(--doc-accent),.26); }
.document-mobile-menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  width: min(290px, calc(100vw - 32px));
  padding: 9px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 18px;
  background: rgba(16,18,24,.98);
  box-shadow: 0 25px 80px rgba(0,0,0,.55);
}
.document-mobile-menu-panel a {
  min-height: 43px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px;
  border-radius: 11px;
  color: #aaaeb5;
  font-size: 12px;
}
.document-mobile-menu-panel a:hover,
.document-mobile-menu-panel a[aria-current="page"] {
  color: #f2eee6;
  background: rgba(var(--doc-accent),.085);
}

.document-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  overflow: hidden;
}
.document-progress span {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, rgba(var(--doc-accent),.42), rgb(var(--doc-accent)));
  box-shadow: 0 0 14px rgba(var(--doc-accent),.4);
}

.document-main {
  position: relative;
  z-index: 1;
  padding: 0 0 110px;
}

.document-hero {
  width: min(var(--doc-width), calc(100% - 48px));
  margin: 0 auto;
  padding: 108px 0 78px;
  position: relative;
  border-bottom: 1px solid rgba(255,255,255,.065);
}

.document-hero::before {
  content: "";
  position: absolute;
  width: 510px;
  height: 270px;
  right: -120px;
  top: 45px;
  pointer-events: none;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--doc-accent),.11), transparent 67%);
  filter: blur(5px);
}

.document-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 31px;
  padding: 0 12px;
  margin-bottom: 28px;
  border: 1px solid rgba(var(--doc-accent),.22);
  border-radius: 999px;
  background: rgba(var(--doc-accent),.055);
  color: rgb(var(--doc-accent));
  font-size: 9px;
  font-weight: 760;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.document-badge::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 5px rgba(var(--doc-accent),.07);
}

.document-hero h1 {
  position: relative;
  max-width: 950px;
  margin: 0;
  font-size: clamp(52px, 6.4vw, 88px);
  line-height: .99;
  font-weight: 510;
  letter-spacing: -.057em;
  text-wrap: balance;
}

.document-hero > p {
  position: relative;
  max-width: 720px;
  margin: 28px 0 0;
  color: #a4a7ae;
  font-size: 16px;
  line-height: 1.75;
  letter-spacing: -.01em;
}

.document-meta {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 34px;
}

.document-meta span {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 999px;
  color: #787b83;
  background: rgba(255,255,255,.018);
  font-size: 10px;
  letter-spacing: .02em;
}

.document-layout {
  width: min(var(--doc-width), calc(100% - 48px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 250px minmax(0, var(--doc-copy-width));
  justify-content: center;
  gap: 68px;
  padding-top: 66px;
}

.document-sidebar {
  position: relative;
  min-width: 0;
}
.document-sidebar-inner {
  position: sticky;
  top: 112px;
}
.document-sidebar-label {
  display: block;
  margin: 0 0 15px 12px;
  color: #5f626a;
  font-size: 9px;
  font-weight: 740;
  letter-spacing: .17em;
  text-transform: uppercase;
}
.document-toc {
  max-height: calc(100vh - 310px);
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.10) transparent;
  padding-right: 7px;
}
.document-toc a {
  position: relative;
  display: block;
  padding: 8px 12px 8px 17px;
  border-left: 1px solid rgba(255,255,255,.075);
  color: #696c74;
  font-size: 11px;
  line-height: 1.5;
  transition: color .2s ease, border-color .2s ease, background .2s ease;
}
.document-toc a:hover {
  color: #c5c7cc;
  border-left-color: rgba(var(--doc-accent),.35);
}
.document-toc a.active {
  color: #ede9e1;
  border-left-color: rgb(var(--doc-accent));
  background: linear-gradient(90deg, rgba(var(--doc-accent),.07), transparent);
}

.document-sidebar-card {
  margin-top: 28px;
  padding: 17px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 17px;
  background: rgba(255,255,255,.018);
}
.document-sidebar-card strong {
  display: block;
  margin-bottom: 10px;
  color: #aaa9a5;
  font-size: 10px;
  font-weight: 690;
  letter-spacing: .06em;
}
.document-sidebar-card a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 32px;
  color: #6e7179;
  font-size: 10px;
  transition: color .2s ease;
}
.document-sidebar-card a:hover { color: var(--doc-gold-soft); }
.document-sidebar-card a[aria-current="page"] { color: rgb(var(--doc-accent)); }

.document-mobile-toc {
  display: none;
}

.document-content {
  min-width: 0;
  width: 100%;
}

.document-callout {
  position: relative;
  margin: 0 0 18px;
  padding: 21px 24px 21px 53px;
  border: 1px solid rgba(var(--doc-accent),.16);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(var(--doc-accent),.075), rgba(var(--doc-accent),.018) 58%, transparent),
    var(--doc-surface);
  color: #c1c3c7;
  font-size: 13px;
  line-height: 1.7;
}
.document-callout::before {
  content: "i";
  position: absolute;
  left: 20px;
  top: 21px;
  width: 21px;
  height: 21px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(var(--doc-accent),.24);
  border-radius: 50%;
  color: rgb(var(--doc-accent));
  font-family: Georgia, "Times New Roman", serif;
  font-size: 12px;
  font-style: italic;
}

.document-section {
  position: relative;
  margin-top: 18px;
  padding: 34px 38px 36px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: var(--doc-radius);
  background:
    linear-gradient(180deg, rgba(255,255,255,.018), transparent 80px),
    rgba(15,17,22,.82);
  box-shadow: 0 18px 50px rgba(0,0,0,.14);
  scroll-margin-top: 110px;
}
.document-section::before {
  content: "";
  position: absolute;
  left: 34px;
  right: 34px;
  top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(var(--doc-accent),.26), transparent);
  opacity: .8;
}
.document-section:first-of-type { margin-top: 0; }
.document-section:target {
  border-color: rgba(var(--doc-accent),.26);
  box-shadow: 0 20px 65px rgba(0,0,0,.24), 0 0 0 1px rgba(var(--doc-accent),.04);
}

.document-section h2 {
  margin: 0 0 23px;
  color: #f0ede6;
  font-size: clamp(23px, 2.2vw, 30px);
  line-height: 1.2;
  font-weight: 560;
  letter-spacing: -.025em;
  text-wrap: balance;
}

.document-section h3 {
  margin: 31px 0 15px;
  padding-top: 3px;
  color: #dedbd4;
  font-size: 17px;
  line-height: 1.35;
  font-weight: 600;
  letter-spacing: -.012em;
}
.document-section h3::before {
  content: "";
  display: inline-block;
  width: 18px;
  height: 1px;
  margin: 0 10px 5px 0;
  background: rgba(var(--doc-accent),.55);
}

.document-section h4 {
  margin: 24px 0 11px;
  color: rgb(var(--doc-accent));
  font-size: 11px;
  line-height: 1.45;
  font-weight: 760;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.document-section p,
.document-section li {
  color: var(--doc-copy);
  font-size: 15px;
  line-height: 1.82;
  letter-spacing: -.004em;
}
.document-section p { margin: 0 0 17px; }
.document-section p:last-child { margin-bottom: 0; }
.document-section strong { color: #e8e5de; font-weight: 620; }
.document-section em { color: #d1d0cc; }

.document-section ul,
.document-section ol {
  margin: 17px 0 21px;
  padding: 0;
  list-style: none;
}
.document-section li {
  position: relative;
  padding-left: 24px;
  margin: 8px 0;
}
.document-section ul > li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .83em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(var(--doc-accent),.85);
  box-shadow: 0 0 0 5px rgba(var(--doc-accent),.055);
}
.document-section ol { counter-reset: doc-list; }
.document-section ol > li { counter-increment: doc-list; padding-left: 34px; }
.document-section ol > li::before {
  content: counter(doc-list);
  position: absolute;
  left: 0;
  top: .28em;
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(var(--doc-accent),.22);
  border-radius: 7px;
  color: rgb(var(--doc-accent));
  font-size: 9px;
  font-weight: 760;
}

.document-section a {
  color: #e3ce98;
  text-decoration: underline;
  text-decoration-color: rgba(227,206,152,.28);
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
  transition: color .2s ease, text-decoration-color .2s ease;
  overflow-wrap: anywhere;
}
.document-section a:hover {
  color: #f2dda8;
  text-decoration-color: currentColor;
}

.document-section blockquote {
  margin: 22px 0;
  padding: 18px 20px;
  border-left: 2px solid rgba(var(--doc-accent),.55);
  background: rgba(var(--doc-accent),.04);
  color: #bfc1c6;
}

.document-section:last-of-type {
  background:
    radial-gradient(circle at 100% 0, rgba(var(--doc-accent),.08), transparent 230px),
    linear-gradient(180deg, rgba(255,255,255,.018), transparent 80px),
    rgba(15,17,22,.82);
}

.document-end-nav {
  margin-top: 22px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 12px;
}
.document-end-nav a {
  position: relative;
  min-height: 104px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 18px 19px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 19px;
  background: rgba(255,255,255,.018);
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.document-end-nav a::after {
  content: "↗";
  position: absolute;
  right: 16px;
  top: 14px;
  color: rgba(var(--doc-accent),.55);
}
.document-end-nav a:hover {
  transform: translateY(-2px);
  border-color: rgba(var(--doc-accent),.22);
  background: rgba(var(--doc-accent),.035);
}
.document-end-nav small {
  margin-bottom: 6px;
  color: #656870;
  font-size: 8px;
  font-weight: 720;
  letter-spacing: .15em;
  text-transform: uppercase;
}
.document-end-nav strong {
  color: #dad8d2;
  font-size: 13px;
  font-weight: 590;
}

.document-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid rgba(255,255,255,.07);
  background: rgba(8,9,12,.68);
}
.document-footer-shell {
  width: min(var(--doc-width), calc(100% - 48px));
  min-height: 126px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 32px;
}
.document-footer-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}
.document-footer-brand .brand-mark { width: 48px; height: 28px; }
.document-footer-brand strong {
  display: block;
  color: #d9d7d1;
  font-size: 11px;
  letter-spacing: .08em;
}
.document-footer-brand span {
  display: block;
  margin-top: 5px;
  color: #555860;
  font-size: 9px;
}
.document-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 20px;
}
.document-footer-links a {
  color: #73767e;
  font-size: 10px;
  transition: color .2s ease;
}
.document-footer-links a:hover { color: var(--doc-gold-soft); }

.document-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 70;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 50%;
  background: rgba(15,17,22,.88);
  backdrop-filter: blur(14px);
  color: #a9abb1;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease, color .2s ease, border-color .2s ease;
}
.document-to-top.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.document-to-top:hover {
  color: rgb(var(--doc-accent));
  border-color: rgba(var(--doc-accent),.28);
}

@media (max-width: 1120px) {
  .document-header-shell { grid-template-columns: auto 1fr auto; }
  .document-route-nav { display: none; }
  .document-mobile-menu { display: block; }
  .document-layout { grid-template-columns: 210px minmax(0, 760px); gap: 42px; }
}

@media (max-width: 900px) {
  .document-header-shell { width: calc(100% - 32px); min-height: 72px; gap: 12px; }
  .document-header .brand-copy small { display: none; }
  .document-header .brand-mark { width: 44px; height: 25px; }
  .document-back { display: none; }
  .document-mobile-menu { grid-column: 3; }
  .document-hero { width: calc(100% - 36px); padding: 82px 0 58px; }
  .document-hero h1 { font-size: clamp(48px, 10vw, 70px); }
  .document-layout { width: calc(100% - 36px); display: block; padding-top: 34px; }
  .document-sidebar { display: none; }
  .document-mobile-toc {
    display: block;
    margin: 0 0 18px;
    border: 1px solid rgba(255,255,255,.075);
    border-radius: 17px;
    background: rgba(255,255,255,.018);
    overflow: hidden;
  }
  .document-mobile-toc summary {
    min-height: 52px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 17px;
    color: #b4b6bc;
    font-size: 11px;
    font-weight: 650;
    cursor: pointer;
    list-style: none;
  }
  .document-mobile-toc summary::-webkit-details-marker { display: none; }
  .document-mobile-toc summary::after { content: "+"; color: rgb(var(--doc-accent)); font-size: 15px; }
  .document-mobile-toc[open] summary::after { content: "−"; }
  .document-mobile-toc nav { padding: 0 9px 10px; }
  .document-mobile-toc nav a {
    display: block;
    padding: 10px 11px;
    border-radius: 10px;
    color: #777a83;
    font-size: 11px;
    line-height: 1.4;
  }
  .document-mobile-toc nav a:hover,
  .document-mobile-toc nav a.active { color: #eeeae2; background: rgba(var(--doc-accent),.07); }
  .document-footer-shell { width: calc(100% - 36px); }
}

@media (max-width: 620px) {
  .document-header .brand-copy strong { font-size: 11px; }
  .document-mobile-menu summary { padding: 0 11px; }
  .document-hero { padding-top: 64px; padding-bottom: 46px; }
  .document-badge { margin-bottom: 21px; }
  .document-hero h1 { font-size: clamp(43px, 13vw, 59px); }
  .document-hero > p { margin-top: 22px; font-size: 14px; line-height: 1.72; }
  .document-meta { margin-top: 26px; gap: 7px; }
  .document-meta span { min-height: 31px; font-size: 9px; }
  .document-layout { width: calc(100% - 28px); }
  .document-section { padding: 27px 22px 29px; border-radius: 19px; }
  .document-section::before { left: 22px; right: 22px; }
  .document-section h2 { margin-bottom: 19px; font-size: 24px; }
  .document-section h3 { font-size: 16px; }
  .document-section p,
  .document-section li { font-size: 14px; line-height: 1.78; }
  .document-callout { padding: 19px 19px 19px 49px; }
  .document-callout::before { left: 17px; top: 19px; }
  .document-end-nav { grid-template-columns: 1fr; }
  .document-footer-shell { min-height: 160px; grid-template-columns: 1fr; gap: 22px; padding: 30px 0; }
  .document-footer-links { justify-content: flex-start; gap: 16px; }
  .document-to-top { right: 14px; bottom: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  .document-to-top,
  .document-back,
  .document-end-nav a { transition: none !important; }
}
