/* ========================================= */
/*     减肥瘦身网站 - 清新绿色系主题 v3.0     */
/*     全新样式结构，不依赖旧主题 CSS         */
/* ========================================= */

/* === 1. Design Tokens === */
:root {
    --primary: #2dd4a8;
    --primary-dark: #1a936f;
    --primary-light: #e8f8f3;
    --accent: #ff7675;
    --bg: #f8faf9;
    --text: #2d3436;
    --text-light: #636e72;
    --white: #ffffff;
    --border: #e0e8e5;
    --shadow: 0 2px 12px rgba(45, 212, 168, 0.08);
    --shadow-hover: 0 6px 24px rgba(45, 212, 168, 0.16);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: all 0.3s ease;
}

/* === 2. Base === */
html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg);
    color: var(--text);
    font-size: 15px;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--primary-dark);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary);
    text-decoration: none;
}

img {
    max-width: 100%;
}

::selection {
    background: rgba(45, 212, 168, 0.2);
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #b0d4c5;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* === 3. Preloader === */
#preloader {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--white);
    z-index: 99999;
}

#status {
    position: fixed;
    top: 25%; left: 0; right: 0;
    width: 400px; height: 300px;
    margin: 0 auto;
    background: url(../../image/tool/loader.gif);
    background-size: contain;
    z-index: 9999999999;
}

@media (max-width: 369px) {
    #status { left: -40px; }
}

/* === 4. Navbar === */
.navbar-mint {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 0.6rem 1.8rem;
    box-shadow: 0 2px 10px rgba(45, 212, 168, 0.2);
}

.navbar-mint .navbar-brand {
    color: var(--white);
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.navbar-mint .navbar-brand:hover {
    color: var(--white);
}

.navbar-mint .nav-link {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.navbar-mint .nav-link:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.15);
}

.navbar-mint .nav-link.disabled,
.navbar-mint .nav-link.active {
    color: var(--white);
    font-weight: 600;
    background: rgba(255, 255, 255, 0.2);
    pointer-events: none;
}

.navbar-mint .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.5);
    padding: 0.4rem 0.6rem;
}

.navbar-mint .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255, 255, 255, 0.9)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Navbar search form */
.navbar-mint .search-form {
    display: flex;
    align-items: center;
}

.navbar-mint .search-form input {
    border: none;
    border-radius: 20px 0 0 20px;
    padding: 7px 16px;
    font-size: 0.9rem;
    background: rgba(255, 255, 255, 0.9);
    color: var(--text);
    outline: none;
    transition: var(--transition);
    min-width: 180px;
}

.navbar-mint .search-form input:focus {
    background: var(--white);
}

.navbar-mint .search-form input::placeholder {
    color: var(--text-light);
}

.navbar-mint .search-form button {
    background: var(--white);
    color: var(--primary-dark);
    border: none;
    border-radius: 0 20px 20px 0;
    width: 40px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.navbar-mint .search-form button:hover {
    background: var(--primary-light);
}

/* === 5. Homepage slider === */
.slider-wrap {
    width: 100%;
    max-width: 1140px;
    margin: 24px auto 0;
    padding: 0 15px;
}

.slider-wrap .slider-container {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    height: 380px;
}

.slider-wrap .slider-item {
    display: flex;
    align-items: center;
    justify-content: center;
}

.slider-wrap .slider-item span {
    display: inline-block;
    background: rgba(0, 0, 0, 0.35);
    border-radius: var(--radius-sm);
    padding: 10px 22px;
    font-size: 1.1rem;
    line-height: 1.6;
}

/* === 6. Homepage layout === */
.home-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
    padding-top: 24px;
    padding-bottom: 24px;
}

.content-area {
    flex: 1;
    min-width: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 22px;
    align-content: start;
}

.side-area {
    width: 300px;
    flex-shrink: 0;
}

/* === 7. Post cards === */
.post-card {
    display: flex;
    flex-direction: column;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
}

.post-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-2px);
}

.post-card__media {
    width: 100%;
    height: 180px;
    background: var(--primary-light);
    overflow: hidden;
}

.post-card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-card__body {
    flex: 1;
    min-width: 0;
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
}

.post-card__meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.post-tag {
    display: inline-block;
    padding: 3px 14px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    border-radius: 15px;
    font-size: 0.8rem;
}

.post-date {
    font-size: 0.85rem;
    color: var(--text-light);
}

.post-card__title {
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.5;
    margin: 0 0 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-card__title a {
    color: var(--text);
}

.post-card__title a:hover {
    color: var(--primary-dark);
}

.post-card__author {
    margin-top: auto;
    font-size: 0.85rem;
    color: var(--text-light);
}

.post-card__author a {
    color: var(--primary-dark);
}

/* === 8. Pagination === */
.mint-pagination {
    grid-column: 1 / -1;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin: 30px 0 10px;
    flex-wrap: wrap;
}

.pg-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--white);
    color: var(--text);
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
}

.pg-btn:hover {
    background: var(--primary-light);
    border-color: var(--primary);
    color: var(--primary-dark);
}

.pg-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

.pg-total {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-left: 8px;
}

/* === 9. Sidebar widgets === */
.side-widget {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 22px;
    overflow: hidden;
}

.side-widget__title {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    font-size: 1.05rem;
    font-weight: 600;
    padding: 12px 18px;
}

.side-widget__title i {
    margin-right: 6px;
}

.side-widget__body {
    padding: 8px 18px 14px;
}

.hot-post {
    display: block;
    padding: 12px 8px;
    border-bottom: 1px solid #f0f4f2;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.hot-post:last-child {
    border-bottom: none;
}

.hot-post:hover {
    background: var(--primary-light);
}

.hot-post__author {
    font-size: 0.8rem;
    color: var(--text-light);
    margin-bottom: 4px;
}

.hot-post__title {
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hot-post:hover .hot-post__title {
    color: var(--primary-dark);
}

.tag-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag-pill {
    display: inline-block;
    padding: 6px 18px;
    background: var(--primary-light);
    color: var(--primary-dark);
    border-radius: 20px;
    font-size: 0.85rem;
    transition: var(--transition);
}

.tag-pill:hover {
    background: var(--primary);
    color: var(--white);
}

/* === 10. BMI page === */
.page-title {
    text-align: center;
    padding: 26px 0 8px;
}

.page-title h4 {
    color: var(--primary-dark);
    font-weight: 700;
    font-size: 1.5rem;
    margin-bottom: 8px;
}

.page-title p {
    color: var(--text-light);
    font-size: 14px;
}

.bmi-card {
    max-width: 720px;
    margin: 18px auto 40px;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 28px;
}

.bmi-card__head {
    background: var(--primary-light);
    border-radius: var(--radius-sm);
    padding: 16px 20px;
    margin-bottom: 16px;
}

.bmi-badge {
    display: inline-block;
    background: var(--primary-dark);
    color: var(--white);
    border-radius: 6px;
    padding: 3px 10px;
    font-size: 0.85rem;
    margin-right: 8px;
}

.bmi-card__subtitle {
    font-weight: 500;
    color: var(--text);
}

.bmi-scale {
    list-style: none;
    margin: 0 0 22px;
    padding: 0;
}

.bmi-scale__item {
    display: flex;
    align-items: center;
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.bmi-scale__item strong {
    font-weight: 500;
}

.bmi-scale__badge {
    display: inline-block;
    color: var(--white);
    border-radius: 14px;
    padding: 3px 14px;
    font-size: 0.85rem;
    margin-right: 12px;
}

.bmi-scale__item--info { background: #eaf4fb; }
.bmi-scale__item--info .bmi-scale__badge { background: #4a9eda; }
.bmi-scale__item--success { background: var(--primary-light); }
.bmi-scale__item--success .bmi-scale__badge { background: var(--primary-dark); }
.bmi-scale__item--warning { background: #fff4e5; }
.bmi-scale__item--warning .bmi-scale__badge { background: #f0a04b; }
.bmi-scale__item--danger { background: #fdecec; }
.bmi-scale__item--danger .bmi-scale__badge { background: #e05c5c; }

.bmi-scale__cur {
    color: var(--primary-dark);
}

.bmi-scale__cur em {
    font-style: normal;
    font-weight: 700;
    font-size: 1.05rem;
}

.bmi-form {
    border-top: 1px solid #f0f4f2;
    padding-top: 22px;
}

.bmi-form__row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.bmi-form__row label {
    width: 70px;
    flex-shrink: 0;
    font-weight: 500;
    margin: 0;
    text-align: right;
}

.bmi-input {
    flex: 1;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 9px 14px;
    font-size: 0.95rem;
    transition: var(--transition);
    background: var(--white);
    color: var(--text);
    height: auto;
}

.bmi-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(45, 212, 168, 0.12);
    outline: none;
}

.bmi-form__unit {
    width: 90px;
    flex-shrink: 0;
    font-size: 0.85rem;
    color: var(--text-light);
}

.bmi-form__action {
    text-align: center;
    margin-top: 24px;
}

/* === 11. Buttons === */
.btn-mint {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    border: none;
    border-radius: 25px;
    padding: 10px 36px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(45, 212, 168, 0.3);
}

.btn-mint:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(45, 212, 168, 0.4);
    color: var(--white);
}

/* === 12. Article detail page === */
.article-banner {
    position: relative;
    height: 300px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
}

.article-banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(20, 50, 40, 0.85) 0%, rgba(20, 50, 40, 0.1) 70%);
}

.article-banner__caption {
    position: relative;
    z-index: 1;
    width: 100%;
    padding: 0 15px 24px;
}

.article-banner__caption .container {
    color: var(--white);
}

.article-banner__tag {
    display: inline-block;
    padding: 3px 14px;
    background: var(--primary);
    color: var(--white);
    border-radius: 15px;
    font-size: 0.8rem;
    margin-bottom: 12px;
}

.article-banner__title {
    font-size: 1.8rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 10px;
    color: var(--white);
}

.article-banner__meta {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.85);
}

.article-body-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 36px;
    margin: -40px auto 40px;
    position: relative;
    z-index: 2;
}

.article-body-card blockquote {
    border-left: 4px solid var(--primary);
    background: var(--primary-light);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    padding: 18px 26px;
    margin-bottom: 24px;
}

.article-body-card blockquote p {
    color: var(--primary-dark);
    font-size: 15px;
    margin: 0;
}

.post_body p {
    font-size: 16px;
    line-height: 1.9;
    color: var(--text);
    margin-bottom: 18px;
}

.post_body img {
    border-radius: var(--radius-sm);
    max-width: 100%;
    height: auto;
    margin: 10px 0;
}

.post_body h2, .post_body h3, .post_body h4 {
    color: var(--text);
    font-weight: 700;
    margin: 26px 0 14px;
}

.post_body ul, .post_body ol {
    padding-left: 24px;
    margin-bottom: 18px;
}

.post_body li {
    line-height: 1.9;
    margin-bottom: 6px;
}

/* === 13. History page === */
.history-page .container {
    padding-top: 26px;
    padding-bottom: 26px;
}

.history-filter {
    display: flex;
    gap: 12px;
    max-width: 720px;
    margin: 0 auto 22px;
    flex-wrap: wrap;
}

.history-filter select {
    flex: 1;
    min-width: 120px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 9px 14px;
    font-size: 0.95rem;
    background: var(--white);
    color: var(--text);
    height: auto;
}

.history-filter select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(45, 212, 168, 0.12);
    outline: none;
}

.history-nav {
    display: flex;
    justify-content: center;
    gap: 14px;
    margin-bottom: 22px;
}

.history-nav a {
    display: inline-block;
    padding: 6px 22px;
    border: 1px solid var(--border);
    border-radius: 20px;
    color: var(--primary-dark);
    font-size: 0.9rem;
    background: var(--white);
    transition: var(--transition);
}

.history-nav a:hover {
    background: var(--primary-light);
    border-color: var(--primary);
}

.history-list {
    max-width: 900px;
    margin: 0 auto;
}

.history-item {
    display: flex;
    gap: 16px;
    align-items: baseline;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 12px 18px;
    margin-bottom: 10px;
    color: var(--text);
    transition: var(--transition);
}

.history-item:hover {
    box-shadow: var(--shadow);
    border-color: var(--primary);
    color: var(--text);
}

.history-item__date {
    flex-shrink: 0;
    width: 90px;
    color: var(--primary-dark);
    font-weight: 600;
    font-size: 0.9rem;
}

.history-item__title {
    flex: 1;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* === 14. Footer === */
#mt_footer {
    background: linear-gradient(135deg, var(--primary-dark) 0%, #147a5c 100%);
    color: var(--white);
    margin-top: 40px;
    padding: 22px 0;
}

.mt_footer_copy {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.mt_footer_copy p {
    margin: 0;
    color: rgba(255, 255, 255, 0.85);
    font-size: 13px;
}

.mt_footer_copy a {
    color: rgba(255, 255, 255, 0.9);
}

.mt_footer_copy a:hover {
    color: var(--white);
}

/* === 15. Back to top === */
.back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 999;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border: none;
    border-radius: 50%;
    width: 46px;
    height: 46px;
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: 0 4px 15px rgba(45, 212, 168, 0.35);
    transition: var(--transition);
}

.back-to-top:hover {
    transform: translateY(-3px);
    color: var(--white);
}

/* === 16. Transitions === */
.fade-enter-active, .fade-leave-active {
    transition: opacity 0.3s;
}

.fade-enter, .fade-leave-to {
    opacity: 0;
}

/* === 17. Responsive === */
@media (max-width: 991px) {
    .home-layout {
        flex-direction: column;
    }

    .side-area {
        width: 100%;
    }
}

@media (max-width: 767px) {
    .slider-wrap .slider-container {
        height: 220px;
    }

    .navbar-mint {
        padding: 0.5rem 1rem;
    }

    .navbar-mint .search-form {
        margin: 10px 0 4px;
        width: 100%;
    }

    .navbar-mint .search-form input {
        min-width: 0;
        flex: 1;
    }

    .content-area {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .post-card__media {
        height: 160px;
    }

    .article-banner {
        height: 220px;
    }

    .article-banner__title {
        font-size: 1.3rem;
    }

    .article-body-card {
        padding: 22px;
        margin-top: -24px;
    }

    .bmi-form__row {
        flex-wrap: wrap;
    }

    .bmi-form__row label {
        width: 100%;
        text-align: left;
    }

    .bmi-form__unit {
        width: auto;
    }

    .history-item {
        flex-direction: column;
        gap: 4px;
    }

    .history-item__date {
        width: auto;
    }
}
