/* 隐藏评分 */
.tutor-course-card .tutor-course-ratings,
.tutor-course-ratings {
    display: none !important;
}

/* 取消课程标题链接下划线 */
.tutor-course-name a {
    text-decoration: none !important;
}

/* 可选：hover 时也不出现下划线 */
.tutor-course-name a:hover {
    text-decoration: none !important;
}

/* 隐藏学生人数模块 */
.tutor-course-card .tutor-meta.tutor-mt-12.tutor-mb-20 {
    display: none !important;
}

/* 隐藏作者栏 */
.tutor-course-card .tutor-meta.tutor-mt-auto {
    display: none !important;
}



/* 基础过渡效果 */
.tutor-course-card {
    transition: box-shadow 0.25s ease, transform 0.25s ease;
}

/* hover 投影效果 */
.tutor-course-card:hover {
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
    transform: translateY(-4px);
}

/* Checkout / Cart 宽幅布局 */
.entry-content:has(.tutor-checkout-page),
.entry-content:has(.tutor-cart-page) {
    max-width: 1260px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

.tutor-checkout-page,
.tutor-cart-page {
    max-width: 1260px;
    margin: 0 auto;
}


/* 通用 hover 卡片效果（需手动添加 class: hover-card） */
.hover-card {
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.hover-card:hover {
    border-color: var(--wp--preset--color--primary, #465aff) !important;
    border-width: 2px !important;
    box-shadow: 0 8px 24px rgba(70, 90, 255, 0.18);
    transform: translateY(-2px);
}


/* 按钮悬停变蓝 */
.hover-trint-button .wp-block-button__link {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease !important;
}

.hover-trint-button:hover .wp-block-button__link,
.hover-trint-button.wp-block-button__link:hover {
    background-color: var(--wp--preset--color--primary, #465aff) !important;
    color: #ffffff !important;
    border-color: var(--wp--preset--color--primary, #465aff) !important;
}

/* ============================
   Tutor LMS Registration Form
   ============================ */
/* 缩小注册表单中的输入框高度，以匹配登录页 */
#tutor-registration-form input[type="text"],
#tutor-registration-form input[type="password"],
#tutor-registration-form input[type="email"] {
    padding: 10px 16px !important;
    height: 42px !important;
    min-height: 42px !important;
    font-size: 15px !important;
}

/* 缩小注册页面的标题 (Student Registration / 学生注册) */
body:has(#tutor-registration-wrap) .wp-block-post-title,
body:has(#tutor-registration-wrap) h1 {
    font-size: 16px !important;
    text-align: center !important;
    color: var(--wp--preset--color--contrast, #1e293b) !important;
    margin-bottom: 16px !important;
    margin-top: 16px !important;
}

/* 1. 整个 header 两列垂直居中 */
header .wp-block-columns,
.wp-block-template-part .wp-block-columns {
    align-items: center;
}

/* 2. 左侧品牌区：强制横向、不换行、垂直居中 */
header .wp-block-group.is-nowrap,
.wp-block-template-part .wp-block-group.is-nowrap {
    display: flex;
    flex-wrap: nowrap !important;
    align-items: center;
    gap: 1rem;
}

/* 3. logo 不要占满一整行 */
header .wp-block-site-logo,
.wp-block-template-part .wp-block-site-logo {
    flex: 0 0 auto;
    margin: 0;
}

header .wp-block-site-logo img,
.wp-block-template-part .wp-block-site-logo img {
    display: block;
    width: auto;
    height: auto;
    max-height: 64px;
}

/* 4. 标题区保持纵向，但整体居中 */
header .wp-block-group.is-vertical,
.wp-block-template-part .wp-block-group.is-vertical {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.25rem;
}

/* 5. 去掉标题默认上下外边距，避免被压到下面 */
header .wp-block-site-title,
.wp-block-template-part .wp-block-site-title {
    margin: 0;
    line-height: 1.1;
}

header .wp-block-site-tagline,
.wp-block-template-part .wp-block-site-tagline {
    margin: 0;
    line-height: 1.2;
}

/* 6. 右侧导航所在列整体靠右 */
header .wp-block-column[style*="66.66%"]>.wp-block-group,
.wp-block-template-part .wp-block-column[style*="66.66%"]>.wp-block-group {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

/* 7. 导航自身再推到最右 */
header .wp-block-navigation,
.wp-block-template-part .wp-block-navigation {
    margin-left: auto;
}

/* 8. 导航菜单项单行显示 */
header .wp-block-navigation__container,
.wp-block-template-part .wp-block-navigation__container {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
}



/* ===== Footer 主体两栏垂直居中 ===== */
.site-footer-octet .wp-block-columns,
footer .wp-block-columns {
    align-items: center;
}

/* ===== Footer 左侧品牌区：把 logo + 标题区做成横向 ===== */
.site-footer-octet .wp-block-column:first-child,
footer .wp-block-column:first-child {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* 如果 logo、标题、描述是直接顺排的，强制整理 */
.site-footer-octet .wp-block-column:first-child>.wp-block-site-logo,
footer .wp-block-column:first-child>.wp-block-site-logo {
    display: inline-flex;
    vertical-align: middle;
    margin-right: 1rem;
    margin-bottom: 0;
}

/* 站点标题不要自带大外边距 */
.site-footer-octet .wp-block-site-title,
footer .wp-block-site-title {
    margin: 0.35rem 0 0 0;
    line-height: 1.1;
}

/* 描述文字和标题拉开一点，但不要太大 */
.site-footer-octet .wp-block-column:first-child>p.has-small-font-size,
footer .wp-block-column:first-child>p.has-small-font-size {
    margin-top: 0.5rem;
    margin-bottom: 0;
}

/* ===== 更稳的做法：如果左侧可加一个包裹 group，这段会自动生效 ===== */
.site-footer-octet .wp-block-group.is-nowrap,
footer .wp-block-group.is-nowrap {
    display: flex;
    flex-wrap: nowrap !important;
    align-items: center;
    gap: 1rem;
}

/* logo 不要被撑满整行 */
.site-footer-octet .wp-block-site-logo,
footer .wp-block-site-logo {
    flex: 0 0 auto;
}

.site-footer-octet .wp-block-site-logo img,
footer .wp-block-site-logo img {
    display: block;
    width: auto;
    height: auto;
    max-height: 32px !important;
}

/* ===== 右侧三列内容保持整齐 ===== */
.site-footer-octet .wp-block-column:nth-child(2) .wp-block-columns,
footer .wp-block-column:nth-child(2) .wp-block-columns {
    align-items: flex-start;
}

/* ===== 底部版权区：左右分开，右侧链接不换行 ===== */
.site-footer-octet .wp-block-group.is-content-justification-space-between,
footer .wp-block-group.is-content-justification-space-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.site-footer-octet .wp-block-group.is-content-justification-space-between>.wp-block-group.is-nowrap,
footer .wp-block-group.is-content-justification-space-between>.wp-block-group.is-nowrap {
    display: flex;
    flex-wrap: nowrap !important;
    align-items: center;
    gap: 1rem;
}

/* ============================
   移动端 Header 顶部空隙修复
   ============================ */
@media (max-width: 782px) {
    /* 移除可能由特定主题样式导致的首个区块顶部空隙 */
    .wp-site-blocks > div:first-child,
    .wp-site-blocks > header,
    .wp-site-blocks > .wp-block-template-part:first-child,
    .wp-site-blocks > .wp-block-template-part:first-child > header {
        margin-top: 0 !important;
        padding-top: 0 !important;
    }
    
    /* 确保 header 本身对齐顶部 */
    header {
        margin-top: 0 !important;
    }
}