/* Joe's ArtLab 返回連結（共用）
   用法：<link rel="stylesheet" href="../css/joelogo.css">
   <div class="title-block"><a class="joelogo-button" href="../index.html">Joe's ArtLab</a><span class="title">頁面名稱</span></div>
   顏色優先沿用頁面變數：--ink / --paper / --accent / --mute，
   其次沿用 --fg / --bg / --acc / --mut；都沒有時依淺色／深色模式使用預設值。 */

.title-block{
  --jl-ink:var(--ink,var(--fg,#0b0b0b));
  --jl-paper:var(--paper,var(--bg,#f2ecd8));
  --jl-accent:var(--accent,var(--acc,#5c2330));
  --jl-mute:var(--mute,var(--mut,#6b6558));
  max-width:1180px; margin:0 auto; padding:6px 24px 8px;
  display:flex; align-items:center; gap:14px;
}
@media (prefers-color-scheme:dark){
  .title-block{
    --jl-ink:var(--ink,var(--fg,#ece6d8));
    --jl-paper:var(--paper,var(--bg,#15171a));
    --jl-accent:var(--accent,var(--acc,#e8805f));
    --jl-mute:var(--mute,var(--mut,#9a978d));
  }
}
.joelogo-button{
  display:inline-flex; align-items:center; gap:12px; min-height:44px;
  font-size:15px; font-weight:600; letter-spacing:.22em; line-height:1;
  margin-right:-.22em; /* 抵銷最後一字的字距，讓標題間距一致 */
  color:var(--jl-ink); text-decoration:none; touch-action:manipulation;
  transition:color .2s ease-out;
}
.joelogo-button::before{
  content:""; width:14px; height:14px; flex:none;
  background:var(--jl-accent); border:2px solid var(--jl-accent);
  box-shadow:inset 0 0 0 2px var(--jl-paper);
  transition:transform .3s ease-out;
}
.joelogo-button:hover{color:var(--jl-accent)}
.joelogo-button:hover::before{transform:rotate(45deg)}
.joelogo-button:focus-visible{outline:2px solid var(--jl-ink); outline-offset:4px}

.title{
  display:inline-flex; align-items:center; min-height:44px;
  font-size:15px; font-weight:400; letter-spacing:.14em; line-height:1;
  color:var(--jl-mute); white-space:nowrap;
}

@media (max-width:860px){
  .title-block{padding:2px 14px 4px; gap:10px; background-position:14px 100%; background-size:calc(100% - 28px) 1px}
  .joelogo-button,.title{font-size:14px}
}
@media (prefers-reduced-motion:reduce){
  .joelogo-button,.joelogo-button::before{transition:none}
}
