/* Matches GemaPastelStyle.kt, LoginWelcomeSurface.kt and CancellationSettingsSurface.kt.
   Keep long-form text and links darker than app secondary labels for readability. */
@font-face { font-family: Poppins; src: url("assets/fonts/Poppins-Regular.ttf") format("truetype"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: Poppins; src: url("assets/fonts/Poppins-SemiBold.ttf") format("truetype"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: Rubik; src: url("assets/fonts/Rubik-Bold.ttf") format("truetype"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: Rubik; src: url("assets/fonts/Rubik-ExtraBold.ttf") format("truetype"); font-weight: 800; font-style: normal; font-display: swap; }
:root {
  color-scheme: light;
  --canvas: #fffcfd;
  --surface: #ffffff;
  --soft: #f3f4f9;
  --ink: #211833;
  --muted: #676174;
  --accent: #a73583;
  --accent-hover: #882569;
  --line: #eae7ee;
  --focus: #8144d2;
  --primary: linear-gradient(90deg, #f65fb0, #a15df9);
  --page-gradient: linear-gradient(180deg, #fffcfd 0%, #fde7f3 32%, #eaeff8 55%, #dff5fa 72%, #fff8d7 100%);
  font-family: Poppins, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
* { box-sizing: border-box; }
html { min-height: 100%; scroll-padding-top: 24px; }
body { margin: 0; background: var(--canvas); color: var(--ink); line-height: 1.75; }
body::before { content: ""; position: fixed; inset: 0; z-index: -1; background: var(--page-gradient); pointer-events: none; }
.page, .wrap {
  width: min(100%, 848px);
  margin-inline: auto;
  padding: 32px max(24px, env(safe-area-inset-right)) max(40px, env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left));
}
.site-header { margin-bottom: 28px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: Rubik, sans-serif; font-size: 20px; font-weight: 800; letter-spacing: .04em; line-height: 1.2; }
.brand-symbol { display: inline-block; flex: 0 0 48px; width: 48px; height: 48px; border-radius: 14px; background: url("assets/gema-brand-icon.png") center / contain no-repeat; }
.legal-nav { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 22px; }
.legal-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 9px 15px;
  border-radius: 12px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  text-decoration: none;
}
.legal-nav a[aria-current="page"] { background: var(--primary); color: var(--ink); font-weight: 600; }
.document, .card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 40px;
  box-shadow: 0 4px 24px #53263f04;
}
.document-heading { padding-bottom: 22px; border-bottom: 1px solid var(--line); margin-bottom: 24px; }
h1 { margin: 0; font-size: clamp(28px, 4.2vw, 38px); font-family: Rubik, sans-serif; font-weight: 800; line-height: 1.2; letter-spacing: -.035em; text-wrap: balance; }
.updated { margin: 12px 0 0; color: var(--muted); font-size: 13px; }
h3 { margin: 24px 0 10px; font: 600 1rem/1.5 Poppins, sans-serif; }
.document-links { display: flex; flex-wrap: wrap; align-items: center; column-gap: 8px; margin-top: 8px; color: var(--muted); font-size: 13px; line-height: 1.6; }
.document-links a { display: inline-flex; align-items: center; min-height: 44px; }
h2 { margin: 34px 0 12px; font-family: Rubik, sans-serif; font-size: 20px; font-weight: 700; line-height: 1.4; letter-spacing: -.015em; }
p { margin: 0 0 16px; }
p, li, a, strong { overflow-wrap: anywhere; }
strong { font-weight: 600; }
ul { padding-left: 22px; margin: 12px 0 22px; }
li { padding-left: 3px; margin: 10px 0; }
li::marker { color: var(--accent); }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
.draft-notice {
  margin: 0 0 28px;
  padding: 16px 18px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-left: 3px solid #a15df9;
  border-radius: 4px 12px 12px 4px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}
.draft-notice > strong { color: var(--ink); font-size: 13px; }
.draft-notice p { margin: 6px 0 0; }
footer { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; line-height: 1.8; }
footer a, .links a { display: inline-flex; align-items: center; min-height: 44px; padding-block: 10px; }
/* Account deletion uses the same shell, with a narrower form column. */
.deletion-page .wrap { max-width: 688px; }
.card h1 { font-size: clamp(27px, 4.2vw, 34px); margin-bottom: 16px; }
.lead { color: var(--muted); font-size: 15px; line-height: 1.75; margin-bottom: 24px; }
.field { margin-bottom: 22px; }
label { display: block; margin-bottom: 8px; font-size: 14px; font-weight: 600; }
input, textarea {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  background: var(--soft);
  color: var(--ink);
  font: inherit;
  font-size: 16px;
  line-height: 1.5;
  appearance: none;
}
input::placeholder, textarea::placeholder { color: #786873; opacity: 1; }
input:focus, textarea:focus { outline: 2px solid var(--focus); outline-offset: 2px; border-color: var(--accent); }
textarea { min-height: 116px; resize: vertical; }
.hint { margin: 8px 0 0; font-size: 13px; color: var(--muted); line-height: 1.6; }
.btn {
  display: block;
  width: 100%;
  min-height: 52px;
  padding: 14px 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.5;
  cursor: pointer;
  touch-action: manipulation;
}
.btn-primary { background: var(--primary); color: var(--ink); }
.btn-ghost { margin-top: 12px; background: var(--soft); color: var(--ink); border-color: var(--line); }
.note { margin-top: 28px; padding: 18px; background: var(--soft); border-radius: 12px; color: var(--muted); font-size: 13px; line-height: 1.75; }
.note strong { color: var(--ink); }
.error { display: none; margin-bottom: 18px; padding: 12px 14px; border: 1px solid #efc4cb; border-radius: 12px; background: #fff1f3; color: #a12b3c; font-size: 14px; }
.error.show { display: block; }
.success { display: none; text-align: center; }
.success.show { display: block; }
.form.hide, [hidden] { display: none !important; }
.check { display: grid; place-items: center; width: 56px; height: 56px; margin: 0 auto 24px; border-radius: 18px; background: #edf8f1; color: #17623f; font-size: 28px; }
.links { margin: 24px 0 0; text-align: center; font-size: 13px; color: var(--muted); }
.deletion-page footer { text-align: center; }
@media (hover: hover) {
  a:hover { text-decoration: none; }
  .legal-nav a:not([aria-current]):hover { background: var(--soft); color: var(--accent); }
  .btn-primary:hover { background: linear-gradient(90deg, #f87cbd, #b27afa); }
  .btn-ghost:hover { background: var(--soft); }
}
@media (max-width: 600px) {
  body { line-height: 1.65; }
  .page, .wrap { padding: 24px max(16px, env(safe-area-inset-right)) max(32px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left)); }
  .site-header { margin-bottom: 20px; }
  .brand { font-size: 18px; }
  .legal-nav { gap: 6px; margin-top: 20px; }
  .legal-nav a { flex: 0 0 auto; min-height: 40px; padding: 8px 12px; background: #ffffff80; font-size: 13px; }
  .document, .card { padding: 26px 20px; border-radius: 24px; }
  .document-heading { padding-bottom: 20px; margin-bottom: 20px; }
  h2 { margin-top: 24px; font-size: 19px; }
  p { margin-bottom: 12px; }
  li { margin-block: 6px; }
  .lead, .note { line-height: 1.65; }
  .draft-notice { padding: 14px; margin-bottom: 24px; }
  .note { padding: 14px; }
  footer { margin-top: 24px; }
}
@media (max-width: 359px) {
  .document, .card { padding-inline: 16px; }
  h1 { font-size: 26px; }
}
@media print {
  body { background: #fff; color: #000; }
  body::before { display: none; }
  .page, .wrap { max-width: none; padding: 0; }
  .legal-nav, .links, .brand-symbol { display: none; }
  .document, .card { padding: 0; border: 0; box-shadow: none; }
  h2 { break-after: avoid; }
  a { color: inherit; }
}
