/* =========================
   フォーム全体
========================= */
.page-bg-inner {
    position: relative;
    z-index: 5;
}

.form-box {
    display: flex;
    justify-content: center;
    width: 100%;
    z-index: 10;
    margin-top: 30px;
}

form {
    width: 400px;
    max-width: 90%;
    margin: 0 auto 60px;
    padding: 24px 22px;
    border-radius: 12px;

    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);

    box-shadow:
        0 2px 10px rgba(232, 156, 167, 0.6),
        0 0 0 1px rgba(255, 255, 255, 0.6);
    opacity: 0.95;
}

/* フォーム行 */
.form-row {
    margin: 18px 0;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    font-size: 0.95rem;
    color: #5a3a4a;
}

.form-row label {
    font-size: 1.05rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: rgba(150, 80, 170, 0.9);
    text-shadow: 0 1px 3px rgba(255, 255, 255, 0.7);
}

.form-row input {
    width: 60%;
    height: 6px;
    padding: 20px 16px;
    font-size: 0.95rem;
    border-radius: 6px;
    border: 1px solid #E89CA7;
}

.form-row input:focus {
    border-color: #E89CA7;
    background-color: #fff8fa;
    outline: none;
}

/* ページリード文 */
.page-lead {
    margin-top: 12px;
    margin-bottom: 40px;
    font-size: 1rem;
    color: #5a3a4a;
    line-height: 1.5;
}

/* =========================
   ボタン
========================= */
button {
    border-radius: 10px;
    border: 1px solid #fff;
    background: linear-gradient(135deg, #a78bfa, #f472b6);
    font-size: 1rem;
    font-weight: 500;
    color: #fff;
    width: 140px;
    height: 44px;
    margin-top: 30px;

    transition: all 0.3s ease;
}

button:hover {
    background: linear-gradient(135deg, #f472b6, #a78bfa);
    transform: translateY(-2px);
}

/* single_uranai_form.php専用css */
.fortune-button {
    width: 100%;
    display: flex;
    justify-content: center;
    /* 中央配置 */
    gap: 4%;
    /* 余白も割合 */
    flex-wrap: wrap;
    /* 狭い画面で折り返し */
}

.fortune-bt {
    width: 40%;
    /* 割合指定 */
    display: flex;
    justify-content: center;
    /* button中央 */
}


.fortune-bt button {
    width: 100%;
}

.single_uranai_form {
    width: 600px;
}



/* =========================
   カスタムセレクト（birth/gender）
========================= */
.custom-select {
    position: relative;
    width: 60%;
    user-select: none;
    cursor: pointer;
    border: 1px solid #E89CA7;
    border-radius: 4px;
    background: #fff;
    padding: 4px 12px 30px;
    font-size: 0.95rem;
    height: 28px;
    line-height: 28px;
}

.custom-select .selected {
    position: relative;
    padding-right: 24px;
}

.custom-select .selected::after {
    content: '↴';
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.85rem;
    font-weight: bold;
    color: #333;
    pointer-events: none;
}

.custom-select .options {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    border: 1px solid #E89CA7;
    border-top: none;
    background: #ffeff1;
    max-height: 150px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
}

.custom-select .option {
    padding: 8px 12px;
    font-size: 0.9rem;
    border-bottom: 1px solid #E89CA7;
}

.custom-select .option:hover {
    background: #ffc8d0;
}

@media(max-width:767px) {

    .page-bg-inner {
        padding-top: 40px;
        text-align: center;
    }

    .page-bg-inner h1 {
        margin-bottom: 12px;
    }

    .page-bg-inner p.page-lead {
        font-size: 4vw;
        margin-bottom: 8%;
    }

    form {
        width: 95%;
        padding: 8% 6%;
        border-radius: 14px;
    }

    .form-row {
        flex-direction: column;
        align-items: flex-start;
        margin: 4% 0;
    }

    .form-row label {
        font-size: 4vw;
        margin-bottom: 2%;
    }

    .form-row input,
    .custom-select {
        width: 100%;
        height: auto;
        font-size: 3.5vw;
        padding: 3% 4%;
    }

    .custom-select .options {
        max-height: 40vw;
    }

    .touroku-login-button button {
        width: 70%;
        font-size: 4vw;
        height: auto;
        padding: 4% 0;
        margin-top: 8%;
    }
}

@media(max-width:530px) {

    .fortune-button {
        margin-top: 40px;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }

    .fortune-bt {
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .fortune-bt button {
        width: 70%;
        margin: 0;
    }
}

@media(max-width:400px) {
    form {
        width: 100%;
        max-width: 100%;
    }
}