*, *::before, *::after {
  box-sizing: border-box;
  border-width: 0;
  border-style: solid;
  border-color: #e5e7eb;
  margin: 0;
  padding: 0;
}

html {
  font-family: 'Space Grotesk', 'LINE Seed JP', system-ui, sans-serif;
  background: #fafafa;
  color: rgb(78 78 78);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
}

.text-muted,
.profile-name,
.about-greeting,
.tag,
.list-item,
.story-text,
.profile-info,
.text-foreground {
  font-family: inherit;
}

body {
  margin: 0;
  line-height: inherit;
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: url('res/bg.png') center / cover no-repeat;
  opacity: 0.15;
  z-index: -1;
  pointer-events: none;
}

a {
  color: inherit;
  text-decoration: inherit;
}

img, svg {
  display: block;
  vertical-align: middle;
}

img {
  max-width: 100%;
  height: auto;
}

h1, h2, h3, h4, h5, h6 {
  font-size: inherit;
  font-weight: inherit;
}

.container {
  width: 100%;
  margin-right: auto;
  margin-left: auto;
  padding-right: 1rem;
  padding-left: 1rem;
}

@media (min-width: 720px) {
  .container {
    max-width: 720px;
  }
}

.fi {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.justify-between {
  justify-content: space-between;
}

.text-muted {
  color: rgb(155 155 155);
}

.text-foreground {
  color: rgb(78 78 78);
}

.text-sm {
  font-size: 0.875rem;
  line-height: 1.25rem;
}

.font-medium {
  font-weight: 500;
}

.tabular-nums {
  font-variant-numeric: tabular-nums;
}

.gap-1 {
  gap: 0.25rem;
}

.gap-2 {
  gap: 0.5rem;
}

.py-outer {
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
}

@media (min-width: 768px) {
  .py-outer {
    padding-top: 2.5rem;
    padding-bottom: 2.5rem;
  }
}

.dashed-lines {
  position: absolute;
  width: 100%;
  height: 100%;
  left: 50%;
  transform: translateX(-50%);
  top: 0;
  pointer-events: none;
}

.dashed-line {
  width: 0.5px;
  position: absolute;
  height: 100%;
  top: 0;
  border-width: 1px;
  border-style: dashed;
  border-color: rgb(241 241 241);
}

.dashed-line.left {
  left: 0;
}

.dashed-line.right {
  right: 0;
}

main > section {
  position: relative;
}

.sections {
  position: relative;
}

.sections > * + * {
  margin-top: 0;
}

.d-border {
  border-top-width: 1px;
  border-style: dashed;
  border-color: rgb(241 241 241);
  height: 0;
  color: inherit;
  margin: 0.625rem 0;
}

.card {
  color: rgb(155 155 155);
  background-color: rgb(255 255 255);
  border-radius: 0.5rem;
  padding: 1rem;
  border: 1px solid rgb(243 243 243);
}

.status-dot {
  width: 0.75rem;
  height: 0.75rem;
  border: 2px solid rgb(155 155 155);
  border-radius: 9999px;
}

.card-intro {
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

.profile-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.75rem;
  padding: 0.5rem 0;
}

.profile-avatar {
  width: 96px;
  height: 96px;
  border-radius: 9999px;
  object-fit: cover;
  border: 1px solid rgb(243 243 243);
}

.profile-sns {
  margin-top: 0.25rem;
}

.sns-link {
  color: rgb(155 155 155);
  transition: all 0.15s;
  padding: 0.25rem;
  display: flex;
}

.sns-link:hover {
  color: rgb(78 78 78);
}

.profile-name {
  font-size: 1.1rem;
  font-weight: 500;
  color: rgb(78 78 78);
}

.grid-6 {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.75rem;
}

.col-2 {
  grid-column: span 6 / span 6;
}

.col-4 {
  grid-column: span 6 / span 6;
}

.col-6 {
  grid-column: span 6 / span 6;
}

@media (min-width: 640px) {
  .col-2 {
    grid-column: span 2 / span 2;
  }
  .col-4 {
    grid-column: span 4 / span 4;
  }
}

.card-about {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.75rem;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

.about-greeting {
  font-size: 1.25rem;
  font-weight: 600;
  color: rgb(78 78 78);
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin-top: 0.25rem;
}

.tag {
  font-size: 0.75rem;
  padding: 0.15rem 0.5rem;
  background: rgb(243 243 243);
  color: rgb(155 155 155);
  border-radius: 9999px;
  font-weight: 400;
}

.card-list {
  padding: 0.75rem;
}

.card-history {
  padding: 1.25rem;
}

.mb-3 {
  margin-bottom: 0.75rem;
}

.history-items {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  border-left: 1px dashed rgb(220, 220, 220);
  padding-left: 1rem;
  margin-left: 0.25rem;
}

.history-item {
  position: relative;
  display: flex;
  align-items: flex-start;
}

.history-dot {
  position: absolute;
  left: -1.35rem;
  top: 0.35rem;
  width: 0.5rem;
  height: 0.5rem;
  background-color: #fafafa;
  border: 1px solid rgb(155 155 155);
  border-radius: 9999px;
}

.history-content {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.history-year {
  font-size: 0.75rem;
}

.history-text {
  color: rgb(78 78 78);
}

.list-items {
  display: flex;
  flex-direction: column;
}

.list-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  justify-content: space-between;
  font-size: 0.875rem;
  padding: 0.75rem;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  transition: all 0.3s;
  border-radius: 0.375rem;
  text-decoration: none;
  color: inherit;
}

.list-item:hover {
  background-color: rgb(250 250 250);
}

.list-item-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.list-item-body h3 {
  font-size: 0.875rem;
}

.list-item-body p {
  font-size: 0.8rem;
}

.space-y-2 > * + * {
  margin-top: 0.5rem;
}

.card-story {
  overflow: hidden;
  padding: 0;
}

.story-inner {
  display: flex;
  flex-direction: column;
  padding: 1rem;
}

@media (min-width: 640px) {
  .story-inner {
    flex-direction: row;
  }
}

.story-text {
  flex: 3;
  color: rgb(155 155 155);
}

.story-icons {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.5rem;
  padding-top: 0.75rem;
}

@media (min-width: 640px) {
  .story-icons {
    padding-top: 0;
  }
}

.footer-dot {
  width: 0.75rem;
  height: 0.75rem;
  border: 1px solid rgb(155 155 155);
  border-radius: 9999px;
}

.footer-link {
  color: rgb(155 155 155);
  transition: all 0.15s;
  padding: 0.25rem;
}

.footer-link:hover {
  color: rgb(78 78 78);
}

/* ── Shutter Animation ── */

.bento-card {
  position: relative;
}

.shutter {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: flex;
  flex-direction: column;
  pointer-events: none;
  border-radius: inherit;
  overflow: hidden;
}

.shutter-half {
  flex: 1;
  background: #fafafa;
  transition: transform 0.7s cubic-bezier(0.76, 0, 0.24, 1);
  position: relative;
}

.shutter-half::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: rgb(230 230 230);
  transition: opacity 0.4s 0.2s;
}

.shutter-top::after {
  bottom: 0;
}

.shutter-bottom::after {
  top: 0;
}

.shutter-top {
  transform-origin: top center;
}

.shutter-bottom {
  transform-origin: bottom center;
}

.shutter.open .shutter-top {
  transform: translateY(-105%);
}

.shutter.open .shutter-bottom {
  transform: translateY(105%);
}

.shutter.open .shutter-half::after {
  opacity: 0;
}

/* ── Mascot (clickable) ── */

.mascot-wrap {
  position: fixed;
  bottom: 0;
  right: 1rem;
  z-index: 50;
  width: 120px;
}

@media (min-width: 640px) {
  .mascot-wrap {
    width: 160px;
    right: 2rem;
  }
}

.mascot-link {
  display: block;
  transition: transform 0.2s ease;
}

.mascot-link:hover {
  transform: translateY(-4px);
}

.mascot-link img {
  width: 100%;
  height: auto;
  opacity: 0.85;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.06));
}
/* Mascot nudge bounce */
@keyframes mascot-nudge {
  0%, 100% { transform: translateY(0); }
  15% { transform: translateY(-8px); }
  30% { transform: translateY(0); }
  45% { transform: translateY(-5px); }
  60% { transform: translateY(0); }
}

.mascot-wrap.nudge .mascot-link {
  animation: mascot-nudge 0.8s ease;
}


/* OC face image click */
.oc-image.clickable {
  cursor: pointer;
}

/* ── Page Transition ── */

.page-overlay {
  position: fixed;
  inset: 0;
  background: #fafafa;
  z-index: 9999;
  pointer-events: none;
  opacity: 1;
  transition: opacity 0.4s ease;
}

.page-overlay.fade-out {
  opacity: 0;
}

/* ── OC Profile ── */

.back-link {
  color: rgb(155 155 155);
  transition: all 0.15s;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.875rem;
}

.back-link:hover {
  color: rgb(78 78 78);
}

.back-link svg {
  display: inline-block;
}

.oc-section-label {
  font-size: 0.8rem;
  font-weight: 500;
  color: rgb(155 155 155);
  letter-spacing: 0.05em;
}

.oc-profile {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

@media (min-width: 640px) {
  .oc-profile {
    flex-direction: row;
    align-items: center;
  }
}

.oc-image {
  flex-shrink: 0;
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
  overflow: hidden;
}

@media (min-width: 640px) {
  .oc-image {
    margin: 0;
  }
}

.oc-image img {
  width: 180%;
  height: auto;
  margin: -15% -40%;
  transform: translateX(22%);
}

.oc-details {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.oc-name-ja {
  font-size: 1.35rem;
  font-weight: 600;
  color: rgb(78 78 78);
}

.oc-name-en {
  font-size: 0.875rem;
  color: rgb(155 155 155);
  margin-top: 0.15rem;
}

.oc-table {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.875rem;
}

.oc-table-row {
  display: flex;
  gap: 1.5rem;
}

.oc-table-label {
  width: 80px;
  flex-shrink: 0;
  font-weight: 500;
  color: rgb(78 78 78);
  letter-spacing: 0.03em;
}

.oc-table-value {
  color: rgb(120 120 120);
}

.oc-description {
  font-size: 0.875rem;
  line-height: 1.8;
  color: rgb(100 100 100);
}

.oc-tag {
  font-size: 0.8rem;
  color: rgb(155 155 155);
}

.oc-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.75rem;
  font-size: 0.8rem;
}

.oc-links a {
  color: rgb(78 78 78);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.15s;
}

.oc-links a:hover {
  color: rgb(155 155 155);
}

.oc-links span {
  color: rgb(200 200 200);
}

::selection {
  background: rgba(155, 155, 155, 0.2);
}
