@charset "utf-8";

/* ===============================
  カード共通設定
=============================== */
.kaiyo-card,
.kpast-link {
  width: 330px;
  max-width: 330px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  line-height: 1.55;

  display: grid;
  gap: 10px;
  padding: 12px;
}

/* ===============================
  現在の海況情報
=============================== */
.kaiyo-row {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
  justify-items: center;
}

@media (min-width: 720px) {
  .kaiyo-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

.kaiyo-card__title {
  margin: 0 0 4px;
}

.kaiyo-card__map {
  width: 100%;
  height: 320px;
  border: none;
  border-radius: var(--radius);
}

.kaiyo-card__legend {
  width: 100%;
  margin: 0;
}

.kaiyo-card__legend img {
  width: 100%;
  display: block;
}

.kaiyo-card__desc {
  margin: 0;
}

/* ===============================
  過去に掲載した海況情報
=============================== */
.kpast-row {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
  justify-items: center;
}

@media (min-width: 720px) {
  .kpast-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1080px) {
  .kpast-row {
    grid-template-columns: repeat(3, 1fr);
  }
}
.kpast-link {
  text-decoration: none;
  color: inherit;
}

.kpast-title {
  margin: 0 0 4px;
}

.kpast-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.kpast-desc {
  margin: 0;
}

/* ===============================
   海況情報ページ 印刷レイアウト
=============================== */
@media print {

  .kaiyo-row {
    grid-template-columns: repeat(2, 1fr);
    justify-items: stretch;
  }

  .kaiyo-card {
    width: 100%;
    max-width: none;
  }

  .kaiyo-card__map {
    height: 380px;
  }

  .kpast-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 12px;
    justify-items: stretch;
  }
}
