/* SHARED page style (home) of 久远澪.com and hisame.live - was inline in /var/www/9on0/index.html until 2026-11-13.
   Colours = variables (style.css / this file give 久远澪's; hisame.live overrides them in its theme.css). Edit here, then /opt/site-style/bump-style.sh. */
  /* Link page for 久远澪00 at 久远澪.com (also the root page of 久远澪00.com; was 9on0.driedjellyfish.com
     until 2026-10-18). Shared colours, fonts, corners: /style.css (new site style since 2026-11-11). */
  .wrap { max-width: 520px; margin: 0 auto; padding: 0 16px 48px; }


  /* 更新日志 window (entries from /changelog.json) */
  dialog.log {
    width: min(520px, calc(100% - 32px)); max-height: min(80vh, 640px); padding: 0;
    border: 0; border-radius: var(--r); background: var(--surface); color: var(--text);
    box-shadow: 0 10px 40px rgba(0, 0, 0, .25);
  }
  dialog.log::backdrop { background: rgba(0, 0, 0, .35); }
  .log-head {
    position: sticky; top: 0; display: flex; align-items: center; justify-content: space-between;
    padding: 14px 14px 12px 20px; background: var(--surface); border-bottom: 1px solid var(--line-soft);
  }
  .log-head h2 { margin: 0; padding: 0; font-family: "Heading Serif", "Songti SC", "STSong", serif; font-size: 18px; font-weight: 600; color: var(--text); letter-spacing: 1px; }
  .log-head button {
    font: inherit; font-size: 20px; line-height: 1; color: var(--muted); cursor: pointer;
    background: none; border: 0; border-radius: 6px; width: 32px; height: 32px;
  }
  .log-head button:hover { color: var(--text); }
  .log-list { padding: 4px 20px 18px; outline: none; }
  .log-list article { padding: 14px 0 4px; }
  .log-list article + article { border-top: 1px solid var(--line-soft); }
  .log-list h3 { margin: 0; font-size: 15px; line-height: 1.45; font-weight: 600; font-variant-numeric: tabular-nums; }
  .log-list ul { margin: 6px 0 0; padding-left: 1.2em; }
  .log-list li { font-size: 14.5px; line-height: 1.65; margin-top: 4px; }
  .log-list li::marker { color: var(--muted); }
  .log-list .emo { height: 1.7em; vertical-align: -.5em; margin: 0 1px; }

  /* 本周直播: button under the name -> window with the week (data: /schedule.json,
     made by /opt/bili-posts/schedule.py from her 周表 image and posts) */
  .sched-btn {
    display: inline-flex; align-items: center; gap: 10px; max-width: 100%; margin-top: 16px;
    font: inherit; font-size: 14px; color: var(--text); cursor: pointer;
    background: transparent; border: 1px solid var(--text); border-radius: var(--r); padding: 6px 12px 6px 14px;
    transition: background-color .15s, color .15s;
  }
  /* kept in place (invisible) until /schedule.json is in, then fades in - nothing below jumps (user 2026-11-12) */
  .sched-btn[hidden] { display: inline-flex; visibility: hidden; opacity: 0; }
  /* the fade-in is ADDED to the hover transition (replacing it lost the hover fade, user 2026-11-13) */
  @media (prefers-reduced-motion: no-preference) { .sched-btn { transition: background-color .15s, color .15s, opacity .25s ease-out; } }
  .sched-btn:hover { background: var(--text); color: var(--surface); }
  .sched-btn:hover span { color: var(--surface); }
  .sched-btn b { font-weight: 600; letter-spacing: 1px; }
  .sched-btn span { color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sched-btn .chev { flex: 0 0 auto; width: 7px; height: 11px; }
  .sched-range { margin: 0; padding: 12px 20px 0; color: var(--muted); font-size: 13px; }
  .sched-list { padding: 6px 12px 16px; outline: none; display: flex; flex-direction: column; gap: 2px; }
  .sched-day { display: flex; gap: 14px; padding: 10px 8px; border-radius: var(--r); }
  .sched-day.today { background: var(--accent-soft); }
  .sched-day.past { color: var(--muted); }
  .sched-day .d { flex: 0 0 52px; font-size: 13px; line-height: 1.5; color: var(--muted); }
  .sched-day .d b { display: block; font-size: 15px; font-weight: 600; color: var(--text); }
  .sched-day.past .d b { color: var(--muted); }
  .sched-day.today .d b { color: var(--accent); }
  .sched-day .s { flex: 1; min-width: 0; font-size: 15px; line-height: 1.5; }
  .sched-day .s > div + div { margin-top: 6px; }
  .sched-day .ln { display: flex; align-items: baseline; gap: 10px; }
  .sched-day .ln .info { flex: 1; min-width: 0; }
  .sched-day .recs { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
  .sched-day .recs a { font-size: 13px; color: var(--accent); text-decoration: none; white-space: nowrap; font-variant-numeric: tabular-nums; }
  .sched-day .recs a:hover { text-decoration: underline; }
  .sched-day .extra .ti, .sched-day .tbd { color: var(--muted); }
  .sched-day .tm { font-variant-numeric: tabular-nums; font-weight: 600; margin-right: 8px; }
  .sched-day .off .tm, .sched-day .off .ti, .sched-day .x { text-decoration: line-through; color: var(--muted); }
  .sched-day .note { display: block; font-size: 13px; color: var(--accent); }
  .sched-day a.note { text-decoration: none; }
  .sched-day a.note:hover { text-decoration: underline; }
  .sched-day .tag-x { font-size: 12px; color: var(--accent); margin-left: 6px; text-decoration: none; }
  .sched-day .tag { display: inline-block; margin-top: 4px; font-size: 12px; color: var(--muted); border: 1px solid var(--tag-line); border-radius: var(--r); padding: 0 6px; }
  .sched-day .rest { color: var(--muted); }

  header { text-align: center; }
  header img { display: block; width: 160px; height: auto; margin: 0 auto 16px; }
  h1 {
    margin: 0; font-family: "Heading Serif", "Songti SC", "STSong", "SimSun", serif; font-weight: 600;
    font-size: 34px; line-height: 1.2; letter-spacing: 2px; color: var(--text);
  }
  .uptime { margin: 8px 0 0; min-height: 1.4em; font-size: 13px; line-height: 1.4; color: var(--faint); letter-spacing: 2px; }   /* min-height: line reserved before the script fills it */
  .uptime b { font: 500 13px var(--mono); color: var(--muted); letter-spacing: 0; margin: 0 6px 0 4px; }   /* left 4px + the 2px letter-spacing after 第 = 6px = right (user 2026-11-11: was 10 vs 8 px, then 4 = too tight) */

  /* Each section = one paper card, rows separated by hairlines */
  nav {
    display: flex; flex-direction: column; margin-top: 30px;
    background: var(--surface); border-radius: var(--r); overflow: hidden;
    box-shadow: 0 1px 2px rgb(var(--shadow-rgb) / .06);
  }
  nav a {
    position: relative; display: flex; align-items: center; gap: 14px; padding: 13px 18px 13px 16px;
    color: var(--text); text-decoration: none; transition: background-color .15s;
  }
  nav a + a::before { content: ""; position: absolute; top: 0; left: 52px; right: 0; border-top: 1px solid var(--line-soft); }
  nav a[hidden] { display: none; }
  nav a:hover { background: #fff; }
  nav a:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
  .ic { flex: 0 0 22px; height: 22px; color: var(--ink); display: flex; align-items: center; justify-content: center; }
  .ic svg { width: 21px; height: 21px; }
  nav a:hover .ic, nav a:hover .t b { color: var(--accent); }
  .t { flex: 1; min-width: 0; }
  .t b { display: block; font-size: 15.5px; font-weight: 600; line-height: 22px; }
  .t b small { font-size: 13px; font-weight: 400; color: var(--muted); margin-left: 6px; }
  .t span { display: block; margin-top: 1px; color: var(--faint); font: 12px/17px var(--mono); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .go { flex: 0 0 auto; width: 7px; height: 11px; color: var(--faint); }   /* drawn chevron: the text › sat off-centre */

  /* Section labels: index number (mono) + serif title + English */
  .wrap > h2 {
    display: flex; align-items: baseline; gap: 10px; margin: 34px 0 0; padding-left: 4px;
    font-family: "Heading Serif", "Songti SC", "STSong", serif; font-size: 16px; font-weight: 600; color: var(--text); letter-spacing: 1px;
  }
  .wrap > h2 i { font: normal 11px var(--mono); color: var(--faint); letter-spacing: 0; }
  .wrap > h2 small { font: 12px var(--mono); color: var(--faint); letter-spacing: 0; font-weight: 400; }
  .wrap > h2 + nav { margin-top: 10px; }

  footer { margin-top: 44px; }

  @media (max-width: 560px) {
    header img { width: 136px; }
    h1 { font-size: 30px; }
    nav a + a::before { left: 50px; }
  }
  @media (prefers-reduced-motion: reduce) { nav a { transition: none; } }

  dialog h2[tabindex]:focus { outline: none; }
  /* Top block: the 美团 banner (yellow extended to the full width, square corners; made from
     the original by /var/www/9on0/style-draft/extend-banner.py) hangs from the top edge, the live row is attached under it */
  .top { margin: 0 0 22px; }
  a.ad { display: block; background: #fccb0e; }
  /* The pizza on the left pushes the yellow box 2% right of the image centre (box x 63-1019
     of 1040): shift left so the box itself is centred like the rows below */
  a.ad img { display: block; width: 100%; height: auto; transition: filter .15s; }
  a.ad:hover img { filter: brightness(1.04); }
  /* Live row (real data since 2026-11-11: /stats/now.json). Offline: status, last stream, 大航海 /
     粉丝团 / 粉丝. Live: status + running time only for now (the rolling live stats come later). */
  .live[hidden] { display: none; }
  .live { display: flex; align-items: center; gap: 10px; padding: 10px 4px; font-size: 14px; border-bottom: 1px solid var(--line-soft);
          color: var(--text); text-decoration: none; }
  .live:hover .lgo, .live:hover .nums { color: var(--accent); }
  .live:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
  .live .lgo { flex: 0 0 auto; width: 6px; height: 10px; color: var(--faint); margin-left: -2px; }   /* drawn chevron: a text › sits low */
  .live.on .dot { background: var(--accent); animation: lvpulse 2s ease-in-out infinite; }
  @keyframes lvpulse { 50% { opacity: .35; } }
  @media (prefers-reduced-motion: reduce) { .live.on .dot { animation: none; } }
  .live .nums .sep { color: var(--faint); margin: 0 5px; }
  .live b { flex: none; white-space: nowrap; }
  .live .when { flex: 0 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .live .nums { flex: none; }
  @media (max-width: 560px) { .live .nums .fc, .live .nums .fc + .sep { display: none; } }
  .live .dot { flex: 0 0 8px; height: 8px; border-radius: 50%; background: var(--faint); }
  .live b { font-weight: 600; }
  .live .when { color: var(--muted); }
  .live .nums { margin-left: auto; font: 12px var(--mono); color: var(--muted); white-space: nowrap; }
  .live .nums em { font-style: normal; color: var(--text); }
  @media (max-width: 480px) { .live .when { display: none; } }
  /* Phones: the banner goes edge to edge (it hangs from the top of the screen) */
  @media (max-width: 560px) {
    a.ad { margin: 0 -16px; }
  }
  .toast {
    position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 20;
    max-width: calc(100% - 32px); padding: 9px 16px; border-radius: var(--r);
    background: var(--toast); color: #fff; font-size: 14px; text-align: center;
    opacity: 0; transition: opacity .2s; pointer-events: none;
  }
  .toast.show { opacity: 1; }
