/*
Theme Name: Lilong Company
Description: 合肥利隆机械制造有限公司官网主题，支持产品内容与企业信息管理。
Version: 1.0.0
Text Domain: lilong-company
*/

:root {
  --navy: #092d63;
  --navy-deep: #06234e;
  --orange: #ff7900;
  --text: #273b56;
  --muted: #5c6b7d;
  --line: #dce3eb;
  --soft: #f4f7fa;
  --white: #ffffff;
  --radius: 4px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; }
body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.8;
  -webkit-text-size-adjust: 100%;
  overflow-wrap: break-word;
}
img { max-width: 100%; height: auto; vertical-align: middle; }
svg { max-width: 100%; }
a { color: var(--navy); text-decoration: none; text-underline-offset: 4px; }
a:hover { color: #b44f00; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 5px;
}
button, input, textarea, select { font: inherit; }
h1, h2, h3, h4, h5, h6 { color: var(--navy); font-weight: 700; line-height: 1.35; overflow-wrap: break-word; }
h1, h2, h3, p { margin-top: 0; }
p { margin-bottom: 1.25em; }
.shell { width: 100%; max-width: 1280px; margin-right: auto; margin-left: auto; padding-right: 24px; padding-left: 24px; }
.site-header { background: var(--white); border-bottom: 1px solid var(--line); }
.site-header > .shell.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px 40px;
  min-height: 110px;
  padding-top: 22px;
  padding-bottom: 22px;
}
.site-brand { display: inline-block; flex: 0 1 240px; max-width: 100%; line-height: 1; }
.site-brand img { display: block; width: 240px; max-width: 100%; height: auto; }
.main-nav { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 32px; }
.main-nav ul { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 32px; margin: 0; padding: 0; list-style: none; }
.main-nav li { margin: 0; padding: 0; }
.main-nav a { display: inline-block; padding: 8px 0; font-size: 16px; font-weight: 600; line-height: 1.5; }
.main-nav a:hover, .main-nav .current-menu-item > a, .main-nav .current_page_item > a { color: #b44f00; }
.hero.shell {
  display: grid;
  grid-template-columns: 1.08fr 1fr;
  align-items: center;
  gap: 56px;
  padding-top: 76px;
  padding-bottom: 80px;
  min-height: 650px;
}
.hero-copy, .hero-media, .content-layout > *, .about-grid > div { min-width: 0; }
.eyebrow { margin: 0 0 16px; color: #b44f00; font-size: 14px; line-height: 1.6; font-weight: 700; letter-spacing: 2px; }
.hero h1 { margin: 0 0 28px; font-size: clamp(38px, 4.4vw, 62px); line-height: 1.28; letter-spacing: -1.5px; }
.hero-copy > p { margin: 0 0 14px; color: var(--muted); font-size: 18px; line-height: 1.9; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  max-width: 100%;
  padding: 12px 26px;
  border: 1px solid var(--orange);
  border-radius: var(--radius);
  background: var(--orange);
  color: var(--navy-deep);
  font-size: 16px;
  line-height: 1.5;
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.button:hover { border-color: var(--navy); background: var(--navy); color: var(--white); }
.hero .button { margin-top: 18px; }
.hero-media { position: relative; overflow: hidden; background: var(--soft); border-radius: var(--radius); }
.hero-media > img { display: block; width: 100%; height: 448px; object-fit: cover; }
.hero-caption {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  padding: 16px 20px;
  background: rgba(9, 45, 99, .93);
  color: var(--white);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: 1.5px;
}
.section.shell { padding-top: 72px; padding-bottom: 76px; border-top: 1px solid var(--line); }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 16px 40px; margin-bottom: 34px; }
.section-heading > div { max-width: 780px; }
.section-heading .eyebrow { margin-bottom: 12px; }
.section-heading h2 { margin: 0; font-size: clamp(28px, 3vw, 38px); }
.section-heading p { max-width: 650px; margin: 14px 0 0; color: var(--muted); font-size: 17px; }
.section > h2 { font-size: clamp(28px, 3vw, 38px); }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.product-card { display: flex; flex-direction: column; min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.product-thumb { display: block; overflow: hidden; aspect-ratio: 4 / 3; background: var(--soft); }
.product-thumb > img { display: block; width: 100%; height: 100%; object-fit: cover; }
.product-placeholder { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; min-height: 180px; padding: 24px; color: var(--navy); background: var(--soft); font-size: 18px; font-weight: 600; text-align: center; }
.product-card-body { display: flex; flex: 1; flex-direction: column; align-items: flex-start; padding: 26px; }
.product-card-body h3 { margin: 0 0 12px; font-size: 23px; }
.product-card-body p { margin: 0 0 22px; color: var(--muted); font-size: 16px; }
.text-link { display: inline-block; color: var(--navy); font-size: 16px; font-weight: 700; text-decoration: underline; text-decoration-color: var(--orange); text-decoration-thickness: 2px; }
.product-card-body .text-link { margin-top: auto; }
.service-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.service-card { padding: 30px; border-top: 3px solid var(--orange); background: var(--soft); }
.service-card h3 { margin: 0 0 14px; font-size: 23px; }
.service-card p { margin: 0; color: var(--muted); font-size: 16px; }
.service-card .eyebrow { margin-bottom: 18px; }
.service-card .text-link { margin-top: 18px; }
.about-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 64px; }
.about-grid h2 { margin: 0 0 20px; font-size: clamp(28px, 3vw, 38px); }
.about-grid p { color: var(--muted); }
.about-grid p:last-child { margin-bottom: 0; }
.about-grid img { display: block; width: 100%; border-radius: var(--radius); }
.contact-panel { padding: 46px 48px; border-radius: var(--radius); background: var(--navy); color: var(--white); }
.contact-panel h2 { margin: 0 0 24px; color: var(--white); font-size: clamp(28px, 3vw, 38px); }
.contact-panel p { margin: 0 0 18px; color: #e1e8f2; font-size: 17px; line-height: 2; overflow-wrap: anywhere; }
.contact-panel p:last-child { margin-bottom: 0; }
.contact-panel a { color: var(--white); text-decoration: underline; text-decoration-color: #91abc9; }
.contact-panel a:hover { color: #ffb169; text-decoration-color: #ffb169; }
.contact-panel .eyebrow { color: #ffb169; }
.contact-panel .button { color: var(--navy-deep); text-decoration: none; }
.contact-panel .button:hover { background: var(--white); border-color: var(--white); }
.site-footer { margin-top: 0; border-top: 1px solid var(--line); background: var(--soft); }
.site-footer > .shell.footer-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px 28px; padding-top: 28px; padding-bottom: 28px; color: var(--muted); font-size: 14px; }
.footer-inner p { margin: 0; font-size: 14px; }
.footer-inner a { color: var(--muted); }
.footer-inner a:hover { color: var(--navy); text-decoration: underline; }
.page-heading.shell { padding-top: 56px; padding-bottom: 38px; }
.page-heading h1 { margin: 12px 0 18px; font-size: clamp(32px, 4vw, 48px); }
.page-heading p { max-width: 780px; margin: 0; color: var(--muted); }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 6px 10px; margin: 0 0 18px; color: var(--muted); font-size: 14px; line-height: 1.7; }
.breadcrumbs a { color: var(--muted); text-decoration: underline; }
.content-layout.shell { display: grid; grid-template-columns: minmax(0, 1fr) 300px; align-items: start; gap: 48px; padding-bottom: 76px; }
.entry-content { min-width: 0; font-size: 17px; line-height: 1.9; }
.entry-content > :first-child { margin-top: 0; }
.entry-content > :last-child { margin-bottom: 0; }
.entry-content h2 { margin: 1.6em 0 .7em; font-size: 29px; }
.entry-content h3 { margin: 1.5em 0 .6em; font-size: 23px; }
.entry-content h4, .entry-content h5, .entry-content h6 { margin: 1.5em 0 .6em; font-size: 18px; }
.entry-content p, .entry-content ul, .entry-content ol, .entry-content blockquote, .entry-content figure { margin-bottom: 1.4em; }
.entry-content a { text-decoration: underline; text-decoration-color: #b4c1d1; }
.entry-content li { margin-bottom: .35em; }
.entry-content ul, .entry-content ol { padding-left: 1.5em; }
.entry-content li > ul, .entry-content li > ol { margin-top: .35em; margin-bottom: .35em; }
.entry-content img { max-width: 100%; height: auto; }
.entry-content figure, .entry-content .wp-caption { max-width: 100%; margin-right: 0; margin-left: 0; }
.entry-content figcaption, .entry-content .wp-caption-text { margin-top: 10px; color: var(--muted); font-size: 14px; line-height: 1.7; }
.entry-content .aligncenter { display: block; margin-right: auto; margin-left: auto; }
.entry-content .alignleft { float: left; margin-right: 24px; margin-bottom: 18px; }
.entry-content .alignright { float: right; margin-left: 24px; margin-bottom: 18px; }
.entry-content::after { display: table; clear: both; content: ""; }
.entry-content .wp-block-image img { display: block; }
.entry-content .wp-block-gallery { display: flex; flex-wrap: wrap; gap: 16px; }
.entry-content .wp-block-gallery .wp-block-image { flex: 1 1 220px; margin: 0; }
.entry-content .wp-block-gallery img { width: 100%; }
.entry-content .gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.entry-content .gallery-item { margin: 0; min-width: 0; }
.entry-content .gallery img { width: 100%; }
.entry-content blockquote { margin-right: 0; margin-left: 0; padding: 16px 24px; border-left: 3px solid var(--orange); background: var(--soft); }
.entry-content blockquote > :last-child { margin-bottom: 0; }
.entry-content .wp-block-table { max-width: 100%; overflow-x: auto; }
.entry-content table { display: block; width: 100%; max-width: 100%; overflow-x: auto; margin: 0 0 28px; border-collapse: collapse; font-size: 16px; line-height: 1.7; }
.entry-content th, .entry-content td { min-width: 110px; padding: 12px 16px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
.entry-content th { background: var(--soft); color: var(--navy); font-weight: 700; }
.entry-content pre { max-width: 100%; overflow-x: auto; padding: 20px; background: var(--soft); font-size: 16px; }
.entry-content hr { clear: both; margin: 36px 0; border: 0; border-top: 1px solid var(--line); }
.entry-content iframe, .entry-content video { max-width: 100%; }
.entry-content .wp-block-embed__wrapper { overflow: hidden; }
.product-image { margin: 0 0 32px; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--soft); }
.product-image img { display: block; width: 100%; height: auto; max-height: 720px; object-fit: contain; }
.product-sidebar { padding: 28px; border-top: 3px solid var(--orange); border-radius: var(--radius); background: var(--soft); }
.product-sidebar h2, .product-sidebar h3 { margin: 0 0 16px; font-size: 23px; }
.product-sidebar p { color: var(--muted); font-size: 16px; overflow-wrap: anywhere; }
.product-sidebar .button { width: 100%; margin-top: 8px; }
.product-sidebar ul { margin: 0 0 24px; padding-left: 1.25em; font-size: 16px; }
.archive-intro { max-width: 780px; margin-bottom: 32px; color: var(--muted); }
.pagination { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin-top: 40px; }
.pagination .nav-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }
.pagination .page-numbers { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 8px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); color: var(--navy); font-size: 16px; line-height: 1.5; }
.pagination .page-numbers.current, .pagination a.page-numbers:hover { border-color: var(--navy); background: var(--navy); color: var(--white); }
.pagination .page-numbers.dots { border-color: transparent; }
.empty-state { grid-column: 1 / -1; padding: 36px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--soft); }
.empty-state h2 { margin-bottom: 14px; font-size: 26px; }
.empty-state p { margin-bottom: 0; color: var(--muted); }
.site-notice { margin-top: 24px; margin-bottom: 24px; padding: 16px 20px; border-left: 3px solid var(--orange); background: #fff5eb; color: var(--navy); font-size: 16px; }
.site-notice p:last-child { margin-bottom: 0; }
.sr-only, .screen-reader-text { position: absolute !important; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); white-space: nowrap; border: 0; }
.sr-only:focus, .screen-reader-text:focus { z-index: 100000; top: 12px; left: 12px; width: auto; height: auto; padding: 12px 20px; overflow: visible; clip: auto; clip-path: none; background: var(--white); color: var(--navy); white-space: normal; font-size: 16px; }

@media (max-width: 1024px) {
  .hero.shell { gap: 32px; padding-top: 58px; padding-bottom: 64px; min-height: 560px; }
  .hero h1 { font-size: clamp(36px, 4.4vw, 50px); }
  .hero-media > img { height: 390px; }
  .product-grid, .service-grid { gap: 20px; }
  .product-card-body, .service-card { padding: 22px; }
  .content-layout.shell { grid-template-columns: minmax(0, 1fr) 270px; gap: 32px; }
  .about-grid { gap: 40px; }
}

@media (max-width: 800px) {
  .site-header > .shell.header-inner { gap: 16px 28px; }
  .main-nav, .main-nav ul { gap: 8px 22px; }
  .hero.shell { grid-template-columns: 1fr; gap: 36px; min-height: 0; }
  .hero h1 { max-width: 650px; font-size: 48px; }
  .hero-media > img { height: 420px; }
  .product-grid, .service-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about-grid { grid-template-columns: 1fr; gap: 20px; }
  .content-layout.shell { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .product-sidebar .button { width: auto; min-width: 180px; }
}

@media (max-width: 640px) {
  .shell { padding-right: 20px; padding-left: 20px; }
  .site-header > .shell.header-inner { align-items: flex-start; min-height: 0; padding-top: 20px; padding-bottom: 18px; gap: 16px; }
  .site-brand { flex-basis: 220px; }
  .site-brand img { width: 220px; }
  .main-nav { width: 100%; }
  .main-nav, .main-nav ul { gap: 6px 24px; }
  .main-nav a { padding-top: 6px; padding-bottom: 6px; }
  .hero.shell { padding-top: 42px; padding-bottom: 46px; gap: 30px; }
  .hero h1 { font-size: clamp(34px, 8vw, 44px); letter-spacing: -.8px; margin-bottom: 22px; }
  .hero-copy > p { font-size: 17px; }
  .hero-media > img { height: 310px; }
  .hero-caption { padding: 12px 16px; letter-spacing: .5px; }
  .section.shell { padding-top: 44px; padding-bottom: 48px; }
  .section-heading { align-items: flex-start; margin-bottom: 26px; gap: 16px; }
  .section-heading h2, .section > h2, .about-grid h2, .contact-panel h2 { font-size: 28px; }
  .product-grid, .service-grid { grid-template-columns: minmax(0, 1fr); gap: 22px; }
  .product-card-body { padding: 24px; }
  .service-card { padding: 26px; }
  .product-placeholder { min-height: 160px; }
  .contact-panel { padding: 30px 24px; }
  .contact-panel p { font-size: 16px; }
  .site-footer > .shell.footer-inner { align-items: flex-start; flex-direction: column; gap: 10px; padding-top: 24px; padding-bottom: 24px; }
  .page-heading.shell { padding-top: 36px; padding-bottom: 28px; }
  .page-heading h1 { font-size: 32px; }
  .content-layout.shell { padding-bottom: 48px; }
  .entry-content h2 { font-size: 26px; }
  .entry-content .alignleft, .entry-content .alignright { float: none; margin-right: 0; margin-left: 0; }
  .entry-content .gallery { grid-template-columns: minmax(0, 1fr); }
  .entry-content .wp-block-gallery .wp-block-image { flex-basis: 100%; }
  .entry-content th, .entry-content td { padding: 10px 12px; }
  .product-sidebar { padding: 24px; }
  .empty-state { padding: 26px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .button { transition: none; }
}

@media print {
  body { color: #111; background: #fff; }
  .site-header, .main-nav, .site-footer, .product-sidebar .button, .pagination { display: none; }
  .shell { max-width: none; padding: 0; }
  .hero.shell, .content-layout.shell, .about-grid { display: block; }
  .hero-media, .product-image, .product-card { break-inside: avoid; }
  .hero-caption, .contact-panel { color: #111; background: #fff; }
  .contact-panel h2, .contact-panel p, .contact-panel a { color: #111; }
  a { color: #111; }
}
