/* ONEBON Makoto Sato photographs — onebon.photo（STUDIO移設・現行踏襲） */

* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { background: #fff; color: #333; font-family: 'Noto Sans JP', sans-serif; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }

/* ---- HERO ---- */
.hero { position: relative; height: 100vh; background: #3b3b3b; overflow: hidden; }
.hero-img {
  width: 100%; height: 100%; object-fit: cover;
  filter: brightness(0.8);
  animation: hero-in 2s ease .2s backwards;
}
@keyframes hero-in {
  from { opacity: .5; transform: scale(1.08); }
  to   { opacity: 1;  transform: none; }
}
.hero-mark {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; color: #fff;
  animation: fade-in 1.6s ease .7s backwards;
}
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
.hero-logo { width: 320px; height: auto; }
.hero-name {
  font-family: 'Cormorant Garamond', serif; font-weight: 500;
  font-size: 28px; letter-spacing: .2em; text-indent: .2em; line-height: 1.4;
  margin-top: 14px;
}
.hero-ph {
  font-family: 'Cormorant Garamond', serif; font-style: italic; font-weight: 400;
  font-size: 20px; letter-spacing: .1em; line-height: 1.4;
}

/* ---- PROFILE ---- */
.profile {
  display: flex; flex-direction: row-reverse; justify-content: center;
  gap: 60px; background: #fff; padding: 80px 100px 40px;
}
.profile-jp { display: flex; flex-direction: row; }
.bio-jp {
  writing-mode: vertical-rl; text-orientation: upright;
  font-family: 'Noto Serif JP', serif; font-weight: 300;
  font-size: 14px; line-height: 2; height: 340px; padding-top: 30px;
}
.name-jp {
  writing-mode: vertical-rl; text-orientation: upright;
  font-family: 'Noto Serif JP', serif; font-weight: 400;
  font-size: 20px; letter-spacing: .1em; line-height: 1.4;
  margin-left: 30px;
}
.profile-en { max-width: 460px; }
.name-en {
  font-family: 'Cormorant Garamond', serif; font-weight: 500;
  font-size: 20px; letter-spacing: .05em; line-height: 1.4;
}
.bio-en {
  font-family: 'Cormorant Garamond', serif; font-weight: 500;
  font-size: 14px; letter-spacing: .05em; line-height: 2; margin-top: 30px;
}

/* ---- CONTACT LINKS（ボタン主導） ---- */
.contact-links { padding: 44px 20px 24px; text-align: center; }
.cta-btn {
  font-family: 'Noto Serif JP', serif; font-size: 15px;
  letter-spacing: .2em; text-indent: .2em;
  color: #fff; background: #333; border: 1px solid #333;
  padding: 16px 64px; cursor: pointer; transition: .18s;
}
.cta-btn:hover { background: #fff; color: #333; }
.sub-links {
  margin-top: 22px;
  font-family: 'Lato', 'Avenir Next', sans-serif; font-weight: 400;
  font-size: 13px; letter-spacing: .06em; color: #888;
}
.sub-links a {
  color: #888; text-decoration: none; transition: .15s;
  display: inline-flex; align-items: center; gap: 7px;
}
.sub-icon { width: 16px; height: 16px; flex: none; }
.sub-links a:hover { color: #333; text-decoration: underline; text-underline-offset: 3px; }
.sub-links .sep { margin: 0 10px; color: #bbb; }

/* ---- SCROLL CUE ---- */
.scroll-cue {
  position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  text-decoration: none;
  opacity: 1; transition: opacity .4s;
  animation: fade-in 1.6s ease 1.4s backwards;
}
.scroll-cue.is-away { opacity: 0; pointer-events: none; }
.cue-word {
  font-family: 'Cormorant Garamond', serif; font-style: italic;
  font-size: 13px; letter-spacing: .18em; color: rgba(255, 255, 255, .85);
}
.cue-line {
  position: relative; width: 1px; height: 44px;
  background: rgba(255, 255, 255, .28); overflow: hidden;
}
.cue-line::after {
  content: ''; position: absolute; left: 0; top: -12px;
  width: 1px; height: 12px; background: #fff;
  animation: cue-fall 1.7s ease-in-out infinite;
}
@keyframes cue-fall { to { transform: translateY(56px); } }

/* ---- 拡大ビューア ---- */
.gallery img { cursor: zoom-in; }
.viewer {
  border: 0; padding: 0; background: transparent; margin: auto;
  max-width: none; max-height: none; width: 100vw; height: 100vh;
  display: none; align-items: center; justify-content: center;
}
.viewer[open] { display: flex; }
.viewer::backdrop { background: rgba(12, 12, 12, .94); }
.viewer-img {
  max-width: min(92vw, 1600px); max-height: 86vh;
  width: auto; height: auto;
  opacity: 0; transform: scale(.985); transition: opacity .3s ease, transform .3s ease;
}
.viewer-img.is-in { opacity: 1; transform: none; }
.viewer button {
  position: absolute; border: 0; background: none; cursor: pointer;
  color: rgba(255, 255, 255, .7); transition: color .15s; padding: 12px;
}
.viewer button:hover { color: #fff; }
.viewer button:focus { outline: none; }
.viewer button:focus-visible { outline: 1px solid #fff; }
.viewer-close { top: 10px; right: 14px; font-size: 32px; font-weight: 300; line-height: 1; }
.viewer-prev, .viewer-next {
  top: 50%; transform: translateY(-50%);
  font-family: 'Cormorant Garamond', serif; font-size: 46px; line-height: 1;
}
.viewer-prev { left: 14px; }
.viewer-next { right: 14px; }
.viewer-count {
  position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%);
  font-family: 'Cormorant Garamond', serif; font-size: 14px; letter-spacing: .15em;
  color: rgba(255, 255, 255, .75);
}

/* ---- GALLERY ---- */
.gallery { display: flex; padding: 40px 30px; background: #fff; }
.gallery .col { width: 33.333%; display: flex; flex-direction: column; }
.gallery img { width: calc(100% - 20px); margin: 10px; }

/* ---- CONTACT FORM（モーダル） ---- */
.contact {
  width: min(560px, calc(100vw - 32px));
  max-height: calc(100vh - 60px); overflow-y: auto;
  border: 0; padding: 48px 40px 56px; background: #fff; color: #333;
  margin: auto; position: relative;
}
.contact::backdrop { background: rgba(20, 20, 20, .55); }
.contact-close {
  position: absolute; top: 8px; right: 10px;
  border: 0; background: none; cursor: pointer;
  font-size: 30px; font-weight: 300; line-height: 1; color: #999; padding: 8px;
}
.contact-close:hover { color: #333; }
.contact-close:focus { outline: none; }
.contact-close:focus-visible { outline: 1px solid #333; }
.contact-title {
  font-family: 'Cormorant Garamond', serif; font-weight: 500;
  font-size: 26px; letter-spacing: .25em; text-indent: .25em;
  text-align: center; color: #333;
}
.contact-lead {
  font-family: 'Noto Serif JP', serif; font-weight: 300;
  font-size: 14px; line-height: 2; text-align: center; margin-top: 18px;
}
.form-note { font-size: 14px; line-height: 2; text-align: center; margin-top: 24px; }
.form-note-err { color: #970000; }
.contact-form { margin-top: 36px; }
.contact-form > p { margin-bottom: 26px; }
.contact-form label {
  display: block; font-family: 'Noto Serif JP', serif; font-weight: 400;
  font-size: 13px; letter-spacing: .1em; margin-bottom: 8px;
}
.contact-form label .en {
  font-family: 'Cormorant Garamond', serif; font-size: 12px; letter-spacing: .15em; color: #888;
  margin-left: 6px;
}
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
  width: 100%; border: 0; border-bottom: 1px solid #999; border-radius: 0;
  background: transparent; padding: 6px 2px 8px;
  font-family: 'Noto Sans JP', sans-serif; font-size: 16px; line-height: 1.6; color: #333;
}
.contact-form textarea { border: 1px solid #999; padding: 10px; resize: vertical; }
.contact-form input:focus, .contact-form textarea:focus {
  outline: none; border-color: #333; border-bottom-width: 2px;
}
.contact-form textarea:focus { border-width: 1px; outline: 1px solid #333; }
.form-submit { text-align: center; margin-top: 34px; }
.form-submit button {
  font-family: 'Noto Serif JP', serif; font-size: 15px; letter-spacing: .2em; text-indent: .2em;
  color: #fff; background: #333; border: 1px solid #333;
  padding: 14px 64px; cursor: pointer; transition: .18s;
}
.form-submit button:hover { background: #fff; color: #333; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---- FOOTER ---- */
footer { background: #666; color: #fff; }
.foot-inner {
  max-width: 1080px; margin: 0 auto;
  display: flex; flex-direction: row;
}
.foot-left { width: 50%; padding: 40px; }
.foot-logo { width: 160px; height: auto; margin-bottom: 12px; }
.foot-addr { font-weight: 300; font-size: 14px; line-height: 1.7; margin: 5px 0; }
.foot-icons { display: flex; align-items: center; margin-top: 10px; }
.foot-icons a { display: inline-flex; padding: 10px; }
.foot-icons a:first-child { margin-left: -10px; }
.foot-icons .icon { width: 26px; height: 26px; }
.foot-nav { width: 50%; padding: 40px; display: flex; flex-direction: column; align-items: flex-start; }
.foot-nav a {
  font-family: 'Lato', 'Roboto', sans-serif; font-weight: 300;
  font-size: 18px; line-height: 1.4; text-decoration: none; margin: 5px;
}
.foot-nav a:hover { text-decoration: underline; }
.copyright {
  font-weight: 300; font-size: 13px; text-align: center; padding: 16px 0 20px;
}

/* ---- TABLET ---- */
@media (max-width: 820px) {
  .profile { flex-direction: column; align-items: center; gap: 40px; padding: 60px 30px 30px; }
  .gallery { flex-wrap: wrap; padding: 20px 10px; }
  .gallery .col { width: 50%; }
  .gallery .col:last-child { width: 100%; flex-direction: row; flex-wrap: wrap; }
  .gallery .col:last-child img { width: calc(50% - 20px); align-self: flex-start; }
}

/* ---- MOBILE ---- */
@media (max-width: 480px) {
  .hero-logo { width: 230px; }
  .hero-name { font-size: 22px; }
  .hero-ph { font-size: 17px; }
  .profile { padding: 50px 24px 20px; }
  /* 縦書きは高さを増やして段数を減らし、左右に呼吸を残す */
  .bio-jp { height: 420px; font-size: 13px; padding-top: 0; }
  .name-jp { font-size: 16px; margin-left: 22px; }
  .cta-btn { font-size: 14px; padding: 14px 44px; }
  .sub-links { font-size: 12px; }
  .sub-links .sep { display: block; height: 6px; overflow: hidden; color: transparent; }
  .viewer-img { max-width: 96vw; }
  .viewer-prev { left: 2px; }
  .viewer-next { right: 2px; }
  .viewer-prev, .viewer-next { font-size: 38px; }
  .gallery .col, .gallery .col:last-child img { width: 100%; }
  .gallery .col:last-child { flex-direction: column; }
  .foot-inner { flex-direction: column; }
  .foot-left, .foot-nav { width: 100%; padding: 30px 30px 0; }
  .foot-nav { padding-bottom: 20px; }
}

/* ---- 404 ---- */
.notfound {
  min-height: 100vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center;
  padding: 40px 24px; animation: fade-in 1s ease backwards;
}
.nf-logo { width: 200px; height: auto; filter: invert(1); opacity: .9; }
.nf-code {
  font-family: 'Cormorant Garamond', serif; font-weight: 500;
  font-size: 96px; letter-spacing: .12em; text-indent: .12em; line-height: 1;
  color: #333; margin-top: 48px;
}
.nf-word {
  font-family: 'Cormorant Garamond', serif; font-style: italic; font-weight: 400;
  font-size: 18px; letter-spacing: .15em; color: #888; margin-top: 10px;
}
.nf-text {
  font-family: 'Noto Serif JP', serif; font-weight: 300;
  font-size: 14px; line-height: 2; margin-top: 40px;
}
.nf-back { margin-top: 30px; }
.nf-back a {
  font-family: 'Noto Serif JP', serif; font-size: 14px; letter-spacing: .1em;
  color: #333; text-decoration: underline; text-underline-offset: 4px;
}
.nf-back a:hover { color: #888; }

@media (prefers-reduced-motion: reduce) {
  .hero-img, .hero-mark, .scroll-cue, .cue-line::after { animation: none; }
  .viewer-img { transition: none; }
}
