/*
Theme Name: Catrix
Theme URI: https://catrix.my
Author: Catrix
Description: 品牌定制主题 — 由Claude根据catrix-website-draft.html草稿转制,首页保留原设计像素级还原,博客区(Home/Blog页)用于Soro自动发布SEO文章。
Version: 1.0
Requires at least: 5.0
Requires PHP: 7.4
Text Domain: catrix
*/

:root {
  --cream: #FDF6EC;
  --cream-deep: #F2D9C0;
  --ink: #1C1410;
  --ink-soft: #5A4A3F;
  --pumpkin: #C97B3A;
  --pumpkin-deep: #A6602A;
  --teal: #8DA98A;
  --teal-deep: #6C8969;
  --blush: #F2D9C0;
  --white: #FFFDF9;
  --line: rgba(28,20,16,0.12);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--cream);
  color: var(--ink);
  font-family: 'DM Sans', sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, .display {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.05;
}

.mono {
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: 0.02em;
}

a { color: inherit; text-decoration: none; }

img { max-width: 100%; display: block; }

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 32px;
}

/* ---------- NAV ---------- */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(251,244,232,0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  gap: 8px;
}
.logo img {
  height: 34px;
  width: auto;
}
.nav-links {
  display: flex;
  gap: 32px;
  font-size: 0.92rem;
  font-weight: 600;
  list-style: none;
}
.nav-links a {
  opacity: 0.75;
  transition: opacity 0.2s;
}
.nav-links a:hover { opacity: 1; }
.nav-cta {
  background: var(--ink);
  color: var(--cream) !important;
  padding: 10px 20px;
  border-radius: 100px;
  font-size: 0.88rem;
  font-weight: 700;
  opacity: 1 !important;
}
@media (max-width: 780px) {
  .nav-links { display: none; }
}

/* ---------- HERO ---------- */
.hero {
  padding: 88px 0 64px;
  position: relative;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--white);
  border: 1px solid var(--line);
  padding: 7px 14px;
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--teal-deep);
  margin-bottom: 22px;
}
.eyebrow::before {
  content: '';
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--teal);
}
.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  margin-bottom: 22px;
}
.hero h1 em {
  font-style: italic;
  color: var(--pumpkin-deep);
}
.hero p.lead {
  font-size: 1.1rem;
  color: var(--ink-soft);
  max-width: 480px;
  margin-bottom: 32px;
}
.hero-ctas {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 100px;
  font-weight: 700;
  font-size: 0.95rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn-primary {
  background: var(--pumpkin);
  color: var(--white);
  box-shadow: 0 6px 0 var(--pumpkin-deep);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 0 var(--pumpkin-deep); }
.btn-secondary {
  background: transparent;
  color: var(--ink);
  border: 1.5px solid var(--ink);
}
.btn-secondary:hover { background: var(--ink); color: var(--cream); }

/* Judge panel — signature element */
.judge-panel {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.judge-card {
  background: var(--white);
  border-radius: 20px;
  padding: 18px 14px 20px;
  text-align: center;
  border: 1px solid var(--line);
  box-shadow: 0 10px 24px rgba(43,33,25,0.06);
  transform: rotate(var(--tilt, 0deg));
  transition: transform 0.25s ease;
  position: relative;
}
.judge-card:hover { transform: rotate(0deg) translateY(-6px); }
.judge-card:nth-child(1) { --tilt: -4deg; margin-top: 26px; }
.judge-card:nth-child(2) { --tilt: 2deg; }
.judge-card:nth-child(3) { --tilt: -2deg; margin-top: 18px; }
.judge-photo {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 14px;
  margin-bottom: 12px;
  display: grid;
  place-items: center;
  font-size: 2.6rem;
  position: relative;
  overflow: hidden;
}
.judge-photo img { width: 100%; height: 100%; object-fit: cover; }
.judge-photo::after {
  content: 'warm-lit photo, cream bg';
  position: absolute;
  bottom: 6px;
  right: 8px;
  font-size: 0.5rem;
  font-family: 'JetBrains Mono', monospace;
  color: rgba(255,255,255,0.8);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  text-align: right;
  max-width: 90%;
}
.judge-photo.has-photo::after { content: ''; display: none; }
.judge-1 .judge-photo { background: linear-gradient(135deg, #C97B3A, #A6602A); }
.judge-2 .judge-photo { background: linear-gradient(135deg, #F2D9C0, #E0BD98); }
.judge-3 .judge-photo { background: linear-gradient(135deg, #8DA98A, #6C8969); }
.judge-name {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1.05rem;
}
.judge-title {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 2px;
}
.verdict-stamp {
  position: absolute;
  top: -14px;
  right: -10px;
  background: var(--teal);
  color: var(--white);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.62rem;
  font-weight: 600;
  padding: 5px 9px;
  border-radius: 8px;
  transform: rotate(8deg);
  box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

/* ---------- STORY ---------- */
.story {
  background: var(--cream-deep);
  color: var(--ink);
  padding: 96px 0;
  margin-top: 40px;
}
.story-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 64px;
  align-items: center;
}
.story-photo {
  aspect-ratio: 4/5;
  border-radius: 24px;
  background: linear-gradient(160deg, #6C8969, #3d5240);
  display: grid;
  place-items: center;
  font-size: 3rem;
  color: rgba(255,255,255,0.4);
  position: relative;
  overflow: hidden;
}
.story-photo img { width: 100%; height: 100%; object-fit: cover; }
.story-photo span.tag {
  position: absolute;
  bottom: 18px;
  left: 18px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  color: rgba(255,255,255,0.6);
  text-transform: uppercase;
}
.story-eyebrow {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  color: var(--pumpkin-deep);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 18px;
}
.story h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.6rem);
  margin-bottom: 20px;
}
.story p {
  color: var(--ink-soft);
  font-size: 1.02rem;
  max-width: 520px;
  margin-bottom: 16px;
}
.story-highlight {
  display: inline-block;
  background: var(--white);
  color: var(--pumpkin-deep);
  padding: 2px 8px;
  border-radius: 6px;
  font-weight: 600;
}

/* ---------- INGREDIENTS STRIP ---------- */
.stats {
  padding: 72px 0;
}
.stats-head {
  text-align: center;
  max-width: 560px;
  margin: 0 auto 48px;
}
.stats-head .story-eyebrow { color: var(--teal-deep); text-align:center; }
.stats-head h2 { font-size: clamp(1.8rem, 3.2vw, 2.3rem); }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.stat-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 28px 20px;
  text-align: center;
}
.stat-num {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 2.2rem;
  color: var(--pumpkin-deep);
}
.stat-label {
  font-size: 0.85rem;
  color: var(--ink-soft);
  font-weight: 600;
  margin-top: 4px;
}
@media (max-width: 780px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- PRODUCTS ---------- */
.products { padding: 40px 0 96px; }
.products-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 40px;
  gap: 24px;
  flex-wrap: wrap;
}
.products-head h2 { font-size: clamp(1.9rem, 3.4vw, 2.5rem); }
.products-head p { color: var(--ink-soft); max-width: 380px; }
.product-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}
@media (max-width: 1050px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); }
}
.product-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 32px rgba(43,33,25,0.09);
}
.product-card.featured {
  border: 2px solid var(--pumpkin);
}
.product-badge {
  background: var(--pumpkin);
  color: var(--white);
  font-size: 0.65rem;
  font-weight: 700;
  text-align: center;
  padding: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.product-img {
  aspect-ratio: 1;
  background: var(--cream-deep);
  display: grid;
  place-items: center;
  font-size: 2.2rem;
  overflow: hidden;
}
.product-img img { width: 100%; height: 100%; object-fit: cover; }
.product-body { padding: 18px 18px 22px; flex: 1; display: flex; flex-direction: column; }
.product-name { font-family: 'Playfair Display', serif; font-weight: 600; font-size: 1.05rem; margin-bottom: 4px; }
.product-desc { font-size: 0.85rem; color: var(--ink-soft); margin-bottom: 14px; flex: 1; }
.product-price {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--teal-deep);
}
.product-platform-note {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--pumpkin-deep);
  text-decoration: underline;
}
@media (max-width: 900px) {
  .product-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- SHOP CTA ---------- */
.shop-cta {
  background: var(--cream-deep);
  border-radius: 28px;
  margin: 0 32px 96px;
  padding: 64px 40px;
  text-align: center;
}
.shop-cta h2 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); margin-bottom: 14px; }
.shop-cta p { color: var(--ink-soft); max-width: 480px; margin: 0 auto 32px; }
.shop-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.shop-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--white);
  border: 1.5px solid var(--ink);
  padding: 14px 28px;
  border-radius: 100px;
  font-weight: 700;
  transition: all 0.2s ease;
}
.shop-btn:hover { background: var(--ink); color: var(--cream); }

/* ---------- FOOTER ---------- */
footer {
  padding: 48px 0 32px;
  border-top: 1px solid var(--line);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}
.footer-social { display: flex; flex-wrap: wrap; gap: 14px 18px; font-weight: 600; font-size: 0.88rem; }
.footer-note { font-size: 0.78rem; color: var(--ink-soft); }

/* ---------- BLOG (Soro SEO articles land here) ---------- */
.blog-hero {
  padding: 64px 0 40px;
  text-align: center;
}
.blog-hero h1 { font-size: clamp(2rem, 4vw, 2.8rem); margin-bottom: 10px; }
.blog-hero p { color: var(--ink-soft); max-width: 480px; margin: 0 auto; }

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  padding: 0 0 96px;
}
.blog-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 16px 32px rgba(43,33,25,0.09); }
.blog-card-img {
  aspect-ratio: 16/10;
  background: var(--cream-deep);
  overflow: hidden;
}
.blog-card-img img { width: 100%; height: 100%; object-fit: cover; }
.blog-card-body { padding: 20px 20px 24px; flex: 1; display: flex; flex-direction: column; }
.blog-card-meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  color: var(--teal-deep);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 10px;
}
.blog-card-title {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  font-size: 1.15rem;
  margin-bottom: 8px;
}
.blog-card-title a:hover { color: var(--pumpkin-deep); }
.blog-card-excerpt { font-size: 0.88rem; color: var(--ink-soft); flex: 1; }
.blog-card-more { font-size: 0.82rem; font-weight: 700; color: var(--pumpkin-deep); margin-top: 14px; }
@media (max-width: 900px) {
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .blog-grid { grid-template-columns: 1fr; }
}

.pagination {
  display: flex;
  justify-content: center;
  gap: 10px;
  padding: 0 0 80px;
}
.pagination a, .pagination span {
  padding: 8px 16px;
  border-radius: 100px;
  border: 1px solid var(--line);
  font-weight: 600;
  font-size: 0.85rem;
}
.pagination .current { background: var(--ink); color: var(--cream); border-color: var(--ink); }

.single-post {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 0 96px;
}
.single-post .post-meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  color: var(--teal-deep);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 16px;
}
.single-post h1 {
  font-size: clamp(2rem, 4.4vw, 2.8rem);
  margin-bottom: 24px;
}
.single-post .post-thumb {
  aspect-ratio: 16/9;
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 36px;
  background: var(--cream-deep);
}
.single-post .post-thumb img { width: 100%; height: 100%; object-fit: cover; }
.single-post .post-content { font-size: 1.05rem; color: var(--ink-soft); }
.single-post .post-content p { margin-bottom: 20px; }
.single-post .post-content h2 {
  font-size: 1.5rem;
  color: var(--ink);
  margin: 36px 0 16px;
}
.single-post .post-content h3 {
  font-size: 1.2rem;
  color: var(--ink);
  margin: 28px 0 12px;
}
.single-post .post-content a { color: var(--pumpkin-deep); text-decoration: underline; }
.single-post .post-content ul, .single-post .post-content ol { margin: 0 0 20px 22px; color: var(--ink-soft); }
.single-post .post-content img { border-radius: 16px; margin: 24px 0; }
.single-post .back-link { display: inline-block; margin-top: 40px; font-weight: 700; color: var(--pumpkin-deep); }

/* ---------- GENERIC PAGE ---------- */
.page-content {
  max-width: 760px;
  margin: 0 auto;
  padding: 64px 0 96px;
}
.page-content h1 { font-size: clamp(2rem, 4vw, 2.6rem); margin-bottom: 28px; }
.page-content p { color: var(--ink-soft); margin-bottom: 18px; font-size: 1.02rem; }

@media (max-width: 780px) {
  .hero-grid { grid-template-columns: 1fr; }
  .story-grid { grid-template-columns: 1fr; }
  .story-photo { max-width: 320px; margin: 0 auto; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}

a:focus-visible, button:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
}
