/*
Theme Name: THAI STANDARD
Theme URI: https://thai-standard.com/
Author: THAI STANDARD
Description: タイ総合情報メディア「THAI STANDARD」専用の軽量WordPressテーマ。
Version: 1.2.1
Requires at least: 6.4
Requires PHP: 8.0
Text Domain: thai-standard
*/

:root {
  --ts-red: #b4262b;
  --ts-red-dark: #8f1c20;
  --ts-gold: #a67c27;
  --ts-ink: #171916;
  --ts-muted: #66685f;
  --ts-paper: #f7f5ef;
  --ts-white: #fff;
  --ts-line: #deddd4;
  --ts-dark: #252923;
  --ts-width: 1180px;
  --ts-serif: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Yu Gothic UI", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  --ts-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Yu Gothic UI", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ts-ink); background: var(--ts-paper); font-family: Meiryo, "メイリオ", "Noto Sans JP", Arial, sans-serif !important; line-height: 1.85; }
h1, h2, h3, h4, h5, h6, p, li, dt, dd { font-family: Meiryo, "メイリオ", "Noto Sans JP", Arial, sans-serif !important; }
img { max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--ts-red); }
.screen-reader-text { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.ts-container { width: min(100% - 40px, var(--ts-width)); margin-inline: auto; }
.ts-alert { padding: 8px 20px; color: var(--ts-white); background: var(--ts-red); font-size: .78rem; text-align: center; }
.ts-alert a { text-decoration: underline; text-underline-offset: 3px; }
.site-header { background: var(--ts-white); border-bottom: 1px solid var(--ts-line); }
.site-header__main { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.site-branding { min-width: 0; }
.site-title { margin: 0; font-family: var(--ts-serif); font-size: clamp(1.65rem, 4vw, 2.45rem); font-weight: 400; letter-spacing: .04em; line-height: 1.1; white-space: nowrap; }
.site-title span { color: var(--ts-red); }
.site-description { margin: 7px 0 0; color: var(--ts-muted); font-size: .72rem; }
.custom-logo { display: block; max-height: 54px; width: auto; }
.header-tools { display: flex; align-items: center; gap: 12px; }
.search-toggle, .menu-toggle { padding: 8px 10px; color: var(--ts-ink); background: transparent; border: 1px solid var(--ts-line); cursor: pointer; font: inherit; }
.menu-toggle { display: none; }
.header-search { display: none; padding: 14px 0; border-top: 1px solid var(--ts-line); }
.header-search.is-open { display: block; }
.search-form { display: flex; gap: 8px; }
.search-field { width: 100%; min-height: 42px; padding: 8px 12px; background: var(--ts-white); border: 1px solid var(--ts-line); font: inherit; }
.search-submit, .ts-button { display: inline-block; padding: 10px 18px; color: var(--ts-white); background: var(--ts-red); border: 0; cursor: pointer; font: inherit; font-weight: 600; }
.search-submit:hover, .ts-button:hover { color: var(--ts-white); background: var(--ts-red-dark); }
.primary-navigation { border-top: 1px solid var(--ts-line); }
.primary-navigation ul { min-height: 48px; margin: 0; padding: 0; display: flex; align-items: center; gap: 26px; list-style: none; }
.primary-navigation a { display: block; padding: 12px 0; font-size: .83rem; font-weight: 600; }
.primary-navigation .current-menu-item > a, .primary-navigation .current-menu-ancestor > a { color: var(--ts-red); }
.site-main { padding: 30px 0 64px; }
.ts-section { padding-top: 42px; }
.ts-section-heading { margin-bottom: 22px; display: flex; align-items: end; justify-content: space-between; gap: 16px; border-bottom: 2px solid var(--ts-ink); }
.ts-section-heading h2 { margin: 0 0 9px; font-family: var(--ts-serif); font-size: 1.65rem; font-weight: 400; letter-spacing: .03em; }
.ts-section-heading a { margin-bottom: 10px; color: var(--ts-red); font-size: .78rem; font-weight: 600; }
.ts-kicker, .cat-links { color: var(--ts-red); font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.ts-hero { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(270px, .9fr); gap: 30px; padding-bottom: 34px; border-bottom: 1px solid var(--ts-line); }
.ts-feature { min-height: 390px; position: relative; display: flex; align-items: end; overflow: hidden; color: var(--ts-white); background: linear-gradient(135deg, #27434e, #4d7379 48%, #b65f3f); }
.ts-feature__image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ts-feature::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.76), rgba(0,0,0,.04) 70%); }
.ts-feature__content { max-width: 760px; padding: 30px; position: relative; z-index: 1; }
.ts-feature__content .ts-kicker { color: #ffd2c8; }
.ts-feature h2 { margin: 8px 0 10px; font-family: var(--ts-serif); font-size: clamp(1.75rem, 4vw, 3rem); font-weight: 400; line-height: 1.35; }
.ts-feature p { margin: 0; color: #f2eee7; font-size: .9rem; }
.ts-brief__title { margin: 0; padding-bottom: 10px; border-bottom: 2px solid var(--ts-ink); font-family: var(--ts-serif); font-size: 1.25rem; font-weight: 400; }
.ts-brief article { padding: 16px 0; border-bottom: 1px solid var(--ts-line); }
.ts-brief h3 { margin: 3px 0 6px; font-size: .96rem; line-height: 1.6; }
.ts-meta { color: var(--ts-muted); font-size: .7rem; }
.ts-card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.ts-card { min-width: 0; }
.ts-card__image { aspect-ratio: 16/9; margin-bottom: 13px; overflow: hidden; background: linear-gradient(145deg, #d8c28d, #94644e); }
.ts-card__image img { width: 100%; height: 100%; object-fit: cover; transition: transform .25s ease; }
.ts-card:hover .ts-card__image img { transform: scale(1.025); }
.ts-card h2, .ts-card h3 { margin: 4px 0 7px; font-size: 1rem; line-height: 1.6; }
.ts-card p { margin: 0; color: var(--ts-muted); font-size: .78rem; }
.ts-select-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; }
.ts-select-item { min-height: 112px; padding: 18px; background: var(--ts-white); border-top: 3px solid var(--ts-gold); }
.ts-select-item strong { display: block; margin-bottom: 8px; }
.ts-select-item span { color: var(--ts-muted); font-size: .73rem; }
.ts-business { padding: 30px; display: grid; grid-template-columns: 1.35fr .75fr; gap: 30px; color: var(--ts-white); background: var(--ts-dark); }
.ts-business h2 { margin: 4px 0 8px; font-family: var(--ts-serif); font-size: 1.7rem; font-weight: 400; }
.ts-business p { margin: 0; color: #c8c9bf; font-size: .82rem; }
.ts-business__links { display: grid; gap: 8px; align-content: center; }
.ts-business__links a { padding: 9px 12px; border: 1px solid #55594f; font-size: .78rem; }
.ts-newsletter { margin-top: 40px; padding: 25px; display: flex; align-items: center; justify-content: space-between; gap: 22px; background: var(--ts-white); border-left: 4px solid var(--ts-red); }
.ts-newsletter h2 { margin: 0 0 4px; font-size: 1.05rem; }
.ts-newsletter p { margin: 0; color: var(--ts-muted); font-size: .76rem; }
.content-area { display: grid; grid-template-columns: minmax(0, 760px) minmax(230px, 1fr); gap: 54px; }
.page-header { margin-bottom: 28px; padding-bottom: 14px; border-bottom: 2px solid var(--ts-ink); }
.page-title { margin: 0; font-family: var(--ts-serif); font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 400; line-height: 1.35; }
.archive-description { color: var(--ts-muted); }
.post-list article { padding: 22px 0; display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 22px; border-bottom: 1px solid var(--ts-line); }
.post-list__image { aspect-ratio: 16/9; overflow: hidden; background: #d9d4c5; }
.post-list__image img { width: 100%; height: 100%; object-fit: cover; }
.post-list h2 { margin: 3px 0 7px; font-size: 1.15rem; line-height: 1.55; }
.post-list p { margin: 0; color: var(--ts-muted); font-size: .82rem; }
.entry-header { margin-bottom: 24px; }
.entry-title { margin: 8px 0 18px; font-family: var(--ts-sans); font-size: clamp(1.85rem, 4.4vw, 2.75rem); font-weight: 800; letter-spacing: -.035em; line-height: 1.38; }
.entry-meta { color: var(--ts-muted); font-size: .75rem; }
.entry-thumbnail { margin: 24px 0; }
.entry-thumbnail img { width: 100%; }
.entry-content { color: #262724; font-size: 1.03rem; line-height: 2; }
.entry-content > h2, .entry-content > section > h2 { margin: 2.5em 0 1em; padding: 0 0 .55em 14px; border-bottom: 1px solid var(--ts-line); border-left: 5px solid var(--ts-red); font-size: 1.42rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.5; }
.entry-content p { margin: 0 0 1.5em; }
.entry-content .ts-guide-lead { margin: 8px 0 40px; padding: 22px 24px; background: #fff; border-left: 5px solid var(--ts-red); box-shadow: 0 8px 24px rgba(29, 31, 27, .06); font-size: 1.06rem; font-weight: 600; line-height: 1.9; }
.entry-content .ts-guide-lead p { margin: 0; }
.entry-content .ts-guide-facts { margin: 48px 0; }
.entry-content .ts-guide-facts dl { margin: 0; overflow: hidden; background: #fff; border: 1px solid var(--ts-line); border-radius: 10px; }
.entry-content .ts-guide-facts dl > div { display: grid; grid-template-columns: 150px minmax(0, 1fr); border-bottom: 1px solid var(--ts-line); }
.entry-content .ts-guide-facts dl > div:last-child { border-bottom: 0; }
.entry-content .ts-guide-facts dt, .entry-content .ts-guide-facts dd { margin: 0; padding: 14px 18px; }
.entry-content .ts-guide-facts dt { background: #f0ede5; font-size: .82rem; font-weight: 700; }
.entry-content .ts-guide-facts dd { font-size: .9rem; }
.entry-content .ts-guide-map { margin: 48px 0; }
.entry-content .ts-map { margin: 0 0 30px; overflow: hidden; background: var(--ts-white); border: 1px solid var(--ts-line); border-radius: 10px; box-shadow: 0 8px 24px rgba(29, 31, 27, .08); }
.entry-content .ts-map iframe { display: block; width: 100%; }
.entry-content h3 { margin-top: 1.8em; padding-left: 12px; border-left: 3px solid var(--ts-red); font-size: 1.2rem; }
.entry-content a { color: var(--ts-red); text-decoration: underline; text-underline-offset: 3px; }
.entry-content blockquote { margin: 1.6em 0; padding: 14px 20px; background: var(--ts-white); border-left: 4px solid var(--ts-gold); }
.entry-content table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.entry-content th, .entry-content td { padding: 10px; border-bottom: 1px solid var(--ts-line); text-align: left; }
.entry-content th { background: var(--ts-white); }
.ts-source { margin-top: 38px; padding: 18px; background: var(--ts-white); border: 1px solid var(--ts-line); font-size: .78rem; }
.ts-source strong { display: block; margin-bottom: 4px; }
.post-navigation { margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--ts-line); }
.sidebar { font-size: .82rem; }
.widget { margin-bottom: 30px; }
.widget-title { padding-bottom: 8px; border-bottom: 2px solid var(--ts-ink); font-family: var(--ts-serif); font-size: 1.05rem; font-weight: 400; }
.widget ul { padding-left: 18px; }
.pagination { margin-top: 32px; }
.nav-links { display: flex; gap: 8px; flex-wrap: wrap; }
.page-numbers { min-width: 38px; padding: 7px 10px; text-align: center; background: var(--ts-white); border: 1px solid var(--ts-line); }
.page-numbers.current { color: var(--ts-white); background: var(--ts-red); border-color: var(--ts-red); }
.site-footer { padding: 42px 0 22px; color: #dadbd2; background: var(--ts-dark); }
.footer-grid { display: grid; grid-template-columns: 1.25fr 1fr 1fr; gap: 36px; }
.footer-title { margin: 0 0 8px; color: var(--ts-white); font-family: var(--ts-serif); font-size: 1.45rem; font-weight: 400; }
.footer-description { margin: 0; color: #b7b9ae; font-size: .76rem; }
.footer-menu { margin: 0; padding: 0; list-style: none; font-size: .78rem; }
.footer-menu li { margin-bottom: 7px; }
.site-info { margin-top: 32px; padding-top: 18px; color: #9fa198; border-top: 1px solid #454940; font-size: .68rem; }

@media (max-width: 860px) {
  .menu-toggle { display: inline-block; }
  .primary-navigation { display: none; }
  .primary-navigation.is-open { display: block; }
  .primary-navigation ul { padding: 12px 0; display: block; }
  .primary-navigation a { padding: 8px 0; }
  .ts-hero, .content-area { grid-template-columns: 1fr; }
  .ts-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ts-select-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sidebar { padding-top: 20px; border-top: 1px solid var(--ts-line); }
}

@media (max-width: 600px) {
  .ts-container { width: min(100% - 28px, var(--ts-width)); }
  .site-header__main { min-height: 74px; gap: 10px; }
  .site-title { font-size: clamp(1.15rem, 5.6vw, 1.45rem); letter-spacing: .015em; }
  .header-tools { gap: 6px; }
  .search-toggle, .menu-toggle { padding: 7px 8px; font-size: .75rem; white-space: nowrap; }
  .site-description { display: none; }
  .ts-feature { min-height: 300px; }
  .ts-feature__content { padding: 22px; }
  .ts-card-grid { grid-template-columns: 1fr; }
  .ts-card { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 14px; }
  .ts-card__image { margin: 0; }
  .ts-card p { display: none; }
  .ts-select-grid { grid-template-columns: 1fr 1fr; }
  .ts-business { grid-template-columns: 1fr; padding: 22px; }
  .ts-newsletter { align-items: start; flex-direction: column; }
  .post-list article { grid-template-columns: 105px minmax(0, 1fr); gap: 14px; }
  .post-list h2 { font-size: .92rem; }
  .post-list p { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .entry-content { font-size: .96rem; line-height: 1.9; }
  .entry-content .ts-guide-lead { padding: 18px; }
  .entry-content .ts-guide-facts dl > div { grid-template-columns: 1fr; }
  .entry-content .ts-guide-facts dt { padding-bottom: 7px; }
  .entry-content .ts-guide-facts dd { padding-top: 7px; }
}
