/* S-Class 首页 · academoo 风格落地页（依赖 s-class-theme.css 令牌） */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    font-family: var(--sc-font-body);
    color: var(--sc-gray-900);
    background: #fff;
    line-height: 1.55;
    overflow-x: hidden;
}
img { max-width: 100%; }
a { color: inherit; }
button { font: inherit; }

/* 登录门 */
#login-gate {
    position: relative;
    min-height: 100dvh;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    background: linear-gradient(180deg, var(--sc-sky-100), #fff 70%);
    overflow: hidden;
}
#login-gate .gate-layout {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    width: min(100%, 60rem);
}
@media (min-width: 900px) { #login-gate .gate-layout { grid-template-columns: 1fr 1.2fr; align-items: stretch; } }
.gate-panel {
    background: #fff;
    border: var(--sc-border) solid var(--sc-line);
    border-radius: var(--sc-radius-xl);
    box-shadow: var(--sc-shadow-lg);
    padding: 2rem 1.75rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.gate-brand { display: flex; align-items: center; gap: 0.6rem; font-family: var(--sc-font-display); font-weight: 700; font-size: 1.5rem; color: #a855f7; }
.gate-brand small { font-family: var(--sc-font-body); font-weight: 600; font-size: 0.85rem; color: var(--sc-gray-500); }
.gate-title { font-family: var(--sc-font-display); font-weight: 600; font-size: clamp(1.9rem, 4vw, 2.6rem); margin: 0; line-height: 1.1; }
.gate-desc { margin: 0; color: var(--sc-gray-600); }
.gate-form { display: flex; flex-direction: column; gap: 0.75rem; }
.gate-name-error { margin: 0; color: var(--sc-accent); font-weight: 700; font-size: 0.9rem; }
.gate-hint { margin: 0; font-size: 0.85rem; color: var(--sc-gray-500); }
.gate-back-btn { align-self: flex-start; }
.wechat-card {
    background: #fff;
    border: var(--sc-border) solid var(--sc-line);
    border-radius: var(--sc-radius-xl);
    box-shadow: var(--sc-shadow-lg);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.35rem;
}
.wechat-card--panel { display: none; }
.wechat-card-kicker { margin: 0; font-family: var(--sc-font-display); font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.75rem; color: #16a34a; }
.wechat-card-title { margin: 0; font-family: var(--sc-font-display); font-weight: 600; font-size: 1.4rem; }
.wechat-card-lead { margin: 0 0 0.5rem; color: var(--sc-gray-600); font-size: 0.9rem; }
.qr-zoom-wrap {
    width: 180px;
    height: 180px;
    border: var(--sc-border-sm) solid var(--sc-line);
    border-radius: var(--sc-radius);
    overflow: hidden;
    background: #fff;
    box-shadow: var(--sc-shadow-sm);
    transition: transform 0.25s;
}
.qr-zoom-wrap img { width: 100%; height: 100%; object-fit: cover; display: block; }
.qr-zoom-wrap:hover, .qr-zoom-wrap:focus-visible { transform: scale(1.6); z-index: 5; position: relative; }
.gate-visual { display: none; }
@media (min-width: 900px) { .gate-visual { display: flex; align-items: stretch; } .gate-visual .wechat-card { width: 100%; justify-content: center; } }
@media (max-width: 899px) { .wechat-card--panel { display: flex; box-shadow: var(--sc-shadow-sm); border-width: var(--sc-border-sm); } }

/* 顶部导航 */
.site-nav { position: sticky; top: 0; z-index: 300; background: rgba(255, 255, 255, 0.94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: var(--sc-border) solid var(--sc-line); }
.site-nav .inner { max-width: 80rem; margin: 0 auto; padding: 0 1rem; min-height: 70px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
@media (min-width: 640px) { .site-nav .inner { padding: 0 1.5rem; } }
.brand { display: inline-flex; align-items: center; gap: 0.55rem; font-family: var(--sc-font-display); font-weight: 700; font-size: 1.55rem; letter-spacing: 0.04em; color: #a855f7; text-decoration: none; }
.brand svg { width: 42px; height: 42px; filter: drop-shadow(2px 2px 0 rgba(0, 0, 0, 0.15)); }
.nav-menu { display: none; align-items: center; gap: 0.2rem; }
@media (min-width: 769px) { .nav-menu { display: flex; } }
.nav-menu a { font-family: var(--sc-font-display); font-weight: 600; font-size: 1.02rem; padding: 0.5rem 0.95rem; border-radius: 999px; color: var(--sc-gray-800); text-decoration: none; transition: background 0.2s; }
.nav-menu a:hover, .nav-menu a.is-active { background: var(--sc-yellow); }
.nav-right { display: flex; align-items: center; gap: 0.6rem; }
.welcome-name { font-family: var(--sc-font-display); font-weight: 600; font-size: 0.95rem; color: var(--sc-gray-700); display: none; }
@media (min-width: 640px) { .welcome-name { display: inline; } }
.welcome-logout { font-size: 0.85rem; font-weight: 700; color: var(--sc-gray-500); text-decoration: none; }
.welcome-logout:hover { color: var(--sc-accent); }
.nav-toggle { display: inline-flex; flex-direction: column; justify-content: center; gap: 5px; width: 44px; height: 44px; padding: 0 10px; background: #fff; border: var(--sc-border-sm) solid var(--sc-line); border-radius: 0.75rem; box-shadow: var(--sc-shadow-sm); cursor: pointer; }
@media (min-width: 769px) { .nav-toggle { display: none; } }
.nav-toggle-bar { display: block; height: 3px; border-radius: 2px; background: var(--sc-gray-900); }
.nav-overlay { position: fixed; inset: 0; background: rgba(17, 24, 39, 0.4); z-index: 290; }
html.nav-open .nav-menu {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    position: fixed;
    top: 74px;
    right: 1rem;
    left: 1rem;
    z-index: 310;
    padding: 0.75rem;
    background: #fff;
    border: var(--sc-border) solid var(--sc-line);
    border-radius: var(--sc-radius-lg);
    box-shadow: var(--sc-shadow-lg);
}
html.nav-open .nav-menu a { text-align: center; font-size: 1.15rem; padding: 0.8rem; }

/* 英雄区 */
.hero { position: relative; overflow: hidden; background: linear-gradient(180deg, var(--sc-sky-100), var(--sc-blue-50) 55%, #fff); padding: 2.5rem 0 3.5rem; }
@media (min-width: 768px) { .hero { padding: 3.5rem 0 4.5rem; } }
.hero-inner { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 2.5rem; align-items: center; }
@media (min-width: 1024px) { .hero-inner { flex-direction: row; gap: 3rem; } }
.hero-copy { flex: 1; text-align: center; }
@media (min-width: 1024px) { .hero-copy { text-align: left; } }
.hero-brandline { display: inline-flex; align-items: center; gap: 0.5rem; margin-bottom: 0.75rem; font-family: var(--sc-font-display); font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; letter-spacing: 0.04em; color: #a855f7; }
.hero-brandline svg { width: 64px; height: 64px; filter: drop-shadow(2px 3px 0 rgba(0, 0, 0, 0.18)); }
@media (min-width: 768px) { .hero-brandline svg { width: 80px; height: 80px; } }
.hero h1 { font-family: var(--sc-font-display); font-weight: 600; font-size: clamp(2.2rem, 5.2vw, 3.4rem); line-height: 1.12; margin: 0 0 1rem; color: var(--sc-gray-900); }
.hero h1 .c-blue { color: #0ea5e9; }
.hero h1 .c-purple { color: #a855f7; }
.hero h1 .c-orange { color: #f97316; }
.hero-lead { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: var(--sc-gray-700); max-width: 36rem; margin: 0 auto 1.5rem; line-height: 1.65; }
@media (min-width: 1024px) { .hero-lead { margin-left: 0; } }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; justify-content: center; }
@media (min-width: 1024px) { .hero-actions { justify-content: flex-start; } }
.hero-stats { display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: center; margin-top: 1.5rem; }
@media (min-width: 1024px) { .hero-stats { justify-content: flex-start; } }
.hero-visual { flex: 1; width: 100%; max-width: 34rem; }
@media (min-width: 1024px) { .hero-visual { max-width: none; } }
.hero-collage { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.hero-collage figure { margin: 0; position: relative; overflow: hidden; border: var(--sc-border) solid var(--sc-line); border-radius: var(--sc-radius-lg); box-shadow: var(--sc-shadow); aspect-ratio: 16 / 9; background: linear-gradient(135deg, var(--sc-sky-100), #fdf2f8); }
.hero-collage figure.wide { grid-column: span 2; aspect-ratio: 2 / 1; border-radius: var(--sc-radius-xl); box-shadow: var(--sc-shadow-lg); }
/* 每张截图已按瓷片比例取景（宽图 2:1，小图 16:9），对准练习主体，不再从顶部硬裁 */
.hero-viewport { position: absolute; inset: 0; overflow: hidden; background: #fff; }
.hero-track { display: flex; height: 100%; will-change: transform; }
.hero-track.is-ready { transition: transform 0.72s cubic-bezier(0.22, 0.8, 0.28, 1); }
.hero-track img { flex: 0 0 auto; height: 100%; width: 100%; max-width: none; object-fit: cover; object-position: var(--pos, center center); display: block; background: #fff; }
.hero-collage figcaption { max-width: calc(100% - 6.4rem); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 640px) {
    .hero-collage { gap: 0.7rem; }
    .hero-collage figcaption { left: 0.45rem; bottom: 0.45rem; padding: 0.12rem 0.45rem; font-size: 0.7rem; max-width: calc(100% - 4.6rem); }
    .hero-collage figure.wide figcaption { font-size: 0.8rem; }
    .hero-badge { width: 4.2rem; height: 4.2rem; font-size: 0.68rem; top: -0.5rem; right: -0.5rem; }
    .hero-dots { right: 0.4rem; bottom: 0.5rem; }
}
.hero-collage figcaption { position: absolute; left: 0.75rem; bottom: 0.75rem; z-index: 4; padding: 0.25rem 0.7rem; font-family: var(--sc-font-display); font-weight: 700; font-size: 0.85rem; background: var(--sc-yellow); border: 2px solid var(--sc-line); border-radius: 999px; }
.hero-dots { position: absolute; right: 0.7rem; bottom: 0.85rem; z-index: 4; display: flex; align-items: center; gap: 0.28rem; }
.hero-dots button { width: 0.48rem; height: 0.48rem; padding: 0; border: 2px solid var(--sc-line); border-radius: 999px; background: #fff; cursor: pointer; }
.hero-dots button.is-on { width: 1.15rem; background: var(--sc-orange); }
.hero-badge { position: absolute; top: -0.8rem; right: -0.8rem; z-index: 5; width: 5.5rem; height: 5.5rem; display: flex; align-items: center; justify-content: center; text-align: center; font-family: var(--sc-font-display); font-weight: 700; font-size: 0.8rem; line-height: 1.1; background: var(--sc-orange); color: #fff; border: var(--sc-border-sm) solid var(--sc-line); border-radius: 50%; box-shadow: var(--sc-shadow-sm); transform: rotate(8deg); }
@media (prefers-reduced-motion: reduce) {
    .hero-track.is-ready { transition: none; }
}

/* 特性条 */
.feature-strip { border-top: var(--sc-border) solid var(--sc-line); border-bottom: var(--sc-border) solid var(--sc-line); background: #fff; padding: 2.25rem 0; }
.feature-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
@media (min-width: 640px) { .feature-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) { .feature-grid { grid-template-columns: repeat(6, 1fr); } }
.feature { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 0.7rem; font-family: var(--sc-font-body); font-weight: 700; font-size: 0.95rem; color: var(--sc-gray-800); line-height: 1.3; }

/* 课程体系 */
.program-grid { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .program-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .program-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1280px) { .program-grid { grid-template-columns: repeat(4, 1fr); } }
.program-card { display: flex; flex-direction: column; gap: 0.6rem; align-items: stretch; text-align: left; height: 100%; }
.program-head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.25rem; }
.program-card .sc-card-title { margin: 0; font-size: 1.2rem; }
.program-card .sc-card-desc { margin: 0; flex: 1; font-size: 0.93rem; }
.program-meta { list-style: none; margin: 0.35rem 0 0; padding: 0.75rem 0 0; border-top: 2px dashed var(--sc-gray-200, #e5e7eb); display: flex; flex-wrap: wrap; gap: 0.35rem 0.5rem; }
.program-meta li { font-size: 0.78rem; font-weight: 700; color: var(--sc-gray-700); padding: 0.15rem 0.55rem; background: var(--sc-gray-100, #f3f4f6); border: 2px solid var(--sc-line); border-radius: 999px; }
.program-extra { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-top: 1.25rem; }
@media (min-width: 768px) { .program-extra { grid-template-columns: repeat(2, 1fr); } }
.program-extra-card { display: flex; flex-direction: row; align-items: center; gap: 0.9rem; text-align: left; padding: 1rem 1.15rem; background: var(--sc-blue-50); }
.program-extra-card > span:nth-child(2) { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0.15rem; }
.program-extra-card strong { font-family: var(--sc-font-display); font-weight: 600; font-size: 1.1rem; }
.program-extra-card em { font-style: normal; font-size: 0.88rem; color: var(--sc-gray-600); }
.program-extra-card .sc-card-go { margin: 0; }

/* 教学方法 */
.steps { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .steps { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 640px) { .steps--4 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .steps--4 { grid-template-columns: repeat(4, 1fr); } }
.step { position: relative; }
.step .sc-step-num { position: absolute; top: -1.25rem; left: 1.25rem; }
.step .sc-card { padding-top: 2.25rem; height: 100%; }

/* 阶段卡（catalog） */
.stage-grid { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .stage-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .stage-grid { grid-template-columns: repeat(5, 1fr); } }
.stage-card { text-align: left; align-items: flex-start; gap: 0.6rem; min-height: 13rem; width: 100%; }
.stage-card .sc-icon-box { margin-bottom: 0.25rem; }
.stage-card--primary { background: linear-gradient(180deg, #fff, #ecfdf5); }
.stage-card--junior { background: linear-gradient(180deg, #fff, var(--sc-sky-50)); }
.stage-card--senior { background: linear-gradient(180deg, #fff, #faf5ff); }
.stage-card--abroad { background: linear-gradient(180deg, #fff, #fff7ed); }
.stage-card--extra { background: linear-gradient(180deg, #fff, #fdf2f8); }

/* 学习目录（learning hub，登录后） */
.learning-hub-panel { display: none; background: linear-gradient(180deg, var(--sc-sky-100), #fff 30%); min-height: 70dvh; padding: 2rem 0 4rem; }
html.learning-mode .learning-hub-panel { display: block; }
html.learning-mode #home-view, html.learning-mode .site-footer { display: none; }
.learning-hub-panel .wrap { max-width: 72rem; margin: 0 auto; padding: 0 1rem; }
.learning-toolbar { display: flex; align-items: center; gap: 0.9rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.hub-crumb { display: inline-flex; align-items: center; gap: 0.4rem; font-family: var(--sc-font-display); font-weight: 600; color: var(--sc-gray-600); }
.hub-crumb a { color: var(--sc-gray-600); text-decoration: none; padding: 0.2rem 0.6rem; border-radius: 999px; }
.hub-crumb a:hover { background: var(--sc-yellow); color: var(--sc-gray-900); }
.hub-crumb-sep { color: var(--sc-gray-300); }
.hub-crumb > span:last-child { padding: 0.2rem 0.7rem; border: 2px solid var(--sc-line); border-radius: 999px; background: #fff; color: var(--sc-gray-900); }
.catalog-head { margin-bottom: 1.75rem; }
.catalog-head .section-tag { display: inline-block; margin-bottom: 0.5rem; padding: 0.25rem 0.75rem; font-family: var(--sc-font-display); font-weight: 700; font-size: 0.8rem; letter-spacing: 0.1em; text-transform: uppercase; background: var(--sc-yellow); border: 2px solid var(--sc-line); border-radius: 999px; }
.catalog-head h2 { font-family: var(--sc-font-display); font-weight: 600; font-size: clamp(1.7rem, 3.6vw, 2.5rem); margin: 0 0 0.4rem; }
.catalog-head p { margin: 0; color: var(--sc-gray-600); font-size: 1.05rem; }
.hub-stage-grid { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr)); }
.hub-stage-card {
    display: flex; align-items: center; gap: 1rem; text-align: left; width: 100%;
    padding: 1.15rem 1.25rem; background: #fff; border: var(--sc-border) solid var(--sc-line); border-radius: var(--sc-radius-lg); box-shadow: var(--sc-shadow); cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}
.hub-stage-card:hover { transform: translateY(-4px); box-shadow: var(--sc-shadow-lg); }
.hub-stage-card:active { transform: translateY(0); box-shadow: var(--sc-shadow-press); }
.hub-stage-card--primary .hub-stage-icon { background: var(--sc-green); }
.hub-stage-card--junior .hub-stage-icon { background: var(--sc-blue); }
.hub-stage-card--senior .hub-stage-icon { background: var(--sc-purple); }
.hub-stage-card--abroad .hub-stage-icon { background: var(--sc-orange); }
.hub-stage-card--extra .hub-stage-icon { background: var(--sc-pink); }
.hub-stage-copy { flex: 1; display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; }
.hub-stage-copy strong { font-family: var(--sc-font-display); font-weight: 600; font-size: 1.2rem; }
.hub-stage-copy em { font-style: normal; font-size: 0.88rem; color: var(--sc-gray-600); }
.hub-stage-card > .fa-arrow-right, .hub-module-card > .fa-arrow-right { flex-shrink: 0; width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; border: 2.5px solid var(--sc-line); border-radius: 50%; background: var(--sc-yellow); box-shadow: 2px 2px 0 #000; font-size: 0.85rem; }
.hub-module-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr)); }
.hub-module-card {
    display: flex; align-items: center; gap: 0.9rem; text-decoration: none; color: inherit;
    padding: 1rem 1.1rem; background: #fff; border: var(--sc-border-sm) solid var(--sc-line); border-radius: var(--sc-radius-lg); box-shadow: var(--sc-shadow);
    transition: transform 0.2s, box-shadow 0.2s;
}
.hub-module-card:hover { transform: translateY(-4px); box-shadow: var(--sc-shadow-lg); }
.hub-module-card:active { transform: translateY(0); box-shadow: var(--sc-shadow-press); }
.hub-module-card strong { font-family: var(--sc-font-display); font-weight: 600; font-size: 1.1rem; display: block; }
.hub-module-card em { font-style: normal; font-size: 0.85rem; color: var(--sc-gray-600); display: block; margin-top: 0.1rem; }
.hub-module-card > span { flex: 1; min-width: 0; }

/* FAQ / CTA */
.cta-band { position: relative; overflow: hidden; background: linear-gradient(135deg, var(--sc-sky-100), #fdf2f8 60%, #fefce8); border-top: var(--sc-border) solid var(--sc-line); }
.cta-card { position: relative; z-index: 1; text-align: center; max-width: 46rem; margin: 0 auto; padding: 2.5rem 1.5rem; }

/* 页脚 */
.site-footer { background: var(--sc-gray-900); color: #e5e7eb; padding: 3rem 0 2rem; border-top: var(--sc-border) solid var(--sc-line); }
.footer-grid { max-width: 80rem; margin: 0 auto; padding: 0 1rem; display: grid; gap: 2rem; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 1fr 1fr 1fr; padding: 0 1.5rem; } }
.footer-col h4 { font-family: var(--sc-font-display); color: #fff; font-size: 1.1rem; margin: 0 0 0.75rem; }
.footer-contact a { display: flex; align-items: center; gap: 0.55rem; color: #fff; text-decoration: none; padding: 0.35rem 0; }
.footer-contact a:hover { text-decoration: underline; text-decoration-color: var(--sc-yellow); text-decoration-thickness: 3px; text-underline-offset: 4px; }
.footer-brand p { margin: 0.5rem 0 0; color: #9ca3af; font-size: 0.92rem; line-height: 1.6; }
.wechat-card--footer { background: #fff; color: var(--sc-gray-900); box-shadow: var(--sc-shadow); }
.wechat-card--footer .qr-zoom-wrap { width: 140px; height: 140px; }
.footer-bottom { max-width: 80rem; margin: 2rem auto 0; padding: 1.25rem 1rem 0; border-top: 1px solid rgba(255, 255, 255, 0.15); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem; font-size: 0.85rem; color: #9ca3af; }

/* 显示状态（沿用原逻辑） */
#main-app { display: block; }
html.show-login-gate #login-gate { display: flex !important; }
html.show-login-gate #main-app { display: none !important; }
html.show-login-gate #login-gate.hidden { display: none !important; }
html.logged-in #login-gate { display: none !important; }
html.logged-in #main-app { display: block !important; }
html.sclass-auth-pending #login-gate, html.sclass-auth-pending #main-app { visibility: hidden; }
