/* ==========================================================================
   アスオタウンの ページ (/town 配下) の ヘッダーと フッター (2026-11-30)
   layouts/asuka.blade.php の town_chrome で 読む。色は アスオタウンの 草の 緑と 黒い 枠
   ========================================================================== */
.town-site{ --t-grass:#93c66e; --t-grass-d:#6a9a4a; --t-ink:#222; --t-sky:#bfe3f2; --t-sun:#ffd23f; }
.town-site{ background:linear-gradient(180deg, var(--t-sky) 0, #e9f6e1 260px, #f6f1df 100%); }

.town-gheader{ position:relative; z-index:50; background:var(--t-grass); border-bottom:4px solid var(--t-ink); padding:10px 20px; }
.town-gheader .inner{ position:relative; max-width:var(--maxw, 1100px); margin:0 auto; display:flex; align-items:center; gap:16px; }
.town-gheader .tbrand{ flex:0 0 auto; display:flex; align-items:center; }
.town-gheader .tbrand img{ height:46px; width:auto; filter:drop-shadow(2px 2px 0 rgba(0,0,0,.25)); transition:transform .2s; }
.town-gheader .tbrand:hover img{ transform:rotate(-3deg) scale(1.04); }
/* メニューの ボタンは 白地に 黒い 縁と 影 (2026-11-30「メニューボタンは 前の 方が 良かった」) */
.town-menu{ flex:1 1 auto; display:flex; align-items:center; gap:6px; flex-wrap:wrap; }
.town-menu a{ color:var(--t-ink); font-size:13px; font-weight:bold; padding:7px 14px; border-radius:18px; text-decoration:none;
  border:3px solid var(--t-ink); background:#fff; box-shadow:3px 3px 0 var(--t-ink); white-space:nowrap; transition:transform .12s; }
.town-menu a:hover{ transform:translate(-1px,-1px); background:var(--t-sun); text-decoration:none; }
.town-menu a.active{ background:var(--t-sun); }
.town-to-asuka{ flex:0 0 auto; color:var(--t-ink); font-size:12px; font-weight:bold; text-decoration:none; border-bottom:2px solid var(--t-ink); white-space:nowrap; }
.town-to-asuka:hover{ color:#fff; border-color:#fff; text-decoration:none; }
.town-gheader .ttoggle{ display:none; margin-left:auto; background:#fff; color:var(--t-ink); border:3px solid var(--t-ink); border-radius:30px;
  padding:7px 14px; font-weight:bold; cursor:pointer; font-size:13px; box-shadow:3px 3px 0 var(--t-ink); font-family:inherit; }
.town-gheader .ttoggle:focus-visible, .town-menu a:focus-visible, .town-to-asuka:focus-visible{ outline:3px solid #1a6aff; outline-offset:2px; }

@media (max-width:760px){
  .town-gheader{ padding:8px 14px; }
  .town-gheader .tbrand img{ height:38px; }
  .town-gheader .ttoggle{ display:inline-block; }
  .town-to-asuka{ display:none; }
  .town-menu{ display:none; position:absolute; top:calc(100% + 12px); left:-14px; right:-14px; flex-direction:column; align-items:stretch;
    background:var(--t-grass); border-bottom:4px solid var(--t-ink); padding:14px; gap:10px; z-index:60; }
  .town-menu.open{ display:flex; }
  .town-menu a{ text-align:center; }
}

.town-footer{ position:relative; z-index:5; text-align:center; padding:36px 20px 80px; margin-top:0; font-size:11px; color:#3a4a2e;
  background:var(--t-grass); border-top:2px solid var(--t-ink); }
.town-footer .tf-lead{ font-size:13px; font-weight:bold; margin:0 0 14px; color:var(--t-ink); }
.town-footer .tf-lead a{ color:var(--t-ink); }
.town-footer .foot-follow{ margin:0 0 14px; }
.town-footer .tf-links{ margin:0 0 8px; line-height:2; }
.town-footer .tf-links a{ color:var(--t-ink); font-size:12px; font-weight:bold; text-decoration:none; }
.town-footer .tf-links a:hover{ text-decoration:underline; }
.town-footer .tf-sub a, .town-footer .tf-sub .ck-relink{ font-weight:normal; color:#3a4a2e; }
.town-footer .sep{ color:rgba(0,0,0,.3); margin:0 3px; }
.town-footer .ck-relink{ background:none; border:0; padding:0; font:inherit; font-size:12px; cursor:pointer; text-decoration:none; }
.town-footer .copy{ margin-top:12px; color:#3a4a2e; }

/* ==========================================================================
   アスオタウンの ページ 共通: 背景と 本文の 欄・枠を 使わない 部品 (2026-11-30)
   **枠 (特に 角丸の 箱) で 囲まない。**区切りは 余白と 細い 直線だけ
   ========================================================================== */
.town-wrap{ position:relative; overflow:hidden; background:#b9b07a url('/town-assets/town-map-bg.webp?v=1') repeat; background-size:880px auto; }
/* 地図は ゲームの 町 (townmapshot.js で 縫い合わせた もの)。紙の 際だけ 少し 明るく して、本文と 混ざらない ように */
.town-wrap::before{ content:''; position:absolute; inset:0; background:linear-gradient(90deg, rgba(255,253,246,.1), rgba(255,253,246,.45) calc(50% - 520px), rgba(255,253,246,.45) calc(50% + 520px), rgba(255,253,246,.1)); }
.town-sheet{ position:relative; z-index:1; max-width:1000px; margin:0 auto; background:#fffdf6; min-height:70vh; border-left:2px solid var(--t-ink); border-right:2px solid var(--t-ink); }
@media (max-width:1004px){ .town-sheet{ border-left:0; border-right:0; } }
/* 中の 先頭の 要素の margin が 紙の 外へ 抜けて、ヘッダーとの あいだに 背景が 見える のを 防ぐ */
.town-sheet{ display:flow-root; }
/* 見出し: 大きく、下に 黄色の 太い 線 (直線の 強調) */
.town-sheet :is(.cast-hero h1, .asuka-title h1, .gl-h){ display:inline-block; padding:0 6px; background:linear-gradient(transparent 62%, #ffd23f 62%, #ffd23f 90%, transparent 90%); }
.town-sheet .asuka-title{ text-align:center; margin:22px 0 18px; }
.town-sheet .asuka-title h1{ font-size:clamp(28px,5vw,42px) !important; letter-spacing:.04em; }
.town-sheet .asuka-page{ background:none; }

/* 囲みの 部品を 平らに (手描きの 枠 asuka-tegaki.css も 外す) */
.town-site .town-sheet .asuka-panel{ border:0 !important; border-radius:0 !important; box-shadow:none !important; background:none !important; padding:0 !important; margin:0 0 28px; }
.town-site .town-sheet :is(.asuka-panel, .asuka-btn)::before, .town-site .town-sheet :is(.asuka-panel, .asuka-btn)::after{ display:none !important; }
.town-site .town-sheet .asuka-btn{ display:inline; background:none !important; border:0 !important; border-radius:0 !important; box-shadow:none !important; padding:0 !important;
  color:#222 !important; font-weight:bold; text-decoration:underline; text-underline-offset:4px; text-decoration-color:#93c66e; text-decoration-thickness:2px; }
.town-site .town-sheet .asuka-btn:hover{ text-decoration-color:#222; transform:none; }
/* 本体サイトの 見出し (虹色・揺れ) を 町の ページの 見出し (黒字に 黄色の 線) に そろえる */
.town-site .town-sheet .asuka-title h1{ color:#222 !important; filter:none !important; text-shadow:none !important; animation:none !important; transform:none !important;
  -webkit-background-clip:border-box !important; background-clip:border-box !important; background-size:auto !important;
  background-image:linear-gradient(transparent 62%, #ffd23f 62%, #ffd23f 90%, transparent 90%) !important; line-height:1.3 !important; font-weight:bold; }
.town-site .town-sheet .asuka-pager a, .town-site .town-sheet .asuka-pager span{ border:0 !important; border-radius:0 !important; box-shadow:none !important; background:none !important; }
.town-site .town-sheet .asuka-pager .active, .town-site .town-sheet .asuka-pager [aria-current]{ text-decoration:underline; text-underline-offset:4px; }


/* できること (カードの 枠を 外す) */
.town-site .dk-item{ border:0 !important; border-radius:0 !important; box-shadow:none !important; background:none !important; }
.town-site .dk-item:hover{ transform:none; }
.town-site .dk-item img{ border-bottom:0 !important; }
.town-site .dk-item h2{ padding:10px 0 0 !important; }
.town-site .dk-item:hover h2{ text-decoration:underline; text-underline-offset:4px; }

/* アスオ新聞の 一覧と 記事 (紙面は そのまま。まわりの 暗い 背景と カードの 枠を 外す) */
.town-site .gl-page{ background:none !important; }
.town-site .gl-h{ color:#222 !important; font-size:clamp(28px,5vw,42px) !important; letter-spacing:.04em !important; line-height:1.3; display:table !important; margin:22px auto 12px !important; font-family:inherit; }
.town-site .gl-sub{ color:#555 !important; text-align:center; }
.town-site .gl-card{ border:0 !important; box-shadow:none !important; background:none !important; }
.town-site .gl-card:hover{ transform:none; }
.town-site .gl-card:hover .gl-head{ text-decoration:underline; }
.town-site .gl-thumb{ border-bottom:0 !important; }
.town-site .gl-meta{ padding:8px 0 0 !important; }
.town-site .gogai-wrap{ background:none !important; }
.town-site .gogai-links{ display:flex; flex-wrap:wrap; gap:6px 20px; }


/* できることの カードの 手描きの 線 (asuka-tegaki.css の .dk-item::before) も 外す */
.town-site .dk-item::before, .town-site .dk-item::after{ display:none !important; }
.town-site .dk-item img{ border-radius:0 !important; }

/* 全画面の ときは ヘッダーと フッターを 出さない */
body.town-immersive :is(.town-gheader, .town-footer){ display:none; }

/* ==========================================================================
   線を 手描き風に (2026-11-30「アスオタウンの ページでも 線を 手書き風に」)
   asuka-tegaki.css と 同じ 描き方: 線は 透明な 箱の 辺に 引き、箱ごと filter:url(#roughN) で 歪ませる。
   **細い 線は そのまま 歪ませると 消える** ので、高さ 16px の 箱の 下辺に 引く
   ========================================================================== */
.town-gheader{ border-bottom-color:transparent !important; }
.town-gheader::after{ content:''; position:absolute; left:0; right:0; bottom:-4px; height:16px; border-bottom:4px solid var(--t-ink); filter:url(#rough2); pointer-events:none; }
.town-footer{ border-top-color:transparent !important; }
.town-footer::before{ content:''; position:absolute; left:0; right:0; top:-4px; height:16px; border-top:3px solid var(--t-ink); filter:url(#rough2); pointer-events:none; }
.town-sheet{ border-left-color:transparent !important; border-right-color:transparent !important; }
.town-sheet::before{ content:''; position:absolute; top:0; bottom:0; left:-2px; right:-2px; border-left:2px solid var(--t-ink); border-right:2px solid var(--t-ink); filter:url(#rough1); pointer-events:none; z-index:2; }
@media (max-width:1004px){ .town-sheet::before{ display:none; } }
.town-sheet .cast-parade{ position:relative; border-bottom-color:transparent !important; padding-bottom:4px !important; }
.town-sheet .cast-parade::after{ content:''; position:absolute; left:0; right:0; bottom:0; height:16px; border-bottom:2px solid var(--t-grass-d); filter:url(#rough2); pointer-events:none; }
.town-sheet .cast-foot{ position:relative; border-top-color:transparent !important; }
.town-sheet .cast-foot::before{ content:''; position:absolute; left:0; right:0; top:-2px; height:16px; border-top:2px solid var(--t-ink); filter:url(#rough2); pointer-events:none; }
/* メニューの ボタン: 縁と 地色と 影を ::before に 描いて 歪ませる (文字は ぼけない) */
.town-menu a, .town-gheader .ttoggle{ position:relative; isolation:isolate; background:transparent !important; border-color:transparent !important; box-shadow:none !important; }
.town-menu a::before, .town-gheader .ttoggle::before{ content:''; position:absolute; inset:-3px; z-index:-1; border:3px solid var(--t-ink); border-radius:18px; background:#fff;
  box-shadow:3px 3px 0 var(--t-ink); filter:url(#rough1); }
.town-menu a.active::before, .town-menu a:hover::before{ background:var(--t-sun); }
/* スマホの MENU ボタンは 白地 (地色は ボタン 自身に 塗る) */
.town-gheader .ttoggle{ background:#fff !important; }
.town-gheader .ttoggle::before{ border-radius:30px; background:none; }

/* ==========================================================================
   背景を 楽しく (2026-11-30「もっと 背景を デザイン性 ある 愉快な 感じに」)
   ========================================================================== */

/* フッターの 上の 草の 帯: 登場人物が 歩いて いく */
.town-parade{ position:relative; z-index:4; height:170px; overflow:hidden; background:linear-gradient(180deg, #cfe9f5 0, #e6f4dc 76%, var(--t-grass) 76%); }
.town-parade::after{ content:''; position:absolute; left:0; right:0; top:calc(76% - 1px); height:16px; border-top:3px solid var(--t-grass-d); filter:url(#rough2); pointer-events:none; z-index:1; }
.tp-track{ position:absolute; z-index:2; left:0; bottom:30px; display:flex; align-items:flex-end; gap:34px; width:max-content; padding-left:34px; animation:tpWalk 90s linear infinite; }
.tp-track img{ width:auto; height:auto; max-height:124px; flex:0 0 auto; animation:tpStep .9s ease-in-out infinite; filter:drop-shadow(0 5px 0 rgba(0,0,0,.15)); }
@keyframes tpWalk{ from{ transform:translateX(-50%); } to{ transform:translateX(0); } }
@keyframes tpStep{ 0%,100%{ translate:0 0; rotate:-2deg; } 50%{ translate:0 -5px; rotate:2deg; } }
body.town-immersive .town-parade{ display:none; }
/* スマホ (ヘッダーが MENU に なる 幅) では 出さない */
@media (max-width:760px){ .town-parade{ display:none; } }
@media (prefers-reduced-motion: reduce){
  .tp-track, .tp-track img{ animation:none; }
}
