/* ===== 共通UIコンポーネント ===== */

/* ロゴ画像サイズ */
.header__logo-mark { height: 56px; width: auto; display: block; }
.header__logo-name { height: 58px; width: auto; display: block; }
.footer__logo-mark { height: 44px; width: auto; display: block; }
.footer__logo-name { height: 46px; width: auto; display: block; }

/* ===== ローダー ===== */
.loader {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--dark);
  display: flex; align-items: center; justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.loader.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loader__inner { display: flex; align-items: center; }
.loader__logo { display: flex; align-items: center; gap: 18px; }
.loader__mark {
  height: 110px; width: auto;
  opacity: 0; transform: translateX(-16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.loader__name {
  height: 120px; width: auto;
  opacity: 0; transform: translateX(12px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

/* ===== 背景デコレーション（ロゴマーク形） ===== */
.bg-deco { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.bg-deco__shape {
  position: absolute;
  opacity: 0.16;
  background-image: url('../images/logo-mark.svg');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}
.bg-deco__shape--1 { width: 680px; height: 294px; top: 60px; right: 60px; }
.bg-deco__shape--2, .bg-deco__shape--3 { display: none; }
@media (max-width: 768px) {
  .bg-deco__shape--1 { width: 320px; height: 138px; top: 40px; right: -40px; }
}

/* ===== ヘッダー ===== */
.header {
  position: fixed; top: 0; left: 0; width: 100%; z-index: 100;
  padding: 0 40px;
  transition: background var(--transition), box-shadow var(--transition);
}
.header.is-scrolled {
  background: rgba(13,13,26,0.96);
  backdrop-filter: blur(12px);
  box-shadow: 0 2px 24px rgba(0,0,0,0.3);
}
.header__logoarea {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%;
  height: 72px;
}
.header__logo {
  display: flex; align-items: center; gap: 12px;
  transition: opacity var(--transition);
}
.header__logo:hover { opacity: 0.8; }

/* ハンバーガーボタン */
.header__menu-btn {
  background: none; border: none; cursor: pointer;
  display: flex; flex-direction: column; gap: 7px;
  padding: 8px; z-index: 201; position: relative;
}
.header__menu-btn span {
  display: block; width: 28px; height: 2px;
  background: var(--white); border-radius: 2px;
  transition: var(--transition);
}
.header__menu-btn.is-open span:nth-child(1) { transform: translateY(4.5px) rotate(20deg); }
.header__menu-btn.is-open span:nth-child(2) { transform: translateY(-4.5px) rotate(-20deg); }

/* ===== メニューオーバーレイ（丸ボタン） ===== */
.menu {
  display: none;
  position: fixed; inset: 0; z-index: 200;
  background: rgba(255,255,255,0.5);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  align-items: center; justify-content: center;
  padding: 100px 32px 40px;
}
.menu.is-open { display: flex; }
.menu__list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  width: 100%; max-width: 640px;
}
.menu__item { aspect-ratio: 1 / 1; }
.menu__link {
  width: 100%; height: 100%;
  border-radius: 50%;
  background: var(--accent);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 6px;
  box-shadow: 0 8px 32px rgba(41,169,225,0.4);
  transition: all var(--transition);
}
.menu__link:hover {
  transform: scale(1.06);
  background: var(--accent-dark);
  box-shadow: 0 12px 40px rgba(41,169,225,0.55);
}
.menu__link__arw {
  display: block; width: 8px; height: 8px;
  border-right: 2px solid rgba(255,255,255,0.7);
  border-top: 2px solid rgba(255,255,255,0.7);
  transform: rotate(45deg);
}
.menu__link__txt {
  font-size: 0.78rem; font-weight: 700;
  color: var(--white); letter-spacing: 0.1em;
  text-align: center; line-height: 1.4;
}

/* ===== ヒーロー ===== */
.hero {
  min-height: 100vh;
  background:
    radial-gradient(ellipse at 70% 40%, rgba(41,169,225,0.15) 0%, transparent 60%),
    radial-gradient(ellipse at 20% 70%, rgba(124,58,237,0.10) 0%, transparent 55%),
    linear-gradient(160deg, #0d0d1a 0%, #1a1a2e 50%, #0d1b2a 100%);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  position: relative; overflow: hidden;
  padding: 120px 24px 80px; z-index: 1;
}
.hero__bg-logo {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: clamp(280px, min(90vw, 80vmax), 1100px);
  pointer-events: none; user-select: none; z-index: -1;
}
.hero__bg-logo img { width: 100%; height: auto; opacity: 0.04; filter: brightness(10) grayscale(1); }
.hero__inner { text-align: center; position: relative; z-index: 1; max-width: 800px; }
.hero__label {
  display: inline-block; font-size: 0.72rem; letter-spacing: 0.3em;
  color: var(--accent); border: 1px solid var(--accent);
  padding: 6px 16px; border-radius: 100px; margin-bottom: 28px;
}
.hero__title {
  font-size: clamp(2rem, 5.5vw, 4rem); font-weight: 700; line-height: 1.3;
  color: var(--white); margin-bottom: 24px; letter-spacing: -0.01em;
  position: relative;
}
.hero__title em {
  font-style: normal;
  background: linear-gradient(135deg, var(--accent) 0%, #7c3aed 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
/* BraveのiOS版でグラデーション文字が正しく描画されないための回避策(main.jsでBrave判定) */
.is-brave .hero__title em {
  background: none;
  -webkit-text-fill-color: var(--accent); color: var(--accent);
}
.hero__desc {
  font-size: clamp(0.85rem, 1.5vw, 1rem);
  color: rgba(255,255,255,0.65); margin-bottom: 40px; line-height: 2;
  word-break: keep-all;
}
.hero__actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.hero__scroll {
  position: absolute; left: 50%; bottom: 40px; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 6px;
}
.hero__scroll__dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: rgba(255,255,255,0.5);
  animation: scrollDot 1.4s ease-in-out infinite;
}
.hero__scroll__dot:nth-child(2) { animation-delay: 0.2s; }
.hero__scroll__dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes scrollDot {
  0%, 100% { opacity: 0.2; transform: translateY(0); }
  50%       { opacity: 1;   transform: translateY(6px); }
}

/* ===== ボタン ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 32px; font-size: 0.85rem; font-weight: 500;
  letter-spacing: 0.08em; border-radius: 4px;
  cursor: pointer; border: none; transition: all var(--transition);
  min-width: 200px;
}
.btn--primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: var(--white);
  box-shadow: 0 4px 20px var(--accent-glow);
}
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 8px 32px var(--accent-glow); }
.btn--outline {
  background: transparent; color: var(--white);
  border: 1px solid rgba(255,255,255,0.4);
}
.btn--outline:hover { border-color: var(--white); background: rgba(255,255,255,0.08); }
.btn--outline-dark {
  background: transparent; color: var(--text);
  border: 1px solid rgba(0,0,0,0.2);
}
.btn--outline-dark:hover { border-color: var(--accent); color: var(--accent); }
.btn--large { padding: 18px 48px; font-size: 0.95rem; min-width: 280px; }

/* ===== セクション共通 ===== */
.section-head { text-align: center; margin-bottom: 56px; }
.section-head__label {
  position: relative;
  width: 66px; height: 22px;
  margin: 0 auto 20px; display: block;
}
.section-head__label::before,
.section-head__label::after {
  content: ''; position: absolute; left: 0; height: 9px;
  clip-path: polygon(0 0, 100% 0, 78% 100%, 0 100%);
}
.section-head__label::before { top: 0; width: 52px; background: var(--accent); }
.section-head__label::after { top: 13px; width: 36px; background: #72d3e9; }
.section-head__title { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; letter-spacing: -0.01em; }
.section-head--inline .section-head__title {
  display: inline-flex; align-items: center; gap: 14px;
}
.section-head--inline .service-card__flag {
  width: 46px; height: 26px;
}
.section-head--inline .service-card__flag::before { width: 36px; height: 10px; }
.section-head--inline .service-card__flag::after { width: 25px; height: 10px; top: 13px; }
.section-head--flanked {
  display: flex; align-items: center; justify-content: center; gap: 20px;
}
.section-head__flank {
  width: 40px; height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, transparent, var(--accent));
}
.section-head__flank--r { background: linear-gradient(90deg, var(--accent), transparent); }

/* ===== サービスカード（トップ） ===== */
.services { padding: 100px 0; position: relative; z-index: 1; }
.services__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.service-card {
  background: var(--white); border-radius: var(--radius);
  padding: 40px 36px; display: flex; flex-direction: column; gap: 10px;
  box-shadow: var(--shadow-sm); border: 1px solid rgba(0,0,0,0.06);
  transition: all var(--transition); position: relative; overflow: hidden;
}
.service-card::before {
  content: ''; position: absolute; top: 0; left: 0;
  width: 4px; height: 0;
  background: linear-gradient(to bottom, var(--accent), #7c3aed);
  transition: height 0.4s ease;
}
.service-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.service-card:hover::before { height: 100%; }
.service-card__icon {
  font-size: 2.5rem; font-weight: 900; letter-spacing: -0.04em;
  background: linear-gradient(135deg, var(--accent), #7c3aed);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  line-height: 1; margin-bottom: 8px;
}
.service-card__title {
  font-size: 1.1rem; font-weight: 700; letter-spacing: 0.1em;
  display: flex; align-items: center; gap: 10px; margin-bottom: 4px;
}
.service-card__flag {
  position: relative; flex-shrink: 0;
  width: 28px; height: 16px;
}
.service-card__flag::before,
.service-card__flag::after {
  content: ''; position: absolute; left: 0; height: 6px;
  clip-path: polygon(0 0, 100% 0, 78% 100%, 0 100%);
}
.service-card__flag::before { top: 0; width: 22px; background: var(--accent); }
.service-card__flag::after { top: 8px; width: 15px; background: #72d3e9; }
.service-card__desc { font-size: 0.85rem; color: var(--text-light); line-height: 1.8; flex: 1; }
.service-card__link { font-size: 0.78rem; color: var(--accent); font-weight: 500; margin-top: 8px; }

/* ===== お知らせ（トップ） ===== */
.news-section { padding: 100px 0; position: relative; z-index: 1; }
.news-list { display: flex; flex-direction: column; margin-bottom: 40px; }
.news-item {
  display: flex; align-items: baseline; gap: 16px;
  padding: 20px 0; border-bottom: 1px solid rgba(0,0,0,0.08);
  transition: background var(--transition);
}
.news-item:first-child { border-top: 1px solid rgba(0,0,0,0.08); }
.news-item:hover { background: var(--bg); padding-left: 12px; padding-right: 12px; margin: 0 -12px; }
.news-item__date { font-size: 0.8rem; color: var(--text-light); letter-spacing: 0.05em; white-space: nowrap; }
.news-item__cat {
  font-size: 0.7rem; padding: 2px 4px; border-radius: 100px;
  background: rgba(41,169,225,0.1); color: var(--accent);
  white-space: nowrap; font-weight: 500;
  width: 68px; text-align: center; flex-shrink: 0;
}
.news-item__title { font-size: 0.9rem; flex: 1; }
.news-item__empty { color: var(--text-light); font-size: 0.9rem; padding: 24px 0; }
.news-section__more { text-align: center; }

/* ===== CTA ===== */
.cta-section {
  padding: 100px 0; text-align: center;
  background: radial-gradient(ellipse at 50% 50%, rgba(41,169,225,0.12) 0%, transparent 70%),
              linear-gradient(160deg, #0d0d1a, #1a1a2e);
  position: relative; z-index: 1;
}
.cta-section__title { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; color: var(--white); margin-bottom: 16px; }
.cta-section__desc { font-size: 0.9rem; color: rgba(255,255,255,0.6); margin-bottom: 36px; line-height: 2; word-break: keep-all; }

/* ===== フッター ===== */
.footer { background: #080812; padding: 60px 40px 32px; position: relative; z-index: 1; }
.footer__inner {
  max-width: var(--max-w); margin: 0 auto;
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 48px; padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  flex-wrap: wrap;
}
.footer__logo { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.footer__address { font-size: 0.78rem; color: rgba(255,255,255,0.6); margin-bottom: 8px; line-height: 1.8; }
.footer__mail {
  font-size: 0.78rem; color: rgba(255,255,255,0.6);
  transition: color var(--transition);
}
.footer__mail:hover { color: var(--accent); }
.footer__nav ul { display: flex; flex-direction: column; gap: 12px; }
.footer__nav a {
  font-size: 0.78rem; color: rgba(255,255,255,0.6);
  letter-spacing: 0.08em; transition: color var(--transition);
}
.footer__nav a:hover { color: var(--white); }
.footer__copy {
  max-width: var(--max-w); margin: 28px auto 0;
  font-size: 0.7rem; color: rgba(255,255,255,0.5); text-align: center;
}

/* ===== レスポンシブ ===== */
@media (max-width: 768px) {
  .header { padding: 0 20px; }
  .hero { display: grid; grid-template-rows: auto auto auto; justify-items: center; min-height: auto; padding: 140px 24px 48px; }
  .hero__scroll { position: static; left: auto; bottom: auto; transform: none; margin-top: 40px; }
  .hero__bg-logo { top: 68%; }
  .services__grid { grid-template-columns: 1fr; }
  .service-card { padding: 28px 24px; }
  .news-item { flex-wrap: wrap; gap: 8px; }
  .news-item__title { width: 100%; }
  .footer__inner { flex-direction: column; gap: 32px; }
  .footer { padding: 48px 20px 24px; }
  .menu__list { grid-template-columns: repeat(2, 1fr); max-width: 400px; }
}
@media (max-width: 480px) {
  .hero__actions { flex-direction: column; align-items: stretch; }
  .btn { width: 100%; min-width: 0; text-align: center; }
  .services { padding: 64px 0; }
  .news-section { padding: 64px 0; }
  .cta-section { padding: 64px 0; }
  .loader__logo { gap: 12px; }
  .loader__mark { height: 68px; }
  .loader__name { height: 74px; }
}
