:root {
    --main-bg-color: #fff0f5;
    --accent-color: #ff69b4;
    --second-color: #f78da7;
}

body {
    font-family: 'Arial', sans-serif;
    font-size: 16px;
    background-color:var(--main-bg-color);
    margin: 0;
    padding: 20px;
    color: #333; /* 読みやすい文字色 */
}

.container {
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

#drop-area {
    border: 2px dashed var(--accent-color);
    border-radius: 10px;
    background-color: #ffffff; /* 背景色は白を維持 */
    padding: 20px;
    text-align: center;
    margin-bottom: 20px;
    box-shadow: 0 4px 8px rgba(255, 105, 180, 0.2); /* ピンク色の影を追加 */
}

.label {
    background-color: var(--accent-color);
    color: #ffffff;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    display: inline-block;
}

.button {
    background-color: #555;
    color: #ffffff;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    display: block;
    width: 100%;
    box-sizing: border-box;
    margin-top: 10px;
    box-shadow: 0 2px 4px rgba(50, 50, 50, 0.2);
    font-size: 16px;
}

@media (min-width: 769px) {
    .button {
        width: auto;
        display: inline-block;
    }
}

/* ホバーエフェクトをより洗練されたものに更新 */
.label:hover, .button:hover {
    opacity: 0.8;
}

.my-form p {
    margin: 10px 0;
}

input[type="file"] {
    display: none; /* デフォルトのファイル選択を非表示に */
}

#result {
    margin-top: 20px;
    padding: 15px;
    border-radius: 5px;
}

.result-container {
    text-align: center;
    padding: 20px;
    border-radius: 10px;
}

/* その他の要素も軽く調整 */
#result, .result-container {
    border: 1px solid var(--accent-color);
    box-shadow: 0 2px 4px rgba(255, 105, 180, 0.1);
    background-color: #ffffff;
}

.result-image {
    max-width: 80%;
    border-radius: 5px;
    margin-top: 10px;
}

#image-info-table-container {
    overflow-x: auto;
}

#image-info-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

#image-info-table th {
    background-color: var(--accent-color);
    color: white;
}

#image-info-table th, #image-info-table td {
    text-align: center;
    padding: 8px;
    border-bottom: 1px solid #ddd;
}

/* 奇数行と偶数行の背景色を軽く調整して読みやすく */
#image-info-table tr:nth-child(odd) {
    background-color: #ffffff;
}
#image-info-table tr:nth-child(even) {
    background-color: #ffffff;
}

#image-preview-container {
    text-align: center; /* 画像を中央に表示 */
    margin-bottom: 20px;
}

#image-preview {
    max-width: 100%;
    height: auto;
    display: block; /* ブロック要素として表示 */
    margin: auto; /* 上下のマージンはそのままで、左右のマージンを自動調整して中央揃え */
}

#info-section {
    margin-top: 20px;
    margin-bottom: 10px;
    text-align: center;
}

#info-section ul {
    padding-left: 20px;
}

#info-section h3 {
    color: #222; /* タイトル色 */
}

#info-content {
    display: none;
    text-align: left;
    padding: 10px;
    margin-top: 10px;
    background-color: #ffffff; /* 軽い背景色でセクションを目立たせる */
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1); /* ソフトな影で立体感を演出 */
}

#info-content ul {
    list-style-type: disc; /* リストにディスクマークを使用 */
    padding-left: 20px;
    font-size: 12px;
}

.info-note {
    font-size: 12px;
    margin-top: 10px;
    color: #555;
}

#info-button {
    background-color: #6c757d; /* 目立たないグレー色 */
    color: #ffffff; /* ボタンのテキスト色を白に */
    padding: 5px 10px; /* ボタンの高さを低く、フォントサイズを小さくする */
    font-size: 12px;
    border-radius: 5px; /* ボタンの角を丸く */
    border: 1px solid #6c757d; /* ボタンの枠線もグレーに */
    margin: 0 auto; /* 中央寄せ */
    display: block; /* ブロック要素として表示 */
    width: auto; /* デフォルトの幅 */
    cursor: pointer; /* カーソルをポインタに */
    box-shadow: none; /* 影を消す */
    transition: background-color 0.3s; /* 背景色の変更にアニメーションを使用 */
}

#info-button:hover {
    background-color: #5a6268; /* ホバー時に少し濃いグレーに */
}

.loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.7);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
}

#loading {
    display: none;
}

.spinner {
    border: 4px solid rgba(0,0,0,.1);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border-left-color: #09f;
    animation: spin 1s ease infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.links-container {
    display: flex;
    justify-content: center; /* 中央揃えに変更 */
    align-items: center;
    width: 100%;
    max-width: 600px;
    gap: 20px; /* ボタン間に余白を追加 */
    margin: 10px auto;
}

.link {
    background-color: #ddd; /* ボタンの色をグレーに変更 */
    color: #333; /* テキスト色を白に変更 */
    padding: 10px 10px;
    border-radius: 5px;
    text-decoration: none;
    transition: background-color 0.3s ease;
    flex-grow: 1; /* 各リンクが利用可能なスペースを均等に埋めるように */
    text-align: center; /* テキストを中央揃えに */
}

.link:hover {
    background-color: #333; /* ホバー時の色を濃いグレーに変更 */
}

/* 共通スタイル */
.heading {
    font-family: 'Arial', sans-serif;
    color: #333;
    text-align: center;
    margin-top: 20px;
    margin-bottom: 20px;
    font-weight: bold;
    background-color: var(--accent-color);
    color: #ffffff;
    padding: 10px 0;
    border-radius: 5px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    width: 80%;
    margin-left: auto;
    margin-right: auto;
}

h1.heading {
    font-size: 24px; /* 特有のフォントサイズ */
}

h2.heading {
    font-size: 20px; /* h2に適したサイズ */
    background-color: var(--second-color);
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .heading {
        padding: 8px 0;
        width: 90%;
    }

    h1.heading {
        font-size: 20px; /* 小さめの画面ではフォントサイズを小さく調整 */
    }

    h2.heading {
        font-size: 18px; /* h2に適した小さめのサイズ */
    }
}
