/* JakSky V215. Final warm presentation layer, loaded after older styles.
   Product palette: dark cocoa, warm taupe, cream.  No behavior modifications.
   Keep meaningful colors: VIP gold, status green, danger red, custom avatar frames.
*/
:root{
  --jk215-ink:#382a22;
  --jk215-ink-muted:#6d5748;
  --jk215-border:#d7bdab;
  --jk215-surface:#f7ede3;
  --jk215-card:#fff9f2;
  --jk215-alt:#ebdbca;
  --jk215-button:#594236;
  --jk215-button-ink:#fff5e9;
  --jk215-focus:#b98b67;
  --jk-pink:#876957;
  --jk-pink-soft:#b99477;
  --jk-purple:#796153;
}
html[data-jak-theme="dark"] body.jakPageHome,
html[data-theme="dark"] body.jakPageHome,
html:not([data-jak-theme="light"]) body.jakPageHome:not(.light-mode){
  --jk215-ink:#f5e6d6;
  --jk215-ink-muted:#d9bfaa;
  --jk215-border:#8c6d5b;
  --jk215-surface:#3c302a;
  --jk215-card:#4c3c32;
  --jk215-alt:#574438;
  --jk215-button:#ead4bf;
  --jk215-button-ink:#34271f;
  --jk215-focus:#f1cdac;
}
/* Map source theme variables so older CSS using them inherits mocha. */
html[data-jak-theme="dark"]{
  --jak-bg:#2b211d!important;--jak-bg-2:#332822!important;
  --jak-surface:#3c302a!important;--jak-surface-2:#48372e!important;
  --jak-surface-3:#574338!important;
  --jak-ink:#f5e6d6!important;--jak-text:#f5e6d6!important;
  --jak-muted:#dbc1ac!important;
  --jak-line:rgba(220,187,161,.26)!important;
  --jak-line-strong:rgba(220,187,161,.46)!important;
  --jak-blue:#af886c!important;--jak-blue-2:#d3ae8a!important;--jak-blue-dark:#775b4b!important;
  --jt-bg:#2b211d!important;--jt-bg2:#332822!important;
  --jt-surface:#3c302a!important;--jt-surface2:#48372e!important;
  --jt-text:#f5e6d6!important;--jt-text2:#e0cbb7!important;
  --jt-muted:#d0b6a2!important;
  --jt-line:rgba(220,187,161,.25)!important;
  --jt-line2:rgba(220,187,161,.36)!important;
}
/* Comment modal is the most visible remaining legacy-navy surface. */
html:root:root:root:root body.jakPageHome #modal{background:rgba(27,19,15,.80)!important;}
html:root:root:root:root body.jakPageHome #modal .modalBox{
  background:var(--jk215-surface)!important;
  color:var(--jk215-ink)!important;
  border:1px solid var(--jk215-border)!important;
  box-shadow:0 22px 55px rgba(22,13,8,.28)!important;
}
html:root:root:root:root body.jakPageHome #modal .modalBox > :is(h1,h2,h3,h4,#mtitle),
html:root:root:root:root body.jakPageHome #modal .modalBox > :is(p,#mdesc){
  color:var(--jk215-ink)!important;-webkit-text-fill-color:var(--jk215-ink)!important;
}
html:root:root:root:root body.jakPageHome #modal #comments .comment,
html:root:root:root:root body.jakPageHome #modal #comments .replyComment{
  background:var(--jk215-card)!important;
  border:1px solid var(--jk215-border)!important;
  color:var(--jk215-ink)!important;
  box-shadow:0 3px 12px rgba(49,31,19,.08)!important;
}
html:root:root:root:root body.jakPageHome #modal #comments .replyComment{
  background:var(--jk215-alt)!important;
  border-color:var(--jk215-border)!important;
}
html:root:root:root:root body.jakPageHome #modal #comments .comment .commentUserName,
html:root:root:root:root body.jakPageHome #modal #comments .comment > p,
html:root:root:root:root body.jakPageHome #modal #comments .replyComment .replyBodyText,
html:root:root:root:root body.jakPageHome #modal #comments .comment > b{
  color:var(--jk215-ink)!important;
  -webkit-text-fill-color:var(--jk215-ink)!important;
  text-shadow:none!important;opacity:1!important;
}
html:root:root:root:root body.jakPageHome #modal #comments :is(small,.commentMeta,.commentTime,.timestamp),
html:root:root:root:root body.jakPageHome #modal #comments .replyContextLabel{
  color:var(--jk215-ink-muted)!important;
  -webkit-text-fill-color:var(--jk215-ink-muted)!important;
}
html:root:root:root:root body.jakPageHome #modal #comments .replyContext,
html:root:root:root:root body.jakPageHome #modal #comments .replyContextQuote{
  background:rgba(133,99,77,.10)!important;
  border-color:rgba(133,99,77,.23)!important;
  color:var(--jk215-ink)!important;
  -webkit-text-fill-color:var(--jk215-ink)!important;
}
html:root:root:root:root body.jakPageHome #modal #comments .comment > button.jk215-action,
html:root:root:root:root body.jakPageHome #modal #comments .replyComment > button.jk215-action{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;
  min-width:88px!important;min-height:44px!important;
  margin:8px 7px 2px 0!important;padding:10px 14px!important;
  font:700 13px/1.2 system-ui,-apple-system,sans-serif!important;
  border-radius:11px!important;box-shadow:none!important;
  -webkit-text-fill-color:var(--jk215-button-ink)!important;
  color:var(--jk215-button-ink)!important;
  background:var(--jk215-button)!important;
  border:1px solid var(--jk215-border)!important;
  transition:filter .14s ease!important;
}
html:root:root:root:root body.jakPageHome #modal #comments .comment > button.jk215-action.jk215-delete{
  background:transparent!important;
  color:var(--jk215-ink)!important;
  -webkit-text-fill-color:var(--jk215-ink)!important;
  border-color:var(--jk215-border)!important;
}
html:root:root:root:root body.jakPageHome #modal #comments .jk215-action:active{filter:brightness(.91)!important;}
html:root:root:root:root body.jakPageHome #modal #comments .jk215-action:focus-visible{
  outline:3px solid var(--jk215-focus)!important;outline-offset:3px!important;
}
/* Text and actions: avoid legacy cyan/pink buttons or floating icons. */
html:root:root:root:root body.jakPageHome #modal #ctext.commentInput,
html:root:root:root:root body.jakPageHome #modal input.commentInput,
html:root:root:root:root body.jakPageHome #modal textarea.commentInput{
  background:var(--jk215-card)!important;
  color:var(--jk215-ink)!important;
  -webkit-text-fill-color:var(--jk215-ink)!important;
  caret-color:var(--jk215-ink)!important;
  border:1px solid var(--jk215-border)!important;
  box-shadow:none!important;
}
html:root:root:root:root body.jakPageHome #modal #ctext.commentInput::placeholder,
html:root:root:root:root body.jakPageHome #modal input.commentInput::placeholder{
  color:var(--jk215-ink-muted)!important;
  -webkit-text-fill-color:var(--jk215-ink-muted)!important;opacity:1!important;
}
html:root:root:root:root body.jakPageHome #modal .sendBtn,
html:root:root:root:root body.jakPageHome #modal .closeBtn,
html:root:root:root:root body.jakPageHome #modal #tabs button,
html:root:root:root:root body.jakPageHome #modal .btns button,
html:root:root:root:root body.jakPageHome #modal .rate button{
  background:var(--jk215-button)!important;color:var(--jk215-button-ink)!important;
  -webkit-text-fill-color:var(--jk215-button-ink)!important;
  border:1px solid var(--jk215-border)!important;box-shadow:none!important;
  border-radius:12px!important;
}
html:root:root:root:root body.jakPageHome #modal .sendBtn{min-height:48px!important;}
html:root:root:root:root body.jakPageHome #modal .closeBtn{min-width:44px!important;min-height:44px!important;}
html:root:root:root:root body.jakPageHome #modal :is(input,textarea,button):focus-visible{
  outline:3px solid var(--jk215-focus)!important;outline-offset:2px!important;
}
/* Legacy navy global dialogs and helper elements; retain chosen theme mode. */
html:root:root:root:root body.jakPageHome :is(.jakDialogBox,.jakConfirmCard,.publicProfileBox,.profileModal,.jakRedeemCard,.jakMusicCard){
  background:var(--jk215-surface)!important;
  border-color:var(--jk215-border)!important;color:var(--jk215-ink)!important;
}
html:root:root:root:root body.jakPageHome #jakDialogOverlay .jakDialogActions{
  background:var(--jk215-surface)!important;
}
html:root:root:root:root body.jakPageHome :is(.jakDialogBox,.jakConfirmCard) :is(h2,h3,p,small),
html:root:root:root:root body.jakPageHome .publicProfileBox :is(h2,h3,p){
  color:var(--jk215-ink)!important;
  -webkit-text-fill-color:var(--jk215-ink)!important;
}
html:root:root:root:root body.jakPageHome :is(.jakDialogBox,.jakConfirmCard) button:not(.jakDialogCancel):not(.jakConfirmCancel){
  background:var(--jk215-button)!important;color:var(--jk215-button-ink)!important;
  -webkit-text-fill-color:var(--jk215-button-ink)!important;
}
html:root:root:root:root body.jakPageHome #downloadBtn{
  background:#584438!important;color:#fff5e9!important;
  -webkit-text-fill-color:#fff5e9!important;box-shadow:none!important;
}
/* User-selected avatars, badges (VIP gold, verified colors), media and platform logos untouched. */
@media(max-width:480px){
  html:root:root:root:root body.jakPageHome #modal .modalBox{width:min(100%,640px)!important;max-width:100%!important;}
  html:root:root:root:root body.jakPageHome #modal #comments .comment > button.jk215-action{min-height:44px!important;}
}
@media(prefers-reduced-motion:reduce){
 html:root:root:root:root body.jakPageHome #modal .jk215-action{transition:none!important;}
}
/* Small phone safeguards for long usernames and reply quotes. */
html:root:root:root:root body.jakPageHome #modal,
html:root:root:root:root body.jakPageHome #modal .modalBox,
html:root:root:root:root body.jakPageHome #modal #comments .comment{
  box-sizing:border-box!important;
  min-width:0!important;
}
html:root:root:root:root body.jakPageHome #modal{
  max-width:100vw!important;overflow-x:hidden!important;
}
html:root:root:root:root body.jakPageHome #modal .modalBox{
  max-width:min(640px,calc(100vw - 24px))!important;
  overflow-wrap:anywhere!important;
}
/* Warm dark page backdrop in the legacy navy appearance mode. */
html:root:root:root:root[data-jak-theme="dark"] body.jakPageHome{
  background:linear-gradient(180deg,#47382f 0%,#302520 100%)!important;
  color:#f5e6d6!important;
}
/* Guard against decorative pseudo icons from historical button rules. */
html:root:root:root:root body.jakPageHome #modal .jk215-action::before,
html:root:root:root:root body.jakPageHome #modal .jk215-action::after{
  content:none!important;display:none!important;
}
