/* 出行须知 (owner 2026-12-03). Loaded by the home page (index.html, wildtrail-index.html) and the trip page (wildtrail-event.html), after
   site.css / trip.css, and uses their colours (--ink, --ink2, --ink3, --line, --line2, --card, --orange, --orange-text, --glass, --r, --ease).
   Two places show the same briefing (site/notice.js cardsHtml): the trip page section #trip-notice and, on the home page, the panel of a
   .notice-item (site/home.js). Warning lines carry a "!" badge as well as the amber colour (never colour alone).
   Look (wt-design 2026-12-04, owner: "add it to this part and an extended bar, and when you click it, it expands with detail information"):
   - Home page (made to read as a notification, owner 2026-12-03 "make it a notification so that it is easily noticeable that it is important"):
     one bar under the resort cards of the hero: a solid orange block with a bell, a warm cream face with an orange edge, 「出行须知」 in bold with
     a small orange dot, a one-line summary of the nearest trip, a down arrow. It arrives once (slides down, the bell rings) and then stays still. Closed it is one bar high and moves nothing. A press opens the list of trips in place (the
     body scrolls by itself when long, so the headline and the search never leave the screen); each trip is a row that opens its briefing.
   - The briefing itself is ONE column, a list: a heading with its icon, then the lines, a thin divider between the parts. No grey tiles.
     The trip page uses the very same list inside one white card. On phones the hero is on paper (no photo), so the bar is solid cream there. */

/* ---------- the briefing list: shared by both pages ---------- */
.notice-lines{list-style:none;margin:0;padding:0;display:grid;gap:6px}
.notice-line{position:relative;padding-left:14px;font-size:14px;line-height:1.6;color:var(--ink2);overflow-wrap:anywhere}
.notice-line::before{content:"";position:absolute;left:1px;top:.72em;width:5px;height:5px;border-radius:50%;background:var(--ink3)}
.notice-line a{color:var(--orange-text)}
.notice-line.is-warn{padding:8px 12px 8px 40px;border-radius:12px;background:#fff3cf;color:#5a4300}
.notice-line.is-warn::before{content:"!";left:12px;top:9px;width:20px;height:20px;border-radius:50%;background:#8a5a00;color:#fff;font:700 13px/20px var(--sans);text-align:center}
.notice-line.is-warn a{color:#5a4300}
/* the owner's own text of a part (2026-12-04): a blank line in it = a bigger gap; a line that already starts with • or ・ has no second dot */
.notice-line.notice-gap{margin-top:10px}
.notice-line.notice-mark{padding-left:0}
.notice-line.notice-mark::before{content:none}
.notice-card{min-width:0;padding:14px 0 16px;border-top:1px solid var(--line)}
.notice-card:first-child{padding-top:6px;border-top:0}
.notice-card:last-child{padding-bottom:8px}
.notice-card h3{display:flex;align-items:center;gap:8px;margin:0 0 8px;font-size:15px;font-weight:600;line-height:1.35;color:var(--ink)}
.notice-card h3 .ic{flex:none;width:20px;height:20px;color:var(--orange-text)}
/* the event page: the whole briefing in one white card, one column (the wrapper keeps trip.js's .infos grid class, so it is reset here) */
.notice-sec .notice-grid{display:block;max-width:760px;padding:8px 24px;border-radius:20px;background:var(--card);border:1px solid var(--line2)}
/* the section title carries the same bell as the home bar, quietly (tinted tile, like the icons of the other info cards); trip.js writes the h2, the bell is drawn here.
   The bell is a file (site/notice-bell.svg), not an inline URI: the Content-Security-Policy (img-src 'self' + three photo hosts) blocks inline images */
.notice-sec>h2{display:flex;align-items:center;gap:12px}
.notice-sec>h2::before{content:"";flex:none;width:36px;height:36px;border-radius:12px;background:rgba(255,90,30,.14) url("/site/notice-bell.svg") center/20px no-repeat}

/* ---------- home page: the bar under the resort cards ---------- */
.notice-home{--nr:var(--r);--nbg:#fff7ef;--nedge:rgba(255,90,30,.6);--nsep:rgba(255,90,30,.28);
  margin-top:12px;border-radius:var(--nr);color:var(--ink);background:rgba(255,247,239,.97);
  -webkit-backdrop-filter:blur(16px) saturate(1.3);backdrop-filter:blur(16px) saturate(1.3);border:1px solid var(--nedge);
  box-shadow:0 14px 30px -14px rgba(255,90,30,.65),0 4px 12px -6px rgba(0,0,0,.3);animation:notice-in .5s var(--ease) .2s backwards}
.notice-home[hidden]{display:none}
.notice-bar-h{margin:0;font:inherit}
/* a notification, not a card: a solid orange block with a bell on the left, a warm cream face, an orange edge. Dark ink on the orange (5.3:1) */
.notice-bar{display:grid;grid-template-columns:56px auto minmax(0,1fr) auto 24px;align-items:center;gap:0 16px;width:100%;min-height:56px;padding:0 16px 0 0;border:0;border-radius:var(--nr);background:none;
  color:inherit;font:inherit;text-align:left;cursor:pointer;transition:background-color .15s ease-out}
.notice-bar:hover{background:rgba(255,90,30,.08)}
.notice-bar:focus-visible{outline:3px solid var(--ink);outline-offset:-5px}   /* ink ring, not the site's orange one: it must show on the orange block too */
.notice-home.is-open .notice-bar{border-radius:var(--nr) var(--nr) 0 0}
.notice-bar-badge{align-self:stretch;display:grid;place-items:center;background:var(--orange);color:var(--ink);border-radius:calc(var(--nr) - 1px) 0 0 calc(var(--nr) - 1px)}
.notice-home.is-open .notice-bar-badge{border-bottom-left-radius:0}
.notice-bar-ic{width:26px;height:26px;stroke-width:2;transform-origin:50% 8%;animation:notice-ring .8s cubic-bezier(.36,.07,.19,.97) .8s 1}
.notice-bar-t{font-size:16px;font-weight:700;line-height:1.3;white-space:nowrap}
.notice-bar-t::after{content:"";display:inline-block;width:8px;height:8px;margin-left:8px;border-radius:50%;background:var(--orange);vertical-align:middle}   /* "unread" dot, decorative */
.notice-sum{display:flex;align-items:center;gap:6px 14px;min-width:0;font-size:14px;line-height:1.35;color:var(--ink2)}
.notice-sum-m{flex:0 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.notice-count:empty{display:none}
.notice-count{padding:2px 10px;border-radius:999px;background:var(--orange);color:var(--ink);font-size:12px;font-weight:700;white-space:nowrap}
/* once, on arrival: the bar slides down a little and the bell rings; nothing repeats */
@keyframes notice-in{from{opacity:0;transform:translateY(-10px)}}
@keyframes notice-ring{0%,100%{transform:rotate(0)}15%{transform:rotate(14deg)}30%{transform:rotate(-12deg)}45%{transform:rotate(8deg)}60%{transform:rotate(-5deg)}75%{transform:rotate(2deg)}}
.notice-chev{width:20px;height:20px;justify-self:end;color:var(--ink);transition:transform .25s var(--ease)}
.notice-bar[aria-expanded="true"] .notice-chev,.notice-item.is-open .notice-chev{transform:rotate(180deg)}
.notice-date{font-size:14px;font-weight:500;font-variant-numeric:tabular-nums;color:var(--ink2)}
.notice-wxline{display:inline-flex;align-items:center;gap:8px;min-width:0;font-size:14px;line-height:1.35;color:var(--ink2)}
.notice-sum .notice-wxline{flex:none;white-space:nowrap}
.notice-wxline .wx-ic{flex:none;width:22px;height:22px}

/* open / close: the body grows from 0fr to 1fr (no fixed height); closed content is not focusable (visibility waits until the row has shrunk) */
.notice-body,.notice-panel{display:grid;grid-template-rows:0fr;transition:grid-template-rows .22s var(--ease)}
.notice-home.is-open .notice-body,.notice-item.is-open .notice-panel{grid-template-rows:1fr;transition-duration:.32s}
.notice-body-in,.notice-panel-in{min-height:0;overflow:hidden;visibility:hidden;opacity:0;transition:visibility 0s linear .22s,opacity .18s var(--ease)}
.notice-home.is-open .notice-body-in,.notice-item.is-open .notice-panel-in{visibility:visible;opacity:1;transition:visibility 0s,opacity .28s var(--ease) .06s}
.notice-scroll{max-height:min(48vh,420px);overflow-y:auto;overscroll-behavior:contain;border-top:1px solid var(--nsep)}
/* desktop: the open list hangs from the bar over the photo (it pushes nothing, so the headline and the search stay where they are) */
@media (min-width:801px){
  .notice-home{position:relative;z-index:6}
  .notice-home.is-open{border-bottom-left-radius:0;border-bottom-right-radius:0;background:var(--nbg)}   /* solid once open: the headline must not show through the list; the bar and the list are one cream sheet */
  .notice-body{position:absolute;left:-1px;right:-1px;top:calc(100% - 1px);border-radius:0 0 var(--r) var(--r);background:var(--nbg)}
  .notice-home.is-open .notice-body{border:1px solid var(--nedge);border-top:0;box-shadow:0 26px 50px -22px rgba(0,0,0,.55)}
}
.notice-lead{margin:0;padding:12px 18px 6px;font-size:13px;line-height:1.5;color:var(--ink2)}
.notice-cards{display:block;padding:0 8px 8px}

/* one trip = one row; rows are told apart by a thin line, not by boxes */
.notice-item{border-top:1px solid var(--line)}
.notice-item:first-child{border-top:0}
.notice-row{margin:0;font:inherit}
.notice-toggle{display:grid;grid-template-columns:7.2em minmax(0,1fr) auto 24px;align-items:center;gap:6px 16px;width:100%;min-height:56px;padding:8px 10px;border:0;border-radius:12px;background:none;
  color:inherit;font:inherit;text-align:left;cursor:pointer;transition:background-color .15s ease-out}
.notice-toggle:hover,.notice-item.is-open .notice-toggle{background:rgba(20,32,27,.05)}
.notice-toggle:focus-visible{outline:2px solid var(--orange);outline-offset:-2px}
.notice-name{font-size:16px;font-weight:500;line-height:1.35;overflow-wrap:anywhere}
.notice-toggle .notice-wxline{text-align:right}
.notice-panel .notice-grid{padding:4px 10px 0}
.notice-more{display:inline-flex;align-items:center;gap:8px;min-height:44px;margin:4px 0 10px 10px;padding:0 18px;border-radius:999px;border:1px solid var(--line2);background:var(--card);
  color:var(--ink);font-size:14px;font-weight:500;text-decoration:none;transition:border-color .15s ease-out}
.notice-more:hover{border-color:var(--ink)}
.notice-more:focus-visible{outline:2px solid var(--orange);outline-offset:3px}
.notice-more .ic{width:18px;height:18px;transition:transform .25s var(--ease)}
.notice-more:hover .ic{transform:translateX(3px)}

@media (max-width:800px){
  /* phones: the hero is paper, the resort cards are solid white tiles, so the bar is one too. Two lines: title (and the count) / nearest trip (and its weather) */
  .notice-home{--nr:var(--r-card,20px);margin-top:12px;background:var(--nbg);box-shadow:0 10px 22px -12px rgba(255,90,30,.6);-webkit-backdrop-filter:none;backdrop-filter:none}
  .notice-bar{grid-template-columns:52px minmax(0,1fr) auto 24px;grid-template-areas:"ic t n chev" "ic sum sum chev";gap:2px 12px;padding:10px 14px 10px 0}
  .notice-bar-badge{grid-area:ic;margin:-10px 0}   /* the orange block runs the full height of the two-line bar */
  .notice-bar-t{grid-area:t}
  .notice-chev{grid-area:chev}
  .notice-sum{grid-area:sum;font-size:13px}
  .notice-sum .notice-wxline{gap:5px}
  .notice-sum .notice-wxline .wx-ic{display:none}   /* the words carry it; the room goes to the trip name */
  .notice-count{grid-area:n;justify-self:end}
  .notice-scroll{max-height:min(62svh,520px)}
  .notice-lead{padding:10px 14px 4px}
  .notice-cards{padding:0 6px 6px}
  .notice-toggle{grid-template-columns:auto minmax(0,1fr) 24px;grid-template-areas:"date wx chev" "name name chev";gap:2px 12px;padding:8px}
  .notice-toggle .notice-date{grid-area:date}
  .notice-toggle .notice-wxline{grid-area:wx;justify-self:end;font-size:13px}
  .notice-name{grid-area:name}
  .notice-toggle .notice-chev{grid-area:chev}
  .notice-panel .notice-grid{padding:2px 8px 0}
  .notice-more{margin:4px 8px 10px;width:calc(100% - 16px);justify-content:center}
  .notice-sec .notice-grid{max-width:none;padding:4px 16px}
}
/* narrow phones (below 375, long English dates and forecast words): the weather drops to its own line instead of running into the date;
   from 375 up it shares the date's line and may itself wrap (.notice-wxline is not nowrap) */
@media (max-width:374px){
  .notice-toggle{grid-template-columns:minmax(0,1fr) 24px;grid-template-areas:"date chev" "name chev" "wx chev"}
  .notice-toggle .notice-wxline{justify-self:start;text-align:left}
  .notice-sum{flex-wrap:wrap}
}

@media (prefers-reduced-motion:reduce){
  .notice-home,.notice-bar-ic{animation:none}
  .notice-bar,.notice-toggle,.notice-chev,.notice-more,.notice-more .ic{transition:none}
  .notice-body,.notice-home.is-open .notice-body,.notice-body-in,.notice-home.is-open .notice-body-in,
  .notice-panel,.notice-item.is-open .notice-panel,.notice-panel-in,.notice-item.is-open .notice-panel-in{transition:none}
  .notice-more:hover .ic{transform:none}
}
