@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@700&display=swap');

/* 清除瀏覽器預設樣式 + 觸控優化 */
* {
    margin: 0;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    padding: 0;
    box-sizing: border-box;
}

/* 整個網頁 */
body {
    min-height: 100vh;
    font-family: "Microsoft JhengHei", Arial, sans-serif;
    color: #444;
    background: linear-gradient(
        135deg,
        #ffd6e4,
        #ffafc7,
        #f98fb2
    );
}

/* 上方導覽列 */
.navbar {
    height: 75px;
    padding: 0 7%;
    display: flex;
    align-items: center;
    justify-content: space-between;

    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(10px);

    position: relative;
    z-index: 10;

    box-shadow: 0 3px 20px rgba(135, 35, 75, 0.08);
}

/* 網站名稱 */
.logo {
    display: flex;
    align-items: center;
    gap: 10px;

    color: #ef3f78;
    font-size: 25px;
    font-weight: bold;
}

/* Logo 愛心 */
.heart-logo {
    font-size: 37px;
    line-height: 1;
}

/* 導覽列連結 */
.nav-links {
    display: flex;
    gap: 35px;
}

.nav-links a {
    color: #555;
    text-decoration: none;
    font-size: 16px;
    transition: 0.25s;
}

.nav-links a:hover {
    color: #ef3f78;
}

/* 首頁主要區域 */
.hero {
    min-height: calc(100vh - 75px);

    display: flex;
    justify-content: center;
    align-items: center;

    padding: 40px 20px;

    position: relative;
    overflow: hidden;
}

/* 中間白色卡片 */
.welcome-card {
    width: 100%;
    max-width: 570px;

    padding: 55px 60px;

    text-align: center;

    background: rgba(255, 255, 255, 0.9);

    border: 1px solid rgba(255, 255, 255, 0.7);
    border-radius: 30px;

    backdrop-filter: blur(15px);

    box-shadow:
        0 25px 70px rgba(125, 25, 65, 0.2);

    position: relative;
    z-index: 2;
}

/* 卡片上面的愛心 */
.main-heart {
    width: 82px;
    height: 82px;

    margin: 0 auto 18px;

    display: flex;
    align-items: center;
    justify-content: center;

    color: white;
    font-size: 41px;

    border-radius: 50%;

    background: linear-gradient(
        135deg,
        #ff7aa6,
        #ed2869
    );

    box-shadow: 0 12px 25px rgba(239, 63, 120, 0.3);
}

/* MyDating 標題 */
.welcome-card h1 {
    color: #ed3e76;
    font-size: 54px;
    margin-bottom: 10px;
}

/* 中文標語 */
.welcome-card h2 {
    color: #555;
    font-size: 25px;
    font-weight: 500;
    margin-bottom: 18px;
}

/* 說明文字 */
.description {
    color: #777;
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 32px;
}

/* 按鈕區域 */
.button-area {
    display: flex;
    gap: 16px;
}

/* 兩個按鈕共用設定 */
.main-button {
    flex: 1;

    height: 58px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 999px;

    text-decoration: none;
    font-size: 19px;
    font-weight: bold;

    transition: 0.25s;
}

/* 登入按鈕 */
.login-button {
    color: white;

    background: linear-gradient(
        90deg,
        #2d4a3e,
        #ff6595
    );

    box-shadow: 0 10px 25px rgba(237, 63, 119, 0.3);
}

.login-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 28px rgba(237, 63, 119, 0.4);
}

/* 免費註冊按鈕 */
.register-button {
    color: #2d4a3e;
    background: white;
    border: 2px solid #2d4a3e;
}

.register-button:hover {
    color: white;
    background: #2d4a3e;
    transform: translateY(-3px);
}

/* 安全文字 */
.security-text {
    margin-top: 30px;
    color: #888;
    font-size: 14px;
}

/* 背景飄浮愛心 */
.heart {
    position: absolute;
    color: rgba(255, 255, 255, 0.55);

    animation: floating 4s ease-in-out infinite;

    user-select: none;
}

.heart-one {
    top: 13%;
    left: 10%;
    font-size: 75px;
}

.heart-two {
    top: 23%;
    right: 12%;
    font-size: 55px;
    animation-delay: 0.7s;
}

.heart-three {
    bottom: 12%;
    left: 18%;
    font-size: 45px;
    animation-delay: 1.4s;
}

.heart-four {
    bottom: 18%;
    right: 18%;
    font-size: 80px;
    animation-delay: 2s;
}

/* 愛心上下移動動畫 */
@keyframes floating {
    0% {
        transform: translateY(0) rotate(-6deg);
    }

    50% {
        transform: translateY(-18px) rotate(6deg);
    }

    100% {
        transform: translateY(0) rotate(-6deg);
    }
}

/* 平板與手機 */
@media screen and (max-width: 700px) {

    .navbar {
        height: auto;
        padding: 18px 24px;
    }

    .nav-links {
        display: none;
    }

    .hero {
        min-height: calc(100vh - 68px);
    }

    .welcome-card {
        max-width: 420px;
        padding: 42px 25px;
    }

    .welcome-card h1 {
        font-size: 42px;
    }

    .welcome-card h2 {
        font-size: 21px;
    }

    .button-area {
        flex-direction: column;
    }

    .main-button {
        flex: none;
        width: 100%;
    }
}/* 登入、註冊頁面 */
.form-page {
    min-height: calc(100vh - 75px);

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 40px 20px;

    background:
        radial-gradient(
            circle at top left,
            rgba(255, 255, 255, 0.45),
            transparent 35%
        ),
        linear-gradient(
            135deg,
            #ffd8e6,
            #ff9fbe
        );
}

.form-card {
    width: 100%;
    max-width: 460px;

    padding: 45px;

    background: rgba(255, 255, 255, 0.94);

    border-radius: 28px;

    text-align: center;

    box-shadow:
        0 25px 70px rgba(130, 30, 70, 0.2);
}

.small-heart {
    width: 65px;
    height: 65px;

    margin: 0 auto 18px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    color: white;
    font-size: 31px;

    background: linear-gradient(
        135deg,
        #ff739f,
        #ed326f
    );
}

.form-card h1 {
    color: #2d4a3e;
    font-size: 36px;
    margin-bottom: 8px;
}

.form-description {
    color: #777;
    margin-bottom: 30px;
}

.input-group {
    margin-bottom: 19px;
    text-align: left;
}

.input-group label {
    display: block;
    margin-bottom: 8px;

    color: #555;
    font-weight: bold;
}

.input-group input {
    width: 100%;
    height: 55px;

    padding: 0 16px;

    border: 1px solid #dddddd;
    border-radius: 13px;

    background: #fafafa;

    font-size: 16px;
    outline: none;

    transition: 0.2s;
}

.input-group input:focus {
    border-color: #2d4a3e;
    background: white;

    box-shadow:
        0 0 0 4px rgba(237, 63, 119, 0.1);
}

.login-options {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin: 5px 0 25px;

    font-size: 14px;
}

.remember-box {
    display: flex;
    align-items: center;
    gap: 7px;

    color: #666;
}

.forgot-link {
    color: #2d4a3e;
    text-decoration: none;
}

.submit-button {
    width: 100%;
    height: 57px;

    border: none;
    border-radius: 999px;

    color: white;
    font-size: 19px;
    font-weight: bold;

    cursor: pointer;

    background: linear-gradient(
        90deg,
        #2d4a3e,
        #ff6595
    );

    box-shadow:
        0 10px 25px rgba(237, 63, 119, 0.3);

    transition: 0.25s;
}

.submit-button:hover {
    transform: translateY(-2px);
}

.form-message {
    min-height: 24px;
    margin-top: 14px;

    color: #d42f61;
    font-size: 14px;
}

.form-footer {
    margin-top: 18px;
    color: #777;
}

.form-footer a {
    color: #2d4a3e;
    font-weight: bold;
    text-decoration: none;
}

.logo {
    text-decoration: none;
}.agreement {
    display: flex;
    align-items: center;
    gap: 8px;

    margin: 5px 0 25px;

    color: #666;
    font-size: 14px;
    text-align: left;
}

.agreement input {
    width: auto;
    height: auto;
}/* 登入後會員首頁 */

.dashboard-body {
    min-height: 100vh;
    background: #fff5f8;
}

.dashboard-navbar {
    min-height: 75px;

    padding: 0 7%;

    display: flex;
    align-items: center;
    justify-content: space-between;

    background: white;

    box-shadow:
        0 4px 20px rgba(120, 30, 70, 0.08);
}

.dashboard-logo {
    color: #2d4a3e;

    font-size: 26px;
    font-weight: bold;

    text-decoration: none;
}

.dashboard-user {
    display: flex;
    align-items: center;
    gap: 18px;
}

.user-name {
    color: #555;
    font-weight: bold;
}

.logout-button {
    border: 1px solid #2d4a3e;
    border-radius: 999px;

    padding: 9px 19px;

    color: #2d4a3e;
    background: white;

    font-size: 15px;
    cursor: pointer;

    transition: 0.2s;
}

.logout-button:hover {
    color: white;
    background: #2d4a3e;
}

.dashboard-main {
    width: 100%;
    max-width: 1150px;

    margin: 0 auto;
    padding: 55px 24px;
}

.welcome-section {
    margin-bottom: 35px;
}

.welcome-section h1 {
    color: #2d4a3e;
    font-size: 38px;
    margin-bottom: 8px;
}

.welcome-section p {
    color: #777;
    font-size: 17px;
}

.dashboard-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 22px;
}

.dashboard-card {
    min-height: 210px;

    padding: 30px;

    display: flex;
    flex-direction: column;
    justify-content: center;

    color: #444;
    text-decoration: none;

    background: white;

    border: 1px solid #f4dce5;
    border-radius: 22px;

    box-shadow:
        0 10px 30px rgba(100, 25, 60, 0.07);

    transition: 0.25s;
}

.dashboard-card:hover {
    transform: translateY(-7px);

    border-color: #23723a;

    box-shadow:
        0 18px 35px rgba(150, 35, 80, 0.13);
}

.card-icon {
    margin-bottom: 18px;
    font-size: 42px;
}

.dashboard-card h2 {
    margin-bottom: 10px;

    color: #2d4a3e;
    font-size: 23px;
}

.dashboard-card p {
    color: #777;
    line-height: 1.7;
}

@media screen and (max-width: 900px) {

    .dashboard-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }
}

@media screen and (max-width: 600px) {

    .dashboard-navbar {
        padding: 16px 20px;
    }

    .dashboard-user {
        gap: 10px;
    }

    .user-name {
        display: none;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-main {
        padding: 35px 18px;
    }

    .welcome-section h1 {
        font-size: 30px;
    }
}/* 討論區選擇頁 */

.forum-body {
    min-height: 100vh;
    background:
        linear-gradient(
            135deg,
            #fff4f8,
            #ffe4ee
        );
}

.forum-main {
    width: 100%;
    max-width: 1100px;

    margin: 0 auto;
    padding: 55px 24px;
}

.forum-title {
    text-align: center;
    margin-bottom: 35px;
}

.forum-title h1 {
    color: #2d4a3e;
    font-size: 38px;
    margin-bottom: 10px;
}

.forum-title p {
    color: #777;
    font-size: 17px;
}

.forum-grid {
    display: grid;
    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 22px;
}

.forum-card {
    min-height: 155px;

    padding: 25px;

    display: flex;
    align-items: center;
    gap: 22px;

    color: #444;
    text-decoration: none;

    background: rgba(255, 255, 255, 0.94);

    border: 1px solid #f4dce5;
    border-radius: 22px;

    box-shadow:
        0 10px 30px rgba(110, 25, 65, 0.08);

    transition: 0.25s;
}

.forum-card:hover {
    transform: translateY(-6px);

    border-color: #ed82a7;

    box-shadow:
        0 18px 35px rgba(145, 35, 80, 0.14);
}

.forum-icon {
    width: 72px;
    height: 72px;

    flex-shrink: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 20px;

    background: #fff0f5;

    font-size: 36px;
}

.forum-card h2 {
    color: #2d4a3e;
    margin-bottom: 7px;
    font-size: 22px;
}

.forum-card p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 8px;
}

.forum-card span {
    color: #999;
    font-size: 13px;
}

.back-button {
    color: #2d4a3e;
    text-decoration: none;

    padding: 9px 17px;

    border: 1px solid #2d4a3e;
    border-radius: 999px;
}

.back-button:hover {
    color: white;
    background: #2d4a3e;
}

@media screen and (max-width: 750px) {

    .forum-grid {
        grid-template-columns: 1fr;
    }

    .forum-main {
        padding: 35px 18px;
    }

    .forum-card {
        min-height: 140px;
    }
}/* ===========================
   Members Page
=========================== */

.members-body{
    background:#f7f8fc;
    font-family:"Microsoft JhengHei",sans-serif;
}

.members-main{
    width:90%;
    max-width:1200px;
    margin:40px auto;
}

.members-title{
    text-align:center;
    margin-bottom:35px;
}

.members-title h1{
    font-size:38px;
    color:#ff4d88;
    margin-bottom:10px;
}

.members-title p{
    color:#666;
    font-size:18px;
}

.search-box{
    background:#fff;
    padding:30px;
    border-radius:18px;
    box-shadow:0 8px 25px rgba(0,0,0,.08);
    margin-bottom:40px;
}

.search-row{
    display:flex;
    gap:20px;
    margin-bottom:20px;
}

.search-item{
    flex:1;
    display:flex;
    flex-direction:column;
}

.search-item label{
    margin-bottom:8px;
    font-weight:bold;
    color:#444;
}

.search-item select,
.search-item input{
    padding:13px;
    border:1px solid #ddd;
    border-radius:10px;
    font-size:16px;
}

.search-item select:focus,
.search-item input:focus{
    outline:none;
    border-color:#ff4d88;
}

.search-button{
    width:100%;
    padding:15px;
    border:none;
    background:#ff4d88;
    color:white;
    border-radius:12px;
    font-size:18px;
    cursor:pointer;
    transition:.3s;
}

.search-button:hover{
    background:#ff2d72;
}

.result-title{
    margin:40px 0 25px;
    color:#333;
}

.member-grid{
    display:grid;
    grid-template-columns:repeat(auto-fill,minmax(260px,1fr));
    gap:25px;
}

.member-card{
    background:#fff;
    border-radius:18px;
    overflow:hidden;
    box-shadow:0 8px 25px rgba(0,0,0,.08);
    transition:.3s;
}

.member-card:hover{
    transform:translateY(-8px);
}

.member-photo{
    width:100%;
    height:320px;
    object-fit:cover;
    filter:blur(10px);
    transition:.3s;
}

.member-card:hover .member-photo{
    filter:blur(8px);
}

.member-card h3{
    padding:15px 20px 5px;
    color:#ff4d88;
}

.member-card p{
    padding:3px 20px;
    color:#666;
}

.view-button{
    display:block;
    margin:20px;
    text-align:center;
    background:#ff4d88;
    color:white;
    text-decoration:none;
    padding:12px;
    border-radius:10px;
    transition:.3s;
}

.view-button:hover{
    background:#ff2d72;
}

@media(max-width:768px){

.search-row{
    flex-direction:column;
}

.members-title h1{
    font-size:30px;
}

.member-photo{
    height:280px;
}

}/* ===========================
   Member Detail
=========================== */

.detail-body{
    background:#f7f8fc;
}

.detail-main{
    width:90%;
    max-width:1100px;
    margin:50px auto;
}

.detail-card{
    background:white;
    border-radius:20px;
    overflow:hidden;
    display:flex;
    gap:40px;
    padding:30px;
    box-shadow:0 10px 30px rgba(0,0,0,.08);
}

.detail-photo{
    width:360px;
    border-radius:15px;
    object-fit:cover;
    filter:blur(12px);
}

.detail-info{
    flex:1;
}

.detail-info h1{
    color:#ff4d88;
    margin-bottom:20px;
}

.detail-info p{
    margin:12px 0;
    color:#555;
    line-height:1.8;
}

.tags{
    display:flex;
    flex-wrap:wrap;
    gap:10px;
    margin:15px 0 25px;
}

.tags span{
    background:#ffe4ee;
    color:#ff4d88;
    padding:8px 15px;
    border-radius:30px;
}

.intro{
    margin-top:10px;
}

.button-group{
    display:flex;
    gap:20px;
    margin-top:35px;
}

.unlock-btn,
.like-btn{
    flex:1;
    border:none;
    padding:15px;
    font-size:17px;
    border-radius:12px;
    cursor:pointer;
}

.unlock-btn{
    background:#ffb347;
    color:white;
}

.like-btn{
    background:#ff4d88;
    color:white;
}

.unlock-btn:hover{
    background:#f7a623;
}

.like-btn:hover{
    background:#ff2d72;
}

@media(max-width:900px){

.detail-card{
    flex-direction:column;
}

.detail-photo{
    width:100%;
}

.button-group{
    flex-direction:column;
}

}/* ===========================
   Profile
=========================== */

.profile-body{
    background:#f5f7fb;
}

.profile-main{
    width:90%;
    max-width:1100px;
    margin:40px auto;
}

.profile-card{
    background:white;
    border-radius:20px;
    padding:35px;
    display:flex;
    gap:40px;
    box-shadow:0 10px 25px rgba(0,0,0,.08);
}

.profile-left{
    width:280px;
    text-align:center;
}

.profile-avatar{
    width:220px;
    height:220px;
    border-radius:50%;
    object-fit:cover;
    margin-bottom:20px;
}

.profile-right{
    flex:1;
}

.profile-row{
    display:flex;
    gap:20px;
}

.profile-group{
    display:flex;
    flex-direction:column;
    flex:1;
    margin-bottom:18px;
}

.profile-group label{
    font-weight:bold;
    margin-bottom:8px;
}

.profile-group input,
.profile-group select,
.profile-group textarea{
    padding:12px;
    border:1px solid #ddd;
    border-radius:10px;
    font-size:16px;
}

.save-btn{
    width:100%;
    border:none;
    padding:15px;
    border-radius:12px;
    background:#ff4d88;
    color:white;
    font-size:18px;
    cursor:pointer;
}

.save-btn:hover{
    background:#ff2d72;
}

@media(max-width:900px){

.profile-card{
    flex-direction:column;
}

.profile-left{
    width:100%;
}

.profile-avatar{
    width:180px;
    height:180px;
}

.profile-row{
    flex-direction:column;
}

}/* ===========================
   Notification
=========================== */

.notification-body{
    background:#f5f7fb;
}

.notification-main{
    width:90%;
    max-width:900px;
    margin:40px auto;
}

.notification-main h1{
    color:#ff4d88;
    margin-bottom:25px;
}

.notification-card{
    background:#fff;
    display:flex;
    gap:20px;
    align-items:center;
    padding:20px;
    border-radius:15px;
    margin-bottom:20px;
    box-shadow:0 5px 15px rgba(0,0,0,.08);
}

.notification-icon{
    width:60px;
    height:60px;
    background:#ffe4ee;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    font-size:28px;
}

.notification-card h3{
    margin-bottom:8px;
    color:#333;
}

.notification-card p{
    color:#666;
}

.notification-card span{
    font-size:13px;
    color:#999;
}/* ===========================
   Setting
=========================== */

.setting-body{
    background:#f5f7fb;
}

.setting-main{
    width:90%;
    max-width:700px;
    margin:40px auto;
}

.setting-main h1{
    color:#ff4d88;
    margin-bottom:25px;
}

.setting-card{
    background:white;
    padding:30px;
    border-radius:20px;
    box-shadow:0 8px 20px rgba(0,0,0,.08);
}

.setting-card label{
    display:block;
    margin-top:20px;
    margin-bottom:8px;
    font-weight:bold;
}

.setting-card input,
.setting-card select{
    width:100%;
    padding:12px;
    border:1px solid #ddd;
    border-radius:10px;
    font-size:16px;
}/* ===========================
   Chat Room
=========================== */

.chat-body{
    background:#f5f7fb;
}

.chat-main{
    width:95%;
    max-width:1400px;
    margin:30px auto;
    display:flex;
    gap:20px;
    height:80vh;
}

.chat-sidebar{
    width:320px;
    background:white;
    border-radius:20px;
    padding:20px;
    box-shadow:0 8px 20px rgba(0,0,0,.08);
    overflow:auto;
}

.chat-sidebar h2{
    color:#ff4d88;
    margin-bottom:20px;
}

.chat-user{
    display:flex;
    gap:15px;
    align-items:center;
    padding:15px;
    border-radius:12px;
    cursor:pointer;
    margin-bottom:10px;
}

.chat-user:hover,
.chat-user.active{
    background:#ffe4ee;
}

.chat-user img{
    width:55px;
    height:55px;
    border-radius:50%;
}

.chat-content{
    flex:1;
    background:white;
    border-radius:20px;
    display:flex;
    flex-direction:column;
    box-shadow:0 8px 20px rgba(0,0,0,.08);
}

.chat-header{
    display:flex;
    align-items:center;
    gap:15px;
    padding:20px;
    border-bottom:1px solid #eee;
}

.chat-header img{
    width:60px;
    height:60px;
    border-radius:50%;
}

.messages{
    flex:1;
    padding:20px;
    overflow:auto;
}

.message{
    max-width:70%;
    padding:12px 18px;
    border-radius:18px;
    margin-bottom:15px;
}

.left{
    background:#f1f1f1;
}

.right{
    background:#ff4d88;
    color:white;
    margin-left:auto;
}

.chat-input{
    display:flex;
    gap:15px;
    padding:20px;
    border-top:1px solid #eee;
}

.chat-input input{
    flex:1;
    padding:14px;
    border:1px solid #ddd;
    border-radius:12px;
}

.chat-input button{
    background:#ff4d88;
    color:white;
    border:none;
    padding:14px 30px;
    border-radius:12px;
    cursor:pointer;
}

.chat-input button:hover{
    background:#ff2d72;
}

@media(max-width:900px){

.chat-main{
    flex-direction:column;
    height:auto;
}

.chat-sidebar{
    width:100%;
}

}
/* ==================================================
   MyDating 會員共用版型
   左側固定選單＋會員專屬首頁
================================================== */

/* 整個會員頁背景 */
.member-shell-body {
    min-height: 100vh;
    margin: 0;
    color: #555;
    background:
        linear-gradient(
            180deg,
            #f7f8f7 0,
            #f7f8f7 26px,
            #ffffff 26px,
            #ffffff 100%
        );
}

/* 左右整體結構 */
.member-shell {
    width: min(1180px, calc(100% - 40px));
    min-height: 100vh;
    margin: 0 auto;
    padding: 42px 0 60px;

    display: grid;
    grid-template-columns: 210px minmax(0, 1fr);
    gap: 42px;
}

/* ==================================================
   左側會員選單
================================================== */

.member-sidebar {
    align-self: start;
    min-height: 650px;

    background: #ffffff;
    border: 1px solid #eeeeee;

    position: sticky;
    top: 25px;

    box-shadow: 0 6px 22px rgba(110, 70, 85, 0.04);
}

/* 頭像區 */
.sidebar-top {
    padding: 28px 20px 24px;
    text-align: center;
}

.sidebar-avatar {
    width: 105px;
    height: 105px;

    display: block;
    margin: 0 auto 13px;

    object-fit: cover;

    border-radius: 2px;
    background: #f1f1f1;
}

.sidebar-top h3 {
    margin: 0;

    color: #444;
    font-size: 17px;
    font-weight: 500;
}

.sidebar-top::after {
    content: "";

    display: block;
    width: 100%;
    height: 1px;

    margin-top: 24px;

    background: #eeeeee;
}

/* 選單 */
.sidebar-menu {
    padding: 6px 15px 22px;

    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sidebar-item {
    min-height: 48px;
    padding: 0 8px;

    display: flex;
    align-items: center;
    gap: 12px;

    color: #555;
    text-decoration: none;

    border-radius: 8px;

    transition:
        background 0.2s,
        color 0.2s,
        transform 0.2s;
}

.sidebar-item:hover {
    color: #ea668d;
    background: #fff2f6;
    transform: translateX(3px);
}

.sidebar-icon {
    width: 25px;

    display: inline-flex;
    justify-content: center;

    filter: grayscale(1);
    opacity: 0.55;

    font-size: 19px;
}

.sidebar-item:hover .sidebar-icon {
    filter: none;
    opacity: 1;
}

.sidebar-text {
    flex: 1;

    font-size: 16px;
}

.sidebar-badge {
    min-width: 22px;
    height: 22px;
    padding: 0 6px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    color: #ffffff;
    background: #ee1010;

    border-radius: 999px;

    font-size: 12px;
    font-weight: 700;
}

/* ==================================================
   右側主要內容
================================================== */

.member-content {
    min-width: 0;
}

/* 頁面標題 */
.member-page-header {
    margin-bottom: 20px;
    padding: 8px 4px 18px;

    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;

    border-bottom: 1px solid #e8a1b4;
}

.member-page-kicker {
    margin: 0 0 7px;

    color: #b9b9b9;
    font-size: 12px;
    letter-spacing: 2px;
}

.member-page-header h1 {
    margin: 0 0 8px;

    color: #e65d86;
    font-size: 28px;
}

.member-page-header > div > p:last-child {
    margin: 0;

    color: #888;
    line-height: 1.7;
}

.role-badge {
    flex-shrink: 0;

    padding: 8px 16px;

    color: #155c2a;
    background: #fff1f5;

    border: 1px solid #f1b3c5;
    border-radius: 999px;

    font-size: 14px;
}

/* 驗證提示 */
.verification-alert {
    margin-bottom: 17px;
    padding: 15px 18px;

    display: flex;
    align-items: center;
    gap: 11px;

    background: #fff3f5;

    border-radius: 9px;
}

.verification-alert span {
    font-size: 18px;
}

.verification-alert p {
    flex: 1;
    margin: 0;

    color: #765d64;
    font-size: 14px;
}

.verification-alert a {
    color: #e2537c;
    text-decoration: none;
    font-weight: 700;
}

/* ==================================================
   會員資訊卡
================================================== */

.member-summary-card {
    padding: 20px;

    background:
        linear-gradient(
            135deg,
            #ffb8c2,
            #ffcdd3
        );

    border: 1px solid #c5d8c8;
    border-radius: 15px;

    box-shadow: 0 10px 28px rgba(217, 93, 128, 0.12);
}

/* 上方會員資訊 */
.summary-profile {
    margin-bottom: 16px;

    display: flex;
    align-items: center;
    gap: 16px;
}

.summary-profile img {
    width: 76px;
    height: 76px;

    object-fit: cover;

    border: 4px solid rgba(255, 255, 255, 0.85);
    border-radius: 50%;

    background: #ffffff;
}

.summary-name-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.summary-name-row h2 {
    margin: 0;

    color: #493c40;
    font-size: 22px;
}

.summary-profile p {
    margin: 7px 0 0;

    color: #a3576d;
    font-size: 14px;
}

.mini-vip-badge {
    padding: 4px 9px;

    color: #995568;
    background: rgba(255, 255, 255, 0.65);

    border-radius: 5px;

    font-size: 12px;
}

.mini-vip-badge.is-vip {
    color: #ffffff;
    background:
        linear-gradient(
            90deg,
            #c88c36,
            #efc96d
        );
}

/* 狀態卡 */
.summary-status-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.summary-status-grid article {
    min-height: 115px;
    padding: 18px 15px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;

    background: rgba(255, 255, 255, 0.62);

    border: 8px solid rgba(255, 255, 255, 0.22);
    border-radius: 10px;
}

.summary-status-grid article span {
    margin-bottom: 10px;

    color: #664b53;
    font-size: 14px;
}

.summary-status-grid article strong {
    margin-bottom: 11px;

    color: #aa7f8b;
    font-size: 14px;
    font-weight: 500;
}

.summary-status-grid article a {
    padding: 7px 16px;

    color: #ffffff;
    background:
        linear-gradient(
            180deg,
            #ffb0bd,
            #e88295
        );

    border-radius: 6px;

    text-decoration: none;
    font-size: 13px;

    box-shadow: 0 4px 10px rgba(201, 91, 122, 0.16);
}

/* ==================================================
   聊天室與留言板快捷列
================================================== */

.dashboard-shortcuts {
    margin-top: 14px;

    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));

    border: 1px solid #2d5a3e;
    border-radius: 8px;
    overflow: hidden;

    background: #fff8fa;
}

.dashboard-shortcuts a {
    min-height: 44px;
    padding: 0 20px;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    color: #555;
    text-decoration: none;
}

.dashboard-shortcuts a:first-child {
    border-right: 1px solid #2d5a3e;
}

.dashboard-shortcuts a:hover {
    color: #e2537c;
    background: #fff0f5;
}

.dashboard-shortcuts b {
    font-size: 12px;
}

/* ==================================================
   內容區塊
================================================== */

.dashboard-section {
    margin-top: 35px;
}

.section-heading {
    margin-bottom: 17px;

    display: flex;
    align-items: flex-end;
    justify-content: space-between;

    border-bottom: 1px solid #e9a5b7;
}

.section-heading p {
    margin: 0 0 4px;

    color: #c3a3ab;
    font-size: 11px;
    letter-spacing: 2px;
}

.section-heading h2 {
    display: inline-block;
    margin: 0;
    padding: 0 0 8px;

    color: #e46087;
    font-size: 21px;

    border-bottom: 3px solid #e46087;
}

/* 功能卡 */
.dashboard-feature-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.dashboard-feature-card {
    min-height: 110px;
    padding: 20px;

    display: flex;
    align-items: center;
    gap: 17px;

    color: #555;
    text-decoration: none;

    background:
        linear-gradient(
            180deg,
            #ffbbc8,
            #fa668b
        );

    border-radius: 9px;

    box-shadow: 0 7px 17px rgba(227, 84, 125, 0.14);

    transition:
        transform 0.2s,
        box-shadow 0.2s;
}

.dashboard-feature-card:hover {
    transform: translateY(-4px);

    box-shadow: 0 12px 24px rgba(227, 84, 125, 0.22);
}

.dashboard-feature-card .feature-icon {
    width: 63px;
    height: 63px;
    flex-shrink: 0;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    color: #ffffff;
    background: rgba(255, 255, 255, 0.25);

    border-radius: 13px;

    font-size: 30px;
}

.dashboard-feature-card h3 {
    margin: 0 0 7px;

    color: #ffffff;
    font-size: 18px;
}

.dashboard-feature-card p {
    margin: 0;

    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
    font-size: 14px;
}

.vip-feature-card {
    background:
        linear-gradient(
            135deg,
            #f4adbc,
            #e785a2
        );
}

/* hidden屬性確實隱藏 */
.gender-feature-section[hidden] {
    display: none;
}

/* ==================================================
   手機選單按鈕與遮罩
================================================== */

.mobile-menu-button {
    display: none;

    position: fixed;
    top: 12px;
    left: 18px;
    z-index: 1050;

    width: 40px;
    height: 40px;

    color: #ffffff;
    background: #155c2a;

    border: none;
    border-radius: 50%;

    font-size: 20px;
    cursor: pointer;

    box-shadow: 0 7px 18px rgba(21, 92, 42, 0.25);
}

.sidebar-overlay {
    display: none;

    position: fixed;
    inset: 0;
    z-index: 1000;

    background: rgba(42, 32, 36, 0.35);
}

.sidebar-overlay.show {
    display: block;
}

/* ==================================================
   平板版
================================================== */

@media screen and (max-width: 920px) {

    .member-shell {
        width: min(100% - 30px, 850px);

        grid-template-columns: 185px minmax(0, 1fr);
        gap: 24px;
    }

    .summary-status-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-feature-grid {
        grid-template-columns: 1fr;
    }
}

/* ==================================================
   手機版
================================================== */

@media screen and (max-width: 700px) {

    .member-shell-body {
        background:
            linear-gradient(
                180deg,
                #f7f8f7 0,
                #f7f8f7 18px,
                #ffffff 18px,
                #ffffff 100%
            );
    }

    .member-shell {
        width: 100%;
        padding: 78px 16px 40px;

        display: block;
    }

    .mobile-menu-button {
        display: block;
    }

    .member-sidebar {
        width: 260px;
        height: 100vh;
        min-height: 0;

        position: fixed;
        top: 0;
        left: -280px;
        z-index: 1100;

        overflow-y: auto;

        border: none;

        transition: left 0.25s ease;
    }

    .member-sidebar.show {
        left: 0;
    }

    .sidebar-open .mobile-menu-button {
        display: none !important;
    }

    .member-page-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .member-page-header h1 {
        font-size: 25px;
    }

    .verification-alert {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .verification-alert a {
        width: 100%;
        padding-left: 29px;
    }

    .member-summary-card {
        padding: 15px;
    }

    .summary-profile {
        align-items: flex-start;
    }

    .summary-profile img {
        width: 64px;
        height: 64px;
    }

    .summary-status-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-shortcuts {
        grid-template-columns: 1fr;
    }

    .dashboard-shortcuts a:first-child {
        border-right: none;
        border-bottom: 1px solid #2d5a3e;
    }

    .dashboard-feature-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-feature-card {
        min-height: 100px;
        padding: 17px;
    }
}

/* ==================================================
   小螢幕
================================================== */

@media screen and (max-width: 430px) {

    .summary-profile {
        flex-direction: column;
    }

    .dashboard-feature-card {
        align-items: flex-start;
    }

    .dashboard-feature-card .feature-icon {
        width: 54px;
        height: 54px;

        font-size: 25px;
    }
}/* ==================================================
   左側選單 Firebase 資料補充樣式
================================================== */

.sidebar-avatar-link {
    display: block;
    width: fit-content;
    margin: 0 auto;
    text-decoration: none;
}

.sidebar-member-meta {
    margin-top: 10px;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}

.sidebar-vip-status,
.sidebar-gender-status {
    padding: 4px 8px;

    color: #999;
    background: #f5f5f5;

    border-radius: 999px;

    font-size: 11px;
}

.sidebar-vip-status.is-vip {
    color: #8a641c;
    background: linear-gradient(
        135deg,
        #fff0b7,
        #e9c46b
    );
}

.sidebar-profile-link {
    display: inline-block;
    margin-top: 12px;

    color: #db6687;
    text-decoration: none;
    font-size: 12px;
}

.sidebar-profile-link:hover {
    text-decoration: underline;
}

/* 目前所在頁面反白 */
.sidebar-item.active {
    color: #e45e86;
    background: #fff0f5;

    font-weight: 700;
}

.sidebar-item.active .sidebar-icon {
    filter: none;
    opacity: 1;
}

/* VIP 選單 */
.sidebar-vip-item {
    color: #b78328;
}

.sidebar-vip-item .sidebar-icon {
    color: #c9993c;
    filter: none;
    opacity: 1;
}

/* 登出按鈕 */
.sidebar-logout-button {
    width: 100%;
    background: rgba(255, 255, 255, 0.10) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.16) !important;
    border-radius: 10px;
    font-family: inherit;
    text-align: left;
    cursor: pointer;
}

.sidebar-logout-button .sidebar-icon,
.sidebar-logout-button .sidebar-text {
    color: inherit !important;
}

.sidebar-logout-button:hover,
.sidebar-logout-button:focus-visible {
    background: rgba(255, 255, 255, 0.20) !important;
    color: #ffffff !important;
    outline: none;
}

.sidebar-logout-button:active {
    background: rgba(0, 0, 0, 0.16) !important;
}

.sidebar-logout-button:disabled {
    cursor: wait;
    opacity: 0.65;
}

/* 手機選單開啟時避免背景滾動 */
body.sidebar-open {
    overflow: hidden;
}/* ==================================================
   MyDating 個人資料頁
================================================== */

/* 系統訊息 */
.profile-message {
    margin-bottom: 18px;
    padding: 14px 18px;

    border-radius: 9px;

    font-size: 14px;
    line-height: 1.6;
}

.profile-message[hidden] {
    display: none;
}

.profile-message.loading {
    color: #8b6f77;
    background: #fff4f7;
    border: 1px solid #c5d8c8;
}

.profile-message.success {
    color: #39734d;
    background: #eefaf2;
    border: 1px solid #b9dfc4;
}

.profile-message.error {
    color: #a13d50;
    background: #fff0f2;
    border: 1px solid #efb5c0;
}


/* ==================================================
   個人資料完成度
================================================== */

.profile-progress-card {
    margin-bottom: 26px;
    padding: 22px 24px;

    background:
        linear-gradient(
            135deg,
            #fff5f8,
            #ffffff
        );

    border: 1px solid #f0ccd6;
    border-radius: 14px;

    box-shadow: 0 8px 25px rgba(210, 94, 128, 0.08);
}

.profile-progress-info {
    margin-bottom: 16px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.profile-progress-kicker {
    margin: 0 0 5px;

    color: #c39ca7;
    font-size: 11px;
    letter-spacing: 2px;
}

.profile-progress-info h2 {
    margin: 0 0 5px;

    color: #dc6487;
    font-size: 20px;
}

.profile-progress-info p:last-child {
    margin: 0;

    color: #929292;
    font-size: 14px;
}

.profile-progress-info strong {
    flex-shrink: 0;

    color: #e35e86;
    font-size: 28px;
}

.profile-progress-track {
    width: 100%;
    height: 11px;

    overflow: hidden;

    background: #f3e4e9;

    border-radius: 999px;
}

.profile-progress-bar {
    width: 0;
    height: 100%;

    background:
        linear-gradient(
            90deg,
            #f5a0b8,
            #e55f87
        );

    border-radius: inherit;

    transition: width 0.35s ease;
}


/* ==================================================
   個人資料表單
================================================== */

.profile-form {
    display: flex;
    flex-direction: column;
    gap: 26px;
}

.profile-form-section {
    padding: 25px;

    background: #ffffff;

    border: 1px solid #eeeeee;
    border-radius: 13px;

    box-shadow: 0 7px 24px rgba(83, 58, 67, 0.05);
}

.profile-form-section .section-heading {
    margin-bottom: 24px;
}

.profile-form-section .section-heading h2 {
    font-size: 20px;
}


/* ==================================================
   頭像與基本資料配置
================================================== */

.profile-basic-layout {
    display: grid;
    grid-template-columns: 210px minmax(0, 1fr);
    gap: 30px;
    align-items: start;
}

.profile-avatar-panel {
    text-align: center;
}

.profile-avatar-preview {
    width: 180px;
    height: 180px;

    margin: 0 auto 15px;

    position: relative;
    overflow: hidden;

    background: #f5f5f5;

    border: 5px solid #fff2f6;
    border-radius: 15px;

    box-shadow: 0 7px 20px rgba(200, 87, 120, 0.13);
}

.profile-avatar-preview img {
    width: 100%;
    height: 100%;

    display: block;
    object-fit: cover;
}

.profile-avatar-loading {
    position: absolute;
    inset: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    color: #ffffff;
    background: rgba(77, 52, 61, 0.65);

    font-size: 14px;
    font-weight: 700;
}

.profile-avatar-loading[hidden] {
    display: none;
}

.profile-upload-button {
    min-height: 42px;
    padding: 0 17px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    color: #ffffff;
    background:
        linear-gradient(
            180deg,
            #23723a,
            #e25f87
        );

    border-radius: 8px;

    font-size: 14px;
    font-weight: 700;
    cursor: pointer;

    box-shadow: 0 5px 13px rgba(216, 83, 122, 0.18);

    transition:
        transform 0.2s,
        box-shadow 0.2s;
}

.profile-upload-button:hover {
    transform: translateY(-2px);

    box-shadow: 0 8px 17px rgba(216, 83, 122, 0.24);
}

.profile-upload-hint {
    margin: 12px auto 0;

    max-width: 190px;

    color: #999;
    font-size: 12px;
    line-height: 1.7;
}


/* ==================================================
   表單欄位
================================================== */

.profile-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.profile-field {
    min-width: 0;

    display: flex;
    flex-direction: column;
    gap: 8px;
}

.profile-field-full {
    grid-column: 1 / -1;
}

.profile-field > label {
    color: #60565a;
    font-size: 14px;
    font-weight: 700;
}

.profile-field > label span {
    color: #e75f86;
}

.profile-field input,
.profile-field select,
.profile-field textarea {
    width: 100%;

    color: #555;
    background: #ffffff;

    border: 1px solid #dddddd;
    border-radius: 8px;

    font-family: inherit;
    font-size: 14px;

    outline: none;

    transition:
        border-color 0.2s,
        box-shadow 0.2s,
        background 0.2s;
}

.profile-field input,
.profile-field select {
    height: 45px;
    padding: 0 13px;
}

.profile-field textarea {
    min-height: 110px;
    padding: 13px;

    resize: vertical;
    line-height: 1.7;
}

.profile-field input::placeholder,
.profile-field textarea::placeholder {
    color: #b7b7b7;
}

.profile-field input:focus,
.profile-field select:focus,
.profile-field textarea:focus {
    border-color: #e884a1;

    box-shadow: 0 0 0 4px rgba(232, 132, 161, 0.12);
}

.profile-field input[readonly] {
    color: #999;
    background: #f7f7f7;
    cursor: not-allowed;
}

.profile-input-unit {
    position: relative;
}

.profile-input-unit input {
    padding-right: 48px;
}

.profile-input-unit > span {
    position: absolute;
    top: 50%;
    right: 14px;

    color: #999;

    transform: translateY(-50%);
}


/* ==================================================
   自我介紹文字計數
================================================== */

.profile-text-counter {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;

    color: #aaa;
    font-size: 12px;
    line-height: 1.5;
}

.profile-text-counter span:last-child {
    flex-shrink: 0;

    color: #d87894;
}


/* ==================================================
   隱私開關
================================================== */

.profile-switch-list {
    display: flex;
    flex-direction: column;
    gap: 13px;
}

.profile-switch-item {
    min-height: 76px;
    padding: 15px 18px;

    position: relative;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;

    background: #fff9fb;

    border: 1px solid #f1dde3;
    border-radius: 10px;

    cursor: pointer;

    transition:
        border-color 0.2s,
        background 0.2s;
}

.profile-switch-item:hover {
    background: #fff4f7;
    border-color: #eeb7c6;
}

.profile-switch-item > div {
    min-width: 0;

    display: flex;
    flex-direction: column;
    gap: 5px;
}

.profile-switch-item strong {
    color: #5f5458;
    font-size: 14px;
}

.profile-switch-item > div span {
    color: #999;
    font-size: 13px;
    line-height: 1.5;
}

.profile-switch-item input {
    width: 1px;
    height: 1px;

    position: absolute;

    opacity: 0;
    pointer-events: none;
}

.profile-switch-control {
    width: 48px;
    height: 27px;
    flex-shrink: 0;

    position: relative;

    background: #cccccc;

    border-radius: 999px;

    transition: background 0.25s;
}

.profile-switch-control::after {
    content: "";

    width: 21px;
    height: 21px;

    position: absolute;
    top: 3px;
    left: 3px;

    background: #ffffff;

    border-radius: 50%;

    box-shadow: 0 2px 5px rgba(50, 50, 50, 0.2);

    transition: transform 0.25s;
}

.profile-switch-item input:checked +
.profile-switch-control {
    background:
        linear-gradient(
            90deg,
            #ef9db5,
            #155c2a
        );
}

.profile-switch-item input:checked +
.profile-switch-control::after {
    transform: translateX(21px);
}

.profile-switch-item input:focus-visible +
.profile-switch-control {
    box-shadow: 0 0 0 4px rgba(232, 132, 161, 0.2);
}


/* ==================================================
   表單底部按鈕
================================================== */

.profile-form-actions {
    padding: 21px 0 5px;

    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 13px;
}

.profile-cancel-button,
.profile-save-button {
    min-height: 46px;
    padding: 0 23px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border-radius: 8px;

    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;

    cursor: pointer;

    transition:
        transform 0.2s,
        box-shadow 0.2s,
        background 0.2s;
}

.profile-cancel-button {
    color: #777;
    background: #ffffff;

    border: 1px solid #dcdcdc;
}

.profile-cancel-button:hover {
    color: #dc6487;
    border-color: #e6a2b5;
    background: #fff7f9;
}

.profile-save-button {
    color: #ffffff;
    background:
        linear-gradient(
            180deg,
            #23723a,
            #dd5b83
        );

    border: none;

    box-shadow: 0 6px 15px rgba(213, 76, 116, 0.2);
}

.profile-save-button:hover {
    transform: translateY(-2px);

    box-shadow: 0 9px 20px rgba(213, 76, 116, 0.27);
}

.profile-save-button:disabled {
    opacity: 0.65;
    cursor: wait;
    transform: none;
}


/* ==================================================
   個人資料頁平板版
================================================== */

@media screen and (max-width: 950px) {

    .profile-basic-layout {
        grid-template-columns: 170px minmax(0, 1fr);
        gap: 22px;
    }

    .profile-avatar-preview {
        width: 150px;
        height: 150px;
    }

}


/* ==================================================
   個人資料頁手機版
================================================== */

@media screen and (max-width: 700px) {

    .profile-progress-card,
    .profile-form-section {
        padding: 19px;
    }

    .profile-progress-info {
        align-items: flex-start;
    }

    .profile-progress-info strong {
        font-size: 23px;
    }

    .profile-basic-layout {
        display: block;
    }

    .profile-avatar-panel {
        margin-bottom: 28px;
    }

    .profile-avatar-preview {
        width: 170px;
        height: 170px;
    }

    .profile-form-grid {
        grid-template-columns: 1fr;
    }

    .profile-field-full {
        grid-column: auto;
    }

    .profile-text-counter {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    .profile-form-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .profile-cancel-button,
    .profile-save-button {
        width: 100%;
    }

}


/* ==================================================
   個人資料頁小螢幕
================================================== */

@media screen and (max-width: 430px) {

    .profile-progress-info {
        flex-direction: column;
        gap: 12px;
    }

    .profile-form-section {
        padding: 16px;
    }

    .profile-switch-item {
        align-items: flex-start;
    }

    .profile-switch-control {
        margin-top: 3px;
    }

}/* ==================================================
   MyDating 會員瀏覽頁
================================================== */

/* 篩選區 */
.members-filter-card {
    margin-bottom: 26px;
    padding: 22px 24px;

    background: #ffffff;

    border: 1px solid #eeeeee;
    border-radius: 14px;

    box-shadow: 0 8px 24px rgba(87, 57, 68, 0.05);
}

.members-filter-grid {
    display: grid;
    grid-template-columns: 1.6fr repeat(3, 1fr);
    gap: 18px;
}

.members-filter-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.members-filter-field label {
    color: #65595e;
    font-size: 14px;
    font-weight: 700;
}

.members-filter-field input,
.members-filter-field select {
    width: 100%;
    height: 44px;
    padding: 0 13px;

    color: #555;
    background: #ffffff;

    border: 1px solid #dddddd;
    border-radius: 8px;

    font-family: inherit;
    font-size: 14px;

    outline: none;

    transition:
        border-color 0.2s,
        box-shadow 0.2s;
}

.members-filter-field input::placeholder {
    color: #b4b4b4;
}

.members-filter-field input:focus,
.members-filter-field select:focus {
    border-color: #e783a0;

    box-shadow:
        0 0 0 4px rgba(231, 131, 160, 0.12);
}

.members-filter-actions {
    margin-top: 18px;

    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.members-reset-button,
.members-search-button {
    min-height: 43px;
    padding: 0 20px;

    border-radius: 8px;

    font-family: inherit;
    font-size: 14px;
    font-weight: 700;

    cursor: pointer;

    transition:
        transform 0.2s,
        box-shadow 0.2s,
        background 0.2s;
}

.members-reset-button {
    color: #777;
    background: #ffffff;

    border: 1px solid #d9d9d9;
}

.members-reset-button:hover {
    color: #dd6486;
    background: #fff7f9;
    border-color: #e5a4b6;
}

.members-search-button {
    color: #ffffff;

    background:
        linear-gradient(
            180deg,
            #23723a,
            #155c2a
        );

    border: none;

    box-shadow:
        0 6px 15px rgba(215, 79, 119, 0.2);
}

.members-search-button:hover {
    transform: translateY(-2px);

    box-shadow:
        0 9px 20px rgba(215, 79, 119, 0.26);
}


/* ==================================================
   訊息提示
================================================== */

.members-message {
    margin-bottom: 22px;
    padding: 14px 18px;

    color: #8b6f77;
    background: #fff4f7;

    border: 1px solid #f0bfcd;
    border-radius: 9px;

    font-size: 14px;
}

.members-message[hidden] {
    display: none;
}


/* ==================================================
   會員卡片格線
================================================== */

.members-grid {
    display: grid;
    grid-template-columns:
        repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.member-card {
    min-width: 0;
    overflow: hidden;

    background: #ffffff;

    border: 1px solid #ececec;
    border-radius: 16px;

    box-shadow:
        0 10px 28px rgba(73, 46, 57, 0.08);

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        border-color 0.25s ease;
}

.member-card:hover {
    transform: translateY(-6px);

    border-color: #efb4c4;

    box-shadow:
        0 16px 34px rgba(76, 42, 55, 0.13);
}


/* ==================================================
   會員圖片
================================================== */

.member-card-image {
    width: 100%;
    aspect-ratio: 4 / 5;

    position: relative;
    overflow: hidden;

    background: #f1f1f1;
}

.member-card-image img {
    width: 100%;
    height: 100%;

    display: block;
    object-fit: cover;

    transition: transform 0.35s ease;
}

.member-card:hover .member-card-image img {
    transform: scale(1.04);
}

.member-card-image::after {
    content: "";

    position: absolute;
    inset: auto 0 0 0;
    height: 35%;

    pointer-events: none;

    background:
        linear-gradient(
            180deg,
            rgba(0, 0, 0, 0),
            rgba(0, 0, 0, 0.35)
        );
}

.member-card-goal {
    position: absolute;
    right: 13px;
    bottom: 13px;
    z-index: 1;

    max-width: calc(100% - 26px);
    padding: 7px 11px;

    color: #ffffff;
    background: rgba(21, 92, 42, 0.92);

    border: 1px solid rgba(255, 255, 255, 0.45);
    border-radius: 999px;

    font-size: 12px;
    font-weight: 700;

    backdrop-filter: blur(5px);
}


/* ==================================================
   會員卡片內容
================================================== */

.member-card-body {
    padding: 19px;
}

.member-card-title {
    margin-bottom: 8px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.member-card-title h2 {
    margin: 0;

    min-width: 0;

    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;

    display: flex;
    align-items: center;
    gap: 7px;

    color: #155c2a;
    font-size: 21px;
}

/* 搜尋會員卡片：名字旁的線上狀態圓點 */
.member-card-title .member-online-dot {
    display: inline-block !important;
    width: 10px;
    height: 10px;
    min-width: 10px;
    flex: 0 0 10px !important;
    margin: 0 !important;
    border-radius: 50%;
    background: #e55353 !important;
    box-shadow: 0 0 0 2px #ffffff, 0 0 0 3px rgba(229, 83, 83, 0.22);
}

.member-card-title .member-online-dot.is-online {
    background: #20b860 !important;
    box-shadow: 0 0 0 2px #ffffff, 0 0 0 3px rgba(32, 184, 96, 0.22);
}

.member-card-title .member-online-dot.is-offline {
    background: #e55353 !important;
}

.member-card-title span {
    flex-shrink: 0;

    color: #8a7e82;
    font-size: 13px;
}

.member-card-location,
.member-card-job,
.member-card-intro {
    margin: 0;
}

.member-card-location {
    margin-bottom: 5px;

    color: #8c7d82;
    font-size: 13px;
}

.member-card-location::before {
    content: "⌖";
    margin-right: 5px;

    color: #155c2a;
}

.member-card-job {
    margin-bottom: 13px;

    color: #746a6e;
    font-size: 13px;
}

.member-card-job::before {
    content: "▣";
    margin-right: 6px;

    color: #2d5a3e;
}

.member-card-intro {

    min-height: 66px;
    margin-bottom: 17px;

    display: -webkit-box;
    overflow: hidden;

    line-clamp: 3;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;

    color: #8a8587;
    font-size: 13px;
    line-height: 1.7;

}

.member-card-button {
    width: 100%;
    min-height: 43px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    color: #ffffff;

    background:
        linear-gradient(
            180deg,
            #23723a,
            #155c2a
        );

    border-radius: 8px;

    font-size: 14px;
    font-weight: 700;
    text-decoration: none;

    box-shadow:
        0 6px 14px rgba(21, 92, 42, 0.19);

    transition:
        transform 0.2s,
        box-shadow 0.2s;
}

.member-card-button:hover {
    transform: translateY(-2px);

    box-shadow:
        0 9px 18px rgba(21, 92, 42, 0.27);
}


/* ==================================================
   沒有會員資料
================================================== */

.members-empty {
    padding: 60px 25px;

    text-align: center;

    background: #ffffff;

    border: 1px solid #eeeeee;
    border-radius: 14px;

    box-shadow:
        0 8px 24px rgba(87, 57, 68, 0.05);
}

.members-empty[hidden] {
    display: none;
}

.members-empty-icon {
    width: 72px;
    height: 72px;

    margin: 0 auto 18px;

    display: flex;
    align-items: center;
    justify-content: center;

    color: #e36a8c;
    background: #fff0f4;

    border-radius: 50%;

    font-size: 34px;
}

.members-empty h2 {
    margin: 0 0 9px;

    color: #155c2a;
    font-size: 20px;
}

.members-empty p {
    margin: 0;

    color: #999;
    font-size: 14px;
}


/* ==================================================
   平板版
================================================== */

@media screen and (max-width: 1100px) {

    .members-filter-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .members-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

}


/* ==================================================
   手機版
================================================== */

@media screen and (max-width: 700px) {

    .members-filter-card {
        padding: 18px;
    }

    .members-filter-grid {
        grid-template-columns: 1fr;
    }

    .members-filter-actions {
        flex-direction: column-reverse;
    }

    .members-reset-button,
    .members-search-button {
        width: 100%;
    }

    .members-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .member-card-body {
        padding: 10px;
    }

    .member-card-title h2 {
        font-size: 14px;
    }

    .member-card-title span {
        font-size: 11px;
    }

    .member-card-location,
    .member-card-job {
        font-size: 11px;
    }

    .member-card-intro {
        font-size: 11px;
        min-height: 40px;
        margin-bottom: 10px;
    }

    .member-card-button {
        min-height: 34px;
        font-size: 12px;
    }

}/* =========================================
   VIP PAGE
========================================= */

.vip-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 120px;
    padding: 10px 18px;

    border: 1px solid #e8dfe2;
    border-radius: 999px;

    background: #ffffff;
    color: #8a8587;

    font-size: 14px;
    font-weight: 700;
}

.vip-status-badge.active {
    border-color: #e7c66a;

    background: linear-gradient(
        135deg,
        #fff9dc,
        #f7df94
    );

    color: #79570b;
}

.vip-hero {
    position: relative;
    overflow: hidden;

    margin-bottom: 32px;
    padding: 64px 40px;

    border-radius: 28px;

    background:
        radial-gradient(
            circle at top right,
            rgba(255, 255, 255, 0.45),
            transparent 38%
        ),
        linear-gradient(
            135deg,
            #fff3bf,
            #e9c96f,
            #d8a944
        );

    box-shadow: 0 20px 50px rgba(160, 119, 26, 0.18);
}

.vip-hero::before {
    content: "";

    position: absolute;
    top: -80px;
    right: -60px;

    width: 260px;
    height: 260px;

    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
}

.vip-hero::after {
    content: "";

    position: absolute;
    right: 100px;
    bottom: -120px;

    width: 220px;
    height: 220px;

    border: 1px solid rgba(255, 255, 255, 0.32);
    border-radius: 50%;
}

.vip-hero-content {
    position: relative;
    z-index: 1;

    max-width: 650px;
}

.vip-crown {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 66px;
    height: 66px;
    margin-bottom: 20px;

    border-radius: 22px;

    background: rgba(255, 255, 255, 0.5);

    font-size: 34px;
}

.vip-label {
    margin: 0 0 10px;

    color: #79570b;

    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
}

.vip-hero h2 {
    margin: 0 0 16px;

    color: #4d3909;

    font-size: clamp(30px, 5vw, 48px);
    line-height: 1.2;
}

.vip-description {
    max-width: 560px;
    margin: 0 0 28px;

    color: #69521c;

    font-size: 16px;
    line-height: 1.9;
}

.vip-upgrade-button {
    padding: 14px 28px;

    border: 0;
    border-radius: 999px;

    background: #4b3708;
    color: #ffffff;

    font-size: 15px;
    font-weight: 800;

    cursor: pointer;

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        opacity 0.2s ease;
}

.vip-upgrade-button:hover {
    transform: translateY(-2px);

    box-shadow: 0 12px 26px rgba(75, 55, 8, 0.25);
}

.vip-upgrade-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.vip-feature-section,
.vip-plan-section,
.vip-status-section {
    margin-bottom: 38px;
}

.vip-section-heading {
    margin-bottom: 22px;
}

.vip-section-heading h2 {
    margin: 5px 0 8px;

    color: #3e3638;

    font-size: 28px;
}

.vip-section-heading > p:last-child {
    margin: 0;

    color: #8a8587;
    line-height: 1.7;
}

.vip-feature-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
}

.vip-feature-card {
    padding: 26px 22px;

    border: 1px solid #eee5e7;
    border-radius: 22px;

    background: #ffffff;

    box-shadow: 0 10px 30px rgba(62, 54, 56, 0.06);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.vip-feature-card:hover {
    transform: translateY(-4px);

    box-shadow: 0 16px 38px rgba(62, 54, 56, 0.1);
}

.vip-feature-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 52px;
    height: 52px;
    margin-bottom: 18px;

    border-radius: 17px;

    background: #fff5dd;

    font-size: 25px;
}

.vip-feature-card h3 {
    margin: 0 0 10px;

    color: #433b3d;

    font-size: 17px;
}

.vip-feature-card p {
    margin: 0;

    color: #8a8587;

    font-size: 14px;
    line-height: 1.8;
}.vip-plan-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.vip-plan-card {
    position: relative;

    padding: 30px 24px;

    border: 1px solid #eee5e7;
    border-radius: 24px;

    background: #ffffff;

    box-shadow: 0 12px 34px rgba(62, 54, 56, 0.07);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        border-color 0.2s ease;
}

.vip-plan-card:hover {
    transform: translateY(-5px);

    border-color: #e6c665;

    box-shadow: 0 18px 42px rgba(62, 54, 56, 0.12);
}

.vip-plan-card-featured {
    border: 2px solid #dfbb4d;

    background: linear-gradient(
        180deg,
        #fffdf5,
        #ffffff
    );
}

.vip-popular-badge {
    position: absolute;
    top: -13px;
    left: 50%;

    transform: translateX(-50%);

    padding: 7px 16px;

    border-radius: 999px;

    background: #4b3708;
    color: #ffffff;

    font-size: 12px;
    font-weight: 800;

    white-space: nowrap;
}

.vip-plan-name {
    margin: 0 0 14px;

    color: #8a8587;

    font-size: 14px;
    font-weight: 700;
}

.vip-plan-card h3 {
    margin: 0 0 8px;

    color: #44360e;

    font-size: 32px;
}

.vip-plan-period {
    margin: 0 0 24px;

    color: #9a8b61;

    font-size: 14px;
}

.vip-plan-list {
    display: grid;
    gap: 12px;

    margin: 0 0 28px;
    padding: 0;

    list-style: none;
}

.vip-plan-list li {
    position: relative;

    padding-left: 25px;

    color: #6f686a;

    font-size: 14px;
    line-height: 1.7;
}

.vip-plan-list li::before {
    content: "✓";

    position: absolute;
    top: 0;
    left: 0;

    color: #c69923;

    font-weight: 900;
}

.vip-plan-button {
    width: 100%;
    padding: 13px 20px;

    border: 0;
    border-radius: 14px;

    background: #f5e8b9;
    color: #5d450b;

    font-size: 14px;
    font-weight: 800;

    cursor: pointer;

    transition:
        transform 0.2s ease,
        background 0.2s ease,
        opacity 0.2s ease;
}

.vip-plan-button:hover {
    transform: translateY(-2px);

    background: #ebd68e;
}

.vip-plan-card-featured .vip-plan-button {
    background: #4b3708;
    color: #ffffff;
}

.vip-plan-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.vip-status-section .setting-card {
    margin: 0;

    border: 1px solid #eee5e7;
    border-radius: 22px;

    background: #ffffff;

    box-shadow: 0 10px 30px rgba(62, 54, 56, 0.06);
}

/* 女生上傳 4 張照片免費解鎖區塊 */
.female-unlock-card {
    margin-bottom: 32px;
    padding: 34px;

    border: 1px solid #eaf3ec;
    border-radius: 26px;

    background: linear-gradient(
        135deg,
        #fff4f8,
        #fffdfd
    );

    box-shadow: 0 14px 36px rgba(170, 96, 126, 0.1);
}

.female-unlock-card h2 {
    margin: 0 0 12px;

    color: #5f3b49;

    font-size: 27px;
}

.female-unlock-card p {
    margin: 0 0 22px;

    color: #8a6d78;

    line-height: 1.8;
}

.female-photo-progress {
    display: flex;
    align-items: center;
    gap: 14px;

    margin-bottom: 22px;
}

.female-photo-progress-bar {
    flex: 1;
    overflow: hidden;

    height: 12px;

    border-radius: 999px;

    background: #f1e3e8;
}

.female-photo-progress-fill {
    width: 0%;
    height: 100%;

    border-radius: inherit;

    background: linear-gradient(
        90deg,
        #d98ca7,
        #b85f80
    );

    transition: width 0.3s ease;
}

.female-photo-progress-text {
    min-width: 52px;

    color: #6f4b59;

    font-size: 14px;
    font-weight: 800;
}

.female-upload-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 13px 24px;

    border: 0;
    border-radius: 999px;

    background: #6f3e50;
    color: #ffffff;

    font-size: 14px;
    font-weight: 800;

    cursor: pointer;

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.female-upload-button:hover {
    transform: translateY(-2px);

    box-shadow: 0 10px 24px rgba(111, 62, 80, 0.2);
}

.female-unlock-success {
    border-color: #cae9d4;

    background: linear-gradient(
        135deg,
        #f1fff5,
        #ffffff
    );
}

.vip-hidden {
    display: none !important;
}

@media (max-width: 1050px) {

    .vip-feature-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .vip-plan-grid {
        grid-template-columns: 1fr;
    }

}

@media (max-width: 700px) {

    .vip-hero {
        padding: 42px 24px;
        border-radius: 22px;
    }

    .vip-feature-grid {
        grid-template-columns: 1fr;
    }

    .vip-plan-card,
    .vip-feature-card,
    .female-unlock-card {
        padding: 24px 20px;
    }

    .vip-status-badge {
        margin-top: 12px;
    }

}
/* ==================================================
   MyDating 個人資料頁
   頁面基礎與主要版面
================================================== */

.member-shell-body {
    margin: 0;
    min-height: 100vh;
    background:
        linear-gradient(
            135deg,
            #fff8fb 0%,
            #fff5f8 45%,
            #f8f7ff 100%
        );
    color: #2f2a35;
    font-family:
        "Noto Sans TC",
        "Microsoft JhengHei",
        Arial,
        sans-serif;
}

.member-shell-body *,
.member-shell-body *::before,
.member-shell-body *::after {
    box-sizing: border-box;
}

.member-shell {
    display: flex;
    min-height: 100vh;
}

.member-content {
    width: calc(100% - 280px);
    min-width: 0;
    margin-left: 280px;
    padding: 38px 48px 80px;
}

.member-page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    width: 100%;
    max-width: 1180px;
    margin: 0 auto 28px;
}

.member-page-header h1 {
    margin: 4px 0 8px;
    color: #302a35;
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 800;
    letter-spacing: -1px;
}

.member-page-header > div > p:not(.member-page-kicker) {
    margin: 0;
    color: #847b89;
    font-size: 15px;
    line-height: 1.8;
}

.member-page-kicker {
    margin: 0;
    color: #2d4a3e;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2.5px;
}


/* ==================================================
   手機選單按鈕
================================================== */

.mobile-menu-button {
    position: fixed;
    top: 12px;
    left: 16px;
    z-index: 1050;
    display: none;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #155c2a;
    color: #fff;
    box-shadow: 0 8px 25px rgba(21, 92, 42, 0.2);
    cursor: pointer;
    font-size: 20px;
}

.sidebar-overlay {
    position: fixed;
    inset: 0;
    z-index: 1090;
    display: none;
    background: rgba(25, 19, 27, 0.48);
    backdrop-filter: blur(3px);
}


/* ==================================================
   個人資料主容器
================================================== */

.profile-page,
.profile-form {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
}

.profile-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.profile-message {
    width: 100%;
    margin-bottom: 18px;
    padding: 15px 18px;
    border: 1px solid transparent;
    border-radius: 16px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.6;
}

.profile-message[hidden] {
    display: none;
}

.profile-message.loading {
    border-color: #f3d6e0;
    background: #fff3f7;
    color: #c84f76;
}

.profile-message.success {
    border-color: #bfe7cd;
    background: #ecfbf1;
    color: #21844a;
}

.profile-message.error {
    border-color: #f4bfc4;
    background: #fff0f1;
    color: #c43e4b;
}


/* ==================================================
   資料完成度
================================================== */

.profile-progress-section,
.profile-progress-card {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto 24px;
    padding: 24px 28px;
    border: 1px solid rgba(237, 213, 223, 0.8);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 16px 45px rgba(73, 48, 62, 0.07);
}

.profile-progress-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 15px;
}

.profile-progress-header h2,
.profile-progress-header h3 {
    margin: 0;
    color: #352e39;
    font-size: 18px;
    font-weight: 800;
}

.profile-progress-header p {
    margin: 5px 0 0;
    color: #918792;
    font-size: 13px;
}

.profile-completion-badge,
#profileCompletionBadge {
    flex-shrink: 0;
    padding: 8px 14px;
    border-radius: 999px;
    background: #fff0f5;
    color: #155c2a;
    font-size: 13px;
    font-weight: 800;
}

.profile-progress-track {
    position: relative;
    width: 100%;
    height: 12px;
    overflow: hidden;
    border-radius: 999px;
    background: #eaf3ec;
}

.profile-progress-bar,
#profileProgressBar {
    width: 0;
    height: 100%;
    border-radius: inherit;
    background:
        linear-gradient(
            90deg,
            #2d4a3e,
            #fa89a9
        );
    box-shadow: 0 4px 12px rgba(236, 94, 139, 0.28);
    transition: width 0.35s ease;
}

.profile-progress-number,
#profileProgressNumber {
    display: inline-block;
    margin-top: 10px;
    color: #155c2a;
    font-size: 14px;
    font-weight: 800;
}


/* ==================================================
   共用白色區塊
================================================== */

.profile-form-section,
.profile-avatar-section,
.profile-gallery-section {
    width: 100%;
    padding: 30px;
    border: 1px solid rgba(237, 213, 223, 0.85);
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 16px 45px rgba(73, 48, 62, 0.065);
}

.section-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 26px;
    padding-bottom: 18px;
    border-bottom: 1px solid #eaf3ec;
}

.section-heading p {
    margin: 0 0 5px;
    color: #2d4a3e;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 2px;
}

.section-heading h2 {
    margin: 0;
    color: #332d37;
    font-size: 23px;
    font-weight: 850;
}

.section-heading > span,
.section-heading > small {
    color: #978d99;
    font-size: 13px;
    line-height: 1.6;
}


/* ==================================================
   大頭照區域
================================================== */

.profile-avatar-layout {
    display: flex;
    align-items: center;
    gap: 30px;
}

.profile-avatar-wrapper {
    position: relative;
    flex: 0 0 auto;
    width: 170px;
    height: 170px;
}

.profile-avatar-preview,
#profileAvatarPreview {
    display: block;
    width: 170px;
    height: 170px;
    overflow: hidden;
    border: 5px solid #ffffff;
    border-radius: 50%;
    background: #f4edf0;
    box-shadow:
        0 0 0 2px #f3d5df,
        0 14px 35px rgba(88, 55, 71, 0.14);
    object-fit: cover;
}

.profile-avatar-loading,
#profileAvatarLoading {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.82);
    color: #155c2a;
    font-size: 13px;
    font-weight: 800;
    backdrop-filter: blur(3px);
}

.profile-avatar-loading[hidden],
#profileAvatarLoading[hidden] {
    display: none;
}

.profile-avatar-info {
    flex: 1;
    min-width: 0;
}

.profile-avatar-info h3 {
    margin: 0 0 8px;
    color: #362f3a;
    font-size: 20px;
    font-weight: 800;
}

.profile-avatar-info p {
    max-width: 620px;
    margin: 0 0 18px;
    color: #8d838f;
    font-size: 14px;
    line-height: 1.8;
}

.profile-avatar-upload-button,
.avatar-upload-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 45px;
    padding: 10px 20px;
    border: 0;
    border-radius: 999px;
    background:
        linear-gradient(
            135deg,
            #2d4a3e,
            #f47fa1
        );
    color: #ffffff;
    box-shadow: 0 9px 22px rgba(236, 94, 139, 0.25);
    cursor: pointer;
    font-size: 14px;
    font-weight: 800;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.profile-avatar-upload-button:hover,
.avatar-upload-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 26px rgba(236, 94, 139, 0.32);
}

#profileAvatarInput,
#profileGalleryInput {
    display: none;
}


/* ==================================================
   六張照片區域
================================================== */

.profile-gallery-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}

.profile-gallery-header h2,
.profile-gallery-header h3 {
    margin: 0 0 7px;
    color: #342e38;
    font-size: 23px;
    font-weight: 850;
}

.profile-gallery-header p {
    margin: 0;
    color: #908691;
    font-size: 14px;
    line-height: 1.7;
}

.profile-photo-count,
#profilePhotoCount {
    flex-shrink: 0;
    padding: 8px 13px;
    border-radius: 999px;
    background: #fff0f5;
    color: #155c2a;
    font-size: 13px;
    font-weight: 850;
}

.profile-photo-grid,
#profilePhotoGrid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.profile-photo-card {
    position: relative;
    width: 100%;
    overflow: hidden;
    border: 1px solid #d8e8dc;
    border-radius: 20px;
    background: #faf6f8;
    aspect-ratio: 4 / 5;
    box-shadow: 0 7px 20px rgba(72, 51, 61, 0.05);
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.profile-photo-card:hover {
    transform: translateY(-3px);
    border-color: #edb6c8;
    box-shadow: 0 13px 28px rgba(72, 51, 61, 0.1);
}

.gallery-photo-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    width: 100%;
    height: 100%;
    color: #c6859d;
    cursor: pointer;
    background:
        linear-gradient(
            145deg,
            #fffafd,
            #fbf1f5
        );
    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.photo-empty:hover {
    color: #e4507e;
    background: #fff0f5;
}

.photo-empty span {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    margin-bottom: 10px;
    border: 1px dashed #dda1b6;
    border-radius: 50%;
    background: #ffffff;
    font-size: 28px;
    font-weight: 300;
    line-height: 1;
}

.photo-empty small {
    font-size: 13px;
    font-weight: 800;
}

.delete-photo-button {
    position: absolute;
    top: 10px;
    right: 10px;
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(36, 28, 33, 0.72);
    color: #ffffff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.18);
    cursor: pointer;
    font-size: 14px;
    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

.delete-photo-button:hover {
    transform: scale(1.08);
    background: #155c2a;
}

.profile-photo-message,
#profilePhotoMessage {
    margin: 17px 0 0;
    padding: 13px 16px;
    border-radius: 14px;
    background: #fff3f7;
    color: #d45079;
    font-size: 13px;
    font-weight: 750;
    line-height: 1.6;
}


/* ==================================================
   平板尺寸
================================================== */

@media (max-width: 1050px) {

    .member-content {
        width: calc(100% - 240px);
        margin-left: 240px;
        padding: 34px 28px 70px;
    }

    .profile-photo-grid,
    #profilePhotoGrid {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));
        gap: 13px;
    }
}


/* ==================================================
   手機尺寸
================================================== */

@media (max-width: 780px) {

    .mobile-menu-button {
        display: grid;
        place-items: center;
    }

    .member-content {
        width: 100%;
        margin-left: 0;
        padding: 82px 16px 55px;
    }

    .member-page-header {
        margin-bottom: 20px;
    }

    .member-page-header h1 {
        font-size: 30px;
    }

    .profile-progress-section,
    .profile-progress-card,
    .profile-form-section,
    .profile-avatar-section,
    .profile-gallery-section {
        padding: 22px 18px;
        border-radius: 21px;
    }

    .profile-avatar-layout {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-avatar-wrapper,
    .profile-avatar-preview,
    #profileAvatarPreview {
        width: 140px;
        height: 140px;
    }

    .profile-photo-grid,
    #profilePhotoGrid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
        gap: 11px;
    }

    .section-heading,
    .profile-gallery-header {
        flex-direction: column;
        align-items: flex-start;
    }
}/* ==================================================
   表單欄位
================================================== */

.profile-field-grid {
    display: grid;
    grid-template-columns:
        repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.profile-field {
    display: flex;
    flex-direction: column;
    gap: 9px;
    min-width: 0;
}

.profile-field.full-width {
    grid-column: 1 / -1;
}

.profile-field label {
    color: #4a414d;
    font-size: 14px;
    font-weight: 800;
}

.profile-field label span {
    margin-left: 5px;
    color: #e85783;
}

.profile-field small {
    color: #9a909b;
    font-size: 12px;
    line-height: 1.6;
}

.profile-field input,
.profile-field select,
.profile-field textarea {
    width: 100%;
    min-height: 50px;
    padding: 13px 15px;
    border: 1px solid #e8dbe1;
    border-radius: 15px;
    outline: none;
    background: #fffdfd;
    color: #37303a;
    font: inherit;
    font-size: 14px;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.profile-field textarea {
    min-height: 145px;
    resize: vertical;
    line-height: 1.8;
}

.profile-field input::placeholder,
.profile-field textarea::placeholder {
    color: #b7adb7;
}

.profile-field input:hover,
.profile-field select:hover,
.profile-field textarea:hover {
    border-color: #c5d8c8;
}

.profile-field input:focus,
.profile-field select:focus,
.profile-field textarea:focus {
    border-color: #155c2a;
    background: #ffffff;
    box-shadow:
        0 0 0 4px rgba(236, 94, 139, 0.11);
}

.profile-field input:disabled,
.profile-field select:disabled,
.profile-field textarea:disabled {
    cursor: not-allowed;
    background: #f5f1f3;
    color: #9c929d;
}

.profile-field select {
    cursor: pointer;
}

.profile-field input[type="number"] {
    appearance: textfield;
}

.profile-field input[type="number"]::-webkit-inner-spin-button,
.profile-field input[type="number"]::-webkit-outer-spin-button {
    margin: 0;
    appearance: none;
}


/* ==================================================
   年齡、身高範圍
================================================== */

.profile-range-row {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        auto
        minmax(0, 1fr);
    align-items: center;
    gap: 12px;
}

.profile-range-divider {
    color: #a798a1;
    font-size: 14px;
    font-weight: 800;
    text-align: center;
}


/* ==================================================
   自我介紹字數
================================================== */

.profile-textarea-wrapper {
    position: relative;
}

.profile-textarea-wrapper textarea {
    padding-bottom: 42px;
}

.profile-text-counter {
    position: absolute;
    right: 14px;
    bottom: 13px;
    color: #b08797;
    font-size: 12px;
    font-weight: 700;
    pointer-events: none;
}

.profile-text-counter span {
    color: #e45782;
}


/* ==================================================
   單選與複選膠囊按鈕
================================================== */

.profile-option-group {
    display: flex;
    flex-wrap: wrap;
    gap: 11px;
}

.profile-option {
    position: relative;
    display: inline-flex;
}

.profile-option input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.profile-option label,
.profile-option > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 9px 17px;
    border: 1px solid #eadce2;
    border-radius: 999px;
    background: #fffdfd;
    color: #675c68;
    cursor: pointer;
    font-size: 13px;
    font-weight: 750;
    line-height: 1.3;
    user-select: none;
    transition:
        color 0.2s ease,
        border-color 0.2s ease,
        background 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.profile-option label:hover,
.profile-option > span:hover {
    transform: translateY(-1px);
    border-color: #e4aabe;
    background: #fff5f8;
    color: #dc507b;
}

.profile-option input:checked + label,
.profile-option input:checked + span {
    border-color: #2d4a3e;
    background:
        linear-gradient(
            135deg,
            #2d4a3e,
            #f681a2
        );
    color: #ffffff;
    box-shadow:
        0 8px 18px rgba(236, 94, 139, 0.23);
}

.profile-option input:focus-visible + label,
.profile-option input:focus-visible + span {
    outline: 3px solid rgba(236, 94, 139, 0.2);
    outline-offset: 2px;
}


/* ==================================================
   卡片式選項
================================================== */

.profile-choice-grid {
    display: grid;
    grid-template-columns:
        repeat(3, minmax(0, 1fr));
    gap: 13px;
}

.profile-choice-card {
    position: relative;
}

.profile-choice-card input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.profile-choice-card label {
    display: flex;
    align-items: center;
    gap: 11px;
    width: 100%;
    min-height: 66px;
    padding: 14px 15px;
    border: 1px solid #e9dde2;
    border-radius: 17px;
    background: #fffdfd;
    color: #605661;
    cursor: pointer;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        background 0.2s ease,
        box-shadow 0.2s ease;
}

.profile-choice-card label:hover {
    transform: translateY(-2px);
    border-color: #e2adbf;
    background: #fff6f9;
}

.profile-choice-card input:checked + label {
    border-color: #155c2a;
    background: #fff1f5;
    color: #d94c78;
    box-shadow:
        0 8px 20px rgba(236, 94, 139, 0.12);
}

.profile-choice-icon {
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    border-radius: 13px;
    background: #fff0f5;
    font-size: 19px;
}

.profile-choice-card input:checked + label
.profile-choice-icon {
    background: #2d4a3e;
    color: #ffffff;
}

.profile-choice-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.profile-choice-text strong {
    font-size: 14px;
}

.profile-choice-text small {
    color: #a095a0;
    font-size: 11px;
    font-weight: 500;
}


/* ==================================================
   區塊內小標題
================================================== */

.profile-subsection {
    padding-top: 6px;
}

.profile-subsection + .profile-subsection {
    margin-top: 28px;
    padding-top: 28px;
    border-top: 1px solid #f1e7eb;
}

.profile-subsection-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.profile-subsection-title span {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 12px;
    background: #fff0f5;
    font-size: 17px;
}

.profile-subsection-title h3 {
    margin: 0;
    color: #423943;
    font-size: 16px;
    font-weight: 850;
}

.profile-subsection-title p {
    margin: 3px 0 0;
    color: #9b909b;
    font-size: 12px;
}


/* ==================================================
   VIP 提示卡
================================================== */

.profile-vip-hint {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-top: 18px;
    padding: 17px 19px;
    border: 1px solid #f0cfdb;
    border-radius: 18px;
    background:
        linear-gradient(
            135deg,
            #fff4f8,
            #fffafd
        );
}

.profile-vip-hint div {
    min-width: 0;
}

.profile-vip-hint strong {
    display: block;
    margin-bottom: 4px;
    color: #d64f79;
    font-size: 14px;
}

.profile-vip-hint p {
    margin: 0;
    color: #8f818c;
    font-size: 12px;
    line-height: 1.6;
}

.profile-vip-hint span {
    flex-shrink: 0;
    padding: 8px 12px;
    border-radius: 999px;
    background: #2d4a3e;
    color: #ffffff;
    font-size: 12px;
    font-weight: 850;
}


/* ==================================================
   儲存區域
================================================== */

.profile-save-section {
    position: sticky;
    bottom: 18px;
    z-index: 30;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
    padding: 18px 22px;
    border: 1px solid rgba(232, 208, 218, 0.9);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.93);
    box-shadow:
        0 16px 40px rgba(72, 48, 61, 0.14);
    backdrop-filter: blur(12px);
}

.profile-save-section p {
    margin: 0;
    color: #948994;
    font-size: 13px;
    line-height: 1.6;
}

.profile-save-button,
#saveProfileButton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    min-width: 190px;
    min-height: 52px;
    padding: 12px 24px;
    border: 0;
    border-radius: 999px;
    background:
        linear-gradient(
            135deg,
            #e94f7f,
            #f781a2
        );
    color: #ffffff;
    box-shadow:
        0 10px 25px rgba(232, 79, 127, 0.29);
    cursor: pointer;
    font-size: 15px;
    font-weight: 900;
    letter-spacing: 0.2px;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        opacity 0.2s ease;
}

.profile-save-button:hover,
#saveProfileButton:hover {
    transform: translateY(-2px);
    box-shadow:
        0 13px 30px rgba(232, 79, 127, 0.36);
}

.profile-save-button:active,
#saveProfileButton:active {
    transform: translateY(0);
}

.profile-save-button:disabled,
#saveProfileButton:disabled {
    cursor: not-allowed;
    opacity: 0.58;
    transform: none;
    box-shadow: none;
}


/* ==================================================
   必填與錯誤狀態
================================================== */

.profile-field input:invalid:not(:placeholder-shown),
.profile-field textarea:invalid:not(:placeholder-shown),
.profile-field select:invalid {
    border-color: #e49aa6;
}

.profile-field-error {
    display: none;
    color: #d94c59;
    font-size: 12px;
    font-weight: 700;
}

.profile-field.has-error
.profile-field-error {
    display: block;
}


/* ==================================================
   小提醒與分隔線
================================================== */

.profile-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 14px 16px;
    border-radius: 15px;
    background: #faf5f7;
    color: #817580;
    font-size: 12px;
    line-height: 1.7;
}

.profile-note-icon {
    flex: 0 0 auto;
    font-size: 16px;
}

.profile-divider {
    width: 100%;
    height: 1px;
    margin: 7px 0;
    background: #f0e5ea;
}


/* ==================================================
   平板
================================================== */

@media (max-width: 980px) {

    .profile-choice-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }
}


/* ==================================================
   手機
================================================== */

@media (max-width: 680px) {

    .profile-field-grid {
        grid-template-columns: 1fr;
        gap: 17px;
    }

    .profile-field.full-width {
        grid-column: auto;
    }

    .profile-choice-grid {
        grid-template-columns: 1fr;
    }

    .profile-range-row {
        grid-template-columns:
            minmax(0, 1fr)
            auto
            minmax(0, 1fr);
        gap: 8px;
    }

    .profile-option-group {
        gap: 9px;
    }

    .profile-option label,
    .profile-option > span {
        min-height: 40px;
        padding: 8px 14px;
        font-size: 12px;
    }

    .profile-vip-hint {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-save-section {
        bottom: 10px;
        flex-direction: column;
        align-items: stretch;
        padding: 15px;
        border-radius: 18px;
    }

    .profile-save-button,
    #saveProfileButton {
        width: 100%;
        min-width: 0;
    }
}
/* ==================================================
   MyDating 照片管理區重新設計
   參考使用者提供的會員網站風格
================================================== */

.profile-gallery-section {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.profile-gallery-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin: 0 0 16px;
    padding: 0 0 13px;
    border-bottom: 1px solid #efb7c9;
}

.profile-gallery-header h2,
.profile-gallery-header h3 {
    margin: 0;
    color: #4c4248;
    font-size: 18px;
    font-weight: 700;
}

.profile-gallery-header p {
    margin: 4px 0 0;
    color: #9c9197;
    font-size: 13px;
}

.profile-photo-count,
#profilePhotoCount {
    padding: 6px 13px;
    border: 1px solid #f0bdce;
    border-radius: 999px;
    background: #fff8fa;
    color: #df648c;
    font-size: 12px;
    font-weight: 700;
}


/* ==================================================
   六張生活照排列
================================================== */

.profile-photo-grid,
#profilePhotoGrid {
    display: grid;
    grid-template-columns:
        repeat(6, minmax(0, 1fr));
    gap: 9px;
    width: 100%;
}

.profile-photo-card {
    position: relative;
    width: 100%;
    min-width: 0;
    overflow: hidden;
    border: 1px solid #eeeeee;
    border-radius: 2px;
    background: #f3f3f3;
    box-shadow: none;
    aspect-ratio: 1 / 1;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.profile-photo-card:hover {
    z-index: 2;
    transform: translateY(-3px);
    border-color: #ef9fba;
    box-shadow: 0 8px 20px rgba(198, 92, 128, 0.16);
}


/* ==================================================
   左上角粉紅色斜角標籤
================================================== */

.profile-photo-card::before {
    position: absolute;
    top: 7px;
    left: -27px;
    z-index: 5;
    width: 92px;
    padding: 4px 0;
    background: #f47b9f;
    color: #ffffff;
    content: "生活照";
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    transform: rotate(-45deg);
    pointer-events: none;
}

.profile-photo-card:first-child::before {
    content: "主要照片";
    background: #ed668f;
}


/* ==================================================
   已上傳照片
================================================== */

.gallery-photo-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition:
        transform 0.35s ease,
        filter 0.35s ease;
}

.profile-photo-card:hover .gallery-photo-image {
    transform: scale(1.045);
    filter: brightness(0.9);
}


/* ==================================================
   尚未上傳照片
================================================== */

.photo-empty {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    width: 100%;
    height: 100%;
    min-height: 120px;
    padding: 15px 8px 10px;
    background: #f4f4f4;
    color: #bcbcbc;
    cursor: pointer;
    text-align: center;
    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.photo-empty::before {
    display: block;
    margin-bottom: 7px;
    content: "📷";
    opacity: 0.23;
    filter: grayscale(1);
    font-size: 40px;
    line-height: 1;
}

.photo-empty span {
    display: none;
}

.photo-empty small {
    color: #b2b2b2;
    font-size: 11px;
    font-weight: 500;
}

.photo-empty small::before {
    content: "點擊上傳";
}

.photo-empty:hover {
    background: #fff3f7;
    color: #e06b91;
}

.photo-empty:hover::before {
    opacity: 0.65;
    filter: none;
}

.photo-empty:hover small {
    color: #de6a90;
}


/* ==================================================
   刪除照片按鈕
================================================== */

.delete-photo-button {
    position: absolute;
    top: auto;
    right: 8px;
    bottom: 8px;
    z-index: 8;
    display: grid;
    place-items: center;
    width: 31px;
    height: 31px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.75);
    border-radius: 50%;
    background: rgba(52, 42, 47, 0.76);
    color: #ffffff;
    cursor: pointer;
    font-size: 12px;
    opacity: 0;
    transform: translateY(6px);
    transition:
        opacity 0.2s ease,
        transform 0.2s ease,
        background 0.2s ease;
}

.profile-photo-card:hover .delete-photo-button {
    opacity: 1;
    transform: translateY(0);
}

.delete-photo-button:hover {
    background: #e65165;
}


/* ==================================================
   第一張照片標示
================================================== */

.profile-photo-card:first-child::after {
    position: absolute;
    right: 7px;
    bottom: 7px;
    z-index: 6;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(236, 95, 139, 0.9);
    color: #ffffff;
    content: "封面";
    font-size: 10px;
    font-weight: 700;
    pointer-events: none;
}

.profile-photo-card:first-child:has(.photo-empty)::after {
    display: none;
}


/* ==================================================
   女生免費 VIP 提示
================================================== */

.profile-photo-message,
#profilePhotoMessage {
    position: relative;
    margin: 22px 0 0;
    padding: 16px 18px 16px 52px;
    border: 1px dashed #e6a8bc;
    border-radius: 3px;
    background:
        linear-gradient(
            90deg,
            #fff7f9,
            #ffffff
        );
    color: #bd5979;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.7;
}

.profile-photo-message::before,
#profilePhotoMessage::before {
    position: absolute;
    top: 50%;
    left: 17px;
    display: grid;
    place-items: center;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    background: #f88baa;
    color: #ffffff;
    content: "V";
    font-size: 12px;
    font-weight: 800;
    transform: translateY(-50%);
}


/* ==================================================
   照片管理說明區
================================================== */

.profile-gallery-section::after {
    display: block;
    margin-top: 15px;
    padding: 12px 15px;
    border-top: 1px solid #f2e4e9;
    background: #fffafb;
    color: #93868d;
    content:
        "照片建議：第一張會作為封面照片，請選擇清楚且完整的本人照片。支援 JPG、PNG、WEBP，最多可上傳 6 張。";
    font-size: 12px;
    line-height: 1.8;
}


/* ==================================================
   照片區外層白色內容
================================================== */

.profile-form {
    max-width: 1040px;
}

.profile-form-section,
.profile-avatar-section,
.profile-gallery-section {
    width: 100%;
}

.profile-gallery-section {
    padding: 25px 12px 28px;
    background: #ffffff;
}


/* ==================================================
   大頭照區改成參考圖的小型風格
================================================== */

.profile-avatar-section {
    padding: 24px 12px;
    border: 0;
    border-radius: 0;
    background: #ffffff;
    box-shadow: none;
}

.profile-avatar-layout {
    display: flex;
    align-items: center;
    gap: 22px;
}

.profile-avatar-wrapper {
    width: 115px;
    height: 115px;
}

.profile-avatar-preview,
#profileAvatarPreview {
    width: 115px;
    height: 115px;
    border: 1px solid #ece2e6;
    border-radius: 3px;
    background: #f4f4f4;
    box-shadow: none;
    object-fit: cover;
}

.profile-avatar-info h3 {
    margin: 0 0 7px;
    color: #51464c;
    font-size: 17px;
}

.profile-avatar-info p {
    margin: 0 0 13px;
    color: #9c9097;
    font-size: 12px;
}

.profile-avatar-upload-button,
.avatar-upload-button {
    min-height: 38px;
    padding: 8px 25px;
    border-radius: 999px;
    background:
        linear-gradient(
            90deg,
            #fa8ba9,
            #f47c9c
        );
    box-shadow: 0 5px 15px rgba(235, 100, 143, 0.23);
    font-size: 13px;
}


/* ==================================================
   平板
================================================== */

@media (max-width: 1000px) {

    .profile-photo-grid,
    #profilePhotoGrid {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));
    }

    .profile-photo-card {
        aspect-ratio: 4 / 3;
    }
}


/* ==================================================
   手機
================================================== */

@media (max-width: 620px) {

    .profile-gallery-section {
        padding: 20px 0 24px;
    }

    .profile-photo-grid,
    #profilePhotoGrid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .profile-photo-card {
        aspect-ratio: 1 / 1;
    }

    .profile-gallery-header {
        align-items: flex-start;
    }

    .profile-gallery-header h2,
    .profile-gallery-header h3 {
        font-size: 17px;
    }

    .profile-avatar-layout {
        align-items: flex-start;
    }

    .profile-avatar-wrapper,
    .profile-avatar-preview,
    #profileAvatarPreview {
        width: 95px;
        height: 95px;
    }

    .delete-photo-button {
        opacity: 1;
        transform: none;
    }
}
/* ==================================================
   MyDating 個人資料表單重新設計
   風格：參考圖的台灣交友網站版型
================================================== */

.profile-page,
.profile-form {
    width: 100%;
    max-width: 1040px;
    margin: 0 auto;
}

.profile-form {
    display: block;
    padding: 0 12px 80px;
    background: #ffffff;
}


/* ==================================================
   移除大卡片風格
================================================== */

.profile-form-section {
    width: 100%;
    margin: 0;
    padding: 32px 0;
    border: 0;
    border-bottom: 1px solid #f0e7eb;
    border-radius: 0;
    background: #ffffff;
    box-shadow: none;
}

.profile-form-section:last-of-type {
    border-bottom: 0;
}


/* ==================================================
   區塊標題
================================================== */

.section-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin: 0 0 24px;
    padding: 0 0 12px;
    border-bottom: 1px solid #efb6c8;
}

.section-heading p {
    display: none;
}

.section-heading h2 {
    margin: 0;
    color: #4d4349;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0;
}

.section-heading > span,
.section-heading > small {
    color: #a0969b;
    font-size: 12px;
}


/* ==================================================
   表單改為單欄
================================================== */

.profile-field-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 23px;
}

.profile-field,
.profile-field.full-width {
    display: flex;
    grid-column: auto;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.profile-field label {
    color: #5e5459;
    font-size: 13px;
    font-weight: 500;
}

.profile-field label span {
    margin-left: 3px;
    color: #e36c91;
    font-size: 12px;
}

.profile-field small {
    color: #9d9298;
    font-size: 11px;
    line-height: 1.7;
}


/* ==================================================
   輸入框
================================================== */

.profile-field input,
.profile-field select,
.profile-field textarea {
    width: 100%;
    min-height: 43px;
    padding: 9px 13px;
    border: 1px solid #dcd7da;
    border-radius: 2px;
    outline: 0;
    background: #ffffff;
    color: #51484d;
    box-shadow: none;
    font-family:
        "Noto Sans TC",
        "Microsoft JhengHei",
        sans-serif;
    font-size: 13px;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.profile-field textarea {
    min-height: 116px;
    padding: 12px 13px;
    resize: vertical;
    line-height: 1.75;
}

.profile-field input:hover,
.profile-field select:hover,
.profile-field textarea:hover {
    border-color: #cfc5ca;
}

.profile-field input:focus,
.profile-field select:focus,
.profile-field textarea:focus {
    border-color: #e68aa7;
    background: #ffffff;
    box-shadow:
        0 0 0 2px rgba(231, 123, 157, 0.11);
}

.profile-field input::placeholder,
.profile-field textarea::placeholder {
    color: #bbb3b7;
}


/* ==================================================
   生日、年齡與身高範圍
================================================== */

.profile-range-row {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        28px
        minmax(0, 1fr);
    align-items: center;
    gap: 9px;
}

.profile-range-divider {
    color: #756a70;
    font-size: 13px;
    font-weight: 400;
    text-align: center;
}


/* ==================================================
   區塊內小標題
================================================== */

.profile-subsection {
    width: 100%;
    padding: 0;
}

.profile-subsection + .profile-subsection {
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid #f0ebed;
}

.profile-subsection-title {
    display: block;
    margin: 0 0 13px;
}

.profile-subsection-title > span {
    display: none;
}

.profile-subsection-title h3 {
    position: relative;
    margin: 0;
    padding-left: 13px;
    color: #62575d;
    font-size: 13px;
    font-weight: 500;
}

.profile-subsection-title h3::before {
    position: absolute;
    top: 50%;
    left: 0;
    width: 7px;
    height: 7px;
    border: 1px solid #e384a2;
    border-radius: 50%;
    content: "";
    transform: translateY(-50%);
}

.profile-subsection-title p {
    margin: 5px 0 0 13px;
    color: #a1989d;
    font-size: 11px;
}


/* ==================================================
   標籤選項
================================================== */

.profile-option-group {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    width: 100%;
}

.profile-option {
    position: relative;
    display: inline-flex;
}

.profile-option input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.profile-option label,
.profile-option > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 35px;
    padding: 7px 12px;
    border: 1px solid #d8d2d5;
    border-radius: 9px;
    background: linear-gradient(
        180deg,
        #ffffff,
        #f8f8f8
    );
    color: #776d72;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    cursor: pointer;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.3;
    transition:
        border-color 0.18s ease,
        background 0.18s ease,
        color 0.18s ease,
        transform 0.18s ease;
}

.profile-option label:hover,
.profile-option > span:hover {
    transform: none;
    border-color: #e7a7bb;
    background: #fff7f9;
    color: #d86588;
}

.profile-option input:checked + label,
.profile-option input:checked + span {
    border-color: #f1ced9;
    background: #fde9ef;
    color: #df6088;
    box-shadow: none;
}

.profile-option input:focus-visible + label,
.profile-option input:focus-visible + span {
    outline: 2px solid rgba(227, 108, 145, 0.2);
    outline-offset: 2px;
}


/* ==================================================
   卡片選項改成小標籤
================================================== */

.profile-choice-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.profile-choice-card {
    position: relative;
    display: inline-flex;
}

.profile-choice-card input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.profile-choice-card label {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    width: auto;
    min-height: 35px;
    padding: 7px 12px;
    border: 1px solid #d8d2d5;
    border-radius: 9px;
    background: linear-gradient(
        180deg,
        #ffffff,
        #f8f8f8
    );
    color: #776d72;
    box-shadow: none;
    cursor: pointer;
}

.profile-choice-card label:hover {
    transform: none;
    border-color: #e7a7bb;
    background: #fff7f9;
}

.profile-choice-card input:checked + label {
    border-color: #f1ced9;
    background: #fde9ef;
    color: #df6088;
    box-shadow: none;
}

.profile-choice-icon {
    display: none;
}

.profile-choice-text {
    display: inline-flex;
    flex-direction: row;
    align-items: center;
    gap: 4px;
}

.profile-choice-text strong {
    color: inherit;
    font-size: 12px;
    font-weight: 400;
}

.profile-choice-text small {
    display: none;
}


/* ==================================================
   自我介紹文字框
================================================== */

.profile-textarea-wrapper {
    position: relative;
}

.profile-textarea-wrapper textarea {
    padding-bottom: 34px;
}

.profile-text-counter {
    position: absolute;
    right: 11px;
    bottom: 9px;
    color: #aaa0a5;
    font-size: 11px;
}

.profile-text-counter span {
    color: #dc6e91;
}


/* ==================================================
   自訂內容輸入列
================================================== */

.profile-custom-input-row {
    display: flex;
    align-items: center;
    gap: 7px;
    width: 100%;
    margin-top: 9px;
    padding-top: 9px;
    border-top: 1px solid #f0ebed;
}

.profile-custom-input-row input {
    width: 130px;
    min-height: 35px;
    padding: 7px 10px;
    border: 1px solid #ded8db;
    border-radius: 2px;
    outline: none;
    font-size: 12px;
}

.profile-custom-input-row input:focus {
    border-color: #e692ad;
}

.profile-custom-input-row button {
    min-height: 35px;
    padding: 7px 13px;
    border: 0;
    border-radius: 3px;
    background: #f5a1ba;
    color: #ffffff;
    cursor: pointer;
    font-size: 12px;
}

.profile-custom-input-row button:hover {
    background: #ec86a6;
}


/* ==================================================
   一般勾選框
================================================== */

.profile-checkbox-line {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    margin-top: 8px;
    color: #71676c;
    font-size: 12px;
}

.profile-checkbox-line input {
    width: 14px;
    height: 14px;
    accent-color: #e8789b;
}


/* ==================================================
   VIP 說明框
================================================== */

.profile-vip-hint {
    display: block;
    margin-top: 18px;
    padding: 0;
    border: 1px dashed #e7afc0;
    border-radius: 2px;
    background: #ffffff;
}

.profile-vip-hint div {
    min-width: 0;
}

.profile-vip-hint strong {
    display: block;
    margin: 0;
    padding: 9px 12px;
    background: #fff1f5;
    color: #cf6685;
    font-size: 13px;
    font-weight: 700;
}

.profile-vip-hint p {
    margin: 0;
    padding: 11px 12px;
    color: #74696f;
    font-size: 12px;
    line-height: 1.9;
}

.profile-vip-hint > span {
    display: none;
}


/* ==================================================
   提醒訊息
================================================== */

.profile-note {
    display: flex;
    align-items: flex-start;
    gap: 7px;
    margin-top: 9px;
    padding: 10px 12px;
    border-radius: 2px;
    background: #fff8fa;
    color: #8c7f86;
    font-size: 11px;
    line-height: 1.7;
}


/* ==================================================
   完成度改成細版
================================================== */

.profile-progress-section,
.profile-progress-card {
    width: 100%;
    max-width: 1040px;
    margin: 0 auto 22px;
    padding: 15px 18px;
    border: 1px solid #f0d7df;
    border-radius: 3px;
    background: #ffffff;
    box-shadow: none;
}

.profile-progress-header {
    margin-bottom: 10px;
}

.profile-progress-header h2,
.profile-progress-header h3 {
    color: #5d5157;
    font-size: 14px;
    font-weight: 600;
}

.profile-progress-header p {
    color: #a2999d;
    font-size: 11px;
}

.profile-completion-badge,
#profileCompletionBadge {
    padding: 4px 10px;
    border-radius: 999px;
    background: #fff0f5;
    color: #dc688c;
    font-size: 11px;
}

.profile-progress-track {
    height: 6px;
    background: #f3e6eb;
}

.profile-progress-bar,
#profileProgressBar {
    background: linear-gradient(
        90deg,
        #f59ab5,
        #ed6f96
    );
    box-shadow: none;
}

.profile-progress-number,
#profileProgressNumber {
    margin-top: 7px;
    color: #d9698b;
    font-size: 11px;
}


/* ==================================================
   儲存按鈕
================================================== */

.profile-save-section {
    position: static;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    margin-top: 32px;
    padding: 25px 0 0;
    border: 0;
    border-top: 1px solid #f0e6ea;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
}

.profile-save-section p {
    display: none;
}

.profile-save-button,
#saveProfileButton {
    width: 280px;
    min-width: 0;
    min-height: 45px;
    padding: 10px 20px;
    border: 0;
    border-radius: 999px;
    background: linear-gradient(
        90deg,
        #fa8eab,
        #f37b9c
    );
    color: #ffffff;
    box-shadow:
        0 6px 18px rgba(231, 108, 147, 0.28);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
}

.profile-save-button:hover,
#saveProfileButton:hover {
    transform: translateY(-1px);
    box-shadow:
        0 8px 22px rgba(231, 108, 147, 0.34);
}


/* ==================================================
   訊息
================================================== */

.profile-message {
    margin: 0 0 20px;
    padding: 11px 14px;
    border-radius: 2px;
    font-size: 12px;
}

.profile-message.loading {
    border-color: #efd2dc;
    background: #fff6f9;
    color: #ca6685;
}

.profile-message.success {
    border-color: #cde5d5;
    background: #f4fbf6;
    color: #49815b;
}

.profile-message.error {
    border-color: #efc9cd;
    background: #fff5f6;
    color: #c95863;
}


/* ==================================================
   整個頁面背景與內容
================================================== */

.member-shell-body {
    background: #ffffff;
}

.member-content {
    background: #ffffff;
}

.member-page-header {
    max-width: 1040px;
    margin-bottom: 22px;
    padding: 0 12px;
}

.member-page-header h1 {
    margin: 0 0 5px;
    color: #554a50;
    font-size: 24px;
    font-weight: 600;
    letter-spacing: 0;
}

.member-page-header > div > p:not(.member-page-kicker) {
    color: #9c9197;
    font-size: 12px;
}

.member-page-kicker {
    display: none;
}


/* ==================================================
   手機版
================================================== */

@media (max-width: 680px) {

    .profile-form {
        padding-right: 0;
        padding-left: 0;
    }

    .profile-form-section {
        padding: 25px 0;
    }

    .section-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    .profile-range-row {
        grid-template-columns:
            minmax(0, 1fr)
            22px
            minmax(0, 1fr);
    }

    .profile-option-group,
    .profile-choice-grid {
        gap: 5px;
    }

    .profile-option label,
    .profile-option > span,
    .profile-choice-card label {
        min-height: 34px;
        padding: 7px 10px;
        font-size: 11px;
    }

    .profile-save-button,
    #saveProfileButton {
        width: 100%;
    }

    .profile-custom-input-row input {
        flex: 1;
        width: auto;
    }
}/* =========================================================
   MyDating 個人資料頁－最終視覺修正版
   直接放在 style.css 最下面
========================================================= */


/* =========================================================
   1. 整體頁面寬度
========================================================= */

.member-shell-body {
    margin: 0;
    min-height: 100vh;
    background: #fff;
    color: #555;
    font-family:
        "Noto Sans TC",
        "Microsoft JhengHei",
        Arial,
        sans-serif;
}

.member-content {
    width: calc(100% - 250px);
    min-height: 100vh;
    margin-left: 250px;
    padding: 30px 45px 80px;
    background: #fff;
}

.member-page-header,
.profile-page,
#profileForm,
.profile-form,
.profile-progress-section,
.profile-progress-card {
    width: 100%;
    max-width: 950px;
    margin-right: auto;
    margin-left: auto;
}

.member-page-header {
    margin-bottom: 20px;
    padding: 0;
}

.member-page-header h1 {
    margin: 0 0 6px;
    color: #4d4147;
    font-size: 28px;
    font-weight: 700;
}

.member-page-header p {
    margin: 0;
    color: #999;
    font-size: 13px;
}


/* =========================================================
   2. 表單全部統一
========================================================= */

#profileForm,
.profile-form {
    display: block;
    padding: 0;
    background: #fff;
}

#profileForm *,
.profile-form * {
    box-sizing: border-box;
}

.profile-form-section,
.profile-avatar-section,
.profile-gallery-section {
    width: 100%;
    margin: 0;
    padding: 30px 0;
    border: 0;
    border-bottom: 1px solid #f1e3e8;
    border-radius: 0;
    background: #fff;
    box-shadow: none;
}

.profile-form-section:last-of-type {
    border-bottom: 0;
}


/* =========================================================
   3. 區塊標題
========================================================= */

.section-heading,
.profile-gallery-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin: 0 0 24px;
    padding: 0 0 12px;
    border-bottom: 1px solid #ee9fba;
}

.section-heading p {
    display: none;
}

.section-heading h2,
.profile-gallery-header h2,
.profile-gallery-header h3 {
    position: relative;
    margin: 0;
    padding-bottom: 8px;
    color: #493e44;
    font-size: 20px;
    font-weight: 700;
}

.section-heading h2::after,
.profile-gallery-header h2::after,
.profile-gallery-header h3::after {
    position: absolute;
    bottom: -13px;
    left: 0;
    width: 65px;
    height: 3px;
    border-radius: 999px;
    background: #f27b9f;
    content: "";
}

.section-heading > span,
.section-heading > small,
.profile-gallery-header p {
    margin: 0;
    color: #a2999e;
    font-size: 12px;
}


/* =========================================================
   4. 完成度
========================================================= */

.profile-progress-section,
.profile-progress-card {
    margin-bottom: 28px;
    padding: 22px 26px;
    border: 1px solid #efc6d3;
    border-radius: 4px;
    background: #fff;
    box-shadow: none;
}

.profile-progress-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 14px;
}

.profile-progress-header h2,
.profile-progress-header h3 {
    margin: 0;
    color: #e2668d;
    font-size: 18px;
    font-weight: 700;
}

.profile-progress-header p {
    margin: 4px 0 0;
    color: #999;
    font-size: 12px;
}

.profile-completion-badge,
#profileCompletionBadge {
    padding: 5px 12px;
    border: 1px solid #f3b7ca;
    border-radius: 999px;
    background: #fff4f7;
    color: #e2688e;
    font-size: 11px;
    font-weight: 700;
}

.profile-progress-track {
    width: 100%;
    height: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #f5e8ed;
}

.profile-progress-bar,
#profileProgressBar {
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(
        90deg,
        #f58eae,
        #155c2a
    );
    transition: width 0.3s ease;
}


/* =========================================================
   5. 基本資料雙欄排列
========================================================= */

.profile-field-grid {
    display: grid;
    grid-template-columns:
        repeat(2, minmax(0, 1fr));
    gap: 22px 26px;
    width: 100%;
}

.profile-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.profile-field.full-width {
    grid-column: 1 / -1;
}

.profile-field > label,
#profileForm > label,
#profileForm legend {
    color: #5b5056;
    font-size: 13px;
    font-weight: 500;
}

.profile-field > label span {
    color: #e16c91;
}


/* =========================================================
   6. 所有輸入框強制美化
========================================================= */

#profileForm input[type="text"],
#profileForm input[type="email"],
#profileForm input[type="number"],
#profileForm input[type="date"],
#profileForm input[type="tel"],
#profileForm input[type="url"],
#profileForm select,
#profileForm textarea,
.profile-field input:not([type="checkbox"]):not([type="radio"]),
.profile-field select,
.profile-field textarea {
    display: block;
    width: 100%;
    min-height: 46px;
    padding: 10px 13px;
    border: 1px solid #dcd5d8;
    border-radius: 3px;
    outline: none;
    background: #fff;
    color: #51484d;
    box-shadow: none;
    font: inherit;
    font-size: 13px;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

#profileForm textarea,
.profile-field textarea {
    min-height: 130px;
    resize: vertical;
    line-height: 1.75;
}

#profileForm input:focus,
#profileForm select:focus,
#profileForm textarea:focus {
    border-color: #e985a5;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(233, 133, 165, 0.12);
}

#profileForm input::placeholder,
#profileForm textarea::placeholder {
    color: #bbb2b7;
}


/* =========================================================
   7. 關於我、個性、生活型態的小區塊
========================================================= */

.profile-subsection {
    width: 100%;
    margin: 0;
    padding: 0;
}

.profile-subsection + .profile-subsection {
    margin-top: 26px;
    padding-top: 26px;
    border-top: 1px solid #f2eaed;
}

.profile-subsection-title {
    margin: 0 0 14px;
}

.profile-subsection-title > span {
    display: none;
}

.profile-subsection-title h3 {
    position: relative;
    margin: 0;
    padding-left: 14px;
    color: #5d5258;
    font-size: 14px;
    font-weight: 500;
}

.profile-subsection-title h3::before {
    position: absolute;
    top: 50%;
    left: 0;
    width: 7px;
    height: 7px;
    border: 1px solid #df7898;
    border-radius: 50%;
    content: "";
    transform: translateY(-50%);
}

.profile-subsection-title p {
    margin: 5px 0 0 14px;
    color: #aaa0a5;
    font-size: 11px;
}


/* =========================================================
   8. Checkbox、Radio 改成參考圖的粉色標籤
========================================================= */

.profile-option-group,
.profile-choice-grid,
#profileForm fieldset {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.profile-option,
.profile-choice-card {
    position: relative;
    display: inline-flex;
    margin: 0;
}

.profile-option input,
.profile-choice-card input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.profile-option label,
.profile-option > span,
.profile-choice-card label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    min-height: 36px;
    padding: 7px 13px;
    border: 1px solid #d8d2d5;
    border-radius: 9px;
    background: linear-gradient(
        180deg,
        #fff,
        #f8f8f8
    );
    color: #766c71;
    cursor: pointer;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.3;
    transition:
        border-color 0.18s ease,
        background 0.18s ease,
        color 0.18s ease;
}

.profile-option label:hover,
.profile-option > span:hover,
.profile-choice-card label:hover {
    border-color: #e6a4b9;
    background: #fff7f9;
    color: #dc6489;
}

.profile-option input:checked + label,
.profile-option input:checked + span,
.profile-choice-card input:checked + label {
    border-color: #f1c9d6;
    background: #fde6ed;
    color: #de5f87;
    box-shadow: none;
}

.profile-choice-icon {
    display: none;
}

.profile-choice-text {
    display: inline-flex;
}

.profile-choice-text strong {
    color: inherit;
    font-size: 12px;
    font-weight: 400;
}

.profile-choice-text small {
    display: none;
}


/* 支援 input 包在 label 裡面的寫法 */

#profileForm label:has(> input[type="checkbox"]),
#profileForm label:has(> input[type="radio"]) {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    width: auto;
    min-height: 35px;
    margin: 3px 3px 3px 0;
    padding: 7px 12px;
    border: 1px solid #d8d2d5;
    border-radius: 9px;
    background: linear-gradient(
        180deg,
        #fff,
        #f8f8f8
    );
    color: #756b70;
    cursor: pointer;
    font-size: 12px;
    font-weight: 400;
}

#profileForm label:has(> input[type="checkbox"]:checked),
#profileForm label:has(> input[type="radio"]:checked) {
    border-color: #f0c8d5;
    background: #fde6ed;
    color: #dd5e86;
}

#profileForm label:has(> input[type="checkbox"]) input,
#profileForm label:has(> input[type="radio"]) input {
    width: 13px;
    height: 13px;
    margin: 0;
    accent-color: #e87599;
}


/* 支援 input 在 label 前面的寫法 */

#profileForm input[type="checkbox"] + label,
#profileForm input[type="radio"] + label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    min-height: 35px;
    margin: 3px 4px 3px 0;
    padding: 7px 12px;
    border: 1px solid #d8d2d5;
    border-radius: 9px;
    background: linear-gradient(
        180deg,
        #fff,
        #f8f8f8
    );
    color: #756b70;
    cursor: pointer;
    font-size: 12px;
}

#profileForm input[type="checkbox"]:checked + label,
#profileForm input[type="radio"]:checked + label {
    border-color: #f0c8d5;
    background: #fde6ed;
    color: #dd5e86;
}


/* =========================================================
   9. 自我介紹
========================================================= */

.profile-textarea-wrapper {
    position: relative;
    width: 100%;
}

.profile-textarea-wrapper textarea {
    padding-bottom: 38px;
}

.profile-text-counter {
    position: absolute;
    right: 12px;
    bottom: 10px;
    color: #aaa1a6;
    font-size: 11px;
}

.profile-text-counter span {
    color: #de6a8e;
}


/* =========================================================
   10. 大頭照
========================================================= */

.profile-avatar-layout {
    display: flex;
    align-items: center;
    gap: 28px;
}

.profile-avatar-wrapper {
    position: relative;
    flex: 0 0 auto;
    width: 150px;
    height: 150px;
}

.profile-avatar-preview,
#profileAvatarPreview {
    display: block;
    width: 150px;
    height: 150px;
    border: 1px solid #e4dadd;
    border-radius: 3px;
    background: #eee;
    box-shadow: none;
    object-fit: cover;
}

.profile-avatar-info {
    flex: 1;
}

.profile-avatar-info h3 {
    margin: 0 0 7px;
    color: #554a50;
    font-size: 17px;
}

.profile-avatar-info p {
    margin: 0 0 15px;
    color: #9d9398;
    font-size: 12px;
    line-height: 1.7;
}

.profile-avatar-upload-button,
.avatar-upload-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 9px 28px;
    border: 0;
    border-radius: 999px;
    background: linear-gradient(
        90deg,
        #f793b0,
        #ef7699
    );
    color: #fff;
    box-shadow: 0 6px 16px rgba(229, 104, 143, 0.25);
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
}


/* =========================================================
   11. 六張照片區
========================================================= */

.profile-photo-grid,
#profilePhotoGrid {
    display: grid;
    grid-template-columns:
        repeat(6, minmax(0, 1fr));
    gap: 10px;
    width: 100%;
}

.profile-photo-card {
    position: relative;
    width: 100%;
    min-width: 0;
    overflow: hidden;
    border: 1px solid #e8e4e6;
    border-radius: 2px;
    background: #f2f2f2;
    box-shadow: none;
    aspect-ratio: 1 / 1;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.profile-photo-card:hover {
    z-index: 2;
    transform: translateY(-3px);
    border-color: #eaa0b8;
    box-shadow: 0 8px 20px rgba(202, 106, 137, 0.18);
}

.profile-photo-card::before {
    position: absolute;
    top: 8px;
    left: -29px;
    z-index: 5;
    width: 98px;
    padding: 4px 0;
    background: #f17d9e;
    color: #fff;
    content: "生活照";
    font-size: 10px;
    text-align: center;
    transform: rotate(-45deg);
    pointer-events: none;
}

.profile-photo-card:first-child::before {
    content: "主要照片";
    background: #155c2a;
}

.gallery-photo-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition:
        transform 0.3s ease,
        filter 0.3s ease;
}

.profile-photo-card:hover .gallery-photo-image {
    transform: scale(1.05);
    filter: brightness(0.9);
}

.photo-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    width: 100%;
    height: 100%;
    min-height: 135px;
    padding: 14px 8px;
    background: #f3f3f3;
    color: #aaa;
    cursor: pointer;
    text-align: center;
}

.photo-empty::before {
    margin-bottom: 8px;
    content: "📷";
    opacity: 0.3;
    filter: grayscale(1);
    font-size: 38px;
}

.photo-empty span {
    display: none;
}

.photo-empty small {
    color: #aaa;
    font-size: 11px;
}

.photo-empty:hover {
    background: #fff3f7;
}

.photo-empty:hover small {
    color: #dc688b;
}

.delete-photo-button {
    position: absolute;
    right: 8px;
    bottom: 8px;
    z-index: 8;
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(45, 37, 41, 0.78);
    color: #fff;
    cursor: pointer;
    opacity: 0;
    transition:
        opacity 0.2s ease,
        background 0.2s ease;
}

.profile-photo-card:hover .delete-photo-button {
    opacity: 1;
}

.delete-photo-button:hover {
    background: #155c2a;
}

.profile-photo-count,
#profilePhotoCount {
    padding: 5px 12px;
    border: 1px solid #efbfd0;
    border-radius: 999px;
    background: #fff6f8;
    color: #dd678b;
    font-size: 11px;
    font-weight: 700;
}

.profile-photo-message,
#profilePhotoMessage {
    margin: 18px 0 0;
    padding: 13px 16px;
    border: 1px dashed #e4a7ba;
    border-radius: 3px;
    background: #fff7f9;
    color: #c65e7e;
    font-size: 12px;
    line-height: 1.7;
}


/* =========================================================
   12. VIP 提示
========================================================= */

.profile-vip-hint {
    display: block;
    width: 100%;
    margin-top: 18px;
    padding: 0;
    overflow: hidden;
    border: 1px dashed #e3a5b8;
    border-radius: 3px;
    background: #fff;
}

.profile-vip-hint strong {
    display: block;
    padding: 10px 13px;
    background: #fff0f4;
    color: #cb617f;
    font-size: 13px;
}

.profile-vip-hint p {
    margin: 0;
    padding: 12px 13px;
    color: #766b70;
    font-size: 12px;
    line-height: 1.9;
}

.profile-vip-hint > span {
    display: none;
}


/* =========================================================
   13. 儲存按鈕
========================================================= */

.profile-save-section {
    position: static;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-top: 20px;
    padding: 32px 0;
    border: 0;
    border-top: 1px solid #f0e4e8;
    border-radius: 0;
    background: #fff;
    box-shadow: none;
}

.profile-save-section p {
    display: none;
}

.profile-save-button,
#saveProfileButton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 320px;
    min-width: 0;
    min-height: 48px;
    padding: 11px 24px;
    border: 0;
    border-radius: 999px;
    background: linear-gradient(
        90deg,
        #fa91ae,
        #ef7498
    );
    color: #fff;
    box-shadow: 0 7px 20px rgba(226, 101, 140, 0.28);
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.profile-save-button:hover,
#saveProfileButton:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(226, 101, 140, 0.35);
}

.profile-save-button:disabled,
#saveProfileButton:disabled {
    cursor: not-allowed;
    opacity: 0.55;
    transform: none;
}


/* =========================================================
   14. 錯誤與成功訊息
========================================================= */

.profile-message {
    width: 100%;
    margin: 0 0 20px;
    padding: 12px 15px;
    border-radius: 3px;
    font-size: 12px;
}

.profile-message[hidden] {
    display: none;
}

.profile-message.success {
    border: 1px solid #c5e2ce;
    background: #f1faf4;
    color: #438158;
}

.profile-message.error {
    border: 1px solid #edc3c9;
    background: #fff3f4;
    color: #c45561;
}

.profile-message.loading {
    border: 1px solid #edd0da;
    background: #fff5f8;
    color: #c85e80;
}


/* =========================================================
   15. 平板
========================================================= */

@media (max-width: 1050px) {

    .member-content {
        width: calc(100% - 220px);
        margin-left: 220px;
        padding: 28px 25px 70px;
    }

    .profile-photo-grid,
    #profilePhotoGrid {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));
    }
}


/* =========================================================
   16. 手機
========================================================= */

@media (max-width: 760px) {

    .member-content {
        width: 100%;
        margin-left: 0;
        padding: 78px 16px 55px;
    }

    .profile-field-grid {
        grid-template-columns: 1fr;
    }

    .profile-field.full-width {
        grid-column: auto;
    }

    .profile-avatar-layout {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-avatar-wrapper,
    .profile-avatar-preview,
    #profileAvatarPreview {
        width: 125px;
        height: 125px;
    }

    .profile-photo-grid,
    #profilePhotoGrid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .delete-photo-button {
        opacity: 1;
    }

    .section-heading,
    .profile-gallery-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 7px;
    }

    .profile-save-button,
    #saveProfileButton {
        width: 100%;
    }
}/* =========================================================
   目前 profile.html 真正使用的選項區樣式
========================================================= */

.profile-choice-section {
    width: 100%;
    margin-top: 28px;
    padding-top: 26px;
    border-top: 1px solid #f1e7eb;
}

.profile-choice-section:first-child {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}


/* =========================================================
   選項區標題
========================================================= */

.profile-choice-title {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 15px;
    padding-left: 14px;
    color: #554a50;
    font-size: 14px;
    font-weight: 600;
}

.profile-choice-title::before {
    position: absolute;
    top: 50%;
    left: 0;
    width: 7px;
    height: 7px;
    border: 1px solid #e47e9e;
    border-radius: 50%;
    background: #ffffff;
    content: "";
    transform: translateY(-50%);
}

.profile-choice-title small {
    color: #a59ba0;
    font-size: 11px;
    font-weight: 400;
}


/* =========================================================
   選項排列
========================================================= */

.profile-choice-group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    width: 100%;
}


/* =========================================================
   每一個選項標籤
========================================================= */

.profile-choice-chip {
    position: relative;
    display: inline-flex;
    margin: 0;
    cursor: pointer;
}

.profile-choice-chip input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.profile-choice-chip span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 37px;
    padding: 8px 14px;
    border: 1px solid #d9d2d6;
    border-radius: 9px;
    background:
        linear-gradient(
            180deg,
            #ffffff 0%,
            #f8f7f8 100%
        );
    color: #746a6f;
    box-shadow:
        0 1px 2px rgba(70, 50, 60, 0.04);
    font-size: 12px;
    font-weight: 400;
    line-height: 1.25;
    user-select: none;
    transition:
        color 0.18s ease,
        border-color 0.18s ease,
        background 0.18s ease,
        box-shadow 0.18s ease,
        transform 0.18s ease;
}

.profile-choice-chip:hover span {
    transform: translateY(-1px);
    border-color: #e5a3b8;
    background: #fff6f9;
    color: #db6287;
    box-shadow:
        0 4px 10px rgba(219, 98, 135, 0.09);
}

.profile-choice-chip input:checked + span {
    border-color: #f2c4d3;
    background:
        linear-gradient(
            135deg,
            #ffeef3,
            #fce2ea
        );
    color: #db5b84;
    box-shadow:
        0 4px 12px rgba(221, 91, 132, 0.12);
}

.profile-choice-chip input:checked + span::before {
    margin-right: 5px;
    content: "✓";
    color: #155c2a;
    font-size: 11px;
    font-weight: 800;
}

.profile-choice-chip input:focus-visible + span {
    outline: 3px solid rgba(231, 111, 150, 0.18);
    outline-offset: 2px;
}


/* =========================================================
   必填標示
========================================================= */

.profile-choice-title .required,
.profile-choice-title em {
    color: #e4688f;
    font-style: normal;
}


/* =========================================================
   整組欄位間距
========================================================= */

.profile-choice-section + .profile-choice-section {
    margin-top: 28px;
}


/* =========================================================
   手機版
========================================================= */

@media (max-width: 680px) {

    .profile-choice-section {
        margin-top: 23px;
        padding-top: 22px;
    }

    .profile-choice-group {
        gap: 7px;
    }

    .profile-choice-chip span {
        min-height: 35px;
        padding: 7px 11px;
        font-size: 11px;
    }
}/* =========================================================
   基本資料區重新排版
   左側照片、右側基本資料
========================================================= */

.profile-basic-layout {
    display: grid;
    grid-template-columns: 210px minmax(0, 1fr);
    align-items: start;
    gap: 34px;
    width: 100%;
}


/* 沒有 profile-basic-layout 時，
   也支援基本資料區直接包含照片與欄位的結構 */

.profile-basic-section {
    width: 100%;
}

.profile-basic-section .profile-avatar-section {
    margin: 0;
}


/* =========================================================
   左側照片欄
========================================================= */

.profile-photo-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.profile-avatar-section {
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
}

.profile-avatar-layout {
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.profile-avatar-wrapper {
    position: relative;
    width: 165px;
    height: 165px;
    margin: 0 auto;
}

.profile-avatar-preview,
#profileAvatarPreview {
    display: block;
    width: 165px;
    height: 165px;
    border: 1px solid #e7dde1;
    border-radius: 4px;
    background:
        linear-gradient(
            145deg,
            #f4f2f3,
            #e9e7e8
        );
    box-shadow:
        0 7px 18px rgba(76, 51, 63, 0.08);
    object-fit: cover;
}

.profile-avatar-preview[src=""],
#profileAvatarPreview[src=""] {
    color: transparent;
}

.profile-avatar-loading,
#profileAvatarLoading {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.82);
    color: #df678b;
    font-size: 12px;
    font-weight: 700;
}

.profile-avatar-loading[hidden],
#profileAvatarLoading[hidden] {
    display: none;
}

.profile-avatar-info {
    display: flex;
    align-items: center;
    flex-direction: column;
    width: 100%;
    text-align: center;
}

.profile-avatar-info h3 {
    margin: 0 0 5px;
    color: #554a50;
    font-size: 15px;
    font-weight: 600;
}

.profile-avatar-info p {
    margin: 0 0 12px;
    color: #9e9499;
    font-size: 11px;
    line-height: 1.7;
}

.profile-avatar-upload-button,
.avatar-upload-button,
label[for="profileAvatarInput"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 145px;
    min-height: 41px;
    padding: 9px 20px;
    border: 0;
    border-radius: 4px;
    background:
        linear-gradient(
            90deg,
            #f592ae,
            #ed7397
        );
    color: #ffffff;
    box-shadow:
        0 6px 15px rgba(226, 103, 143, 0.23);
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease;
}

.profile-avatar-upload-button:hover,
.avatar-upload-button:hover,
label[for="profileAvatarInput"]:hover {
    transform: translateY(-1px);
    box-shadow:
        0 8px 19px rgba(226, 103, 143, 0.3);
}

#profileAvatarInput {
    display: none;
}


/* =========================================================
   六張生活照縮圖
========================================================= */

.profile-gallery-section {
    width: 100%;
    margin-top: 22px;
    padding: 0;
    border: 0;
    background: transparent;
}

.profile-gallery-header {
    display: block;
    margin: 0 0 10px;
    padding: 0;
    border: 0;
    text-align: center;
}

.profile-gallery-header h2,
.profile-gallery-header h3 {
    margin: 0 0 4px;
    padding: 0;
    color: #54494f;
    font-size: 13px;
    font-weight: 600;
}

.profile-gallery-header h2::after,
.profile-gallery-header h3::after {
    display: none;
}

.profile-gallery-header p {
    margin: 0;
    color: #aaa0a5;
    font-size: 10px;
    line-height: 1.5;
}

.profile-photo-count,
#profilePhotoCount {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 7px;
    padding: 3px 10px;
    border: 1px solid #f0bdcc;
    border-radius: 999px;
    background: #fff5f8;
    color: #dc678b;
    font-size: 10px;
    font-weight: 700;
}

.profile-photo-grid,
#profilePhotoGrid {
    display: grid;
    grid-template-columns:
        repeat(3, minmax(0, 1fr));
    gap: 6px;
    width: 100%;
    max-width: 190px;
    margin: 0 auto;
}

.profile-photo-card {
    position: relative;
    width: 100%;
    min-width: 0;
    overflow: hidden;
    border: 1px solid #eadfe3;
    border-radius: 3px;
    background: #f4f2f3;
    box-shadow: none;
    aspect-ratio: 1 / 1;
    transition:
        transform 0.18s ease,
        border-color 0.18s ease,
        box-shadow 0.18s ease;
}

.profile-photo-card:hover {
    z-index: 3;
    transform: translateY(-2px);
    border-color: #e69ab3;
    box-shadow:
        0 6px 14px rgba(201, 102, 135, 0.16);
}

.profile-photo-card::before {
    position: absolute;
    top: 4px;
    left: -25px;
    z-index: 5;
    width: 72px;
    padding: 3px 0;
    background: #23723a;
    color: #ffffff;
    content: "生活照";
    font-size: 7px;
    line-height: 1;
    text-align: center;
    transform: rotate(-45deg);
    pointer-events: none;
}

.profile-photo-card:first-child::before {
    content: "封面";
    background: #ed678f;
}

.gallery-photo-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition:
        transform 0.25s ease,
        filter 0.25s ease;
}

.profile-photo-card:hover .gallery-photo-image {
    transform: scale(1.06);
    filter: brightness(0.92);
}

.photo-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    width: 100%;
    height: 100%;
    min-height: 55px;
    padding: 6px 3px;
    background: #f4f2f3;
    color: #b3aaae;
    cursor: pointer;
    text-align: center;
}

.photo-empty::before {
    margin-bottom: 3px;
    content: "＋";
    color: #d58ca3;
    opacity: 0.8;
    font-size: 18px;
    line-height: 1;
}

.photo-empty span {
    display: none;
}

.photo-empty small {
    max-width: 48px;
    overflow: hidden;
    color: #a99fa4;
    font-size: 7px;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.photo-empty:hover {
    background: #fff2f6;
}

.photo-empty:hover::before,
.photo-empty:hover small {
    color: #dc6489;
}

.delete-photo-button {
    position: absolute;
    right: 3px;
    bottom: 3px;
    z-index: 8;
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(50, 42, 46, 0.78);
    color: #ffffff;
    cursor: pointer;
    font-size: 9px;
    opacity: 0;
    transition:
        opacity 0.18s ease,
        background 0.18s ease;
}

.profile-photo-card:hover .delete-photo-button {
    opacity: 1;
}

.delete-photo-button:hover {
    background: #db5268;
}


/* =========================================================
   VIP 照片提示
========================================================= */

.profile-photo-message,
#profilePhotoMessage {
    position: relative;
    width: 100%;
    max-width: 190px;
    margin: 12px auto 0;
    padding: 10px 9px 10px 31px;
    border: 1px dashed #e8afc0;
    border-radius: 3px;
    background: #fff7f9;
    color: #c45d7d;
    font-size: 9px;
    font-weight: 500;
    line-height: 1.55;
    text-align: left;
}

.profile-photo-message::before,
#profilePhotoMessage::before {
    position: absolute;
    top: 50%;
    left: 9px;
    display: grid;
    place-items: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #ed7d9e;
    color: #ffffff;
    content: "V";
    font-size: 8px;
    font-weight: 800;
    transform: translateY(-50%);
}


/* =========================================================
   右側基本資料欄
========================================================= */

.profile-basic-fields {
    min-width: 0;
    width: 100%;
}

.profile-basic-fields .profile-field-grid {
    display: grid;
    grid-template-columns:
        repeat(2, minmax(0, 1fr));
    gap: 19px 20px;
    width: 100%;
}

.profile-basic-fields .profile-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-width: 0;
}

.profile-basic-fields .profile-field.full-width {
    grid-column: 1 / -1;
}

.profile-basic-fields .profile-field > label {
    color: #5b5056;
    font-size: 12px;
    font-weight: 500;
}

.profile-basic-fields input:not([type="radio"]):not([type="checkbox"]),
.profile-basic-fields select {
    width: 100%;
    min-height: 44px;
    padding: 9px 12px;
    border: 1px solid #ddd5d9;
    border-radius: 3px;
    outline: none;
    background: #ffffff;
    color: #51484d;
    font: inherit;
    font-size: 12px;
}

.profile-basic-fields input:focus,
.profile-basic-fields select:focus {
    border-color: #e787a5;
    box-shadow:
        0 0 0 3px rgba(231, 135, 165, 0.11);
}


/* =========================================================
   基本資料區的標題
========================================================= */

.profile-basic-heading {
    position: relative;
    margin: 0 0 24px;
    padding: 0 0 12px;
    border-bottom: 1px solid #efa3bb;
}

.profile-basic-heading h2 {
    margin: 0;
    color: #493e44;
    font-size: 20px;
    font-weight: 700;
}

.profile-basic-heading::after {
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 65px;
    height: 3px;
    border-radius: 999px;
    background: #ef789c;
    content: "";
}


/* =========================================================
   桌面內容寬度放大
========================================================= */

.member-content {
    width: calc(100% - 250px);
    margin-left: 250px;
    padding: 32px 48px 80px;
}

.member-page-header,
.profile-page,
#profileForm,
.profile-form,
.profile-progress-section,
.profile-progress-card {
    width: 100%;
    max-width: 1020px;
    margin-right: auto;
    margin-left: auto;
}


/* =========================================================
   平板
========================================================= */

@media (max-width: 1000px) {

    .profile-basic-layout {
        grid-template-columns: 180px minmax(0, 1fr);
        gap: 25px;
    }

    .profile-avatar-wrapper,
    .profile-avatar-preview,
    #profileAvatarPreview {
        width: 145px;
        height: 145px;
    }

    .profile-photo-grid,
    #profilePhotoGrid {
        max-width: 170px;
    }
}


/* =========================================================
   手機
========================================================= */

@media (max-width: 720px) {

    .profile-basic-layout {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .profile-photo-column {
        max-width: 310px;
        margin: 0 auto;
    }

    .profile-avatar-wrapper,
    .profile-avatar-preview,
    #profileAvatarPreview {
        width: 145px;
        height: 145px;
    }

    .profile-photo-grid,
    #profilePhotoGrid {
        max-width: 260px;
        gap: 8px;
    }

    .photo-empty {
        min-height: 75px;
    }

    .profile-photo-message,
    #profilePhotoMessage {
        max-width: 260px;
    }

    .profile-basic-fields .profile-field-grid {
        grid-template-columns: 1fr;
    }

        .profile-basic-fields .profile-field.full-width {
        grid-column: auto;
    }
}
/* ==================================================
   手機版全域修正 (補丁) — 不影響桌機版
================================================== */
@media screen and (max-width: 780px) {

    /* 修正 sidebar 在手機版收起來 */
    .member-sidebar {
        position: fixed !important;
        top: 0 !important;
        left: -300px !important;
        width: 260px !important;
        height: 100vh !important;
        min-height: 0 !important;
        z-index: 1100 !important;
        overflow-y: auto !important;
        transition: left 0.25s ease !important;
    }

    .member-sidebar.show {
        left: 0 !important;
    }

    /* 修正主內容區佔滿全寬 */
    .member-content {
        width: 100% !important;
        margin-left: 0 !important;
        padding: 82px 16px 55px !important;
    }

    /* 修正 grid layout 改成 block */
    .member-shell {
        display: block !important;
        width: 100% !important;
        padding: 0 !important;
    }

    /* 修正漢堡選單顯示 */
    .mobile-menu-button {
        display: grid !important;
        place-items: center !important;
    }

    /* 修正 sidebar overlay */
    .sidebar-overlay {
        display: none;
        position: fixed;
        inset: 0;
        z-index: 1050;
        background: rgba(0,0,0,0.35);
    }

    .sidebar-overlay.show {
        display: block;
    }

    /* 修正 chat-list 的 VIP 標籤位置 */
    .message-item-vip,
    .message-item .vip-badge {
        position: absolute;
        bottom: 0;
        right: 0;
        font-size: 8px;
    }

    .message-item-avatar {
        position: relative;
    }

    /* 防止文字被擠成一行一個字 */
    * {
        word-break: normal !important;
        overflow-wrap: break-word !important;
        white-space: normal !important;
    }

    /* 修正 profile 頁面不要超出螢幕 */
    .profile-form-section,
    .profile-progress-card,
    .profile-avatar-section,
    .profile-gallery-section {
        max-width: 100% !important;
        overflow: hidden !important;
    }
}

/* ===== MeetU 自然系主題覆蓋 ===== */
:root {
    --meetu-sidebar-bg: #2d4a3e;
    --meetu-sidebar-text: rgba(255,255,255,0.75);
    --meetu-sidebar-active-bg: rgba(255,255,255,0.15);
    --meetu-sidebar-hover-bg: rgba(255,255,255,0.1);
    --meetu-green: #3d6b5a;
    --meetu-bg: #f0ece2;
    --meetu-card-bg: #ffffff;
    --meetu-border: #e2dbd0;
    --meetu-text: #2c2c2c;
    --meetu-text-muted: #7a7a6e;
}
body.member-shell-body { background: var(--meetu-bg) !important; font-family: 'Noto Sans TC', sans-serif !important; }
.member-sidebar { background: var(--meetu-sidebar-bg) !important; border: none !important; box-shadow: none !important; }
.sidebar-top::after { background: rgba(255,255,255,0.1) !important; }
.sidebar-top h3, #sidebarMemberName { color: #ffffff !important; }
.sidebar-avatar { border-radius: 50% !important; border: 2px solid rgba(255,255,255,0.3) !important; }
.sidebar-member-meta .sidebar-vip-status, .sidebar-member-meta .sidebar-gender-status { color: rgba(255,255,255,0.7) !important; background: rgba(255,255,255,0.1) !important; }
.sidebar-vip-status.is-vip { background: rgba(255,255,255,0.2) !important; color: #ffffff !important; }
.sidebar-profile-link { color: rgba(255,255,255,0.6) !important; }
.sidebar-profile-link:hover { color: #ffffff !important; }
.sidebar-item { color: var(--meetu-sidebar-text) !important; }
.sidebar-item:hover { background: var(--meetu-sidebar-hover-bg) !important; color: #ffffff !important; transform: none !important; }
.sidebar-item.active { background: var(--meetu-sidebar-active-bg) !important; color: #ffffff !important; }
.sidebar-item.active .sidebar-icon { filter: none !important; opacity: 1 !important; }
.sidebar-icon { filter: brightness(10) !important; opacity: 0.75 !important; }
.sidebar-item:hover .sidebar-icon { filter: brightness(10) !important; opacity: 1 !important; }
.sidebar-text { color: inherit !important; }
.sidebar-badge { background: #ee1010 !important; }
.sidebar-vip-item { background: rgba(255,255,255,0.08) !important; border-radius: 10px !important; }
.sidebar-vip-item .sidebar-icon { filter: none !important; opacity: 1 !important; }
.member-content { background: var(--meetu-bg) !important; }
.member-page-header h1, .member-page-title { color: var(--meetu-text) !important; }
.member-page-kicker { color: var(--meetu-green) !important; }
.member-summary-card, .dashboard-section, .dashboard-feature-card { background: var(--meetu-card-bg) !important; border: 1px solid var(--meetu-border) !important; border-radius: 16px !important; }
.dashboard-feature-card:hover { border-color: var(--meetu-green) !important; transform: translateY(-2px) !important; box-shadow: 0 6px 20px rgba(61,107,90,0.12) !important; }
.vip-feature-card { background: linear-gradient(135deg, #2d4a3e, #3d6b5a) !important; border: none !important; }
.vip-feature-card * { color: #ffffff !important; }
.section-heading p { color: var(--meetu-green) !important; }
.section-heading h2 { color: var(--meetu-text) !important; }
.role-badge, .mini-vip-badge { background: var(--meetu-green) !important; color: #ffffff !important; }
.search-button:not(.secondary) { background: var(--meetu-green) !important; color: #ffffff !important; border-radius: 50px !important; }
.member-card { border: 1px solid var(--meetu-border) !important; border-radius: 16px !important; }
.member-card .view-btn, .view-button { background: var(--meetu-green) !important; color: #ffffff !important; border-radius: 50px !important; }
.member-content input, .member-content select, .member-content textarea { border: 1.5px solid var(--meetu-border) !important; border-radius: 12px !important; }
.member-content input:focus, .member-content select:focus, .member-content textarea:focus { border-color: var(--meetu-green) !important; }
.form-page { background: var(--meetu-bg) !important; }
.form-card { background: var(--meetu-card-bg) !important; border-radius: 20px !important; }
.form-card h1 { color: #2d4f2a !important; }
.submit-button, .btn { background: var(--meetu-green) !important; border-radius: 50px !important; box-shadow: 0 10px 25px rgba(61,107,90,0.2) !important; }
.navbar { background: rgba(255,255,255,0.88) !important; }
.logo { color: var(--meetu-green) !important; }
.small-heart { background: linear-gradient(135deg, #3d6b5a, #2d4a3e) !important; }
body { background: var(--meetu-bg) !important; }
@media (max-width: 780px) { .member-sidebar { background: var(--meetu-sidebar-bg) !important; } }

/* ===== Sidebar 統一寬度和定位修正 ===== */
@media (min-width: 781px) {
    /* 與首頁一致：所有桌面頁面固定使用 260px 側邊欄 */
    .member-sidebar {
        width: 260px !important;
        min-width: 260px !important;
        max-width: 260px !important;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        height: 100vh !important;
        min-height: 100vh !important;
        overflow-y: auto !important;
        z-index: 100 !important;
        padding: 0 !important;
        border-radius: 0 !important;
        margin: 0 !important;
    }
    .member-content {
        margin-left: 260px !important;
        width: calc(100% - 260px) !important;
    }
}
.sidebar-top::after { display: none !important; }
.sidebar-icon {
    width: 20px !important;
    min-width: 20px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    filter: none !important;
    opacity: 1 !important;
    font-size: 14px !important;
}
.sidebar-icon svg {
    stroke: rgba(255,255,255,0.75) !important;
}
.sidebar-item:hover .sidebar-icon svg,
.sidebar-item.active .sidebar-icon svg {
    stroke: #ffffff !important;
}
.sidebar-text {
    font-size: 14px !important;
    white-space: nowrap !important;
}
.sidebar-menu {
    padding: 12px 10px !important;
}
.sidebar-item {
    min-height: 40px !important;
    padding: 0 10px !important;
    gap: 10px !important;
    border-radius: 8px !important;
    margin-bottom: 2px !important;
}
@media (max-width: 780px) {
    .member-sidebar {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 260px !important;
        min-width: 260px !important;
        max-width: 260px !important;
        height: 100vh !important;
        z-index: 1100 !important;
        overflow-y: auto !important;
        transform: translateX(-100%) !important;
        transition: transform 0.3s ease !important;
        padding: 0 !important;
        border-radius: 0 !important;
        margin: 0 !important;
    }
    .member-sidebar.show {
        transform: translateX(0) !important;
    }
    .member-content {
        margin-left: 0 !important;
        width: 100% !important;
    }
    .mobile-menu-button {
        display: grid !important;
        place-items: center !important;
        position: fixed !important;
        top: 14px !important;
        left: 14px !important;
        z-index: 1200 !important;
        width: 42px !important;
        height: 42px !important;
        background: #155c2a !important;
        color: #fff !important;
        border: none !important;
        border-radius: 50% !important;
        font-size: 20px !important;
        cursor: pointer !important;
        box-shadow: 0 4px 12px rgba(21,92,42,0.3) !important;
    }
    .sidebar-overlay {
        display: none;
        position: fixed;
        inset: 0;
        z-index: 1050;
        background: rgba(0,0,0,0.4);
    }
    .sidebar-overlay.show {
        display: block;
    }
}


/* ========== MeetU 深綠色側邊欄主題 ========== */
.member-sidebar {
    background: #2d4a3e !important;
    color: #fff !important;
}
.member-sidebar .sidebar-logo,
.member-sidebar .sidebar-brand {
    color: #fff !important;
}
.member-sidebar .sidebar-nav-item,
.member-sidebar .sidebar-nav-link,
.member-sidebar a {
    color: rgba(255,255,255,0.85) !important;
}
.member-sidebar .sidebar-nav-item:hover,
.member-sidebar .sidebar-nav-link:hover,
.member-sidebar a:hover {
    background: rgba(255,255,255,0.1) !important;
    color: #fff !important;
}
.member-sidebar .sidebar-nav-item.active,
.member-sidebar .sidebar-nav-link.active {
    background: rgba(255,255,255,0.15) !important;
    color: #fff !important;
}
.member-sidebar .sidebar-upgrade-card {
    background: rgba(255,255,255,0.1) !important;
    border: 1px solid rgba(255,255,255,0.2) !important;
}
.primary-button, #saveProfileButton, .submit-button {
    background: linear-gradient(90deg, #155c2a, #23723a) !important;
    box-shadow: 0 10px 25px rgba(21, 92, 42, 0.3) !important;
    color: #fff !important;
}
