/* Homepage layout with a quiet green palette. */
:root {
  --bg: #f7f8f4;
  --card: #fff;
  --text: #202b24;
  --muted: #687369;
  --primary: #32654a;
  --primary-contrast: #fff;
  --border: #dfe5dc;
  --soft: #edf2e9;
  --paper: #f0eee7;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}
.theme-dark {
  --bg: #111914;
  --card: #1a241d;
  --text: #ecf2e9;
  --muted: #a2b0a3;
  --primary: #a0d6ac;
  --primary-contrast: #15261b;
  --border: #344037;
  --soft: #202e23;
  --paper: #242c23;
}

/* Reset and layout */
.home-page { padding-top: 76px; font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', sans-serif; }
.home-page button { font: inherit; }
.home-page a { -webkit-tap-highlight-color: transparent; }
.site-shell { width: min(1160px, calc(100% - 64px)); margin-inline: auto; }
.home-section { padding-block: 92px; scroll-margin-top: 96px; }
.home-page h1, .home-page h2, .home-page h3, .home-page p { margin-top: 0; }
.home-page :focus-visible { outline: 3px solid var(--primary); outline-offset: 5px; }
.home-page .site-header { box-shadow: none; background: color-mix(in oklab, var(--bg) 88%, transparent); }
.home-page .nav { max-width: 1208px; min-height: 76px; padding: 14px 24px; }
.home-page .nav-links a { font-size: 14px; padding: 8px 12px; }
.home-page .logo-avatar { border-color: var(--border); box-shadow: none; }
.home-page .logo-text { font-size: 16px; gap: 8px; }
.home-page .logo, .home-page .logo:hover { border-color: transparent; background: transparent; box-shadow: none; transform: none; }
.home-page .logo::before, .home-page .logo::after { display: none; }
.home-page .theme-toggle { box-shadow: none; border-color: var(--border); }
.home-page .theme-toggle:hover { box-shadow: none; transform: none; }
.skip-link { position: fixed; top: -80px; left: 20px; z-index: 200; padding: 10px 18px; color: var(--primary-contrast); background: var(--primary); border-radius: 8px; }
.skip-link:focus { top: 14px; }
.section-kicker { margin-bottom: 18px; color: var(--muted); font-size: 13px; font-weight: 500; }
.section-heading { margin-bottom: 36px; display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; }
.home-page .section-heading h2, .home-page .learning-copy h2, .home-page .about-copy h2 { margin-bottom: 0; font-size: clamp(27px, 2.8vw, 34px); letter-spacing: -.02em; line-height: 1.35; font-weight: 600; }
.section-heading > p { max-width: 360px; margin-bottom: 2px; color: var(--muted); font-size: 14px; line-height: 1.9; }
.text-link { display: inline-flex; align-items: center; gap: 9px; color: var(--primary); text-decoration: none; font-size: 14px; font-weight: 600; }
.text-link:hover { text-decoration: underline; text-underline-offset: 5px; }
.arrow { font-family: system-ui, sans-serif; transition: transform .25s var(--ease); }
a:hover .arrow, button:hover .arrow { transform: translate(3px, -2px); }
.home-button { display: inline-flex; align-items: center; justify-content: center; gap: 22px; min-height: 50px; padding: 12px 23px; border: 1px solid var(--border); border-radius: 10px; color: var(--text); background: var(--card); text-decoration: none; font-size: 14px; font-weight: 550; transition: transform .25s var(--ease), background .25s var(--ease); }
.home-button:hover { transform: translateY(-1px); background: var(--soft); }
.home-button.primary { border-color: var(--primary); background: var(--primary); color: var(--primary-contrast); }
.home-button.primary:hover { background: color-mix(in oklab, var(--primary) 90%, var(--text)); }
.state-label { display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border-radius: 5px; color: var(--muted); background: var(--soft); font-size: 11px; line-height: 1.4; white-space: nowrap; }
.state-label.live { color: var(--primary); }

/* Introduction */
.intro-section { padding: 74px 0 48px; }
.intro-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, .9fr); align-items: center; gap: 72px; }
.intro-eyebrow { font-size: 14px; font-weight: 500; color: var(--muted); margin-bottom: 20px; }
.home-page .intro-title { margin-bottom: 25px; font-size: clamp(40px, 4.9vw, 64px); line-height: 1.25; font-weight: 650; letter-spacing: -.035em; }
.intro-title span { color: var(--primary); }
.intro-description { color: var(--muted); font-size: 16px; line-height: 1.95; max-width: 490px; margin-bottom: 29px; }
.intro-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 22px; }
.intro-product-link { font-size: 12px; color: var(--muted); }
.intro-product-link a { margin-left: 8px; color: var(--primary); text-underline-offset: 4px; }
.intro-photo { margin: 0; padding: 9px 9px 0; border: 1px solid var(--border); border-radius: 14px; background: var(--card); }
.intro-photo > img { display: block; width: 100%; height: 365px; object-fit: cover; object-position: 63% center; border-radius: 8px; }
.intro-photo figcaption { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 17px 7px 18px; font-size: 11px; color: var(--muted); }
.intro-photo figcaption strong { color: var(--text); font-size: 12px; font-weight: 550; }
.intro-footnote { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-top: 54px; padding-top: 25px; border-top: 1px solid var(--border); color: var(--muted); font-size: 11px; letter-spacing: .04em; }
.practice-topics { display: flex; flex-wrap: wrap; gap: 26px; }
.practice-topics span + span { padding-left: 26px; border-left: 1px solid var(--border); }

/* Real cases */
.cases-section { padding-top: 68px; }
.featured-case { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; background: var(--card); }
.featured-copy { padding: 36px 38px 32px; }
.case-brand { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 24px; }
.case-brand-name { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 550; }
.case-brand-name img { width: 28px; height: 28px; border-radius: 6px; object-fit: contain; }
.home-page .featured-copy h3 { margin-bottom: 16px; font-size: 26px; line-height: 1.5; letter-spacing: -.02em; font-weight: 600; }
.featured-copy > p, .case-card > p { color: var(--muted); font-size: 14px; line-height: 1.9; }
.featured-copy > p { margin-bottom: 20px; }
.case-scope { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.case-scope span { font-size: 11px; color: var(--muted); }
.case-scope span + span::before { content: '·'; margin-right: 8px; color: var(--muted); }
.case-details summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 13px; color: var(--primary); font-size: 13px; font-weight: 550; }
.case-details summary::-webkit-details-marker { display: none; }
.case-details summary::after { content: '+'; font-size: 17px; }
.case-details[open] summary::after { content: '−'; }
.case-detail-body { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--border); }
.case-detail-body p { margin-bottom: 13px; color: var(--muted); font-size: 13px; line-height: 1.85; }
.case-detail-body strong { display: block; color: var(--text); font-weight: 550; margin-bottom: 3px; }
.case-workflow { padding: 36px; background: var(--soft); display: flex; flex-direction: column; justify-content: center; }
.workflow-head { color: var(--muted); font-size: 12px; margin-bottom: 23px; }
.workflow-row { display: flex; justify-content: space-between; align-items: center; gap: 15px; padding: 17px 16px; border: 1px solid var(--border); border-radius: 7px; background: var(--card); }
.workflow-row strong { min-width: 0; font-size: 13px; font-weight: 550; }
.workflow-row span { max-width: 110px; font-size: 11px; text-align: right; color: var(--muted); }
.workflow-connector { height: 21px; margin-left: 25px; border-left: 1px solid color-mix(in oklab, var(--primary) 35%, transparent); }
.case-workflow .workflow-note { margin: 17px 0 0; color: var(--muted); font-size: 11px; line-height: 1.8; }
.case-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 20px; }
.case-card { padding: 30px 33px; border: 1px solid var(--border); border-radius: 12px; background: var(--card); }
.router-mark, .share-mark { width: 29px; height: 29px; display: grid; place-items: center; color: var(--primary); background: var(--soft); border-radius: 6px; font-size: 15px; font-weight: 600; }
.home-page .case-card h3 { font-size: 23px; font-weight: 600; line-height: 1.5; letter-spacing: -.02em; margin-bottom: 14px; }
.case-card > p { margin-bottom: 24px; }
.case-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.case-card-footer > span { font-size: 11px; color: var(--muted); }
.more-projects { margin-top: 28px; padding: 21px 0; display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; border-bottom: 1px solid var(--border); font-size: 12px; color: var(--muted); }
.more-projects > span:first-child { font-size: 11px; margin-right: auto; }
.more-projects a { color: var(--text); text-decoration: none; }
.more-projects a:hover { color: var(--primary); }
.more-projects small { color: var(--muted); margin-left: 5px; font-size: 10px; }
/* Learning */
.learning-section { background: var(--paper); border-block: 1px solid var(--border); }
.learning-grid { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 92px; }
.learning-copy h2 { margin-bottom: 24px !important; }
.learning-copy > p:not(.section-kicker) { color: var(--muted); font-size: 14px; line-height: 1.95; margin-bottom: 26px; max-width: 420px; }
.learning-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 20px; }
.learning-status { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; margin-bottom: 18px; }
.learning-status::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #ad874e; }
.learning-topic { display: grid; grid-template-columns: 35px 1fr; gap: 14px; padding: 21px 0; border-bottom: 1px solid color-mix(in oklab, var(--border) 65%, var(--muted)); }
.learning-topic:last-child { border-bottom: none; padding-bottom: 0; }
.topic-number { color: var(--primary); font-size: 12px; font-variant-numeric: tabular-nums; padding-top: 2px; }
.home-page .learning-topic h3 { font-size: 16px; font-weight: 550; margin-bottom: 7px; }
.learning-topic p { font-size: 12px; color: var(--muted); margin-bottom: 0; line-height: 1.85; }

/* Public records */
.records-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.record-card { padding: 24px 25px; border: 1px solid var(--border); border-radius: 9px; background: var(--card); display: flex; flex-direction: column; text-decoration: none; color: var(--text); transition: border-color .25s var(--ease); }
.record-card:hover { border-color: var(--primary); }
.record-meta { display: flex; justify-content: space-between; gap: 12px; color: var(--muted); font-size: 11px; margin-bottom: 20px; }
.home-page .record-card h3 { font-size: 17px; font-weight: 560; line-height: 1.65; letter-spacing: -.02em; margin-bottom: 12px; }
.record-card p { font-size: 13px; color: var(--muted); line-height: 1.85; margin-bottom: 22px; }
.record-source { display: flex; justify-content: space-between; gap: 12px; color: var(--primary); font-size: 11px; margin-top: auto; }
.records-note { margin: 19px 0 0; color: var(--muted); font-size: 11px; line-height: 1.8; }

/* About and reading */
.about-section { padding-top: 24px; }
.about-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 76px; padding-top: 57px; border-top: 1px solid var(--border); }
.about-copy h2 { margin-bottom: 20px !important; font-size: 30px !important; }
.about-copy > p:not(.section-kicker) { max-width: 480px; color: var(--muted); font-size: 14px; line-height: 1.95; }
.about-path { display: flex; align-items: center; gap: 15px; margin-top: 26px; font-size: 11px; color: var(--muted); }
.about-path strong { color: var(--primary); font-weight: 550; }
.reading-block { scroll-margin-top: 110px; display: flex; align-items: center; gap: 28px; padding: 28px; background: var(--soft); border-radius: 14px; align-self: center; }
.reading-cover { width: 106px; height: 144px; flex-shrink: 0; border-radius: 3px 9px 9px 3px; background: #315540; color: #f6f4e9; padding: 21px 15px; box-shadow: 4px 6px 10px #00000015; border-left: 5px solid #264d32; display: flex; flex-direction: column; justify-content: space-between; }
.reading-cover strong { font-size: 16px; line-height: 1.55; font-weight: 550; letter-spacing: 1px; }
.reading-cover small { font-size: 8px; letter-spacing: .12em; color: #c5d2c4; }
.reading-copy .section-kicker { margin-bottom: 9px; font-size: 10px; }
.home-page .reading-copy h3 { font-size: 16px; font-weight: 550; margin-bottom: 10px; }
.reading-copy p { color: var(--muted); font-size: 11px; line-height: 1.8; margin-bottom: 12px; }
.reading-copy .text-link { font-size: 12px; }
.reading-license { display: block; margin-top: 10px; color: var(--muted); font-size: 9px; }

/* Contact */
.contact-section { background: var(--soft); border-block: 1px solid var(--border); }
.contact-section .section-heading > p { max-width: 385px; }
.contact-options { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 17px; }
.contact-option { padding: 25px 26px; text-align: left; border: 1px solid var(--border); border-radius: 9px; background: var(--card); color: var(--text); cursor: pointer; transition: border-color .25s var(--ease); }
.contact-option:hover { border-color: var(--primary); }
.contact-option-head { display: flex; justify-content: space-between; gap: 16px; font-size: 16px; font-weight: 550; margin-bottom: 13px; }
.contact-option > span:last-child { display: block; color: var(--muted); font-size: 12px; font-weight: 400; line-height: 1.9; }
.contact-bottom { display: flex; justify-content: space-between; align-items: center; gap: 25px; margin-top: 30px; }
.contact-bottom > p { margin-bottom: 0; color: var(--muted); font-size: 11px; }
.social-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.home-page .social-buttons .platform-card { width: auto; min-width: 0; min-height: 0; padding: 9px 12px; border: 1px solid var(--border); border-radius: 7px; display: inline-flex; flex-direction: row; gap: 7px; color: var(--muted); background: transparent; box-shadow: none; }
.home-page .social-buttons .platform-card .platform-name { font-size: 11px; font-weight: 400; color: inherit; margin: 0; }
.home-page .social-buttons .platform-card > img { width: 15px; height: 15px; object-fit: contain; border-radius: 3px; }
.home-page .social-buttons .platform-card:hover { color: var(--primary); border-color: var(--primary); transform: none; }
.home-page .social-buttons .platform-card::before, .home-page .social-buttons .qr-tooltip { display: none; }
.home-page .site-footer { padding: 32px 0 27px; background: var(--bg); border: 0; }
.home-page .footer-slogan { font-size: 14px; font-weight: 500; letter-spacing: 0; background: none; -webkit-text-fill-color: var(--text); color: var(--text); margin-bottom: 8px; }
.home-page .footer-sub { font-size: 11px; margin-bottom: 20px; }
.home-page .footer-bottom { font-size: 10px; }
.home-page .footer-copy, .home-page .footer-icp, .home-page .footer-police { font-size: 10px; }
.home-page .back-to-top { width: 42px; height: 42px; right: 23px; bottom: 24px; border-radius: 10px; background: var(--card); box-shadow: 0 4px 18px #0000000b; }
.home-page .back-to-top-shine { display: none; }
.home-page .qr-modal-content { border-radius: 16px; background: var(--card); }
.home-page .qr-modal-close { color: var(--text); }
.home-page .qr-modal-text { line-height: 1.85; }

/* Responsive */
@media (max-width: 1000px) {
  .intro-grid { gap: 40px; }
  .intro-photo > img { height: 330px; }
  .home-page .intro-title { font-size: 51px; }
  .featured-copy, .case-workflow { padding: 30px; }
  .learning-grid { gap: 50px; }
  .about-grid { gap: 38px; }
  .reading-block { padding: 23px; gap: 20px; }
  .records-grid { gap: 14px; }
  .record-card { padding: 22px; }
}
@media (max-width: 768px) {
  .site-shell { width: calc(100% - 40px); }
  .home-section { padding-block: 62px; }
  .intro-section { padding-top: 42px; padding-bottom: 26px; }
  .intro-grid { grid-template-columns: 1fr; gap: 36px; }
  .home-page .intro-title { font-size: clamp(38px, 7vw, 53px); }
  .intro-description { max-width: 540px; font-size: 14px; }
  .intro-photo { max-width: 460px; transform: none; width: 100%; margin-inline: auto; }
  .intro-photo > img { height: 275px; object-position: 63% 35%; }
  .intro-footnote { margin-top: 35px; font-size: 10px; }
  .practice-topics { gap: 16px; }
  .practice-topics span + span { padding-left: 16px; }
  .section-heading { display: block; margin-bottom: 27px; }
  .section-heading > p { max-width: 540px; margin-top: 16px; font-size: 13px; }
  .section-kicker { margin-bottom: 14px; }
  .featured-case { grid-template-columns: 1fr; }
  .featured-copy, .case-workflow { padding: 27px; }
  .home-page .featured-copy h3 { font-size: 24px; }
  .case-grid { gap: 16px; }
  .case-card { padding: 25px; }
  .home-page .case-card h3 { font-size: 21px; }
  .case-card-footer { display: block; }
  .case-card-footer > span { display: block; margin-top: 10px; }
  .learning-grid { grid-template-columns: 1fr; gap: 36px; }
  .learning-copy > p:not(.section-kicker) { max-width: 540px; }
  .records-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about-grid { grid-template-columns: 1fr; padding-top: 35px; gap: 27px; }
  .about-section { padding-top: 0; }
  .reading-block { max-width: 500px; }
  .contact-options { gap: 12px; }
  .contact-option { padding: 21px; }
  .contact-option-head { font-size: 14px; }
  .contact-bottom { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 640px) {
  .home-page { padding-top: 64px; }
  .home-page .nav { min-height: 64px; padding: 10px 16px; }
  .home-page .nav-links a { font-size: 16px; padding: 16px 24px; }
  .home-page .logo-text { font-size: 14px; }
  .home-page .nav-links { background: var(--card); }
  .intro-eyebrow { font-size: 12px; margin-bottom: 22px; }
  .intro-actions { gap: 10px; }
  .home-button { min-height: 47px; padding: 11px 18px; font-size: 13px; gap: 14px; }
  .intro-product-link { font-size: 11px; line-height: 1.9; }
  .intro-photo > img { height: 235px; }
  .intro-photo figcaption { font-size: 10px; gap: 8px; padding: 14px 3px; }
  .intro-photo figcaption strong { font-size: 11px; }
  .intro-footnote > span { display: none; }
  .home-page .section-heading h2, .home-page .learning-copy h2 { font-size: 29px; }
  .case-grid { grid-template-columns: 1fr; }
  .case-card-footer { display: flex; }
  .case-card-footer > span { margin-top: 0; }
  .more-projects { gap: 16px 22px; align-items: flex-start; }
  .more-projects > span:first-child { width: 100%; }
  .records-grid { grid-template-columns: 1fr; gap: 12px; }
  .record-card { padding: 22px 23px; }
  .record-meta { margin-bottom: 15px; }
  .record-card p { margin-bottom: 18px; }
  .reading-block { padding: 22px; gap: 20px; }
  .reading-cover { width: 86px; height: 125px; padding: 17px 12px; }
  .reading-cover strong { font-size: 14px; }
  .home-page .reading-copy h3 { font-size: 15px; }
  .reading-license { font-size: 9px; }
  .contact-options { grid-template-columns: 1fr; }
  .contact-option { padding: 22px 24px; }
  .contact-option-head { font-size: 16px; margin-bottom: 9px; }
  .contact-bottom { margin-top: 24px; gap: 19px; }
  .home-page .footer-bottom { gap: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .home-page *, .home-page *::before, .home-page *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
