/* 影视大全：清爽目录型影视资料站 */
:root {
  --brand: #143642;
  --brand-soft: #2B6E7D;
  --deep: #0B1920;
  --canvas: #F5F6F8;
  --surface: #FFFFFF;
  --text: #1A242B;
  --muted: #5A6872;
  --accent: #C85019;
  --line: #DCE2E6;
  --radius: 6px;
  --content: 1220px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 92px; }
body { margin: 0; background: var(--canvas); color: var(--text); font-family: "Microsoft YaHei", "PingFang SC", system-ui, sans-serif; font-size: 15px; line-height: 1.7; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--brand-soft); }
button, input { font: inherit; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
.container { width: min(var(--content), calc(100% - 44px)); margin-inline: auto; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 20; padding: 8px 12px; background: white; border: 1px solid var(--line); }
.skip-link:focus { top: 12px; }
.site-header { position: sticky; top: 0; z-index: 10; background: rgba(255,255,255,.97); border-bottom: 1px solid var(--line); }
.header-inner { width: min(var(--content), calc(100% - 44px)); min-height: 76px; margin: auto; display: flex; align-items: center; gap: 30px; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-width: 220px; color: var(--brand); }
.brand img { width: 42px; height: 42px; object-fit: contain; }
.brand strong { display: block; font-size: 21px; line-height: 1.2; letter-spacing: .02em; }
.brand small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
.main-nav { display: flex; align-items: center; gap: 28px; flex: 1; }
.main-nav a, .mobile-nav a { font-size: 14px; font-weight: 600; }
.header-action, .primary-button { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: 0 17px; border-radius: 4px; color: white; background: var(--brand); font-size: 13px; font-weight: 700; }
.header-action:hover, .primary-button:hover { color: white; background: var(--brand-soft); }
.menu-toggle { display: none; border: 1px solid var(--line); border-radius: 4px; padding: 7px 12px; background: white; color: var(--brand); }
.mobile-nav { padding: 8px 22px 16px; border-top: 1px solid var(--line); gap: 18px; }
.mobile-nav:not([hidden]) { display: grid; grid-template-columns: repeat(2, 1fr); }
.intro-band { background: linear-gradient(110deg, #fff 0%, #F0F4F5 100%); border-bottom: 1px solid var(--line); }
.intro-grid { display: grid; grid-template-columns: 1.45fr .85fr; gap: 54px; align-items: center; padding-block: 38px 34px; }
.eyebrow { margin: 0 0 10px; color: var(--brand-soft); font-size: 12px; font-weight: 700; letter-spacing: .08em; }
h1, h2, h3, p { margin-top: 0; }
h1 { max-width: 760px; margin-bottom: 13px; color: var(--brand); font-size: clamp(27px, 3vw, 38px); line-height: 1.3; letter-spacing: -.025em; }
.intro-lead { max-width: 760px; margin-bottom: 18px; color: #42515A; font-size: 15px; }
.intro-points { display: flex; flex-wrap: wrap; gap: 9px; }
.intro-points span { padding: 4px 10px; border: 1px solid #D8E1E4; border-radius: 4px; color: var(--brand); background: white; font-size: 12px; font-weight: 600; }
.intro-side { display: grid; gap: 12px; }
.search-panel { padding: 17px; border: 1px solid var(--line); border-radius: var(--radius); background: white; }
.search-panel label { display: block; margin-bottom: 8px; color: var(--brand); font-size: 14px; font-weight: 700; }
.search-panel input { width: 100%; min-height: 42px; padding: 8px 12px; border: 1px solid #CBD5DA; border-radius: 4px; outline: none; }
.search-panel input:focus { border-color: var(--brand-soft); box-shadow: 0 0 0 3px rgba(43,110,125,.12); }
.search-panel p { margin: 7px 0 0; color: var(--muted); font-size: 12px; }
.quick-index { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.quick-index a { padding: 10px 11px; border: 1px solid var(--line); border-radius: 4px; background: white; }
.quick-index b, .quick-index span { display: block; }
.quick-index b { color: var(--brand); font-size: 13px; }
.quick-index span { margin-top: 2px; color: var(--muted); font-size: 10px; }
.content-section { padding-block: 31px 3px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 16px; }
.section-heading h2 { margin: 0 0 3px; color: var(--brand); font-size: 22px; line-height: 1.35; }
.section-heading p { margin: 0; color: var(--muted); font-size: 13px; }
.film-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 17px 14px; }
.film-card { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 5px; background: var(--surface); }
.poster-link { display: block; }
.poster-frame { position: relative; overflow: hidden; aspect-ratio: 2 / 3; background: #E4E9EB; }
.poster-frame img { width: 100%; height: 100%; object-fit: cover; transition: transform .25s ease; }
.poster-link:hover .poster-frame img { transform: scale(1.035); }
.poster-flag { position: absolute; top: 8px; left: 0; padding: 3px 8px; color: white; background: var(--accent); font-size: 10px; font-weight: 700; }
.film-info { padding: 10px 10px 11px; }
.film-info h3 { overflow: hidden; margin: 0 0 5px; font-size: 15px; line-height: 1.4; white-space: nowrap; text-overflow: ellipsis; }
.film-summary { display: -webkit-box; min-height: 42px; overflow: hidden; margin: 0 0 8px; color: var(--muted); font-size: 11px; line-height: 1.55; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.badge-row { display: flex; flex-wrap: wrap; gap: 4px; }
.badge { display: inline-block; padding: 1px 5px; border-radius: 3px; color: #8F3B18; background: #FFF0E9; font-size: 10px; font-weight: 700; line-height: 1.7; }
.film-meta { margin: 7px 0 0; color: #7A878E; font-size: 10px; }
.filter-row { display: flex; flex-wrap: wrap; gap: 7px; margin: -2px 0 14px; }
.filter-row a { padding: 4px 11px; border: 1px solid var(--line); border-radius: 4px; background: white; color: var(--muted); font-size: 12px; }
.filter-row a:first-child { border-color: var(--brand); background: var(--brand); color: white; }
.special-section { padding-top: 35px; }
.special-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.special-card { display: grid; grid-template-columns: 112px 1fr; gap: 14px; min-height: 154px; padding: 10px; border: 1px solid var(--line); border-radius: 5px; background: white; }
.special-card img { width: 112px; height: 132px; object-fit: cover; border-radius: 3px; }
.special-card h3 { margin: 2px 0 5px; color: var(--brand); font-size: 16px; }
.special-card p:not(.special-type) { margin-bottom: 8px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.special-type { margin: 0; color: var(--accent); font-size: 11px; font-weight: 700; }
.split-section { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; padding-top: 36px; }
.ranking-panel, .collection-panel { min-width: 0; }
.ranking-list { margin: 0; padding: 0; list-style: none; border: 1px solid var(--line); border-radius: 5px; background: white; }
.ranking-list li { display: grid; grid-template-columns: 34px 1fr; gap: 10px; padding: 12px 14px; border-bottom: 1px solid #EDF0F2; }
.ranking-list li:last-child { border-bottom: 0; }
.rank-number { display: grid; width: 27px; height: 27px; place-items: center; border-radius: 4px; background: #EAF0F2; color: var(--brand); font-size: 13px; font-weight: 800; }
.ranking-list li:nth-child(-n+3) .rank-number { background: #FFF0E9; color: var(--accent); }
.ranking-list h3 { margin: 0 0 3px; font-size: 14px; }
.ranking-list p { margin: 0 0 3px; color: var(--muted); font-size: 11px; }
.ranking-list small { color: var(--brand-soft); font-size: 10px; }
.collection-list { display: grid; gap: 8px; }
.collection-list article { padding: 11px 13px; border: 1px solid var(--line); border-left: 3px solid var(--brand-soft); border-radius: 4px; background: white; }
.collection-list h3 { margin: 0 0 4px; color: var(--brand); font-size: 14px; }
.collection-list p { margin: 0 0 5px; color: var(--muted); font-size: 11px; }
.collection-list span { color: #7A878E; font-size: 10px; }
.guide-section { padding-top: 36px; }
.guide-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.guide-grid article { padding: 17px; border: 1px solid var(--line); border-radius: 5px; background: white; }
.guide-icon { display: grid; width: 34px; height: 34px; margin-bottom: 9px; place-items: center; border-radius: 4px; background: var(--brand); color: white; font-size: 11px; font-weight: 700; }
.guide-grid h3 { margin: 0 0 5px; color: var(--brand); font-size: 15px; }
.guide-grid p { margin: 0; color: var(--muted); font-size: 12px; }
.faq-section { padding-top: 36px; padding-bottom: 42px; }
.faq-section details { margin-bottom: 8px; padding: 12px 15px; border: 1px solid var(--line); border-radius: 4px; background: white; }
.faq-section summary { cursor: pointer; color: var(--brand); font-size: 14px; font-weight: 700; }
.faq-section details p { margin: 8px 0 0; color: var(--muted); font-size: 13px; }
.site-footer { background: var(--deep); color: #D9E1E4; }
.footer-inner { width: min(var(--content), calc(100% - 44px)); margin: auto; padding: 27px 0 20px; }
.footer-brand strong { color: white; font-size: 19px; }
.footer-brand p { max-width: 580px; margin: 5px 0 14px; color: #B7C4C9; font-size: 12px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 20px; margin-bottom: 16px; font-size: 12px; }
.footer-links a:hover { color: white; }
.copyright { margin: 0; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.14); color: #9EADB3; font-size: 11px; }
.error-page { min-height: 58vh; padding-block: 85px; text-align: center; }
.error-code { margin: 0; color: var(--accent); font-size: 72px; font-weight: 800; line-height: 1; }
.error-page h1 { margin: 18px auto 10px; }
.error-page > p:not(.error-code) { color: var(--muted); }
.primary-button { margin-top: 10px; }
@media (max-width: 1050px) {
  .film-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .header-inner { gap: 20px; }
  .brand { min-width: 190px; }
  .main-nav { gap: 17px; }
}
@media (max-width: 760px) {
  .container, .header-inner, .footer-inner { width: min(100% - 30px, var(--content)); }
  .header-inner { min-height: 66px; justify-content: space-between; }
  .brand { min-width: 0; }
  .brand strong { font-size: 19px; }
  .main-nav, .header-action { display: none; }
  .menu-toggle { display: inline-flex; }
  .intro-grid { grid-template-columns: 1fr; gap: 22px; padding-block: 28px; }
  h1 { font-size: 28px; }
  .film-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 11px; }
  .film-info { padding: 8px; }
  .film-info h3 { font-size: 13px; }
  .film-summary { min-height: 48px; font-size: 10px; }
  .special-grid, .split-section { grid-template-columns: 1fr; }
  .guide-grid { grid-template-columns: 1fr; }
  .section-heading h2 { font-size: 20px; }
}
@media (max-width: 420px) {
  .container, .header-inner, .footer-inner { width: calc(100% - 24px); }
  .film-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .quick-index { grid-template-columns: 1fr; }
  .quick-index a { display: flex; align-items: center; justify-content: space-between; }
  .special-card { grid-template-columns: 90px 1fr; gap: 10px; }
  .special-card img { width: 90px; height: 120px; }
  .intro-points { gap: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}


/* 内容深化区：长文卡片采用清晰的标题、导语和段落层级。 */
.editorial-section { padding-top: 38px; }
.editorial-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.editorial-card { padding: 18px 19px; border: 1px solid var(--line); border-radius: 5px; background: var(--surface); }
.editorial-card h3 { margin: 0 0 8px; color: var(--brand); font-size: 16px; line-height: 1.5; }
.editorial-card p { margin: 0 0 10px; color: #52616A; font-size: 13px; line-height: 1.85; }
.editorial-card p:last-child { margin-bottom: 0; }
.editorial-card .editorial-intro { padding-bottom: 10px; border-bottom: 1px solid #E9EEF0; color: var(--text); font-weight: 600; }
.film-card[hidden] { display: none; }
.film-card:focus-within { outline: 2px solid var(--brand-soft); outline-offset: 2px; }
.poster-link:focus-visible, .film-info a:focus-visible, .main-nav a:focus-visible,
.mobile-nav a:focus-visible, .footer-links a:focus-visible, .filter-row a:focus-visible,
.header-action:focus-visible, .primary-button:focus-visible {
  outline: 3px solid #E28A5C;
  outline-offset: 3px;
  border-radius: 3px;
}
.search-panel input::placeholder { color: #87949A; }
.search-panel input::-webkit-search-cancel-button { cursor: pointer; }
.quick-index a:hover, .filter-row a:hover { border-color: var(--brand-soft); background: #F3F8F9; }
.collection-list article:hover, .special-card:hover, .guide-grid article:hover {
  border-color: #B9C9CE;
}
.film-card:hover { border-color: #B7C7CC; }
.ranking-list li:hover { background: #FAFCFC; }
.faq-section summary:focus-visible { outline: 2px solid var(--brand-soft); outline-offset: 3px; }
.faq-section details[open] { border-color: #B7C9CE; }
.faq-section details[open] summary { color: var(--accent); }
.site-footer a { color: #D9E1E4; }
.site-footer a:focus-visible { outline-color: #F0A27D; }
.error-page .primary-button { min-width: 170px; }
@media (min-width: 1250px) {
  .intro-grid { padding-block: 44px 40px; }
  .content-section { padding-top: 34px; }
  .film-grid { gap: 18px 16px; }
  .film-info { padding: 11px 11px 12px; }
}
@media (max-width: 980px) {
  .intro-grid { gap: 28px; }
  .film-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .split-section { gap: 16px; }
  .editorial-card { padding: 15px; }
}
@media (max-width: 600px) {
  .editorial-grid { grid-template-columns: 1fr; }
  .editorial-card p { font-size: 12px; }
  .section-heading { align-items: start; }
  .section-heading p { max-width: 95%; }
  .special-card { align-items: start; }
  .ranking-list li { padding: 11px; }
  .footer-links { gap: 13px; }
}
@media (max-width: 360px) {
  .brand img { width: 36px; height: 36px; }
  .brand strong { font-size: 17px; }
  .brand small { font-size: 10px; }
  .menu-toggle { padding-inline: 9px; font-size: 13px; }
  .film-info h3 { font-size: 12px; }
  .badge { font-size: 9px; }
}

/* 窄屏内容保护与长标题换行。 */
.intro-copy, .intro-side, .ranking-panel, .collection-panel, .special-card > div { min-width: 0; }
.special-card h3, .editorial-card h3 { overflow-wrap: anywhere; }
.film-summary, .collection-list p, .guide-grid p, .ranking-list p { overflow-wrap: break-word; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .55; }
::selection { color: white; background: var(--brand-soft); }
@media print {
  .site-header, .site-footer, .search-panel, .menu-toggle { display: none !important; }
  body { background: white; color: black; }
  .container { width: 100%; }
  .film-card, .special-card, .editorial-card, .guide-grid article { break-inside: avoid; }
  a { color: black; text-decoration: underline; }
}


/* 题材词条目录：适配桌面多列阅读和移动端单列浏览。 */
.glossary-section { padding-top: 38px; padding-bottom: 36px; }
.glossary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; }
.glossary-grid article { min-width: 0; padding: 12px 13px; border: 1px solid var(--line); border-radius: 4px; background: var(--surface); }
.glossary-grid h3 { margin: 0 0 5px; color: var(--brand); font-size: 13px; font-weight: 700; }
.glossary-grid p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.75; }
.glossary-grid article:hover { border-color: #B7C9CE; background: #FCFDFD; }
.glossary-grid article:focus-within { outline: 2px solid var(--brand-soft); outline-offset: 2px; }
@media (max-width: 1080px) {
  .glossary-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .glossary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .glossary-grid article { padding: 11px; }
}
@media (max-width: 390px) {
  .glossary-grid { grid-template-columns: 1fr; }
}

/* 页面元素在不同字体缩放比例下保持布局稳定。 */
@supports (overflow-wrap: anywhere) {
  .brand, .main-nav, .header-action, .section-heading, .film-info, .footer-inner { min-width: 0; }
}
@supports not (aspect-ratio: 2 / 3) {
  .poster-frame { height: 0; padding-bottom: 150%; }
  .poster-frame img { position: absolute; inset: 0; }
}
@media (hover: none) {
  .poster-link:hover .poster-frame img { transform: none; }
}
@media (prefers-contrast: more) {
  :root { --line: #AAB6BC; --muted: #3E4B52; }
  .badge { border: 1px solid #C85019; }
}


/* 细节状态与长内容排版补充 */
.intro-band .intro-copy { max-width: 780px; }
.intro-points span { line-height: 1.6; }
.quick-index a { min-height: 58px; }
.quick-index a:focus-visible { outline: 3px solid #E28A5C; outline-offset: 2px; }
.poster-frame { isolation: isolate; }
.poster-flag { z-index: 1; }
.film-card .film-info { display: flex; flex-direction: column; align-items: flex-start; }
.film-card .film-meta { margin-top: auto; padding-top: 7px; }
.film-card .badge-row { min-height: 21px; }
.special-card { align-content: start; }
.special-card .badge-row { margin-top: 6px; }
.collection-list article { transition: border-color .15s ease, background-color .15s ease; }
.guide-grid article { transition: border-color .15s ease; }
.editorial-card { box-shadow: 0 1px 0 rgba(20,54,66,.025); }
.glossary-grid article { transition: border-color .15s ease, background-color .15s ease; }
.site-header .brand:focus-visible { outline: 3px solid #E28A5C; outline-offset: 4px; }
.main-nav a { position: relative; padding-block: 8px; }
.main-nav a::after { position: absolute; right: 0; bottom: 2px; left: 0; height: 2px; background: var(--brand-soft); content: ""; transform: scaleX(0); transform-origin: left; transition: transform .16s ease; }
.main-nav a:hover::after, .main-nav a:focus-visible::after { transform: scaleX(1); }
.filter-row a { transition: background-color .15s ease, border-color .15s ease; }
.primary-button { border: 0; cursor: pointer; }
.faq-section summary { line-height: 1.6; }
.faq-section details p { max-width: 900px; line-height: 1.8; }
.footer-brand { max-width: 720px; }
.copyright { line-height: 1.7; }
@media (min-width: 761px) {
  .mobile-nav { display: none !important; }
}
@media (max-width: 760px) {
  .header-inner { gap: 10px; }
  .intro-side { width: 100%; }
  .quick-index { gap: 7px; }
  .quick-index a { padding: 9px; }
  .film-card { align-self: start; }
  .film-info .badge-row { row-gap: 3px; }
  .special-card { min-height: 0; }
  .editorial-card { padding: 14px; }
  .glossary-section { padding-bottom: 28px; }
}
@media (max-width: 480px) {
  .intro-grid { padding-top: 24px; }
  .intro-lead { font-size: 14px; }
  .search-panel { padding: 13px; }
  .search-panel input { min-height: 40px; }
  .film-grid { column-gap: 9px; row-gap: 10px; }
  .film-info { padding: 7px; }
  .film-summary { min-height: 46px; }
  .badge-row { gap: 3px; }
  .special-card p:not(.special-type) { font-size: 11px; }
  .ranking-list p { line-height: 1.65; }
  .guide-grid article { padding: 14px; }
  .faq-section details { padding: 11px 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .main-nav a::after, .collection-list article, .guide-grid article,
  .glossary-grid article, .filter-row a { transition: none; }
}


/* 长列表和键盘访问的额外细节 */
.glossary-grid article { min-height: 104px; }
.glossary-grid h3::before { display: inline-block; width: 4px; height: 4px; margin: 0 7px 3px 0; border-radius: 50%; background: var(--accent); content: ""; }
.film-info a:focus-visible { border-radius: 2px; }
button:focus-visible, input:focus-visible, summary:focus-visible { outline: 3px solid #E28A5C; outline-offset: 2px; }
@media (max-width: 700px) { .glossary-grid article { min-height: 0; } }
