/*
Theme Name: Monotone
Theme URI: https://www.monotone.ltd/
Author: Monotone Ltd.
Description: Monotone株式会社 コーポレートサイト
Version: 1.0.0
License: All Rights Reserved
Text Domain: monotone
*/

/* ============================================================
   CSS Variables
============================================================ */
:root {
  --black: #080808;
  --white: #f5f5f0;
  --gray: #1a1a1a;
  --mid-gray: #333;
  --light-gray: #888;
}

/* ============================================================
   Reset
============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--black) !important;
  color: var(--white);
  font-family: 'Noto Sans JP', sans-serif;
  font-weight: 300;
  overflow-x: hidden;
  cursor: none;
}

/* ============================================================
   Custom Cursor
============================================================ */
.cursor {
  width: 12px; height: 12px;
  background: var(--white);
  border-radius: 50%;
  position: fixed;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.3s, height 0.3s;
}
.cursor-ring {
  width: 40px; height: 40px;
  border: 1px solid rgba(245,245,240,0.4);
  border-radius: 50%;
  position: fixed;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: width 0.3s, height 0.3s;
}

/* ============================================================
   Navigation
============================================================ */
.mt-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 60px;
  mix-blend-mode: difference;
}
.mt-logo a {
  display: flex;
  align-items: center;
  text-decoration: none;
  height: 22px;
}
.mt-logo a svg { height: 22px; width: auto; }
.mt-footer-logo svg { height: 16px; width: auto; opacity: 0.5; }
.mt-nav-links {
  display: flex;
  gap: 40px;
  list-style: none;
}
.mt-nav-links a {
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--white);
  text-decoration: none;
  position: relative;
}
.mt-nav-links a::after {
  content: '';
  position: absolute;
  bottom: -3px; left: 0;
  width: 0; height: 1px;
  background: var(--white);
  transition: width 0.4s ease;
}
.mt-nav-links a:hover::after { width: 100%; }

/* ============================================================
   Hero
============================================================ */
#hero {
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 0 40px;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--mid-gray);
}
#hero::before {
  content: '';
  position: absolute;
  inset: -50%;
  background: repeating-linear-gradient(
    -45deg,
    transparent,
    transparent 60px,
    rgba(255,255,255,0.018) 60px,
    rgba(255,255,255,0.018) 61px
  );
  pointer-events: none;
  animation: bgDrift 30s linear infinite;
}
@keyframes bgDrift {
  from { transform: translate(0, 0); }
  to   { transform: translate(88px, 88px); }
}
.hero-glow {
  position: absolute;
  width: 700px; height: 700px;
  background: radial-gradient(circle, rgba(255,255,255,0.04) 0%, transparent 70%);
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.hero-copy {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hero-eyebrow {
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.5em;
  color: var(--light-gray);
  margin-bottom: 32px;
  opacity: 0;
  animation: fadeUp 1s ease 0.2s forwards;
}
.hero-main {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(72px, 13vw, 200px);
  line-height: 0.85;
  letter-spacing: 0.04em;
  color: var(--white);
  opacity: 0;
  animation: fadeUp 1s ease 0.5s forwards;
}
.hero-main em {
  font-style: normal;
  -webkit-text-stroke: 1px var(--white);
  color: transparent;
}
.hero-divider {
  width: 1px; height: 0;
  background: rgba(245,245,240,0.3);
  margin: 28px auto;
  animation: lineGrow 0.8s ease 1.2s forwards;
}
@keyframes lineGrow { to { height: 60px; } }
.hero-tagline {
  font-family: 'Space Mono', monospace;
  font-size: clamp(12px, 1.6vw, 20px);
  letter-spacing: 0.3em;
  color: var(--white);
  opacity: 0;
  animation: fadeUp 1s ease 1.6s forwards;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.hero-corner-left {
  position: absolute;
  bottom: 40px; left: 60px;
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: rgba(245,245,240,0.25);
  z-index: 2;
}
.hero-scroll {
  position: absolute;
  right: 60px; bottom: 40px;
  writing-mode: vertical-rl;
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--light-gray);
  display: flex;
  align-items: center;
  gap: 16px;
  z-index: 2;
}
.hero-scroll::before {
  content: '';
  display: block;
  width: 1px; height: 50px;
  background: var(--light-gray);
  animation: scrollLine 2s ease-in-out infinite;
}
@keyframes scrollLine {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

/* ============================================================
   Section Base
============================================================ */
.mt-section {
  padding: 120px 60px;
  border-bottom: 1px solid var(--mid-gray);
}
.section-label {
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.4em;
  color: var(--light-gray);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 20px;
}
.section-label::before {
  content: '';
  display: block;
  width: 40px; height: 1px;
  background: var(--light-gray);
}
.section-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(50px, 7vw, 100px);
  letter-spacing: 0.05em;
  line-height: 1;
  margin-bottom: 8px;
}

/* ============================================================
   Service
============================================================ */
#section-service { background: var(--black); }
.service-intro {
  font-size: 13px;
  color: var(--light-gray);
  line-height: 2;
  max-width: 500px;
  margin-bottom: 60px;
}
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--mid-gray);
  border-left: 1px solid var(--mid-gray);
}
.service-card {
  padding: 40px 30px;
  border-right: 1px solid var(--mid-gray);
  border-bottom: 1px solid var(--mid-gray);
  position: relative;
  overflow: hidden;
}
.service-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--white);
  transform: translateY(calc(100% + 1px));
  transition: transform 0.5s cubic-bezier(0.76, 0, 0.24, 1);
}
.service-card:hover::before { transform: translateY(0); }
.service-card:hover .service-num,
.service-card:hover .service-name,
.service-card:hover .service-desc { color: var(--black); }
.service-num {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 48px;
  color: rgba(245,245,240,0.1);
  position: relative;
  z-index: 1;
  transition: color 0.4s;
  line-height: 1;
  margin-bottom: 40px;
}
.service-name {
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.15em;
  color: var(--white);
  position: relative;
  z-index: 1;
  transition: color 0.4s;
  margin-bottom: 16px;
  line-height: 1.6;
}
.service-desc {
  font-size: 11px;
  color: var(--light-gray);
  line-height: 1.8;
  position: relative;
  z-index: 1;
  transition: color 0.4s;
}

/* ============================================================
   Company
============================================================ */
#section-company { background: var(--gray); }
.company-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}
.company-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}
.company-table tr { border-bottom: 1px solid var(--mid-gray); }
.company-table td {
  padding: 20px 0;
  font-size: 13px;
  line-height: 1.8;
  vertical-align: top;
}
.company-table td:first-child {
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.15em;
  color: var(--light-gray);
  width: 130px;
}
.map-box {
  aspect-ratio: 4/3;
  overflow: hidden;
  position: relative;
}
.map-box iframe {
  width: 100%; height: 100%;
  border: none;
  filter: grayscale(100%) contrast(1.1) brightness(0.85);
}
.map-label {
  position: absolute;
  top: 20px; left: 20px;
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--white);
  background: var(--black);
  padding: 8px 14px;
}

/* ============================================================
   Contact / Contact Form 7
============================================================ */
#section-contact { background: var(--black); }
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 100px;
  align-items: start;
}
.contact-copy {
  font-size: 13px;
  color: var(--light-gray);
  line-height: 2.2;
  margin-bottom: 40px;
}
.form-head::after {
  content: "*";
  margin-left: 8px;
}
/* ============================================================
   Contact Form 7
============================================================ */

/* 全体を囲むpタグのリセット */
.wpcf7-form > p {
  margin: 0 !important;
  padding: 0 !important;
}

/* pタグ直下のbrをすべて非表示（フィールド間の区切り） */
.wpcf7-form > p > br {
  display: none !important;
}

/* label — ブロック化してフィールドをそれぞれ独立させる */
.wpcf7-form label {
  display: block !important;
  font-family: 'Space Mono', monospace !important;
  font-size: 10px !important;
  letter-spacing: 0.2em !important;
  color: var(--light-gray) !important;
  margin: 20px 0 0 0 !important;
  line-height: 1 !important;
}

/* label内のbr（ラベルテキストとinputの間）を非表示 */
.wpcf7-form label > br {
  display: none !important;
}

/* wpcf7-form-control-wrap をブロック化 */
.wpcf7-form .wpcf7-form-control-wrap {
  display: block !important;
  margin-top: 8px !important;
}

/* input / textarea */
.wpcf7-form input[type="text"],
.wpcf7-form input[type="email"],
.wpcf7-form textarea {
  display: block !important;
  width: 100% !important;
  background: var(--gray) !important;
  border: 1px solid var(--mid-gray) !important;
  color: var(--white) !important;
  font-family: 'Noto Sans JP', sans-serif !important;
  font-size: 13px !important;
  padding: 16px 20px !important;
  outline: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  transition: border-color 0.3s !important;
  margin: 0 !important;
  -webkit-appearance: none !important;
}
.wpcf7-form input[type="text"]:focus,
.wpcf7-form input[type="email"]:focus,
.wpcf7-form textarea:focus {
  border-color: var(--white) !important;
}
.wpcf7-form input.wpcf7-not-valid,
.wpcf7-form textarea.wpcf7-not-valid {
  border-color: rgba(255, 100, 100, 0.6) !important;
}
.wpcf7-form textarea {
  resize: vertical !important;
  min-height: 140px !important;
  line-height: 1.8 !important;
}

/* バリデーションエラーメッセージ */
.wpcf7-not-valid-tip {
  display: block !important;
  font-family: 'Space Mono', monospace !important;
  font-size: 9px !important;
  letter-spacing: 0.1em !important;
  color: rgba(255, 100, 100, 0.8) !important;
  margin-top: 6px !important;
  padding: 0 !important;
  background: none !important;
  border: none !important;
  line-height: 1.5 !important;
}

/* 送信ボタン — labelの外のinputなのでブロックで扱わずinline-block */
.wpcf7-form input[type="submit"] {
  display: inline-block !important;
  margin-top: 24px !important;
  background: var(--white) !important;
  color: var(--black) !important;
  font-family: 'Space Mono', monospace !important;
  font-size: 11px !important;
  letter-spacing: 0.2em !important;
  padding: 18px 40px !important;
  border: none !important;
  border-radius: 0 !important;
  cursor: pointer !important;
  transition: background 0.3s, color 0.3s !important;
  -webkit-appearance: none !important;
}
.wpcf7-form input[type="submit"]:hover {
  background: var(--mid-gray) !important;
  color: var(--white) !important;
}

/* スピナー非表示 */
.wpcf7-spinner {
  display: none !important;
}

/* レスポンスメッセージ */
.wpcf7-response-output {
  font-family: 'Space Mono', monospace !important;
  font-size: 10px !important;
  letter-spacing: 0.1em !important;
  border: 1px solid #0a0a0a !important;
  color: var(--light-gray) !important;
  padding: 14px 18px !important;
  margin: 20px 0 0 0 !important;
  background: transparent !important;
  border-radius: 0 !important;
  line-height: 1.8 !important;
}
.wpcf7-form.sent .wpcf7-response-output {
  border-color: rgba(180, 180, 180, 0.4) !important;
  color: var(--white) !important;
}
.wpcf7-form.invalid .wpcf7-response-output,
.wpcf7-form.failed .wpcf7-response-output {
  border-color: rgba(255, 100, 100, 0.4) !important;
  color: rgba(255, 100, 100, 0.8) !important;
}

/* screen-reader-response 非表示 */
.wpcf7 .screen-reader-response {
  display: none !important;
}

/* hidden fieldset リセット */
.wpcf7-form fieldset.hidden-fields-container {
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* モバイル */
@media (max-width: 600px) {
  .wpcf7-form input[type="submit"] {
    width: 100% !important;
    text-align: center !important;
  }
}

/* ============================================================
   Footer
============================================================ */
.mt-footer {
  padding: 40px 60px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--black);
}
.mt-footer-logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 18px;
  letter-spacing: 0.15em;
  color: var(--light-gray);
}
.mt-footer-copy {
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  color: rgba(245,245,240,0.2);
}

/* ============================================================
   Reveal / Noise
============================================================ */

/* JSが有効な時だけ非表示にする（body.js-readyクラスで制御） */
body.js-ready .reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
body.js-ready .reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

body::after {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='1'/%3E%3C/svg%3E");
  opacity: 0.025;
  pointer-events: none;
  z-index: 9997;
}
/* ============================================================
   404 page
============================================================ */
#page-404 {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 80px;
  background: var(--black);
}

.page-404-code {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(160px, 20vw, 280px);
  line-height: 0.85;
  color: transparent;
  -webkit-text-stroke: 2px var(--white);
  letter-spacing: -0.02em;
  margin: 0;
  animation: fadeUp 0.6s ease 0.05s both;
}

.page-404-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(48px, 8vw, 100px);
  line-height: 0.9;
  color: var(--white);
  letter-spacing: -0.01em;
  margin: 0 0 28px 0;
  animation: fadeUp 0.6s ease 0.15s both;
}

.page-404-divider {
  width: 40px;
  height: 1px;
  background: var(--mid-gray);
  margin-bottom: 28px;
  animation: fadeUp 0.6s ease 0.22s both;
}

.page-404-desc {
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 13px;
  line-height: 2;
  color: var(--white);
  margin-bottom: 48px;
  animation: fadeUp 0.6s ease 0.28s both;
}

.page-404-btn {
  display: inline-block;
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--black);
  background: var(--white);
  padding: 16px 36px;
  text-decoration: none;
  transition: background 0.3s, color 0.3s;
  animation: fadeUp 0.6s ease 0.34s both;
}

.page-404-btn:hover {
  background: var(--mid-gray);
  color: var(--white);
}

@media (max-width: 600px) {
  #page-404 { padding: 100px 24px; }
  .page-404-code { font-size: clamp(120px, 30vw, 180px); }
}

/* ============================================================
   Responsive
============================================================ */
@media (max-width: 1024px) {
  .mt-header { padding: 24px 30px; }
  .mt-section { padding: 80px 30px; }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .service-card { border-right: 1px solid var(--mid-gray); border-bottom: 1px solid var(--mid-gray); }
  .company-layout, .contact-layout { grid-template-columns: 1fr; gap: 50px; }
  .mt-footer { padding: 30px; flex-direction: column; gap: 12px; text-align: center; }
  .mt-nav-links { gap: 24px; }
}

@media (max-width: 600px) {
  .mt-header { padding: 18px 20px; }
  .mt-logo a { font-size: 16px; }
  .mt-nav-links { gap: 14px; }
  .mt-nav-links a { font-size: 9px; letter-spacing: 0.1em; }

  #hero { padding: 0 24px; }
  .hero-eyebrow { font-size: 9px; margin-bottom: 20px; }
  .hero-main { font-size: clamp(52px, 17vw, 85px); line-height: 0.88; }
  .hero-divider { margin: 18px auto; }
  .hero-tagline { font-size: 10px; letter-spacing: 0.12em; }

  .mt-section { padding: 64px 20px; }
  .section-title { font-size: 42px; }
  .section-label { margin-bottom: 36px; }

  .services-grid { grid-template-columns: 1fr; }
  .service-card { border-bottom: 1px solid var(--mid-gray); }
  .map-box { aspect-ratio: 16/9; }

  .mt-footer { padding: 24px 20px; }
  .cursor, .cursor-ring { display: none; }
  body { cursor: auto; }
}
