/*
Theme Name: LMD Models Block
Theme URI: https://www.henpang.com/
Author: Codex
Description: Block theme for Chengdu LMD model agency. Built around Gutenberg pages, preserved legacy model URLs, and a casting-desk editorial layout.
Version: 1.0.1
Requires at least: 6.6
Tested up to: 6.9
Requires PHP: 7.4
License: GNU General Public License v2 or later
Text Domain: lmd-models-block
*/

:root {
  --hp-ink: #101010;
  --hp-ink-soft: #2c2925;
  --hp-paper: #f3eee4;
  --hp-paper-deep: #e4dccd;
  --hp-card: #fffaf2;
  --hp-line: #d6cbbb;
  --hp-muted: #80766b;
  --hp-red: #c33b31;
  --hp-red-dark: #8f2d27;
  --hp-teal: #226d66;
  --hp-gold: #bd9853;
  --hp-shadow: 0 18px 48px rgba(16, 16, 16, 0.12);
  --hp-radius: 8px;
  --hp-wrap: 1180px;
}

html {
  scroll-behavior: smooth;
  text-size-adjust: 100%;
}

body {
  background:
    linear-gradient(90deg, rgba(16, 16, 16, 0.035) 1px, transparent 1px) 0 0 / 72px 72px,
    var(--hp-paper);
  color: var(--hp-ink);
  font-family: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.72;
  letter-spacing: 0;
}

body .is-layout-constrained > :where(:not(.alignleft):not(.alignright):not(.alignfull)) {
  max-width: var(--hp-wrap);
}

a {
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

.wp-site-blocks {
  overflow-x: clip;
}

.hp-site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  margin: 0;
  border-bottom: 1px solid rgba(214, 203, 187, 0.9);
  background: rgba(243, 238, 228, 0.92);
  backdrop-filter: blur(16px);
}

.hp-site-header .wp-block-group {
  gap: 24px;
}

.hp-brand {
  min-width: 214px;
  text-decoration: none;
}

.hp-brand-mark {
  display: inline-grid;
  width: 44px;
  height: 44px;
  margin-right: 12px;
  place-items: center;
  border: 1px solid var(--hp-ink);
  background: var(--hp-ink);
  color: var(--hp-card);
  font-family: "Times New Roman", serif;
  font-size: 15px;
  line-height: 1;
}

.hp-brand-name {
  display: inline-block;
  color: var(--hp-ink);
  font-size: 15px;
  font-weight: 700;
  vertical-align: middle;
}

.hp-brand-note {
  display: block;
  margin-left: 58px;
  color: var(--hp-muted);
  font-size: 11px;
  text-transform: uppercase;
}

.hp-nav {
  font-size: 14px;
}

.hp-nav a {
  text-decoration: none;
}

.hp-nav .wp-block-navigation-item__content {
  font-weight: 600;
}

.hp-nav .wp-block-navigation__submenu-icon {
  margin-left: 2px;
}

.hp-nav .wp-block-navigation__submenu-container {
  min-width: 168px;
  padding: 8px;
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  background: var(--hp-card);
  box-shadow: var(--hp-shadow);
}

.hp-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content {
  padding: 9px 12px;
  border-radius: 6px;
  font-weight: 600;
}

.hp-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content:hover {
  background: var(--hp-paper);
  color: var(--hp-red);
}

.hp-header-cta .wp-block-button__link,
.hp-button-red .wp-block-button__link {
  border-radius: 999px;
  background: var(--hp-red);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  padding: 11px 18px;
  text-decoration: none;
}

.hp-button-ghost .wp-block-button__link {
  border: 1px solid var(--hp-ink);
  border-radius: 999px;
  background: transparent;
  color: var(--hp-ink);
  font-size: 14px;
  font-weight: 700;
  padding: 10px 18px;
  text-decoration: none;
}

.hp-casting-hero {
  min-height: 720px;
  margin: 0;
  padding: 70px 24px 56px;
  border-bottom: 1px solid var(--hp-line);
}

.hp-kicker {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  margin: 0 0 18px;
  color: var(--hp-red);
  font-size: 13px;
  font-weight: 800;
}

.hp-kicker::before {
  display: inline-block;
  width: 34px;
  height: 1px;
  background: currentColor;
  content: "";
}

.hp-hero-title {
  max-width: 760px;
  margin: 0;
  font-family: "Noto Serif SC", "Songti SC", "SimSun", serif;
  font-size: 5rem;
  font-weight: 500;
  line-height: 1.06;
  letter-spacing: 0;
}

.hp-hero-title strong {
  color: var(--hp-red);
  font-weight: 500;
}

.hp-hero-lede {
  max-width: 650px;
  color: var(--hp-ink-soft);
  font-size: 19px;
}

.hp-hero-board {
  position: relative;
  min-height: 610px;
}

.hp-hero-board .wp-block-image,
.hp-hero-board figure {
  margin: 0;
}

.hp-hero-main img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center top;
  border: 1px solid var(--hp-ink);
  border-radius: var(--hp-radius);
  box-shadow: var(--hp-shadow);
}

.hp-model-cover img {
  width: 100%;
  max-height: 560px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top center;
  border: 1px solid var(--hp-ink);
  border-radius: var(--hp-radius);
  box-shadow: var(--hp-shadow);
}

.hp-hero-portrait {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 42%;
  min-width: 210px;
  padding: 10px;
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  background: var(--hp-card);
  box-shadow: 0 14px 40px rgba(16, 16, 16, 0.16);
}

.hp-hero-portrait img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 5px;
}

.hp-hero-caption {
  margin: 12px 0 0;
  color: var(--hp-muted);
  font-size: 13px;
}

.hp-proof-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin: 36px auto 0;
  background: var(--hp-line);
  border: 1px solid var(--hp-line);
}

.hp-proof-strip > .wp-block-group {
  min-height: 112px;
  padding: 22px;
  background: var(--hp-card);
}

.hp-proof-num {
  margin: 0;
  color: var(--hp-red);
  font-family: "Times New Roman", serif;
  font-size: 32px;
  line-height: 1;
}

.hp-section {
  margin: 0;
  padding: 76px 24px;
}

.hp-section.hp-dark {
  background: var(--hp-ink);
  color: var(--hp-card);
}

.hp-section.hp-dark h1,
.hp-section.hp-dark h2,
.hp-section.hp-dark h3,
.hp-section.hp-dark p {
  color: inherit;
}

.hp-section-head {
  max-width: 820px;
  margin-bottom: 34px;
}

.hp-section-title {
  margin: 0 0 18px;
  font-family: "Noto Serif SC", "Songti SC", "SimSun", serif;
  font-size: 3.15rem;
  font-weight: 500;
  line-height: 1.13;
  letter-spacing: 0;
}

.hp-section-lede {
  color: var(--hp-muted);
  font-size: 18px;
}

.hp-dark .hp-section-lede {
  color: #d7cfc2;
}

.hp-duo-card {
  min-height: 440px;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  background: var(--hp-card);
}

.hp-duo-card .wp-block-image {
  margin: 0;
}

.hp-duo-card img {
  width: 100%;
  aspect-ratio: 5 / 4;
  object-fit: cover;
}

.hp-duo-card .wp-block-group {
  padding: 26px;
}

.hp-dossier-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.hp-service-dossier,
.hp-process-step,
.hp-contact-slip {
  min-height: 210px;
  padding: 26px;
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  background: var(--hp-card);
}

.hp-section.hp-dark .hp-service-dossier,
.hp-section.hp-dark .hp-process-step,
.hp-section.hp-dark .hp-contact-slip {
  color: var(--hp-ink);
}

.hp-service-dossier h3,
.hp-process-step h3,
.hp-contact-slip h3 {
  margin-top: 0;
  font-family: "Noto Serif SC", "Songti SC", "SimSun", serif;
  font-size: 1.45rem;
  color: var(--hp-ink);
  letter-spacing: 0;
}

.hp-service-dossier p,
.hp-process-step p,
.hp-contact-slip p {
  color: var(--hp-muted);
}

.hp-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.hp-chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 7px 12px;
  border: 1px solid var(--hp-line);
  border-radius: 999px;
  background: rgba(255, 250, 242, 0.78);
  color: var(--hp-ink-soft);
  font-size: 13px;
}

.hp-model-hero {
  margin: 0;
  padding: 58px 24px 32px;
}

.hp-model-hero .hp-hero-title {
  font-size: 4.35rem;
}

.hp-model-gallery {
  gap: 14px !important;
}

.hp-model-gallery.wp-block-gallery.has-nested-images figure.wp-block-image {
  flex-grow: 0;
  width: calc(25% - 11px);
}

.hp-model-gallery.wp-block-gallery.has-nested-images figure.wp-block-image img {
  width: 100%;
  aspect-ratio: 3 / 4.65;
  object-fit: cover;
  border-radius: var(--hp-radius);
  filter: saturate(0.92) contrast(1.02);
}

.hp-model-note {
  padding: 22px 0;
  border-top: 1px solid var(--hp-line);
  border-bottom: 1px solid var(--hp-line);
  color: var(--hp-muted);
}

.hp-profile-roster {
  display: grid;
  gap: 38px;
  margin-top: 30px;
}

.hp-profile-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--hp-line);
}

.hp-profile-group-head p,
.hp-profile-group-head span {
  margin: 0;
}

.hp-profile-group-head p {
  color: var(--hp-ink);
  font-size: 1.25rem;
  font-weight: 800;
}

.hp-profile-group-head span {
  min-width: max-content;
  color: var(--hp-red-dark);
  font-size: 14px;
  font-weight: 800;
}

.hp-profile-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.hp-profile-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  background: var(--hp-card);
  box-shadow: 0 10px 28px rgba(16, 16, 16, 0.08);
}

.hp-profile-photo {
  display: block;
  aspect-ratio: 3 / 4.25;
  margin: 0;
  overflow: hidden;
  background: var(--hp-paper-deep);
}

.hp-profile-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.02);
}

.hp-profile-copy {
  display: grid;
  gap: 8px;
  padding: 15px 15px 17px;
}

.hp-profile-type,
.hp-profile-copy h3,
.hp-profile-specs {
  margin: 0;
}

.hp-profile-type {
  color: var(--hp-red-dark);
  font-size: 12px;
  font-weight: 800;
}

.hp-profile-copy h3 {
  color: var(--hp-ink);
  font-size: 1.12rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.hp-profile-specs {
  color: var(--hp-ink-soft);
  font-size: 14px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.hp-case-grid.wp-block-gallery.has-nested-images figure.wp-block-image {
  width: calc(33.333% - 12px);
}

.hp-case-grid.wp-block-gallery.has-nested-images figure.wp-block-image img {
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: var(--hp-radius);
}

.hp-case-post-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.hp-case-post-card {
  overflow: hidden;
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  background: var(--hp-card);
  box-shadow: 0 12px 30px rgba(16, 16, 16, 0.08);
}

.hp-case-post-image {
  display: block;
  min-height: 210px;
  background: var(--hp-paper-deep);
}

.hp-case-post-image img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.hp-case-post-copy {
  display: grid;
  gap: 10px;
  padding: 20px;
}

.hp-case-post-copy h3,
.hp-case-post-copy p {
  margin: 0;
}

.hp-case-post-copy h3 {
  font-size: 1.25rem;
  line-height: 1.35;
}

.hp-case-post-copy h3 a {
  color: var(--hp-ink);
  text-decoration: none;
}

.hp-case-post-copy > p:last-child {
  color: var(--hp-muted);
  font-size: 14px;
}

.hp-archive-shell,
.hp-page-shell,
.hp-single-shell {
  padding: 64px 24px 82px;
}

.hp-entry-content > * + * {
  margin-block-start: 24px;
}

.hp-post-list {
  gap: 18px;
}

.hp-post-list .wp-block-post {
  padding: 24px;
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  background: var(--hp-card);
}

.hp-news-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.hp-news-col {
  display: flex;
  flex-direction: column;
  padding: 30px;
  border: 1px solid var(--hp-line);
  border-radius: var(--hp-radius);
  background: var(--hp-card);
}

.hp-news-col-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 6px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--hp-line);
}

.hp-news-col-head h3 {
  margin: 0;
  font-family: "Noto Serif SC", "Songti SC", "SimSun", serif;
  font-size: 1.5rem;
  color: var(--hp-ink);
}

.hp-news-col-head h3 a {
  color: inherit;
  text-decoration: none;
}

.hp-news-col-head h3 a:hover {
  color: var(--hp-red);
}

.hp-news-col-head span {
  min-width: max-content;
  color: var(--hp-muted);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hp-news-col .wp-block-query,
.hp-news-col .wp-block-post-template {
  flex: 1 1 auto;
  margin: 0;
}

.hp-news-col .wp-block-post-template {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  list-style: none;
}

.hp-news-col .wp-block-post {
  padding: 15px 0;
  border-bottom: 1px solid rgba(214, 203, 187, 0.6);
}

.hp-news-col .wp-block-post:last-child {
  border-bottom: 0;
}

.hp-news-col .wp-block-post-title {
  margin: 0;
  font-family: var(--hp-display, inherit);
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.5;
}

.hp-news-col .wp-block-post-title a {
  color: var(--hp-ink-soft);
  text-decoration: none;
}

.hp-news-col .wp-block-post-title a:hover {
  color: var(--hp-red);
}

.hp-news-more {
  margin-top: 18px;
}

.hp-news-more a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--hp-red-dark);
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}

.hp-footer {
  margin: 0;
  padding: 54px 24px 30px;
  border-top: 1px solid var(--hp-line);
  background: #171512;
  color: var(--hp-card);
}

.hp-footer a {
  color: inherit;
}

.hp-footer-note {
  color: #d4cbbc;
  font-size: 14px;
}

.hp-old-backup-note {
  padding: 18px;
  border: 1px dashed var(--hp-red);
  background: #fff8ef;
  color: var(--hp-red-dark);
}

@media (max-width: 1100px) {
  .hp-hero-title {
    font-size: 3.9rem;
  }

  .hp-section-title {
    font-size: 2.55rem;
  }

  .hp-model-hero .hp-hero-title {
    font-size: 3.4rem;
  }

  .hp-dossier-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hp-profile-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .hp-case-post-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 782px) {
  body {
    font-size: 16px;
  }

  .hp-site-header {
    position: static;
  }

  .hp-site-header .wp-block-group {
    align-items: flex-start;
  }

  .hp-brand {
    min-width: 0;
  }

  .hp-brand-note {
    margin-left: 0;
  }

  .hp-casting-hero,
  .hp-section,
  .hp-model-hero,
  .hp-archive-shell,
  .hp-page-shell,
  .hp-single-shell {
    padding-right: 18px;
    padding-left: 18px;
  }

  .hp-casting-hero {
    min-height: auto;
    padding-top: 42px;
  }

  .hp-hero-title,
  .hp-model-hero .hp-hero-title {
    font-size: 2.55rem;
    line-height: 1.13;
  }

  .hp-hero-lede {
    font-size: 17px;
  }

  .hp-hero-board {
    min-height: auto;
  }

  .hp-hero-portrait {
    position: relative;
    right: auto;
    bottom: auto;
    width: 70%;
    margin: -70px 0 0 auto;
  }

  .hp-proof-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hp-section-title {
    font-size: 2.15rem;
  }

  .hp-dossier-grid {
    grid-template-columns: 1fr;
  }

  .hp-news-grid {
    grid-template-columns: 1fr;
  }

  .hp-profile-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .hp-case-post-grid {
    grid-template-columns: 1fr;
  }

  .hp-model-gallery.wp-block-gallery.has-nested-images figure.wp-block-image,
  .hp-case-grid.wp-block-gallery.has-nested-images figure.wp-block-image {
    width: calc(50% - 8px);
  }
}

@media (max-width: 520px) {
  .hp-hero-title,
  .hp-model-hero .hp-hero-title {
    font-size: 2.2rem;
  }

  .hp-proof-strip {
    grid-template-columns: 1fr;
  }

  .hp-profile-grid {
    grid-template-columns: 1fr;
  }

  .hp-hero-portrait {
    width: 82%;
  }

  .hp-model-gallery.wp-block-gallery.has-nested-images figure.wp-block-image,
  .hp-case-grid.wp-block-gallery.has-nested-images figure.wp-block-image {
    width: 100%;
  }
}
