/* Noventra module styles (loaded only when a module is active). */

/* Dark mode palette */
html[data-nv-theme="dark"] {
	--nv-color-bg: #0f172a;
	--nv-color-text: #cbd5e1;
	--nv-color-heading: #f1f5f9;
	--nv-color-border: #1e293b;
	--nv-color-muted: #94a3b8;
	--nv-header-bg: #0f172a;
	--nv-card-bg: #131c31;
}
.nv-dark-icon-sun { display:none; }
html[data-nv-theme="dark"] .nv-dark-icon-moon { display:none; }
html[data-nv-theme="dark"] .nv-dark-icon-sun { display:inline; }

/* Sticky header */
body.nv-sticky-header .site-header.is-stuck {
	position:fixed; top:0; left:0; right:0; z-index:999;
	box-shadow:0 4px 20px rgba(0,0,0,.08);
	animation:nvSlideDown .35s ease;
}
@keyframes nvSlideDown { from { transform:translateY(-100%); } to { transform:translateY(0); } }
body.nv-sticky-header .nv-header-spacer { display:block; }

/* Back to top */
.nv-back-to-top {
	position:fixed; bottom:24px; right:24px; z-index:900;
	width:46px; height:46px; border-radius:50%;
	opacity:0; visibility:hidden; transition:opacity .25s ease, transform .25s ease;
}
.nv-back-to-top.is-visible { opacity:1; visibility:visible; }
.nv-back-to-top:hover { transform:translateY(-3px); }

/* Reading progress */
.nv-reading-progress { position:fixed; top:0; left:0; right:0; height:4px; z-index:1000; background:transparent; }
.nv-reading-progress span { display:block; height:100%; width:0; background:var(--nv-color-accent,#2563eb); transition:width .1s linear; }

/* Preloader */
.nv-preloader { position:fixed; inset:0; background:var(--nv-color-bg,#fff); z-index:99999; display:flex; align-items:center; justify-content:center; transition:opacity .4s ease; }
.nv-preloader.is-hidden { opacity:0; visibility:hidden; }
.nv-preloader-spinner { width:42px; height:42px; border:4px solid var(--nv-color-border,#e2e8f0); border-top-color:var(--nv-color-accent,#2563eb); border-radius:50%; animation:nvSpin .8s linear infinite; }
@keyframes nvSpin { to { transform:rotate(360deg); } }

/* Breadcrumbs */
.nv-breadcrumbs { margin-bottom:24px; font-size:.88rem; }
.nv-breadcrumbs ol { list-style:none; display:flex; flex-wrap:wrap; gap:8px; margin:0; padding:0; align-items:center; }
.nv-breadcrumbs li:not(:last-child)::after { content:"/"; margin-left:8px; color:var(--nv-color-muted,#94a3b8); }
.nv-breadcrumbs a { color:var(--nv-color-muted,#64748b); }
.nv-breadcrumbs a:hover { color:var(--nv-color-accent,#2563eb); }

/* Author box */
.nv-author-box { display:flex; gap:20px; align-items:flex-start; padding:24px; margin:40px 0; background:var(--nv-card-bg,#f8fafc); border:1px solid var(--nv-color-border,#e2e8f0); border-radius:var(--nv-radius,8px); }
.nv-author-box img { border-radius:50%; }
.nv-author-name { margin:0 0 6px; }
.nv-author-bio { margin:0 0 8px; color:var(--nv-color-muted,#64748b); }

/* Social share */
.nv-social-share { display:flex; align-items:center; gap:10px; margin:28px 0; flex-wrap:wrap; }
.nv-share-label { font-weight:600; }
.nv-social-share a { width:38px; height:38px; display:inline-flex; align-items:center; justify-content:center; border-radius:50%; border:1px solid var(--nv-color-border,#e2e8f0); color:var(--nv-color-heading,#11161f); }
.nv-social-share a:hover { background:var(--nv-color-accent,#2563eb); color:#fff; border-color:transparent; }

/* Newsletter box */
.nv-newsletter-box { padding:28px; margin:40px 0; background:var(--nv-card-bg,#f8fafc); border:1px solid var(--nv-color-border,#e2e8f0); border-radius:var(--nv-radius,8px); text-align:center; }
.nv-newsletter-form { display:flex; gap:10px; max-width:460px; margin:16px auto 0; }
@media (max-width:520px){ .nv-newsletter-form { flex-direction:column; } }

/* Reading time chip */
.nv-reading-time { display:inline-flex; align-items:center; gap:4px; }

/* Announcement bar */
.nv-announcement-bar { background:var(--nv-color-accent,#2563eb); color:#fff; font-size:.9rem; }
.nv-announcement-inner { display:flex; align-items:center; justify-content:center; gap:16px; min-height:42px; position:relative; }
.nv-announcement-bar a { color:#fff; text-decoration:underline; }
.nv-announcement-close { position:absolute; right:0; background:none; box-shadow:none; color:#fff; padding:4px; }
.nv-announcement-close:hover { background:none; transform:none; opacity:.8; }

/* Cookie notice */
.nv-cookie-notice { position:fixed; bottom:20px; left:20px; right:20px; max-width:560px; margin:auto; background:var(--nv-color-heading,#11161f); color:#fff; padding:18px 20px; border-radius:var(--nv-radius,8px); box-shadow:0 12px 40px rgba(0,0,0,.25); z-index:9000; display:none; align-items:center; gap:16px; }
.nv-cookie-notice.is-visible { display:flex; }
.nv-cookie-notice p { margin:0; font-size:.9rem; }

/* Wishlist / quick view buttons */
.nv-wishlist-btn, .nv-quickview-btn { background:none; box-shadow:none; border:1px solid var(--nv-color-border,#e2e8f0); color:var(--nv-color-heading,#11161f); padding:8px 12px; font-size:.85rem; }
.nv-wishlist-btn.is-active { color:#e11d48; border-color:#e11d48; }
.nv-quickview-btn:hover { background:var(--nv-color-accent,#2563eb); color:#fff; }

/* Quick view modal */
.nv-modal { position:fixed; inset:0; z-index:10000; display:none; align-items:center; justify-content:center; padding:20px; }
.nv-modal.is-open { display:flex; }
.nv-modal-backdrop { position:absolute; inset:0; background:rgba(0,0,0,.55); }
.nv-modal-dialog { position:relative; background:var(--nv-color-bg,#fff); border-radius:var(--nv-radius,8px); max-width:860px; width:100%; max-height:90vh; overflow:auto; padding:28px; z-index:1; }
.nv-modal-close { position:absolute; top:14px; right:14px; background:none; box-shadow:none; color:var(--nv-color-heading,#11161f); }
.nv-quickview-content { display:grid; gap:28px; grid-template-columns:1fr; }
@media (min-width:700px){ .nv-quickview-content { grid-template-columns:1fr 1fr; } }

/* Floating cart */
.nv-floating-cart { position:fixed; bottom:24px; left:24px; z-index:900; width:54px; height:54px; border-radius:50%; box-shadow:0 8px 24px rgba(0,0,0,.2); }
.nv-mini-cart-panel { position:fixed; top:0; right:0; bottom:0; width:min(380px,90vw); background:var(--nv-color-bg,#fff); z-index:10001; transform:translateX(100%); transition:transform .3s ease; box-shadow:-10px 0 40px rgba(0,0,0,.15); display:flex; flex-direction:column; }
.nv-mini-cart-panel.is-open { transform:translateX(0); }
.nv-mini-cart-head { display:flex; align-items:center; justify-content:space-between; padding:18px 20px; border-bottom:1px solid var(--nv-color-border,#e2e8f0); }
.nv-mini-cart-head h3 { margin:0; }
.nv-mini-cart-body { padding:20px; overflow-y:auto; flex:1; }

/* Sticky add to cart */
.nv-sticky-atc { position:fixed; bottom:0; left:0; right:0; background:var(--nv-color-bg,#fff); border-top:1px solid var(--nv-color-border,#e2e8f0); box-shadow:0 -4px 20px rgba(0,0,0,.08); z-index:880; transform:translateY(100%); transition:transform .3s ease; }
.nv-sticky-atc.is-visible { transform:translateY(0); }
.nv-sticky-atc-inner { display:flex; align-items:center; gap:16px; padding:12px 20px; }
.nv-sticky-atc-title { font-weight:700; flex:1; }
