/* 銀河色星占い天命殺 - 鑑定ウィジェット (WordPress移植版)
   すべて .gU 配下に閉じ込め、テーマ(Cocoon等)のスタイルと干渉しない */

.gU { max-width: 680px; margin: 0 auto; line-height: 1.6; }
.gU, .gU * { box-sizing: border-box; }
.gU img { max-width: 100%; height: auto; }
/* 盤の中の画像だけは原寸必須(縮尺は transform で行うため) */
.gU-wheelBox img { max-width: none; height: auto; }
.gU-center { text-align: center; }
.gU-click { cursor: pointer; }
.gU-link { text-decoration: underline; cursor: pointer; }
.gU-red { color: red; }
.gU-satsu { font-size: larger; color: red; }
.gU-kou { font-size: larger; color: blue; }

/* ---- 入力フォーム ---- */
.gU-entry img { max-width: 100%; height: auto; }
.gU-formTable { margin: 0 auto; border-collapse: collapse; }
.gU-formTable td { padding: 4px 8px; border: none; background: none; }
.gU-formTable img { max-width: 160px; }
.gU-unknown { margin-left: 20px; white-space: nowrap; }

/* ---- 回転盤 (650x650 固定を transform で縮尺) ---- */
.gU-wheelScale { width: 100%; overflow: hidden; }
.gU-wheelBox {
  position: relative; width: 650px; height: 650px;
  overflow: hidden; background-position: 0 0;
  transform-origin: top left;
}
.gU-wheelIn { position: absolute; left: 25px; top: 25px; width: 600px; height: 600px; overflow: hidden; }
.gU-meter {
  position: relative; left: 196px; top: 246px; width: 202px; height: 92px;
  background-color: #fff; border: 2px solid blue;
}
.gU-tl {
  position: absolute; left: 1px; top: 1px; width: 198px; height: 38px;
  background-color: #fff; border: 1px solid blue;
  background-repeat: repeat-y; background-position: 0 0;
}
.gU-tcell {
  position: absolute; top: 41px; width: 48px; height: 18px;
  background-color: #fff; border: 1px solid blue; overflow: hidden;
}
.gU-tcell img { position: absolute; left: 0; top: 0; }
.gU-ccell {
  position: absolute; top: 61px; width: 48px; height: 28px;
  background-color: #fff; border: 1px solid blue;
  background-repeat: repeat-y; background-position: 0 0;
}

.gU-bottomTitle { font-weight: bold; margin-top: 8px; }
.gU-bottomBody { font-size: smaller; }

/* ---- 見出し (旧 #main h3 の青帯) ---- */
.gU-h3 {
  background-color: #fff; border-radius: 5px;
  box-shadow: 0 1px 2px rgba(0,0,0,.2);
  line-height: 1; margin: 15px 0; padding: 11px 0;
  position: relative; z-index: 1; clear: both; color: #fff;
}
.gU-h3::before {
  content: ""; position: absolute; top: 2px; right: 2px; bottom: 2px; left: 2px;
  background-color: #4698cc; border-radius: 4px; z-index: -1;
  background-image: linear-gradient(-45deg, rgba(255,255,255,.03) 25%, rgba(255,255,255,0) 25%, rgba(255,255,255,0) 50%, rgba(255,255,255,.03) 50%, rgba(255,255,255,.03) 75%, rgba(255,255,255,0) 75%, rgba(255,255,255,0));
  background-size: 34px 34px;
}
.gU-h3 span {
  color: #fff; display: block; font-size: 18px; font-weight: bold;
  padding: 0 15px; line-height: 1.4; text-shadow: 0 1px 1px #6491c5;
}

/* ---- 鑑定結果 ---- */
.gU-result { border: 3px groove silver; padding: 6px; }
.gU-resultGrid { display: flex; gap: 8px; flex-wrap: wrap; }
.gU-nekoCol { flex: 0 0 200px; }
.gU-nekoCol img { width: 95%; height: auto; border: 5px ridge blue; }
.gU-mainCol { flex: 1 1 300px; min-width: 260px; }
.gU-star { font-size: x-large; font-weight: 800; font-family: "ＭＳ ゴシック", sans-serif; margin: 0 0 4px; }
.gU-catch { font-size: large; font-weight: 800; margin: 0 0 4px; }
.gU-colorTable { border-collapse: collapse; width: 100%; }
.gU-colorTable th {
  width: 110px; font-weight: 800; text-align: center;
  background: none; border: none; padding: 2px; vertical-align: middle;
}
.gU-colorTable td { background: none; border: none; padding: 2px; }
.gU-colorTable img { vertical-align: middle; max-width: 100%; height: auto; }

.gU-tenmeiGrid {
  display: grid; grid-template-columns: 110px 1fr 110px 1fr;
  gap: 4px; align-items: center; margin-top: 6px;
}
.gU-tenmeiGrid img { width: 100%; height: auto; border: 1px solid #888; }
.gU-tenmeiTxt {
  text-align: center; font-family: "ＭＳ ゴシック", sans-serif;
  font-size: larger; font-weight: 800;
}

/* ---- 吹き出し (旧 boxL/boxR) ---- */
.gU-boxL, .gU-boxR {
  position: relative; height: auto; width: auto;
  margin: 25px 10px 0; padding: 5px 12px;
  border: 1px solid #999; border-radius: 20px;
}
.gU-boxL { background: #ddf; }
.gU-boxR { background: #fdd; }
.gU-boxL::after, .gU-boxR::after {
  content: ""; position: absolute; top: -19px;
  border-right: 10px solid transparent; border-left: 10px solid transparent;
}
.gU-boxL::after { border-bottom: 20px solid #ddf; left: 30px; }
.gU-boxR::after { border-bottom: 20px solid #fdd; left: 245px; }
.gU-boxL::before, .gU-boxR::before {
  content: ""; position: absolute; top: -21px;
  border-bottom: 20px solid #999;
  border-right: 10px solid transparent; border-left: 10px solid transparent;
}
.gU-boxL::before { left: 30px; }
.gU-boxR::before { left: 245px; }
.gU-boxTitle { font-size: x-large; margin: 4px 0; }
.gU-close { text-align: right; margin-right: 20px; font-weight: 800; font-family: "ＭＳ ゴシック", sans-serif; }

/* 段落先頭の大文字装飾 (旧 .fl) */
.gU-fl:first-letter { font-size: 2.5em; line-height: 1; float: left; margin: 0 .2em 0 0; padding: .1em 0; }
.gU-body { margin-top: 8px; }

/* ---- ピンク飾り枠 (旧 DesignFramePink) ---- */
.gU-pinkFrame {
  padding: 30px; position: relative; width: 100%; height: auto;
  margin: 0 auto; overflow: hidden;
  background-image:
    url("assets/frame/PP/P_01.png"),
    url("assets/frame/PP/P_04.png"),
    url("assets/frame/PP/P_16.png"),
    url("assets/frame/PP/P_13.png"),
    url("assets/frame/PP/P_02.png"),
    url("assets/frame/PP/P_14.png"),
    url("assets/frame/PP/P_05.png"),
    url("assets/frame/PP/P_08.png"),
    url("assets/frame/PP/P_06.png");
  background-position: top left, top right, bottom right, bottom left, top left, bottom left, top left, top right, top left;
  background-repeat: no-repeat, no-repeat, no-repeat, no-repeat, repeat-x, repeat-x, repeat-y, repeat-y, repeat;
}

/* ---- スマホ ---- */
@media (max-width: 560px) {
  .gU-nekoCol { flex: 1 1 100%; text-align: center; }
  .gU-nekoCol img { max-width: 240px; width: auto; }
  .gU-tenmeiGrid { grid-template-columns: 90px 1fr; }
  .gU-boxR::after, .gU-boxR::before { left: 60%; }
  /* 3列テーブルのままだと鑑定ボタンが入力欄と重なるため、
     ラベル+入力の2列グリッドに組み替え、ボタン(rowspanセル)は最下段へ回す */
  .gU-formTable { width: 100%; }
  .gU-formTable tbody { display: grid; grid-template-columns: max-content 1fr; gap: 0 6px; align-items: center; }
  .gU-formTable tr { display: contents; }
  .gU-formTable td { display: block; padding: 4px 0; }
  .gU-formTable td[rowspan] { grid-column: 1 / -1; order: 99; text-align: center; padding-top: 8px; }
  /* 入力3欄は横長になり過ぎるため固定幅(従来のおよそ半分)で統一 */
  .gU-formTable input[type="text"],
  .gU-formTable input[type="date"],
  .gU-formTable input[type="time"] { width: 130px; max-width: 100%; box-sizing: border-box; }
  .gU-formTable img { max-width: 160px; }
}


/* ---- シャドーカラー対応商品リンク (data/products.json にURLを入れると表示される) ---- */
.gU-shop { margin: 10px 0 4px; }
.gU-shopTitle { font-weight: bold; font-size: 14px; margin: 0 0 6px; color: #333; }
.gU-shopList { display: flex; flex-wrap: wrap; gap: 6px; }
.gU-shopItem { display: inline-flex; align-items: center; gap: 5px; padding: 4px 12px;
  border: 1px solid #c9a45c; border-radius: 15px; background: #fffdf5;
  text-decoration: none; color: #333; font-size: 13px; line-height: 1.4; }
.gU-shopItem:hover { background: #fff3d6; }
.gU-shopItem img { vertical-align: middle; }
.gU-shopNote { font-size: 11px; color: #888; margin: 6px 0 0; }