/* Wspolne style podstron (confirm, unsubscribe, privacy). Strona glowna ma wlasne style w index.html. */
:root {
  --bg: #fbf3f5;
  --surface: #ffffff;
  --text: #2b1534;
  --muted: #6e5a76;
  --accent: #d93a76;
  --accent-text: #ffffff;
  --accent-soft: #fde3ea;
  --line: #ecd9e0;
  --shadow: 0 8px 28px rgba(217, 58, 118, .14);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #1a0e20;
    --surface: #26142e;
    --text: #f7e9ef;
    --muted: #b9a2c2;
    --accent: #ff6b9d;
    --accent-text: #2b1534;
    --accent-soft: #3a1d44;
    --line: #3d2548;
    --shadow: 0 8px 28px rgba(0, 0, 0, .45);
  }
}
:root[data-theme="dark"] {
  --bg: #1a0e20; --surface: #26142e; --text: #f7e9ef; --muted: #b9a2c2;
  --accent: #ff6b9d; --accent-text: #2b1534; --accent-soft: #3a1d44;
  --line: #3d2548; --shadow: 0 8px 28px rgba(0, 0, 0, .45);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; -webkit-text-size-adjust: 100%; }
.wrap { max-width: 560px; margin: 0 auto; padding: 0 20px; }
header { padding: 18px 0 4px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; letter-spacing: -.01em; color: var(--text); text-decoration: none; }
.brand em { font-style: normal; color: var(--accent); }
.logo { width: 28px; height: 28px; border-radius: 9px; background: var(--accent); display: grid; place-items: center; }
.logo i { width: 10px; height: 10px; border-radius: 50%; background: var(--accent-text); }
main { padding: 24px 0 0; }
h1 { font-size: clamp(28px, 8vw, 38px); line-height: 1.1; margin: 0 0 16px; letter-spacing: -.03em; font-weight: 850; }
h2 { font-size: 19px; line-height: 1.3; margin: 28px 0 8px; letter-spacing: -.01em; font-weight: 800; }
p, li { color: var(--text); }
.muted { color: var(--muted); }
ul { padding-left: 20px; }
li { margin: 4px 0; }
a { color: var(--accent); font-weight: 650; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 20px; box-shadow: var(--shadow); }
.btn { display: block; width: 100%; margin-top: 12px; font: inherit; font-weight: 750; font-size: 17px; cursor: pointer; text-align: center; text-decoration: none; padding: 16px; border: 0; border-radius: 14px; background: var(--accent); color: var(--accent-text); }
.btn:active { transform: scale(.98); }
.btn[disabled] { opacity: .6; cursor: default; }
.msg { margin: 16px 0 0; padding: 16px; border-radius: 14px; background: var(--accent-soft); font-weight: 650; }
.msg[hidden] { display: none; }
footer { padding: 28px 0 calc(32px + env(safe-area-inset-bottom)); color: var(--muted); font-size: 13px; }
button:focus-visible, a:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Animacje: nacisniecie przycisku, ladowanie, komunikaty */
:root { --danger: #d92d20; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --danger: #ff7a6b; } }
:root[data-theme="dark"] { --danger: #ff7a6b; }

.btn { transition: transform .12s ease, filter .12s ease; }
.btn:active { transform: scale(.96); filter: brightness(.92); }

@keyframes spin { to { transform: rotate(360deg); } }
.btn.loading { position: relative; color: transparent; }
.btn.loading::after { content: ""; position: absolute; left: 50%; top: 50%; width: 20px; height: 20px; margin: -10px 0 0 -10px; border: 3px solid var(--accent-text); border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }

@keyframes pop { 0% { opacity: 0; transform: scale(.94); } 60% { transform: scale(1.03); } 100% { opacity: 1; transform: scale(1); } }
@keyframes shake { 0%, 100% { transform: translateX(0); } 20% { transform: translateX(-8px); } 40% { transform: translateX(7px); } 60% { transform: translateX(-5px); } 80% { transform: translateX(3px); } }
.msg.ok { animation: pop .35s ease-out; }
.msg.error { border-left: 4px solid var(--danger); animation: shake .4s ease; }

@keyframes view-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
main { animation: view-in .28s ease-out both; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
