/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

/* Bootstrapのmt-4(1.5rem)にさらに10px足した見出し用の余白 */
.section-heading-mt {
  margin-top: calc(1.5rem + 15px);
}

/* /generations のテーブル: table-responsiveはoverflow-xを持つため、
   sticky-topを機能させるには自前でoverflow-y:autoの高さを与える必要がある。
   また、theadへのposition: stickyはSafari等で効かないことがあるため、th単位で指定する。 */
.generations-table-wrap {
  max-height: 75vh;
  overflow-y: auto;
}

.generations-table-thead th {
  position: sticky;
  top: 0;
  z-index: 1;
}

/* /generations で、URLフラグメント（#year-1990等）で指定した年の行をハイライトする */
tr:target {
  background-color: #fff3cd;
  scroll-margin-top: 3rem; /* theadがsticky-topで常時表示されるため、その高さ分ずらす */
}

/* /generations のテーブル内の世代名リンク: 下線を消す */
.generations-table-wrap a {
  text-decoration: none;
}

/* 円形のホロスコープ（HoroscopeWheelSvg）。viewBoxは400x400固定なので、
   表示サイズだけ画面幅に応じて縮小させる。 */
.horoscope-wheel {
  width: 100%;
  max-width: 400px;
  height: auto;
}
