/*
|---------------------------------------------------------------
| qinc2026-sidebar.css - サイドバーウィジェット共通スタイル
|---------------------------------------------------------------
*/

/* ==========================================================================
   Sidebar Widgets - Common
   ========================================================================== */
.sidebar-widget {
  margin-bottom: 48px;
}

.sidebar-widget:last-child {
  margin-bottom: 0;
}

.sidebar-widget__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--color-blue01);
  margin-bottom: 20px;
}

.sidebar-widget__title {
  margin: 0;
  font-family: var(--font-family-ja);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.33;
  color: var(--color-blue01);
}

.sidebar-widget__link {
  font-family: var(--font-family-ja);
  font-weight: 600;
  font-size: 14px;
  line-height: 1.14;
  color: var(--color-blue01);
  text-decoration: none;
  white-space: nowrap;
  transition: opacity 0.2s ease;
}

.sidebar-widget__link:hover {
  opacity: 0.7;
}

/* ==========================================================================
   Sidebar - Whitepaper Card
   ========================================================================== */
.sidebar-whitepaper {
  background-color: #f8fafc;
  border-radius: 8px;
  padding: 20px;
  text-align: center;
}

.sidebar-whitepaper__image {
  width: 100%;
  height: 186px;
  background-color: #ccc;
  margin-bottom: 24px;
  overflow: hidden;
}

.sidebar-whitepaper__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.sidebar-whitepaper:hover .sidebar-whitepaper__image img {
  transform: scale(1.05);
}

.sidebar-whitepaper__title {
  margin: 0 0 8px;
  font-family: var(--font-family-ja);
  font-weight: 700;
  font-size: 16px;
  line-height: 1.25;
  color: #1e293b;
}

.sidebar-whitepaper__desc {
  margin: 0 0 16px;
  font-family: var(--font-family-ja);
  font-weight: 400;
  font-size: 12px;
  line-height: 1.33;
  color: var(--color-blue01);
}

.sidebar-whitepaper__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  max-width: 200px;
  height: 32px;
  padding: 0 16px;
  border: 1px solid var(--color-blue01);
  border-radius: 4px;
  background: none;
  font-family: var(--font-family-ja);
  font-weight: 700;
  font-size: 12px;
  line-height: 1.33;
  color: var(--color-blue01);
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.sidebar-whitepaper__btn:hover {
  opacity: 0.7;
}

.sidebar-whitepaper__btn-icon {
  display: inline-flex;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.sidebar-whitepaper__btn-icon svg {
  width: 100%;
  height: 100%;
}

/* ==========================================================================
   Sidebar - Kachinote Diagnosis Banner
   ========================================================================== */
.sidebar-diagnosis {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  overflow: hidden;
  margin-bottom: 48px;
  padding: 36px 24px;
  border: 2px solid var(--color-blue01);
  border-radius: 8px;
  background: linear-gradient(to right, #eff6ff, #f8fafc);
  text-decoration: none;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  transition: box-shadow 0.3s ease;
}

.sidebar-diagnosis::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../../images/cta/bg-graph.png") center / contain no-repeat;
  pointer-events: none;
}

.sidebar-diagnosis:hover {
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
}

.sidebar-diagnosis__heading {
  position: relative;
  display: block;
  font-size: 26px;
  line-height: 1;
  margin-bottom: 16px;
}

.sidebar-diagnosis__slash {
  font-weight: 400;
  color: var(--color-blue-grey02);
}

.sidebar-diagnosis__free {
  font-weight: 900;
  color: var(--color-gold);
}

.sidebar-diagnosis__name {
  font-weight: 700;
  color: var(--color-blue01);
}

.sidebar-diagnosis__text {
  position: relative;
  margin: 0 0 20px;
  font-family: var(--font-family-ja);
  font-weight: 600;
  font-size: 16px;
  line-height: 1.44;
  color: var(--color-blue01);
}

.sidebar-diagnosis__btn {
  position: relative;
  display: inline-block;
  min-width: 134px;
  padding: 10px 24px;
  background-color: var(--color-gold);
  border-radius: 9999px;
  font-family: var(--font-family-ja);
  font-weight: 900;
  font-size: 14px;
  line-height: 1.14;
  color: #fff;
  text-align: center;
  transition: opacity 0.2s ease;
}

.sidebar-diagnosis__btn:hover {
  opacity: 0.8;
}

/* ==========================================================================
   Sidebar - Ranking
   ========================================================================== */
.sidebar-ranking {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sidebar-ranking__item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 0;
}

.sidebar-ranking__item + .sidebar-ranking__item {
  border-top: none;
}

.sidebar-ranking__number {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border: 1px solid var(--color-gold);
  font-family: var(--font-family-en);
  font-weight: 700;
  font-size: 18px;
  line-height: 1;
  color: var(--color-gold);
}

.sidebar-ranking__link {
  font-family: var(--font-family-ja);
  font-weight: 700;
  font-size: 14px;
  line-height: 1.43;
  color: #334155;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.sidebar-ranking__link:hover {
  opacity: 0.7;
}

/* ==========================================================================
   Sidebar - Keywords
   ========================================================================== */
.sidebar-keywords {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.sidebar-keywords__tag {
  display: inline-block;
  padding: 6px 8px;
  background-color: #f8fafc;
  border: 1px solid var(--color-blue-grey);
  border-radius: 4px;
  font-family: var(--font-family-ja);
  font-weight: 400;
  font-size: 14px;
  line-height: 1.14;
  color: var(--color-blue01);
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.sidebar-keywords__tag:hover {
  opacity: 0.7;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media screen and (max-width: 768px) {
  .sidebar-widget__header {
    margin-bottom: 16px;
  }

  .sidebar-diagnosis {
    padding: 28px 20px;
  }

  .sidebar-diagnosis__heading {
    font-size: 22px;
    margin-bottom: 12px;
  }

  .sidebar-diagnosis__text {
    font-size: 14px;
    margin-bottom: 16px;
  }

  .sidebar-diagnosis__btn {
    font-size: 13px;
    padding: 8px 20px;
    min-width: 120px;
  }
}
