/* ============================================================
   まりも.α ポートフォリオサイト スタイルシート
   方針: モバイルファースト / モノトーン×青アクセント / 読みやすさ優先
   ============================================================ */

/* ---------- カラー・サイズの変数 ---------- */
:root {
  --color-text: #1c1c1c;        /* 本文(ほぼ黒) */
  --color-text-sub: #55595e;    /* 補足テキスト(グレー) */
  --color-bg: #e9eaec;          /* 基本背景(明るいグレー) */
  --color-bg-alt: #f4f5f6;      /* 交互セクション背景(やや白寄り) */
  --color-bg-dark: #16181d;     /* フッター背景 */
  --color-border: #d8dadd;      /* 罫線 */
  --color-accent: #2563eb;      /* アクセント(青) */
  --color-accent-dark: #1d4ed8; /* アクセント hover */
  --color-error: #c0392b;       /* エラー文 */

  --radius-card: 12px;
  --radius-btn: 8px;
  --shadow-card: 0 2px 8px rgba(22, 24, 29, 0.06);

  --font-jp: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  --font-display: "Bebas Neue", "Arial Narrow", sans-serif; /* 英語ディスプレイ見出し */
}

/* ---------- リセット・基本 ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  /* 固定ヘッダーの高さ分、アンカー位置をずらす */
  scroll-padding-top: 72px;
}

body {
  font-family: var(--font-jp);
  font-size: 16px;
  line-height: 1.8;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--color-accent); }
a:hover { color: var(--color-accent-dark); }
ul, ol { list-style-position: inside; }

/* スクリーンリーダー専用テキスト */
.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

/* SPのみ改行 */
.sp-only { display: inline; }
@media (min-width: 768px) { .sp-only { display: none; } }

/* ---------- レイアウト ---------- */
.container {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
}
.container-narrow { max-width: 720px; }

.section { padding: 72px 0; }
.section-alt { background: var(--color-bg-alt); }
@media (min-width: 768px) { .section { padding: 120px 0; } }

.mt-24 { margin-top: 24px; }

/* ---------- 見出し(英語ディスプレイ+日本語のエディトリアル構成) ---------- */
.section-en {
  font-family: var(--font-display);
  font-size: clamp(48px, 10vw, 96px);
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--color-text);
  margin-bottom: 8px;
}
.section-title {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 24px;
  padding-left: 2px;
}
.section-lead {
  color: var(--color-text-sub);
  max-width: 720px;
  margin-bottom: 40px;
}
.section-lead-next {
  text-align: center;
  margin-top: 48px;
  color: var(--color-text-sub);
}
@media (min-width: 768px) {
  .section-title { font-size: 24px; margin-bottom: 32px; }
}
/* ---------- 流れるテキスト(マーキー) ---------- */
.marquee {
  overflow: hidden;
  background: var(--color-bg-dark);
  padding: 14px 0;
  white-space: nowrap;
}
.marquee-track {
  display: inline-flex;
  animation: marquee-scroll 28s linear infinite;
}
.marquee-track span {
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  padding-right: 8px;
}
@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; }
}

/* ---------- ヘッダー ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(233, 234, 236, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--color-border);
}
.header-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.site-logo {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text);
  text-decoration: none;
}
.logo-accent { color: var(--color-accent); }

/* ナビ(SP: 開閉式 / PC: 横並び) */
.global-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.global-nav a {
  display: block;
  padding: 12px 20px;
  color: var(--color-text);
  text-decoration: none;
  font-size: 15px;
}
.global-nav a:hover { color: var(--color-accent); }
.nav-cta { font-weight: 700; color: var(--color-accent) !important; }

@media (max-width: 899px) {
  .global-nav {
    position: absolute;
    top: 60px; left: 0; right: 0;
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border);
    display: none;
    padding: 8px 0 16px;
  }
  .global-nav.is-open { display: block; }
}
@media (min-width: 900px) {
  .global-nav ul { flex-direction: row; align-items: center; gap: 8px; }
  .global-nav a { padding: 8px 10px; }
  .nav-toggle { display: none; }
}

/* ハンバーガーボタン */
.nav-toggle {
  width: 44px; height: 44px;
  background: none; border: none; cursor: pointer;
  position: relative;
}
.nav-toggle-bar,
.nav-toggle-bar::before,
.nav-toggle-bar::after {
  content: "";
  display: block;
  width: 22px; height: 2px;
  background: var(--color-text);
  position: absolute; left: 11px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle-bar { top: 21px; }
.nav-toggle-bar::before { top: -7px; left: 0; }
.nav-toggle-bar::after { top: 7px; left: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::after { transform: translateY(-7px) rotate(-45deg); }

/* ---------- ボタン ---------- */
.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: var(--radius-btn);
  font-size: 16px;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  border: none;
  transition: background 0.2s ease;
}
.btn-primary {
  background: var(--color-accent);
  color: #fff;
}
.btn-primary:hover { background: var(--color-accent-dark); color: #fff; }
.btn-secondary {
  background: #fff;
  color: var(--color-text);
  border: 1px solid var(--color-border);
}
.btn-secondary:hover { border-color: var(--color-accent); color: var(--color-accent); }

/* ---------- ファーストビュー(ダークトーン+背景動画) ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 64px;
  background: #17181b; /* モノクロ動画に合わせた無彩色の下地 */
  color: #fff;
  text-align: center;
}
/* 背景動画(なければposterの静止画が表示される) */
.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
/* 文字の可読性を確保する暗めのオーバーレイ */
.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 11, 13, 0.68) 0%, rgba(10, 11, 13, 0.55) 55%, rgba(10, 11, 13, 0.72) 100%);
}
.hero-content { position: relative; z-index: 1; }

.hero-eyebrow {
  font-size: 14px;
  font-weight: 500;
  color: #9db8e8;
  letter-spacing: 0.05em;
  margin-bottom: 16px;
}
.hero-title {
  font-size: 34px;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 20px;
  text-shadow: 0 2px 12px rgba(13, 20, 35, 0.5);
}
.hero-lead {
  color: #c6d2e2;
  max-width: 640px;
  margin: 0 auto 32px;
  text-shadow: 0 1px 8px rgba(13, 20, 35, 0.5);
}
.hero-cta { margin-bottom: 32px; }
.hero-badges {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}
.hero-badges li {
  font-size: 13px;
  color: #dbe4f0;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  padding: 6px 14px;
}
@media (min-width: 768px) {
  .hero { padding: 140px 0 110px; }
  .hero-title { font-size: 56px; }
}
/* 動きを減らす設定の閲覧者には動画を再生せず、静止画(poster)を表示 */
@media (prefers-reduced-motion: reduce) {
  .hero-video { display: none; }
  .hero-media {
    background: url("../images/hero-poster.jpg") center / cover no-repeat;
  }
}

/* ---------- カード ---------- */
.card-grid { display: grid; gap: 20px; }
@media (min-width: 768px) {
  .card-grid-2 { grid-template-columns: 1fr 1fr; }
  .card-grid-3 { grid-template-columns: repeat(3, 1fr); }
}
.card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: 24px;
}
.card-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
  line-height: 1.5;
}
.card p { color: var(--color-text-sub); }

/* リスト */
.dot-list, .check-list, .tool-list { list-style: none; }
.dot-list li, .tool-list li {
  position: relative;
  padding-left: 18px;
  margin-bottom: 8px;
  color: var(--color-text-sub);
}
.dot-list li::before, .tool-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 12px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--color-accent);
}
.tool-list li strong { color: var(--color-text); }
.check-list { counter-reset: check; }
.check-list li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 8px;
  color: var(--color-text-sub);
  counter-increment: check;
}
.check-list li::before {
  content: counter(check);
  position: absolute;
  left: 0; top: 3px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--color-accent);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 正直な注意書き */
.honest-note {
  margin-top: 40px;
  padding: 20px 24px;
  background: var(--color-bg-alt);
  border-left: 3px solid var(--color-accent);
  border-radius: 0 var(--radius-card) var(--radius-card) 0;
  color: var(--color-text-sub);
  font-size: 15px;
}

/* ---------- サービス ---------- */
.service-list { display: grid; gap: 24px; }
.service-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: 28px 24px;
}
.service-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
  line-height: 1.5;
}
.service-num {
  display: inline-block;
  margin-right: 12px;
  color: var(--color-accent);
  font-size: 15px;
  letter-spacing: 0.05em;
}
.service-desc { margin-bottom: 16px; }
.service-detail dt {
  font-weight: 700;
  font-size: 14px;
  color: var(--color-accent);
  margin-top: 12px;
}
.service-detail dd {
  color: var(--color-text-sub);
  font-size: 15px;
}
.service-note {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px dashed var(--color-border);
  font-size: 15px;
}
@media (min-width: 768px) {
  .service-card { padding: 32px 36px; }
}

/* ---------- プロセス ---------- */
.process-list {
  list-style: none;
  counter-reset: step;
  max-width: 720px;
  margin: 0 auto;
}
.process-step {
  position: relative;
  padding: 0 0 32px 56px;
  counter-increment: step;
}
/* 縦のつなぎ線 */
.process-step::before {
  content: "";
  position: absolute;
  left: 19px; top: 40px; bottom: 0;
  width: 2px;
  background: var(--color-border);
}
.process-step:last-child::before { display: none; }
/* ステップ番号 */
.process-step::after {
  content: counter(step);
  position: absolute;
  left: 0; top: 0;
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--color-accent);
  color: #fff;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.process-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 40px;
  margin-bottom: 4px;
}
.process-step p { color: var(--color-text-sub); }
.process-note {
  display: block;
  margin-top: 4px;
  font-size: 14px;
  color: var(--color-accent);
}

/* ---------- 制作事例 ---------- */
/* セクション背景に、キャラクターイラストを透過で敷く */
#works {
  position: relative;
  overflow: hidden;
}
#works::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../images/works-bg.jpg") center / cover no-repeat;
  opacity: 0.14;
  pointer-events: none;
}
#works .container { position: relative; }

.work-grid { display: grid; gap: 24px; }
@media (min-width: 900px) {
  .work-grid { grid-template-columns: repeat(3, 1fr); }
}
.work-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
.work-thumb {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: var(--color-bg-alt);
}
/* 事例カード内のクリック再生動画(制作過程モンタージュなど) */
.work-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: #16233a;
}
.work-body { padding: 20px; }
.work-type {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  color: var(--color-accent);
  border: 1px solid var(--color-accent);
  border-radius: 999px;
  padding: 2px 12px;
  margin-bottom: 12px;
}
.work-title {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.6;
  margin-bottom: 12px;
}
.work-detail dt {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text);
  margin-top: 10px;
}
.work-detail dd {
  font-size: 14px;
  color: var(--color-text-sub);
}

/* ---------- プロフィール ---------- */
.profile-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}
.profile-img {
  width: 120px; height: 120px;
  border-radius: 50%;
  object-fit: cover;
  /* 縦長イラストの顔まわりが円の中に入るよう、切り抜き位置を上寄りにする */
  object-position: 50% 18%;
  border: 1px solid var(--color-border);
}
.profile-name {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
}
.profile-body p:not(.profile-name) { color: var(--color-text-sub); }

/* 資格・経歴のチップ表示 */
.profile-quals {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
}
.profile-quals li {
  font-size: 13px;
  color: var(--color-text-sub);
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  padding: 4px 14px;
}
@media (min-width: 768px) {
  .profile-quals { justify-content: flex-start; }
}
@media (min-width: 768px) {
  .profile-wrap { flex-direction: row; text-align: left; }
  .profile-img { width: 160px; height: 160px; }
}

/* ---------- 考え方 ---------- */
.philosophy-list {
  max-width: 720px;
  margin: 0 auto;
  display: grid;
  gap: 24px;
}
.philosophy-item h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  padding-left: 14px;
  border-left: 3px solid var(--color-accent);
  line-height: 1.5;
}
.philosophy-item p { color: var(--color-text-sub); }

/* ---------- FAQ ---------- */
.faq-list { max-width: 720px; margin: 0 auto; }
.faq-item {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  margin-bottom: 12px;
  overflow: hidden;
}
.faq-item summary {
  padding: 16px 44px 16px 20px;
  font-weight: 500;
  cursor: pointer;
  position: relative;
  list-style: none; /* デフォルトの三角を消す */
}
.faq-item summary::-webkit-details-marker { display: none; }
/* 開閉アイコン(+/−) */
.faq-item summary::before,
.faq-item summary::after {
  content: "";
  position: absolute;
  right: 20px; top: 50%;
  width: 14px; height: 2px;
  background: var(--color-accent);
  transition: transform 0.2s ease;
}
.faq-item summary::after { transform: rotate(90deg); }
.faq-item[open] summary::after { transform: rotate(0); }
.faq-item summary:hover { color: var(--color-accent); }
.faq-item p {
  padding: 0 20px 16px;
  color: var(--color-text-sub);
}

/* ---------- 問い合わせフォーム ---------- */
.section-contact { background: var(--color-bg-alt); }

.contact-form {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: 28px 20px;
}
@media (min-width: 768px) { .contact-form { padding: 40px; } }

.form-field { margin-bottom: 20px; }
.form-field label {
  display: block;
  font-weight: 700;
  font-size: 15px;
  margin-bottom: 6px;
}
.required-mark, .optional-mark {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  border-radius: 4px;
  padding: 1px 8px;
  margin-left: 6px;
  vertical-align: 2px;
}
.required-mark { background: var(--color-accent); color: #fff; }
.optional-mark { background: #eceef1; color: var(--color-text-sub); }

.form-field input[type="text"],
.form-field input[type="email"],
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 12px 14px;
  font-size: 16px; /* iOSでの自動ズームを防ぐため16px以上 */
  font-family: inherit;
  color: var(--color-text);
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-btn);
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: 2px solid var(--color-accent);
  outline-offset: 1px;
  border-color: var(--color-accent);
}
.form-field textarea { resize: vertical; }

/* エラー表示 */
.field-error {
  color: var(--color-error);
  font-size: 13px;
  margin-top: 4px;
  min-height: 0;
}
.form-field .is-invalid { border-color: var(--color-error); }

/* 同意チェック */
.consent-label {
  display: flex !important;
  align-items: center;
  gap: 10px;
  font-weight: 500 !important;
  cursor: pointer;
}
.consent-label input[type="checkbox"] {
  width: 20px; height: 20px;
  accent-color: var(--color-accent);
  flex-shrink: 0;
}

.privacy-note {
  font-size: 13px;
  color: var(--color-text-sub);
  background: var(--color-bg-alt);
  border-radius: var(--radius-btn);
  padding: 12px 16px;
  margin-bottom: 24px;
}

.form-submit { text-align: center; }
.btn-submit { width: 100%; }
@media (min-width: 768px) { .btn-submit { width: auto; min-width: 280px; } }
.btn-submit:disabled {
  background: #9aa4b2;
  cursor: not-allowed;
}
.form-status {
  text-align: center;
  margin-top: 12px;
  font-size: 14px;
  color: var(--color-text-sub);
}
.form-status.is-error { color: var(--color-error); }

/* honeypot(スパム対策用の不可視フィールド) */
.hidden-field { display: none !important; }

/* ---------- 送信完了ページ ---------- */
.thanks-section { padding-top: 96px; }
.thanks-section .section-title { text-align: center; }
.thanks-box {
  background: var(--color-bg-alt);
  border-radius: var(--radius-card);
  padding: 28px 24px;
  text-align: center;
  margin-bottom: 32px;
}
.thanks-box p { margin-bottom: 8px; }
.thanks-back { text-align: center; }

/* ---------- フッター ---------- */
.site-footer {
  background: var(--color-bg-dark);
  color: #c9ced6;
  padding: 40px 0;
  text-align: center;
}
.footer-logo {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
}
.footer-note { font-size: 13px; margin-bottom: 16px; }
.footer-copy { font-size: 12px; color: #8b929c; }

/* ---------- フェードインアニメーション ----------
   JS有効時のみ(htmlにjsクラスが付いたときだけ)初期非表示にする。
   JS無効の環境では最初から表示されるため、内容が見えなくなる心配はない。 */
.js .fade-in {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.js .fade-in.is-visible {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .fade-in { opacity: 1; transform: none; transition: none; }
}
