.water-bg, .fire-bg, .grass-bg, .rock-bg, .thunder-bg {
    border: 5px solid #1a1a1a !important;
    border-radius: 20px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
    max-width: 600px;
    margin: 30px auto;
    padding: 0;
    overflow: hidden;
    position: relative;
    background-blend-mode: overlay;
    background-repeat: repeating-linear-gradient;
}

.fire-bg {
    background: 
        repeating-linear-gradient(45deg, rgba(211, 26, 56, 0.1) 0 50px, transparent 50px 100px),
        repeating-linear-gradient(-45deg, rgba(211, 26, 56, 0.1) 0 50px, transparent 50px 100px),
        linear-gradient(to bottom, #ff8c69 0%, #ffb399 40%, #ffffff 100%) !important;
}

.water-bg {
    background: 
        repeating-linear-gradient(45deg, rgba(26, 115, 211, 0.08) 0 50px, transparent 50px 100px),
        repeating-linear-gradient(-45deg, rgba(26, 115, 211, 0.08) 0 50px, transparent 50px 100px),
        linear-gradient(to bottom, #69c5ff 0%, #b3e0ff 40%, #ffffff 100%) !important;
}

.grass-bg {
    background: 
        repeating-linear-gradient(45deg, rgba(41, 211, 26, 0.05) 0 50px, transparent 50px 100px),
        repeating-linear-gradient(-45deg, rgba(41, 211, 26, 0.05) 0 50px, transparent 50px 100px),
        linear-gradient(to bottom, #a2e89d 0%, #d1f7d5 40%, #ffffff 100%) !important;
}

.rock-bg {
    background: 
        repeating-linear-gradient(45deg, rgba(194, 133, 75, 0.1) 0 50px, transparent 50px 100px),
        repeating-linear-gradient(-45deg, rgba(194, 133, 75, 0.1) 0 50px, transparent 50px 100px),
        linear-gradient(to bottom, #e3b98c 0%, #ebd3ba 40%, #ffffff 100%) !important;
}

.thunder-bg {
    background: 
        repeating-linear-gradient(45deg, rgba(211, 180, 26, 0.05) 0 50px, transparent 50px 100px),
        repeating-linear-gradient(-45deg, rgba(211, 180, 26, 0.05) 0 50px, transparent 50px 100px),
        linear-gradient(to bottom, #f3e595 0%, #fdf6d0 40%, #ffffff 100%) !important;
}

.card-header {
    background-color: #3b2c55; 
    background-image: 
        linear-gradient(45deg, rgba(0, 0, 0, 0.15) 25%, transparent 25%, transparent 75%, rgba(0, 0, 0, 0.15) 75%, rgba(0, 0, 0, 0.15)),
        linear-gradient(-45deg, rgba(0, 0, 0, 0.15) 25%, transparent 25%, transparent 75%, rgba(0, 0, 0, 0.15) 75%, rgba(0, 0, 0, 0.15));
    background-size: 30px 30px; 
    
    padding: 12px 20px;
    border-bottom: 4px solid #1a1a1a;
    display: flex;
    justify-content: space-between; 
    align-items: center;    
}

.card-title {
    font-size: 1.8em;
    font-weight: 900;
    color: #ffffff !important; 
    font-family: "Hiragino Sans", "Meiryo", sans-serif; 
    letter-spacing: 1px;
    
    text-shadow: 
        2px  2px 0px #1a1a1a,
       -2px  2px 0px #1a1a1a,
        2px -2px 0px #1a1a1a,
       -2px -2px 0px #1a1a1a,
        3px  0px 0px #1a1a1a,
       -3px  0px 0px #1a1a1a,
        0px  3px 0px #1a1a1a,
        0px -3px 0px #1a1a1a,
        3px  3px 3px rgba(0,0,0,0.8);
    transform: skewX(-8deg); 
    display: inline-block;
}

.card-icons {
    display: flex;
    gap: 8px;
    filter: drop-shadow(2px 2px 0px rgba(0,0,0,0.5));
}

.card-body {
    padding: 16px;
}

.info-section {
    background: #ffffff !important; 
    border: 1px dashed #bde0fe;    
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
}

.skill-panel {
    background: #ffffff !important;
    border: 1px solid #d0eaff;
    border-radius: 10px;
    padding: 10px;
    margin-top: 10px;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.05); 
    width: 100%;      
    box-sizing: border-box;
}
.skill-panel table {
    width: 100% !important; 
    table-layout: fixed;    
    word-wrap: break-word;  
    border-collapse: collapse;
}
.skill-panel td {
    padding: 8px !important;
    white-space: normal !important; 
    word-break: break-all !important; 
    overflow: visible !important;    
    line-height: 1.4;            
}
.skill-panel td:first-child {
    width: 60px; 
}

.main-visual-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 15px 0;
    box-sizing: border-box;
}

.range-dummy, .range-box {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
}

.range-box {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    height: 80px !important;
}

.range-grid {
    display: grid !important;
    grid-template-columns: repeat(5, 12px);
    grid-template-rows: repeat(5, 12px);
    gap: 1.5px;
    background: #333;
    padding: 3px;
    border-radius: 4px;
    border: 1px solid #000;
}

.r-cell { width: 12px; height: 12px; background: #555; border-radius: 1px; display: block; }
.r-c { background: #ff5722; border: 1px solid #fff; display: block; }
@-webkit-keyframes pulse-glow-yellow {
    0% {
        background: #ffeb3b;
        box-shadow: 0 0 3px #ffeb3b;
    }
    50% {
        background: #ffeb3b;
        box-shadow: 
            0 0 3px #ffeb3b,
            0 0 7px rgba(255, 235, 59, 0.6); 
    }
    100% {
        background: #ffeb3b;
        box-shadow: 0 0 3px #ffeb3b;
    }
}
@keyframes pulse-glow-yellow {
    0% {
        background: #ffeb3b;
        box-shadow: 0 0 3px #ffeb3b;
    }
    50% {
        background: #ffeb3b;
        box-shadow: 
            0 0 3px #ffeb3b,
            0 0 7px rgba(255, 235, 59, 0.6); 
    }
    100% {
        background: #ffeb3b;
        box-shadow: 0 0 3px #ffeb3b;
    }
}
.r-a { 
    display: block; 
    -webkit-animation: pulse-glow-yellow 1.5s infinite ease-in-out;
    animation: pulse-glow-yellow 1.5s infinite ease-in-out; 
}

@-webkit-keyframes pulse-glow-blue {
    0% {
        background: #2196f3;
        box-shadow: 0 0 3px #2196f3;
    }
    50% {
        background: #2196f3;
        box-shadow: 
            0 0 3px #2196f3,
            0 0 7px rgba(33, 150, 243, 0.6); 
    }
    100% {
        background: #2196f3;
        box-shadow: 0 0 3px #2196f3;
    }
}
@keyframes pulse-glow-blue {
    0% {
        background: #2196f3;
        box-shadow: 0 0 3px #2196f3;
    }
    50% {
        background: #2196f3;
        box-shadow: 
            0 0 3px #2196f3,
            0 0 7px rgba(33, 150, 243, 0.6); 
    }
    100% {
        background: #2196f3;
        box-shadow: 0 0 3px #2196f3;
    }
}
.r-b { 
    display: block; 
    -webkit-animation: pulse-glow-blue 1.5s infinite ease-in-out;
    animation: pulse-glow-blue 1.5s infinite ease-in-out; 
}
.range-label {
    font-size: 11px;
    font-weight: bold;
    color: #888;
    margin-bottom: 2px;
}

.r-note {
    font-size: 10px;
    line-height: 1.2;
    text-align: center;
    display: block;
    width: 140%;
    white-space: nowrap;
}

.x1 img {
    border: none !important;
    transition: opacity 0.2s, transform 0.2s;
}

.x1 a {
    -webkit-tap-highlight-color: transparent !important;
    outline: none !important;
}
.x1 a:active img {
    opacity: 0.8 !important;
    transform: scale(0.98) !important;
}

.x1 .atwiki-link-img-icon {
    display: none !important;
}

.cl, .cl a, .cl h1, .cl h2, .cl h3, .cl h1 a, .cl h2 a, .cl h3 a ,cl h4 a{
    font-size: 1.2em; 
    font-weight: 900;
    color: #ffffff !important; 
    font-family: "Hiragino Sans", "Meiryo", sans-serif;
    letter-spacing: 1px;
    text-decoration: none !important;
    display: inline-block;
    transform: skewX(-8deg);
    padding: 2px 5px;
    text-shadow: 
        1.5px 1.5px 0 #1a1a1a, -1.5px 1.5px 0 #1a1a1a,
        1.5px -1.5px 0 #1a1a1a, -1.5px -1.5px 0 #1a1a1a,
        2px 0 0 #1a1a1a, -2px 0 0 #1a1a1a,
        0 2px 0 #1a1a1a, 0 -2px 0 #1a1a1a,
        1px 2px 0 #1a1a1a, -1px 2px 0 #1a1a1a,
        1px -2px 0 #1a1a1a, -1px -2px 0 #1a1a1a,
        2px 1px 0 #1a1a1a, -2px 1px 0 #1a1a1a,
        2px -1px 0 #1a1a1a, -2px -1px 0 #1a1a1a,
        3px 3px 5px rgba(0,0,0,0.8);
}

.cl h1, .cl h2, .cl h3,cl h4 {
    margin: 0;
    padding: 0;
    border: none;
    background: none;
    line-height: 1.4;
}

.cl:hover, .cl a:hover, .cl h1:hover, .cl h2:hover, .cl h3:hover ,cl h4:hover{
    color: #ffffff !important;
    filter: brightness(1.2);
    transition: 0.2s;
}
.hidden { display: none; }

.MAX_table table {
    width: 100% !important;
    table-layout: auto; 
    word-wrap: break-word;
    border-collapse: collapse;
}

.MAX_table table td,
.MAX_table table th {
    width: 1px; 
    white-space: nowrap; 
    padding: 8px; 
}
.MAX_table table td:last-child,
.MAX_table table th:last-child {
    width: auto !important; 
    white-space: normal !important; 
    text-align: left;
}
.MAX_table table td {
    text-align: center !important;  
    vertical-align: middle !important; 
}

.sns-button-container {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 20px 0;
    justify-content: center;
}

.sns-btn {
    position: relative; 
    display: flex !important;
    flex-direction: column !important; 
    align-items: center !important;  
    justify-content: center !important; 
    padding: 15px 5px; 
    border-radius: 8px;
    background-color: #ffffff;
    border: 1px solid #ddd;
    box-sizing: border-box;
    transition: transform 0.2s, background-color 0.2s;
    flex: 1 1 calc(25% - 12px); 
    min-width: 110px;
    max-width: 160px; 
}

.sns-btn a::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    cursor: pointer;
}

.sns-btn img {
    margin: 0 0 8px 0 !important; 
    padding: 0 !important;
    display: block !important;
    vertical-align: top !important;
    border: none !important;
}

.sns-btn a {
    color: #333333 !important;
    text-decoration: none !important;
    font-weight: bold;
    font-size: 13px;
    line-height: 1 !important;
    position: static;
}

.sns-btn:hover {
    background-color: #f8f9fa; 
    transform: translateY(-2px);
    border-color: #bbb;
}

@media screen and (max-width: 768px) {
    .sns-btn {
        flex: 1 1 calc(50% - 12px) !important; 
        padding: 12px 5px;
    }
}

.sns-btn br { display: none !important; }

.btn-official  { border-bottom: 4px solid #2e7d32 !important; }
.btn-discord   { border-bottom: 4px solid #5865f2 !important; }
.btn-facebook  { border-bottom: 4px solid #0674e8 !important; }
.btn-instagram { border-bottom: 4px solid #d62976 !important; }
.btn-x         { border-bottom: 4px solid #111111 !important; }
.btn-youtube   { border-bottom: 4px solid #c4302b !important; }
.btn-reddit    { border-bottom: 4px solid #ff4500 !important; }

.hidden-data {
    display: none !important;
}

.evo-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 2px;
    margin-bottom: 15px;
}
.evo-table th {
    padding: 8px;
    font-size: 0.9em;
    color: #fff; 
}
.evo-table td {
    background-color: #fff !important;
    border: 1px solid #eee;
    text-align: center;
    padding: 10px 5px;
    vertical-align: top; /* 上揃えが綺麗です */
}

.skill-panel td:first-child {
    background-color: #4682b4 !important; 
    color: #fff !important;
    font-weight: bold;
    text-align: center !important;
    width: 70px !important;
}
.skill-panel td:last-child {
    background-color: #fff !important;
    text-align: left !important;
}

.info-section dl dt { font-weight: bold; color: #3b2c55; margin-top: 10px; border-left: 4px solid #3b2c55; padding-left: 8px; }
.info-section dl dd { margin: 5px 0 10px 12px; font-size: 0.95em; line-height: 1.5; }

.monster-template {
    opacity: 0;
    height: 0;
    overflow: hidden;
    transition: opacity 0.4s ease;
}
.monster-template.is-ready {
    opacity: 1;
    height: auto;
    overflow: visible;
}

h1{
    font-size: 30px !important;
    font-weight: 900 !important;
    font-family: "Hiragino Sans", "Meiryo", sans-serif !important;
    color: #ffffff !important;
    -webkit-text-stroke: 5px #1a1a1a;
    paint-order: stroke fill;
    text-shadow:
        3px 3px 6px rgba(0,0,0,.45);
    letter-spacing: 1px;
    display: inline-block !important;
    transform: skewX(-5deg);
    padding: 4px 12px;
    margin: 10px 0 !important;
    line-height: 1.15 !important;
    border: none !important;
    background: none !important;
}


.story-quote blockquote {
    font-size: 1rem; 
    line-height: 1.7; 
}

@media screen and (max-width: 480px) {
    .story-quote blockquote {
        font-size: 0.7rem; 
    }
}

.card-list-container table {
    width: 100% !important;
    max-width: 500px; 
    table-layout: fixed !important;
    border-collapse: collapse;
    margin-bottom: 15px;
}

.card-list-container td {
    width: 30% !important;
    text-align: center;
    vertical-align: top;
    padding: 6px 4px !important;
    font-size: 11px; 
    word-break: break-all; 
}

.card-list-container td img {
    width: 100% !important;
    height: auto !important;
}

.chip_table {
    width: 100% !important;
    max-width: 100% !important;
    display: block !important;
    overflow-x: auto; 
}

.chip_table table {
    width: 100% !important;
    min-width: 100% !important; 
    table-layout: auto; 
    word-wrap: break-word;
    word-break: break-all;
    border-collapse: collapse;
}

.chip_table table th,
.chip_table table td {
    width: 1% !important; 
    white-space: nowrap; 
    padding: 8px 6px; 
    vertical-align: middle !important;
    text-align: center !important;  
}

.chip_table table th:nth-child(2),
.chip_table table td:nth-child(2) {
    width: 98% !important; 
    white-space: normal !important; 
    text-align: left !important;
}

@media screen and (max-width: 768px) {
    .chip_table table th:first-child,
    .chip_table table td:first-child {
        width: 30% !important;
        max-width: 30% !important;
        white-space: normal !important; 
    }


    .chip_table table td:first-child img {
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
    }

    .chip_table table th:nth-child(2),
    .chip_table table td:nth-child(2) {
        width: 69% !important;
    }

    .chip_table table th:nth-child(3),
    .chip_table table td:nth-child(3) {
        width: 1% !important;
    }
}
@media screen and (min-width: 769px) {
    .chip_table table th:first-child,
    .chip_table table td:first-child {
        width: 100px !important;    
        max-width: 100px !important;
    }

    .chip_table table td:first-child img {
        width: 94px !important;    
        height: auto !important;
    }
}

.gif-walker {
    width: 100%;
    overflow: hidden; 
    white-space: nowrap;
    position: relative;
    height: 60px; 
}

.gif-walker img {
    position: absolute;
    left: -100px; 
    animation: walkRight 8s linear infinite; 
}

@keyframes walkRight {
    0% {
        left: -100px; 
    }
    100% {
        left: 100%; 
    }
}
.xscroll {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 15px 0;
  padding-bottom: 15px;
}

/* region内のラッパーを横並びにする */
.xscroll .regionhtml {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: flex-start;
  gap: 20px;
  min-width: max-content;
}

/* 各ユニオンのブロック */
.xscroll-card {
  display: inline-block;
  width: 280px;
  vertical-align: top;
  white-space: normal; /* テキストの折り返しを維持 */
}

/* テーブル幅の固定 */
.xscroll-card table {
  width: 100% !important;
  max-width: 280px !important;
  table-layout: fixed;
}

/* 
  ★ タイトル以外の、カード内のすべての基本文字（テーブル、進化先、説明文など）を
  　 カードの太い黒枠に負けない極太フォントに変更します。
*/
.water-bg *:not(.card-title), 
.fire-bg *:not(.card-title), 
.grass-bg *:not(.card-title), 
.rock-bg *:not(.card-title), 
.thunder-bg *:not(.card-title) {
    font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Meiryo", sans-serif !important;
    font-weight: 900 !important; 
    letter-spacing: 0.03em !important;
}
/* 
  ★ カード内の「太字（''文字''で囲んだ部分）」だけをさらに目立たせる
*/
.water-bg strong, .water-bg b,
.fire-bg strong, .fire-bg b,
.grass-bg strong, .grass-bg b,
.rock-bg strong, .rock-bg b,
.thunder-bg strong, .thunder-bg b {
    font-size: 1.15em !important;           
    display: inline-block !important;  
    margin-bottom: 4px !important;    
}
.monster-list-table {
    margin-left: auto !important;
    margin-right: auto !important;
    display: table !important; /* 環境によってズレるのを防ぐおまじない */
}
.monster-list-table td:nth-child(1) img,
    .monster-list-table td:nth-child(2) img {
        max-width: 100% !important; 
        width: 14vw !important; 
        height: auto !important;
    }
.monster-list-table td:nth-child(4) img,
.monster-list-table td:nth-child(5) img {
     max-width: 100% !important; 
        width: 7vw !important;
        height: auto !important;
}
.monster-list-table td:nth-child(5) {
        font-size: 12px !important;   
        line-height: 1.2 !important;   
        letter-spacing: -0.5px !important; 
        padding: 4px 2px !important;   
    }
@media screen and (min-width: 1024px) {
    .monster-list-table td:nth-child(1) img,
    .monster-list-table td:nth-child(2) img {
        width: 130px !important; 
    }
    .monster-list-table td:nth-child(4) img,
    .monster-list-table td:nth-child(5) img {
        width: 50px !important;  
    }
}
.evo_table_wrap {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling:
}

.evo_table_wrap table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border-radius: 12px !important;
}