/*
Theme Name: THREE-UP
Description: 株式会社THREE-UP のサイト用テーマ（1 ページ構成）。外観 → カスタマイズ →「THREE-UP 設定」で電話番号・会社情報・文章を変更できます。製品は管理画面の「製品」、お知らせは「お知らせ」から追加します。
Version: 1.0.0
Requires at least: 6.3
Requires PHP: 7.4
Text Domain: threeup
*/
:root {
  --ink: #1f2a33;
  --muted: #5d6b76;
  --line: #e3e8ec;
  --bg-soft: #f4f9fb;
  --brand: #2bb3df;      /* ロゴの水色 */
  --brand-dark: #1592bd;
  --accent: #8a7468;     /* リファインストレートのボトルの色 */
  --white: #fff;
  --header-h: 72px;
  --font-ja: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  --font-en: "Cormorant Garamond", "Times New Roman", serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }
body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font-ja);
  font-size: 16px;
  line-height: 1.9;
  letter-spacing: .04em;
  -webkit-text-size-adjust: 100%;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand-dark); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.container { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.container.narrow { max-width: 860px; }

/* ヘッダー */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(6px);
}
.header-inner {
  max-width: 1200px; margin: 0 auto; padding: 0 16px;
  height: var(--header-h);
  display: flex; align-items: center; gap: 24px;
}
.logo img { width: 120px; height: auto; }
.global-nav { display: flex; align-items: center; gap: 28px; margin-left: auto; }
.global-nav a { color: var(--ink); text-decoration: none; font-size: 15px; font-weight: 500; }
.global-nav a:hover { color: var(--brand-dark); }
.global-nav .nav-contact {
  background: var(--brand); color: var(--white);
  padding: 8px 20px; border-radius: 999px;
}
.global-nav .nav-contact:hover { background: var(--brand-dark); color: var(--white); }
.header-tel { display: flex; flex-direction: column; line-height: 1.3; text-align: right; }
.header-tel a { color: var(--ink); text-decoration: none; font-size: 20px; font-weight: 700; letter-spacing: .02em; }
.header-tel span { font-size: 11px; color: var(--muted); }
.menu-toggle { display: none; }

/* メインビジュアル */
.hero {
  background: url(images/hero-wave.png) right bottom / cover no-repeat, var(--white);
  min-height: 560px;
  display: flex; align-items: center;
}
.hero-inner { max-width: 1120px; width: 100%; margin: 0 auto; padding: 80px 16px; }
.hero-en { font-family: var(--font-en); font-size: 28px; color: var(--brand-dark); margin: 0 0 8px; letter-spacing: .08em; }
.hero-title { font-size: 44px; line-height: 1.5; margin: 0 0 24px; font-weight: 700; letter-spacing: .06em; }
.hero-lead { color: var(--muted); margin: 0 0 36px; }
.hero-buttons { display: flex; flex-wrap: wrap; gap: 16px; }

/* ボタン */
.btn {
  display: inline-block; text-align: center; text-decoration: none;
  font-weight: 700; font-size: 15px; letter-spacing: .08em;
  padding: 14px 36px; border-radius: 999px; border: 2px solid transparent;
  cursor: pointer; font-family: inherit; transition: background .2s, color .2s;
}
.btn-primary { background: var(--brand); color: var(--white); }
.btn-primary:hover { background: var(--brand-dark); }
.btn-outline { border-color: var(--ink); color: var(--ink); background: rgba(255,255,255,.7); }
.btn-outline:hover { background: var(--ink); color: var(--white); }
.btn-white { background: var(--white); color: var(--brand-dark); }
.btn-white:hover { background: var(--ink); color: var(--white); }

/* セクション共通 */
.section { padding: 100px 0; }
.section-head { text-align: center; margin-bottom: 56px; }
.section-en { font-family: var(--font-en); font-size: 20px; color: var(--brand-dark); margin: 0; letter-spacing: .12em; }
.section-en.light { color: rgba(255,255,255,.85); }
.section-title { font-size: 30px; margin: 4px 0 0; letter-spacing: .1em; }
.section-title::after {
  content: ""; display: block; width: 40px; height: 2px;
  background: var(--brand); margin: 18px auto 0;
}
.draft-note { font-size: 13px; color: #c2410c; background: #fff7ed; padding: 6px 12px; border-radius: 4px; }

/* 製品 */
.products { background: var(--bg-soft); }
.product-list { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.product {
  background: var(--white); border-radius: 8px; overflow: hidden;
  box-shadow: 0 2px 16px rgba(31,42,51,.06);
  display: flex; flex-direction: column;
}
.product-image { aspect-ratio: 1 / 1; overflow: hidden; background: #eee; }
.product-image img { width: 100%; height: 100%; object-fit: cover; }
.product-body { padding: 28px 28px 32px; }
.product-category { font-size: 13px; color: var(--accent); margin: 0; font-weight: 500; }
.product-name { font-size: 22px; margin: 2px 0 16px; letter-spacing: .06em; }
.product-points { margin: 0; padding: 0; list-style: none; font-size: 14.5px; line-height: 1.85; }
.product-points li { position: relative; padding-left: 1.3em; margin-bottom: 8px; }
.product-points li::before {
  content: ""; position: absolute; left: 0; top: .72em;
  width: 7px; height: 7px; border-radius: 50%; background: var(--brand);
}
.product-points small { font-size: 12px; color: var(--muted); }

/* 私たちについて */
.about-text { font-size: 16px; line-height: 2.1; }

/* 代理店募集 */
.agency { background: linear-gradient(120deg, var(--brand-dark), var(--brand)); color: var(--white); padding: 64px 0; }
.agency-inner { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.agency-title { font-size: 28px; line-height: 1.5; margin: 4px 0 12px; }
.agency-text { margin: 0; opacity: .92; }

/* お知らせ */
.news-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.news-list li { display: flex; gap: 32px; padding: 20px 8px; border-bottom: 1px solid var(--line); }
.news-list time { font-family: var(--font-en); font-size: 18px; color: var(--brand-dark); min-width: 72px; }

/* 企業情報 */
.company { background: var(--bg-soft); }
.company-table { width: 100%; border-collapse: collapse; background: var(--white); }
.company-table th, .company-table td { padding: 20px 24px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.company-table th { width: 28%; font-weight: 500; color: var(--muted); white-space: nowrap; }
.tbd { background: #fff3cd; color: #8a5a00; padding: 0 6px; border-radius: 3px; font-size: 14px; }

/* お問い合わせ */
.contact-lead { text-align: center; margin: -24px 0 40px; color: var(--muted); }
.contact-form { display: grid; gap: 20px; }
.form-row { display: grid; gap: 20px; }
.form-row.two { grid-template-columns: 1fr 1fr; }
.contact-form label, .contact-form .label { display: block; font-size: 14px; font-weight: 500; }
.contact-form em {
  font-style: normal; font-size: 11px; color: var(--white); background: #e05a47;
  padding: 1px 6px; border-radius: 3px; margin-left: 8px; vertical-align: 1px;
}
.contact-form input[type=text], .contact-form input[type=email], .contact-form input[type=tel],
.contact-form select, .contact-form textarea {
  display: block; width: 100%; margin-top: 6px;
  font: inherit; font-size: 16px; letter-spacing: normal;
  padding: 12px 14px; border: 1px solid #cfd8de; border-radius: 6px; background: var(--white); color: var(--ink);
}
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus { outline: 2px solid var(--brand); outline-offset: 1px; border-color: var(--brand); }
.choices { display: flex; gap: 24px; margin-top: 6px; }
.contact-form .choice { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; }
.contact-form .choice input { width: 18px; height: 18px; accent-color: var(--brand); }
.agree { justify-items: center; }
.form-submit { text-align: center; }
.form-submit .btn { min-width: 240px; }

/* フッター */
.site-footer { background: var(--ink); color: rgba(255,255,255,.85); padding: 56px 0 24px; font-size: 14px; }
.footer-inner { display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.footer-company img { width: 110px; background: var(--white); padding: 6px 10px; border-radius: 4px; margin-bottom: 12px; }
.footer-company p { margin: 0; line-height: 1.9; }
.footer-nav { display: grid; grid-template-columns: repeat(2, auto); gap: 6px 40px; align-content: start; }
.footer-nav a { color: rgba(255,255,255,.85); text-decoration: none; }
.footer-nav a:hover { color: var(--white); text-decoration: underline; }
.copyright { text-align: center; margin: 40px 0 0; font-size: 12px; color: rgba(255,255,255,.55); }

/* タブレット */
@media (max-width: 1000px) {
  .header-tel { display: none; }
  .global-nav { gap: 20px; }
}

/* スマホ */
@media (max-width: 767px) {
  :root { --header-h: 60px; }
  body { font-size: 15px; }
  .pc-only { display: none; }
  .logo img { width: 96px; }
  .menu-toggle {
    display: flex; flex-direction: column; justify-content: center; gap: 6px;
    margin-left: auto; width: 44px; height: 44px; padding: 10px;
    background: none; border: 0; cursor: pointer;
  }
  .menu-toggle span:not(.sr-only) { display: block; height: 2px; background: var(--ink); transition: transform .2s, opacity .2s; }
  .menu-open .menu-toggle span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .menu-open .menu-toggle span:nth-child(2) { opacity: 0; }
  .menu-open .menu-toggle span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
  .global-nav {
    position: fixed; left: 0; right: 0; top: var(--header-h);
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--white); border-bottom: 1px solid var(--line);
    padding: 8px 16px 24px; margin: 0;
    transform: translateY(-120%); visibility: hidden; transition: transform .25s, visibility .25s;
  }
  .menu-open .global-nav { transform: none; visibility: visible; }
  .global-nav a { padding: 14px 4px; border-bottom: 1px solid var(--line); font-size: 16px; }
  .global-nav .nav-contact { margin-top: 16px; text-align: center; border-bottom: 0; }

  .hero { min-height: 0; background-size: auto 100%; background-position: 70% bottom; }
  .hero-inner { padding: 56px 16px 72px; }
  .hero-en { font-size: 22px; }
  .hero-title { font-size: 28px; }
  .hero-buttons .btn { flex: 1 1 100%; }

  .section { padding: 64px 0; }
  .section-head { margin-bottom: 36px; }
  .section-title { font-size: 24px; }
  .product-list { grid-template-columns: 1fr; gap: 28px; }
  .product-body { padding: 22px 20px 26px; }
  .product-name { font-size: 20px; }

  .agency-inner { flex-direction: column; align-items: flex-start; }
  .agency-title { font-size: 22px; }
  .agency .btn { width: 100%; }

  .news-list li { flex-direction: column; gap: 2px; }

  .company-table th, .company-table td { display: block; width: 100%; }
  .company-table th { padding: 14px 16px 0; border-bottom: 0; }
  .company-table td { padding: 2px 16px 14px; }

  .contact-lead { margin-top: -12px; }
  .form-row.two { grid-template-columns: 1fr; }

  .footer-inner { flex-direction: column; }
}

/* ===== ここから WordPress 用に追加 ===== */

/* 製品の特長（本文の箇条書き） */
.product-content { font-size: 14.5px; line-height: 1.85; }
.product-content > *:first-child { margin-top: 0; }
.product-content > *:last-child { margin-bottom: 0; }
.product-content ul { margin: 0; padding: 0; list-style: none; }
.product-content li { position: relative; padding-left: 1.3em; margin-bottom: 8px; }
.product-content li::before {
  content: ""; position: absolute; left: 0; top: .72em;
  width: 7px; height: 7px; border-radius: 50%; background: var(--brand);
}
.product-content p { margin: 0 0 8px; }

/* お知らせ */
.news-list a { color: var(--ink); text-decoration: none; }
.news-list a:hover { color: var(--brand-dark); text-decoration: underline; }
.news-more { text-align: right; margin: 20px 0 0; }
.news-empty { text-align: center; color: var(--muted); }

/* 下層ページ */
.page-main { padding: 72px 0 100px; min-height: 50vh; }
.page-header { text-align: center; margin-bottom: 48px; }
.entry-header { margin-bottom: 32px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.entry-date { font-family: var(--font-en); font-size: 18px; color: var(--brand-dark); }
.entry-title { font-size: 26px; line-height: 1.5; margin: 4px 0 0; }
.entry-content { line-height: 2; }
.entry-content h2 { font-size: 21px; margin: 48px 0 16px; padding-left: 12px; border-left: 4px solid var(--brand); line-height: 1.5; }
.entry-content h3 { font-size: 18px; margin: 32px 0 12px; }
.entry-content img { border-radius: 6px; }
.back-link { margin-top: 56px; text-align: center; }
.center { text-align: center; }
.navigation.pagination { margin-top: 40px; text-align: center; }
.navigation.pagination .page-numbers { display: inline-block; padding: 4px 12px; margin: 0 2px; text-decoration: none; color: var(--ink); }
.navigation.pagination .current { background: var(--brand); color: var(--white); border-radius: 4px; }

/* Contact Form 7 */
.contact-form .wpcf7-form-control-wrap { display: block; }
.contact-form .wpcf7-radio, .contact-form .wpcf7-acceptance { display: flex; flex-wrap: wrap; gap: 24px; margin-top: 6px; }
.contact-form .wpcf7-list-item { margin: 0; }
.contact-form .wpcf7-list-item label { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; }
.contact-form .wpcf7-list-item input { width: 18px; height: 18px; accent-color: var(--brand); }
.contact-form .wpcf7-not-valid-tip { font-size: 13px; color: #c0392b; margin-top: 4px; }
.contact-form .wpcf7-response-output { margin: 8px 0 0 !important; padding: 12px 16px !important; border-radius: 6px; font-size: 14px; }
.contact-form .wpcf7-spinner { margin: 0 0 0 8px; vertical-align: middle; }
.contact-form input[type=submit] { border: 0; }
.contact-privacy { text-align: center; font-size: 13px; color: var(--muted); margin-top: 16px; }

/* 管理バー表示中のヘッダー位置 */
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .site-header { top: 0; } }

@media (max-width: 767px) {
  .page-main { padding: 48px 0 72px; }
  .entry-title { font-size: 22px; }
  .admin-bar .global-nav { top: calc(var(--header-h) + 46px); }
}
@media (max-width: 600px) {
  .admin-bar .global-nav { top: var(--header-h); }
}
