/* =========================================================
   Haruka Matsuda — Portfolio
   思考が、形になって、届くまで。
   ========================================================= */

:root {
  --bg: #FCFBF8;
  --bg-soft: #F7F3EC;
  --ink: #3A3530;
  --ink-2: #6F675E;
  --ink-3: #A39A8F;
  --line: #E8E1D6;

  --beige: #E9DFCE;
  --beige-deep: #CDBBA0;
  --coral: #E09A8C;
  --coral-soft: #F6E0DA;
  --lav: #B7A6CF;
  --lav-soft: #EAE4F2;
  --blue: #A3BFD8;
  --blue-soft: #E2EBF3;

  --serif: 'Shippori Mincho', 'Hiragino Mincho ProN', serif;
  --sans: 'Zen Kaku Gothic New', 'Hiragino Kaku Gothic ProN', sans-serif;
  --en-font: 'Cormorant Garamond', serif;

  --nav-h: 72px;
  --radius: 18px;
  --shadow-soft: 0 24px 60px -30px rgba(90, 78, 62, 0.25);
  --shadow-card: 0 16px 40px -24px rgba(90, 78, 62, 0.3);
}

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

html { scroll-behavior: auto; }

html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  font-size: 15.5px;
  line-height: 2;
  letter-spacing: 0.04em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input { font-family: inherit; }

.en { font-family: var(--en-font); letter-spacing: 0.08em; }
.pc { display: inline; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}

.container {
  width: min(1120px, calc(100% - 48px));
  margin-inline: auto;
}

.section { padding: clamp(96px, 14vh, 170px) 0; position: relative; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 13px 34px;
  border-radius: 999px;
  font-size: 14px; font-weight: 500; letter-spacing: 0.1em;
  transition: transform 0.35s cubic-bezier(.22,1,.36,1), box-shadow 0.35s, background 0.35s, color 0.35s;
}
.btn-primary {
  background: var(--ink); color: #fff;
  box-shadow: 0 12px 28px -14px rgba(58, 53, 48, 0.55);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 18px 34px -14px rgba(58, 53, 48, 0.5); }
.btn-ghost {
  border: 1px solid var(--line); color: var(--ink-2); background: rgba(255,255,255,0.6);
}
.btn-ghost:hover { border-color: var(--ink-3); color: var(--ink); transform: translateY(-2px); }
.btn-large { padding: 17px 52px; font-size: 15px; }
.btn-nav { padding: 9px 22px; font-size: 13px; }

.text-link {
  color: var(--ink);
  border-bottom: 1px solid var(--coral);
  padding-bottom: 1px;
  transition: color .3s;
}
.text-link:hover { color: var(--coral); }

/* ---------- Section heading ---------- */
.sec-head { margin-bottom: clamp(48px, 7vh, 80px); }
.sec-label {
  font-size: 13px; color: var(--ink-3); letter-spacing: 0.22em;
  margin-bottom: 14px; display: flex; align-items: center; gap: 14px;
}
.sec-label::before {
  content: ""; width: 34px; height: 1px; background: var(--coral); display: inline-block;
}
.sec-label .en { font-size: 16px; font-style: italic; }
.sec-title {
  font-family: var(--serif);
  font-size: clamp(26px, 3.4vw, 38px);
  font-weight: 500; line-height: 1.7; letter-spacing: 0.06em;
}
.sec-lead { margin-top: 18px; color: var(--ink-2); font-size: 14.5px; }

/* =========================================================
   Navigation
   ========================================================= */
.site-nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  transition: background .5s, box-shadow .5s, backdrop-filter .5s;
}
.site-nav.scrolled {
  background: rgba(252, 251, 248, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--line);
}
.nav-inner {
  height: var(--nav-h);
  width: min(1240px, calc(100% - 40px));
  margin-inline: auto;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.nav-logo { display: flex; align-items: center; gap: 10px; }
.nav-logo-mark {
  width: 10px; height: 10px; border-radius: 50%;
  background: linear-gradient(135deg, var(--coral), var(--lav));
}
.nav-logo-text { font-family: var(--en-font); font-size: 19px; letter-spacing: 0.06em; }
.nav-links { display: flex; gap: 30px; }
.nav-links a {
  font-family: var(--en-font); font-size: 15px; letter-spacing: 0.1em; color: var(--ink-2);
  position: relative; padding: 4px 0; transition: color .3s;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 1px;
  background: var(--coral); transform: scaleX(0); transform-origin: right;
  transition: transform .4s cubic-bezier(.22,1,.36,1);
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav-right { display: flex; align-items: center; gap: 14px; }

.nav-burger {
  display: none; width: 40px; height: 40px; position: relative; z-index: 130;
  flex-direction: column; align-items: center; justify-content: center; gap: 7px;
}
.nav-burger span {
  display: block; width: 22px; height: 1.5px; background: var(--ink);
  transition: transform .4s, opacity .4s;
}
.nav-burger.open span:nth-child(1) { transform: translateY(4.25px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { transform: translateY(-4.25px) rotate(-45deg); }

.nav-overlay {
  position: fixed; inset: 0; z-index: 95; /* .site-nav(100)より下: ロゴとバーガーは常に見える */
  background: rgba(252, 251, 248, 0.96);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity .5s;
}
.nav-overlay.open { opacity: 1; pointer-events: auto; }
.overlay-links { display: flex; flex-direction: column; gap: 6px; text-align: center; }
.overlay-links a {
  font-family: var(--serif); font-size: 24px; padding: 10px 30px;
  display: flex; flex-direction: column; gap: 2px;
}
.overlay-links a small {
  font-family: var(--sans); font-size: 11px; color: var(--ink-3); letter-spacing: 0.2em;
}

/* =========================================================
   1. Hero — 起動シーン
   ========================================================= */
.hero { position: relative; }
.hero-stage {
  height: 100vh; height: 100svh;
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background:
    radial-gradient(1200px 700px at 80% -10%, var(--lav-soft) 0%, transparent 55%),
    radial-gradient(1000px 600px at 5% 110%, var(--blue-soft) 0%, transparent 50%),
    var(--bg);
}

.hero-net { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
#netLine { stroke: var(--beige-deep); stroke-width: 1; opacity: 0; }

/* 思考のかけら */
.frag {
  position: absolute;
  left: var(--x); top: var(--y);
  will-change: transform;
  animation: floaty 7s ease-in-out infinite;
}
@keyframes floaty {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -9px; }
}
.frag:nth-child(odd)  { animation-duration: 8.5s; animation-delay: -2s; }
.frag:nth-child(3n)   { animation-duration: 6.5s; animation-delay: -4s; }

.dot { width: 9px; height: 9px; border-radius: 50%; }
.dot-coral { background: var(--coral); }
.dot-lav   { background: var(--lav); }
.dot-blue  { background: var(--blue); }
.dot-beige { background: var(--beige-deep); }

.chip {
  display: inline-flex; align-items: center;
  padding: 7px 18px; border-radius: 999px;
  font-size: 12.5px; letter-spacing: 0.16em;
  background: rgba(255,255,255,0.75);
  border: 1px solid var(--line);
  box-shadow: 0 8px 24px -14px rgba(90,78,62,.35);
  backdrop-filter: blur(4px);
  white-space: nowrap;
}
.chip-lav   { border-color: color-mix(in srgb, var(--lav) 55%, white); color: #7a68a0; }
.chip-blue  { border-color: color-mix(in srgb, var(--blue) 65%, white); color: #5f7f9c; }
.chip-coral { border-color: color-mix(in srgb, var(--coral) 55%, white); color: #bf7060; }
.chip-beige { border-color: var(--beige-deep); color: #9c8867; }

.mini-card {
  width: 92px; padding: 12px 12px 14px;
  background: rgba(255,255,255,0.9);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: var(--shadow-card);
  rotate: var(--r, 0deg);
  display: flex; flex-direction: column; gap: 7px;
}
.mini-card i { height: 4px; border-radius: 2px; background: var(--line); display: block; }
.mini-card i:first-child { background: var(--beige-deep); }

.hero-copy {
  position: relative; z-index: 3;
  text-align: center;
  padding: 0 24px;
}
.hero-eyebrow {
  font-size: 12.5px; letter-spacing: 0.26em; color: var(--ink-3);
  margin-bottom: 26px;
}
.hero-eyebrow .en { font-size: 17px; font-style: italic; letter-spacing: 0.12em; }
.hero-title {
  font-family: var(--serif);
  font-size: clamp(30px, 5.2vw, 58px);
  font-weight: 500; line-height: 1.8; letter-spacing: 0.08em;
}
.hero-title .ch { display: inline-block; will-change: transform, opacity; }
.hero-sub {
  margin-top: 30px;
  font-size: clamp(13.5px, 1.2vw, 15px);
  color: var(--ink-2); line-height: 2.3;
}
.hero-cta { margin-top: 40px; display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.scroll-hint {
  position: absolute; bottom: 34px; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 12px; z-index: 3;
}
.scroll-hint-text { font-size: 11px; letter-spacing: 0.24em; color: var(--ink-3); }
.scroll-hint-line {
  width: 1px; height: 48px; background: var(--line); position: relative; overflow: hidden;
}
.scroll-hint-line::after {
  content: ""; position: absolute; left: 0; top: -50%;
  width: 100%; height: 50%; background: var(--coral);
  animation: hintdrop 2.2s cubic-bezier(.65,0,.35,1) infinite;
}
@keyframes hintdrop {
  0% { top: -50%; } 60%, 100% { top: 110%; }
}

/* =========================================================
   2. Process Words
   ========================================================= */
.pwords { position: relative; }
.pw-stage {
  height: 100vh; height: 100svh;
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.pw-tint { position: absolute; inset: 0; opacity: 0; }
.pw-tint-beige { background: radial-gradient(900px 600px at 50% 50%, #F4EDE0 0%, transparent 70%); }
.pw-tint-lav   { background: radial-gradient(900px 600px at 50% 50%, var(--lav-soft) 0%, transparent 70%); }
.pw-tint-blue  { background: radial-gradient(900px 600px at 50% 50%, var(--blue-soft) 0%, transparent 70%); }
.pw-tint-coral { background: radial-gradient(900px 600px at 50% 50%, var(--coral-soft) 0%, transparent 70%); }

.pw-word {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 26px; text-align: center; padding: 0 24px;
}
.pw-word h2 {
  font-family: var(--serif);
  font-size: clamp(44px, 8vw, 92px);
  font-weight: 500; letter-spacing: 0.12em;
}
.pw-word p { color: var(--ink-2); font-size: clamp(13px, 1.2vw, 15px); letter-spacing: 0.12em; }

.pw-progress {
  position: absolute; bottom: 60px; left: 50%; transform: translateX(-50%);
  width: min(320px, 60%);
}
.pw-bar {
  display: block; height: 1.5px; background: var(--line); overflow: hidden; border-radius: 2px;
}
.pw-bar i {
  display: block; height: 100%; width: 100%;
  background: linear-gradient(90deg, var(--beige-deep), var(--lav), var(--blue), var(--coral));
  transform: scaleX(0); transform-origin: left;
}
.pw-marks {
  display: flex; justify-content: space-between; margin-top: 10px; padding: 0 1px;
}
.pw-marks i { width: 5px; height: 5px; border-radius: 50%; background: var(--line); }

/* =========================================================
   3. About
   ========================================================= */
.about { background: var(--bg); }
.about-grid {
  display: grid; grid-template-columns: 340px 1fr; gap: clamp(48px, 6vw, 96px);
  align-items: start;
}
.about-portrait { position: sticky; top: calc(var(--nav-h) + 40px); }
.portrait-frame {
  aspect-ratio: 3 / 3.6;
  border-radius: var(--radius);
  background: linear-gradient(160deg, #FFFDF9 0%, var(--bg-soft) 100%);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; position: relative;
}
.portrait-abstract { position: relative; width: 60%; aspect-ratio: 1; }
.pa-circle {
  position: absolute; inset: 12% auto auto 8%;
  width: 52%; aspect-ratio: 1; border-radius: 50%;
  background: linear-gradient(140deg, var(--coral-soft), var(--coral));
  opacity: 0.85;
}
.pa-arc {
  position: absolute; inset: auto 4% 8% auto;
  width: 58%; aspect-ratio: 1; border-radius: 50%;
  border: 1.5px solid var(--lav);
  border-left-color: transparent; border-bottom-color: transparent;
  transform: rotate(24deg);
}
.pa-line {
  position: absolute; left: 6%; bottom: 20%;
  width: 70%; height: 1.5px; background: var(--blue);
}
.portrait-caption {
  margin-top: 16px; font-size: 13px; color: var(--ink-3);
  font-style: italic; text-align: center; letter-spacing: 0.1em;
}

.about-body p { margin-bottom: 1.8em; color: var(--ink-2); }
.about-body p:first-child { color: var(--ink); }

.about-views { margin-top: 56px; display: grid; gap: 0; }
.about-views li {
  padding: 30px 4px;
  border-top: 1px solid var(--line);
  display: grid; grid-template-columns: 64px 1fr; grid-template-rows: auto auto;
  column-gap: 20px;
}
.about-views li:last-child { border-bottom: 1px solid var(--line); }
.view-num {
  grid-row: 1 / 3; font-size: 22px; font-style: italic; color: var(--coral);
  padding-top: 4px;
}
.about-views h3 {
  font-family: var(--serif); font-size: 17.5px; font-weight: 500; letter-spacing: 0.06em;
}
.about-views p { margin: 6px 0 0; font-size: 14px; color: var(--ink-2); }

/* =========================================================
   4. Editing — 情報が編集されていく
   ========================================================= */
.editing { background: linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 18%, var(--bg-soft) 82%, var(--bg) 100%); }
.edit-pin {
  height: 100vh; height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  overflow: hidden; padding: calc(var(--nav-h) + 10px) 0 30px;
}
.edit-caption {
  font-family: var(--serif);
  font-size: clamp(20px, 2.6vw, 30px);
  letter-spacing: 0.1em; text-align: center;
}
.edit-caption-b { margin-top: -1.2em; }

.edit-stage {
  position: relative;
  width: min(1060px, calc(100% - 48px));
  margin: 40px auto 0;
  flex: 1; max-height: 620px; min-height: 420px;
}
.edit-cols {
  position: absolute; inset: 0 0 auto 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
}
.edit-col {
  text-align: center; padding: 14px 0 18px;
  border-top: 1px solid var(--ink-3);
}
.edit-col .en { font-size: 15px; font-style: italic; color: var(--ink-3); }
.edit-col h3 {
  font-family: var(--serif); font-size: 17px; font-weight: 500;
  letter-spacing: 0.14em; margin-top: 2px;
}

.note {
  position: absolute; left: 0; top: 0;
  width: 148px; padding: 14px 16px;
  background: #FFFEFB;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 26px -16px rgba(90,78,62,.4);
  font-size: 12.5px; line-height: 1.6; letter-spacing: 0.08em;
  color: var(--ink-2);
  will-change: transform;
}
.note::before {
  content: ""; position: absolute; top: 9px; left: 16px;
  width: 18px; height: 3px; border-radius: 2px;
  background: var(--note-tape, var(--line));
}
.note { padding-top: 22px; }
.note[data-cat="0"] { --note-tape: var(--lav); }
.note[data-cat="1"] { --note-tape: var(--blue); }
.note[data-cat="2"] { --note-tape: var(--coral); }

/* =========================================================
   5. Works
   ========================================================= */
.work-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 48px; }
.chip-btn {
  padding: 9px 20px; border-radius: 999px;
  border: 1px solid var(--line); background: rgba(255,255,255,.7);
  font-size: 12.5px; letter-spacing: 0.1em; color: var(--ink-2);
  transition: all .35s cubic-bezier(.22,1,.36,1);
}
.chip-btn:hover { border-color: var(--ink-3); color: var(--ink); transform: translateY(-1px); }
.chip-btn.is-active { background: var(--ink); border-color: var(--ink); color: #fff; }

.work-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px;
}
.work-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .5s cubic-bezier(.22,1,.36,1), box-shadow .5s;
}
.work-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-soft); }
.work-thumb {
  position: relative; aspect-ratio: 16 / 10.5; overflow: hidden;
}
.work-card:hover .work-thumb > * { transform: translateY(-3px); }
.work-thumb > * { transition: transform .6s cubic-bezier(.22,1,.36,1); }
.work-meta { padding: 22px 24px 26px; }
.work-tag {
  display: inline-block; font-size: 11px; letter-spacing: 0.16em;
  padding: 4px 12px; border-radius: 999px; margin-bottom: 12px;
}
.tag-blue  { background: var(--blue-soft); color: #5f7f9c; }
.tag-lav   { background: var(--lav-soft); color: #7a68a0; }
.tag-coral { background: var(--coral-soft); color: #bf7060; }
.tag-beige { background: #F2EBDD; color: #9c8867; }
.work-meta h3 {
  font-family: var(--serif); font-size: 17px; font-weight: 500;
  letter-spacing: 0.05em; line-height: 1.6;
}
.work-meta p { font-size: 13px; color: var(--ink-2); margin-top: 8px; line-height: 1.9; }

/* --- 実物スクリーンショット --- */
.work-shot { background: var(--beige-soft, #F7F3EC); }
.work-shot img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: top center;
  display: block;
}
.work-card:hover .work-shot img { transform: scale(1.035); }
.work-link { display: block; color: inherit; text-decoration: none; }

/* --- 但し書き（架空デモである等の断り） --- */
.work-note {
  margin-top: 14px; padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 11.5px; letter-spacing: 0.04em;
  color: var(--ink-3);
}
.work-meta p.work-note { line-height: 1.7; }

/* --- CSSサムネイル --- */
.thumb-web { background: linear-gradient(150deg, var(--blue-soft), #F2F6FA); }
.tw-bar { position: absolute; top: 10%; left: 8%; width: 84%; height: 7%; background: #fff; border-radius: 4px; }
.tw-hero { position: absolute; top: 22%; left: 8%; width: 84%; height: 34%; background: linear-gradient(120deg, var(--blue), var(--lav)); opacity: .55; border-radius: 6px; }
.tw-col { position: absolute; top: 62%; height: 26%; width: 26%; background: #fff; border-radius: 6px; }
.tw-col:nth-of-type(3) { left: 8%; } .tw-col:nth-of-type(4) { left: 37%; } .tw-col:nth-of-type(5) { left: 66%; }

.thumb-app { background: linear-gradient(150deg, var(--lav-soft), #F6F3FA); }
.ta-window { position: absolute; inset: 14% 12%; background: #fff; border-radius: 10px; padding: 14% 10%; display: flex; flex-direction: column; gap: 12%; box-shadow: 0 14px 30px -18px rgba(122,104,160,.45); }
.ta-window i { height: 10%; min-height: 5px; border-radius: 3px; background: var(--lav-soft); }
.ta-window i:first-child { width: 55%; background: var(--lav); opacity: .7; }
.ta-fab { position: absolute; right: 16%; bottom: 16%; width: 12%; aspect-ratio: 1; border-radius: 50%; background: var(--lav); opacity: .85; }

.thumb-ux { background: linear-gradient(150deg, var(--coral-soft), #FBF4F1); }
.tu-flow { position: absolute; top: 49%; left: 12%; width: 76%; height: 1.5px; background: var(--coral); opacity: .5; }
.tu-node { position: absolute; top: 42%; width: 11%; aspect-ratio: 1; border-radius: 50%; background: #fff; border: 1.5px solid var(--coral); }
.tu-node.n1 { left: 10%; } .tu-node.n2 { left: 32%; } .tu-node.n3 { left: 54%; } .tu-node.n4 { left: 76%; }
.tu-node.drop { background: var(--coral); border-color: var(--coral); top: 58%; }

.thumb-banner { background: linear-gradient(150deg, #F2EBDD, #FBF8F1); }
.tb-b { position: absolute; border-radius: 6px; background: #fff; box-shadow: 0 10px 24px -16px rgba(156,136,103,.5); }
.tb-b.b1 { top: 16%; left: 10%; width: 46%; height: 30%; background: linear-gradient(120deg, var(--beige), #fff); }
.tb-b.b2 { top: 26%; left: 62%; width: 26%; height: 52%; background: linear-gradient(160deg, #fff, var(--beige)); }
.tb-b.b3 { top: 56%; left: 14%; width: 38%; height: 26%; }

.thumb-flyer { background: linear-gradient(150deg, var(--blue-soft), #F4F8FB); }
.tf-paper { position: absolute; inset: 12% 26%; background: #fff; border-radius: 4px; box-shadow: 0 16px 30px -18px rgba(95,127,156,.5); padding: 10% 12%; display: flex; flex-direction: column; gap: 9%; transform: rotate(-2deg); }
.tf-paper i { height: 7%; min-height: 4px; border-radius: 2px; background: var(--blue-soft); }
.tf-paper i:first-child { height: 22%; background: linear-gradient(120deg, var(--blue), var(--lav)); opacity: .5; }

.thumb-movie { background: linear-gradient(150deg, var(--lav-soft), #F2F0F7); }
.tm-screen { position: absolute; inset: 16% 14% 30%; background: linear-gradient(130deg, #4d4560, #6d6284); border-radius: 8px; display: flex; align-items: center; justify-content: center; }
.tm-play { width: 0; height: 0; border-left: 14px solid rgba(255,255,255,.9); border-top: 9px solid transparent; border-bottom: 9px solid transparent; margin-left: 4px; }
.tm-seek { position: absolute; left: 14%; right: 14%; bottom: 20%; height: 3px; border-radius: 2px; background: #fff; overflow: hidden; }
.tm-seek::after { content: ""; position: absolute; inset: 0 62% 0 0; background: var(--lav); }

.thumb-sns { background: linear-gradient(150deg, var(--coral-soft), #FBF2EF); }
.ts-post { position: absolute; width: 34%; aspect-ratio: 1; border-radius: 10px; background: #fff; box-shadow: 0 12px 26px -16px rgba(191,112,96,.4); }
.ts-post.p1 { top: 14%; left: 12%; background: linear-gradient(140deg, #fff 55%, var(--coral-soft)); }
.ts-post.p2 { top: 30%; left: 36%; background: linear-gradient(140deg, #fff 40%, var(--lav-soft)); }
.ts-post.p3 { top: 46%; left: 60%; background: linear-gradient(140deg, #fff 45%, var(--blue-soft)); }

/* =========================================================
   6. Viewpoint
   ========================================================= */
.viewpoint { background: var(--bg); }
.vp-pin {
  height: 100vh; height: 100svh;
  display: flex; align-items: center; overflow: hidden;
  padding-top: var(--nav-h);
}
.vp-layout {
  display: grid; grid-template-columns: minmax(300px, 420px) 1fr;
  gap: clamp(40px, 6vw, 90px); align-items: center;
}
.vp-title { margin-bottom: 40px; }
.vp-steps { position: relative; min-height: 170px; }
.vp-step { position: absolute; inset: 0 0 auto 0; }
.vp-step-num { font-size: 15px; font-style: italic; color: var(--coral); letter-spacing: 0.14em; }
.vp-step h3 {
  font-family: var(--serif); font-size: 21px; font-weight: 500;
  margin: 10px 0 8px; letter-spacing: 0.08em;
}
.vp-step p { font-size: 14px; color: var(--ink-2); }
.vp-counter { margin-top: 30px; font-size: 15px; color: var(--ink-3); font-style: italic; letter-spacing: 0.2em; }
.vp-counter #vpNow { color: var(--ink); }

.vp-frame {
  aspect-ratio: 16 / 11;
  border-radius: var(--radius);
  background:
    radial-gradient(600px 400px at 70% 20%, var(--lav-soft) 0%, transparent 60%),
    var(--bg-soft);
  border: 1px solid var(--line);
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.vp-canvas {
  width: 74%; aspect-ratio: 16 / 11.5;
  background: #fff; border-radius: 10px;
  box-shadow: 0 30px 70px -35px rgba(90,78,62,.45);
  position: relative; overflow: hidden;
  will-change: transform, filter;
}
.vm-chrome {
  height: 7%; border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 5px; padding: 0 4%;
}
.vm-chrome i { width: 6px; height: 6px; border-radius: 50%; background: var(--line); }
.vm-hero {
  height: 30%; margin: 3% 4% 0;
  background: linear-gradient(120deg, var(--blue-soft), var(--lav-soft));
  border-radius: 6px;
  display: flex; flex-direction: column; justify-content: center; gap: 7%;
  padding: 0 6%;
}
.vm-title { width: 42%; height: 11%; border-radius: 3px; background: var(--ink-3); opacity: .7; }
.vm-line { height: 6%; min-height: 3px; border-radius: 2px; background: #fff; display: block; }
.vm-line.w60 { width: 60%; } .vm-line.w40 { width: 40%; }
.vm-line.w80 { width: 80%; } .vm-line.w70 { width: 70%; } .vm-line.w50 { width: 50%; }
.vm-btn { width: 18%; height: 12%; border-radius: 99px; background: var(--coral); opacity: .8; }
.vm-cards { height: 22%; margin: 3% 4% 0; display: flex; gap: 3%; }
.vm-cards i { flex: 1; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 6px; }
.vm-text {
  height: 14%; margin: 3% 4% 0;
  display: flex; flex-direction: column; gap: 9%;
}
.vm-text .vm-line { background: var(--line); }
.vm-footer { height: 9%; margin-top: 3%; background: var(--bg-soft); border-top: 1px solid var(--line); }

.vp-wire { position: absolute; inset: 0; background: rgba(252,251,248,.6); }
.vp-wire span {
  position: absolute; border: 1px dashed var(--lav);
  border-radius: 4px; background: rgba(183,166,207,.06);
}

/* =========================================================
   7. Gate — Restricted Archive
   ========================================================= */
.gate {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, var(--bg) 0%, #F4F0EA 50%, var(--bg) 100%);
  padding: clamp(110px, 16vh, 190px) 0;
}
.gate-bg {
  position: absolute; inset: 8% 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px;
  width: min(1120px, 92%); margin-inline: auto; left: 0; right: 0;
  filter: blur(7px); opacity: .5; pointer-events: none;
}
.gate-ghost {
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 26px 24px; display: flex; flex-direction: column; gap: 12px;
  min-height: 150px;
}
.gate-ghost .en { font-size: 15px; font-style: italic; color: var(--ink-3); }
.gate-ghost i { height: 6px; border-radius: 3px; background: var(--bg-soft); display: block; }
.gate-ghost i:first-of-type { width: 70%; background: var(--lav-soft); }
.gate-ghost i:last-of-type { width: 45%; }

.gate-center { position: relative; z-index: 2; display: flex; justify-content: center; }
.gate-panel {
  width: min(560px, 100%);
  text-align: center;
  padding: clamp(40px, 6vw, 64px) clamp(28px, 5vw, 60px);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(255,255,255,0.9);
  box-shadow: 0 40px 90px -45px rgba(90,78,62,.5);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  background-image:
    linear-gradient(rgba(255,255,255,0) 0%, rgba(255,255,255,0) 100%),
    repeating-linear-gradient(0deg, transparent 0 27px, rgba(163,154,143,.08) 27px 28px),
    repeating-linear-gradient(90deg, transparent 0 27px, rgba(163,154,143,.08) 27px 28px);
}
.gate-label {
  font-size: 15px; font-style: italic; letter-spacing: 0.3em;
  color: var(--ink-3); margin-bottom: 22px;
}
.gate-lock { display: inline-block; width: 34px; color: var(--ink-2); margin-bottom: 18px; }
.gate-lock svg { width: 100%; }
.gate-title {
  font-family: var(--serif); font-size: clamp(20px, 2.4vw, 26px);
  font-weight: 500; letter-spacing: 0.08em; margin-bottom: 16px;
}
.gate-desc { font-size: 13.5px; color: var(--ink-2); margin-bottom: 34px; line-height: 2.1; }
.gate-actions { display: flex; justify-content: center; }
/* .gate-form は旧パスワード欄の名残。2026-07-29に欄そのものを廃止したが、
   将来サーバー側認証を入れるときに同じ見た目で戻せるよう残してある */
.gate-form {
  display: flex; gap: 10px; justify-content: center; flex-wrap: wrap;
}
.gate-form input {
  flex: 1; min-width: 200px; max-width: 280px;
  padding: 13px 22px;
  border: 1px solid var(--line); border-radius: 999px;
  background: rgba(255,255,255,.85);
  font-size: 14px; letter-spacing: 0.12em; color: var(--ink);
  outline: none; transition: border-color .3s, box-shadow .3s;
}
.gate-form input:focus {
  border-color: var(--lav);
  box-shadow: 0 0 0 4px rgba(183,166,207,.18);
}
.gate-error { min-height: 1.6em; margin-top: 14px; font-size: 12.5px; color: #C56A5A; letter-spacing: 0.08em; }
.gate-note { margin-top: 26px; font-size: 12.5px; font-style: italic; color: var(--ink-3); letter-spacing: 0.12em; }

.gate-panel.shake { animation: gateshake .5s; }
@keyframes gateshake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-9px); } 40% { transform: translateX(8px); }
  60% { transform: translateX(-5px); } 80% { transform: translateX(3px); }
}
.gate-panel.unlocked .lock-shackle { transform: translateY(-3px) rotate(-14deg); transform-origin: 8px 10px; }
.lock-shackle { transition: transform .6s cubic-bezier(.22,1,.36,1); }

/* =========================================================
   8. Service
   ========================================================= */
.service { background: var(--bg); }
.service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.service-card {
  position: relative;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 40px 34px 38px;
  overflow: hidden;
  transition: transform .5s cubic-bezier(.22,1,.36,1), box-shadow .5s;
}
.service-card::before {
  content: ""; position: absolute; inset: 0 auto 0 0; width: 3px;
}
.sc-lav::before   { background: var(--lav); }
.sc-blue::before  { background: var(--blue); }
.sc-coral::before { background: var(--coral); }
.service-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-soft); }
.sc-num { font-size: 26px; font-style: italic; color: var(--ink-3); }
.service-card h3 {
  font-family: var(--serif); font-size: 19px; font-weight: 500;
  margin: 14px 0 14px; letter-spacing: 0.08em;
}
.service-card > p { font-size: 13.5px; color: var(--ink-2); margin-bottom: 22px; }
.service-card ul { display: grid; gap: 10px; }
.service-card li {
  font-size: 13px; color: var(--ink-2);
  padding-left: 18px; position: relative;
}
.service-card li::before {
  content: ""; position: absolute; left: 0; top: 0.9em;
  width: 7px; height: 1.5px; background: var(--ink-3);
}

/* =========================================================
   9. Career
   ========================================================= */
.career { background: var(--bg-soft); }
.career-grid {
  display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(48px, 6vw, 100px);
  align-items: start;
}
.timeline { position: relative; padding-left: 34px; }
.timeline::before {
  content: ""; position: absolute; left: 5px; top: 8px; bottom: 8px;
  width: 1px; background: var(--line);
}
.timeline li { position: relative; padding-bottom: 44px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: ""; position: absolute; left: -33px; top: 9px;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--bg-soft); border: 2px solid var(--coral);
}
.tl-year { font-size: 17px; font-style: italic; color: var(--coral); letter-spacing: 0.12em; }
.timeline h3 {
  font-family: var(--serif); font-size: 18px; font-weight: 500;
  margin: 6px 0 8px; letter-spacing: 0.06em;
}
.timeline p { font-size: 13.5px; color: var(--ink-2); }

.quals {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 38px 36px;
  position: sticky; top: calc(var(--nav-h) + 40px);
}
.quals-title {
  font-family: var(--serif); font-size: 16px; font-weight: 500;
  letter-spacing: 0.12em; margin-bottom: 18px;
}
.quals-title:not(:first-child) { margin-top: 34px; }
.qual-chips { display: flex; flex-wrap: wrap; gap: 9px; }
.qual-chips li {
  font-size: 12.5px; letter-spacing: 0.08em;
  padding: 8px 16px; border-radius: 999px;
  background: var(--lav-soft); color: #6d5c92;
}
.qual-chips.soft li { background: var(--bg-soft); color: var(--ink-2); }

/* =========================================================
   10. Philosophy — 静かなセクション
   ========================================================= */
.philosophy {
  background: var(--bg);
  padding: clamp(140px, 22vh, 260px) 0;
}
.philosophy-inner {
  max-width: 640px; text-align: center;
  display: flex; flex-direction: column; align-items: center;
}
.philosophy .sec-label { justify-content: center; }
.philosophy .sec-label::before { display: none; }
.phi-title {
  font-family: var(--serif); font-size: clamp(24px, 3vw, 34px);
  font-weight: 500; letter-spacing: 0.1em; line-height: 2;
  margin: 26px 0 54px;
}
.phi-body p {
  font-size: clamp(14px, 1.3vw, 15.5px);
  color: var(--ink-2); line-height: 2.6; letter-spacing: 0.08em;
  margin-bottom: 2.4em;
}
.phi-mark {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--coral); margin-top: 10px;
}

/* =========================================================
   11. Convergence
   ========================================================= */
.converge { background: var(--bg); }
.cv-pin {
  height: 100vh; height: 100svh;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.cv-stage {
  position: relative; width: min(900px, 94%); height: min(640px, 86vh);
}
.cv-item { position: absolute; left: 0; top: 0; will-change: transform; }
.cv-chip {
  display: inline-flex; padding: 8px 20px; border-radius: 999px;
  font-size: 12.5px; letter-spacing: 0.14em; white-space: nowrap;
  background: rgba(255,255,255,.8); border: 1px solid var(--line);
  box-shadow: 0 8px 24px -14px rgba(90,78,62,.35);
}
.cv-dot { width: 9px; height: 9px; border-radius: 50%; }
.cv-ring {
  position: absolute; left: 50%; top: 50%;
  width: 0; height: 0; border-radius: 50%;
  border: 1px solid var(--line);
  transform: translate(-50%, -50%);
  opacity: 0;
}
.cv-copy {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 8px; text-align: center; padding: 0 24px;
}
.cv-line {
  font-family: var(--serif);
  font-size: clamp(20px, 2.8vw, 30px);
  letter-spacing: 0.1em; line-height: 2;
  position: absolute;
}
.cv-line em {
  font-style: normal;
  background: linear-gradient(transparent 68%, var(--coral-soft) 68%);
  padding: 0 2px;
}
.cv-cta { position: absolute; bottom: 26%; }

/* =========================================================
   12. Contact / Footer
   ========================================================= */
.contact {
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 100%);
  text-align: center;
}
.contact-inner { display: flex; flex-direction: column; align-items: center; }
.contact .sec-label { justify-content: center; }
.contact .sec-label::before { display: none; }
.contact .sec-title { margin: 20px 0 26px; }
.contact-lead { color: var(--ink-2); font-size: 14.5px; margin-bottom: 46px; }
.contact-actions { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.contact-note { font-size: 12.5px; color: var(--ink-3); letter-spacing: 0.1em; line-height: 2.1; }
.contact-mail {
  color: var(--ink-2);
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: color .3s, border-color .3s;
}
.contact-mail:hover { color: var(--ink); border-color: var(--beige-deep); }
.contact-sns { display: flex; gap: 30px; margin-top: 60px; }
.contact-sns a {
  font-size: 15px; font-style: italic; color: var(--ink-2); letter-spacing: 0.12em;
  border-bottom: 1px solid transparent; transition: color .3s, border-color .3s;
}
.contact-sns a:hover { color: var(--ink); border-color: var(--coral); }

.site-footer {
  background: var(--bg-soft);
  text-align: center; padding: 30px 20px 40px;
  border-top: 1px solid var(--line);
}
.site-footer p { font-size: 13px; font-style: italic; color: var(--ink-3); letter-spacing: 0.14em; }

/* =========================================================
   Private page (Archive)
   ========================================================= */
.private-body { background: var(--bg); }
.private-header {
  padding: calc(var(--nav-h) + clamp(60px, 10vh, 110px)) 0 clamp(50px, 8vh, 90px);
  text-align: center;
  background:
    radial-gradient(900px 500px at 85% -20%, var(--lav-soft) 0%, transparent 55%),
    radial-gradient(800px 500px at 10% 120%, var(--blue-soft) 0%, transparent 50%),
    var(--bg);
}
.private-label { font-size: 16px; font-style: italic; letter-spacing: 0.3em; color: var(--ink-3); }
.private-title {
  font-family: var(--serif); font-size: clamp(26px, 3.6vw, 40px);
  font-weight: 500; letter-spacing: 0.08em; margin: 18px 0 20px;
}
.private-lead { font-size: 14px; color: var(--ink-2); }

.case { padding: clamp(70px, 10vh, 120px) 0; border-top: 1px solid var(--line); }
.case-grid {
  display: grid; grid-template-columns: 280px 1fr; gap: clamp(40px, 5vw, 80px);
  align-items: start;
}
.case-side { position: sticky; top: calc(var(--nav-h) + 30px); }
.case-num { font-size: 30px; font-style: italic; color: var(--coral); letter-spacing: 0.1em; }
.case-side h2 {
  font-family: var(--serif); font-size: 22px; font-weight: 500;
  line-height: 1.8; letter-spacing: 0.06em; margin: 12px 0 18px;
}
.case-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.case-blocks { display: grid; gap: 0; }
.case-block {
  display: grid; grid-template-columns: 150px 1fr; gap: 24px;
  padding: 26px 0; border-top: 1px solid var(--line);
}
.case-block:first-child { border-top: none; padding-top: 0; }
.case-block h3 {
  font-size: 13px; letter-spacing: 0.14em; color: var(--ink-3);
  font-weight: 500; padding-top: 4px;
}
.case-block h3 .en { display: block; font-size: 16px; font-style: italic; color: var(--ink); margin-bottom: 2px; }
.case-block p, .case-block li { font-size: 14px; color: var(--ink-2); line-height: 2.1; }
.case-block ol { list-style: none; counter-reset: proc; display: grid; gap: 8px; }
.case-block ol li { counter-increment: proc; padding-left: 34px; position: relative; }
.case-block ol li::before {
  content: "0" counter(proc);
  position: absolute; left: 0; top: 0;
  font-family: var(--en-font); font-style: italic; font-size: 15px; color: var(--coral);
}
.private-back { text-align: center; padding: 60px 0 100px; }

/* private gate overlay */
.pv-guard {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  background: rgba(252,251,248,.9);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  padding: 24px;
}
.pv-guard[hidden] { display: none; }

/* =========================================================
   Reduced motion
   ========================================================= */
@media (prefers-reduced-motion: reduce) {
  .frag, .scroll-hint-line::after { animation: none !important; }
  html.reduced .hero-stage { height: auto; min-height: 80vh; padding: 140px 0 80px; }
  html.reduced .frag, html.reduced .hero-net { display: none; }
  html.reduced .pw-stage { height: auto; padding: 100px 0; gap: 60px; display: grid; }
  html.reduced .pw-word { position: static; }
  html.reduced .pw-progress, html.reduced .pw-tint { display: none; }
  html.reduced .edit-pin, html.reduced .vp-pin, html.reduced .cv-pin { height: auto; padding: 100px 0; }
  html.reduced .edit-stage { display: none; }
  html.reduced .edit-caption-b { margin-top: 0; }
  html.reduced .vp-steps .vp-step { position: static; margin-bottom: 30px; }
  html.reduced .cv-stage .cv-item { display: none; }
  html.reduced .cv-line, html.reduced .cv-cta { position: static; }
}

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 1023px) {
  .work-grid { grid-template-columns: repeat(2, 1fr); }
  .service-grid { grid-template-columns: 1fr; max-width: 560px; margin-inline: auto; }
  .career-grid { grid-template-columns: 1fr; }
  .quals { position: static; }
  .vp-layout { grid-template-columns: 1fr; gap: 30px; align-content: center; }
  .vp-title br { display: none; }
  .vp-title { margin-bottom: 20px; }
  .vp-steps { min-height: 150px; }
  .vp-frame { max-width: 560px; }
  .about-grid { grid-template-columns: 1fr; }
  .about-portrait { position: static; max-width: 320px; }
}

@media (max-width: 767px) {
  body { font-size: 14.5px; }
  .nav-links { display: none; }
  .nav-burger { display: flex; }
  .btn-nav { display: none; }
  .pc { display: none; }

  .hero-sub br { display: none; }
  .mini-card { width: 74px; }
  .chip { padding: 6px 14px; font-size: 11.5px; }
  /* 狭い画面ではコピーとかけらが重なるので、カードは出さない（基準1優先） */
  .hero-stage .mini-card { display: none; }

  .work-grid { grid-template-columns: 1fr; }
  .work-chips { gap: 8px; }
  .chip-btn { padding: 8px 15px; font-size: 12px; }

  .note { width: 104px; padding: 18px 10px 10px; font-size: 10.5px; }
  .edit-stage { min-height: 380px; }
  .edit-col h3 { font-size: 13px; letter-spacing: 0.08em; }
  .edit-col .en { font-size: 13px; }

  .gate-bg { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .gate-form input { min-width: 0; width: 100%; max-width: none; }
  .gate-form { flex-direction: column; align-items: stretch; }

  .case-grid { grid-template-columns: 1fr; }
  .case-side { position: static; }
  .case-block { grid-template-columns: 1fr; gap: 8px; padding: 22px 0; }

  .cv-chip { padding: 6px 14px; font-size: 11px; }
  .cv-cta { bottom: 18%; }

  .timeline { padding-left: 28px; }
  .timeline li::before { left: -27px; }
}
