/* ═══════════════════════════════════════════════════════════════
   NEUTRALIZAM — style.css
   Theme: Refined Darkness — slate charcoal + warm gold
═══════════════════════════════════════════════════════════════ */

:root {
  --bg:        #0B0D12;
  --surface:   #131620;
  --surface2:  #1A1E2E;
  --gold:      #C9A84C;
  --gold-dim:  #8A7035;
  --text:      #E5E3DE;
  --text-sub:  #7A7870;
  --border:    #232737;
  --radius:    4px;
  --font-disp: 'Playfair Display', Georgia, serif;
  --font-body: 'DM Sans', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-snap-type: y proximity;
  overflow-y: scroll;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 300;
  line-height: 1.7;
  overflow-x: hidden;
}

/* ─── SCROLLBAR ─── */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--gold-dim); border-radius: 2px; }

/* ─── PROGRESS BAR ─── */
#progressBar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 2px;
  z-index: 9999;
  background: transparent;
  pointer-events: none;
}
#progressFill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--gold-dim), var(--gold), #f0d080);
  transition: width 0.1s linear;
  box-shadow: 0 0 8px rgba(201,168,76,0.6);
}

/* ─── LOADING SCREEN ─── */
#loadingScreen {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.65s ease;
}
#loadingScreen.ls-done {
  opacity: 0;
  pointer-events: none;
}

.ls-spinner {
  position: relative;
  width: 120px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
}
/* Faint track ring */
.ls-spinner::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2.5px solid rgba(201,168,76,0.14);
}
/* Rotating arc */
.ls-spinner::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2.5px solid transparent;
  border-top-color: var(--gold);
  border-right-color: rgba(201,168,76,0.35);
  animation: lsSpin 0.9s linear infinite;
}
@keyframes lsSpin {
  to { transform: rotate(360deg); }
}
.ls-logo {
  width: 68px;
  height: 68px;
  object-fit: contain;
  border-radius: 50%;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}

/* ─── HERO TITLE ANIMATION ─── */
@keyframes heroWordIn {
  from {
    opacity: 0;
    transform: translateY(22px);
    filter: blur(7px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0px);
  }
}
.hero-title.htx-anim > span {
  display: inline-block;
  animation: heroWordIn 0.75s cubic-bezier(0.22, 1, 0.36, 1) 0.05s both;
}
.hero-title.htx-anim em span {
  display: inline-block;
  animation: heroWordIn 0.75s cubic-bezier(0.22, 1, 0.36, 1) 0.22s both;
}

/* ─── NAVBAR ─── */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 3rem;
  height: 64px;
  background: rgba(11, 13, 18, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s ease;
}

.nav-logo {
  font-family: var(--font-disp);
  font-size: 1.25rem;
  letter-spacing: 0.04em;
  cursor: default;
}
.logo-n { color: var(--gold); font-weight: 700; }
.logo-rest { color: var(--text); font-weight: 400; }

.nav-links {
  display: flex;
  gap: 2.5rem;
  list-style: none;
}
.nav-links a {
  color: var(--text-sub);
  text-decoration: none;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--gold); }

.nav-right { display: flex; align-items: center; gap: 1rem; }

.lang-toggle {
  background: none;
  border: 1px solid var(--border);
  color: var(--text-sub);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  transition: all 0.2s;
}
.lang-toggle:hover { border-color: var(--gold); color: var(--gold); }

.login-btn {
  background: var(--gold);
  border: none;
  color: var(--bg);
  padding: 0.4rem 1.2rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  transition: opacity 0.2s;
}
.login-btn:hover { opacity: 0.85; }

/* ─── PARALLAX SECTIONS ─── */
.parallax-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  scroll-snap-align: start;
}

.parallax-bg {
  position: absolute;
  inset: -20%;
  background-size: cover;
  background-position: center;
  will-change: transform;
}

#heroBg {
  background:
    radial-gradient(ellipse 80% 60% at 50% 40%, rgba(201,168,76,0.06) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 20% 80%, rgba(201,168,76,0.04) 0%, transparent 60%),
    var(--bg);
}
.stats-bg {
  background:
    radial-gradient(ellipse 60% 50% at 80% 30%, rgba(201,168,76,0.05) 0%, transparent 70%),
    var(--surface);
}
.survey-bg { background: var(--bg); }
.questions-bg { background: var(--surface); }
.download-bg {
  background:
    radial-gradient(ellipse 50% 60% at 30% 50%, rgba(201,168,76,0.07) 0%, transparent 70%),
    var(--bg);
}
.post-bg { background: var(--surface); }
.postq-bg { background: var(--bg); }

/* ─── SECTION INNER ─── */
.section-inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 800px;
  padding: 6rem 2rem;
  text-align: center;
}

.section-label {
  color: var(--gold);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.section-title {
  font-family: var(--font-disp);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 600;
  line-height: 1.15;
  margin-bottom: 1.5rem;
  color: var(--text);
}

.section-desc {
  color: var(--text-sub);
  font-size: 1.05rem;
  max-width: 540px;
  margin: 0 auto 3rem;
}

/* ─── SECTION DIVIDER ─── */
.section-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 3rem;
  position: relative;
  z-index: 2;
  scroll-snap-align: none;
}
.divider-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
}
.divider-diamond {
  width: 8px;
  height: 8px;
  border: 1px solid var(--gold-dim);
  transform: rotate(45deg);
  flex-shrink: 0;
}

/* ─── HERO ─── */
#hero { text-align: center; }

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  padding-top: 64px;
}

.hero-emblem {
  position: relative;
  width: 100px;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.emblem-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid;
  animation: spinRing linear infinite;
}
.ring1 { width: 100px; height: 100px; border-color: rgba(201,168,76,0.3); animation-duration: 20s; }
.ring2 { width: 75px; height: 75px; border-color: rgba(201,168,76,0.2); animation-duration: 15s; animation-direction: reverse; }
.ring3 { width: 50px; height: 50px; border-color: rgba(201,168,76,0.4); animation-duration: 10s; }

@keyframes spinRing {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

.emblem-letter {
  font-family: var(--font-disp);
  font-size: 2rem;
  font-weight: 700;
  color: var(--gold);
  position: relative;
  z-index: 1;
}

.hero-title {
  font-family: var(--font-disp);
  font-size: clamp(3rem, 8vw, 6rem);
  font-weight: 700;
  line-height: 1.05;
  color: var(--text);
}
.hero-title em {
  font-style: italic;
  color: var(--gold);
  font-weight: 400;
}

.hero-sub {
  color: var(--text-sub);
  font-size: 1.1rem;
  max-width: 480px;
  line-height: 1.7;
}

.scroll-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-sub);
  text-decoration: none;
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-top: 2rem;
  transition: color 0.2s;
}
.scroll-cta:hover { color: var(--gold); }

.cta-arrow {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--text-sub), transparent);
  animation: arrowBob 2s ease-in-out infinite;
}
@keyframes arrowBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(8px); }
}

/* ─── STATS ─── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.stat-card {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.5rem 2rem;
  text-align: center;
  transition: border-color 0.3s, transform 0.3s;
}
.stat-card:hover {
  border-color: var(--gold-dim);
  transform: translateY(-4px);
}

.stat-icon {
  color: var(--gold);
  font-size: 1.5rem;
  margin-bottom: 1rem;
  opacity: 0.7;
}

.stat-number {
  font-family: var(--font-disp);
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--gold);
  line-height: 1;
  margin-bottom: 0.75rem;
}

.stat-label {
  color: var(--text-sub);
  font-size: 0.85rem;
  letter-spacing: 0.05em;
}

/* ─── SURVEY ─── */
.survey-form {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
  align-items: center;
}

.survey-question {
  width: 100%;
  max-width: 560px;
}

.q-text {
  margin-bottom: 1rem;
  font-size: 1rem;
  color: var(--text);
  text-align: center;
}

.scale-btns {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
  justify-content: center;
}

.scale-btn {
  width: 44px;
  height: 44px;
  border: 1px solid var(--border);
  background: none;
  color: var(--text-sub);
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.9rem;
  transition: all 0.2s;
}
.scale-btn:hover { border-color: var(--gold-dim); color: var(--gold); }
.scale-btn.selected {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--bg);
  font-weight: 500;
}

.scale-labels {
  display: flex;
  justify-content: space-between;
  color: var(--text-sub);
  font-size: 0.75rem;
  letter-spacing: 0.05em;
}

.comment-box {
  width: 100%;
  max-width: 560px;
  min-height: 100px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 1rem;
  resize: vertical;
  transition: border-color 0.2s;
  text-align: left;
}
.comment-box:focus {
  outline: none;
  border-color: var(--gold-dim);
}

.submit-btn {
  align-self: center;
  background: var(--gold);
  border: none;
  color: var(--bg);
  padding: 0.85rem 2.5rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  transition: opacity 0.2s, transform 0.2s;
}
.submit-btn:hover { opacity: 0.85; transform: translateY(-1px); }
.submit-btn:active { transform: translateY(0); }

.survey-note {
  color: var(--text-sub);
  font-size: 0.8rem;
  margin-top: -1rem;
  text-align: center;
}

.survey-done {
  text-align: center;
  padding: 3rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.done-icon {
  width: 56px;
  height: 56px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  font-size: 1.5rem;
  margin: 0 auto 1.5rem;
}

/* ─── QUESTIONS ─── */
.questions-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.question-item {
  display: flex;
  align-items: flex-start;
  gap: 2rem;
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
  transition: all 0.3s;
}
.question-item:hover { padding-left: 1rem; }
.question-item:last-child { border-bottom: none; }

.q-num {
  font-family: var(--font-disp);
  font-size: 0.8rem;
  color: var(--gold-dim);
  letter-spacing: 0.1em;
  flex-shrink: 0;
  margin-top: 0.2rem;
}

.question-item p {
  color: var(--text);
  font-size: 1.05rem;
  line-height: 1.6;
}

/* ─── DOWNLOAD ─── */
.book-card {
  display: flex;
  gap: 4rem;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}

.book-cover {
  display: flex;
  flex-shrink: 0;
  filter: drop-shadow(0 20px 40px rgba(0,0,0,0.5));
}

.book-spine {
  width: 24px;
  background: linear-gradient(to right, #8A7035, #C9A84C, #8A7035);
  border-radius: 2px 0 0 2px;
}

.book-front {
  width: 160px;
  height: 220px;
  background: linear-gradient(135deg, #1A1E2E, #131620);
  border: 1px solid var(--border);
  border-left: none;
  border-radius: 0 2px 2px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
}
.book-front::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(201,168,76,0.08) 0%, transparent 60%);
}

.book-title-small {
  font-family: var(--font-disp);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  text-align: center;
  position: relative;
}
.book-author-small {
  font-size: 0.7rem;
  color: var(--text-sub);
  position: relative;
}
.book-n {
  font-family: var(--font-disp);
  font-size: 3rem;
  font-weight: 700;
  color: var(--gold);
  opacity: 0.3;
  position: absolute;
  bottom: 0.5rem;
  right: 1rem;
}

.book-info {
  flex: 1;
  min-width: 220px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.book-meta {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
  width: 100%;
}
.meta-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.meta-key {
  color: var(--text-sub);
  font-size: 0.85rem;
  letter-spacing: 0.05em;
}
.meta-val {
  color: var(--text);
  font-size: 0.9rem;
}

.download-btn {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
  padding: 0.85rem 2rem;
  border-radius: var(--radius);
  text-decoration: none;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  transition: all 0.2s;
  margin-bottom: 1rem;
}
.download-btn:hover {
  background: var(--gold);
  color: var(--bg);
}
.btn-arrow {
  font-size: 1.1rem;
  transition: transform 0.2s;
}
.download-btn:hover .btn-arrow { transform: translateY(3px); }

.download-note {
  color: var(--text-sub);
  font-size: 0.8rem;
  text-align: center;
}

/* ─── FOOTER ─── */
footer {
  border-top: 1px solid var(--border);
  padding: 3rem 2rem;
  text-align: center;
  scroll-snap-align: start;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  max-width: 700px;
  margin: 0 auto;
}
.footer-logo {
  font-family: var(--font-disp);
  font-size: 2rem;
  font-weight: 700;
  color: var(--gold);
  opacity: 0.4;
}
footer p { color: var(--text-sub); font-size: 0.85rem; }
.footer-copy { font-size: 0.75rem; opacity: 0.6; }

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 0.25rem;
}
.footer-link {
  color: var(--text-sub);
  font-size: 0.8rem;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-link:hover { color: var(--gold); }
.footer-sep {
  color: var(--border);
  font-size: 0.8rem;
  user-select: none;
}

.footer-tracking {
  font-size: 0.72rem !important;
  color: var(--text-sub);
  opacity: 0.55;
  max-width: 540px;
  line-height: 1.5;
  margin-top: 0.25rem;
}

/* GDPR policy link inside checkbox */
.gdpr-policy-link {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.75rem;
  color: var(--gold-dim);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s;
}
.gdpr-policy-link:hover { color: var(--gold); }

@media (max-width: 480px) {
  footer { padding: 2rem 1.25rem; }
  .footer-nav { gap: 0.4rem; }
}

/* ─── MODAL ─── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 2.5rem;
  width: 100%;
  max-width: 420px;
  position: relative;
  animation: modalIn 0.3s ease;
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-close {
  position: absolute;
  top: 1rem; right: 1rem;
  background: none;
  border: none;
  color: var(--text-sub);
  font-size: 1rem;
  cursor: pointer;
  transition: color 0.2s;
}
.modal-close:hover { color: var(--text); }

.modal-title {
  font-family: var(--font-disp);
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.modal-desc {
  color: var(--text-sub);
  font-size: 0.875rem;
  margin-bottom: 1.75rem;
  line-height: 1.6;
}

.modal-input {
  display: block;
  width: 100%;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 0.8rem 1rem;
  margin-bottom: 0.875rem;
  transition: border-color 0.2s;
}
.modal-input:focus { outline: none; border-color: var(--gold-dim); }

.modal-switch {
  color: var(--text-sub);
  font-size: 0.85rem;
  margin-bottom: 1.25rem;
}

.link-btn {
  background: none;
  border: none;
  color: var(--gold);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.85rem;
  text-decoration: underline;
  margin-left: 0.25rem;
}

#loginForm .submit-btn,
#registerForm .submit-btn {
  width: 100%;
  justify-content: center;
}

.modal-error {
  color: #e07070;
  font-size: 0.85rem;
  margin-top: 0.75rem;
}

.logged-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-disp);
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 auto 1rem;
}

.logged-name {
  text-align: center;
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.logout-btn {
  width: 100%;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-sub);
}
.logout-btn:hover { border-color: #e07070; color: #e07070; opacity: 1; }

/* ─── REVEAL ANIMATIONS ─── */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-item {
  opacity: 0;
  transform: translateX(-20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal-item.visible {
  opacity: 1;
  transform: translateX(0);
}

/* ─── UTILITIES ─── */
.hidden { display: none !important; }

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE — Mobile · Tablet · Desktop · TV
═══════════════════════════════════════════════════════════════ */

/* ── TV / Ultra-wide (1600px+) ── */
@media (min-width: 1600px) {
  .section-inner      { max-width: 1000px; padding: 8rem 3rem; }
  .hero-title         { font-size: clamp(5rem, 7vw, 8rem); }
  .hero-sub           { font-size: 1.25rem; max-width: 600px; }
  .stat-number        { font-size: 4.5rem; }
  .section-title      { font-size: clamp(2.5rem, 4vw, 4.5rem); }
  .stat-card          { padding: 3rem 2.5rem; }
  .book-card          { gap: 6rem; }
  .qw-title           { font-size: 2.8rem; }
  .modal-box          { max-width: 520px; }
  #navbar             { height: 72px; font-size: 1rem; }
  .nav-links a        { font-size: 0.9rem; }
  .nav-links          { gap: 3rem; }
  .ls-spinner         { width: 150px; height: 150px; }
  .ls-logo            { width: 90px; height: 90px; }
}

/* ── Large Desktop (1200px – 1599px) — baseline, already fine ── */

/* ── Tablet landscape (1025px – 1199px) ── */
@media (max-width: 1199px) and (min-width: 1025px) {
  .section-inner { max-width: 720px; }
  .book-card     { gap: 3rem; }
  .stats-grid    { gap: 1.25rem; }
}

/* ── Tablet portrait (768px – 1024px) ── */
@media (max-width: 1024px) and (min-width: 768px) {
  #navbar         { padding: 0 2rem; }
  .nav-links      { gap: 1.75rem; }
  .nav-links a    { font-size: 0.8rem; }
  .section-inner  { padding: 5rem 2rem; }
  .hero-title     { font-size: clamp(3rem, 7vw, 5rem); }
  .stats-grid     { grid-template-columns: repeat(3, 1fr); gap: 1rem; }
  .stat-number    { font-size: 3rem; }
  .book-card      { gap: 2.5rem; }
  .qw-title       { font-size: 1.75rem; }
  .social-links   { max-width: 100%; }
}

/* ── Mobile large (481px – 767px) ── */
@media (max-width: 767px) {
  #navbar              { padding: 0 1.25rem; height: 56px; }
  .nav-links           { display: none; }
  .nav-right           { gap: 0.4rem; }
  .login-btn           { padding: 0.4rem 0.9rem; font-size: 0.8rem; }
  .settings-lang-badge { display: none; }
  .settings-btn        { padding: 0 0.5rem; gap: 0; width: 36px; height: 36px; justify-content: center; border-radius: var(--radius); }
  .hero-title          { font-size: clamp(2.8rem, 9vw, 4rem); }
  .hero-sub            { font-size: 1rem; }
  .section-inner       { padding: 4rem 1.25rem; }
  .section-title       { font-size: clamp(1.8rem, 7vw, 2.8rem); }
  .stats-grid          { grid-template-columns: 1fr; gap: 1rem; }
  .stat-card           { padding: 1.75rem 1.5rem; }
  .stat-number         { font-size: 2.8rem; }
  .survey-form         { gap: 2rem; }
  .submit-btn          { width: 100%; text-align: center; justify-content: center; }
  .book-card           { flex-direction: column; gap: 2rem; align-items: center; }
  .book-cover          { align-self: center; }
  .modal-box           { padding: 2rem 1.5rem; }
  .social-links        { gap: 0.75rem; }
  .social-card         { padding: 1rem 1.25rem; gap: 1rem; }
  .stranka-content     { flex-direction: column; gap: 2rem; }
  .stranka-logo        { width: 120px; height: 120px; }
  .settings-box        { max-width: 100%; }
  .qw-input-row        { flex-direction: column; width: 100%; }
  .qw-textarea         { width: 100%; box-sizing: border-box; }
  .qw-submit-btn       { width: 100%; justify-content: center; margin-top: 0; height: auto; padding: 0.8rem 1.25rem; }
  .qw-title            { font-size: 1.5rem; }
  .hero-content        { padding-top: 56px; }
}

/* ── Mobile small (≤480px) ── */
@media (max-width: 480px) {
  .hero-title          { font-size: clamp(2.2rem, 10vw, 3.2rem); }
  .scale-btns          { gap: 0.4rem; }
  .scale-btn           { width: 38px; height: 38px; font-size: 0.8rem; }
  .book-front          { width: 140px; height: 190px; }
  .download-btn        { width: 100%; justify-content: center; }
  .modal-box           { padding: 1.5rem 1.25rem; margin: 0.5rem; }
  .settings-row        { gap: 0.4rem; }
  .setting-chip        { padding: 0.35rem 0.7rem; font-size: 0.78rem; }
  .font-row .setting-chip { font-size: 0.75rem; }
  .stat-number         { font-size: 2.4rem; }
  .section-title       { font-size: clamp(1.6rem, 8vw, 2.2rem); }
  .ls-spinner          { width: 100px; height: 100px; }
  .ls-logo             { width: 58px; height: 58px; }
  .social-card         { gap: 0.75rem; padding: 0.875rem 1rem; }
}

/* ── Touch devices — remove hover transforms ── */
@media (hover: none) {
  .stat-card:hover     { transform: none; }
  .social-card:hover   { transform: none; }
  .submit-btn:hover    { transform: none; }
  .qw-submit-btn:hover { transform: none; }
}


/* ─── SOCIAL LINKS ─── */
.social-links {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 560px;
  margin: 0 auto;
  width: 100%;
}
.social-card {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  background: rgba(255,255,255,0.02);
  transition: border-color 0.25s, background 0.25s, transform 0.25s;
}
.social-card:hover {
  border-color: var(--gold-dim);
  background: rgba(201,168,76,0.04);
  transform: translateX(6px);
}
.social-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  flex-shrink: 0;
  transition: border-color 0.25s;
}
.social-card:hover .social-icon { border-color: var(--gold-dim); }
.social-icon svg { width: 18px; height: 18px; display: block; }
.social-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}
.social-name { color: var(--text); font-size: 0.95rem; font-weight: 500; }
.social-handle { color: var(--text-sub); font-size: 0.8rem; letter-spacing: 0.03em; }
.social-arrow {
  color: var(--gold-dim);
  font-size: 1.1rem;
  flex-shrink: 0;
  transition: transform 0.25s, color 0.25s;
}
.social-card:hover .social-arrow { transform: translateX(4px); color: var(--gold); }

/* ─── ACCOUNT ACTIONS ─── */
.account-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  width: 100%;
}
.account-btn {
  width: 100%;
  background: none;
  border: 1px solid var(--border);
  color: var(--text-sub);
  padding: 0.6rem 1rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.82rem;
  transition: all 0.2s;
  text-align: center;
}
.delete-btn:hover { border-color: #e07070; color: #e07070; }

/* ─── MODE SELECTION ─── */
.mode-btns {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 0.5rem;
}
.mode-btn {
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  text-align: left;
}
.mode-btn:hover { border-color: var(--gold-dim); background: rgba(201,168,76,0.04); }
.mode-icon { color: var(--gold); font-size: 1.2rem; flex-shrink: 0; width: 24px; text-align: center; }
.mode-text { flex: 1; display: flex; flex-direction: column; gap: 0.2rem; }
.mode-label { color: var(--text); font-size: 0.95rem; font-weight: 500; font-family: var(--font-body); }
.mode-desc { color: var(--text-sub); font-size: 0.78rem; font-family: var(--font-body); }
.mode-arrow { color: var(--gold-dim); font-size: 1rem; flex-shrink: 0; }
.back-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 1.25rem;
  color: var(--text-sub);
  font-size: 0.82rem;
  padding: 0.5rem 0;
  border-top: 1px solid var(--border);
  width: 100%;
  transition: color 0.2s;
}
.back-btn:hover { color: var(--gold); }

/* ─── MOBILE ─── */
/* ─── SCROLL SNAP DIVIDERS FIX ─── */
.section-divider {
  scroll-snap-align: none;
  margin: 0;
  height: 0;
  padding: 0;
  overflow: visible;
  position: relative;
  z-index: 2;
}
.section-divider .divider-line,
.section-divider .divider-diamond {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
}
.section-divider .divider-diamond {
  left: 50%;
  transform: translate(-50%, -50%) rotate(45deg);
}

/* ─── STRANKA LOGO ─── */
.stranka-content {
  display: flex;
  align-items: flex-start;
  gap: 4rem;
}
.stranka-logo {
  width: 180px;
  height: 180px;
  object-fit: contain;
  border-radius: 8px;
  flex-shrink: 0;
  opacity: 0.9;
}

/* ─── SETTINGS BUTTON ─── */
.settings-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: none;
  border: 1px solid var(--border);
  color: var(--text-sub);
  padding: 0.25rem 0.6rem 0.25rem 0.5rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  transition: all 0.2s;
  height: 34px;
}
.settings-btn svg { flex-shrink: 0; opacity: 0.7; transition: opacity 0.2s; }
.settings-btn:hover { border-color: var(--gold); color: var(--gold); }
.settings-btn:hover svg { opacity: 1; }
.settings-lang-badge {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  font-weight: 500;
}

/* ─── SETTINGS PANEL ─── */
.settings-box {
  max-width: 380px;
}
.settings-title {
  display: flex;
  align-items: center;
  margin-bottom: 2rem;
}
.settings-group {
  margin-bottom: 1.75rem;
}
.settings-group:last-child {
  margin-bottom: 0;
}
.settings-group-label {
  color: var(--text-sub);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}
.settings-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* ─── SETTING CHIPS ─── */
.setting-chip {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-sub);
  padding: 0.4rem 0.85rem;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.82rem;
  transition: all 0.18s;
  white-space: nowrap;
}
.setting-chip:hover {
  border-color: var(--gold-dim);
  color: var(--text);
  background: rgba(201,168,76,0.05);
}
.setting-chip.active {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(201,168,76,0.08);
}
.chip-icon { font-size: 0.9rem; }

/* ─── ZOOM CONTROL ─── */
.zoom-control {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  width: fit-content;
}
.zoom-btn {
  background: rgba(255,255,255,0.03);
  border: none;
  color: var(--text-sub);
  width: 40px;
  height: 36px;
  cursor: pointer;
  font-size: 1.2rem;
  font-family: var(--font-body);
  transition: all 0.18s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.zoom-btn:hover { background: rgba(201,168,76,0.08); color: var(--gold); }
.zoom-value {
  min-width: 58px;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text);
  font-family: var(--font-body);
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  padding: 0 0.5rem;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ─── LIGHT THEME OVERRIDES ─── */
[data-theme="light"] #heroBg {
  background:
    radial-gradient(ellipse 80% 60% at 50% 40%, rgba(154,110,26,0.07) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 20% 80%, rgba(154,110,26,0.04) 0%, transparent 60%),
    var(--bg);
}
[data-theme="light"] .stats-bg {
  background:
    radial-gradient(ellipse 60% 50% at 80% 30%, rgba(154,110,26,0.06) 0%, transparent 70%),
    var(--surface);
}
[data-theme="light"] .download-bg {
  background:
    radial-gradient(ellipse 50% 60% at 30% 50%, rgba(154,110,26,0.08) 0%, transparent 70%),
    var(--bg);
}
[data-theme="light"] .survey-bg  { background: var(--bg); }
[data-theme="light"] .questions-bg { background: var(--surface); }
[data-theme="light"] .post-bg    { background: var(--surface); }
[data-theme="light"] .postq-bg   { background: var(--bg); }

[data-theme="light"] ::-webkit-scrollbar-track { background: var(--bg); }
[data-theme="light"] ::-webkit-scrollbar-thumb { background: var(--gold-dim); }

[data-theme="light"] .stat-card,
[data-theme="light"] .mode-btn,
[data-theme="light"] .social-card,
[data-theme="light"] .setting-chip {
  background: rgba(0,0,0,0.03);
}
[data-theme="light"] .modal-box {
  background: var(--surface);
  box-shadow: 0 8px 40px rgba(0,0,0,0.12);
}
[data-theme="light"] .modal-input {
  background: rgba(0,0,0,0.04);
  color: var(--text);
}
[data-theme="light"] .book-front {
  background: linear-gradient(135deg, #d4b896 0%, #c4a07a 100%);
  border-color: #b8956a;
}
[data-theme="light"] .book-spine {
  background: #b8956a;
}
[data-theme="light"] #toastMsg {
  background: var(--surface2) !important;
  color: var(--text) !important;
}


/* ─── QUESTIONS WIDGET ─── */
.questions-widget {
  margin-top: 4rem;
  width: 100%;
  text-align: center;
}

.qw-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  margin-bottom: 3rem;
}

.qw-title {
  font-family: var(--font-disp);
  font-size: clamp(1.5rem, 3.5vw, 2.2rem);
  font-weight: 600;
  color: var(--text);
  margin-bottom: 1.75rem;
  line-height: 1.2;
}

/* ── Input row ── */
.qw-input-row {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  margin-bottom: 0.6rem;
  text-align: left;
  width: 100%;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.qw-textarea {
  flex: 1;
  min-height: 72px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 0.85rem 1rem;
  resize: none;
  transition: border-color 0.2s;
  line-height: 1.5;
}
.qw-textarea:focus { outline: none; border-color: var(--gold-dim); }
.qw-textarea::placeholder { color: var(--text-sub); }

.qw-submit-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--gold);
  border: none;
  color: var(--bg);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  white-space: nowrap;
  transition: opacity 0.2s, transform 0.2s;
  height: 44px;
  align-self: flex-start;
  margin-top: 14px;
}
.qw-submit-btn:hover { opacity: 0.85; transform: translateY(-1px); }
.qw-submit-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.qw-arrow { font-size: 1rem; }

.qw-note {
  color: var(--text-sub);
  font-size: 0.78rem;
  margin-bottom: 2.5rem;
  text-align: left;
}

/* ── Top label ── */
.qw-top-label {
  color: var(--gold);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 1rem;
  text-align: center;
}

/* ── Question list ── */
.qw-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 1.75rem;
}

.qw-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s;
}
.qw-item:hover { border-color: var(--gold-dim); }

.qw-item-text {
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.55;
  flex: 1;
}

.qw-vote-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-sub);
  padding: 0.35rem 0.6rem;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.75rem;
  min-width: 40px;
  transition: all 0.18s;
  flex-shrink: 0;
}
.qw-vote-btn:hover { border-color: var(--gold-dim); color: var(--gold); }
.qw-vote-btn.voted {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(201,168,76,0.08);
  cursor: default;
}
.qw-vote-count { font-size: 0.8rem; font-weight: 500; }

/* ── Skeleton loaders ── */
.qw-skeleton {
  height: 58px;
  background: linear-gradient(90deg, var(--border) 25%, rgba(255,255,255,0.04) 50%, var(--border) 75%);
  background-size: 200% 100%;
  border-radius: var(--radius);
  animation: qwShimmer 1.4s infinite;
}
@keyframes qwShimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ── Empty state ── */
.qw-empty {
  color: var(--text-sub);
  font-size: 0.88rem;
  padding: 1.25rem 0;
  font-style: italic;
}

/* ── Search row ── */
.qw-search-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0 1rem;
  margin-bottom: 1rem;
  background: rgba(255,255,255,0.02);
  transition: border-color 0.2s;
}
.qw-search-row:focus-within { border-color: var(--gold-dim); }

.qw-search-icon { color: var(--text-sub); flex-shrink: 0; display: flex; align-items: center; }

.qw-search-input {
  flex: 1;
  background: none;
  border: none;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.9rem;
  padding: 0.85rem 0;
  outline: none;
}
.qw-search-input::placeholder { color: var(--text-sub); }

/* ── Admin reply on public page ── */
.qw-item-inner {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  min-width: 0;
}

.qw-admin-reply {
  background: rgba(201,168,76,0.06);
  border-left: 2px solid var(--gold-dim);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 0.6rem 0.85rem;
}
.qw-admin-reply-label {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.3rem;
}
.qw-admin-reply-text {
  color: var(--text);
  font-size: 0.88rem;
  line-height: 1.55;
}

[data-theme="light"] .qw-admin-reply {
  background: rgba(154,110,26,0.07);
  border-left-color: var(--gold);
}


[data-theme="light"] .qw-item,
[data-theme="light"] .qw-search-row {
  background: rgba(0,0,0,0.03);
}
[data-theme="light"] .qw-skeleton {
  background: linear-gradient(90deg, var(--border) 25%, rgba(0,0,0,0.06) 50%, var(--border) 75%);
  background-size: 200% 100%;
  animation: qwShimmer 1.4s infinite;
}



/* ═══════════════════════════════════════════════════════════════
   HAMBURGER MENU
═══════════════════════════════════════════════════════════════ */
.hamburger-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  padding: 7px 8px;
  transition: border-color 0.2s;
  flex-shrink: 0;
}
.hamburger-btn:hover { border-color: var(--gold-dim); }
.hamburger-btn span {
  display: block;
  width: 100%;
  height: 1.5px;
  background: var(--text-sub);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s, background 0.2s;
  transform-origin: center;
}
.hamburger-btn.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); background: var(--gold); }
.hamburger-btn.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger-btn.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); background: var(--gold); }

@media (max-width: 767px) {
  .hamburger-btn { display: flex; }
}

/* Mobile menu */
.mobile-menu { display: none; }
.mobile-menu.open { display: block; }

.mobile-menu-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(4px);
  z-index: 149;
  animation: fadeIn 0.2s ease;
}
.mobile-menu-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(80vw, 280px);
  background: var(--surface);
  border-left: 1px solid var(--border);
  z-index: 150;
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  animation: slideInRight 0.25s cubic-bezier(0.22,1,0.36,1);
  overflow-y: auto;
}
@keyframes slideInRight {
  from { transform: translateX(100%); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}
@keyframes fadeIn {
  from { opacity: 0; } to { opacity: 1; }
}
.mobile-menu-close {
  align-self: flex-end;
  background: none;
  border: none;
  color: var(--text-sub);
  font-size: 1.1rem;
  cursor: pointer;
  margin-bottom: 2rem;
  transition: color 0.2s;
  padding: 0.25rem;
}
.mobile-menu-close:hover { color: var(--gold); }
.mobile-menu-panel ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.mobile-menu-panel ul li {
  border-bottom: 1px solid var(--border);
}
.mobile-menu-panel ul li:last-child { border-bottom: none; }
.mobile-menu-panel ul a {
  display: block;
  padding: 1rem 0.25rem;
  color: var(--text-sub);
  text-decoration: none;
  font-size: 1rem;
  letter-spacing: 0.05em;
  transition: color 0.2s, padding-left 0.2s;
}
.mobile-menu-panel ul a:hover { color: var(--gold); padding-left: 0.5rem; }

/* ═══════════════════════════════════════════════════════════════
   NOTIFICATION BELL
═══════════════════════════════════════════════════════════════ */
.notif-btn {
  position: relative;
  background: none;
  border: 1px solid var(--border);
  color: var(--text-sub);
  width: 34px;
  height: 34px;
  border-radius: var(--radius);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s, color 0.2s;
  flex-shrink: 0;
}
.notif-btn:hover { border-color: var(--gold); color: var(--gold); }
.notif-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background: var(--gold);
  color: var(--bg);
  font-size: 0.62rem;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
  border: 2px solid var(--bg);
}

/* ═══════════════════════════════════════════════════════════════
   INBOX PANEL
═══════════════════════════════════════════════════════════════ */
.inbox-panel { display: contents; }
.inbox-panel.hidden .inbox-backdrop,
.inbox-panel.hidden .inbox-drawer { display: none; }

.inbox-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(4px);
  z-index: 180;
  animation: fadeIn 0.2s ease;
}
.inbox-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(92vw, 380px);
  background: var(--surface);
  border-left: 1px solid var(--border);
  z-index: 181;
  display: flex;
  flex-direction: column;
  animation: slideInRight 0.28s cubic-bezier(0.22,1,0.36,1);
}
.inbox-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.inbox-title {
  font-family: var(--font-disp);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
}
.inbox-close {
  background: none;
  border: none;
  color: var(--text-sub);
  font-size: 1rem;
  cursor: pointer;
  transition: color 0.2s;
  padding: 0.25rem;
}
.inbox-close:hover { color: var(--text); }
.inbox-body {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.inbox-loading {
  display: flex;
  justify-content: center;
  padding: 2rem;
}
.inbox-spinner {
  width: 28px;
  height: 28px;
  border: 2px solid var(--border);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: lsSpin 0.8s linear infinite;
}
.inbox-item {
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  transition: border-color 0.2s;
  cursor: default;
}
.inbox-item.unread {
  border-left: 3px solid var(--gold);
  background: rgba(201,168,76,0.04);
}
.inbox-item-type {
  font-size: 0.67rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.4rem;
}
.inbox-item-title {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 0.35rem;
  line-height: 1.4;
}
.inbox-item-body {
  font-size: 0.84rem;
  color: var(--text-sub);
  line-height: 1.55;
}
.inbox-item-date {
  font-size: 0.72rem;
  color: var(--text-sub);
  margin-top: 0.5rem;
  opacity: 0.7;
}
.inbox-empty {
  text-align: center;
  color: var(--text-sub);
  font-size: 0.88rem;
  padding: 3rem 1rem;
  font-style: italic;
}
.inbox-section-label {
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-sub);
  padding: 0.5rem 0.25rem 0.25rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.25rem;
}

/* ── Inbox tabs ── */
.inbox-tabs {
  display: flex;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.inbox-tab {
  flex: 1;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-sub);
  font-family: var(--font-body);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.75rem 0.5rem;
  cursor: pointer;
  transition: color 0.18s, border-color 0.18s;
  margin-bottom: -1px;
}
.inbox-tab:hover { color: var(--text); }
.inbox-tab.active { color: var(--gold); border-bottom-color: var(--gold); }

/* ── Login prompt inside messages tab ── */
.inbox-login-prompt {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2.5rem 1.5rem;
  gap: 0.5rem;
}
.inbox-login-btn {
  background: var(--gold);
  border: none;
  color: var(--bg);
  padding: 0.65rem 2rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  transition: opacity 0.2s;
}
.inbox-login-btn:hover { opacity: 0.85; }

/* ═══════════════════════════════════════════════════════════════
   GDPR PRIVOLA — checkbox u registracijskoj formi
═══════════════════════════════════════════════════════════════ */
.gdpr-check-label {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  cursor: pointer;
  margin-bottom: 1rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(201,168,76,0.03);
  transition: border-color 0.2s, background 0.2s;
  user-select: none;
}
.gdpr-check-label:hover {
  border-color: var(--gold-dim);
  background: rgba(201,168,76,0.06);
}
/* Hide native checkbox */
.gdpr-check-label input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}
/* Custom box */
.gdpr-check-box {
  width: 18px;
  height: 18px;
  min-width: 18px;
  border: 1.5px solid var(--border);
  border-radius: 3px;
  background: rgba(255,255,255,0.03);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
  transition: border-color 0.18s, background 0.18s;
  position: relative;
}
/* Checkmark tick via pseudo */
.gdpr-check-box::after {
  content: '';
  display: block;
  width: 5px;
  height: 9px;
  border: 2px solid transparent;
  border-top: none;
  border-left: none;
  transform: rotate(45deg) translateY(-1px);
  transition: border-color 0.15s;
}
/* Checked state */
.gdpr-check-label input:checked ~ .gdpr-check-box {
  background: var(--gold);
  border-color: var(--gold);
}
.gdpr-check-label input:checked ~ .gdpr-check-box::after {
  border-color: var(--bg);
}
/* Focus ring on keyboard nav */
.gdpr-check-label input:focus-visible ~ .gdpr-check-box {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}
.gdpr-check-text {
  font-size: 0.78rem;
  color: var(--text-sub);
  line-height: 1.55;
}
/* Submit button disabled state */
#doRegister:disabled {
  opacity: 0.38;
  cursor: not-allowed;
  transform: none !important;
}

/* ═══════════════════════════════════════════════════════════════
   WEB SHARE BUTTON
═══════════════════════════════════════════════════════════════ */
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: none;
  border: 1px solid var(--border);
  color: var(--text-sub);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 400;
  transition: border-color 0.2s, color 0.2s;
  margin-top: 0.75rem;
}
.share-btn:hover { border-color: var(--gold-dim); color: var(--gold); }

/* ═══════════════════════════════════════════════════════════════
   ACCESSIBILITY — Focus indicators
═══════════════════════════════════════════════════════════════ */
:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 2px;
}
/* Remove outline for mouse users */
:focus:not(:focus-visible) { outline: none; }

/* Skip-to-content link (screen readers) */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--gold);
  color: var(--bg);
  padding: 0.5rem 1rem;
  border-radius: 0 0 var(--radius) var(--radius);
  font-size: 0.85rem;
  font-weight: 600;
  z-index: 99999;
  transition: top 0.2s;
}
.skip-link:focus { top: 0; }

/* ═══════════════════════════════════════════════════════════════
   PREFERS-REDUCED-MOTION
═══════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal, .reveal-item {
    opacity: 1 !important;
    transform: none !important;
  }
  .hero-title.htx-anim > span,
  .hero-title.htx-anim em span {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }
}

/* ═══════════════════════════════════════════════════════════════
   PRINT STYLESHEET
═══════════════════════════════════════════════════════════════ */
@media print {
  /* Hide interactive/nav elements */
  #progressBar, #loadingScreen, #navbar, #gdprBanner,
  #settingsOverlay, #loginOverlay, #inboxPanel,
  .mobile-menu, .scroll-cta, .cta-arrow,
  .submit-btn, .share-btn, .download-btn,
  .scale-btns, .comment-box, footer,
  .section-divider, .qw-input-row, .qw-search-row,
  .qw-note, .qw-vote-btn { display: none !important; }

  body {
    background: #fff !important;
    color: #111 !important;
    font-size: 12pt;
    line-height: 1.6;
  }
  .parallax-section {
    min-height: auto !important;
    padding: 2rem 0 !important;
    page-break-inside: avoid;
  }
  .parallax-bg { display: none !important; }
  .section-inner { padding: 1rem 0 !important; max-width: 100% !important; }
  .hero-content { padding-top: 0 !important; }
  .hero-title { color: #111 !important; font-size: 28pt !important; }
  .section-title { color: #111 !important; font-size: 18pt !important; }
  .section-label { color: #555 !important; }
  .section-desc, p { color: #333 !important; }
  .stat-card { border: 1px solid #ccc !important; break-inside: avoid; }
  .stat-number { color: #555 !important; }
  .survey-question { break-inside: avoid; }
  .qw-item { border: 1px solid #ccc !important; break-inside: avoid; }
  .qw-admin-reply { border: 1px solid #aaa !important; background: #f5f5f5 !important; }
  .social-card { border: 1px solid #ccc !important; }
  a { color: #555 !important; text-decoration: underline; }
  .reveal, .reveal-item { opacity: 1 !important; transform: none !important; }
}

/* ═══════════════════════════════════════════════════════════════
   BACK TO TOP
═══════════════════════════════════════════════════════════════ */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 500;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gold);
  border: none;
  color: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(201,168,76,0.35);
  transition: opacity 0.3s, transform 0.3s, box-shadow 0.2s;
  opacity: 1;
}
.back-to-top[hidden] {
  display: flex !important; /* override hidden attr with opacity trick */
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
}
.back-to-top:not([hidden]) {
  opacity: 1;
  transform: translateY(0);
}
.back-to-top:hover {
  box-shadow: 0 6px 28px rgba(201,168,76,0.5);
  transform: translateY(-2px);
}
@media (max-width: 767px) {
  .back-to-top { bottom: 1.25rem; right: 1.25rem; width: 40px; height: 40px; }
}

/* ═══════════════════════════════════════════════════════════════
   QUESTION CHAR COUNTER
═══════════════════════════════════════════════════════════════ */
.qw-counter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
  gap: 1rem;
  text-align: left;
  width: 100%;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}
.qw-char-counter {
  font-size: 0.72rem;
  color: var(--text-sub);
  font-family: var(--font-body);
  white-space: nowrap;
  transition: color 0.2s;
  flex-shrink: 0;
}
.qw-char-counter.qw-counter-over {
  color: #e07070;
  font-weight: 500;
}
/* qw-note is now inside counter-row so remove its standalone margin */
.qw-counter-row .qw-note {
  margin-bottom: 0;
  text-align: right;
}

/* ═══════════════════════════════════════════════════════════════
   LOGGED-IN META (birth year + reg date)
═══════════════════════════════════════════════════════════════ */
.logged-meta {
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-sub);
  margin-top: -0.75rem;
  margin-bottom: 1.25rem;
  letter-spacing: 0.03em;
}

/* ═══════════════════════════════════════════════════════════════
   CHECKBOX POP ANIMATION
═══════════════════════════════════════════════════════════════ */
@keyframes checkPop {
  0%   { transform: scale(1); }
  40%  { transform: scale(1.25); }
  70%  { transform: scale(0.9); }
  100% { transform: scale(1); }
}
.gdpr-check-box.gdpr-check-pop {
  animation: checkPop 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Smooth checkbox tick draw */
.gdpr-check-label input:checked ~ .gdpr-check-box::after {
  border-color: var(--bg);
  animation: tickDraw 0.18s ease-out;
}
@keyframes tickDraw {
  from { border-right-width: 0; border-bottom-width: 0; }
  to   { border-right-width: 2px; border-bottom-width: 2px; }
}

/* ═══════════════════════════════════════════════════════════════
   VOTED BUTTON CURSOR
═══════════════════════════════════════════════════════════════ */
.qw-vote-btn.voted {
  cursor: help;
}

/* ═══════════════════════════════════════════════════════════════
   SEARCH SKELETON — in search list
═══════════════════════════════════════════════════════════════ */
#qwSearchList .qw-skeleton {
  height: 58px;
  background: linear-gradient(90deg, var(--border) 25%, rgba(255,255,255,0.04) 50%, var(--border) 75%);
  background-size: 200% 100%;
  border-radius: var(--radius);
  animation: qwShimmer 1.4s infinite;
  margin-bottom: 0.6rem;
}

/* ═══════════════════════════════════════════════════════════════
   DEVICE OPTIMIZATIONS — Dopune za sve uređaje
═══════════════════════════════════════════════════════════════ */

/* ── Number input — ukloni spinner strelice ── */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
input[type="number"] { -moz-appearance: textfield; }

/* ── Bolje dodirne mete (min 44px) na mobilnim ── */
@media (max-width: 767px) {
  .scale-btn        { min-width: 44px; min-height: 44px; }
  .nav-links a      { min-height: 44px; display: flex; align-items: center; }
  .gdpr-check-label { padding: 1rem; }
  .back-to-top      { width: 48px; height: 48px; }
  .notif-btn, .settings-btn { width: 38px; height: 38px; }
  .modal-input      { font-size: 16px; } /* sprječava auto-zoom na iOS */
  .qw-search-input  { font-size: 16px; }
  .qw-textarea      { font-size: 16px; }
  .inp              { font-size: 16px; }
}

/* ── Landscape mobitel ── */
@media (max-width: 767px) and (orientation: landscape) {
  .parallax-section { min-height: auto; padding: 3rem 0; }
  .hero-content     { padding-top: 70px; gap: 1rem; }
  .hero-emblem      { width: 70px; height: 70px; }
  .hero-title       { font-size: clamp(2rem, 8vw, 3rem); }
  .section-inner    { padding: 2.5rem 1.25rem; }
  .ls-spinner       { width: 80px; height: 80px; }
  .ls-logo          { width: 48px; height: 48px; }
}

/* ── iPad Pro / Large tablet (1024px square) ── */
@media (min-width: 1024px) and (max-width: 1024px) {
  .section-inner { max-width: 760px; }
}

/* ── Visoki ekrani (TV s više od 900px visine) ── */
@media (min-height: 900px) and (min-width: 1200px) {
  .parallax-section { min-height: 85vh; }
  .section-inner    { padding: 7rem 2rem; }
}

/* ── Performansne optimizacije ── */
.parallax-bg       { will-change: transform; contain: layout style; }
.stat-card         { contain: layout style; }
.inbox-drawer      { will-change: transform; }
.mobile-menu-panel { will-change: transform; }
.modal-box         { will-change: transform, opacity; }

/* ── Bolji text rendering ── */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* ── Sprječaj horizontalni scroll na svim uređajima ── */
html, body { max-width: 100%; overflow-x: hidden; }

/* ── Modal: fullscreen na malim ekranima ── */
@media (max-width: 480px) {
  .modal-overlay  { padding: 0; align-items: flex-end; }
  .modal-box      {
    border-radius: 16px 16px 0 0;
    margin: 0;
    max-height: 92vh;
    overflow-y: auto;
    width: 100%;
    max-width: 100%;
    padding: 1.75rem 1.25rem 2rem;
  }
  .settings-box   { border-radius: 16px 16px 0 0; }
}

/* ── Inbox drawer — fullscreen na mobitelu ── */
@media (max-width: 480px) {
  .inbox-drawer {
    width: 100%;
    border-left: none;
    border-top: 1px solid var(--border);
    border-radius: 16px 16px 0 0;
  }
}

/* ── Scroll snap — isključi na landscape mobitelu ── */
@media (max-width: 767px) and (orientation: landscape) {
  html { scroll-snap-type: none; }
}

/* ── Visoki kontrast (accessibility) ── */
@media (forced-colors: active) {
  .submit-btn, .gdpr-accept, .back-to-top { forced-color-adjust: none; }
  :focus-visible { outline: 3px solid Highlight; }
}

/* ── Štedi bateriju na uređajima koji traže ── */
@media (prefers-reduced-motion: reduce) {
  .parallax-bg { transform: none !important; }
  .ls-spinner::after { animation: none !important; }
}
/* ─── SURVEY GDPR ART.9 NOTICE ─── */
.survey-gdpr-notice {
  width: 100%;
  max-width: 560px;
  background: rgba(201,168,76,0.04);
  border: 1px solid rgba(201,168,76,0.18);
  border-radius: var(--radius);
  padding: 0.85rem 1.1rem;
  margin-bottom: 1rem;
}
.survey-gdpr-notice p {
  color: var(--text-sub);
  font-size: 0.76rem;
  line-height: 1.55;
  margin: 0;
  text-align: center;
}
/* ═══════════════════════════════════════════════════════════════
   TV I VELIKI EKRANI (≥1920px)
═══════════════════════════════════════════════════════════════ */
@media (min-width: 1920px) {
  .section-inner      { max-width: 1200px; padding: 9rem 4rem; }
  .hero-title         { font-size: clamp(6rem, 6vw, 10rem); }
  .hero-sub           { font-size: 1.4rem; max-width: 700px; }
  .stat-number        { font-size: 5.5rem; }
  .section-title      { font-size: clamp(3rem, 4vw, 5.5rem); }
  .stat-card          { padding: 3.5rem 3rem; }
  .book-card          { gap: 8rem; }
  .modal-box          { max-width: 600px; padding: 3rem 3.5rem; }
  #navbar             { height: 80px; }
  .nav-links          { gap: 4rem; }
  .nav-links a        { font-size: 1rem; }
  .logo-rest, .nav-logo { font-size: 1.4rem; }
  .social-card        { padding: 1.75rem 2rem; }
  .qw-item            { padding: 1.5rem 2rem; }
  .footer-inner       { max-width: 1200px; }
}

/* ═══════════════════════════════════════════════════════════════
   4K / UHD (≥2560px)
═══════════════════════════════════════════════════════════════ */
@media (min-width: 2560px) {
  html                { font-size: 20px; }
  .section-inner      { max-width: 1600px; }
  .hero-title         { font-size: clamp(7rem, 6vw, 12rem); }
  #navbar             { height: 96px; }
  .modal-box          { max-width: 720px; }
}

/* ═══════════════════════════════════════════════════════════════
   TABLET LANDSCAPE POBOLJŠANJA (1025px – 1199px)
═══════════════════════════════════════════════════════════════ */
@media (max-width: 1199px) and (min-width: 1025px) {
  .modal-box          { max-width: 500px; }
  .stats-grid         { gap: 1.5rem; }
  .qw-input-row       { gap: 0.75rem; }
}

/* ═══════════════════════════════════════════════════════════════
   TABLET PORTRAIT POBOLJŠANJA (768px – 1024px)
═══════════════════════════════════════════════════════════════ */
@media (max-width: 1024px) and (min-width: 768px) {
  .modal-overlay      { padding: 1.5rem; }
  .modal-box          { max-width: 480px; }
  .survey-question    { padding: 1.25rem 1rem; }
  .scale-btns         { gap: 0.6rem; }
  .scale-btn          { width: 44px; height: 44px; }
  .book-cover         { flex-shrink: 0; }
  .book-front         { width: 160px; height: 220px; }
  .settings-row       { flex-wrap: wrap; }
  .qw-textarea        { min-height: 70px; }
  .inbox-drawer       { width: 420px; }
}

/* ═══════════════════════════════════════════════════════════════
   MALI TABLET / VELIKI MOBITEL (600px – 767px)
═══════════════════════════════════════════════════════════════ */
@media (max-width: 767px) and (min-width: 600px) {
  .stats-grid         { grid-template-columns: repeat(3, 1fr); }
  .modal-box          { max-width: 500px; padding: 2rem; }
  .book-card          { flex-direction: row; gap: 2rem; }
}

/* ═══════════════════════════════════════════════════════════════
   MALI MOBITEL — iPhone SE, Galaxy A (≤390px)
═══════════════════════════════════════════════════════════════ */
@media (max-width: 390px) {
  .hero-title         { font-size: clamp(2rem, 11vw, 2.8rem); }
  .section-title      { font-size: clamp(1.5rem, 9vw, 2rem); }
  .scale-btn          { width: 36px; height: 36px; font-size: 0.78rem; }
  .setting-chip       { padding: 0.3rem 0.55rem; font-size: 0.74rem; }
  .book-front         { width: 120px; height: 165px; }
  .modal-box          { padding: 1.25rem 1rem; }
  .nav-right          { gap: 0.3rem; }
  .login-btn          { padding: 0.3rem 0.6rem; font-size: 0.74rem; }
  .settings-btn        { width: 32px; height: 32px; }
  .notif-btn           { width: 32px; height: 32px; }
  .admin-totp-digit   { width: 36px; height: 44px; font-size: 1.2rem; }
  .social-card        { padding: 0.75rem; }
  .social-icon        { width: 36px; height: 36px; }
  .footer-nav         { flex-wrap: wrap; justify-content: center; gap: 0.3rem; }
}

/* ═══════════════════════════════════════════════════════════════
   VISOKI EKRANI / TV — sprječaj previše whitespace
═══════════════════════════════════════════════════════════════ */
@media (min-height: 1080px) and (min-width: 1920px) {
  .parallax-section   { min-height: 80vh; }
  .hero-content       { gap: 2.5rem; }
}
@media (min-height: 2000px) {
  /* Ultra-tall displays (folded phones, portrait TV) */
  .parallax-section   { min-height: 60vh; }
}

/* ═══════════════════════════════════════════════════════════════
   FOLD / ULTRA-NARROW (<320px) — stari/jeftini mobiteli
═══════════════════════════════════════════════════════════════ */
@media (max-width: 320px) {
  html                { font-size: 13px; }
  .hero-title         { font-size: 2rem; letter-spacing: 0; }
  .nav-logo           { font-size: 1rem; }
  .scale-btns         { gap: 0.25rem; }
  .scale-btn          { width: 32px; height: 32px; font-size: 0.74rem; }
  .modal-box          { padding: 1rem 0.75rem; }
  .admin-totp-digit   { width: 30px; height: 38px; font-size: 1rem; }
  .admin-totp-sep     { display: none; }
  .setting-chip       { padding: 0.28rem 0.45rem; font-size: 0.7rem; }
}