body {
    font-family: sans-serif;
    background-color: #f4f4f9;
    display: flex;
    justify-content: center;
    margin: 0;
}

/* 変換ツールの枠 */
.converter-box {
    background-color: #333;
    padding: 25px;
    border-radius: 16px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
    width: 100%;
    max-width: 320px;
    box-sizing: border-box;
    margin-top: 30px; 
    color: #fff;
}

.converter-box h2 {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 1.3rem;
    text-align: center;
    color: #f09a36;
}

.input-group {
    margin-bottom: 15px;
}

.input-group label {
    display: block;
    font-size: 0.85rem;
    color: #a5a5a5;
    margin-bottom: 5px;
}

/* 入力欄の外枠 */
.field-wrap, .field-wrap-wareki {
    display: flex;
    align-items: center;
    background-color: #222;
    border-radius: 8px;
    padding: 5px 10px;
}

/* ⚠️ プルダウン（select）のスタイル修正 */
.field-wrap select, .field-wrap-wareki select {
    background-color: #222; /* 背景を黒に固定 */
    border: none;
    color: #fff;
    font-size: 1.1rem;
    padding: 8px;
    width: 100%;
    box-sizing: border-box;
    outline: none;
    cursor: pointer;
    
    /* 矢印を絶対に消さないための標準設定 */
    display: inline-block;
}

/* プルダウンを開いた時の選択肢の背景 */
select option {
    background-color: #222;
    color: #fff;
}

/* 元号選択の横幅 */
#select-gengo {
    width: 45%;
    color: #f09a36;
    font-weight: bold;
}

/* 年選択の横幅 */
#select-wareki {
    width: 55%;
}

/* 結果表示エリア */
.result-area {
    background-color: #222;
    border-radius: 8px;
    padding: 15px;
    margin-top: 20px;
    margin-bottom: 15px;
}

.result-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.result-row:last-child {
    margin-bottom: 0;
}

.res-label {
    color: #a5a5a5;
    font-size: 0.9rem;
}

.res-val {
    font-size: 1.5rem;
    font-weight: bold;
    color: #fff;
}

.res-unit {
    font-size: 0.9rem;
    color: #a5a5a5;
    margin-left: 2px;
}

/* クリアボタン */
.clear-btn {
    width: 100%;
    height: 45px;
    background-color: #a5a5a5;
    color: #000;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: opacity 0.1s;
}

.clear-btn:active {
    opacity: 0.7;
}