/*
Theme Name: Nishida Profile
Theme URI: https://example.com
Author: Nishida Takahiro
Description: 西田岳大の個人事業プロフィールサイト用テーマ。Web制作×生成AI活用支援。エディトリアルで温かみのある一枚もの構成。
Version: 0.1.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 7.4
License: GNU General Public License v2 or later
Text Domain: nishida-profile
*/

/* ============================================================
   Design tokens
   ============================================================ */
:root {
  --bg: #fcfaf6;         /* 基本背景（クリーム） */
  --band: #f7f5ef;       /* 帯背景（サービス/連絡先） */
  --bg-soft: #f7f5ef;
  --ink: #161310;        /* 見出し・ほぼ黒 */
  --body: #524d47;       /* 本文（ウォームグレー） */
  --muted: #9a978f;      /* ラベル・補助 */
  --line: #edebe3;       /* 罫線 */
  --accent: #a75245;     /* クレイ（アクセント） */
  --accent-soft: #e3c8c0;
  --navy: #1c354e;       /* プライマリ（実績背景・ボタン） */
  --navy-deep: #12283e;
  --icon-wrap: #edf2f8;  /* サービスアイコン背景 */
  --nav-dark: #1c354e;   /* ロゴ箱・ボタン（=navy） */

  --serif: "Noto Serif JP", "Shippori Mincho", "Hiragino Mincho ProN", serif;
  --sans: "Noto Sans JP", -apple-system, BlinkMacSystemFont, "Helvetica Neue", "Hiragino Sans", "Yu Gothic", sans-serif;

  --maxw: 1120px;
  --gutter: clamp(20px, 5vw, 64px);
}

/* ============================================================
   Reset / base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--body);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.9;
  font-feature-settings: "palt";
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3 { margin: 0; color: var(--ink); font-weight: 600; line-height: 1.45; }

.container { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(72px, 12vw, 140px); }
.eyebrow {
  font-family: var(--sans);
  font-size: 12px; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--muted); font-weight: 600;
  display: inline-flex; align-items: center; gap: 12px;
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--muted); }
.lead { color: var(--body); max-width: 46em; }
/* 文節単位で折り返す（日本語の中途半端な改行を防ぐ） */
.phrase { display: inline-block; }
.accent { color: var(--accent); }

/* buttons */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 26px; border-radius: 999px;
  font-size: 14px; font-weight: 600; letter-spacing: 0.04em;
  transition: transform .2s ease, background .2s ease, color .2s ease;
}
.btn--primary { background: var(--nav-dark); color: #fff; }
.btn--primary:hover { transform: translateY(-2px); background: #29384c; }
.btn--ghost { border: 1px solid var(--line); color: var(--ink); }
.btn--ghost:hover { border-color: var(--ink); transform: translateY(-2px); }

/* ============================================================
   Header / nav
   ============================================================ */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  background: rgba(251, 250, 248, 0.82);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, background .3s ease;
}
.site-header.is-scrolled { border-color: var(--line); }
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand__mark {
  width: 36px; height: 36px; border-radius: 9px;
  background: var(--nav-dark); color: #fff;
  display: grid; place-items: center;
  font-family: var(--serif); font-size: 18px;
}
.brand__text { display: inline-flex; flex-direction: column; line-height: 1.1; }
.brand__name { font-family: var(--serif); font-size: 16px; color: var(--ink); line-height: 1.15; }
.brand__roman { font-size: 10px; letter-spacing: 0.04em; color: var(--muted); margin-top: 2px; }
.nav__links { display: flex; align-items: center; gap: 30px; }
.nav__links a { font-size: 14px; color: var(--ink); position: relative; }
.nav__links a::after {
  content: ""; position: absolute; left: 0; bottom: -6px; width: 0; height: 1px;
  background: var(--accent); transition: width .25s ease;
}
.nav__links a:hover::after { width: 100%; }
.nav__cta { margin-left: 8px; }
.nav__toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav__toggle span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 5px 0; transition: .3s; }

/* mobile menu panel */
.mobile-menu {
  position: fixed; inset: 72px 0 auto 0; z-index: 49;
  background: var(--bg); border-bottom: 1px solid var(--line);
  transform: translateY(-120%); transition: transform .35s ease;
  padding: 16px var(--gutter) 28px;
}
.mobile-menu.is-open { transform: translateY(0); }
.mobile-menu a { display: block; padding: 14px 0; font-size: 16px; color: var(--ink); border-bottom: 1px solid var(--line); }

/* ============================================================
   Hero
   ============================================================ */
.hero { padding-top: 140px; }
.hero__eyebrow { margin-bottom: 28px; }
.hero h1 {
  font-family: var(--serif);
  font-size: clamp(30px, 5.4vw, 60px);
  letter-spacing: 0.04em; line-height: 1.55; color: var(--ink);
}
.hero p.lead { margin-top: 28px; font-size: clamp(15px, 1.6vw, 18px); }
.hero__actions { margin-top: 40px; display: flex; gap: 16px; flex-wrap: wrap; }

.hero__media { margin-top: 64px; position: relative; }
.media-frame {
  position: relative; border-radius: 18px; overflow: hidden;
  aspect-ratio: 16 / 7; background: linear-gradient(120deg, #efe9e2, #e7ded4 60%, #d9cdbf);
}
.media-frame__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.media-frame__tag {
  position: absolute; left: 20px; top: 18px; font-size: 11px; letter-spacing: 0.2em;
  color: #fff; z-index: 1; text-shadow: 0 1px 8px rgba(0,0,0,.4);
}
.media-badge {
  position: absolute; right: 18px; bottom: 18px; z-index: 1;
  background: rgba(251,250,248,.92); border: 1px solid var(--line);
  border-radius: 14px; padding: 12px 16px; display: flex; align-items: center; gap: 12px;
}
.media-badge__icon { width: 34px; height: 34px; border-radius: 50%; background: var(--icon-wrap); display: grid; place-items: center; color: var(--navy); font-size: 18px; }
.media-badge small { display: block; font-size: 10px; letter-spacing: 0.18em; color: var(--muted); }
.media-badge strong { font-weight: 600; color: var(--ink); font-size: 14px; }

/* stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; margin-top: 56px; }
.stat__num { font-family: var(--serif); font-weight: 600; font-size: clamp(32px, 4.2vw, 48px); color: var(--ink); line-height: 1; letter-spacing: 0.01em; }
.stat__label { font-size: 12px; color: var(--muted); margin-top: 10px; }

/* ============================================================
   Profile
   ============================================================ */
.profile__head { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: end; }
.profile h2 { font-family: var(--serif); font-size: clamp(24px, 3.4vw, 38px); margin-top: 20px; }
.profile__grid { display: grid; grid-template-columns: 320px 1fr; gap: clamp(32px, 5vw, 72px); margin-top: 64px; }
.profile__photo {
  border-radius: 14px; overflow: hidden; aspect-ratio: 1 / 1;
  background: linear-gradient(160deg, #e9e3da, #d8cabd); position: relative;
}
.profile__photo img { width: 100%; height: 100%; object-fit: cover; object-position: center; }
.profile__quote-tag { display: flex; align-items: center; gap: 10px; margin-top: 18px; font-size: 13px; color: var(--body); }
.profile__quote-tag::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.profile__facts { margin-top: 26px; display: grid; grid-template-columns: 1fr 1fr; gap: 18px 24px; }
.fact dt { font-size: 11px; letter-spacing: 0.18em; color: var(--muted); text-transform: uppercase; }
.fact dd { margin: 4px 0 0; color: var(--ink); font-size: 14px; }

/* timeline */
.timeline { position: relative; counter-reset: tl; list-style: none; margin: 0; padding: 0; }
.timeline::before { content: ""; position: absolute; left: 21px; top: 10px; bottom: 10px; width: 1px; background: var(--line); }
.tl-item { position: relative; counter-increment: tl; padding: 0 0 46px 72px; }
.tl-item::before {
  content: counter(tl, decimal-leading-zero);
  position: absolute; left: 0; top: -2px;
  width: 43px; height: 43px; border-radius: 50%;
  background: var(--bg); border: 1px solid var(--line);
  display: grid; place-items: center;
  font-family: var(--serif); font-size: 13px; color: var(--muted); letter-spacing: 0.04em;
}
.tl-item:last-child { padding-bottom: 0; }
.tl-item .tl-tag { font-size: 11px; letter-spacing: 0.16em; color: var(--muted); text-transform: uppercase; }
.tl-item h3 { font-family: var(--serif); font-size: 20px; margin: 8px 0 10px; }
.tl-item p { margin: 0; font-size: 14px; }

/* ============================================================
   Cards (services / why)
   ============================================================ */
.section-head { max-width: 52em; }
.section-head h2 { font-family: var(--serif); font-size: clamp(24px, 3.4vw, 36px); margin: 18px 0 18px; }
.cards { display: grid; gap: 24px; margin-top: 56px; }
.cards--3 { grid-template-columns: repeat(3, 1fr); }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  padding: 34px 30px; transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 18px 40px -28px rgba(32,48,63,.4); border-color: var(--accent-soft); }
.card__no { font-family: var(--serif); color: var(--accent); font-size: 14px; }
.card h3 { font-family: var(--serif); font-size: 21px; margin: 14px 0 14px; }
.card p { font-size: 14px; margin: 0 0 18px; }
.card ul li { display: flex; align-items: flex-start; gap: 9px; font-size: 13.5px; margin-bottom: 9px; color: var(--ink); }
.card ul li i { color: var(--accent); font-size: 15px; line-height: 1.55; flex: none; }

/* card icon wraps（参考サイトのアイコン） */
.svc-icon { display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--icon-wrap); color: var(--navy-deep); font-size: 22px; margin-bottom: 18px; }
.why-icon { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 14px; background: var(--navy); color: #fff; font-size: 26px; margin-bottom: 22px; }

/* contact info icons */
.contact__info dt { display: flex; align-items: center; gap: 8px; }
.contact__info .ci-icon { color: var(--accent); font-size: 15px; }

/* button & link arrows */
.btn i, .work__link i { font-size: 15px; line-height: 1; }

/* ============================================================
   お悩み相談セクション
   ============================================================ */
.worries { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 28px; margin-top: 48px; }
.worry {
  display: flex; gap: 12px; align-items: center;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 18px 22px; transition: border-color .2s ease, transform .2s ease;
}
.worry:hover { border-color: var(--accent-soft); transform: translateY(-2px); }
.worry i { color: var(--accent); font-size: 20px; flex: none; }
.worry p { margin: 0; font-size: 14.5px; color: var(--ink); line-height: 1.7; }
.worries-cta { margin-top: 40px; display: flex; flex-wrap: wrap; align-items: center; gap: 20px; }
.worries-cta p { margin: 0; font-family: var(--serif); font-size: clamp(17px, 2.2vw, 22px); color: var(--ink); }

/* ============================================================
   注目サービス（事業開発・ITコンサル）
   ============================================================ */
.feature-card {
  display: flex; gap: 28px; align-items: flex-start; margin-top: 24px;
  background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--navy);
  border-radius: 16px; padding: clamp(24px, 3vw, 36px);
}
.feature-card__icon {
  width: 56px; height: 56px; border-radius: 14px; background: var(--navy); color: #fff;
  display: grid; place-items: center; font-size: 26px; flex: none;
}
.feature-card__label { font-size: 12px; letter-spacing: 0.14em; color: var(--accent); font-weight: 600; }
.feature-card h3 { font-family: var(--serif); font-size: clamp(19px, 2.4vw, 25px); margin: 8px 0 12px; }
.feature-card p { font-size: 14px; margin: 0 0 18px; }
.feature-card__tags { display: flex; flex-wrap: wrap; gap: 10px; }
.feature-card__tags li { font-size: 12.5px; color: var(--ink); background: var(--band); border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; }

/* ============================================================
   サービス：そのほか頼めること
   ============================================================ */
.more-services { margin-top: 60px; }
.more-services__title { font-family: var(--serif); font-size: clamp(18px, 2.4vw, 24px); color: var(--ink); text-align: center; }
.more-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 30px; }
.more-item { display: flex; gap: 14px; align-items: flex-start; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 20px 22px; transition: border-color .2s ease, transform .2s ease; }
.more-item:hover { border-color: var(--accent-soft); transform: translateY(-2px); }
.more-item > i { color: var(--navy); font-size: 22px; flex: none; margin-top: 2px; }
.more-item strong { display: block; font-size: 15px; color: var(--ink); margin-bottom: 5px; }
.more-item span { display: block; font-size: 12.5px; color: var(--body); line-height: 1.65; }
.more-note { margin-top: 24px; text-align: center; font-size: 13px; color: var(--muted); }

/* ============================================================
   Works
   ============================================================ */
.works-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 56px; }
.work { background: #fff; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; transition: transform .25s ease, box-shadow .25s ease; }
.work:hover { transform: translateY(-4px); box-shadow: 0 18px 40px -28px rgba(32,48,63,.4); }
.work__thumb { aspect-ratio: 4 / 3; background: linear-gradient(150deg, #e7ded4, #d6c8ba); position: relative; display: grid; place-items: center; color: rgba(32,48,63,.35); font-family: var(--serif); overflow: hidden; }
.work__thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.work__body { padding: 22px 24px 26px; }
.work__cat { font-size: 11px; letter-spacing: 0.14em; color: var(--accent); text-transform: uppercase; }
.work h3 { font-family: var(--serif); font-size: 19px; margin: 8px 0 4px; }
.work__sub { font-size: 12px; color: var(--muted); }
.work p { font-size: 13.5px; margin: 12px 0 16px; }
.work__link { font-size: 13px; font-weight: 600; color: var(--ink); display: inline-flex; gap: 8px; align-items: center; }
.work__link:hover { color: var(--accent); }

/* ============================================================
   Contact
   ============================================================ */
/* section background bands（参考サイト準拠） */
.services { background: var(--band); }
.contact { background: var(--band); }

/* works = 濃紺セクション（白文字・明色カード） */
.works { background: var(--navy); }
.works .eyebrow { color: rgba(255,255,255,.62); }
.works .eyebrow::before { background: rgba(255,255,255,.45); }
.works .section-head h2 { color: #fff; }
.works .section-head .lead { color: rgba(255,255,255,.72); }
.contact__grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: clamp(32px, 5vw, 72px); margin-top: 48px; align-items: start; }
.contact__info dl { display: grid; gap: 22px; }
.contact__info dt { font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }
.contact__info dd { margin: 4px 0 0; color: var(--ink); font-size: 15px; }
.contact__info a { color: var(--accent); }
.form { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: clamp(24px, 3vw, 36px); }
.field { margin-bottom: 20px; }
.field label { display: block; font-size: 13px; color: var(--ink); margin-bottom: 8px; }
.field input, .field textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 10px;
  padding: 13px 14px; font-family: inherit; font-size: 14px; color: var(--ink); background: var(--bg);
}
.field input:focus, .field textarea:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
.field textarea { resize: vertical; min-height: 130px; }
.field__count { float: right; font-size: 11px; color: var(--muted); }
.form__note { font-size: 12px; color: var(--muted); margin: 4px 0 16px; }
.form button { width: 100%; justify-content: center; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer { padding: 40px 0; border-top: 1px solid var(--line); text-align: center; color: var(--muted); font-size: 13px; }
.site-footer a { color: var(--accent); }

/* ============================================================
   Reveal animation
   ============================================================ */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s ease, transform .8s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 920px) {
  .nav__links, .nav__cta { display: none; }
  .nav__toggle { display: block; }
  .stats { grid-template-columns: repeat(2, 1fr); gap: 24px 20px; }
  .profile__head { grid-template-columns: 1fr; gap: 16px; }
  .profile__grid { grid-template-columns: 1fr; }
  .cards--3, .works-grid { grid-template-columns: 1fr; }
  .more-grid { grid-template-columns: 1fr; }
  .worries { grid-template-columns: 1fr; }
  .feature-card { flex-direction: column; gap: 18px; }
  .contact__grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .stats { grid-template-columns: 1fr 1fr; }
  .hero { padding-top: 116px; }
}

/* reduce motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
