:root {
    --bg: #111114;
    --panel: #1b1b22;
    --panel-2: #24242c;
    --text: #f7f7f7;
    --muted: #a8a8b3;
    --gold: #d6a94a;
    --pink: #e85c8b;
    --border: rgba(255,255,255,.1);
}

body {
    background:
        radial-gradient(circle at top left, rgba(232,92,139,.16), transparent 28rem),
        radial-gradient(circle at top right, rgba(214,169,74,.13), transparent 26rem),
        var(--bg);
    color: var(--text);
    font-family: "Microsoft JhengHei", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

a { color: inherit; }
.site-header {
    background: rgba(10,10,14,.92);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(8px);
}
.site-footer {
    background: #0b0b0e;
    border-top: 1px solid var(--border);
}

.home-hero {
    padding: 28px 0 20px;
}
.hero-slider {
    border-radius: 28px;
    overflow: hidden;
    border: 1px solid var(--border);
    box-shadow: 0 18px 50px rgba(0,0,0,.28);
}
.hero-slide {
    min-height: 440px;
    background:
        linear-gradient(90deg, rgba(0,0,0,.78), rgba(0,0,0,.24)),
        radial-gradient(circle at top right, rgba(232,92,139,.35), transparent 24rem),
        linear-gradient(135deg, #252531, #111116);
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
}
.hero-slide-content {
    padding: 56px;
    max-width: 680px;
}
.hero-slide h1 {
    font-size: clamp(2rem, 5vw, 4.6rem);
    font-weight: 900;
    line-height: 1.05;
}
.hero-slide p {
    color: rgba(255,255,255,.78);
    font-size: 1.2rem;
    margin: 18px 0 26px;
}
.hero-search {
    margin-top: -32px;
    position: relative;
    z-index: 5;
}

.btn-gold {
    background: linear-gradient(135deg, #e9c46a, #b88a28);
    border: none;
    color: #111;
    font-weight: 700;
}
.btn-pink {
    background: linear-gradient(135deg, #ff7aa8, #c93c71);
    border: none;
    color: #fff;
    font-weight: 700;
}
.btn-dark-soft {
    background: rgba(255,255,255,.08);
    border: 1px solid var(--border);
    color: var(--text);
}
.section-title {
    font-weight: 900;
    margin-bottom: 18px;
}
.filter-box,
.dark-card {
    background: rgba(27,27,34,.94);
    border: 1px solid var(--border);
    border-radius: 22px;
    padding: 18px;
}
.form-control,
.form-select {
    background-color: #111116;
    color: #fff;
    border-color: rgba(255,255,255,.16);
    min-height: 44px;
}
.form-control:focus,
.form-select:focus {
    background-color: #111116;
    color: #fff;
    border-color: var(--gold);
    box-shadow: 0 0 0 .25rem rgba(214,169,74,.12);
}
.form-select option {
    color: #111;
}
.member-card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 22px;
    overflow: hidden;
    height: 100%;
    transition: transform .2s ease, border-color .2s ease;
}
.member-card:hover {
    transform: translateY(-4px);
    border-color: rgba(214,169,74,.45);
}
.member-photo {
    height: 260px;
    background: linear-gradient(135deg, #343443, #19191f);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,.45);
    font-size: 4rem;
    font-weight: 800;
}
.detail-photo {
    height: 560px;
}
.badge-soft {
    background: rgba(255,255,255,.1);
    color: #fff;
    border: 1px solid var(--border);
}
.badge-gold {
    background: rgba(214,169,74,.18);
    color: #f7d58b;
    border: 1px solid rgba(214,169,74,.35);
}
.badge-pink {
    background: rgba(232,92,139,.16);
    color: #ff9fc0;
    border: 1px solid rgba(232,92,139,.35);
}
.member-price {
    color: #ffd480;
    font-weight: 800;
}
.spec-line {
    color: rgba(255,255,255,.72);
    font-size: .92rem;
}
.area-list a {
    display: inline-block;
    padding: 8px 12px;
    margin: 4px;
    border-radius: 999px;
    background: rgba(255,255,255,.07);
    text-decoration: none;
    color: #fff;
    border: 1px solid var(--border);
}
.area-list a:hover {
    border-color: var(--gold);
}
.admin-layout {
    min-height: 100vh;
    background: #f5f5f7;
    color: #222;
}
.admin-card {
    background: #fff;
    border-radius: 16px;
    padding: 18px;
    box-shadow: 0 8px 24px rgba(0,0,0,.06);
}
.table > :not(caption) > * > * {
    vertical-align: middle;
}

@media (max-width: 991px) {
    .home-hero { padding-top: 16px; }
    .hero-slide {
        min-height: 340px;
    }
    .hero-slide-content {
        padding: 34px 24px;
    }
    .hero-search {
        margin-top: 12px;
    }
    .filter-box {
        border-radius: 18px;
    }
}

@media (max-width: 768px) {
    .container {
        padding-left: 14px;
        padding-right: 14px;
    }
    .hero-slider {
        border-radius: 18px;
    }
    .hero-slide {
        min-height: 300px;
    }
    .hero-slide h1 {
        font-size: 2.05rem;
    }
    .hero-slide p {
        font-size: 1rem;
    }
    .member-card {
        border-radius: 16px;
    }
    .member-photo {
        height: 190px;
        font-size: 3rem;
    }
    .member-card .p-3 {
        padding: 12px !important;
    }
    .member-card h5 {
        font-size: 1rem;
    }
    .member-price {
        font-size: .95rem;
    }
    .detail-photo {
        height: 420px;
    }
    .btn-lg {
        padding: .65rem 1rem;
        font-size: 1rem;
    }
}

.member-media-slider {
    border-radius: 22px;
    overflow: hidden;
}
.media-frame {
    background: linear-gradient(135deg, #343443, #19191f);
    border-radius: 22px;
    overflow: hidden;
}
.member-media-dots {
    bottom: 10px;
}
.media-thumbs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
}
.media-thumbs button {
    width: 74px;
    height: 74px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,.16);
    background: rgba(255,255,255,.08);
    overflow: hidden;
    flex: 0 0 auto;
    padding: 0;
}
.media-thumbs button.active {
    border-color: var(--gold);
}
.media-thumbs img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.video-thumb {
    display: flex;
    height: 100%;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.5rem;
}
.extra-mini {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}
.extra-mini span {
    font-size: .78rem;
    color: #ffd480;
    background: rgba(214,169,74,.12);
    border: 1px solid rgba(214,169,74,.24);
    border-radius: 999px;
    padding: 3px 7px;
}
@media (max-width: 768px) {
    .media-thumbs button {
        width: 58px;
        height: 58px;
        border-radius: 10px;
    }
}


/* v4 layout fixes */
.home-hero .container {
    max-width: 1320px;
}
.hero-slider {
    min-height: 430px;
}
.hero-slide {
    min-height: 460px;
    background-size: cover !important;
    background-position: center !important;
}
.hero-slide::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0,0,0,.70), rgba(0,0,0,.25));
    pointer-events: none;
}
.carousel-item {
    position: relative;
}
.hero-slide-content {
    position: relative;
    z-index: 2;
}
.member-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}
.row > [class*="col-"] > .member-card {
    height: 100%;
}
.member-body {
    min-height: 265px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 10px;
}
.member-top {
    /*min-height: 158px;*/
}
.member-bottom {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.member-title-wrap {
    min-width: 0;
}
.member-title {
    font-size: 1.08rem;
    font-weight: 800;
    margin: 0;
    line-height: 1.25;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}
.member-title small {
    color: var(--muted);
    font-size: .82rem;
}
.member-location {
    margin-top: 3px;
    color: var(--muted);
    font-size: .84rem;
    min-height: 20px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}
.member-rating {
    color: #ffc857;
    font-weight: 800;
    white-space: nowrap;
    font-size: .95rem;
}
.member-badges {
    /*height: 48px;*/
    overflow: hidden;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    align-content: flex-start;
    margin: 7px 0;
}
.member-intro {
    color: var(--muted);
    font-size: .88rem;
    line-height: 1.45;
    height: 40px;
    margin: 0;
    overflow: hidden;
}
.member-time {
    color: var(--muted);
    font-size: .84rem;
    min-height: 20px;
}
.member-actions {
    display: grid;
    grid-template-columns: 1fr 74px;
    gap: 8px;
    margin-top: 4px;
}
.member-actions .btn {
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.extra-mini {
    min-height: 28px;
    max-height: 28px;
    overflow: hidden;
}
.extra-mini.is-empty {
    visibility: hidden;
}
.spec-line {
    min-height: 21px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}
.member-photo {
    flex: 0 0 260px;
}
@media (max-width: 991px) {
    .hero-slider {
        min-height: 350px;
    }
    .hero-slide {
        min-height: 350px;
    }
}
@media (max-width: 768px) {
    .hero-slider {
        min-height: 300px;
    }
    .hero-slide {
        min-height: 300px;
    }
    .hero-slide-content {
        padding: 30px 20px;
    }
    .member-photo {
        flex-basis: 185px;
        height: 185px;
    }
    .member-body {
        min-height: 300px;
        padding: 11px;
    }
    .member-top {
        /*min-height: 156px;*/
    }
    .member-title {
        font-size: .98rem;
    }
    .member-location,
    .member-time,
    .spec-line {
        font-size: .78rem;
    }
    .member-intro {
        font-size: .8rem;
        height: 38px;
    }
    .member-badges {
        /*height: 44px;*/
    }
    .member-actions {
        grid-template-columns: 1fr;
    }
    .member-actions .btn {
        width: 100%;
        min-height: 34px;
    }
}
@media (max-width: 420px) {
    .row.g-4 {
        --bs-gutter-x: .75rem;
        --bs-gutter-y: .75rem;
    }
    .member-photo {
        flex-basis: 165px;
        height: 165px;
    }
    .member-body {
        min-height: 305px;
    }
    .member-price {
        font-size: .86rem;
    }
    .extra-mini span {
        font-size: .72rem;
    }
}


/* v5 banner and search improvements */
.home-hero {
    padding-top: 18px;
}
.home-hero .container {
    max-width: 1440px;
}
.hero-slider {
    min-height: 620px;
    border-radius: 34px;
}
.hero-slide {
    min-height: 620px;
}
.hero-slide-content {
    padding: 78px 72px;
    max-width: 760px;
}
.hero-slide h1 {
    font-size: clamp(2.8rem, 6vw, 5.6rem);
}
.hero-slide p {
    font-size: 1.35rem;
    max-width: 620px;
}
.hero-search-trigger {
    display: flex;
    justify-content: center;
    margin-top: -34px;
    position: relative;
    z-index: 8;
}
.hero-search-btn {
    min-width: min(560px, 92vw);
    min-height: 72px;
    border-radius: 999px;
    box-shadow: 0 14px 38px rgba(232, 92, 139, .32);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    font-size: 1.25rem;
}
.hero-search-btn small {
    font-size: .85rem;
    opacity: .86;
    font-weight: 500;
}
.hero-search {
    margin-top: 18px;
    box-shadow: 0 18px 45px rgba(0,0,0,.22);
}
.member-price {
    white-space: nowrap;
}
@media (min-width: 1500px) {
    .hero-slider,
    .hero-slide {
        min-height: 680px;
    }
}
@media (max-width: 991px) {
    .hero-slider {
        min-height: 520px;
        border-radius: 26px;
    }
    .hero-slide {
        min-height: 520px;
    }
    .hero-slide-content {
        padding: 58px 36px;
    }
    .hero-slide h1 {
        font-size: clamp(2.4rem, 9vw, 4.5rem);
    }
    .hero-search-trigger {
        margin-top: -28px;
    }
}
@media (max-width: 768px) {
    .home-hero {
        padding-top: 10px;
    }
    .hero-slider {
        min-height: 430px;
        border-radius: 20px;
    }
    .hero-slide {
        min-height: 430px;
    }
    .hero-slide-content {
        padding: 48px 22px 64px;
    }
    .hero-slide h1 {
        font-size: 2.55rem;
    }
    .hero-slide p {
        font-size: 1.05rem;
    }
    .hero-search-btn {
        min-height: 64px;
        font-size: 1.08rem;
        flex-direction: column;
        gap: 2px;
    }
    .hero-search-trigger {
        margin-top: -24px;
    }
    .hero-search {
        margin-top: 14px;
    }
}
@media (max-width: 420px) {
    .hero-slider {
        min-height: 390px;
    }
    .hero-slide {
        min-height: 390px;
    }
    .hero-slide h1 {
        font-size: 2.15rem;
    }
    .hero-slide-content {
        padding: 40px 18px 58px;
    }
}


/* v6: remove old visible homepage search block completely */
.hero-search {
    margin-top: 0 !important;
    display: none !important;
}
.home-search-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: -34px;
    position: relative;
    z-index: 20;
}
.home-search-panel > .collapse,
.home-search-panel > .collapsing {
    width: min(1120px, 96%);
}
.hero-search-form {
    width: 100%;
    margin-top: 18px !important;
    box-shadow: 0 18px 45px rgba(0,0,0,.28);
    border-color: rgba(232,92,139,.28);
}
.hero-search-btn {
    min-width: min(560px, 92vw);
    min-height: 74px;
    border-radius: 999px;
    box-shadow: 0 14px 38px rgba(232, 92, 139, .34);
    display: inline-flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    position: relative;
    z-index: 22;
}
.hero-search-btn .search-main {
    font-size: 1.22rem;
    font-weight: 900;
    line-height: 1.1;
}
.hero-search-btn .search-sub {
    font-size: .86rem;
    opacity: .88;
    font-weight: 500;
}
.hero-search-btn:not(.collapsed) .search-main::after {
    content: "  ▲";
    font-size: .8rem;
}
.hero-search-btn.collapsed .search-main::after {
    content: "  ▼";
    font-size: .8rem;
}
@media (max-width: 991px) {
    .home-search-panel {
        margin-top: -28px;
    }
}
@media (max-width: 768px) {
    .home-search-panel {
        margin-top: -24px;
    }
    .hero-search-btn {
        min-height: 66px;
    }
    .hero-search-btn .search-main {
        font-size: 1.08rem;
    }
    .hero-search-btn .search-sub {
        font-size: .78rem;
    }
}


/* v18 admin select readability */
.admin-layout .form-select,
.admin-layout .form-control {
    background-color: #fff !important;
    color: #212529 !important;
    border-color: #ced4da !important;
}
.admin-layout .form-select option {
    background-color: #fff !important;
    color: #212529 !important;
}


/* v20 portrait image ratio fixes: source images are about 1045x1567 (2:3) */
.member-photo {
    aspect-ratio: 2 / 3;
    height: auto !important;
    flex-basis: auto !important;
    background: linear-gradient(135deg, #343443, #19191f);
    overflow: hidden;
}
.member-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    display: block;
}

/* Detail page: show the whole portrait image whenever possible */
.detail-photo,
.media-frame {
    aspect-ratio: 2 / 3;
    height: auto !important;
    max-height: calc(100vh - 180px);
    min-height: 520px;
    background: #111;
}
.detail-media-item {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
    display: block;
    background: #111;
}

/* Detail thumbs remain stable */
.media-thumbs button {
    aspect-ratio: 2 / 3;
    height: 86px;
    width: auto;
}
.media-thumbs img {
    object-fit: cover;
    object-position: center top;
}

/* Front card layout adjustment after portrait image height changes */
.member-card {
    overflow: hidden;
}
.member-body {
    min-height: 260px;
}

@media (max-width: 991px) {
    .detail-photo,
    .media-frame {
        min-height: 480px;
        max-height: none;
    }
}
@media (max-width: 768px) {
    .member-photo {
        aspect-ratio: 2 / 3;
        height: auto !important;
    }
    .detail-photo,
    .media-frame {
        min-height: 420px;
    }
    .media-thumbs button {
        height: 72px;
    }
}
@media (max-width: 420px) {
    .detail-photo,
    .media-frame {
        min-height: 360px;
    }
    .member-body {
        min-height: 300px;
    }
}


/* v26 search readability and budget range */
.filter-box .form-select,
.filter-box .form-control,
.hero-search-form .form-select,
.hero-search-form .form-control,
.hero-search .form-select,
.hero-search .form-control {
    background-color: #fff !important;
    color: #212529 !important;
    border-color: rgba(255,255,255,.24) !important;
}
.filter-box .form-select option,
.hero-search-form .form-select option,
.hero-search .form-select option {
    background-color: #fff !important;
    color: #212529 !important;
}
.filter-box label,
.hero-search-form label {
    color: rgba(255,255,255,.86);
}
.budget-range-box {
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 14px;
    padding: 10px 12px;
    color: #fff;
}
.budget-sliders {
    position: relative;
    height: 28px;
}
.budget-sliders input[type="range"] {
    position: absolute;
    left: 0;
    top: 2px;
    width: 100%;
    pointer-events: none;
    appearance: none;
    background: transparent;
}
.budget-sliders input[type="range"]::-webkit-slider-thumb {
    pointer-events: auto;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #d6a94a;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,.25);
}
.budget-sliders input[type="range"]::-webkit-slider-runnable-track {
    height: 6px;
    border-radius: 999px;
    background: rgba(255,255,255,.28);
}
.budget-sliders input[type="range"]::-moz-range-thumb {
    pointer-events: auto;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #d6a94a;
    border: 2px solid #fff;
}
.budget-sliders input[type="range"]::-moz-range-track {
    height: 6px;
    border-radius: 999px;
    background: rgba(255,255,255,.28);
}


/* v27 front search cleanup */
.member-filter-clean .form-select,
.member-filter-clean .form-control,
.filter-box .form-select,
.filter-box .form-control {
    background-color: #fff !important;
    color: #212529 !important;
    border-color: rgba(255,255,255,.28) !important;
}
.member-filter-clean .form-select option,
.filter-box .form-select option {
    background-color: #fff !important;
    color: #212529 !important;
}
.member-filter-clean label {
    color: rgba(255,255,255,.86);
}
.budget-range-box {
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 14px;
    padding: 10px 12px;
    color: #fff;
}
.budget-sliders {
    position: relative;
    height: 28px;
}
.budget-sliders input[type="range"] {
    position: absolute;
    left: 0;
    top: 2px;
    width: 100%;
    pointer-events: none;
    appearance: none;
    background: transparent;
}
.budget-sliders input[type="range"]::-webkit-slider-thumb {
    pointer-events: auto;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #d6a94a;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,.25);
}
.budget-sliders input[type="range"]::-webkit-slider-runnable-track {
    height: 6px;
    border-radius: 999px;
    background: rgba(255,255,255,.28);
}
.budget-sliders input[type="range"]::-moz-range-thumb {
    pointer-events: auto;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #d6a94a;
    border: 2px solid #fff;
}
.budget-sliders input[type="range"]::-moz-range-track {
    height: 6px;
    border-radius: 999px;
    background: rgba(255,255,255,.28);
}


/* v31 mobile search + SEO intro */
.mobile-search-toggle {
    border-radius: 999px;
    min-height: 52px;
    font-weight: 800;
}
.mobile-search-toggle.collapsed::after {
    content: " ▼";
    font-size: .85em;
}
.mobile-search-toggle:not(.collapsed)::after {
    content: " ▲";
    font-size: .85em;
}
.route-intro {
    line-height: 1.8;
}
@media (max-width: 991px) {
    #memberSearchCollapse .filter-box {
        margin-top: 0;
    }
}


/* v36 member detail readability + SEO detail layout */
.member-detail-page {
    color: #f4f4f6;
}
.detail-media-card,
.detail-info-card,
.detail-recommend {
    background: rgba(18, 18, 26, .94);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 22px;
    box-shadow: 0 20px 60px rgba(0,0,0,.28);
}
.detail-media-card {
    padding: 14px;
}
.detail-info-card {
    padding: 24px;
}
.detail-title {
    color: #ffffff;
    font-size: clamp(1.35rem, 2.6vw, 2.2rem);
    line-height: 1.35;
    font-weight: 900;
}
.detail-subtitle {
    color: rgba(255,255,255,.72);
}
.detail-price {
    color: #ffd36a;
    font-size: 1.8rem;
    font-weight: 900;
}
.detail-spec-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}
.detail-spec-grid > div,
.detail-table > div {
    background: rgba(255,255,255,.075);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 14px;
    padding: 12px;
}
.detail-spec-grid span,
.detail-table span {
    display: block;
    color: rgba(255,255,255,.58);
    font-size: .84rem;
    margin-bottom: 4px;
}
.detail-spec-grid strong,
.detail-table strong {
    color: #ffffff;
    font-weight: 800;
}
.detail-section {
    margin-top: 22px;
}
.detail-section h2 {
    color: #ffffff;
    font-size: 1.12rem;
    font-weight: 900;
    margin-bottom: 12px;
}
.detail-table {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}
.detail-chip {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    background: rgba(255,211,106,.14);
    color: #ffd36a;
    border: 1px solid rgba(255,211,106,.28);
    padding: 7px 12px;
    font-weight: 700;
}
.detail-text {
    color: rgba(255,255,255,.82);
    line-height: 1.85;
}
.detail-empty {
    display:flex;
    align-items:center;
    justify-content:center;
    color:#fff;
    background:#111;
    border-radius:16px;
}
.media-thumbs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
}
.media-thumbs button {
    border: 2px solid transparent;
    background: #111;
    color: #fff;
    border-radius: 10px;
    overflow: hidden;
    padding: 0;
    height: 86px;
    aspect-ratio: 2 / 3;
    flex: 0 0 auto;
}
.media-thumbs button.active,
.media-thumbs button:hover {
    border-color: #ffd36a;
}
.media-thumbs img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.media-thumbs span {
    width: 100%;
    height: 100%;
    display:flex;
    align-items:center;
    justify-content:center;
}
.detail-recommend {
    padding: 24px;
}
.recommend-subtitle {
    color: rgba(255,255,255,.78);
    font-size: 1rem;
    font-weight: 800;
    margin: 14px 0;
}
@media (max-width: 768px) {
    .detail-info-card {
        padding: 18px;
    }
    .detail-spec-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .detail-price {
        font-size: 1.45rem;
    }
}


/* v37: restore old member-detail look, only fix readability and add recommendation area */
.old-detail-style .dark-card,
.old-detail-style .member-detail-main-card,
.old-detail-style .detail-mini-card {
    color: #f7f7fb;
}
.old-detail-style .text-muted {
    color: rgba(255,255,255,.68) !important;
}
.old-detail-style .detail-intro-text {
    color: rgba(255,255,255,.78) !important;
    line-height: 1.85;
}
.old-detail-style .detail-mini-card {
    background: rgba(255,255,255,.055);
    border: 1px solid rgba(255,255,255,.10);
}
.old-detail-style .detail-mini-card small {
    color: rgba(255,255,255,.58) !important;
}
.old-detail-style h1,
.old-detail-style h4,
.old-detail-style h5 {
    color: #fff;
}
.old-detail-style .member-price {
    color: #ffd36a;
    font-weight: 800;
}
.detail-recommend-old {
    background: rgba(18,18,26,.72);
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 22px;
    padding: 24px;
}
.detail-recommend-old .section-title {
    color: #fff;
    font-weight: 900;
}
.detail-recommend-old .recommend-subtitle {
    color: rgba(255,255,255,.72);
    font-size: 1rem;
    font-weight: 800;
    margin: 14px 0;
}


/* v42 member-card-extra adjusted item chips */
.member-card-extra {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-height: 24px;
}
.member-card-extra span {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    border-radius: 999px;
    padding: 4px 8px;
    font-size: .78rem;
    font-weight: 700;
    color: #ffd36a;
    background: rgba(255, 211, 106, .12);
    border: 1px solid rgba(255, 211, 106, .28);
    white-space: nowrap;
}


/* v45 article admin/frontend */
.article-editor {
    font-family: Consolas, Monaco, monospace;
    min-height: 420px;
}
.article-editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.article-category-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.article-category-tabs a {
    color: rgba(255,255,255,.8);
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 999px;
    padding: 8px 12px;
    text-decoration: none;
}
.article-category-tabs a.active,
.article-category-tabs a:hover {
    color: #111;
    background: #ffd36a;
}
.article-card {
    overflow: hidden;
}
.article-cover {
    display: block;
    aspect-ratio: 16 / 9;
    margin: -24px -24px 18px;
    overflow: hidden;
    background: #111;
}
.article-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.article-detail-card {
    max-width: 960px;
    margin: 0 auto;
}
.article-detail-cover {
    width: calc(100% + 48px);
    max-width: none;
    margin: -24px -24px 24px;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 18px 18px 0 0;
}
.article-summary {
    font-size: 1.08rem;
}
.article-toc {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 16px;
    padding: 16px 18px;
    margin: 20px 0;
}
.article-toc ol {
    margin: 0;
    padding-left: 20px;
}
.article-toc a {
    color: #ffd36a;
    text-decoration: none;
}
.article-toc .toc-level-3 {
    margin-left: 16px;
}
.article-content {
    color: rgba(255,255,255,.84);
    line-height: 1.9;
}
.article-content h2,
.article-content h3,
.article-content h4 {
    color: #fff;
    margin-top: 1.6em;
    font-weight: 900;
}
.article-content a {
    color: #ffd36a;
}
.article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 14px;
    display: block;
    margin: 18px auto;
}
.article-content blockquote {
    border-left: 4px solid #ffd36a;
    padding: 12px 18px;
    background: rgba(255,255,255,.06);
    color: rgba(255,255,255,.82);
}
.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 18px 0;
}
.article-content th,
.article-content td {
    border: 1px solid rgba(255,255,255,.14);
    padding: 10px;
}


/* v46 article detail: desktop sidebar toc + related articles, mobile collapsible toc */
.article-detail-page {
    scroll-behavior: smooth;
}
.article-sidebar-col {
    display: block;
}
.article-sidebar-sticky {
    position: sticky;
    top: 92px;
}
.article-sidebar-box {
    background: rgba(18,18,26,.86);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 18px;
    padding: 18px;
    box-shadow: 0 18px 45px rgba(0,0,0,.18);
}
.sidebar-box-title {
    color: #fff;
    font-size: 1.05rem;
    font-weight: 900;
    margin-bottom: 12px;
}
.article-toc {
    background: rgba(18,18,26,.86);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 18px;
    padding: 18px;
}
.article-toc ol {
    margin: 0;
    padding-left: 18px;
}
.article-toc li {
    margin: 8px 0;
}
.article-toc a {
    color: rgba(255,255,255,.82);
    text-decoration: none;
    line-height: 1.45;
}
.article-toc a:hover {
    color: #ffd36a;
}
.article-toc .toc-level-3 {
    margin-left: 16px;
    font-size: .94rem;
}
.article-toc-mobile {
    border-radius: 0 0 18px 18px;
    margin-top: -1px;
}
.article-toc-mobile-btn {
    border-radius: 16px;
    min-height: 48px;
    font-weight: 900;
}
.article-toc-mobile-btn.collapsed::after {
    content: " ▼";
    font-size: .85rem;
}
.article-toc-mobile-btn:not(.collapsed)::after {
    content: " ▲";
    font-size: .85rem;
}
.related-article-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.related-article-item {
    display: grid;
    grid-template-columns: 88px 1fr;
    gap: 12px;
    align-items: center;
    color: #fff;
    text-decoration: none;
    padding: 8px;
    border-radius: 14px;
    background: rgba(255,255,255,.045);
    border: 1px solid rgba(255,255,255,.08);
    transition: .18s ease;
}
.related-article-item:hover {
    transform: translateY(-1px);
    border-color: rgba(255,211,106,.35);
    background: rgba(255,211,106,.08);
}
.related-article-item img,
.related-article-placeholder {
    width: 88px;
    height: 64px;
    border-radius: 10px;
    object-fit: cover;
    background: rgba(255,255,255,.12);
}
.related-article-item em {
    display: block;
    color: #ffd36a;
    font-size: .78rem;
    font-style: normal;
    margin-bottom: 4px;
}
.related-article-item strong {
    display: -webkit-box;
    color: rgba(255,255,255,.88);
    font-size: .94rem;
    line-height: 1.42;
    font-weight: 800;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.article-content h2,
.article-content h3 {
    scroll-margin-top: 100px;
}
@media (max-width: 991px) {
    .article-sidebar-col {
        display: none;
    }
    .article-detail-cover {
        width: calc(100% + 32px);
        margin: -16px -16px 20px;
    }
}


/* v47 article detail sidebar beautify */
.article-sidebar-sticky {
    position: sticky;
    top: 96px;
}
.article-sidebar-box {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at top right, rgba(255, 211, 106, .16), transparent 38%),
        linear-gradient(180deg, rgba(34,34,45,.96), rgba(17,17,25,.96));
    border: 1px solid rgba(255,255,255,.13);
    border-radius: 22px;
    padding: 18px;
    box-shadow: 0 24px 70px rgba(0,0,0,.28);
}
.article-sidebar-box::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    border: 1px solid rgba(255,211,106,.08);
}
.sidebar-box-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    font-size: 1.05rem;
    font-weight: 950;
    margin-bottom: 14px;
    letter-spacing: .02em;
}
.sidebar-box-title::before {
    content: "";
    display: inline-block;
    width: 7px;
    height: 20px;
    border-radius: 99px;
    background: linear-gradient(180deg, #ffd36a, #f29b38);
}
.article-sidebar-box.article-toc {
    padding: 18px 18px 14px;
}
.article-sidebar-box.article-toc ol {
    counter-reset: toc;
    list-style: none;
    padding-left: 0;
    margin: 0;
}
.article-sidebar-box.article-toc li {
    counter-increment: toc;
    margin: 7px 0;
}
.article-sidebar-box.article-toc a {
    display: grid;
    grid-template-columns: 28px 1fr;
    gap: 8px;
    align-items: start;
    color: rgba(255,255,255,.78);
    text-decoration: none;
    line-height: 1.45;
    padding: 8px 10px;
    border-radius: 12px;
    transition: .16s ease;
}
.article-sidebar-box.article-toc a::before {
    content: counter(toc);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 999px;
    color: #111;
    background: rgba(255,211,106,.9);
    font-size: .78rem;
    font-weight: 900;
}
.article-sidebar-box.article-toc a:hover {
    color: #fff;
    background: rgba(255,255,255,.075);
    transform: translateX(2px);
}
.article-sidebar-box.article-toc .toc-level-3 {
    margin-left: 18px;
    opacity: .92;
}
.article-sidebar-box.article-toc .toc-level-3 a {
    grid-template-columns: 22px 1fr;
    font-size: .92rem;
    padding-top: 6px;
    padding-bottom: 6px;
}
.article-sidebar-box.article-toc .toc-level-3 a::before {
    width: 18px;
    height: 18px;
    font-size: .68rem;
    background: rgba(255,255,255,.18);
    color: rgba(255,255,255,.78);
}
.related-article-box {
    padding: 18px;
}
.related-article-list {
    gap: 12px;
}
.related-article-item {
    grid-template-columns: 92px 1fr;
    gap: 12px;
    padding: 10px;
    background: rgba(255,255,255,.055);
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 16px;
}
.related-article-item img,
.related-article-placeholder {
    width: 92px;
    height: 66px;
    border-radius: 12px;
}
.related-article-item:hover {
    background: rgba(255,211,106,.10);
    border-color: rgba(255,211,106,.38);
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(0,0,0,.20);
}
.related-article-item em {
    color: #ffd36a;
    font-weight: 800;
}
.related-article-item strong {
    color: rgba(255,255,255,.92);
}
.article-detail-card {
    border-radius: 24px;
    overflow: hidden;
}
.article-detail-card .article-content {
    font-size: 1.03rem;
}
.article-toc-mobile {
    background:
        radial-gradient(circle at top right, rgba(255, 211, 106, .12), transparent 38%),
        rgba(18,18,26,.96);
    border: 1px solid rgba(255,255,255,.12);
}
.article-toc-mobile ol {
    list-style: decimal;
    margin: 0;
    padding-left: 22px;
}
.article-toc-mobile li {
    margin: 8px 0;
}
.article-toc-mobile a {
    color: rgba(255,255,255,.84);
}
.article-toc-mobile a:hover {
    color: #ffd36a;
}

/* v47 article edit page */
.article-admin-form .form-control,
.article-admin-form .form-select {
    background: #fff;
    color: #212529;
}
.article-editor {
    font-family: Consolas, Monaco, monospace;
    min-height: 520px;
}
.article-editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px;
    border-radius: 14px;
    background: rgba(0,0,0,.04);
}
