/* =========================
   お問い合わせフォーム 入力ページ専用CSS
========================= */

/* dl要素（ラベル＋必須と入力欄） */
.ec-borderedDefs dl {
    display: block;
    margin-bottom: 15px;
    width: 100%;
}

/* dtはラベルと必須マークを横並び、左端揃え */
.ec-borderedDefs dt {
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: bold;
    margin: 0 0 5px 0;
    padding: 0;
    width: 100%;
    box-sizing: border-box;
}

/* 必須マーク */
.ec-required {
    display: inline-block;
    background-color: #ff0000;
    color: #fff;
    font-size: 12px;
    padding: 2px 4px;
    border-radius: 2px;
}

/* ddは入力欄をラベルと左端揃え・幅最大に */
.ec-borderedDefs dd {
    margin: 0;
    padding: 0;
    width: 100%;
    box-sizing: border-box;
}

/* 半分入力欄（姓・名など） */
.ec-halfInput {
    display: flex;
    gap: 10px;
    width: 100%;
    box-sizing: border-box;
}

.ec-halfInput input {
    flex: 1;
    padding: 8px;
    font-size: 14px;
    box-sizing: border-box;
    min-width: 0;
}

.ec-halfInput.error input,
.ec-halfInput.error div input {
    border: 1px solid #ff0000;
}

/* 単独入力欄 */
.ec-input input,
.ec-input textarea {
    width: 100%;
    padding: 8px;
    font-size: 14px;
    box-sizing: border-box;
}

.ec-input.error input,
.ec-input.error textarea {
    border: 1px solid #ff0000;
}

.ec-input textarea {
    min-height: 100px;
    resize: vertical;
}

/* =========================
   モバイル表示調整（入力ページ）
========================= */
@media (max-width: 767px) {
    .ec-borderedDefs dl {
        display: block;
    }

    .ec-halfInput {
        flex-direction: column;
        gap: 10px;
    }

    .ec-halfInput input {
        width: 100%;
    }

    .ec-input input,
    .ec-input textarea {
        width: 100%;
    }

    .ec-borderedDefs dd p {
        width: 100%;
    }
}
