/* style.css */
body {
    background-color: #000000;
    color: white;
    font-family: 'Courier New', Courier, monospace;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    overflow: hidden; /* ブラウザ全体のスクロールバーを非表示 */
}

#console {
    width: 80%;
    height: 60vh;
    border: 2px solid #005500;
    padding: 20px;
    overflow-y: auto; /* コンソール内のスクロールは維持 */
    overflow-x: hidden; /* 横方向のバーを禁止 */
    background-color: #050505;
    position: relative;
    
    /* 画面全体のチカチカ（点滅ノイズ） */
    animation: flicker 0.2s infinite;
}

/* コンソール内のスクロールバーを隠す設定 */
#console::-webkit-scrollbar {
    display: none; /* Chrome, Safari 用 */
}
#console {
    -ms-overflow-style: none;  /* IE, Edge 用 */
    scrollbar-width: none;  /* Firefox 用 */
}

/* 文字のグロー（光彩）エフェクト */
#output, .input-line {
    text-shadow: 0 0 4px rgba(255, 255, 255, 0.8);
}

.input-line {
    display: flex;
    align-items: center;
    position: relative;
    white-space: pre;
}

/* 透明な入力欄 */
#command-input {
    position: absolute;
    left: 1ch; 
    background: transparent;
    border: none;
    color: transparent; 
    outline: none;
    font-family: inherit;
    font-size: 1rem;
    width: 100%;
    caret-color: transparent; 
    z-index: 5;
    text-shadow: none; 
    appearance: none;
}

/* 予測入力対策 */
#command-input:-webkit-autofill,
#command-input:-webkit-autofill:hover, 
#command-input:-webkit-autofill:focus {
    -webkit-text-fill-color: transparent;
    transition: background-color 5000s ease-in-out 0s;
}

/* 見える方の文字 */
#display-text {
    color: #ffffff;
}

/* 入力カーソルの点滅 */
#cursor {
    color: #ffffff;
    animation: blink 1s infinite;
}

@keyframes blink { 50% { opacity: 0; } }

/* チカチカ（チラツキ）を作るアニメーションの定義 */
@keyframes flicker {
    0% { opacity: 0.97; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.001); }
    100% { opacity: 0.98; transform: scale(1); }
}

/* 🟢 【新規】コンソール内に画像を100%綺麗に収める設定 */
.log-image-container {
    width: 100%;
    max-width: 400px; /* パソコン画面で画像が大きくなりすぎないように制限 */
    margin: 15px 0;
    display: block;
}

.console-image {
    width: 100%;
    height: auto;     /* 縦横比を崩さない */
    max-width: 100%;  /* コンソールの横幅を絶対にはみ出さない */
    border: 1px solid #005500; /* サイバー感を出すための暗い緑のフチ */
    box-shadow: 0 0 8px rgba(0, 85, 0, 0.5); /* ほんのり緑色に発光 */
}

.hidden-key {
    display: inline;
    font-weight: bold;
    text-shadow: 0 0 1px rgba(255, 255, 255, 0.3) !important;
}

/* style.css の最下部に上書きしてください */
@media screen and (max-width: 768px) {
    #console {
        /* スマホの画面を限界まで広く使うために余白を最小限に */
        padding: 10px; 
    }

    /* 🟢 通常の出力文字、警告メッセージなどをスマホでもズームされない限界の小ささ（16px）に一括固定 */
    #output, 
    .input-line, 
    .command-prompt {
        font-size: 16px !important; /* 👈 iPhoneのお節介ズームを完全に回避する魔法のサイズ */
        line-height: 1.4 !important;  
        
        /* 🟢 スマホでの指による文字の長押し・選択・コピペを強制的に100%許可します */
        -webkit-user-select: text !important; /* Safari (iPhone) 用 */
        -moz-user-select: text !important;    /* Firefox 用 */
        -ms-user-select: text !important;     /* IE/Edge 用 */
        user-select: text !important;         /* 標準設定 */
    }
    /* 🟢 ここから新規追加（別ブロック） */
    .color-000015 {
        color: #000015 !important;
    font-size: 12px;          /* iPhone が許す最小 */
    transform: scale(0.01);    
        line-height: 1.0;
    }

}
    /* 🟢 透明な入力欄も同じ文字サイズにピッタリ同期させて表示崩れを防止 */
    #command-input {
        font-size: 16px !important;
        line-height: 1.4 !important;
    }

    /* 入力欄をタップした瞬間もサイズを完全に16pxで固定 */
    #command-input:focus {
        font-size: 16px !important;
    }
    
    /* スマホの時は画像を横幅いっぱいにフィットさせる */
    .log-image-container {
        max-width: 100%;
    }