/*
Theme Name: 安適得台灣版（多語言多貨幣）
Theme URI: https://example.com/
Author: Custom build
Description: 可遷移的繁體中文寵物關節保健品牌主題，支援 WooCommerce。
Version: 1.4.0
Text Domain: antinol-taiwan
*/

:root {
  --ink: #18332f;
  --ink-soft: #55706a;
  --cream: #f7f3ea;
  --paper: #fffdf8;
  --line: #dfe7df;
  --mint: #d9e9dd;
  --sage: #a8c2ae;
  --coral: #dd6e51;
  --sun: #efc45d;
  --max: 1240px;
  --radius: 6px;
  --shadow: 0 16px 40px rgba(24, 51, 47, .10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  line-height: 1.7;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
button, input { font: inherit; }
.screen-reader-text { clip: rect(0,0,0,0); clip-path: inset(50%); height: 1px; overflow: hidden; position: absolute; white-space: nowrap; width: 1px; }
.container { width: min(var(--max), calc(100% - 48px)); margin-inline: auto; }
.skip-link { position: absolute; left: 20px; top: -80px; z-index: 20; padding: 10px 16px; background: var(--ink); color: white; }
.skip-link:focus { top: 10px; }

.announcement { position: sticky; top: 0; z-index: 30; min-height: 42px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 26px; background: #ff6900; color: #fff; font-size: 15px; font-weight: 700; letter-spacing: 0; }
.announcement-copy { display: flex; align-items: center; justify-content: center; flex: 1; gap: 7px; text-align: center; }
.announcement-item { display: none; }
.announcement-item.is-active { display: inline; }
.announcement-copy a, .announcement-copy strong { color: inherit; font-weight: 800; }
.announcement-arrow { width: 28px; height: 28px; padding: 0; border: 0; background: transparent; color: inherit; font-size: 31px; line-height: 1; cursor: pointer; }
.site-header { position: sticky; top: 42px; z-index: 25; background: rgba(255,255,255,.98); border-bottom: 1px solid #ececec; backdrop-filter: blur(12px); transition: box-shadow .2s ease; }
.site-header.is-scrolled { box-shadow: 0 5px 18px rgba(24,51,47,.08); }
.utility-row { min-height: 50px; }
.utility-inner { display: flex; align-items: center; justify-content: space-between; min-height: 50px; }
.utility-actions { display: flex; align-items: center; gap: 16px; margin-left: auto; }
.brand-row { min-height: 124px; display: grid; place-items: center; }
.brand-row .container { display: flex; justify-content: center; }
.site-header.is-scrolled .utility-row, .site-header.is-scrolled .utility-inner { min-height: 38px; }
.site-header.is-scrolled .brand-row { min-height: 72px; }
.site-header.is-scrolled .nav-inner, .site-header.is-scrolled .primary-nav a { min-height: 50px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 29px; font-weight: 800; letter-spacing: .02em; white-space: nowrap; }
.brand small { display: block; margin-top: -5px; font-size: 9px; letter-spacing: .16em; text-align: center; }
.brand-mark { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 0; background: transparent; color: #a99283; font-size: 30px; }
.nav-row { border-top: 1px solid #f2f2f2; }
.nav-inner { position: relative; display: flex; justify-content: center; min-height: 62px; }
.primary-nav ul { display: flex; gap: 30px; align-items: center; list-style: none; margin: 0; padding: 0; font-size: 15px; font-weight: 600; }
.primary-nav a { display: inline-flex; align-items: center; min-height: 62px; padding: 5px 0; border-bottom: 2px solid transparent; white-space: nowrap; }
.primary-nav a:hover, .primary-nav a:focus { border-color: var(--coral); }
.header-actions { display: flex; align-items: center; gap: 8px; }
.localization-tools { display: flex; align-items: center; gap: 12px; color: var(--ink); font-size: 15px; }
.localization-tools:empty { display: none; }
.localization-tools > div:empty { display: none; }
.localization-tools select { min-height: 34px; padding: 4px 22px 4px 4px; border: 0; border-radius: 0; background: transparent; color: var(--ink); font: inherit; font-weight: 600; }
.localization-tools .woocs_auto_switcher, .localization-tools .trp-language-switcher { margin: 0; }
.localization-tools .yay-currency-custom-select-wrapper { width: 158px !important; min-width: 0 !important; }
.localization-tools .yay-currency-custom-select { width: 158px !important; min-width: 0 !important; }
.localization-tools .yay-currency-custom-select__trigger { min-height: 32px !important; padding: 3px 6px !important; border-radius: 5px !important; }
.localization-tools .yay-currency-selected-option, .localization-tools .trp-language-item-name { max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px !important; }
.localization-tools .trp-shortcode-switcher__wrapper { --font-size: 12px !important; --flag-size: 14px !important; }
.localization-tools .trp-current-language-item__wrapper { min-height: 32px !important; padding: 3px 6px !important; }
.localization-tools .yay-currency-flag { transform: scale(.72); }
.icon-link, .menu-toggle { width: 38px; height: 38px; display: grid; place-items: center; border: 0; border-radius: 0; background: transparent; color: #111; cursor: pointer; font-size: 23px; }
.icon-link:hover, .menu-toggle:hover { color: var(--coral); }
.menu-toggle { display: none; }
.cart-count { display: inline-grid; place-items: center; min-width: 16px; height: 16px; margin-left: -4px; border-radius: 50%; background: var(--coral); color: white; font-size: 10px; line-height: 1; }

.hero { background: var(--cream); }
.hero-grid { min-height: 610px; display: grid; grid-template-columns: 1fr; align-items: stretch; }
.hero-copy { display: flex; flex-direction: column; justify-content: center; padding: 72px 9% 72px 0; }
.eyebrow { margin: 0 0 14px; color: var(--coral); font-size: 12px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.hero h1 { max-width: 620px; margin: 0; font-size: 68px; line-height: 1.08; letter-spacing: -.03em; }
.hero h1 em { color: var(--coral); font-style: normal; }
.hero-lead { max-width: 520px; margin: 24px 0 0; color: var(--ink-soft); font-size: 18px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.button { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 11px 20px; border: 1px solid var(--ink); border-radius: var(--radius); background: var(--ink); color: white; font-size: 14px; font-weight: 800; cursor: pointer; transition: transform .2s ease, background .2s ease; }
.button:hover, .button:focus { background: var(--coral); border-color: var(--coral); transform: translateY(-2px); }
.button--quiet { background: transparent; color: var(--ink); }
.button--quiet:hover, .button--quiet:focus { color: white; }
.hero-media { min-height: 610px; position: relative; overflow: hidden; background: var(--mint); }
.carousel-track, .carousel-slide { position: absolute; inset: 0; }
.carousel-slide { background-position: center; background-size: cover; opacity: 0; transition: opacity .6s ease; }
.carousel-slide.is-active { opacity: 1; }
.carousel-control { position: absolute; z-index: 2; top: 50%; display: grid; width: 42px; height: 42px; place-items: center; border: 1px solid rgba(255,255,255,.8); border-radius: 50%; background: rgba(17,35,31,.42); color: white; font-size: 20px; transform: translateY(-50%); }
.carousel-control:hover { background: var(--coral); }
.carousel-prev { left: 18px; }
.carousel-next { right: 18px; }
.carousel-dots { position: absolute; z-index: 2; top: 24px; right: 24px; display: flex; gap: 7px; }
.carousel-dots button { width: 8px; height: 8px; padding: 0; border: 1px solid white; border-radius: 50%; background: transparent; }
.carousel-dots button[aria-selected="true"] { background: white; }
.custom-block { background: var(--paper); }
.custom-block-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 54px; align-items: center; }
.custom-block-grid > div:last-child { max-width: 560px; }
.custom-block-image { min-height: 360px; background: center/cover no-repeat; }
.hero-media::after { content: ""; position: absolute; right: 28px; bottom: 28px; width: 140px; height: 140px; border: 1px solid rgba(255,255,255,.7); border-radius: 50%; }
.hero-note { position: absolute; left: 28px; bottom: 28px; width: min(250px, calc(100% - 56px)); padding: 16px 18px; background: rgba(255,253,248,.92); color: var(--ink); font-size: 13px; }

.trust-strip { border-bottom: 1px solid var(--line); background: var(--paper); }
.trust-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; padding: 22px 0; }
.trust-item { display: flex; align-items: center; gap: 12px; color: var(--ink-soft); font-size: 13px; }
.trust-icon { width: 30px; height: 30px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; background: var(--mint); color: var(--ink); font-weight: 800; }

.section { padding: 96px 0; }
.section--cream { background: var(--cream); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 36px; }
.section#products .section-heading { display: block; }
.section#products .section-heading > p { max-width: 680px; margin: 14px 0 0; }
.section-heading h2 { max-width: 680px; margin: 0; font-size: 44px; line-height: 1.15; letter-spacing: -.025em; }
.section-heading p { max-width: 430px; margin: 0; color: var(--ink-soft); }
.product-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.product-card { position: relative; overflow: hidden; border: 1px solid var(--line); background: var(--paper); }
.product-image { aspect-ratio: 1 / 1; overflow: hidden; background: var(--mint); }
.product-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.product-card:hover .product-image img { transform: scale(1.04); }
.product-info { padding: 20px; }
.product-info h3 { margin: 0; font-size: 18px; line-height: 1.35; }
.product-info p { min-height: 48px; margin: 8px 0 16px; color: var(--ink-soft); font-size: 13px; }
.product-price { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-weight: 800; }
.product-empty { grid-column: 1 / -1; padding: 28px; border: 1px dashed var(--line); color: var(--ink-soft); text-align: center; }
.price-old { color: #8b9993; font-size: 12px; text-decoration: line-through; font-weight: 500; }
.product-link { color: var(--coral); font-size: 13px; font-weight: 800; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split-media { min-height: 500px; background: url('https://images.unsplash.com/photo-1548199973-03cce0bbc87b?auto=format&fit=crop&w=1300&q=86') center/cover; }
.split-copy h2 { margin: 0; font-size: 52px; line-height: 1.12; }
.split-copy > p { margin: 22px 0; color: var(--ink-soft); }
.check-list { list-style: none; margin: 26px 0 30px; padding: 0; }
.check-list li { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.check-list li::before { content: "✓"; color: var(--coral); font-weight: 900; }

.science-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 64px; align-items: start; }
.science-intro h2 { max-width: 650px; margin: 0; font-size: 52px; line-height: 1.1; }
.science-intro p { max-width: 590px; color: var(--ink-soft); }
.stat-list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.stat { min-height: 170px; padding: 22px; border: 1px solid var(--line); background: var(--paper); }
.stat strong { display: block; color: var(--coral); font-size: 38px; line-height: 1; }
.stat span { display: block; margin-top: 14px; color: var(--ink-soft); font-size: 13px; }

.faq-wrap { max-width: 900px; margin: 0 auto; }
.faq-item { border-top: 1px solid var(--line); }
.faq-item:last-child { border-bottom: 1px solid var(--line); }
.faq-question { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 0; border: 0; background: transparent; color: var(--ink); text-align: left; font-weight: 800; cursor: pointer; }
.faq-question span:last-child { color: var(--coral); font-size: 24px; font-weight: 400; }
.faq-answer { display: none; padding: 0 44px 22px 0; color: var(--ink-soft); font-size: 14px; }
.faq-item.is-open .faq-answer { display: block; }

.newsletter { background: var(--ink); color: white; }
.newsletter-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.newsletter h2 { margin: 0; font-size: 46px; line-height: 1.12; }
.newsletter p { margin: 14px 0 0; color: #c8d5cf; }
.newsletter-form { display: flex; gap: 8px; }
.newsletter-form input { min-width: 0; flex: 1; min-height: 48px; padding: 10px 14px; border: 1px solid #66817a; border-radius: var(--radius); background: transparent; color: white; }
.newsletter-form input::placeholder { color: #b1c5bd; }
.newsletter-form .button { border-color: var(--sun); background: var(--sun); color: var(--ink); }
.newsletter-form .button:hover { border-color: white; background: white; }

.site-footer { padding: 58px 0 26px; background: var(--cream); }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 30px; padding-bottom: 44px; }
.footer-title { margin: 0 0 15px; font-size: 13px; text-transform: uppercase; letter-spacing: .1em; }
.footer-list { list-style: none; margin: 0; padding: 0; color: var(--ink-soft); font-size: 14px; }
.footer-list li + li { margin-top: 7px; }
.footer-bottom { display: flex; justify-content: space-between; gap: 20px; padding-top: 22px; border-top: 1px solid var(--line); color: var(--ink-soft); font-size: 12px; }

.woocommerce .site-main { padding: 40px 0 90px; }
.woocommerce ul.products { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.woocommerce ul.products::before, .woocommerce ul.products::after { display: none; }
.woocommerce ul.products li.product { width: auto; margin: 0; padding: 0; border: 1px solid var(--line); background: var(--paper); }
.woocommerce ul.products li.product img { margin: 0; aspect-ratio: 1; object-fit: cover; }
.woocommerce ul.products li.product .woocommerce-loop-product__title, .woocommerce ul.products li.product .price { padding-inline: 20px; }
.woocommerce div.product { display: grid; grid-template-columns: 1fr 1fr; gap: 54px; }
.woocommerce div.product div.images img { background: var(--cream); }
.woocommerce div.product .summary h1 { font-size: 52px; line-height: 1.1; }
.woocommerce button.button, .woocommerce a.button, .woocommerce button.button.alt { border-radius: var(--radius); background: var(--ink); color: white; }
.woocommerce button.button:hover, .woocommerce a.button:hover { background: var(--coral); color: white; }

@media (max-width: 900px) {
  .container { width: min(var(--max), calc(100% - 32px)); }
  .site-header { top: 38px; }
  .utility-row, .utility-inner { min-height: 40px; }
  .brand-row { min-height: 88px; }
  .nav-inner { justify-content: flex-start; min-height: 52px; }
  .menu-toggle { display: grid; }
  .primary-nav { position: absolute; left: 0; right: 0; top: calc(100% + 1px); display: none; padding: 12px 18px; border: 1px solid var(--line); background: var(--paper); box-shadow: var(--shadow); }
  .primary-nav.is-open { display: block; }
  .primary-nav ul { display: block; }
  .primary-nav li + li { border-top: 1px solid var(--line); }
  .primary-nav a { display: block; padding: 12px 0; }
  .hero-grid, .split, .science-grid, .newsletter-grid { grid-template-columns: 1fr; gap: 0; }
  .hero-copy { padding: 64px 0 48px; }
  .hero h1, .split-copy h2, .science-intro h2 { font-size: 44px; }
  .section-heading h2, .newsletter h2, .woocommerce div.product .summary h1 { font-size: 40px; }
  .hero-media { min-height: 440px; }
  .trust-grid { grid-template-columns: repeat(2, 1fr); }
  .section { padding: 72px 0; }
  .section-heading { display: block; }
  .section-heading p { margin-top: 14px; }
  .product-grid, .woocommerce ul.products { grid-template-columns: repeat(2, 1fr); }
  .split-media { min-height: 380px; order: 2; }
  .split-copy { padding: 0 0 48px; }
  .science-intro { padding-bottom: 44px; }
  .newsletter-grid { gap: 26px; }
  .newsletter-form { padding-bottom: 6px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .woocommerce div.product { grid-template-columns: 1fr; gap: 28px; }
  .custom-block-grid { grid-template-columns: 1fr; gap: 28px; }
}
@media (max-width: 560px) {
  .announcement { min-height: 38px; padding: 0 10px; font-size: 12px; }
  .announcement-arrow { font-size: 25px; }
  .site-header { top: 38px; }
  .utility-inner { width: calc(100% - 20px); }
  .utility-actions { gap: 4px; }
  .localization-tools { gap: 4px; font-size: 12px; }
  .localization-tools .language-switcher { display: none; }
  .brand { font-size: 22px; }
  .brand-mark { font-size: 24px; }
  .brand-row { min-height: 78px; }
  .header-actions .icon-link:first-child { display: none; }
  .hero h1, .split-copy h2, .science-intro h2 { font-size: 36px; }
  .section-heading h2, .newsletter h2, .woocommerce div.product .summary h1 { font-size: 34px; }
  .hero-lead { font-size: 16px; }
  .hero-media { min-height: 360px; }
  .trust-grid, .product-grid, .woocommerce ul.products, .stat-list { grid-template-columns: 1fr; }
  .trust-item { font-size: 12px; }
  .section { padding: 58px 0; }
  .split-media { min-height: 300px; }
  .newsletter-form { display: block; }
  .newsletter-form .button { width: 100%; margin-top: 8px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 22px 18px; }
  .footer-grid > div:first-child { grid-column: 1 / -1; }
  .footer-bottom { display: block; }
  .footer-bottom span { display: block; margin-top: 8px; }
}
