/* ============================================
   SewingDuo – Modern Public Stylesheet 2025
   ============================================ */
:root {
  --primary: #111111;
  --accent: #b85a45;
  --accent-light: #d4785f;
  --accent-soft: #faf1ee;
  --accent-muted: #e8d5cf;
  --bg: #faf8f6;
  --bg-alt: #f3efeb;
  --card: #ffffff;
  --text: #1c1917;
  --muted: #78716c;
  --border: #e7e5e4;
  --success: #15803d;
  --danger: #b91c1c;
  --radius: 20px;
  --radius-sm: 12px;
  --shadow: 0 1px 3px rgba(0,0,0,.04), 0 4px 16px rgba(0,0,0,.04);
  --shadow-lg: 0 8px 40px rgba(0,0,0,.08);
  --shadow-xl: 0 20px 60px rgba(0,0,0,.12);
  --font: 'Manrope', system-ui, -apple-system, sans-serif;
  --display: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --display: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --nav-h: 76px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, h4 { font-family: var(--display); font-weight: 600; line-height: 1.15; letter-spacing: -0.02em; }
a { text-decoration: none; color: inherit; transition: color .25s var(--ease); }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

input, textarea, select {
  font-family: inherit; font-size: .95rem; padding: .85rem 1.15rem;
  border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  background: #fff; color: var(--text); width: 100%;
  transition: border-color .25s, box-shadow .25s;
}
input:focus, textarea:focus, select:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(184, 90, 69, .12);
}
label { display: block; font-size: .8rem; font-weight: 600; margin-bottom: .4rem; color: var(--text); letter-spacing: .01em; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .8rem 1.65rem; border-radius: 100px; font-weight: 600; font-size: .9rem;
  transition: all .3s var(--ease); border: none; cursor: pointer; white-space: nowrap;
  letter-spacing: .01em;
}
.btn-primary {
  background: var(--accent); color: #fff;
  box-shadow: 0 4px 20px rgba(184, 90, 69, .3);
}
.btn-primary:hover {
  background: var(--accent-light); transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(184, 90, 69, .4);
}
.btn-outline {
  background: transparent; border: 1.5px solid var(--border); color: var(--text);
}
.btn-outline:hover {
  border-color: var(--accent); color: var(--accent); background: var(--accent-soft);
  transform: translateY(-1px);
}
.btn-dark { background: var(--primary); color: #fff; }
.btn-dark:hover { background: #2a2a2a; transform: translateY(-1px); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-sm { padding: .45rem .95rem; font-size: .8rem; border-radius: 8px; }
.btn-lg { padding: 1.05rem 2.2rem; font-size: 1rem; }
.btn-block { width: 100%; }
.btn-ghost { color: var(--muted); }
.btn-ghost:hover { color: var(--text); background: rgba(0,0,0,.04); }

/* Layout */
.container { max-width: 1160px; margin: 0 auto; padding: 0 1.75rem; }
.section { padding: 6rem 0; }
.section-header { text-align: center; max-width: 560px; margin: 0 auto 3.5rem; }
.section-label {
  display: inline-flex; align-items: center; gap: .4rem;
  color: var(--accent); font-weight: 600; font-size: .75rem;
  letter-spacing: .1em; text-transform: uppercase; margin-bottom: .85rem;
}
.section-header h2 {
  font-size: clamp(2rem, 4vw, 2.75rem); color: var(--primary); margin-bottom: .75rem;
}
.section-header p { color: var(--muted); font-size: 1.05rem; line-height: 1.7; }

/* ===== NAV ===== */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 900;
  height: var(--nav-h); display: flex; align-items: center;
  transition: background .35s var(--ease), box-shadow .35s, backdrop-filter .35s;
}
.nav.scrolled {
  background: rgba(255,255,255,.85);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 0 1px 0 rgba(0,0,0,.06);
}
.nav-inner {
  width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 1.75rem;
  display: flex; align-items: center; justify-content: space-between;
}
.logo {
  font-family: var(--display); font-size: 1.55rem; font-weight: 700;
  letter-spacing: -.03em; display: flex; align-items: center; gap: .5rem;
}
.logo span { color: var(--accent); }
.nav-links { display: flex; gap: 2.25rem; }
.nav-links a {
  font-weight: 500; font-size: .9rem; color: var(--text);
  position: relative; padding: .25rem 0;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: 0; left: 0;
  width: 0; height: 2px; background: var(--accent);
  transition: width .3s var(--ease); border-radius: 1px;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a:hover::after { width: 100%; }
.nav-actions { display: flex; gap: .65rem; align-items: center; }

.user-chip {
  display: none; align-items: center; gap: .55rem;
  padding: .3rem .85rem .3rem .3rem; background: #fff;
  border: 1.5px solid var(--border); border-radius: 100px;
  cursor: pointer; transition: all .25s var(--ease);
}
.user-chip.visible { display: flex; }
.user-chip:hover { border-color: var(--accent); box-shadow: var(--shadow); }
.user-chip-avatar {
  width: 34px; height: 34px; border-radius: 50%; background: var(--accent);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 600; font-size: .85rem; overflow: hidden; flex-shrink: 0;
}
.user-chip-avatar img { width: 100%; height: 100%; object-fit: cover; }
.user-chip-name {
  font-size: .85rem; font-weight: 600; max-width: 110px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

/* ===== HERO ===== */
.hero {
  min-height: 100vh; position: relative; display: flex; align-items: center;
  overflow: hidden; padding-top: var(--nav-h);
}
.slider { position: absolute; inset: 0; z-index: 0; }
.slide {
  position: absolute; inset: 0; opacity: 0;
  transition: opacity 1.2s ease; background-size: cover; background-position: center;
}
.slide.active { opacity: 1; }
.slide-overlay {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 70% 40%, rgba(184,90,69,.08) 0%, transparent 60%),
    linear-gradient(135deg, rgba(250,248,246,.97) 0%, rgba(250,248,246,.88) 40%, rgba(250,241,238,.92) 100%);
}
.hero-content {
  position: relative; z-index: 2; width: 100%; max-width: 1160px;
  margin: 0 auto; padding: 4rem 1.75rem 5rem;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: .45rem;
  background: var(--accent-soft); color: var(--accent);
  padding: .45rem 1.15rem; border-radius: 100px;
  font-size: .8rem; font-weight: 600; margin-bottom: 1.6rem;
  border: 1px solid var(--accent-muted);
}
.hero h1 {
  font-size: clamp(2.75rem, 6vw, 4.25rem); color: var(--primary);
  margin-bottom: 1.35rem; max-width: 680px; letter-spacing: -.03em;
  line-height: 1.08;
}
.hero h1 span { color: var(--accent); }
.hero-desc {
  font-size: 1.15rem; color: var(--muted); max-width: 460px;
  margin-bottom: 2.4rem; line-height: 1.75;
}
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 3.5rem; }
.hero-stats {
  display: flex; gap: 3rem; padding-top: 2.25rem;
  border-top: 1px solid rgba(0,0,0,.07); max-width: 520px;
}
.hero-stat strong {
  display: block; font-family: var(--display); font-size: 1.85rem;
  color: var(--primary); letter-spacing: -.02em;
}
.hero-stat span { font-size: .82rem; color: var(--muted); font-weight: 500; }
.slider-dots {
  position: absolute; bottom: 2.25rem; left: 50%; transform: translateX(-50%);
  display: flex; gap: .5rem; z-index: 5;
}
.slider-dot {
  width: 8px; height: 8px; border-radius: 50%; background: rgba(0,0,0,.15);
  cursor: pointer; transition: all .35s var(--ease);
}
.slider-dot.active { background: var(--accent); width: 28px; border-radius: 4px; }

/* ===== SERVICES ===== */
.services-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem;
}
.service-card {
  background: var(--card); border-radius: var(--radius); padding: 2rem 1.75rem;
  box-shadow: var(--shadow); transition: all .4s var(--ease);
  border: 1px solid transparent; position: relative; overflow: hidden;
}
.service-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-light));
  transform: scaleX(0); transform-origin: left; transition: transform .4s var(--ease);
}
.service-card:hover {
  transform: translateY(-8px); box-shadow: var(--shadow-xl);
  border-color: var(--accent-muted);
}
.service-card:hover::before { transform: scaleX(1); }
.service-icon {
  width: 56px; height: 56px; background: var(--accent-soft); border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.4rem; font-size: 1.5rem;
  transition: transform .35s var(--ease);
}
.service-card:hover .service-icon { transform: scale(1.08); }
.service-card h3 {
  font-family: var(--font); font-size: 1.15rem; font-weight: 650; margin-bottom: .55rem;
}
.service-card p { color: var(--muted); font-size: .92rem; line-height: 1.65; }

/* ===== GALLERY ===== */
.gallery-filters {
  display: flex; gap: .5rem; justify-content: center; flex-wrap: wrap; margin-bottom: 2.5rem;
}
.filter-btn {
  padding: .5rem 1.25rem; border-radius: 100px; font-size: .85rem; font-weight: 550;
  border: 1.5px solid var(--border); background: #fff; color: var(--muted);
  cursor: pointer; transition: all .3s var(--ease);
}
.filter-btn:hover, .filter-btn.active {
  background: var(--accent); color: #fff; border-color: var(--accent);
  box-shadow: 0 4px 16px rgba(184,90,69,.25);
}
.gallery-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 1.25rem;
}
.gallery-item {
  aspect-ratio: 1; border-radius: var(--radius); overflow: hidden;
  position: relative; cursor: pointer; transition: all .4s var(--ease);
  background: linear-gradient(145deg, #f0ebe6, #e4d8d0);
}
.gallery-item img {
  width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease);
}
.gallery-item:hover { transform: scale(1.02); box-shadow: var(--shadow-xl); }
.gallery-item:hover img { transform: scale(1.08); }
.gallery-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.7) 0%, transparent 50%);
  opacity: 0; display: flex; flex-direction: column; justify-content: flex-end;
  padding: 1.4rem; transition: opacity .35s var(--ease); color: #fff;
}
.gallery-item:hover .gallery-overlay { opacity: 1; }
.gallery-overlay strong { font-size: 1rem; font-weight: 600; }
.gallery-overlay span {
  font-size: .78rem; opacity: .9; margin-top: .3rem;
  background: rgba(255,255,255,.2); backdrop-filter: blur(8px);
  padding: .2rem .65rem; border-radius: 6px; display: inline-block; width: fit-content;
}

/* ===== POSTS ===== */
.posts-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem;
}
.post-card {
  background: #fff; border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); transition: all .4s var(--ease);
  border: 1px solid var(--border);
}
.post-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-xl); }
.post-img {
  height: 180px;
  background: linear-gradient(135deg, var(--accent-soft), var(--accent-muted));
  position: relative; overflow: hidden;
}
.post-img::after {
  content: '📰'; position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 2.5rem; opacity: .3;
}
.post-body { padding: 1.5rem 1.6rem 1.7rem; }
.post-date {
  font-size: .75rem; color: var(--accent); margin-bottom: .5rem;
  font-weight: 600; letter-spacing: .03em; text-transform: uppercase;
}
.post-card h3 {
  font-family: var(--font); font-size: 1.1rem; font-weight: 650; margin-bottom: .5rem;
}
.post-card p {
  color: var(--muted); font-size: .9rem;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* ===== CONTACT ===== */
.contact { background: #fff; }
.contact-grid {
  display: grid; grid-template-columns: 1fr 1.2fr; gap: 4rem; align-items: start;
}
.contact-item { display: flex; gap: 1rem; margin-bottom: 1.75rem; }
.contact-icon {
  width: 52px; height: 52px; background: var(--accent-soft); border-radius: 14px;
  display: flex; align-items: center; justify-content: center; font-size: 1.25rem; flex-shrink: 0;
}
.contact-form {
  background: var(--bg); padding: 2.5rem; border-radius: 24px;
  border: 1px solid var(--border);
}
.form-group { margin-bottom: 1.15rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

/* ===== FOOTER ===== */
.footer {
  background: var(--primary); color: #fff; padding: 4.5rem 0 1.75rem;
}
.footer-grid {
  display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 2.5rem; margin-bottom: 3rem;
}
.footer h4 {
  font-family: var(--font); font-size: .9rem; margin-bottom: 1.1rem;
  font-weight: 650; letter-spacing: .02em;
}
.footer ul li { margin-bottom: .6rem; }
.footer ul a { color: rgba(255,255,255,.55); font-size: .9rem; }
.footer ul a:hover { color: #fff; }
.footer-bottom {
  padding-top: 1.75rem; border-top: 1px solid rgba(255,255,255,.1);
  display: flex; justify-content: space-between; font-size: .82rem;
  color: rgba(255,255,255,.35);
}

/* ===== MODAL ===== */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.55);
  backdrop-filter: blur(8px); z-index: 2000; display: none;
  align-items: center; justify-content: center; padding: 1rem;
}
.modal-overlay.active { display: flex; }
.modal {
  background: #fff; border-radius: 24px; width: 100%; max-width: 420px;
  padding: 2.5rem; box-shadow: var(--shadow-xl); position: relative;
  animation: modalIn .35s var(--ease); max-height: 90vh; overflow-y: auto;
}
@keyframes modalIn {
  from { opacity: 0; transform: translateY(20px) scale(.96); }
  to { opacity: 1; transform: none; }
}
.modal-close {
  position: absolute; top: 1rem; right: 1rem; width: 36px; height: 36px;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  color: var(--muted); font-size: 1.15rem; transition: all .2s;
}
.modal-close:hover { background: var(--bg); color: var(--text); }
.modal h2 { font-size: 1.55rem; margin-bottom: .4rem; }
.modal-sub { color: var(--muted); margin-bottom: 1.5rem; font-size: .92rem; }
.auth-tabs {
  display: flex; gap: .4rem; margin-bottom: 1.4rem;
  background: var(--bg); padding: .3rem; border-radius: 12px;
}
.auth-tab {
  flex: 1; padding: .55rem; text-align: center; border-radius: 10px;
  font-weight: 600; font-size: .88rem; color: var(--muted); transition: all .25s;
}
.auth-tab.active { background: #fff; color: var(--primary); box-shadow: var(--shadow); }
.demo-hint {
  background: var(--accent-soft); border-radius: 12px; padding: .85rem 1rem;
  font-size: .78rem; color: var(--accent); margin-bottom: 1.2rem; line-height: 1.55;
  border: 1px solid var(--accent-muted);
}

/* Toast */
.toast {
  position: fixed; bottom: 1.75rem; right: 1.75rem; background: var(--primary);
  color: #fff; padding: .9rem 1.4rem; border-radius: 14px;
  box-shadow: 0 12px 36px rgba(0,0,0,.2); z-index: 3000;
  transform: translateY(100px); opacity: 0; transition: all .35s var(--ease);
  font-size: .9rem; font-weight: 500;
}
.toast.show { transform: translateY(0); opacity: 1; }
.toast.success { background: var(--success); }
.toast.error { background: var(--danger); }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; background: rgba(0,0,0,.92);
  z-index: 5000; display: none; align-items: center; justify-content: center; padding: 2rem;
}
.lightbox.active { display: flex; }
.lightbox img, .lightbox video {
  max-width: 92vw; max-height: 88vh; border-radius: 12px; object-fit: contain;
}
.lightbox-close {
  position: absolute; top: 1.25rem; right: 1.5rem; color: #fff;
  font-size: 2rem; cursor: pointer; opacity: .7; transition: opacity .2s;
}
.lightbox-close:hover { opacity: 1; }

/* Public / Dashboard switch */
#public-site { display: block; }
#public-site.hidden { display: none !important; }
#dashboard { display: none; }
#dashboard.active { display: flex !important; }

/* Responsive */
@media (max-width: 960px) {
  .nav-links { display: none; }
  .hero-content { text-align: center; }
  .hero-desc, .hero-stats { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .contact-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .form-row { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .footer-grid { grid-template-columns: 1fr; }
  .user-chip-name { display: none; }
  .hero-stats { flex-direction: column; gap: 1.25rem; align-items: center; }
  .section { padding: 4rem 0; }
  .hero h1 { font-size: 2.4rem; }
}

/* Creator credit */
.footer-bottom {
  align-items: center;
  flex-wrap: wrap;
  gap: .75rem;
}
.footer-bottom .creator {
  color: rgba(255,255,255,.4);
  font-size: .82rem;
}
.footer-bottom .creator a {
  color: rgba(255,255,255,.7);
  font-weight: 600;
  transition: color .25s ease;
}
.footer-bottom .creator a:hover {
  color: var(--accent-light, #d4785f);
}

/* ===== Theme toggle button ===== */
.theme-toggle {
  width: 40px; height: 40px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.05); border: 1.5px solid var(--border);
  cursor: pointer; transition: all .25s ease; font-size: 1.1rem;
  position: relative;
}
.theme-toggle:hover { background: var(--accent-soft); border-color: var(--accent); }
.theme-icon-dark { display: none; }
.theme-icon-light { display: inline; }
[data-theme="dark"] .theme-icon-light { display: none; }
[data-theme="dark"] .theme-icon-dark { display: inline; }

/* ===== DARK MODE ===== */
[data-theme="dark"] {
  --primary: #f5f5f4;
  --accent: #e07a5f;
  --accent-light: #f0957d;
  --accent-soft: #2a2220;
  --accent-muted: #3d322f;
  --bg: #121212;
  --bg-alt: #1a1a1a;
  --card: #1e1e1e;
  --text: #f5f5f4;
  --muted: #a8a29e;
  --border: #2e2e2e;
  --success: #4ade80;
  --danger: #f87171;
  --shadow: 0 1px 3px rgba(0,0,0,.3), 0 4px 16px rgba(0,0,0,.25);
  --shadow-lg: 0 8px 40px rgba(0,0,0,.4);
  --shadow-xl: 0 20px 60px rgba(0,0,0,.5);
}

[data-theme="dark"] body { background: var(--bg); color: var(--text); }

[data-theme="dark"] .nav.scrolled {
  background: rgba(18,18,18,.9);
  box-shadow: 0 1px 0 rgba(255,255,255,.06);
}

[data-theme="dark"] .logo { color: var(--text); }

[data-theme="dark"] .slide-overlay {
  background:
    radial-gradient(ellipse 80% 60% at 70% 40%, rgba(224,122,95,.12) 0%, transparent 60%),
    linear-gradient(135deg, rgba(18,18,18,.95) 0%, rgba(18,18,18,.88) 40%, rgba(30,24,22,.92) 100%);
}

[data-theme="dark"] .hero h1 { color: var(--text); }
[data-theme="dark"] .hero-stat strong { color: var(--text); }

[data-theme="dark"] .service-card,
[data-theme="dark"] .post-card,
[data-theme="dark"] .contact-form,
[data-theme="dark"] .modal {
  background: var(--card);
  border-color: var(--border);
}

[data-theme="dark"] .filter-btn {
  background: var(--card); border-color: var(--border); color: var(--muted);
}
[data-theme="dark"] .filter-btn.active,
[data-theme="dark"] .filter-btn:hover {
  background: var(--accent); color: #fff; border-color: var(--accent);
}

[data-theme="dark"] .contact { background: var(--bg-alt); }

[data-theme="dark"] .footer { background: #0a0a0a; }

[data-theme="dark"] input,
[data-theme="dark"] textarea,
[data-theme="dark"] select {
  background: #252525; border-color: var(--border); color: var(--text);
}

[data-theme="dark"] .btn-outline {
  border-color: var(--border); color: var(--text);
}
[data-theme="dark"] .btn-outline:hover {
  border-color: var(--accent); color: var(--accent); background: var(--accent-soft);
}

[data-theme="dark"] .user-chip {
  background: var(--card); border-color: var(--border);
}

[data-theme="dark"] .auth-tabs { background: #252525; }
[data-theme="dark"] .auth-tab.active { background: var(--card); color: var(--text); }

[data-theme="dark"] .theme-toggle {
  background: rgba(255,255,255,.08); border-color: var(--border);
}

[data-theme="dark"] .gallery-item {
  background: linear-gradient(145deg, #2a2522, #1e1a18);
}

[data-theme="dark"] .post-img {
  background: linear-gradient(135deg, var(--accent-soft), var(--accent-muted));
}

[data-theme="dark"] .section-header h2 { color: var(--text); }

/* ===== Background ambient effects ===== */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 60% 40% at 10% 20%, rgba(184,90,69,.07) 0%, transparent 55%),
    radial-gradient(ellipse 50% 35% at 90% 80%, rgba(184,90,69,.05) 0%, transparent 50%),
    radial-gradient(ellipse 40% 30% at 50% 50%, rgba(120,100,90,.03) 0%, transparent 60%);
}
[data-theme="dark"] body::before {
  background:
    radial-gradient(ellipse 60% 40% at 15% 15%, rgba(224,122,95,.1) 0%, transparent 55%),
    radial-gradient(ellipse 50% 35% at 85% 75%, rgba(100,80,70,.08) 0%, transparent 50%),
    radial-gradient(ellipse 40% 30% at 50% 50%, rgba(40,30,25,.15) 0%, transparent 60%);
}

/* ===== User dropdown ===== */
.user-menu-wrap { position: relative; display: none; }
.user-menu-wrap.visible { display: block; }
.user-menu-wrap .user-chip {
  display: flex !important; align-items: center; gap: .5rem;
  padding: .28rem .8rem .28rem .28rem; background: var(--card);
  border: 1.5px solid var(--border); border-radius: 100px;
  cursor: pointer; transition: all .25s;
}
.user-menu-wrap .user-chip:hover { border-color: var(--accent); }
.user-dropdown {
  display: none; position: absolute; top: calc(100% + 8px); right: 0;
  min-width: 200px; background: var(--card); border: 1px solid var(--border);
  border-radius: 14px; box-shadow: var(--shadow-xl); padding: .4rem;
  z-index: 1100; animation: modalIn .2s ease;
}
.user-dropdown.open { display: block; }
.user-dropdown button {
  display: block; width: 100%; text-align: left; padding: .7rem 1rem;
  border-radius: 10px; font-size: .88rem; font-weight: 500; color: var(--text);
  transition: background .2s;
}
.user-dropdown button:hover { background: var(--accent-soft); color: var(--accent); }
.user-dropdown button.danger { color: var(--danger); }
.user-dropdown button.danger:hover { background: rgba(185,28,28,.1); }
.user-dropdown hr { border: none; border-top: 1px solid var(--border); margin: .35rem 0; }

/* ===== Notifications ===== */
.notif-wrap { position: relative; }
.notif-btn {
  width: 40px; height: 40px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.05); border: 1.5px solid var(--border);
  cursor: pointer; font-size: 1rem; position: relative; transition: all .25s;
}
.notif-btn:hover { background: var(--accent-soft); border-color: var(--accent); }
[data-theme="dark"] .notif-btn { background: rgba(255,255,255,.08); }
.notif-badge {
  position: absolute; top: 2px; right: 2px; min-width: 16px; height: 16px;
  background: var(--accent); color: #fff; font-size: .65rem; font-weight: 700;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  padding: 0 3px;
}
.notif-dropdown {
  display: none; position: absolute; top: calc(100% + 8px); right: 0;
  width: 300px; max-height: 360px; overflow-y: auto;
  background: var(--card); border: 1px solid var(--border);
  border-radius: 14px; box-shadow: var(--shadow-xl); z-index: 1100;
  padding: .5rem;
}
.notif-dropdown.open { display: block; }
.notif-item {
  padding: .75rem .9rem; border-radius: 10px; font-size: .85rem;
  border-bottom: 1px solid var(--border); cursor: default;
}
.notif-item:last-child { border-bottom: none; }
.notif-item strong { display: block; margin-bottom: .2rem; font-size: .88rem; }
.notif-item span { color: var(--muted); font-size: .78rem; }
.notif-empty { padding: 1.5rem; text-align: center; color: var(--muted); font-size: .88rem; }

/* ===== Progress bar ===== */
.upload-progress {
  margin-top: .75rem; display: none;
}
.upload-progress.active { display: block; }
.upload-progress-bar {
  height: 6px; background: var(--border); border-radius: 3px; overflow: hidden;
}
.upload-progress-bar > div {
  height: 100%; width: 0%; background: linear-gradient(90deg, var(--accent), var(--accent-light));
  border-radius: 3px; transition: width .25s ease;
}
.upload-progress-text {
  font-size: .78rem; color: var(--muted); margin-top: .35rem;
}

/* ===== Better auth modal ===== */
.modal {
  border: 1px solid var(--border);
}
.modal h2 { letter-spacing: -.02em; }
.auth-tabs { margin-top: .5rem; }

/* ===== Posts polish ===== */
.post-card {
  display: flex; flex-direction: column;
}
.post-img {
  background: linear-gradient(135deg, var(--accent-soft) 0%, var(--accent-muted) 100%);
}
[data-theme="dark"] .post-img {
  background: linear-gradient(135deg, #2a2220, #1a1514);
}
.post-body { flex: 1; }

/* Hide notif when not logged */
.notif-wrap.hidden { display: none; }

/* Dark mode visibility fixes */
[data-theme="dark"] .user-chip-name,
[data-theme="dark"] .user-menu-wrap .user-chip,
[data-theme="dark"] .nav-links a {
  color: #f5f5f4 !important;
}
[data-theme="dark"] .section-header h2,
[data-theme="dark"] .section-header p,
[data-theme="dark"] .hero h1,
[data-theme="dark"] .hero-desc,
[data-theme="dark"] .hero-stat strong {
  color: #f5f5f4 !important;
}
[data-theme="dark"] .section-header p,
[data-theme="dark"] .hero-desc,
[data-theme="dark"] .hero-stat span {
  color: #a8a29e !important;
}
[data-theme="dark"] .user-chip {
  background: #1e1e1e !important;
  border-color: #3a3a3a !important;
}
[data-theme="dark"] .post-card h3 { color: #f5f5f4; }
[data-theme="dark"] .post-card p { color: #a8a29e; }

/* Category folder cards on homepage */
.category-folders {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}
.cat-folder {
  background: var(--card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem 1.25rem;
  text-align: center;
  cursor: pointer;
  transition: all .35s var(--ease);
  box-shadow: var(--shadow);
}
.cat-folder:hover {
  transform: translateY(-6px);
  border-color: var(--accent);
  box-shadow: var(--shadow-lg);
}
.cat-folder-icon {
  font-size: 2.5rem;
  margin-bottom: .75rem;
  display: block;
}
.cat-folder h3 {
  font-family: var(--font);
  font-size: 1.05rem;
  font-weight: 650;
  margin-bottom: .35rem;
}
.cat-folder span {
  font-size: .82rem;
  color: var(--muted);
}

/* Category detail page view */
#category-page {
  display: none;
  min-height: 60vh;
  padding: 6rem 0 4rem;
}
#category-page.active { display: block; }
.cat-page-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}
.cat-page-header h1 {
  font-size: 2rem;
  flex: 1;
}

/* Mobile nav */
.nav-toggle {
  display: none;
  width: 42px; height: 42px; border-radius: 10px;
  background: rgba(0,0,0,.05); border: 1.5px solid var(--border);
  font-size: 1.25rem; align-items: center; justify-content: center;
  cursor: pointer; color: var(--text);
}
[data-theme="dark"] .nav-toggle { background: rgba(255,255,255,.08); }

@media (max-width: 960px) {
  .nav-toggle { display: inline-flex; }
  .nav-links {
    display: none;
    position: absolute;
    top: var(--nav-h);
    left: 0; right: 0;
    flex-direction: column;
    background: var(--card);
    border-bottom: 1px solid var(--border);
    padding: 1rem 1.5rem 1.25rem;
    gap: 0;
    box-shadow: var(--shadow-lg);
    z-index: 899;
  }
  .nav-links.open { display: flex; }
  .nav-links li { border-bottom: 1px solid var(--border); }
  .nav-links a {
    display: block; padding: .85rem 0; font-size: 1rem;
  }
  .nav-inner { position: relative; flex-wrap: wrap; }
}

/* Lightbox navigation */
.lightbox { flex-direction: column; gap: 0.5rem; }
.lightbox-stage {
  display: flex; align-items: center; justify-content: center;
  max-width: 92vw; max-height: 82vh;
}
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 48px; height: 48px; border-radius: 50%;
  background: rgba(255,255,255,.15); color: #fff; font-size: 1.8rem;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; z-index: 5001; border: none;
  transition: background .2s;
}
.lightbox-nav:hover { background: rgba(255,255,255,.3); }
.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }
.lightbox-counter {
  color: rgba(255,255,255,.7); font-size: .85rem; z-index: 5001;
}
@media (max-width: 600px) {
  .lightbox-nav { width: 40px; height: 40px; font-size: 1.5rem; }
  .lightbox-prev { left: .4rem; }
  .lightbox-next { right: .4rem; }
}

/* Category folder cover image */
.cat-folder-cover {
  width: 100%; height: 100px; object-fit: cover;
  border-radius: 12px; margin-bottom: .75rem;
  background: var(--bg);
}
.cat-folder.has-cover .cat-folder-icon { display: none; }

/* Posts heading dark mode */
.posts-heading,
[data-theme="dark"] .posts-heading,
[data-theme="dark"] #aktualnosci .section-header h2 {
  color: #f5f5f4 !important;
  opacity: 1 !important;
}
[data-theme="dark"] #aktualnosci .section-label {
  color: var(--accent) !important;
}
[data-theme="dark"] #aktualnosci {
  background: #161616 !important;
}

/* Post card with real image */
.post-img img {
  width: 100%; height: 100%; object-fit: cover;
}
.post-img.has-image::after { display: none; }


/* Najnowsze wpisy – light mode czytelny */
#aktualnosci .posts-heading,
#aktualnosci .section-header h2 {
  color: #1a1a1a !important;
}
[data-theme="dark"] #aktualnosci .posts-heading,
[data-theme="dark"] #aktualnosci .section-header h2 {
  color: #f5f5f4 !important;
}
.gallery-item img[src=""],
.gallery-item img:not([src]) {
  display: none;
}

/* ===== About section ===== */
.about-section { background: var(--bg-alt); }
.about-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 3rem;
  align-items: center;
}
.about-content h2 {
  font-family: var(--font);
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 700;
  margin: .5rem 0 1.5rem;
  letter-spacing: -.02em;
  color: var(--text);
}
.about-text p {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.75;
  margin-bottom: 1rem;
}
.about-text strong { color: var(--text); font-weight: 600; }
.about-features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .85rem 1.25rem;
  margin-top: 1.75rem;
}
.about-feature {
  display: flex;
  align-items: center;
  gap: .65rem;
  font-size: .95rem;
  font-weight: 550;
  color: var(--text);
}
.af-icon {
  width: 28px; height: 28px; border-radius: 50%;
  background: rgba(34, 197, 94, .15);
  color: #16a34a;
  display: flex; align-items: center; justify-content: center;
  font-size: .85rem; font-weight: 700; flex-shrink: 0;
}
.about-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  padding: 2.5rem 2rem;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}
.about-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--accent-light));
}
.about-stat-big strong {
  display: block;
  font-family: var(--font);
  font-size: 3.2rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}
.about-stat-big span {
  font-size: .9rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.about-divider {
  height: 1px; background: var(--border);
  margin: 1.5rem 0;
}
.about-card p {
  color: var(--muted);
  font-size: .95rem;
  line-height: 1.6;
  margin-bottom: .5rem;
}
.about-highlight {
  color: var(--text) !important;
  font-weight: 650 !important;
  font-size: 1.05rem !important;
}
@media (max-width: 800px) {
  .about-grid { grid-template-columns: 1fr; gap: 2rem; }
  .about-features { grid-template-columns: 1fr; }
}

/* Slider video – lepsza widoczność w light mode */
.slide video {
  width: 100%; height: 100%; object-fit: cover;
  filter: brightness(0.85);
}
[data-theme="light"] .slide video,
:root:not([data-theme="dark"]) .slide video {
  filter: brightness(0.72) contrast(1.05);
}
.slide.has-video .slide-overlay {
  background: linear-gradient(
    135deg,
    rgba(0,0,0,.55) 0%,
    rgba(0,0,0,.35) 40%,
    rgba(0,0,0,.45) 100%
  ) !important;
}
[data-theme="light"] .slide.has-video .slide-overlay,
:root:not([data-theme="dark"]) .slide.has-video .slide-overlay {
  background: linear-gradient(
    135deg,
    rgba(20,15,12,.65) 0%,
    rgba(20,15,12,.4) 45%,
    rgba(20,15,12,.55) 100%
  ) !important;
}
/* Hero text on video always readable */
.hero-content {
  text-shadow: 0 2px 24px rgba(0,0,0,.25);
}
[data-theme="light"] .hero.has-video-slide .hero-content h1,
:root:not([data-theme="dark"]) .hero.has-video-slide .hero-content h1 {
  color: #fff !important;
}
[data-theme="light"] .hero.has-video-slide .hero-desc,
[data-theme="light"] .hero.has-video-slide .hero-stat span,
:root:not([data-theme="dark"]) .hero.has-video-slide .hero-desc {
  color: rgba(255,255,255,.9) !important;
}
[data-theme="light"] .hero.has-video-slide .hero-stat strong {
  color: #fff !important;
}


/* ===== News cards (Aktualności) ===== */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
@media (max-width: 960px) {
  .posts-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .posts-grid { grid-template-columns: 1fr; }
}
.post-card {
  background: var(--card);
  border-radius: 18px;
  border: 1px solid var(--border);
  box-shadow: 0 4px 24px rgba(0,0,0,.06);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .3s ease, box-shadow .3s ease;
}
.post-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 36px rgba(0,0,0,.1);
}
.post-cover {
  width: 100%;
  height: 160px;
  overflow: hidden;
  background: var(--bg-alt);
}
.post-cover img {
  width: 100%; height: 100%; object-fit: cover;
}
.post-body {
  padding: 1.35rem 1.4rem 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.post-title {
  font-family: var(--font);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 1rem;
  line-height: 1.35;
  letter-spacing: -.01em;
}
.post-meta { margin-bottom: .65rem; }
.post-author {
  display: flex;
  align-items: center;
  gap: .55rem;
  flex-wrap: wrap;
}
.post-author-av {
  width: 32px; height: 32px; border-radius: 50%;
  object-fit: cover; flex-shrink: 0;
}
.post-author-letter {
  background: linear-gradient(135deg, var(--accent), #8b5cf6);
  color: #fff; font-size: .8rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.post-author-name {
  font-size: .88rem;
  font-weight: 600;
  color: var(--text);
}
.post-role-badge {
  font-size: .68rem;
  font-weight: 700;
  background: #c45c4a;
  color: #fff;
  padding: .2rem .55rem;
  border-radius: 100px;
  letter-spacing: .02em;
}
.post-date {
  font-size: .82rem;
  color: var(--muted);
  margin-bottom: .85rem;
  display: flex;
  align-items: center;
  gap: .35rem;
}
.post-date-icon { font-size: .9rem; opacity: .85; }
.post-excerpt {
  font-size: .92rem;
  line-height: 1.65;
  color: var(--muted);
  margin: 0 0 1.15rem;
  flex: 1;
}
.post-readmore {
  background: none;
  border: none;
  padding: 0;
  color: #7c3aed;
  font-size: .9rem;
  font-weight: 650;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  transition: color .2s;
  align-self: flex-start;
}
.post-readmore:hover { color: var(--accent); }

/* Post modal */
.post-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}
.post-modal.open { display: flex; }
.post-modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.55);
  backdrop-filter: blur(4px);
}
.post-modal-box {
  position: relative;
  background: var(--card);
  border-radius: 20px;
  max-width: 560px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 2rem;
  box-shadow: var(--shadow-xl);
  z-index: 1;
  animation: modalIn .25s ease;
}
.post-modal-close {
  position: absolute; top: .85rem; right: 1rem;
  background: none; border: none;
  font-size: 1.6rem; cursor: pointer; color: var(--muted);
  line-height: 1;
}
.post-modal-cover {
  width: 100%; max-height: 220px; object-fit: cover;
  border-radius: 12px; margin-bottom: 1.25rem;
}
.post-modal-box h2 {
  font-family: var(--font);
  font-size: 1.45rem;
  margin: 0 0 .5rem;
  color: var(--text);
}
.post-modal-meta {
  font-size: .85rem;
  color: var(--muted);
  margin-bottom: 1.25rem;
}
.post-modal-content {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--text);
}

#aktualnosci .section-header h2 {
  font-size: clamp(1.8rem, 3vw, 2.2rem);
}

.about-content-wide { max-width: 760px; margin: 0 auto; }
.about-content-wide h2 { text-align: left; }
.about-section .section-label { display: inline-block; }

/* ========== MOBILE / PHONE ========== */
@media (max-width: 768px) {
  :root { --nav-h: 60px; }

  .container { padding: 0 1.1rem; }

  .nav-inner {
    padding: 0 1rem;
    gap: .5rem;
  }
  .logo { font-size: 1.15rem; }
  .logo img, #logo-img {
    max-height: 36px !important;
    max-width: 120px;
    object-fit: contain;
  }
  .nav-actions {
    gap: .35rem;
    margin-left: auto;
  }
  .nav-actions .btn {
    padding: .4rem .7rem;
    font-size: .78rem;
  }
  .theme-toggle, .notif-btn {
    width: 36px; height: 36px; font-size: .95rem;
  }
  .user-chip-name { display: none; }
  .user-menu-wrap .user-chip { padding: .2rem; }

  .nav-links {
    top: var(--nav-h);
    max-height: calc(100vh - var(--nav-h));
    overflow-y: auto;
    padding: .5rem 0 1rem;
  }
  .nav-links a {
    padding: 1rem 1.25rem;
    font-size: 1.05rem;
  }

  .hero {
    min-height: 78vh;
    padding-top: var(--nav-h);
  }
  .hero-content {
    padding: 2rem 1.1rem 3rem;
  }
  .hero-badge {
    font-size: .72rem;
    padding: .35rem .75rem;
    margin-bottom: 1rem;
  }
  .hero h1 {
    font-size: clamp(1.65rem, 7vw, 2.2rem);
    margin-bottom: 1rem;
    line-height: 1.2;
  }
  .hero-desc {
    font-size: .98rem;
    margin-bottom: 1.5rem;
  }
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
    gap: .65rem;
    margin-bottom: 1.5rem;
  }
  .hero-actions .btn {
    width: 100%;
    text-align: center;
    justify-content: center;
  }
  .slider-dots {
    bottom: 1rem;
  }

  .section { padding: 3.25rem 0; }
  .section-header { margin-bottom: 2rem; }
  .section-header h2 {
    font-size: clamp(1.45rem, 5.5vw, 1.85rem);
  }

  .services-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem;
  }
  .service-card { padding: 1.35rem 1.2rem; }

  .about-content-wide { max-width: 100%; }
  .about-features {
    grid-template-columns: 1fr !important;
    gap: .7rem;
  }
  .about-text p { font-size: .98rem; }

  .category-folders {
    grid-template-columns: 1fr 1fr !important;
    gap: .75rem;
  }
  .cat-folder {
    padding: 1.1rem .75rem;
  }
  .cat-folder-cover { height: 72px; }
  .cat-folder h3 { font-size: .92rem; }
  .cat-folder-icon { font-size: 1.8rem; }

  .gallery-filters {
    flex-wrap: wrap;
    gap: .4rem;
    justify-content: flex-start;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: .25rem;
  }
  .filter-btn {
    font-size: .78rem;
    padding: .4rem .75rem;
    white-space: nowrap;
  }
  .gallery-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: .55rem;
  }
  .gallery-overlay {
    opacity: 1;
    padding: .65rem;
    background: linear-gradient(to top, rgba(0,0,0,.65) 0%, transparent 70%);
  }
  .gallery-overlay strong { font-size: .78rem; }

  .posts-grid {
    grid-template-columns: 1fr !important;
    gap: 1.1rem;
  }
  .post-body { padding: 1.15rem 1.15rem 1.1rem; }
  .post-title { font-size: 1.05rem; }

  .contact-grid {
    grid-template-columns: 1fr !important;
    gap: 1.5rem;
  }
  .contact-form { padding: 1.25rem; }
  .form-row {
    grid-template-columns: 1fr !important;
  }

  .footer { padding: 2.5rem 0 1.5rem; }
  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 1.5rem;
  }

  .modal {
    width: calc(100% - 1.5rem);
    max-width: 100%;
    margin: .75rem;
    padding: 1.35rem 1.15rem;
    max-height: 90vh;
    overflow-y: auto;
  }

  .lightbox-nav {
    width: 40px; height: 40px;
  }
  .lightbox-prev { left: .35rem; }
  .lightbox-next { right: .35rem; }
  .lightbox-stage {
    max-width: 96vw;
    max-height: 70vh;
  }

  .post-modal-box {
    margin: .5rem;
    padding: 1.35rem 1.15rem;
    max-height: 90vh;
  }

  .cat-page-header {
    flex-direction: column;
    align-items: flex-start;
    gap: .75rem;
  }
  .cat-page-header h1 { font-size: 1.45rem; }
}

@media (max-width: 400px) {
  .category-folders {
    grid-template-columns: 1fr !important;
  }
  .gallery-grid {
    grid-template-columns: 1fr !important;
  }
  .nav-actions .btn-outline#btn-register {
    display: none;
  }
}

/* Touch-friendly */
@media (hover: none) {
  .gallery-item:hover { transform: none; }
  .post-card:hover { transform: none; }
  .service-card:hover { transform: none; }
}

.af-icon {
  background: var(--accent-soft) !important;
  color: var(--accent) !important;
  font-size: .75rem !important;
}
.service-icon {
  font-size: 1.75rem;
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  background: var(--accent-soft);
  border-radius: 14px;
  margin-bottom: 1rem;
}
.post-date-icon { filter: grayscale(.3); }

/* Professional SVG icons */
.ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}
.ico svg {
  width: 1.15em;
  height: 1.15em;
  display: block;
}
.service-icon {
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 14px;
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem;
}
.service-icon .ico svg,
.service-icon svg {
  width: 24px; height: 24px;
}
.af-icon {
  width: 32px !important; height: 32px !important;
  border-radius: 10px !important;
  background: var(--accent-soft) !important;
  color: var(--accent) !important;
  display: inline-flex !important;
  align-items: center; justify-content: center;
}
.af-icon .ico svg,
.af-icon svg { width: 16px; height: 16px; }
.cat-folder-ico {
  width: 40px; height: 40px;
  color: var(--accent);
  margin: 0 auto .65rem;
  display: flex;
}
.cat-folder-ico svg { width: 36px; height: 36px; }
.post-date-icon {
  display: inline-flex;
  vertical-align: middle;
  color: var(--muted);
  margin-right: .15rem;
}
.post-date-icon svg { width: 15px; height: 15px; }
.ico-inline {
  display: inline-flex;
  vertical-align: middle;
  margin-right: .25rem;
}
.ico-inline svg { width: 16px; height: 16px; }
.theme-toggle .ico svg { width: 18px; height: 18px; }
.notif-btn .ico svg { width: 18px; height: 18px; }
.theme-icon-light, .theme-icon-dark { display: none; }
:root:not([data-theme="dark"]) .theme-icon-light,
[data-theme="light"] .theme-icon-light { display: inline-flex; }
[data-theme="dark"] .theme-icon-dark { display: inline-flex; }

/* Floating contact */
.float-contact {
  position: fixed;
  right: 1rem;
  bottom: 1.25rem;
  z-index: 800;
  display: flex;
  flex-direction: column;
  gap: .65rem;
}
.float-btn {
  width: 52px; height: 52px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 20px rgba(0,0,0,.18);
  transition: transform .2s, box-shadow .2s;
  color: #fff;
}
.float-btn:hover { transform: scale(1.08); box-shadow: 0 8px 28px rgba(0,0,0,.25); }
.float-btn svg { width: 24px; height: 24px; }
.float-phone { background: #1a1a1a; }
.float-wa { background: #25D366; }
@media (min-width: 900px) {
  .float-contact { right: 1.5rem; bottom: 1.75rem; }
}

/* FAQ */
.faq-section { background: var(--bg); }
.faq-list { max-width: 720px; margin: 0 auto; }
.faq-item {
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--card);
  margin-bottom: .75rem;
  overflow: hidden;
}
.faq-q {
  width: 100%;
  text-align: left;
  padding: 1.1rem 1.25rem;
  background: none;
  border: none;
  font-size: 1rem;
  font-weight: 650;
  color: var(--text);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-family: inherit;
}
.faq-q::after {
  content: '+';
  font-size: 1.25rem;
  color: var(--accent);
  font-weight: 400;
  flex-shrink: 0;
}
.faq-item.open .faq-q::after { content: '−'; }
.faq-a {
  display: none;
  padding: 0 1.25rem 1.15rem;
  color: var(--muted);
  font-size: .95rem;
  line-height: 1.65;
}
.faq-item.open .faq-a { display: block; }

/* Drag handle */
.drag-handle {
  cursor: grab;
  color: var(--muted);
  padding: .25rem .4rem;
  user-select: none;
  font-size: 1rem;
}
.drag-handle:active { cursor: grabbing; }
tr.dragging { opacity: .5; background: var(--accent-soft); }

/* Post preview modal uses post-modal styles */

/* ===== Dark / light text consistency ===== */
[data-theme="dark"] body,
[data-theme="dark"] p,
[data-theme="dark"] li,
[data-theme="dark"] span,
[data-theme="dark"] label {
  color: var(--text);
}
[data-theme="dark"] .section-header h2,
[data-theme="dark"] h1,
[data-theme="dark"] h2,
[data-theme="dark"] h3 {
  color: #f5f5f4 !important;
}
[data-theme="dark"] .section-header p,
[data-theme="dark"] .hero-desc,
[data-theme="dark"] .service-card p,
[data-theme="dark"] .about-text p,
[data-theme="dark"] .post-excerpt,
[data-theme="dark"] .footer p,
[data-theme="dark"] .muted,
[data-theme="dark"] .modal-sub {
  color: #a8a29e !important;
}
[data-theme="dark"] .nav-links a {
  color: #e7e5e4 !important;
}
[data-theme="dark"] .nav-links a:hover {
  color: var(--accent) !important;
}
[data-theme="dark"] .logo,
[data-theme="dark"] #logo-text {
  color: #f5f5f4 !important;
}
[data-theme="dark"] .service-card,
[data-theme="dark"] .post-card,
[data-theme="dark"] .faq-item,
[data-theme="dark"] .about-card,
[data-theme="dark"] .cat-folder,
[data-theme="dark"] .contact-card {
  background: #1e1e1e !important;
  border-color: rgba(255,255,255,.08) !important;
  color: #f5f5f4;
}
[data-theme="dark"] .service-card h3,
[data-theme="dark"] .post-title,
[data-theme="dark"] .cat-folder h3,
[data-theme="dark"] .faq-q {
  color: #f5f5f4 !important;
}
[data-theme="dark"] .filter-btn {
  background: #1e1e1e;
  border-color: rgba(255,255,255,.1);
  color: #a8a29e;
}
[data-theme="dark"] .filter-btn.active,
[data-theme="dark"] .filter-btn:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
[data-theme="dark"] .footer {
  background: #0c0c0c !important;
  color: #a8a29e;
}
[data-theme="dark"] .footer a {
  color: #d6d3d1;
}
[data-theme="dark"] .footer h4 {
  color: #f5f5f4 !important;
}
[data-theme="dark"] .modal {
  background: #1a1a1a !important;
  color: #f5f5f4;
}
[data-theme="dark"] .modal input,
[data-theme="dark"] .modal textarea,
[data-theme="dark"] .contact-form input,
[data-theme="dark"] .contact-form textarea {
  background: #141414 !important;
  border-color: #333 !important;
  color: #f5f5f4 !important;
}
[data-theme="dark"] .user-chip,
[data-theme="dark"] .user-menu {
  background: #1e1e1e;
  color: #f5f5f4;
  border-color: rgba(255,255,255,.1);
}
[data-theme="dark"] .user-menu a,
[data-theme="dark"] .user-menu button {
  color: #e7e5e4 !important;
}
[data-theme="dark"] .section-label {
  color: var(--accent) !important;
}
[data-theme="dark"] .btn-outline {
  border-color: rgba(255,255,255,.2);
  color: #f5f5f4;
}
[data-theme="dark"] .btn-outline:hover {
  background: rgba(255,255,255,.08);
}
[data-theme="dark"] .post-author-name {
  color: #f5f5f4 !important;
}
[data-theme="dark"] .post-date {
  color: #a8a29e !important;
}
[data-theme="dark"] .post-readmore {
  color: #c4b5fd !important;
}
[data-theme="dark"] .about-feature {
  color: #e7e5e4 !important;
}
[data-theme="dark"] .cat-folder span {
  color: #a8a29e !important;
}

/* Light mode safety for headings that were forced white */
:root:not([data-theme="dark"]) .posts-heading,
[data-theme="light"] .posts-heading,
:root:not([data-theme="dark"]) #aktualnosci .section-header h2 {
  color: #1a1a1a !important;
}

/* ===== Animated ambient background ===== */
.bg-ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}
.bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: .45;
  animation: orbFloat 18s ease-in-out infinite;
}
.bg-orb-1 {
  width: 420px; height: 420px;
  background: radial-gradient(circle, rgba(224,122,95,.35), transparent 70%);
  top: -10%; left: -8%;
  animation-duration: 22s;
}
.bg-orb-2 {
  width: 360px; height: 360px;
  background: radial-gradient(circle, rgba(139,92,246,.22), transparent 70%);
  bottom: 10%; right: -5%;
  animation-duration: 26s;
  animation-delay: -6s;
}
.bg-orb-3 {
  width: 280px; height: 280px;
  background: radial-gradient(circle, rgba(224,122,95,.18), transparent 70%);
  top: 45%; left: 40%;
  animation-duration: 20s;
  animation-delay: -3s;
}
[data-theme="dark"] .bg-orb-1 {
  background: radial-gradient(circle, rgba(224,122,95,.2), transparent 70%);
  opacity: .55;
}
[data-theme="dark"] .bg-orb-2 {
  background: radial-gradient(circle, rgba(139,92,246,.18), transparent 70%);
}
[data-theme="dark"] .bg-orb-3 {
  background: radial-gradient(circle, rgba(255,255,255,.04), transparent 70%);
}
@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(40px, -30px) scale(1.08); }
  66% { transform: translate(-30px, 25px) scale(.95); }
}

/* Soft grain + mesh */
.bg-mesh {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(at 20% 20%, rgba(224,122,95,.06) 0, transparent 50%),
    radial-gradient(at 80% 0%, rgba(139,92,246,.05) 0, transparent 45%),
    radial-gradient(at 50% 80%, rgba(224,122,95,.04) 0, transparent 50%);
  animation: meshShift 30s ease-in-out infinite alternate;
}
@keyframes meshShift {
  from { transform: scale(1) translate(0, 0); }
  to { transform: scale(1.05) translate(-1%, 1%); }
}

/* Section fade-in on scroll feel */
.section {
  position: relative;
  animation: fadeUp .7s ease both;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
.service-card, .post-card, .cat-folder, .faq-item {
  transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}
.service-card:hover, .post-card:hover, .cat-folder:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0,0,0,.1);
}
[data-theme="dark"] .service-card:hover,
[data-theme="dark"] .post-card:hover {
  box-shadow: 0 16px 40px rgba(0,0,0,.4);
}

/* Admin form panels smoother */
#dashboard .admin-form .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
@media (max-width: 640px) {
  #dashboard .admin-form .form-row { grid-template-columns: 1fr; }
  .bg-orb { opacity: .3; filter: blur(60px); }
}

.remember-row {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-size: .88rem;
  color: var(--muted);
  margin: .5rem 0 1rem;
  cursor: pointer;
  user-select: none;
}
.remember-row input { width: auto; accent-color: var(--accent); }


/* Typography refresh – strona główna */
body {
  font-family: var(--font);
  font-weight: 500;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
}
.hero h1,
.section-header h2,
.about-content h2,
.posts-heading,
.logo,
#logo-text {
  font-family: var(--display) !important;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.hero h1 {
  font-size: clamp(2.4rem, 5.5vw, 3.6rem);
  line-height: 1.08;
  font-weight: 700;
}
.section-header h2 {
  font-size: clamp(1.85rem, 3.5vw, 2.55rem);
  font-weight: 700;
}
.hero-desc,
.section-header p,
.about-text p,
.service-card p,
.post-excerpt {
  font-family: var(--font);
  font-weight: 500;
  letter-spacing: -0.005em;
}
.nav-links a {
  font-weight: 600;
  letter-spacing: 0.01em;
  font-size: .88rem;
}
.btn {
  font-family: var(--font);
  font-weight: 700;
  letter-spacing: 0.01em;
}
.service-card h3,
.post-title,
.cat-folder h3,
.faq-q {
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: -0.015em;
}
.section-label {
  font-family: var(--font);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: .72rem;
}

.cat-folder-media {
  width: 100%;
  height: 88px;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.06);
  margin-bottom: .65rem;
  position: relative;
}
[data-theme="dark"] .cat-folder-media {
  background: rgba(255,255,255,.06);
}
.cat-folder-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cat-folder-fallback {
  position: absolute;
  inset: 0;
  align-items: center;
  justify-content: center;
}
.cat-folder-ico, .cat-folder-icon {
  color: var(--accent);
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
}
.cat-folder-ico svg, .cat-folder-icon svg { width: 32px; height: 32px; }
.gallery-item img.img-broken {
  opacity: .25;
  background: var(--bg-alt);
}
.img-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  color: var(--muted); font-size: .8rem;
  background: var(--bg-alt);
}
.cat-folder h3 {
  margin: 0 0 .2rem;
  font-size: 1rem;
}
.cat-folder > span {
  font-size: .8rem;
  color: var(--muted);
}

/* Gallery & slider images – mobile fix */
.gallery-item { background: var(--bg-alt); min-height: 140px; }
.gallery-item img {
  width: 100%; height: 100%; object-fit: cover; display: block; background: #e7e5e4;
}
[data-theme="dark"] .gallery-item img { background: #2a2a2a; }
[data-theme="light"] .cat-folder, :root:not([data-theme="dark"]) .cat-folder {
  background: #fff; border-color: #e7e5e4; box-shadow: 0 4px 16px rgba(0,0,0,.06);
}
[data-theme="dark"] .cat-folder { background: #1e1e1e; border-color: rgba(255,255,255,.1); }
[data-theme="dark"] .cat-folder h3 { color: #f5f5f4 !important; }
[data-theme="light"] .cat-folder h3, :root:not([data-theme="dark"]) .cat-folder h3 { color: #1c1917 !important; }
[data-theme="light"] .filter-btn, :root:not([data-theme="dark"]) .filter-btn {
  background: #fff; border: 1.5px solid #e7e5e4; color: #57534e;
}
[data-theme="light"] .filter-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; }
@media (max-width: 768px) {
  .hero { background: linear-gradient(160deg, #2a2422 0%, #4a3f3a 50%, #1a1514 100%); }
  [data-theme="light"] .hero, :root:not([data-theme="dark"]) .hero {
    background: linear-gradient(160deg, #f5ebe6 0%, #e8d5cc 45%, #d4c0b6 100%);
  }
  [data-theme="light"] .hero-content h1, :root:not([data-theme="dark"]) .hero-content h1 { color: #1c1917; }
  [data-theme="light"] .hero-desc, :root:not([data-theme="dark"]) .hero-desc { color: #57534e !important; }
  [data-theme="dark"] .hero-content h1 { color: #fff !important; }
  .slide img, .slide video { min-height: 100%; width: 100%; object-fit: cover; }
  .gallery-item { aspect-ratio: 1; border-radius: 14px; overflow: hidden; }
}

/* ========== Design upgrade 1–9 ========== */

/* 6. Subtle fabric/paper texture */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}
[data-theme="dark"] body::before { opacity: 0.06; }
body > * { position: relative; z-index: 1; }
.bg-ambient { z-index: 0; }

/* 1. Fullscreen cinematic hero */
.hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  position: relative;
}
.hero .slide-overlay {
  background: linear-gradient(
    120deg,
    rgba(20, 14, 12, 0.72) 0%,
    rgba(20, 14, 12, 0.45) 45%,
    rgba(20, 14, 12, 0.55) 100%
  ) !important;
}
.hero-content {
  max-width: 720px;
  padding: 2rem 1.5rem;
}
.hero-content::before {
  content: '';
  position: absolute;
  inset: -1.5rem -2rem;
  background: rgba(12, 10, 9, 0.25);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 28px;
  z-index: -1;
  pointer-events: none;
}
.hero-badge {
  backdrop-filter: blur(8px);
}
.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  text-shadow: 0 4px 32px rgba(0,0,0,.35);
}
.hero-desc {
  text-shadow: 0 2px 12px rgba(0,0,0,.3);
  max-width: 420px;
}
[data-theme="light"] .hero .slide-overlay {
  background: linear-gradient(
    120deg,
    rgba(40, 30, 26, 0.55) 0%,
    rgba(40, 30, 26, 0.3) 50%,
    rgba(40, 30, 26, 0.45) 100%
  ) !important;
}

/* 2. Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* 3. Soft UI cards */
.service-card,
.post-card,
.cat-folder,
.faq-item,
.process-step {
  border-radius: 20px !important;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06) !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  transition: transform 0.35s ease, box-shadow 0.35s ease !important;
}
[data-theme="dark"] .service-card,
[data-theme="dark"] .post-card,
[data-theme="dark"] .cat-folder,
[data-theme="dark"] .faq-item,
[data-theme="dark"] .process-step {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35) !important;
  border-color: rgba(255, 255, 255, 0.07) !important;
}
.service-card:hover,
.post-card:hover,
.cat-folder:hover,
.process-step:hover {
  transform: translateY(-6px) !important;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.12) !important;
}

/* 4. Gallery hover */
.gallery-item {
  border-radius: 18px !important;
  overflow: hidden;
  border: 2px solid transparent;
  transition: border-color 0.3s ease, transform 0.35s ease, box-shadow 0.35s ease !important;
}
.gallery-item:hover {
  border-color: var(--accent) !important;
  transform: translateY(-4px) scale(1.01) !important;
  box-shadow: 0 16px 40px rgba(224, 122, 95, 0.25) !important;
}
.gallery-item img {
  transition: transform 0.55s ease !important;
}
.gallery-item:hover img {
  transform: scale(1.1) !important;
}

/* 7. Stitch line under headers */
.stitch-line {
  width: 72px;
  height: 3px;
  margin: 1rem auto 0;
  background: repeating-linear-gradient(
    90deg,
    var(--accent) 0 6px,
    transparent 6px 10px
  );
  border-radius: 2px;
  opacity: 0.85;
}
.section-header .stitch-line { margin-left: auto; margin-right: auto; }

/* 9. Process section */
.process-section {
  background: var(--bg-alt);
}
.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}
@media (max-width: 900px) {
  .process-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .process-grid { grid-template-columns: 1fr; }
}
.process-step {
  background: var(--card);
  padding: 1.75rem 1.4rem;
  position: relative;
  text-align: left;
}
.process-num {
  font-family: var(--display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  opacity: 0.35;
  line-height: 1;
  margin-bottom: 0.75rem;
}
.process-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: var(--accent-soft, rgba(224,122,95,.12));
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem;
}
.process-icon svg { width: 22px; height: 22px; }
.process-step h3 {
  font-family: var(--display);
  font-size: 1.25rem;
  margin: 0 0 0.5rem;
  color: var(--text);
}
.process-step p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* 8. Before / after slider */
.ba-section { background: var(--bg); }
.ba-slider {
  position: relative;
  max-width: 820px;
  margin: 0 auto;
  aspect-ratio: 16 / 10;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,.15);
  user-select: none;
  background: #2a2a2a;
}
.ba-img {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}
.ba-before { z-index: 1; }
.ba-after {
  z-index: 2;
  width: 50%;
  overflow: hidden;
  border-right: 2px solid #fff;
}
.ba-after::after {
  content: '';
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-image: inherit;
  width: 100%;
  min-width: 820px;
  max-width: none;
}
.ba-range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  z-index: 5;
  cursor: ew-resize;
  margin: 0;
}
.ba-handle {
  position: absolute;
  top: 0; bottom: 0;
  left: 50%;
  width: 3px;
  background: #fff;
  z-index: 4;
  transform: translateX(-50%);
  pointer-events: none;
  box-shadow: 0 0 12px rgba(0,0,0,.3);
}
.ba-handle::before {
  content: '⟷';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px; height: 40px;
  border-radius: 50%;
  background: #fff;
  color: #333;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
  box-shadow: 0 4px 16px rgba(0,0,0,.25);
}
.ba-label {
  position: absolute;
  bottom: 1rem;
  z-index: 3;
  background: rgba(0,0,0,.55);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.35rem 0.75rem;
  border-radius: 100px;
}
.ba-label-l { left: 1rem; }
.ba-label-r { right: 1rem; }
.ba-hint {
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 1rem;
}

/* 5. Footer elegant */
.footer {
  background: #0e0e0e !important;
  padding: 3.5rem 0 0 !important;
  border-top: 1px solid rgba(255,255,255,.06);
}
.footer-top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2.5rem;
  padding-bottom: 2.5rem;
}
@media (max-width: 700px) {
  .footer-top { grid-template-columns: 1fr; gap: 1.75rem; }
}
.footer-logo {
  font-family: var(--display) !important;
  font-size: 1.75rem !important;
  color: #fff !important;
  margin-bottom: 0.85rem;
}
.footer-logo span { color: var(--accent) !important; }
.footer-brand p {
  color: rgba(255,255,255,.5) !important;
  font-size: 0.9rem;
  line-height: 1.65;
  max-width: 280px;
  margin: 0;
}
.footer-col h4 {
  color: #fff !important;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin: 0 0 1rem;
  font-weight: 700;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 0.55rem; color: rgba(255,255,255,.5); font-size: 0.9rem; }
.footer-col a {
  color: rgba(255,255,255,.55) !important;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-col a:hover { color: #fff !important; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding: 1.25rem 0 1.5rem;
  border-top: 1px solid rgba(255,255,255,.08);
  font-size: 0.82rem;
  color: rgba(255,255,255,.4);
}
.footer-bottom .creator a {
  color: var(--accent) !important;
  text-decoration: none;
  font-weight: 600;
}
.footer-bottom .creator a:hover { text-decoration: underline; }

@media (max-width: 768px) {
  .hero-content::before {
    inset: -0.75rem -0.5rem;
    border-radius: 20px;
  }
}

/* ===== Contrast on dark hero / transparent nav ===== */
.hero-actions .btn-outline {
  color: #fff !important;
  border-color: rgba(255, 255, 255, 0.75) !important;
  background: rgba(255, 255, 255, 0.08) !important;
  text-shadow: none;
}
.hero-actions .btn-outline:hover {
  background: rgba(255, 255, 255, 0.2) !important;
  border-color: #fff !important;
  color: #fff !important;
}
.hero-actions .btn-primary {
  color: #fff !important;
}

/* Nav over hero (not scrolled) – light controls */
.nav:not(.scrolled) .nav-links a {
  color: #fff !important;
  text-shadow: 0 1px 8px rgba(0,0,0,.35);
}
.nav:not(.scrolled) .nav-links a:hover {
  color: #f8d0c4 !important;
}
.nav:not(.scrolled) .btn-outline {
  color: #fff !important;
  border-color: rgba(255, 255, 255, 0.7) !important;
  background: rgba(255, 255, 255, 0.1) !important;
}
.nav:not(.scrolled) .btn-outline:hover {
  background: rgba(255, 255, 255, 0.22) !important;
  color: #fff !important;
  border-color: #fff !important;
}
.nav:not(.scrolled) .theme-toggle,
.nav:not(.scrolled) .notif-btn,
.nav:not(.scrolled) .nav-toggle {
  color: #fff !important;
  border-color: rgba(255, 255, 255, 0.45) !important;
  background: rgba(255, 255, 255, 0.12) !important;
}
.nav:not(.scrolled) .theme-toggle .ico,
.nav:not(.scrolled) .notif-btn .ico {
  color: #fff !important;
}

/* Scrolled nav – readable again */
.nav.scrolled .btn-outline {
  color: var(--text) !important;
  border-color: var(--border) !important;
  background: transparent !important;
}
.nav.scrolled .nav-links a {
  color: var(--text) !important;
  text-shadow: none;
}
[data-theme="dark"] .nav.scrolled {
  background: rgba(18, 18, 18, 0.92) !important;
}
[data-theme="dark"] .nav.scrolled .btn-outline {
  color: #f5f5f4 !important;
  border-color: rgba(255,255,255,.25) !important;
}
[data-theme="dark"] .nav.scrolled .nav-links a {
  color: #e7e5e4 !important;
}

/* Mobile menu open on dark – keep readable */
@media (max-width: 768px) {
  .nav:not(.scrolled) .nav-links {
    background: rgba(20, 16, 14, 0.96);
  }
  .nav:not(.scrolled) .nav-links a {
    color: #fff !important;
  }
  .nav.scrolled .nav-links {
    background: var(--card);
  }
}
