/* ============================================================
   site.css — KandyNu CMS shared stylesheet
   Link from every public page:
   <link rel="stylesheet" href="/css/site.css">
   ============================================================ */

/* ── CSS CUSTOM PROPERTIES (theme variables) ── */
:root {
  --accent:           #6dcea0;
  --accent-hover:     #7cddaf;
  --accent-dim:       rgba(109,206,160,0.2);
  --accent-faint:     rgba(109,206,160,0.07);
  --accent-rgb:       109,206,160;

  --bg:               #080e0a;
  --bg-dark:          #050a07;
  --bg-card:          rgba(109,206,160,0.04);
  --bg-input:         rgba(255,255,255,0.04);

  --bg-image:         none;

  --bg-overlay:       transparent;

  --border:           rgba(255,255,255,0.07);
  --border-input:     rgba(255,255,255,0.09);

  --text:             #ffffff;
  --text-muted:       rgba(255,255,255,0.35);
  --text-faint:       rgba(255,255,255,0.2);
  --text-dim:         rgba(255,255,255,0.55);

  --font-serif:       'Source Serif 4', Georgia, serif;
  --font-sans:        'IBM Plex Sans', system-ui, sans-serif;

  --radius-sm:        3px;
  --radius:           6px;
  --radius-lg:        10px;
  --radius-pill:      100px;
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

/* ── BASE ── */
html, body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  min-height: 100%;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
body {
  background-image: none;
  background-color: transparent;
}
/* video background — injected by nav-loader when bgVideo is set in site settings */
.site-bg-video {
  position: fixed !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  z-index: -1 !important;
  pointer-events: none !important;
}
body::before {
  content: '';
  position: fixed; inset: 0;
  background: var(--bg-overlay, radial-gradient(ellipse at 65% 25%, rgba(var(--accent-rgb),0.05) 0%, transparent 65%));
  pointer-events: none;
  z-index: 0;
}

/* ── HEADER (injected by nav-loader.js) ── */
/* nav-loader.js renders its own scoped styles — nothing needed here */

/* ── PAGE WRAPPER ── */
.page {
  position: relative;
  z-index: 1;
  max-width: 760px;
  margin: 0 auto;
  padding: 64px 24px 100px;
}
.page-wide {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  margin: 0 auto;
  padding: 52px 48px 80px;
}

/* ── EYEBROW / SECTION LABEL ── */
.eyebrow {
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.eyebrow::before {
  content: '';
  display: block;
  width: 20px; height: 1px;
  background: rgba(var(--accent-rgb),0.4);
  flex-shrink: 0;
}

/* ── PAGE TITLE ── */
.page-title {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  line-height: 1.05;
  margin-bottom: 12px;
  color: var(--text);
}
.page-title em { font-style: italic; color: var(--accent); }

.page-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 300;
  line-height: 1.7;
  margin-bottom: 52px;
  max-width: 480px;
}

/* ── BUTTONS ── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.65rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  background: var(--accent);
  color: #1a0f18;
  border: none;
  padding: 13px 28px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, transform 0.15s;
}
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.65rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  background: none;
  color: var(--text-muted);
  border: 1px solid var(--border);
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.btn-ghost:hover { color: var(--accent); border-color: var(--accent-dim); }

/* ── LIKE BUTTON ── */
.like-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 10px 20px;
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.like-btn:hover { color: var(--accent); border-color: var(--accent-dim); }
.like-btn.liked { color: var(--accent); border-color: rgba(var(--accent-rgb),0.4); background: var(--accent-faint); }
.like-btn svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: fill 0.2s; }
.like-btn.liked svg { fill: var(--accent); }
.like-count { font-size: 0.72rem; color: var(--text-faint); letter-spacing: 1px; }

/* copy link button */
.copy-url-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 10px 20px;
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.2s, border-color 0.2s;
  margin-left: auto;
}
.copy-url-btn:hover { color: var(--accent); border-color: var(--accent-dim); }
.copy-url-btn.copied { color: #90ee90; border-color: rgba(144,238,144,0.35); }
.copy-url-btn svg { width: 13px; height: 13px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ── FORM INPUTS ── */
.form-input,
.form-textarea,
input[type="text"].site-input,
textarea.site-input {
  background: var(--bg-input);
  border: 1px solid var(--border-input);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 300;
  padding: 11px 14px;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
  width: 100%;
}
.form-input::placeholder,
.form-textarea::placeholder { color: rgba(255,255,255,0.18); }
.form-input:focus,
.form-textarea:focus { border-color: rgba(var(--accent-rgb),0.35); background: rgba(255,255,255,0.06); }
.form-textarea { min-height: 110px; resize: vertical; line-height: 1.7; }
.form-label {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.28);
}

/* ── TAGS / PILLS ── */
.tag-pill, .post-tag {
  display: inline-flex;
  align-items: center;
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  color: rgba(var(--accent-rgb),0.6);
  border: 1px solid rgba(var(--accent-rgb),0.18);
  background: rgba(var(--accent-rgb),0.05);
  text-decoration: none;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
}
.tag-pill:hover,
.post-tag:hover { color: var(--accent); border-color: rgba(var(--accent-rgb),0.4); }
.tag-pill.active,
.post-tag.active { color: #1a0f18; background: var(--accent); border-color: var(--accent); }

/* ── COMMENT FORM ── */
.comment-form { margin-bottom: 48px; display: flex; flex-direction: column; gap: 12px; }
.comment-form input,
.comment-form textarea {
  background: var(--bg-input);
  border: 1px solid var(--border-input);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 300;
  padding: 12px 16px;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
  width: 100%;
}
.comment-form input::placeholder,
.comment-form textarea::placeholder { color: rgba(255,255,255,0.2); }
.comment-form input:focus,
.comment-form textarea:focus { border-color: rgba(var(--accent-rgb),0.35); background: rgba(255,255,255,0.06); }
.comment-form textarea { min-height: 100px; resize: vertical; line-height: 1.7; }
.comment-submit {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  align-self: flex-start;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.65rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  background: var(--accent);
  color: #1a0f18;
  border: none;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}
.comment-submit:hover { background: var(--accent-hover); transform: translateY(-1px); }
.comment-submit:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.comment-confirm { font-size: 0.72rem; color: var(--accent); font-style: italic; font-family: var(--font-serif); display: none; }
.comment-confirm.show { display: block; }

/* comment cards */
.comments-list { display: flex; flex-direction: column; gap: 20px; }
.comment-card {
  padding: 20px 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  animation: fadeUp 0.4s ease both;
}
.comment-meta { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.comment-name { font-size: 0.72rem; font-weight: 600; color: var(--accent); letter-spacing: 1px; }
.comment-date { font-size: 0.6rem; color: var(--text-faint); }
.comment-text { font-size: 0.88rem; color: var(--text-dim); line-height: 1.8; font-weight: 300; }
.no-comments { font-size: 0.82rem; color: var(--text-faint); font-style: italic; font-family: var(--font-serif); }

/* ── COMMENTS SECTION HEADING ── */
.comments-heading {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: 1.6rem;
  color: var(--text);
  margin-bottom: 32px;
}
.comments-heading em { font-style: italic; color: var(--accent); }

/* ── SKELETON / LOADING ── */
.skel {
  background: linear-gradient(90deg, rgba(255,255,255,0.04) 25%, rgba(255,255,255,0.08) 50%, rgba(255,255,255,0.04) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  border-radius: var(--radius-sm);
}
@keyframes shimmer {
  from { background-position: 200% 0; }
  to   { background-position: -200% 0; }
}


.site-footer a { color: rgba(255,255,255,0.2); text-decoration: none; transition: color 0.2s; }
.site-footer a:hover { color: var(--accent); }
.footer-links { display: flex; gap: 20px; }

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #3a2a40; border-radius: 10px; }

/* ── MOBILE ── */
@media (max-width: 768px) {
  .page { padding: 40px 20px 60px; }
  .page-wide { padding: 36px 20px 60px; }
  .site-footer { padding: 24px 20px; flex-direction: column; gap: 12px; }
}




.kn-footer { width: 100%; }

/* ── FOOTER ── */
#site-footer { position: relative; z-index: 1; }
