/* =========================================================
   Ys Co., Ltd. — Corporate Site
   ========================================================= */

:root {
  --bg: #070b16;
  --bg-alt: #0a1020;
  --surface: #10182c;
  --surface-2: #141d35;
  --border: rgba(151, 166, 205, 0.14);
  --border-strong: rgba(151, 166, 205, 0.28);
  --text: #eef1f8;
  --text-dim: #9aa5c4;
  --text-mute: #6a7392;
  --accent: #3d8bff;
  --accent-2: #22d3ee;
  --accent-3: #8b5cf6;
  --gradient: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  --gradient-2: linear-gradient(135deg, var(--accent-3) 0%, var(--accent) 100%);
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 20px 60px rgba(2, 6, 20, 0.45);
  --header-h: 76px;
  --maxw: 1160px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Noto Sans JP", "Inter", -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", sans-serif;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, p { margin: 0; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- background texture ---------- */
.bg-fx {
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(600px 400px at 12% -5%, rgba(61, 139, 255, 0.16), transparent 60%),
    radial-gradient(700px 500px at 110% 10%, rgba(139, 92, 246, 0.14), transparent 60%),
    radial-gradient(900px 600px at 50% 120%, rgba(34, 211, 238, 0.08), transparent 60%),
    var(--bg);
}
.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(151, 166, 205, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(151, 166, 205, 0.06) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 40%, transparent 100%);
}

/* ---------- eyebrow / tags ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: "Inter", sans-serif;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-2);
  padding: 7px 14px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: rgba(61, 139, 255, 0.07);
}
.eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gradient);
  box-shadow: 0 0 10px var(--accent-2);
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 15px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease, color 0.25s ease;
  white-space: nowrap;
}
.btn-primary {
  background: var(--gradient);
  color: #04101f;
  box-shadow: 0 12px 30px rgba(61, 139, 255, 0.3);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 36px rgba(61, 139, 255, 0.42); }
.btn-ghost {
  background: rgba(255, 255, 255, 0.02);
  border-color: var(--border-strong);
  color: var(--text);
}
.btn-ghost:hover { border-color: var(--accent-2); color: var(--accent-2); transform: translateY(-2px); }
.btn-sm { padding: 10px 20px; font-size: 13.5px; }

/* ---------- header ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(7, 11, 22, 0.55);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease;
}
.site-header.scrolled {
  background: rgba(7, 11, 22, 0.86);
  border-bottom-color: var(--border);
}
.header-inner {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: flex; align-items: center; gap: 11px; }
.brand-mark { width: 36px; height: 36px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text .en {
  font-family: "Inter", sans-serif;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: 0.02em;
  color: var(--text);
}
.brand-text .en span { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.brand-text .jp { font-size: 10.5px; color: var(--text-mute); letter-spacing: 0.05em; }

.main-nav { display: flex; align-items: center; gap: 4px; }
.main-nav a {
  position: relative;
  padding: 10px 16px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-dim);
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}
.main-nav a:hover { color: var(--text); background: rgba(255, 255, 255, 0.04); }
.main-nav a.active { color: var(--text); background: rgba(61, 139, 255, 0.12); }
.header-actions { display: flex; align-items: center; gap: 10px; }

.nav-toggle {
  display: none;
  width: 40px; height: 40px;
  align-items: center; justify-content: center;
  background: transparent; border: 1px solid var(--border-strong);
  border-radius: 10px; cursor: pointer;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ""; display: block; width: 18px; height: 2px; background: var(--text);
  position: relative; transition: transform .25s ease, opacity .25s ease;
}
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after { position: absolute; top: 6px; }
.nav-toggle.open span { background: transparent; }
.nav-toggle.open span::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle.open span::after { transform: translateY(-6px) rotate(-45deg); }

/* ---------- hero ---------- */
.hero {
  padding: calc(var(--header-h) + 96px) 0 96px;
  position: relative;
}
.hero-inner { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center; }
.hero h1 {
  font-size: clamp(30px, 4.4vw, 52px);
  font-weight: 800;
  line-height: 1.42;
  letter-spacing: -0.01em;
  margin: 20px 0 22px;
}
.hero h1 .grad { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 16.5px; color: var(--text-dim); max-width: 46ch; margin-bottom: 32px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

.hero-visual { position: relative; aspect-ratio: 1/1; max-width: 460px; margin: 0 auto; }

/* ---------- page hero (inner pages) ---------- */
.page-hero { padding: calc(var(--header-h) + 72px) 0 64px; text-align: center; }
.page-hero h1 { font-size: clamp(28px, 4vw, 42px); font-weight: 800; margin: 18px 0 14px; }
.page-hero p { color: var(--text-dim); max-width: 60ch; margin: 0 auto; font-size: 15.5px; }
.page-hero .eyebrow { margin-bottom: 4px; }
.page-hero-center { display: flex; flex-direction: column; align-items: center; }

/* ---------- sections ---------- */
section { position: relative; padding: 88px 0; }
.section-head { max-width: 640px; margin: 0 0 48px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head h2 { font-size: clamp(24px, 3.2vw, 34px); font-weight: 800; margin: 16px 0 14px; letter-spacing: -0.01em; }
.section-head p { color: var(--text-dim); font-size: 15.5px; }

/* ---------- cards ---------- */
.card {
  background: linear-gradient(180deg, var(--surface), var(--surface-2));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.card:hover { transform: translateY(-4px); border-color: var(--border-strong); box-shadow: var(--shadow); }
.card-icon {
  width: 52px; height: 52px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(61, 139, 255, 0.1);
  border: 1px solid var(--border-strong);
  margin-bottom: 20px;
  color: var(--accent-2);
}
.card h3 { font-size: 19px; font-weight: 700; margin-bottom: 10px; }
.card p { color: var(--text-dim); font-size: 14.5px; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }

/* ---------- process ---------- */
.process { display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; counter-reset: step; }
.process-step { position: relative; padding: 26px 18px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.process-step .num {
  font-family: "Inter", sans-serif; font-weight: 800; font-size: 13px;
  color: var(--accent-2); letter-spacing: 0.08em; margin-bottom: 10px; display: block;
}
.process-step h4 { font-size: 15px; font-weight: 700; margin-bottom: 6px; }
.process-step p { font-size: 13px; color: var(--text-mute); }
.process-step:not(:last-child)::after {
  content: "";
  position: absolute; right: -13px; top: 50%; transform: translateY(-50%);
  width: 10px; height: 10px; border-top: 2px solid var(--border-strong); border-right: 2px solid var(--border-strong);
  rotate: 45deg;
}

/* ---------- pill list ---------- */
.pill-list { display: flex; flex-wrap: wrap; gap: 10px; }
.pill {
  font-size: 13.5px; padding: 9px 16px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border);
  color: var(--text-dim);
  transition: border-color 0.2s ease, color 0.2s ease;
}
.pill:hover { border-color: var(--accent-2); color: var(--text); }

/* ---------- works ---------- */
.work-card {
  display: grid; grid-template-columns: 64px 1fr; gap: 22px;
  padding: 32px; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); margin-bottom: 20px;
}
.work-card .work-icon {
  width: 64px; height: 64px; border-radius: 16px;
  background: var(--gradient-2); display: flex; align-items: center; justify-content: center;
  color: #04101f; flex-shrink: 0;
}
.work-card h3 { font-size: 20px; font-weight: 800; margin-bottom: 6px; }
.work-card .work-tag { font-family: "Inter", sans-serif; font-size: 11.5px; font-weight: 700; letter-spacing: 0.08em; color: var(--accent-2); text-transform: uppercase; margin-bottom: 10px; display: block; }
.work-card p { color: var(--text-dim); font-size: 14.5px; margin-bottom: 14px; }
.work-card .feature-list { display: flex; flex-direction: column; gap: 8px; }
.work-card .feature-list li { display: flex; gap: 10px; font-size: 13.5px; color: var(--text-dim); }
.work-card .feature-list li::before { content: "→"; color: var(--accent-2); font-weight: 700; flex-shrink: 0; }

/* ---------- clients ---------- */
.client-marquee { overflow: hidden; position: relative; mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.client-track { display: flex; gap: 14px; width: max-content; animation: scroll-left 32s linear infinite; }
.client-chip {
  padding: 14px 24px; border: 1px solid var(--border); border-radius: 999px;
  font-size: 14px; font-weight: 600; color: var(--text-dim); white-space: nowrap;
  background: var(--surface);
}
@keyframes scroll-left { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- info table ---------- */
.info-table { width: 100%; border-collapse: collapse; }
.info-table tr { border-bottom: 1px solid var(--border); }
.info-table tr:last-child { border-bottom: none; }
.info-table th, .info-table td { text-align: left; padding: 20px 16px; font-size: 15px; }
.info-table th { width: 180px; color: var(--text-mute); font-weight: 600; }
.info-table td { color: var(--text); }
.info-table a { color: var(--accent-2); }
.info-table a:hover { text-decoration: underline; }

/* ---------- contact ---------- */
.contact-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.contact-card { text-align: center; padding: 34px 24px; }
.contact-card .card-icon { margin: 0 auto 18px; }
.contact-card .value { font-size: 18px; font-weight: 700; margin: 6px 0 4px; }
.contact-card .label { font-size: 12.5px; color: var(--text-mute); letter-spacing: 0.06em; text-transform: uppercase; font-family: "Inter", sans-serif; }

.map-frame { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); filter: grayscale(0.4) invert(0.92) contrast(0.9); height: 340px; }
.map-frame iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ---------- CTA band ---------- */
.cta-band {
  border-radius: 24px;
  padding: 64px 48px;
  text-align: center;
  background: linear-gradient(135deg, rgba(61, 139, 255, 0.14), rgba(139, 92, 246, 0.14));
  border: 1px solid var(--border-strong);
  position: relative;
  overflow: hidden;
}
.cta-band h2 { font-size: clamp(22px, 3vw, 30px); font-weight: 800; margin-bottom: 14px; }
.cta-band p { color: var(--text-dim); margin-bottom: 28px; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- footer ---------- */
.site-footer { padding: 64px 0 32px; border-top: 1px solid var(--border); }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-brand p { color: var(--text-mute); font-size: 13.5px; margin-top: 14px; max-width: 32ch; }
.footer-col h4 { font-size: 13px; color: var(--text-mute); letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 16px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 14px; color: var(--text-dim); transition: color 0.2s ease; }
.footer-col a:hover { color: var(--accent-2); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 24px; border-top: 1px solid var(--border); font-size: 12.5px; color: var(--text-mute); flex-wrap: wrap; gap: 10px; }

/* ---------- reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ---------- responsive ---------- */
@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
  .grid-3, .contact-grid { grid-template-columns: repeat(2, 1fr); }
  .process { grid-template-columns: repeat(2, 1fr); }
  .process-step::after { display: none; }
  .footer-top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  .main-nav, .header-actions .btn { display: none; }
  .nav-toggle { display: flex; }
  .grid-3, .grid-2, .contact-grid { grid-template-columns: 1fr; }
  .process { grid-template-columns: 1fr; }
  .work-card { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .cta-band { padding: 44px 24px; }
  section { padding: 64px 0; }

  .mobile-nav {
    position: fixed; top: var(--header-h); left: 0; right: 0; bottom: 0;
    background: rgba(7, 11, 22, 0.98); backdrop-filter: blur(10px);
    z-index: 99; transform: translateY(-8px); opacity: 0; pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
    padding: 32px 24px; display: flex; flex-direction: column; gap: 6px;
  }
  .mobile-nav.open { opacity: 1; transform: translateY(0); pointer-events: auto; }
  .mobile-nav a { padding: 16px 6px; font-size: 18px; font-weight: 700; border-bottom: 1px solid var(--border); }
  .mobile-nav .btn { margin-top: 16px; }
}
@media (min-width: 761px) {
  .mobile-nav { display: none; }
}
