/*
 * hero_extras.css v4
 * design_v4.py により自動生成。直接編集しないこと。
 */

/* 旧 floating-cta は完全に隠す */
.floating-cta { display: none !important; }

/* ====================================================
 * (1) お知らせウィジェット（さらにコンパクト）
 * ==================================================== */
.mainVisual { position: relative !important; }
.hero-news-widget {
  right: 28px !important;
  bottom: 14px !important;
  width: 320px !important;
  box-shadow: 0 14px 38px rgba(0,0,0,0.36) !important;
}
.hero-news-widget .hnw-head { padding: 6px 12px !important; font-size: 10px !important; }
.hero-news-widget .hnw-body { padding: 14px 16px 12px !important; }
.hero-news-widget .hnw-title { font-size: 12.5px !important; }
@media (max-width: 1100px) {
  .hero-news-widget { right: 12px !important; bottom: 6px !important; width: 280px !important; }
}

/* ====================================================
 * (2) HERO吹き出し → 一旦完全に非表示（CSSで隠すだけ・後で復活可能）
 * ==================================================== */
.mainVisual .ch-head,
.mainVisual .ch-msg {
  display: none !important;
}

/* 以下は非表示なので effectively 無視されるが、復活時のために残しておく */
.mainVisual .ch-head--unused,
.mainVisual .ch-msg--unused {
  background: linear-gradient(135deg, rgba(255,255,255,0.82) 0%, rgba(245,247,255,0.82) 100%) !important;
  backdrop-filter: blur(8px) saturate(140%);
  -webkit-backdrop-filter: blur(8px) saturate(140%);
  max-width: 140px !important;
  position: relative;
  z-index: 3;
}
.mainVisual .ch-head {
  display: flex !important;
  align-items: center; gap: 5px;
  padding: 7px 10px 2px !important;
  border-radius: 10px 10px 0 0 !important;
  font-family: 'Lato', sans-serif !important;
  font-size: 8.5px !important;
  font-weight: 800 !important;
  letter-spacing: 0.12em !important;
  color: #1a2747 !important;
  text-transform: uppercase;
  border-top: 2px solid #6366f1;
}
.mainVisual .ch-msg {
  padding: 2px 10px 9px !important;
  border-radius: 0 0 10px 10px !important;
  font-size: 10.5px !important;
  font-weight: 500 !important;
  line-height: 1.4 !important;
  color: #1a2747 !important;
  box-shadow: 0 10px 28px rgba(0,0,0,0.32),
              0 0 0 1px rgba(255,255,255,0.3) !important;
  margin-bottom: 8px !important;
}
.mainVisual .ch-head:nth-of-type(1) { border-top-color: #6366f1; }
.mainVisual .ch-head:nth-of-type(2) { border-top-color: #10b981; }
.mainVisual .ch-head .dot {
  width: 7px !important; height: 7px !important;
  border-radius: 50% !important;
  background: radial-gradient(circle, #ee3833 30%, #ff6b3d 100%) !important;
  box-shadow: 0 0 0 2.5px rgba(238,56,51,0.18);
  animation: hb-pulse 1.8s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes hb-pulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 0 2.5px rgba(238,56,51,0.18); }
  50% { transform: scale(1.22); box-shadow: 0 0 0 5px rgba(238,56,51,0.05); }
}
.mainVisual .ch-msg strong {
  display: inline-block; padding: 0px 5px; border-radius: 3px;
  background: linear-gradient(135deg, #fff4e6 0%, #ffe0b8 100%);
  color: #d84315; font-weight: 800 !important; font-size: 10px;
  box-shadow: inset 0 -1.5px 0 rgba(216,67,21,0.18);
  white-space: nowrap;
}
.mainVisual .ch-msg:nth-of-type(2) strong,
.mainVisual .ch-head:nth-of-type(2) ~ .ch-msg strong {
  background: linear-gradient(135deg, #e6f7ef 0%, #b8eed3 100%);
  color: #047857;
  box-shadow: inset 0 -2px 0 rgba(4,120,87,0.18);
}
.mainVisual .ch-head, .mainVisual .ch-msg {
  animation: hb-float 6s ease-in-out infinite; will-change: transform;
}
.mainVisual .ch-head:nth-of-type(2),
.mainVisual .ch-head:nth-of-type(2) + .ch-msg { animation-delay: 1.5s; }
@keyframes hb-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

/* ====================================================
 * (3) セクション余白
 * ==================================================== */
body section:not(.mainVisual):not(.mainSection) {
  padding-top: 80px !important;
  padding-bottom: 80px !important;
}
section.clients { padding: 70px 0 78px !important; }
section + section { margin-top: 0 !important; }

/* ====================================================
 * (4) 見出しデザイン強化（v3 と同じ）
 * ==================================================== */
section .headLine01 {
  text-align: center !important;
  margin-bottom: 44px !important;
}
section .headLine01 .en {
  display: block !important;
  font-family: 'Lato', sans-serif !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  letter-spacing: 0.42em !important;
  background: linear-gradient(90deg, #6366f1 0%, #ee3833 100%);
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  margin-bottom: 14px !important;
  text-transform: uppercase !important;
}
section .headLine01 .jp {
  display: block !important;
  font-size: clamp(26px, 3.2vw, 36px) !important;
  font-weight: 800 !important;
  color: #0a0e27 !important;
  line-height: 1.35 !important;
  letter-spacing: -0.02em !important;
}
section .headLine01::after {
  content: '';
  display: block; width: 48px; height: 3px;
  margin: 20px auto 0;
  background: linear-gradient(90deg, #6366f1 0%, #ee3833 100%);
  border-radius: 2px;
}

/* ====================================================
 * (5) 偶数section=淡いグレー背景
 * ==================================================== */
body section:not(.mainVisual):not(.mainSection):nth-of-type(even) {
  background: linear-gradient(180deg, #f9fafb 0%, #f3f4f6 100%) !important;
}
body section.clients { background: #ffffff !important; }

/* ====================================================
 * (6) マイクロインタラクション
 * ==================================================== */
.card, .skillCard, .caseCard, .magCard, .featureCard, .ai-card, .vs-card,
section .col, section .box, .article-item, .seminar-item, .ai-series-item,
.magazine-item, .case-item, .news-item, .voice-item {
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
              box-shadow 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
.card:hover, .skillCard:hover, .caseCard:hover, .magCard:hover,
.featureCard:hover, .ai-card:hover, .vs-card:hover,
.article-item:hover, .seminar-item:hover, .ai-series-item:hover,
.magazine-item:hover, .case-item:hover, .news-item:hover, .voice-item:hover {
  transform: translateY(-6px) !important;
  box-shadow: 0 18px 44px rgba(10, 14, 39, 0.14) !important;
}
.clients .logo-item:hover { transform: none !important; }

/* ====================================================
 * (7) アクセントカラー差し色
 * ==================================================== */
section a:not(.btn):not(.logo-item):not(.btn-header-dl) {
  color: #6366f1;
  transition: color 0.2s ease;
}
section a:not(.btn):not(.logo-item):not(.btn-header-dl):hover { color: #ee3833; }

/* ====================================================
 * (8) タイポグラフィ
 * ==================================================== */
body { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
section p { line-height: 1.85; }
section strong { color: #0a0e27; }

/* ====================================================
 * (9) HEROのCTAボタン hover
 * ==================================================== */
.mainVisual .ctaRow a {
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
              box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
.mainVisual .ctaRow a:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 36px rgba(0,0,0,0.28);
}

/* ====================================================
 * (10) ヘッダー追加CTA
 *      形・サイズは JSが お問い合わせのclassを継承するので同じになる。
 *      色だけ強制的に変える（白背景＋赤文字＋赤枠＝セカンダリ）。
 * ==================================================== */
.btn-header-dl,
.btn-header-dl:link,
.btn-header-dl:visited {
  background: #ffffff !important;
  background-image: none !important;
  color: #ee3833 !important;
  border: 2px solid #ee3833 !important;
  margin-right: 12px !important;
  text-align: center !important;
  justify-content: center !important;
  display: inline-flex !important;
  align-items: center !important;
  box-sizing: border-box !important;
}
.btn-header-dl::before {
  content: '📄';
  margin-right: 6px;
  font-size: 0.9em;
}
.btn-header-dl:hover {
  background: #ee3833 !important;
  color: #ffffff !important;
}
@media (max-width: 768px) { .btn-header-dl { display: none !important; } }

/* ====================================================
 * ★ 吹き出しを絶対に消す（最終勝者ルール・他のどんなCSSにも勝つ）
 * ==================================================== */
.mainVisual .ch-head,
.mainVisual .ch-msg,
body .mainVisual div.ch-head,
body .mainVisual div.ch-msg,
.mainVisual *[class*="ch-head"],
.mainVisual *[class*="ch-msg"] {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  height: 0 !important;
  max-height: 0 !important;
  width: 0 !important;
  max-width: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
  position: absolute !important;
  left: -99999px !important;
  top: -99999px !important;
}

/* ====================================================
 * (11) レスポンシブ
 * ==================================================== */
@media (max-width: 768px) {
  body section:not(.mainVisual):not(.mainSection) {
    padding-top: 48px !important; padding-bottom: 48px !important;
  }
  section.clients { padding: 42px 0 48px !important; }
  .mainVisual .ch-head, .mainVisual .ch-msg {
    animation: none; max-width: 100% !important;
  }
  .mainVisual .ch-msg { font-size: 11px !important; }
  section .headLine01 .jp { font-size: 24px !important; }
}
