/* Kantumruy Pro — self-hosted (SIL Open Font License, see assets/fonts/OFL-LICENSE.txt) */
@font-face{font-family:'Kantumruy Pro';font-style:normal;font-display:swap;font-weight:400;src:url(../fonts/kantumruy-pro-khmer-400-normal.woff2) format('woff2');unicode-range:U+1780-17FF,U+19E0-19FF,U+200C-200D,U+25CC}
@font-face{font-family:'Kantumruy Pro';font-style:normal;font-display:swap;font-weight:500;src:url(../fonts/kantumruy-pro-khmer-500-normal.woff2) format('woff2');unicode-range:U+1780-17FF,U+19E0-19FF,U+200C-200D,U+25CC}
@font-face{font-family:'Kantumruy Pro';font-style:normal;font-display:swap;font-weight:600;src:url(../fonts/kantumruy-pro-khmer-600-normal.woff2) format('woff2');unicode-range:U+1780-17FF,U+19E0-19FF,U+200C-200D,U+25CC}
@font-face{font-family:'Kantumruy Pro';font-style:normal;font-display:swap;font-weight:700;src:url(../fonts/kantumruy-pro-khmer-700-normal.woff2) format('woff2');unicode-range:U+1780-17FF,U+19E0-19FF,U+200C-200D,U+25CC}
@font-face{font-family:'Kantumruy Pro';font-style:normal;font-display:swap;font-weight:400;src:url(../fonts/kantumruy-pro-latin-400-normal.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'Kantumruy Pro';font-style:normal;font-display:swap;font-weight:500;src:url(../fonts/kantumruy-pro-latin-500-normal.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'Kantumruy Pro';font-style:normal;font-display:swap;font-weight:600;src:url(../fonts/kantumruy-pro-latin-600-normal.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'Kantumruy Pro';font-style:normal;font-display:swap;font-weight:700;src:url(../fonts/kantumruy-pro-latin-700-normal.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}

/* ==================================================================
   KhmerForJesus — "Adventure" theme
   Day trail (light) · Night camp (dark)
   ================================================================== */

:root {
  --font: "Kantumruy Pro", "Noto Sans Khmer", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-chord: "Kantumruy Pro", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --bg: #F4ECDC;
  --bg-2: #EADFC8;
  --surface: #FFFBF3;
  --surface-2: #F7EFE0;
  --surface-3: #EFE3CC;
  --ink: #2A2017;
  --ink-2: #5C4C3C;
  --ink-3: #8A7963;
  --line: #E0D2B8;
  --line-2: #CDBB9B;

  --forest: #1F4D3B;
  --forest-2: #2D6A4F;
  --forest-ink: #F3EAD3;
  --moss: #6B8F4E;
  --sunset: #D9602A;
  --sunset-2: #EE8A3A;
  --sunset-ink: #FFFFFF;
  --gold: #E3A535;
  --gold-ink: #3A2A0A;
  --river: #1F7586;
  --berry: #B5473A;
  --chord: #C2501C;

  --header-bg: #163A2D;
  --header-ink: #F1E7CF;
  --header-ink-2: #BFD1BF;

  --success-bg: #E2F0DC; --success-ink: #2C5E2E;
  --error-bg: #F8E0D8;   --error-ink: #8E2F1F;
  --info-bg: #DDEEF0;    --info-ink: #1C5966;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(42,32,23,.06), 0 6px 18px rgba(42,32,23,.07);
  --shadow-lg: 0 10px 40px rgba(42,32,23,.18);
  --topo: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240' viewBox='0 0 240 240'%3E%3Cg fill='none' stroke='%237a6545' stroke-opacity='.10' stroke-width='1.2'%3E%3Cpath d='M-20 60c40-30 80 20 120-5s70-40 110-10 60 25 60 25'/%3E%3Cpath d='M-20 80c40-30 80 20 120-5s70-40 110-10 60 25 60 25'/%3E%3Cpath d='M-20 140c50-20 70 30 120 10s60-50 110-20 50 20 50 20'/%3E%3Cpath d='M-20 160c50-20 70 30 120 10s60-50 110-20 50 20 50 20'/%3E%3Cellipse cx='170' cy='205' rx='38' ry='18'/%3E%3Cellipse cx='170' cy='205' rx='22' ry='9'/%3E%3Cellipse cx='60' cy='25' rx='30' ry='12'/%3E%3C/g%3E%3C/svg%3E");
  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #0D1915;
  --bg-2: #11211B;
  --surface: #15261F;
  --surface-2: #1A2F26;
  --surface-3: #21392E;
  --ink: #EEE6D4;
  --ink-2: #BDB29C;
  --ink-3: #8D8471;
  --line: #24392F;
  --line-2: #33503F;
  --forest: #7CC39A;
  --forest-2: #5FAE82;
  --forest-ink: #0D1915;
  --moss: #9CC27A;
  --sunset: #FF8A3D;
  --sunset-2: #FFA35F;
  --sunset-ink: #1A0E05;
  --gold: #F2C14E;
  --river: #62BCCB;
  --berry: #F07A6A;
  --chord: #FF9C57;
  --header-bg: #08130F;
  --header-ink: #EEE6D4;
  --header-ink-2: #9FB8A8;
  --success-bg: #183626; --success-ink: #A9DDB7;
  --error-bg: #3A1D17;   --error-ink: #F4B1A3;
  --info-bg: #13313A;    --info-ink: #A6DCE6;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 18px rgba(0,0,0,.25);
  --shadow-lg: 0 10px 40px rgba(0,0,0,.5);
  --topo: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240' viewBox='0 0 240 240'%3E%3Cg fill='none' stroke='%239fd1b5' stroke-opacity='.06' stroke-width='1.2'%3E%3Cpath d='M-20 60c40-30 80 20 120-5s70-40 110-10 60 25 60 25'/%3E%3Cpath d='M-20 80c40-30 80 20 120-5s70-40 110-10 60 25 60 25'/%3E%3Cpath d='M-20 140c50-20 70 30 120 10s60-50 110-20 50 20 50 20'/%3E%3Cpath d='M-20 160c50-20 70 30 120 10s60-50 110-20 50 20 50 20'/%3E%3Cellipse cx='170' cy='205' rx='38' ry='18'/%3E%3Cellipse cx='170' cy='205' rx='22' ry='9'/%3E%3Cellipse cx='60' cy='25' rx='30' ry='12'/%3E%3C/g%3E%3C/svg%3E");
  color-scheme: dark;
}

/* ---------- Base (only inside .kfj blocks, so your theme stays in charge elsewhere) ---------- */
.kfj { font-family: var(--font); color: var(--ink); line-height: 1.6; font-size: 16px; -webkit-text-size-adjust: 100%; }
.kfj *, .kfj *::before, .kfj *::after { box-sizing: border-box; }
.kfj a { color: var(--river); text-decoration: none; }
.kfj a:hover { text-decoration: underline; text-underline-offset: 3px; }
.kfj h1, .kfj h2, .kfj h3, .kfj h4 { font-family: var(--font); line-height: 1.3; margin: 0 0 .5em; font-weight: 700; color: var(--ink); letter-spacing: 0; text-transform: none; }
.kfj h1 { font-size: clamp(1.6rem, 3.5vw, 2.3rem); }
.kfj h2 { font-size: 1.35rem; }
.kfj h3 { font-size: 1.1rem; }
.kfj p { margin: 0 0 1em; }
.kfj img { max-width: 100%; display: block; height: auto; }
.kfj button, .kfj input, .kfj select, .kfj textarea { font: inherit; letter-spacing: normal; text-transform: none; }
.kfj ul, .kfj ol { margin-top: 0; }
.kfj hr { border: 0; border-top: 1px dashed var(--line-2); margin: 1.5rem 0; }
.kfj :focus-visible { outline: 3px solid var(--sunset-2); outline-offset: 2px; border-radius: 6px; }
.kfj table { margin: 0; border: 0; }
.kfj-page { padding: 28px 0 56px; }

.kfj-sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.kfj-hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }
.kfj-ic { width: 1.15em; height: 1.15em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; vertical-align: -0.18em; }
.kfj-muted { color: var(--ink-3); }
.kfj-small { font-size: .875rem; }
.kfj-nowrap { white-space: nowrap; }
.kfj-center { text-align: center; }
.kfj-mt-0 { margin-top: 0 }
.kfj-mt-1 { margin-top: .5rem }
.kfj-mt-2 { margin-top: 1rem }
.kfj-mt-3 { margin-top: 1.5rem }
.kfj-mt-4 { margin-top: 2.5rem }
.kfj-mb-0 { margin-bottom: 0 }
.kfj-mb-1 { margin-bottom: .5rem }
.kfj-mb-2 { margin-bottom: 1rem }
.kfj-mb-3 { margin-bottom: 1.5rem }
.kfj-container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.kfj-container-narrow { max-width: 760px; }
.kfj-page { padding: 28px 0 56px; }

/* ---------- Buttons & forms ---------- */
.kfj-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 18px; border-radius: 999px; border: 1.5px solid transparent; cursor: pointer;
  font-weight: 600; font-size: .95rem; line-height: 1.2; text-decoration: none !important; transition: background .15s, transform .1s, box-shadow .15s;
  background: var(--surface-2); color: var(--ink);
}
.kfj-btn:active { transform: translateY(1px); }
.kfj-btn-primary { background: var(--sunset); color: var(--sunset-ink); box-shadow: 0 2px 0 rgba(0,0,0,.12); }
.kfj-btn-primary:hover { background: var(--sunset-2); }
.kfj-btn-forest { background: var(--forest); color: var(--forest-ink); }
.kfj-btn-forest:hover { background: var(--forest-2); }
.kfj-btn-outline { background: transparent; border-color: var(--line-2); color: var(--ink); }
.kfj-btn-outline:hover { background: var(--surface-2); }
.kfj-btn-ghost { background: transparent; color: var(--ink-2); }
.kfj-btn-ghost:hover { background: var(--surface-2); }
.kfj-btn-gold { background: var(--gold); color: var(--gold-ink); }
.kfj-btn-danger { background: var(--berry); color: #fff; }
.kfj-btn-sm { padding: 6px 12px; font-size: .85rem; }
.kfj-btn-lg { padding: 14px 24px; font-size: 1.05rem; }
.kfj-btn-block { width: 100%; }
.kfj-btn[disabled] { opacity: .55; cursor: not-allowed; }

.kfj-field { margin-bottom: 16px; }
.kfj-field label, .kfj-label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 6px; }
.kfj-field .kfj-hint { font-size: .82rem; color: var(--ink-3); margin-top: 5px; }
.kfj-input, .kfj-select, .kfj-textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink);
  background: var(--surface); border: 1.5px solid var(--line-2); border-radius: 10px; padding: 10px 13px;
  transition: border-color .15s, box-shadow .15s;
}
.kfj-input:focus, .kfj-select:focus, .kfj-textarea:focus { outline: none; border-color: var(--forest-2); box-shadow: 0 0 0 4px color-mix(in srgb, var(--forest-2) 18%, transparent); }
.kfj-textarea { min-height: 120px; resize: vertical; line-height: 1.55; }
.kfj-textarea.code { font-family: var(--font-chord); font-size: .95rem; min-height: 360px; }
.kfj-select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%238A7963' stroke-width='2'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 34px; }
.kfj-row { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.kfj-check { display: flex; align-items: center; gap: 9px; cursor: pointer; font-weight: 500; }
.kfj-check input { width: 18px; height: 18px; accent-color: var(--sunset); }
.kfj-form-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.kfj-form-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-top: 8px; }
.kfj-required::after { content: " *"; color: var(--sunset); }

/* ---------- Alerts / flash ---------- */
.kfj-alert { padding: 12px 16px; border-radius: 12px; margin-bottom: 14px; display: flex; gap: 10px; align-items: flex-start; font-weight: 500; }
.kfj-alert-success { background: var(--success-bg); color: var(--success-ink); }
.kfj-alert-error { background: var(--error-bg); color: var(--error-ink); }
.kfj-alert-info { background: var(--info-bg); color: var(--info-ink); }
.kfj-flash-wrap { position: fixed; top: 76px; right: 16px; z-index: 120; display: flex; flex-direction: column; gap: 8px; max-width: min(420px, calc(100vw - 32px)); }
.kfj-flash-wrap .kfj-alert { box-shadow: var(--shadow-lg); animation: pop .2s ease-out; }
.kfj-toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px); background: var(--header-bg); color: var(--header-ink); padding: 11px 18px; border-radius: 999px; box-shadow: var(--shadow-lg); z-index: 200; opacity: 0; transition: .25s; pointer-events: none; font-weight: 500; }
.kfj-toast.is-show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- Chips, badges ---------- */
.kfj-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); font-size: .82rem; font-weight: 600; color: var(--ink-2); white-space: nowrap; }
.kfj-chip .kfj-ic { color: var(--sunset); }
.kfj-chip-key { background: color-mix(in srgb, var(--forest-2) 14%, var(--surface)); border-color: color-mix(in srgb, var(--forest-2) 30%, transparent); color: var(--forest); }
.kfj-pro-badge {
  display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 6px;
  background: var(--gold); color: var(--gold-ink); font-size: .7rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  transform: rotate(-2deg); box-shadow: 0 1px 0 rgba(0,0,0,.15);
}
.kfj-status { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .78rem; font-weight: 700; }
.kfj-status-pending { background: color-mix(in srgb, var(--gold) 25%, var(--surface)); color: #8a5a00; }
.kfj-status-published, .kfj-status-approved, .kfj-status-done, .kfj-status-active, .kfj-status-visible { background: var(--success-bg); color: var(--success-ink); }
.kfj-status-rejected, .kfj-status-banned, .kfj-status-hidden { background: var(--error-bg); color: var(--error-ink); }
.kfj-status-open { background: var(--info-bg); color: var(--info-ink); }
:root[data-theme="dark"] .kfj-status-pending { color: var(--gold); }

/* ---------- Section heading (trail marker) ---------- */
.kfj-section { margin: 40px 0; }
.kfj-sec-head { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.kfj-sec-head h2 { margin: 0; font-size: 1.25rem; white-space: nowrap; }
.kfj-sec-head .kfj-trail { flex: 1; height: 0; border-top: 2px dashed var(--line-2); min-width: 20px; }
.kfj-sec-head .kfj-more { font-weight: 600; font-size: .9rem; display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; color: var(--sunset); }
.kfj-marker {
  width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0;
  background: var(--forest); color: var(--forest-ink); transform: rotate(-4deg); box-shadow: 0 3px 0 rgba(0,0,0,.12);
}
.kfj-marker .kfj-ic { width: 20px; height: 20px; transform: rotate(4deg); }
.kfj-marker.m-sunset { background: var(--sunset); color: #fff; }
.kfj-marker.m-gold { background: var(--gold); color: var(--gold-ink); }
.kfj-marker.m-river { background: var(--river); color: #fff; }
.kfj-marker.m-berry { background: var(--berry); color: #fff; }
:root[data-theme="dark"] .kfj-marker.m-sunset, :root[data-theme="dark"] .kfj-marker.m-river, :root[data-theme="dark"] .kfj-marker.m-berry { color: #0D1915; }

/* ---------- Cards ---------- */
.kfj-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.kfj-card-pad { padding: 20px; }
.kfj-card-head { display: flex; align-items: center; gap: 10px; padding: 16px 18px; border-bottom: 1px dashed var(--line); }
.kfj-card-head h3 { margin: 0; font-size: 1.05rem; }
.kfj-card-head .kfj-more { margin-left: auto; font-size: .85rem; font-weight: 600; color: var(--sunset); }

.kfj-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.kfj-grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.kfj-grid-auto { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }

/* ---------- Song list ---------- */
.kfj-song-list { list-style: none; margin: 0; padding: 0; }
.kfj-song-item { display: flex; align-items: center; gap: 12px; padding: 11px 16px; border-bottom: 1px solid var(--line); position: relative; }
.kfj-song-item:last-child { border-bottom: 0; }
.kfj-song-item:hover { background: var(--surface-2); }
.kfj-song-item .kfj-num {
  width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; flex-shrink: 0;
  background: var(--surface-3); color: var(--ink-2); font-weight: 700; font-size: .85rem;
}
.kfj-song-item .kfj-num.r1 { background: var(--gold); color: var(--gold-ink); }
.kfj-song-item .kfj-num.r2 { background: #C9CDD2; color: #2c3136; }
.kfj-song-item .kfj-num.r3 { background: #D29660; color: #3b1f08; }
.kfj-song-item .kfj-num .kfj-ic { width: 16px; height: 16px; }
.kfj-song-main { flex: 1; min-width: 0; }
.kfj-song-title { display: block; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-decoration: none !important; }
.kfj-song-title::after { content: ""; position: absolute; inset: 0; }
.kfj-song-title:hover { color: var(--sunset); }
.kfj-song-sub { font-size: .84rem; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kfj-song-meta { display: flex; align-items: center; gap: 8px; flex-shrink: 0; color: var(--ink-3); font-size: .8rem; }
.kfj-song-meta .kfj-ic { width: 16px; height: 16px; }
.kfj-song-flags { display: flex; gap: 5px; color: var(--moss); }
.kfj-song-key { font-weight: 700; color: var(--forest); background: var(--surface-2); border: 1px solid var(--line); border-radius: 7px; padding: 1px 7px; font-size: .78rem; }

/* ---------- Artists ---------- */
.kfj-artist-row { display: flex; gap: 18px; overflow-x: auto; padding: 4px 2px 14px; scroll-snap-type: x mandatory; scrollbar-width: thin; }
.kfj-artist-chip { flex: 0 0 auto; width: 118px; text-align: center; scroll-snap-align: start; color: var(--ink); text-decoration: none !important; }
.kfj-artist-chip:hover .kfj-artist-photo { transform: translateY(-3px) rotate(-2deg); }
.kfj-artist-photo {
  width: 96px; height: 96px; border-radius: 50%; margin: 0 auto 8px; overflow: hidden; display: grid; place-items: center;
  font-size: 2rem; font-weight: 700; color: #fff; border: 4px solid var(--surface); box-shadow: 0 0 0 2px var(--line-2), var(--shadow); transition: transform .2s;
}
.kfj-artist-photo img { width: 100%; height: 100%; object-fit: cover; }
.kfj-artist-chip strong { display: block; font-size: .92rem; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.kfj-artist-chip > span:last-child { font-size: .78rem; color: var(--ink-3); }
.kfj-artist-card { display: flex; align-items: center; gap: 14px; padding: 14px; color: var(--ink); text-decoration: none !important; }
.kfj-artist-card:hover { border-color: var(--sunset); }
.kfj-artist-card .kfj-artist-photo { width: 58px; height: 58px; margin: 0; font-size: 1.3rem; border-width: 3px; }
.kfj-artist-card strong { display: block; line-height: 1.3; }

/* ---------- Filters bar ---------- */
.kfj-page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.kfj-page-head h1 { margin: 0; display: flex; align-items: center; gap: 12px; }
.kfj-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.kfj-tab {
  padding: 8px 15px; border-radius: 999px; background: var(--surface); border: 1.5px solid var(--line); color: var(--ink-2);
  font-weight: 600; font-size: .9rem; text-decoration: none !important; display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
}
.kfj-tab:hover { border-color: var(--line-2); color: var(--ink); }
.kfj-tab.is-active { background: var(--forest); border-color: var(--forest); color: var(--forest-ink); }
.kfj-toolbar-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.kfj-toolbar-row .kfj-input, .kfj-toolbar-row .kfj-select { width: auto; padding: 8px 12px; }
.kfj-toolbar-row .kfj-grow { flex: 1; min-width: 200px; }
.kfj-alpha { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 8px; }
.kfj-alpha a {
  min-width: 32px; height: 32px; padding: 0 6px; display: grid; place-items: center; border-radius: 8px;
  background: var(--surface); border: 1px solid var(--line); color: var(--ink-2); font-weight: 600; font-size: .88rem; text-decoration: none !important;
}
.kfj-alpha a:hover { border-color: var(--sunset); color: var(--sunset); }
.kfj-alpha a.is-active { background: var(--sunset); border-color: var(--sunset); color: #fff; }
.kfj-alpha-km a { font-size: 1rem; }

.kfj-pager { display: flex; justify-content: center; align-items: center; gap: 6px; margin-top: 22px; flex-wrap: wrap; }
.kfj-pager a, .kfj-pager span {
  min-width: 40px; height: 40px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  border-radius: 10px; background: var(--surface); border: 1px solid var(--line); color: var(--ink); font-weight: 600; text-decoration: none !important;
}
.kfj-pager .is-current { background: var(--forest); color: var(--forest-ink); border-color: var(--forest); }
.kfj-pager .is-disabled { opacity: .45; }

.kfj-empty { text-align: center; padding: 48px 20px; color: var(--ink-3); }
.kfj-empty .kfj-ic { width: 48px; height: 48px; color: var(--line-2); margin-bottom: 10px; }

/* ---------- Media & video cards ---------- */
.kfj-media-card { display: flex; gap: 12px; padding: 14px; color: var(--ink); text-decoration: none !important; position: relative; }
.kfj-media-card:hover { border-color: var(--sunset); }
.kfj-media-ic { width: 46px; height: 54px; border-radius: 8px; display: grid; place-items: center; flex-shrink: 0; background: var(--surface-3); color: var(--sunset); position: relative; }
.kfj-media-ic::after { content: ""; position: absolute; top: 0; right: 0; border-width: 0 10px 10px 0; border-style: solid; border-color: var(--bg) var(--bg) transparent transparent; border-radius: 0 8px 0 0; }
.kfj-media-ic.audio { background: color-mix(in srgb, var(--river) 18%, var(--surface)); color: var(--river); }
.kfj-media-card strong { display: block; line-height: 1.35; }
.kfj-media-card .kfj-pro-badge { position: absolute; top: 10px; right: 10px; }

.kfj-video-card { overflow: hidden; color: var(--ink); text-decoration: none !important; display: block; }
.kfj-video-card:hover .kfj-thumb img { transform: scale(1.04); }
.kfj-thumb { position: relative; aspect-ratio: 16/9; background: #111 center/cover; overflow: hidden; }
.kfj-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.kfj-thumb .kfj-play { position: absolute; inset: 0; margin: auto; width: 54px; height: 54px; border-radius: 50%; background: rgba(217,96,42,.92); display: grid; place-items: center; color: #fff; box-shadow: 0 4px 20px rgba(0,0,0,.4); }
.kfj-thumb .kfj-play .kfj-ic { width: 22px; height: 22px; margin-left: 3px; }
.kfj-thumb .kfj-cat { position: absolute; left: 10px; top: 10px; background: rgba(0,0,0,.6); color: #fff; font-size: .75rem; padding: 3px 9px; border-radius: 999px; font-weight: 600; }
.kfj-video-card .kfj-vc-body { padding: 12px 14px; }
.kfj-video-card strong { display: block; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.kfj-video-embed { position: relative; aspect-ratio: 16/9; border-radius: var(--radius); overflow: hidden; background: #000; box-shadow: var(--shadow); }
.kfj-video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.kfj-yt-lite { position: absolute; inset: 0; cursor: pointer; border: 0; padding: 0; background: #000 center/cover; width: 100%; }
.kfj-yt-lite .kfj-play { position: absolute; inset: 0; margin: auto; width: 64px; height: 64px; border-radius: 50%; background: rgba(217,96,42,.95); display: grid; place-items: center; color: #fff; }

/* ---------- Banners ---------- */
.kfj-pro-banner {
  position: relative; overflow: hidden; border-radius: 20px; padding: 32px; color: #FFF6E6;
  background: radial-gradient(circle at 85% 20%, rgba(242,193,78,.35), transparent 40%), linear-gradient(135deg, #1F4D3B 0%, #163A2D 60%, #0F2A20 100%);
  display: grid; grid-template-columns: 1.3fr 1fr; gap: 24px; align-items: center; box-shadow: var(--shadow);
}
.kfj-pro-banner h2 { font-size: 1.6rem; margin-bottom: 6px; }
.kfj-pro-banner ul { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; }
.kfj-pro-banner li { display: flex; gap: 8px; align-items: center; font-size: .92rem; }
.kfj-pro-banner li .kfj-ic { color: var(--gold); }
.kfj-pro-banner .kfj-mtn { position: absolute; right: -20px; bottom: -10px; width: 320px; opacity: .14; pointer-events: none; }

.kfj-subscribe-box { border-radius: 20px; padding: 28px; background: var(--surface); border: 2px dashed var(--line-2); display: grid; grid-template-columns: 1fr 1.1fr; gap: 20px; align-items: center; }
.kfj-subscribe-form { display: flex; gap: 8px; flex-wrap: wrap; }
.kfj-subscribe-form .kfj-input { flex: 1; min-width: 200px; border-radius: 999px; }

.kfj-install-banner { display: none; align-items: center; gap: 14px; padding: 16px 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); }
.kfj-install-banner.is-show { display: flex; }
.kfj-install-banner .kfj-ic { width: 28px; height: 28px; color: var(--sunset); }

.kfj-ad-slot { margin: 20px 0; padding: 14px 18px; border-radius: var(--radius); border: 1px dashed var(--line-2); background: var(--surface-2); font-size: .92rem; position: relative; }
.kfj-ad-slot .kfj-ad-label { position: absolute; top: -9px; left: 14px; background: var(--bg); padding: 0 6px; font-size: .7rem; color: var(--ink-3); text-transform: uppercase; letter-spacing: .1em; }

/* ---------- Modal ---------- */
.kfj-modal { position: fixed; inset: 0; z-index: 150; display: none; align-items: flex-start; justify-content: center; padding: 6vh 16px 16px; background: rgba(8,15,12,.62); backdrop-filter: blur(3px); overflow-y: auto; }
.kfj-modal.is-open { display: flex; }
.kfj-modal-box { width: 100%; max-width: 560px; background: var(--surface); border-radius: 18px; box-shadow: var(--shadow-lg); animation: pop .18s ease-out; overflow: hidden; }
.kfj-modal-head { display: flex; align-items: center; gap: 10px; padding: 16px 18px; border-bottom: 1px dashed var(--line); }
.kfj-modal-head h3 { margin: 0; flex: 1; }
.kfj-modal-body { padding: 18px; }
.kfj-icon-btn { width: 38px; height: 38px; border-radius: 50%; border: 0; background: var(--surface-2); color: var(--ink); display: inline-grid; place-items: center; cursor: pointer; flex-shrink: 0; }
.kfj-icon-btn:hover { background: var(--surface-3); }

/* Search modal */
.kfj-search-box { max-width: 680px; }
.kfj-search-input-wrap { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.kfj-search-input-wrap .kfj-ic { width: 22px; height: 22px; color: var(--ink-3); }
.kfj-search-input-wrap input { flex: 1; min-width: 0; border: 0; background: none; font: inherit; font-size: 1.15rem; color: var(--ink); outline: none; }
.kfj-search-opts { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; padding: 10px 16px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.kfj-search-opts .kfj-tab { padding: 5px 12px; font-size: .82rem; }
.kfj-seg { display: inline-flex; background: var(--surface); border: 1.5px solid var(--line); border-radius: 999px; padding: 2px; }
.kfj-seg button, .kfj-seg a { border: 0; background: none; padding: 5px 12px; border-radius: 999px; font-size: .82rem; font-weight: 600; color: var(--ink-2); cursor: pointer; text-decoration: none; }
.kfj-seg button.is-active, .kfj-seg a.is-active { background: var(--forest); color: var(--forest-ink); }
.kfj-search-results { max-height: 60vh; overflow-y: auto; }
.kfj-search-results .kfj-sr-group { padding: 8px 16px 4px; font-size: .75rem; font-weight: 700; color: var(--ink-3); text-transform: uppercase; letter-spacing: .08em; }
.kfj-search-results a.sr-item { display: flex; align-items: center; gap: 12px; padding: 10px 16px; color: var(--ink); text-decoration: none; }
.kfj-search-results a.sr-item:hover, .kfj-search-results a.sr-item.is-focus { background: var(--surface-2); }
.kfj-sr-item .kfj-ic { color: var(--sunset); }
.kfj-sr-item small { display: block; color: var(--ink-3); font-size: .82rem; }

/* ---------- Song page ---------- */
.kfj-song-hero { padding: 26px 0 18px; }
.kfj-song-hero .kfj-crumbs { font-size: .85rem; color: var(--ink-3); margin-bottom: 8px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.kfj-song-hero h1 { margin-bottom: 4px; }
.kfj-song-hero .kfj-sub { font-size: 1.05rem; color: var(--ink-2); margin-bottom: 12px; }
.kfj-song-hero .kfj-sub a { font-weight: 600; color: var(--sunset); }
.kfj-song-chips { display: flex; gap: 8px; flex-wrap: wrap; }
/* main column + sidebar; the sidebar drops below by itself when the column is narrow */
.kfj-song-layout { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.kfj-song-layout > :first-child { flex: 999 1 520px; min-width: 0; }
.kfj-song-layout > .kfj-song-side { flex: 1 1 340px; min-width: 0; }
.kfj-song-side { display: flex; flex-direction: column; gap: 18px; position: sticky; top: 84px; }

.kfj-tools {
  position: sticky; top: 67px; z-index: 30; display: flex; gap: 6px; flex-wrap: wrap; align-items: center;
  background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; margin-bottom: 14px; box-shadow: var(--shadow); scrollbar-width: none;
}
.kfj-tools::-webkit-scrollbar { display: none; }
.kfj-tool-group { display: inline-flex; align-items: center; gap: 2px; background: var(--surface-2); border-radius: 11px; padding: 3px; flex-shrink: 0; }
.kfj-tool-group .kfj-tg-label { font-size: .72rem; font-weight: 700; color: var(--ink-3); padding: 0 6px; text-transform: uppercase; letter-spacing: .05em; }
.kfj-tbtn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 5px; min-width: 34px; height: 34px; padding: 0 8px;
  border: 0; border-radius: 8px; background: transparent; color: var(--ink); cursor: pointer; font-weight: 600; font-size: .85rem; white-space: nowrap;
}
.kfj-tbtn:hover { background: var(--surface); }
.kfj-tbtn.is-active { background: var(--forest); color: var(--forest-ink); }
.kfj-tbtn .kfj-ic { width: 18px; height: 18px; }
.kfj-tbtn.is-locked::after {
  content: "★"; position: absolute; top: -3px; right: -3px; width: 15px; height: 15px; border-radius: 50%;
  background: var(--gold); color: var(--gold-ink); font-size: 9px; display: grid; place-items: center; line-height: 15px; text-align: center;
}
.kfj-tool-select { height: 34px; border: 0; border-radius: 8px; background: var(--surface); color: var(--ink); font: inherit; font-weight: 700; font-size: .88rem; padding: 0 8px; cursor: pointer; }
.kfj-tbtn.is-fav { color: var(--berry); }
.kfj-tbtn.is-fav .kfj-ic { fill: currentColor; }

.kfj-sheet-wrap { padding: 22px 24px; position: relative; }
.kfj-sheet-meta { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; padding-bottom: 12px; border-bottom: 1px dashed var(--line); }
.kfj-sheet-meta .kfj-key-now { font-weight: 700; font-size: 1.05rem; }
.kfj-sheet-meta .kfj-key-now b { color: var(--chord); }
.kfj-sheet { --fs: 18px; font-size: var(--fs); line-height: 1.35; }
.kfj-sheet.cols-2 { column-count: 2; column-gap: 36px; column-rule: 1px dashed var(--line); }
.kfj-sheet .sec { break-inside: avoid; margin-bottom: 1.1em; }
.kfj-sheet .sec-label {
  display: inline-block; font-size: .72em; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--forest); background: color-mix(in srgb, var(--forest-2) 12%, transparent); padding: 2px 10px; border-radius: 6px; margin-bottom: .4em;
}
.kfj-sheet .sec.is-chorus { border-left: 3px solid var(--sunset-2); padding-left: 14px; }
.kfj-sheet .ln { display: flex; flex-wrap: wrap; align-items: flex-end; min-height: 1.4em; margin-bottom: .15em; }
.kfj-sheet .sg { display: inline-flex; flex-direction: column; white-space: pre; }
.kfj-sheet .sg .c { font-family: var(--font-chord); font-weight: 700; color: var(--chord); font-size: .88em; line-height: 1.2; min-height: 1.2em; padding-right: .45em; cursor: default; }
.kfj-sheet .sg .c[data-chord] { cursor: pointer; }
.kfj-sheet .sg .c[data-chord]:hover { text-decoration: underline; text-decoration-style: dotted; }
.kfj-sheet .sg .l { line-height: 1.5; }
.kfj-sheet .ln.no-chords .sg .c { display: none; }
.kfj-sheet .ln.chords-only .sg .l { display: none; }
.kfj-sheet .ln.chords-only { display: block; white-space: pre-wrap; font-family: var(--font-chord); color: var(--ink-3); margin: .2em 0 .35em; }
.kfj-sheet .ln.chords-only .c { font-weight: 700; color: var(--chord); padding: 0 .15em; }
.kfj-sheet .ln.chords-only .c[data-chord] { cursor: pointer; }
.kfj-sheet .ln.comment { font-style: italic; color: var(--ink-3); }
.kfj-sheet .tab-block { font-family: ui-monospace, Menlo, monospace; white-space: pre; overflow-x: auto; font-size: .8em; background: var(--surface-2); padding: 10px; border-radius: 8px; }
.kfj-sheet.mode-lyrics .sg .c { display: none; }
.kfj-sheet.mode-lyrics .ln.chords-only { display: none; }
.kfj-sheet.mode-chords .sg .l { display: none; }
.kfj-sheet.mode-chords .ln:not(.chords-only) .sg .c { padding-right: .7em; }
.kfj-sheet.mode-chords .ln.no-chords { display: none; }
.kfj-sheet.mode-chords .ln.lyric-only { display: none; }
.kfj-sheet .rep { color: var(--ink-3); font-size: .8em; font-weight: 600; }

/* Chord diagrams */
.kfj-diagrams { display: none; gap: 10px; overflow-x: auto; padding: 4px 2px 12px; margin-bottom: 10px; border-bottom: 1px dashed var(--line); }
.kfj-diagrams.is-show { display: flex; }
.diagram { flex: 0 0 auto; text-align: center; background: var(--surface-2); border-radius: 10px; padding: 8px 8px 4px; min-width: 92px; }
.diagram b { display: block; font-size: .9rem; color: var(--chord); margin-bottom: 2px; }
.diagram svg { display: block; margin: 0 auto; }
.diagram .na { font-size: .75rem; color: var(--ink-3); padding: 20px 4px; }
.kfj-chord-pop { position: absolute; z-index: 40; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 8px; }

/* Audio player */
.kfj-player { padding: 16px; }
.kfj-player-top { display: flex; align-items: center; gap: 12px; }
.kfj-player-btn { width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--sunset); color: #fff; display: grid; place-items: center; cursor: pointer; flex-shrink: 0; box-shadow: 0 4px 14px color-mix(in srgb, var(--sunset) 45%, transparent); }
.kfj-player-btn .kfj-ic { width: 22px; height: 22px; }
.kfj-player-btn .i-play { margin-left: 3px; }
.kfj-player-info { flex: 1; min-width: 0; }
.kfj-player-info strong { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kfj-player-bar { margin-top: 12px; display: flex; align-items: center; gap: 10px; font-size: .8rem; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.kfj-player-bar input[type=range] { flex: 1; accent-color: var(--sunset); }
.kfj-track-list { list-style: none; padding: 0; margin: 12px 0 0; border-top: 1px dashed var(--line); }
.kfj-track-list li { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: .9rem; }
.kfj-track-list li.is-current { color: var(--sunset); font-weight: 700; }
.kfj-track-list button.track-play { border: 0; background: var(--surface-2); color: inherit; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; cursor: pointer; }

/* Metronome / autoscroll bar */
.kfj-mini-panel { display: none; align-items: center; gap: 10px; padding: 10px 14px; margin-bottom: 14px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); flex-wrap: wrap; }
.kfj-mini-panel.is-show { display: flex; }
.kfj-mini-panel input[type=range] { accent-color: var(--sunset); width: 160px; }
.kfj-beat-dots { display: inline-flex; gap: 5px; }
.kfj-beat-dots i { width: 12px; height: 12px; border-radius: 50%; background: var(--line-2); }
.kfj-beat-dots i.on { background: var(--sunset); }
.kfj-beat-dots i.on.accent { background: var(--berry); transform: scale(1.2); }

/* Comments */
.kfj-comments { margin-top: 24px; }
.kfj-comment { display: flex; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.kfj-comment .kfj-avatar { width: 38px; height: 38px; flex-shrink: 0; }
.kfj-comment-body { flex: 1; min-width: 0; }
.kfj-comment-body .kfj-who { font-weight: 700; font-size: .92rem; }
.kfj-comment-body .kfj-who small { font-weight: 400; color: var(--ink-3); margin-left: 6px; }

/* ---------- Pro page ---------- */
.kfj-plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; max-width: 760px; margin: 0 auto; }
.kfj-plan { padding: 26px; text-align: center; position: relative; }
.kfj-plan.is-best { border: 2px solid var(--gold); }
.kfj-plan .kfj-ribbon { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); background: var(--gold); color: var(--gold-ink); padding: 3px 14px; border-radius: 999px; font-weight: 800; font-size: .78rem; }
.kfj-plan .kfj-price { font-size: 2.6rem; font-weight: 700; color: var(--forest); line-height: 1.1; margin: 10px 0 2px; }
.kfj-plan .kfj-price small { font-size: 1rem; color: var(--ink-3); font-weight: 500; }
.kfj-benefits { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.kfj-benefit { padding: 18px 14px; text-align: center; }
.kfj-benefit .kfj-marker { margin: 0 auto 10px; }
.kfj-benefit strong { display: block; line-height: 1.35; }
.kfj-benefit span { font-size: .82rem; color: var(--ink-3); }
.kfj-qr-box { text-align: center; padding: 20px; }
.kfj-qr-box img { max-width: 260px; margin: 0 auto 12px; border-radius: 12px; border: 6px solid #fff; box-shadow: var(--shadow); }
.kfj-steps { counter-reset: step; list-style: none; padding: 0; margin: 0; }
.kfj-steps li { counter-increment: step; position: relative; padding: 0 0 14px 44px; }
.kfj-steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 30px; height: 30px; border-radius: 50%; background: var(--sunset); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: .9rem; }

/* ---------- Account ---------- */
.kfj-account-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 24px; align-items: start; }
.kfj-side-nav { padding: 8px; position: sticky; top: 84px; }
.kfj-side-nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; color: var(--ink); font-weight: 500; text-decoration: none !important; }
.kfj-side-nav a:hover { background: var(--surface-2); }
.kfj-side-nav a.is-active { background: var(--forest); color: var(--forest-ink); }
.kfj-side-nav a .kfj-ic { color: var(--sunset); }
.kfj-side-nav a.is-active .kfj-ic { color: inherit; }
.kfj-side-nav .kfj-count { margin-left: auto; background: var(--sunset); color: #fff; border-radius: 999px; font-size: .72rem; padding: 1px 8px; font-weight: 700; }

.kfj-table-wrap { overflow-x: auto; }
.kfj-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.kfj-table th { text-align: left; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); padding: 10px 12px; border-bottom: 2px solid var(--line); white-space: nowrap; }
.kfj-table td { padding: 11px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.kfj-table tr:hover td { background: var(--surface-2); }
.kfj-table .kfj-actions { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.kfj-stat { padding: 18px; display: flex; gap: 14px; align-items: center; }
.kfj-stat b { font-size: 1.6rem; display: block; line-height: 1.1; }
.kfj-stat div span { color: var(--ink-3); font-size: .85rem; display: block; }

/* Auth pages */
.kfj-auth-wrap { max-width: 440px; margin: 0 auto; }
.kfj-auth-wrap .kfj-brand-mark { width: 64px; height: 64px; margin: 0 auto 10px; color: var(--forest); }

/* Prose (CMS pages) */
.kfj-prose { font-size: 1.02rem; }
.kfj-prose h2, .kfj-prose h3 { margin-top: 1.4em; }
.kfj-prose blockquote { margin: 1em 0; padding: 10px 16px; border-left: 4px solid var(--sunset); background: var(--surface-2); border-radius: 0 10px 10px 0; }
.kfj-prose ul, .kfj-prose ol { padding-left: 1.4em; }
.kfj-prose code { background: var(--surface-2); padding: 1px 6px; border-radius: 5px; font-size: .9em; }
.kfj-codeblock { background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; font-family: ui-monospace, Menlo, monospace; font-size: .88rem; white-space: pre-wrap; overflow-x: auto; }

/* Editor helpers */
.kfj-editor-bar { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.kfj-editor-split { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.kfj-preview-box { border: 1.5px dashed var(--line-2); border-radius: 10px; padding: 14px; min-height: 360px; max-height: 600px; overflow: auto; background: var(--surface); }

/* Chord library */
.kfj-lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 14px; }
.kfj-lib-grid .diagram { padding: 14px; }

/* ---------- WordPress additions ---------- */
:root { --kfj-sticky-top: 12px; }
.admin-bar { --kfj-admin-bar: 32px; }
.kfj-tools { top: calc(var(--kfj-sticky-top) + var(--kfj-admin-bar, 0px)); }
.kfj-song-side, .kfj-side-nav { top: calc(var(--kfj-sticky-top) + var(--kfj-admin-bar, 0px) + 16px); }
.kfj-flash-wrap { top: calc(var(--kfj-sticky-top) + var(--kfj-admin-bar, 0px) + 8px); }
.kfj-alert[data-autohide] { transition: opacity .4s; }
.kfj-notices { margin-bottom: 14px; }
.kfj-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.kfj-hero-mini { padding: 26px 0 8px; }
.kfj-login-links { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 10px; font-size: .9rem; }
.kfj .kfj-select, .kfj .kfj-input, .kfj .kfj-textarea { max-width: 100%; box-shadow: none; margin: 0; height: auto; min-height: 0; }
.kfj .kfj-select { appearance: none; -webkit-appearance: none; }
.kfj input[type=checkbox], .kfj input[type=radio] { width: 18px; height: 18px; margin: 0; accent-color: var(--sunset); }
.kfj input[type=range] { padding: 0; border: 0; background: none; }
.kfj-modal .kfj-modal-box { color: var(--ink); }
.kfj-page-intro { max-width: 760px; }
.kfj-wp-content > *:first-child { margin-top: 0; }
.kfj-print-title { display: none; }
.kfj-crumbs { font-size: .85rem; color: var(--ink-3); margin-bottom: 8px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.kfj-crumbs .kfj-ic { width: 14px; height: 14px; }
.kfj-search-results a.kfj-sr-item { display: flex; align-items: center; gap: 12px; padding: 10px 16px; color: var(--ink); text-decoration: none; }
.kfj-search-results a.kfj-sr-item:hover, .kfj-search-results a.kfj-sr-item.is-focus { background: var(--surface-2); }
.kfj-track-list .kfj-track-play { border: 0; background: var(--surface-2); color: inherit; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }
.kfj-track-list .kfj-icon-btn { width: 32px; height: 32px; }
.kfj-avatar { width: 34px; height: 34px; border-radius: 50%; display: inline-grid; place-items: center; color: #fff; font-weight: 700; font-size: .9rem; flex-shrink: 0; }
.kfj-avatar.is-pro { box-shadow: 0 0 0 2px var(--gold); }
.kfj-artist-head { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; }
.kfj-artist-head .kfj-artist-photo { width: 130px; height: 130px; font-size: 2.6rem; margin: 0; }
.kfj-inline-marker { display: inline-grid; vertical-align: middle; margin-right: 10px; }
.kfj-radio-seg { display: inline-flex; gap: 4px; flex-wrap: wrap; background: var(--surface-2); border-radius: 999px; padding: 3px; }
.kfj-radio-seg label { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; cursor: pointer; font-weight: 600; font-size: .9rem; }
.kfj-radio-seg label:has(input:checked) { background: var(--forest); color: var(--forest-ink); }
.kfj-radio-seg input { position: absolute; opacity: 0; pointer-events: none; }
.kfj-inline-form { display: inline; margin: 0; }
.kfj details > summary { cursor: pointer; font-weight: 700; }
.kfj-tool-group.is-locked-group { position: relative; }
.kfj-tool-group.is-locked-group::after { content: "★"; position: absolute; top: -3px; right: -3px; width: 15px; height: 15px; border-radius: 50%; background: var(--gold); color: var(--gold-ink); font-size: 9px; display: grid; place-items: center; }

/* Dropdowns */
.kfj-dd { position: relative; display: inline-block; }
.kfj-dd-menu {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 230px; z-index: 60;
  background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); padding: 6px; display: none; text-align: left;
}
.kfj-dd.is-open > .kfj-dd-menu { display: block; animation: kfjpop .14s ease-out; }
.kfj-dd-menu a, .kfj-dd-menu button {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 12px; border-radius: 9px; font-weight: 500;
  color: var(--ink); background: none; border: 0; text-align: left; cursor: pointer; font-size: .95rem; text-decoration: none !important;
}
.kfj-dd-menu a:hover, .kfj-dd-menu button:hover { background: var(--surface-2); }
.kfj-dd-menu .kfj-ic { color: var(--sunset); }
@keyframes kfjpop { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }

/* ---------- Mountain banner (home page) ---------- */
.kfj-hero {
  position: relative; overflow: hidden; color: #fff; border-radius: 0;
  background: linear-gradient(180deg, #F6C77A 0%, #EE9152 38%, #B65A44 62%, #3E4E46 100%);
  min-height: 420px; display: flex; align-items: flex-end;
}
.kfj-hero.is-boxed { border-radius: 22px; margin-bottom: 8px; }
:root[data-theme="dark"] .kfj-hero { background: linear-gradient(180deg, #0B1630 0%, #1B2A4A 40%, #2D3557 60%, #12221C 100%); }
.kfj-hero-art { position: absolute; inset: 0; width: 100%; height: 100%; }
.kfj-hero-content { position: relative; z-index: 2; padding-top: 64px; padding-bottom: 72px; width: 100%; }
.kfj-hero::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(90deg, rgba(40,18,6,.30), rgba(40,18,6,.08) 55%, transparent 75%); }
.kfj-hero::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 120px; background: linear-gradient(180deg, transparent, rgba(10,25,19,.55)); z-index: 1; pointer-events: none; }
.kfj-hero-kicker { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; background: rgba(0,0,0,.22); padding: 6px 14px; border-radius: 999px; backdrop-filter: blur(4px); color: #fff; }
.kfj .kfj-hero h1 { color: #fff; font-size: clamp(2rem, 5.5vw, 3.4rem); margin: 16px 0 8px; text-shadow: 0 2px 20px rgba(0,0,0,.25); max-width: 760px; }
.kfj-hero .kfj-lead { font-size: clamp(1rem, 2vw, 1.2rem); max-width: 620px; opacity: .95; text-shadow: 0 1px 10px rgba(0,0,0,.3); color: #fff; }
.kfj-hero-search { margin-top: 22px; display: flex; align-items: center; gap: 8px; max-width: 620px; background: var(--surface); border-radius: 999px; padding: 6px 6px 6px 18px; box-shadow: 0 10px 30px rgba(0,0,0,.25); }
.kfj-hero-search .kfj-ic { color: var(--ink-3); width: 22px; height: 22px; }
.kfj-hero-search input { flex: 1; min-width: 0; border: 0 !important; background: none !important; font: inherit; font-size: 1.05rem; color: var(--ink); padding: 10px 4px; outline: none; box-shadow: none !important; }
.kfj-hero-stats { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.kfj-hero-stats span { background: rgba(0,0,0,.25); padding: 6px 14px; border-radius: 999px; font-weight: 600; font-size: .9rem; backdrop-filter: blur(4px); color: #fff; }
.kfj-hero.is-center .kfj-hero-content { text-align: center; }
.kfj-hero.is-center h1, .kfj-hero.is-center .kfj-lead { margin-left: auto; margin-right: auto; }
.h-glow-in { stop-color: #FFF1C9; stop-opacity: .85; }
.h-glow-out { stop-color: #FFF1C9; stop-opacity: 0; }
.h-sun { fill: #FFE7A8; }
.h-stars { fill: #fff; opacity: 0; }
.h-birds { stroke: #6B3A26; opacity: .55; }
.h-m1 { fill: #D98A63; opacity: .55; }
.h-m2 { fill: #A6604A; opacity: .75; }
.h-m3 { fill: #3F6B52; }
.h-m4 { fill: #24503D; }
.h-cross rect { fill: #FFF6E3; }
.h-snow { fill: #F4EBD8; opacity: .85; }
.h-trail { stroke: #F4D7A8; opacity: .8; }
.h-trees { fill: #163A2D; }
.h-tent { fill: #D9602A; }
.h-tent-door { fill: #7A2E12; }
.h-fire { fill: #FFB347; }
.h-ground { fill: #163A2D; }
:root[data-theme="dark"] .h-glow-in { stop-color: #9FB6FF; stop-opacity: .25; }
:root[data-theme="dark"] .h-sun { fill: #EDEBDF; }
:root[data-theme="dark"] .h-stars { opacity: .85; }
:root[data-theme="dark"] .h-birds { opacity: 0; }
:root[data-theme="dark"] .h-m1 { fill: #2B3B5E; opacity: .8; }
:root[data-theme="dark"] .h-m2 { fill: #22324B; opacity: .95; }
:root[data-theme="dark"] .h-m3 { fill: #1A2B2A; }
:root[data-theme="dark"] .h-m4 { fill: #12221C; }
:root[data-theme="dark"] .h-trees, :root[data-theme="dark"] .h-ground { fill: #0D1915; }
:root[data-theme="dark"] .h-trail { stroke: #FF8A3D; opacity: .55; }
:root[data-theme="dark"] .h-fire { fill: #FF8A3D; filter: drop-shadow(0 0 8px #FF8A3D); }


/* Links that look like buttons/cards keep their own colours inside any theme's content area */
.kfj a[class] { text-decoration: none; }
.kfj a.kfj-btn { color: var(--ink); }
.kfj a.kfj-btn-primary { color: var(--sunset-ink); }
.kfj a.kfj-btn-forest { color: var(--forest-ink); }
.kfj a.kfj-btn-outline { color: var(--ink); }
.kfj a.kfj-btn-ghost { color: var(--ink-2); }
.kfj a.kfj-btn-gold { color: var(--gold-ink); }
.kfj a.kfj-btn-danger { color: #fff; }
.kfj a.kfj-song-title { color: var(--ink); }
.kfj a.kfj-song-title:hover { color: var(--sunset); }
.kfj a.kfj-artist-chip, .kfj a.kfj-artist-card, .kfj a.kfj-media-card, .kfj a.kfj-video-card, .kfj a.kfj-stat { color: var(--ink); }
.kfj a.kfj-tab { color: var(--ink-2); }
.kfj a.kfj-tab:hover { color: var(--ink); }
.kfj a.kfj-tab.is-active { color: var(--forest-ink); }
.kfj a.kfj-chip { color: var(--ink-2); }
.kfj a.kfj-chip-key { color: var(--forest); }
.kfj .kfj-alpha a { color: var(--ink-2); }
.kfj .kfj-alpha a.is-active { color: #fff; }
.kfj .kfj-pager a { color: var(--ink); }
.kfj .kfj-side-nav a { color: var(--ink); }
.kfj .kfj-side-nav a.is-active { color: var(--forest-ink); }
.kfj .kfj-dd-menu a { color: var(--ink); }
.kfj .kfj-search-results a.kfj-sr-item { color: var(--ink); }
.kfj .kfj-sec-head a.kfj-more, .kfj .kfj-card-head a.kfj-more { color: var(--sunset); }
.kfj a.kfj-icon-btn { color: var(--ink); }
.kfj-cq { container-type: inline-size; }

/* Follow the width of the content column (themes with narrow content areas) */
@container (max-width: 900px) {
  .kfj-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kfj-benefits { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@container (max-width: 780px) {
  .kfj-pro-banner, .kfj-subscribe-box { grid-template-columns: 1fr; }
  .kfj-account-layout { grid-template-columns: 1fr; }
  .kfj-side-nav { position: static; display: flex; overflow-x: auto; gap: 4px; }
  .kfj-side-nav a { white-space: nowrap; }
  .kfj-editor-split { grid-template-columns: 1fr; }
}
@container (max-width: 640px) {
  .kfj-grid-2, .kfj-grid-3 { grid-template-columns: minmax(0, 1fr); }
  .kfj-plans { grid-template-columns: 1fr; }
  .kfj-pro-banner { padding: 24px; }
  .kfj-pro-banner ul { grid-template-columns: 1fr; }
  .kfj-hero { min-height: 0; }
  .kfj-hero-content { padding-top: 34px; padding-bottom: 185px !important; }
  .kfj-hero-art { top: auto; bottom: 0; height: 235px; }
  .kfj-hero::before { background: linear-gradient(180deg, rgba(40,18,6,.35), rgba(40,18,6,.15) 60%, transparent); }
  .kfj-song-meta .kfj-views { display: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .kfj-song-side { position: static; }
  .kfj-benefits { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .kfj-pro-banner { grid-template-columns: 1fr; }
  .kfj-subscribe-box { grid-template-columns: 1fr; }
  .kfj-account-layout { grid-template-columns: 1fr; }
  .kfj-side-nav { position: static; display: flex; overflow-x: auto; gap: 4px; }
  .kfj-side-nav a { white-space: nowrap; }
  .kfj-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kfj-editor-split { grid-template-columns: 1fr; }
}
@media (max-width: 782px) { .admin-bar { --kfj-admin-bar: 46px; } }
@media (max-width: 680px) {
  .kfj-grid-2, .kfj-grid-3 { grid-template-columns: minmax(0, 1fr); }
  .kfj-tools { flex-wrap: nowrap; overflow-x: auto; }
  .kfj-tools .kfj-dd-menu { position: fixed; left: 12px; right: 12px; top: auto; bottom: 12px; min-width: 0; }
  .kfj-plans { grid-template-columns: 1fr; }
  .kfj-benefits { grid-template-columns: 1fr 1fr; }
  .kfj-pro-banner { padding: 24px; }
  .kfj-pro-banner ul { grid-template-columns: 1fr; }
  .kfj-sheet-wrap { padding: 16px; }
  .kfj-sheet { --fs: 16px; }
  .kfj-sheet.cols-2 { column-count: 1; }
  .kfj-song-item { padding: 10px 12px; }
  .kfj-song-meta .kfj-views { display: none; }
  .kfj-form-card { padding: 18px; }
  .kfj-hero { min-height: 0; }
  .kfj-hero-content { padding-top: 34px; padding-bottom: 185px !important; }
  .kfj-hero-art { top: auto; bottom: 0; height: 235px; }
  .kfj-hero::before { background: linear-gradient(180deg, rgba(40,18,6,.35), rgba(40,18,6,.15) 60%, transparent); }
  .kfj-hero.is-boxed { border-radius: 16px; }
  .kfj-artist-head .kfj-artist-photo { width: 96px; height: 96px; font-size: 2rem; }
  .kfj-sec-head h2 { white-space: normal; }
}
@media (max-width: 600px) { .admin-bar { --kfj-admin-bar: 0px; } }

/* ---------- Print: just the chord sheet ---------- */
@media print {
  @page { margin: 14mm; }
  body { background: #fff !important; color: #000; }
  header, footer, #wpadminbar, .site-header, .site-footer, .kfj-tools, .kfj-song-side, .comments-area, #comments, .kfj-flash-wrap,
  .kfj-no-print, .kfj-ad-slot, .kfj-diagrams, .kfj-mini-panel, .kfj-install-banner, .kfj-modal { display: none !important; }
  .kfj-song-layout { display: block; }
  .kfj-card { box-shadow: none; border: 0; }
  .kfj-sheet-wrap { padding: 0; }
  .kfj-sheet .sg .c, .kfj-sheet .ln.chords-only .c { color: #000; }
  .kfj-sheet .sec-label { background: none; color: #000; padding: 0; border-bottom: 1px solid #000; border-radius: 0; }
  .kfj-song-hero { padding-top: 0; }
  .kfj-print-title { display: inline !important; }
  .kfj a { color: #000; }
}
