/* ============================================================
   アンカーブランチ合同会社 — コーポレートサイト
   ============================================================ */

:root {
  --bg:        #05070E;
  --bg-elev:   #0B1120;
  --line:      rgba(120, 160, 255, 0.14);
  --line-soft: rgba(120, 160, 255, 0.08);
  --text:      #E6EDF7;
  --muted:     #93A4C0;
  --accent:    #4FD1FF;
  --accent-2:  #8B7BFF;
  --glow:      0 0 24px rgba(79, 209, 255, 0.25);

  --font-base: "Space Grotesk", -apple-system, BlinkMacSystemFont, "Hiragino Sans",
               "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", Meiryo, sans-serif;
  --container: 1120px;
  --pad-x: clamp(20px, 5vw, 40px);
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-base);
  font-size: 16px;
  line-height: 1.9;
  color: var(--text);
  background: transparent;
  overflow-wrap: anywhere;
}

h1, h2, h3, p, dl, dd, ol, ul {
  margin: 0;
  padding: 0;
}

ul, ol { list-style: none; }

/* --- 背景: グリッド --------------------------------------- */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(to right,  var(--line-soft) 0 1px, transparent 1px 48px),
    repeating-linear-gradient(to bottom, var(--line-soft) 0 1px, transparent 1px 48px);
  -webkit-mask-image: radial-gradient(130% 80% at 50% 0%, #000 30%, transparent 100%);
          mask-image: radial-gradient(130% 80% at 50% 0%, #000 30%, transparent 100%);
}

/* --- 背景: グロー ----------------------------------------- */
body::after {
  content: "";
  position: fixed;
  inset: -20%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(38% 38% at 18% 12%, rgba(79, 209, 255, 0.16), transparent 70%),
    radial-gradient(42% 42% at 84% 28%, rgba(139, 123, 255, 0.14), transparent 70%);
  animation: drift 30s ease-in-out infinite alternate;
}

@keyframes drift {
  from { transform: translate3d(-2%, -1%, 0) scale(1);    opacity: 0.8; }
  to   { transform: translate3d(3%, 2%, 0)   scale(1.08); opacity: 1; }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

/* --- レイアウト共通 --------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

.section {
  padding-block: clamp(56px, 9vw, 104px);
  animation: fadeUp 0.6s ease both;
}

.services { animation-delay: 0.08s; }
.company  { animation-delay: 0.16s; }

.section-head {
  margin-bottom: clamp(28px, 4vw, 44px);
}

.section-label {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  line-height: 1.4;
}

.section-title {
  font-size: clamp(1.5rem, 3.4vw, 2rem);
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.5;
  margin-top: 6px;
}

.section-title::after {
  content: "";
  display: block;
  width: 44px;
  height: 2px;
  margin-top: 14px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 2px;
}

/* --- ヘッダー --------------------------------------------- */
.site-header {
  border-bottom: 1px solid var(--line);
  background: rgba(5, 7, 14, 0.6);
}

.header-inner {
  display: flex;
  align-items: center;
  min-height: 72px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.logo-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--accent);
  border-radius: 8px;
  font-weight: 700;
  font-size: 1rem;
  line-height: 1;
  color: var(--accent);
  box-shadow: var(--glow), inset 0 0 12px rgba(79, 209, 255, 0.12);
}

.logo-text {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  line-height: 1.4;
}

.company-name-en {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.08em;
}

.logo-suffix {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: var(--muted);
}

/* --- ヒーロー --------------------------------------------- */
.hero {
  padding-block: clamp(64px, 12vw, 140px) clamp(48px, 8vw, 96px);
}

.hero-title {
  margin-top: 0;
  /* 社名が 320px 幅でも1行に収まるサイズ。社名を長いものに差し替える
     場合は、折り返しが起きないか実際の幅で確認すること。 */
  font-size: clamp(1.4rem, 7vw, 3.5rem);
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.28;
  text-shadow: 0 0 32px rgba(79, 209, 255, 0.18);
}

.hero-en {
  margin-top: 14px;
  font-size: clamp(0.8rem, 2.2vw, 0.95rem);
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  line-height: 1.7;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
}

.hero-lead {
  margin-top: 30px;
  font-size: clamp(1.05rem, 2.6vw, 1.35rem);
  font-weight: 500;
  line-height: 1.8;
}

.hero-mission {
  margin-top: 18px;
  max-width: 40em;
  color: var(--text);
}

/* --- 事業内容 --------------------------------------------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.card {
  padding: 28px 24px 30px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(11, 17, 32, 0.9), rgba(5, 7, 14, 0.75));
  transition: border-color 200ms ease, box-shadow 200ms ease, transform 200ms ease;
}

.card:hover {
  border-color: rgba(79, 209, 255, 0.55);
  box-shadow: var(--glow);
  transform: translateY(-2px);
}

.card-label {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  line-height: 1.6;
}

.card-title {
  margin-top: 12px;
  font-size: 1.06rem;
  font-weight: 700;
  line-height: 1.6;
}

.card-body {
  margin-top: 12px;
  font-size: 0.92rem;
  line-height: 1.95;
}

/* --- 会社概要 --------------------------------------------- */
.profile {
  display: grid;
  grid-template-columns: 200px 1fr;
  border-top: 1px solid var(--line);
}

.profile dt,
.profile dd {
  padding: 20px 4px;
  border-bottom: 1px solid var(--line);
}

.profile dt {
  font-weight: 500;
  font-size: 0.9rem;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.profile dd {
  font-size: 0.95rem;
}

.purpose {
  counter-reset: purpose;
  display: grid;
  gap: 8px;
}

.purpose li {
  counter-increment: purpose;
  position: relative;
  padding-left: 2.2em;
  font-size: 0.92rem;
  line-height: 1.9;
}

.purpose li::before {
  content: counter(purpose) ".";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--accent);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

/* --- フッター --------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding-block: clamp(40px, 6vw, 64px) clamp(28px, 4vw, 40px);
  background: rgba(5, 7, 14, 0.6);
  animation: fadeUp 0.6s ease both;
  animation-delay: 0.24s;
}

.footer-title {
  margin-top: 6px;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.6;
}

.footer-mail {
  margin-top: 10px;
  font-size: 1rem;
  letter-spacing: 0.02em;
}

.footer-mail a {
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: color 200ms ease, border-color 200ms ease, text-shadow 200ms ease;
}

.footer-mail a:hover,
.footer-mail a:focus-visible {
  color: var(--accent);
  border-bottom-color: var(--accent);
  text-shadow: 0 0 16px rgba(79, 209, 255, 0.4);
}

.copyright {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--muted);
}

/* --- モーション配慮 --------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* --- レスポンシブ ----------------------------------------- */
@media (max-width: 640px) {
  body { font-size: 15px; }

  .profile {
    grid-template-columns: 1fr;
    border-top: none;
  }

  .profile dt {
    padding: 18px 4px 0;
    border-bottom: none;
  }

  .profile dd {
    padding: 6px 4px 18px;
  }
}

/* --- 印刷 / PDF 出力 ---------------------------------------
   審査書類として印刷・PDF化される場合、ブラウザは既定で背景を
   出力しない。暗色前提のままでは白地に淡色文字となり判読できな
   いため、印刷時のみ白地・黒文字に反転させる。 */
@media print {
  /* 配色トークンごと反転させる。個別セレクタで色を上書きすると
     color を明示している要素（.hero-mission 等）が取り残される。 */
  :root {
    --bg:        #fff;
    --bg-elev:   #fff;
    --line:      #999;
    --line-soft: transparent;
    --text:      #000;
    --muted:     #333;
    --accent:    #000;
    --accent-2:  #000;
  }

  html,
  body {
    background: #fff;
    color: #000;
  }

  body::before,
  body::after { display: none; }

  .site-header,
  .site-footer,
  .card { background: none; }

  .logo-mark { box-shadow: none; }

  .hero-title { text-shadow: none; }

  .hero-en {
    background: none;
    color: #000;
    -webkit-text-fill-color: #000;
  }

  .section-title::after { background: #000; }

  .footer-mail a { color: #000; border-bottom-color: #999; }
}
