/*
Theme Name: RevoSpace
Theme URI: https://revo-space.com/
Author: KEG
Description: 株式会社RevoSpace 公式サイトのテーマ。最初の画面は黒×赤（写真が切り替わる）、その下は白基調のデザイン（C案）。Elementor・WPForms は不要。
Version: 1.2.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: revospace
*/

/* ---------- base ---------- */
:root {
	--bg: #fff;
	--bg2: #f5f3ef;
	--ink: #1d1d1f;
	--muted: #77757a;
	--line: #e6e2dc;
	--red: #e3262e;
	--en: "Montserrat", "Zen Kaku Gothic New", sans-serif;
	--jp: "Zen Kaku Gothic New", sans-serif;
	--r: 20px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--jp); font-size: 15px; line-height: 2; letter-spacing: .05em; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; vertical-align: middle; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p, dl, dd, ul { margin: 0; padding: 0; }
ul { list-style: none; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }
.skip-link:focus { clip: auto; width: auto; height: auto; top: 8px; left: 8px; z-index: 100; padding: 8px 16px; background: #fff; color: #000; }

/* ---------- header ---------- */
.hd { position: sticky; top: 0; z-index: 50; display: flex; align-items: center; justify-content: space-between; height: 84px; padding: 0 48px; background: #fff; transition: box-shadow .3s; }
.admin-bar .hd { top: 32px; }
.hd.is-scrolled { box-shadow: 0 1px 0 var(--line); }
.hd-logo { display: flex; align-items: center; gap: 10px; }
.hd-logo img { width: 58px; height: 58px; object-fit: cover; border-radius: 12px; }
.hd-logo span { font-family: var(--en); font-size: 17px; font-weight: 600; letter-spacing: .12em; }
.hd-nav { display: flex; align-items: center; gap: 40px; }
.hd-nav a { font-family: var(--en); font-size: 13px; font-weight: 500; letter-spacing: .16em; }
.hd-nav a[aria-current] { color: var(--red); }
.hd-nav a.is-btn { padding: 12px 26px; border-radius: 999px; background: var(--ink); color: #fff; transition: background .3s; }
.hd-nav a.is-btn:hover { background: var(--red); }
.hd-menu { display: none; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: var(--bg2); color: var(--ink); cursor: pointer; }
.hd-menu i { display: block; width: 18px; height: 2px; margin: 4px auto; background: currentColor; transition: transform .3s, opacity .3s; }
.hd.is-open .hd-menu i:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.hd.is-open .hd-menu i:nth-child(2) { opacity: 0; }
.hd.is-open .hd-menu i:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------- first view (black, photos change every 5 seconds) ---------- */
/* the white header bar is always shown, so the first view starts below it */
.fv { position: relative; height: calc(100vh - 84px); min-height: 560px; overflow: hidden; background: #0b0b0d; color: #fff; }
.fv .slide { position: absolute; inset: 0; background: center / cover no-repeat; opacity: 0; transform: scale(1); transition: opacity 1.2s, transform 0s 1.2s; }
.fv .slide.is-first { opacity: 1; }
.fv .slide.is-on, .fv .slide.is-prev { opacity: 1; transform: scale(1.15); transition: opacity 1.2s, transform 12s linear; }
.fv .slide.is-on { z-index: 2; }
.fv .slide.is-prev { z-index: 1; }
.fv::after { content: ""; position: absolute; inset: 0; z-index: 3; background: linear-gradient(90deg, rgba(11, 11, 13, .78) 0%, rgba(11, 11, 13, .3) 50%, rgba(11, 11, 13, 0) 100%), linear-gradient(0deg, rgba(11, 11, 13, .7) 0%, transparent 30%); }
.fv-in { position: relative; z-index: 4; display: flex; flex-direction: column; justify-content: center; height: 100%; max-width: 1240px; margin: 0 auto; padding: 0 48px; }
.fv-tag { display: flex; align-items: center; gap: 14px; margin-bottom: 28px; font-family: "Oswald", sans-serif; font-size: 13px; letter-spacing: .3em; color: #ff5a62; }
.fv-tag::before { content: ""; width: 48px; height: 1px; background: var(--red); }
.fv-moji { width: min(620px, 100%); margin-bottom: 36px; }
.fv-lead { font-size: 15px; line-height: 2.2; color: #d6d6de; }
/* the company name in a white frame: phones only (the same as the old site) */
.fv-name { display: none; }
.fv-big { position: absolute; right: -10px; bottom: -40px; z-index: 4; font-family: "Oswald", sans-serif; font-size: clamp(90px, 15vw, 220px); font-weight: 700; line-height: 1; color: transparent; -webkit-text-stroke: 1px rgba(255, 255, 255, .2); pointer-events: none; white-space: nowrap; }
.fv-dots { position: absolute; left: 48px; bottom: 40px; z-index: 4; display: flex; gap: 10px; }
.fv-dots i { width: 28px; height: 2px; background: rgba(255, 255, 255, .3); transition: background .3s; }
.fv-dots i.is-on { background: var(--red); }
.fv-scroll { position: absolute; right: 40px; top: 50%; z-index: 4; font-family: "Oswald", sans-serif; font-size: 11px; letter-spacing: .3em; writing-mode: vertical-rl; color: rgba(255, 255, 255, .6); }
.fv-scroll::after { content: ""; display: block; width: 1px; height: 60px; margin: 14px auto 0; background: linear-gradient(var(--red), transparent); animation: fv-drop 2s infinite; }
@keyframes fv-drop { 0% { transform: scaleY(0); transform-origin: top; } 50% { transform: scaleY(1); transform-origin: top; } 51% { transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* ---------- sections ---------- */
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 48px; }
.sec { padding: 120px 0; }
.sec.is-tint { background: var(--bg2); }
#business { scroll-margin-top: 84px; }
html { scroll-behavior: smooth; }
.ttl { margin-bottom: 56px; }
.ttl small { display: flex; align-items: center; gap: 10px; font-family: var(--en); font-size: 12px; font-weight: 600; letter-spacing: .24em; color: var(--red); }
.ttl small::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--red); }
.ttl b { display: block; margin-top: 8px; font-family: var(--en); font-size: clamp(40px, 5.4vw, 68px); font-weight: 600; line-height: 1.1; letter-spacing: .04em; }

.biz { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; }
.biz-img img { display: block; width: 100%; aspect-ratio: 5 / 4; object-fit: cover; border-radius: var(--r); }
.biz-txt h3 { margin-bottom: 24px; font-size: 26px; font-weight: 700; line-height: 1.7; }
.biz-txt p { color: #48464b; }
.biz-txt p + p { margin-top: 16px; }
.biz-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 72px; }
.biz-list li { padding: 28px 24px; border-radius: var(--r); background: #fff; }
.biz-list li b { display: block; margin-bottom: 6px; font-family: var(--en); font-size: 13px; font-weight: 600; letter-spacing: .14em; color: var(--red); }
.biz-list li span { font-size: 14px; font-weight: 700; line-height: 1.7; }

/* COMPANY / CONTACT cards */
.cards { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.card { display: block; border-radius: var(--r); overflow: hidden; background: var(--bg2); transition: transform .4s, box-shadow .4s; }
.card figure { margin: 0; aspect-ratio: 16 / 9; overflow: hidden; }
.card img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s; }
.card-in { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 30px 34px; }
.card-in b { display: block; font-family: var(--en); font-size: 28px; font-weight: 600; letter-spacing: .06em; line-height: 1.3; }
.card-in span { font-size: 13px; color: var(--muted); }
.card .arrow { display: grid; place-items: center; flex: none; width: 52px; height: 52px; border-radius: 50%; background: #fff; transition: background .3s, color .3s; }
.card .arrow svg { width: 18px; height: 18px; }
.card:hover { transform: translateY(-4px); box-shadow: 0 20px 40px rgba(0, 0, 0, .08); }
.card:hover img { transform: scale(1.05); }
.card:hover .arrow { background: var(--red); color: #fff; }

/* ---------- footer ---------- */
.ft { padding: 80px 0 32px; background: var(--ink); color: #fff; }
.ft-in { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.ft-brand { display: flex; align-items: center; gap: 18px; }
.ft-brand img { width: 72px; height: 72px; border-radius: 16px; }
.ft-brand p { font-size: 13px; line-height: 1.8; color: #b8b6bb; }
.ft-brand .nb { display: inline-block; }
.ft-brand b { display: block; font-family: var(--en); font-size: 16px; letter-spacing: .14em; color: #fff; }
.ft-nav { display: flex; gap: 32px; font-family: var(--en); font-size: 13px; letter-spacing: .16em; }
.ft-nav a:hover { color: #ff6b72; }
.ft-copy { margin-top: 56px; padding-top: 24px; border-top: 1px solid rgba(255, 255, 255, .12); font-family: var(--en); font-size: 11px; letter-spacing: .14em; color: #8d8b90; text-align: center; }

/* ---------- sub pages ---------- */
.pg-hero { padding: 80px 0 64px; }
.pg-hero .ttl { margin: 0; }
.crumb { margin-top: 28px; font-size: 12px; color: var(--muted); }
.crumb a:hover { color: var(--red); }

/* company table */
.co { padding: 24px 56px; border-radius: var(--r); background: #fff; }
.co div { display: grid; grid-template-columns: 200px 1fr; gap: 24px; padding: 26px 0; border-bottom: 1px solid var(--line); }
.co div:last-child { border-bottom: 0; }
.co dt { font-weight: 700; font-size: 14px; }
.co dd { color: #48464b; }
.co dd ul li { position: relative; padding-left: 18px; }
.co dd ul li::before { content: ""; position: absolute; left: 0; top: .9em; width: 6px; height: 6px; border-radius: 50%; background: var(--red); }
.co small { display: block; margin-top: 4px; font-size: 12px; color: var(--muted); }

/* contact form */
.cf { padding: 56px; border-radius: var(--r); background: #fff; scroll-margin-top: 110px; }
.cf-lead { margin-bottom: 36px; color: #48464b; }
.cf-row { margin-bottom: 26px; }
.cf-row label { display: block; margin-bottom: 10px; font-weight: 700; font-size: 14px; }
.cf-row label em { margin-left: 8px; font-style: normal; font-size: 11px; font-weight: 500; color: var(--red); }
.cf-row label em.any { color: var(--muted); }
.cf input[type="text"], .cf input[type="email"], .cf input[type="url"], .cf textarea { width: 100%; padding: 15px 18px; border: 1px solid transparent; border-radius: 12px; background: var(--bg2); color: var(--ink); font: inherit; transition: border-color .2s, background .2s; }
.cf textarea { min-height: 200px; resize: vertical; }
.cf input:focus, .cf textarea:focus { outline: none; border-color: var(--red); background: #fff; }
.cf-agree { margin-top: 36px; padding: 24px; border-radius: 12px; background: var(--bg2); text-align: center; }
.cf-agree p { margin-bottom: 12px; font-size: 13px; color: var(--muted); }
.cf-agree label { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; cursor: pointer; }
.cf-agree input { width: 18px; height: 18px; accent-color: var(--red); }
.cf-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.cf-btn { margin-top: 36px; text-align: center; }
.cf-error { margin-bottom: 28px; padding: 14px 18px; border-radius: 12px; background: #fdecec; color: #b3171e; font-size: 14px; }
.cf-done { text-align: center; }
.cf-done h2 { margin-bottom: 16px; font-family: var(--en); font-size: 28px; font-weight: 600; letter-spacing: .1em; }
.cf-done p { color: #48464b; }
.cf-done .btn { margin-top: 36px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 14px; min-width: 280px; height: 62px; padding: 0 40px; border: 0; border-radius: 999px; background: var(--ink); color: #fff; font-family: var(--en); font-size: 14px; font-weight: 600; letter-spacing: .2em; cursor: pointer; transition: background .3s, transform .3s; }
.btn:hover { background: var(--red); transform: translateY(-2px); }

/* plain pages (page.php / 404) */
.plain { padding: 40px 56px; border-radius: var(--r); background: #fff; line-height: 2; }
.plain h2 { margin: 1.6em 0 .6em; font-size: 20px; }
.plain p { margin-bottom: 1em; }
.plain.is-center { text-align: center; }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s, transform .9s; }
.reveal.is-in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- tablet / phone ---------- */
@media (max-width: 900px) {
	.biz { grid-template-columns: 1fr; gap: 40px; }
	.biz-list { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 782px) {
	.admin-bar .hd { top: 46px; }
}
@media (max-width: 767px) {
	body { font-size: 14px; }
	.hd { height: 68px; padding: 0 16px; }
	.hd-logo img { width: 46px; height: 46px; }
	.hd-logo span { font-size: 15px; }
	.hd-menu { display: block; }
	.hd-nav { position: absolute; top: 100%; left: 12px; right: 12px; flex-direction: column; align-items: stretch; gap: 0; padding: 12px; border-radius: 20px; background: #fff; box-shadow: 0 20px 40px rgba(0, 0, 0, .12); opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .3s, visibility .3s, transform .3s; }
	.hd-nav a { padding: 16px 12px; font-size: 15px; border-bottom: 1px solid var(--line); }
	.hd-nav a.is-btn { margin-top: 12px; border-bottom: 0; text-align: center; }
	.hd.is-open .hd-nav { opacity: 1; visibility: visible; transform: none; }

	.fv { height: calc(100svh - 68px); min-height: 540px; }
	/* phones: centered in the middle of the photo, like the old site */
	.fv::after { background: rgba(11, 11, 13, .42); }
	.fv-in { align-items: center; padding: 0 20px; text-align: center; }
	.fv-tag { justify-content: center; gap: 10px; margin-bottom: 20px; font-size: 11px; letter-spacing: .24em; }
	.fv-tag::before, .fv-tag::after { content: ""; width: 28px; height: 1px; background: var(--red); }
	.fv-moji { width: calc(100% - 40px); margin: 0 20px 30px; }
	.fv-lead { font-size: 13px; line-height: 30px; color: #fff; }
	.fv-name { display: inline-block; margin-top: 20px; padding: 10px 50px; border: 1px solid #fff; font-size: 15px; font-weight: 700; line-height: 1; color: #fff; }
	.fv-dots { left: 0; right: 0; bottom: 28px; justify-content: center; }
	.fv-scroll { display: none; }
	.fv-big { display: none; }

	.wrap { padding: 0 20px; }
	.sec { padding: 80px 0; }
	.ttl { margin-bottom: 36px; }
	.biz-txt h3 { font-size: 20px; }
	.biz-list { margin-top: 48px; gap: 10px; }
	.biz-list li { padding: 20px 16px; }
	.biz-list li span { font-size: 13px; }
	.cards { grid-template-columns: 1fr; gap: 20px; }
	.card-in { padding: 22px 22px; }
	.card-in b { font-size: 22px; }

	.ft { padding: 56px 0 28px; }
	.ft-in { flex-direction: column; align-items: flex-start; }
	.ft-nav { flex-wrap: wrap; gap: 12px 24px; }

	.pg-hero { padding: 48px 0 40px; }
	.co { padding: 8px 22px; }
	.co div { grid-template-columns: 1fr; gap: 4px; padding: 20px 0; }
	.cf { padding: 28px 20px; }
	.plain { padding: 28px 20px; }
	.btn { min-width: 0; width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
	.fv .slide, .fv .slide.is-on, .fv .slide.is-prev { transform: none; }
	.fv-scroll::after { animation: none; }
	.reveal { opacity: 1; transform: none; transition: none; }
}
