/*
 * サイト全体のスタイル。旧 Next.js アプリの src/styles/*.scss を Dart Sass でコンパイルしたものを起点に、
 * 旧アプリ撤去 (2026-09) 以降はこのファイルが唯一のスタイル定義。直接編集してよい。
 * Workers 版で追加した分は styles.workers.css にあり、/styles.css で結合して配信される。
 */
:root {
  --color-base-background: #000;
  --color-base-background-lighter: #333;
  --color-base-text: #fff;
  --color-base-text-lighter: rgba(212, 231, 241, 0.6);
  --color-border: rgba(115, 125, 130, 0.4);
  --color-primary-background: #f75e29;
  --color-primary-text: #FF9F35;
}

html {
  box-sizing: border-box;
  font-size: 16px;
  -ms-text-size-adjust: 100%;
  -webkit-text-size-adjust: 100%;
  line-height: 1.7;
}
@media screen and (max-width: 576px) {
  html {
    font-size: 15px;
  }
}

*,
*:before,
*:after {
  box-sizing: inherit;
}

body {
  margin: 0;
  color: var(--color-base-text);
  background: var(--color-base-background);
  word-break: break-word;
  word-wrap: break-word;
  font-family: "Inter", "BlinkMacSystemFont", "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
}

img {
  max-width: 100%;
}

p,
blockquote,
dl,
dd,
dt,
section {
  margin: 0;
}

a {
  text-decoration: none;
  transition: 0.25s;
  color: inherit;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  font-weight: bold;
  line-height: 1.5;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

hr {
  border: none;
}

button {
  font-family: inherit;
  border: none;
  cursor: pointer;
  appearance: none;
  background: transparent;
  font-size: inherit;
  font-weight: inherit;
  font-family: inherit;
  transition: 0.25s;
  padding: 0;
  margin: 0;
}

.content-wrapper {
  max-width: 850px;
  margin: 0 auto;
  padding: 0 1.3rem;
}

.undo-wrap-for-scroll {
  margin-right: -1.3rem;
}

.site-header {
  padding: 1rem 0;
  position: sticky;
  top: 0;
  background: var(--color-base-background);
  z-index: 99;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-header__logo-link {
  display: flex;
  align-items: center;
}

.site-header__logo-img {
  height: 35px;
}

.site-header__links {
  display: flex;
  align-items: center;
}

.site-header__link {
  margin-left: 1.5rem;
  font-size: 0.95rem;
}

.site-footer {
  margin-top: 5rem;
  padding: 1rem 0;
  border-top: solid 1px var(--color-border);
  text-align: center;
  font-size: 0.9rem;
  color: var(--color-base-text-lighter);
}

.scrollable-members {
  display: flex;
  align-items: flex-start;
  overflow-x: scroll;
  padding-bottom: 1rem; /* for scrollbar */
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  /* right space for horizontal scroll  */
}
.scrollable-members:after {
  content: "";
  display: block;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}
.scrollable-members::-webkit-scrollbar {
  display: none;
  -webkit-appearance: none;
}

.scrollable-member__link {
  display: block;
  flex-shrink: 0;
  width: 90px;
  margin-right: 23px;
  margin-left: -5px;
  text-align: center;
  line-height: 1.5;
  scroll-snap-align: center;
}

.scrollable-member__image,
.scrollable-member__img,
.scrollable-member__name,
.scrollable-member__role {
  display: block;
}

.scrollable-member__img {
  border-radius: 18px;
  margin: 0 auto;
}

.scrollable-member__name {
  margin-top: 8px;
  font-size: 13px;
}

.scrollable-member__role {
  font-size: 12px;
  color: var(--color-base-text-lighter);
}

.post-list-empty {
  padding: 5rem 0;
  text-align: center;
  font-weight: 700;
  color: var(--color-base-text-lighter);
  font-size: 1.4rem;
}

.post-link {
  display: flex;
  flex-flow: column;
  position: relative;
  background: var(--color-base-background-lighter);
}

.post-link__author {
  padding: 1.6rem 1.6rem 0;
  display: flex;
  align-items: center;
  font-size: 13px;
  line-height: 1.4;
}
@media screen and (max-width: 576px) {
  .post-link__author {
    padding: 1.4rem 1rem 0;
  }
}

.post-link__main-link {
  padding: 1.1rem 1.6rem 1.5rem;
  flex: 1;
  display: flex;
  flex-flow: column;
}
@media screen and (max-width: 576px) {
  .post-link__main-link {
    padding: 1rem 1rem 1.2rem;
  }
}

.post-link__date {
  color: var(--color-base-text-lighter);
  font-size: 12px;
}

.post-link__author-img {
  border-radius: 25%;
  margin-right: 0.7rem;
}

.post-link__title {
  font-size: 1.1rem;
  flex: 1;
}

.post-link__site {
  margin-top: 0.9rem;
  color: var(--color-base-text-lighter);
  font-size: 12px;
  display: flex;
  align-items: center;
}

.post-link__site-favicon {
  border-radius: 3px;
  margin-right: 6px;
}

.post-link__new-label {
  position: absolute;
  right: -5px;
  top: -5px;
  display: block;
  text-align: center;
  width: 38px;
  height: 38px;
  line-height: 38px;
  font-size: 11px;
  font-weight: bold;
  color: #fff;
  background: var(--color-primary-background);
  border-radius: 12px;
}
@media screen and (max-width: 576px) {
  .post-link__new-label {
    right: 0;
    top: 0;
    height: 20px;
    line-height: 20px;
    width: 34px;
    border-radius: 0;
    font-size: 10px;
  }
}

.post-list {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
}
.post-list .post-link {
  margin-top: 5%;
  width: 47.5%;
}
@media screen and (max-width: 576px) {
  .post-list .post-link {
    margin-top: 1.3rem;
    width: 100%;
  }
}

.post-list-load {
  margin-top: 3rem;
  text-align: center;
}

.post-list-load__button {
  border: solid 1px var(--color-border);
  padding: 0.9em 2em;
  border-radius: 2.5em;
  font-size: 0.9rem;
  color: var(--color-base-text-lighter);
  overflow-anchor: none;
}

.link-back-home {
  font-size: 0.95rem;
  padding: 0.7em 1.3em;
  color: #fff;
  background: var(--color-primary-background);
}

.home-hero {
  padding: 2.7rem 0 2rem;
}

.home-hero__title {
  font-size: 3.1rem;
  line-height: 1.4;
}
@media screen and (max-width: 400px) {
  .home-hero__title {
    font-size: 2.6rem;
  }
}

.home-hero__description {
  margin-top: 0.4rem;
  font-size: 1.2rem;
  color: var(--color-base-text-lighter);
}

.home-section-title-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.3rem 0;
  border-bottom: solid 1px var(--color-border);
}

.home-section-title {
  font-size: 1.7rem;
}

.home-section-link {
  font-size: 1.1rem;
  color: var(--color-primary-text);
}

.home-members {
  padding: 3rem 0;
}

.home-members-container {
  margin-top: 2rem;
}

.about {
  padding: 2.5rem 0;
}

.about__title {
  font-size: 2.3rem;
}

.about__body p {
  margin-top: 1.2rem;
}
.about__body a {
  color: var(--color-primary-text);
}

.about__actions {
  margin-top: 3.5rem;
  text-align: center;
}

.error {
  padding: 3rem 0;
  text-align: center;
}

.error__status {
  font-size: 110px;
  font-weight: 700;
  line-height: 1.2;
}

.error__message {
  color: var(--color-base-text-lighter);
}

.error__actions {
  margin-top: 3rem;
}

.member-header {
  padding: 2rem 0;
  text-align: center;
}

.member-header__avatar-img {
  border-radius: 18px;
}

.member-header__name {
  margin-top: 0.5rem;
  font-size: 1.5rem;
}

.member-header__bio {
  display: inline-block;
  margin-top: 0.8rem;
  font-size: 0.9rem;
  max-width: 500px;
  opacity: 0.8;
}

.member-posts-container {
  padding-top: 1rem;
  border-top: solid 1px var(--color-border);
}

.member-header__links {
  margin-top: 0.6rem;
}

.member-header__link {
  margin: 0.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--color-base-background-lighter);
  color: var(--color-base-text);
}

.member-header__link-icon {
  font-size: 20px;
}

.members {
  padding: 2.5rem 0;
}

.members__title {
  font-size: 2.3rem;
}

.members__title-team {
  display: block;
  font-size: 1.3rem;
  color: var(--color-base-text-lighter);
}

.members__cards {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-gap: 2.5em 2em;
}
@media screen and (max-width: 576px) {
  .members__cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

.member-card {
  display: block;
  text-align: center;
  font-size: 0.95rem;
  position: relative;
}
.member-card:hover:before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -1rem;
  bottom: -1rem;
  left: -1rem;
  right: -1rem;
  background: var(--color-base-background-lighter);
  opacity: 0;
}
.member-card:hover:before {
  opacity: 1;
}

.member-card__name {
  margin-top: 0.7rem;
  font-size: 1.1rem;
}

.member-card__bio {
  margin-top: 0.5rem;
  display: inline-block;
  text-align: left;
  font-size: 0.85rem;
  line-height: 1.6;
  opacity: 0.7;
}

.member-card__avatar-img {
  border-radius: 0;
  width: 100%;
  height: auto;
  display: block;
}

/*
 * Workers 版固有のスタイル。styles.css (SCSS から生成) の後ろに結合して /styles.css で配信する。
 */

/* LOAD MORE のアンカー (#post-N) で飛んだとき、sticky なヘッダー (ロゴ 35px + 上下 1rem) に隠れないようにする */
.post-link {
  scroll-margin-top: calc(35px + 3rem);
}
