/* =========================================================
   Single
   83 Hero + 81 Right Sidebar + Article Area
========================================================= */

body.single {
  --soho-single-sidebar-width: 150px;
}

.l-soho-main--single {
  --soho-single-sidebar-width: 150px;
}

/* Single本文エリアは、右にSidebar列を持つ */
.l-soho-main--single .l-soho-main-layout--sidebar-right {
  --soho-single-sidebar-width: 176px;

  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--soho-single-sidebar-width);
  align-items: start;
}

/* 本文エリア */
.l-soho-main--single .l-soho-content-area {
  min-width: 0;
}

/* Singleでは fixed Sidebar を sticky として扱う */
.l-soho-main--single .l-soho-sidebar--fixed.l-soho-sidebar--right {
  position: sticky;
  top: 0;
  right: auto;
  bottom: auto;

  grid-column: 2;
  width: var(--soho-single-sidebar-width);
  min-width: var(--soho-single-sidebar-width);
  height: 100vh;
  align-self: start;
}

/* =========================================================
   Single Article
   Text-first readable board
========================================================= */

.l-soho-main--single .p-soho-single-article {
  position: relative;

  width: min(1080px, calc(100% - 72px));
  margin: 0 auto;
  padding: 64px 0 88px;
}

/* 壁に掛かった薄いボード */
.l-soho-main--single .p-soho-single-article::before {
  content: "";
  position: absolute;
  inset: 34px -34px 46px;
  z-index: 0;

  background:
    linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.18) 0%,
      rgba(238, 232, 218, 0.30) 28%,
      rgba(198, 190, 172, 0.28) 100%
    );

  border: 1px solid rgba(27, 26, 23, 0.13);
  box-shadow:
    0 22px 54px rgba(49, 11, 13, 0.24),
    0 4px 18px rgba(137, 29, 33, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    inset 0 -1px 0 rgba(49, 11, 13, 0.10);

  pointer-events: none;
}

/* ボードのかすかな質感 */
.l-soho-main--single .p-soho-single-article::after {
  content: "";
  position: absolute;
  inset: 34px -34px 46px;
  z-index: 0;

  background:
    repeating-linear-gradient(
      90deg,
      rgba(27, 26, 23, 0.018) 0,
      rgba(27, 26, 23, 0.018) 1px,
      transparent 1px,
      transparent 9px
    ),
    radial-gradient(
      circle at 18% 24%,
      rgba(137, 29, 33, 0.045),
      transparent 28%
    );

  opacity: 0.8;
  pointer-events: none;
}

.l-soho-main--single .p-soho-single-header,
.l-soho-main--single .p-soho-single-body,
.l-soho-main--single .p-soho-single-nav {
  position: relative;
  z-index: 1;
}

.l-soho-main--single .p-soho-single-header {
  margin-bottom: 34px;
  padding: 0 34px 22px;
  border-bottom: 1px solid rgba(27, 26, 23, 0.14);
}

.l-soho-main--single .p-soho-single-meta {
  margin: 0 0 14px;

  font-family: var(--soho-font-body);
  font-size: 12px;
  line-height: 1.4;
  letter-spacing: 0.08em;

  color: var(--soho-red);
  opacity: 0.78;
}

.l-soho-main--single .p-soho-single-title {
  margin: 0;

  font-family: var(--soho-font-body);
  font-size: clamp(20px, 1.8vw, 28px);
  line-height: 1.6;
  letter-spacing: 0.01em;
  font-weight: 400;

  color: var(--soho-ink);

  overflow-wrap: anywhere;
  word-break: normal;
}

.l-soho-main--single .p-soho-single-body {
  position: relative;
  z-index: 1;

  padding: 0 34px;

  font-size: clamp(15px, 1.05vw, 16px);
  line-height: 1.95;
  letter-spacing: 0.018em;

  color: var(--soho-ink-soft);
}

.l-soho-main--single[data-lang="en"] .p-soho-single-body,
.l-soho-main--single[data-lang="ru"] .p-soho-single-body {
  line-height: 1.85;
  letter-spacing: 0.006em;
}

.l-soho-main--single .p-soho-single-thumbnail--inline {
  float: right;

  width: min(32%, 300px);
  margin: 0 0 22px 30px;
}

.l-soho-main--single .p-soho-single-thumbnail__image {
  display: block;
  width: 100%;
  height: auto;

  border: 1px solid rgba(27, 26, 23, 0.12);
  box-shadow: 0 12px 26px rgba(49, 11, 13, 0.13);
}

.l-soho-main--single .p-soho-single-body p {
  margin: 0 0 1.45em;
}

.l-soho-main--single .p-soho-single-body h2,
.l-soho-main--single .p-soho-single-body h3 {
  margin: 2.2em 0 0.9em;

  font-family: var(--soho-font-body);
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: 0.01em;

  color: var(--soho-ink);
}

.l-soho-main--single .p-soho-single-body h2 {
  font-size: clamp(19px, 1.7vw, 24px);
}

.l-soho-main--single .p-soho-single-body h3 {
  font-size: clamp(17px, 1.45vw, 21px);
}

.l-soho-main--single .p-soho-single-body a {
  color: var(--soho-red);
  text-decoration: none;
  border-bottom: 1px solid rgba(137, 29, 33, 0.34);
}

.l-soho-main--single .p-soho-single-body ul,
.l-soho-main--single .p-soho-single-body ol {
  margin: 0 0 1.55em;
  padding-left: 1.4em;
}

.l-soho-main--single .p-soho-single-body li {
  margin: 0 0 0.55em;
}

.l-soho-main--single .p-soho-single-body hr {
  width: 72%;
  height: 1px;
  margin: 3.2em auto;

  border: 0;
  background:
    linear-gradient(
      90deg,
      transparent 0%,
      rgba(49, 11, 13, 0.18) 18%,
      rgba(122, 74, 34, 0.46) 50%,
      rgba(49, 11, 13, 0.18) 82%,
      transparent 100%
    );
}

.l-soho-main--single .p-soho-single-body hr::after {
  content: "";
  display: block;

  width: 6px;
  height: 6px;
  margin: -3px auto 0;

  background: #7a4a22;
  transform: rotate(45deg);
  opacity: 0.72;
}

/* =========================================================
   Single Navigation
   Older / Newer cards
========================================================= */

.l-soho-main--single .p-soho-single-nav {
  position: relative;
  z-index: 1;

  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;

  margin: 64px 18px 0;
  padding-top: 30px;

  border-top: 1px solid rgba(49, 11, 13, 0.18);
}

.l-soho-main--single .p-soho-single-nav__item {
  min-width: 0;
}

.l-soho-main--single .p-soho-single-nav__item--newer {
  text-align: right;
}

.l-soho-main--single .p-soho-single-nav__item--older {
  text-align: left;
}

.l-soho-main--single .p-soho-single-nav a {
  display: grid;
  gap: 8px;

  min-width: 0;
  padding: 13px 16px;

  color: var(--soho-ink);
  text-decoration: none;

  background:
    linear-gradient(
      135deg,
      rgba(49, 11, 13, 0.045) 0%,
      rgba(180, 141, 75, 0.045) 100%
    );

  border: 1px solid rgba(49, 11, 13, 0.15);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.20),
    0 8px 18px rgba(49, 11, 13, 0.07);

  transition:
    background 0.25s ease,
    border-color 0.25s ease,
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.l-soho-main--single .p-soho-single-nav a:hover {
  background:
    linear-gradient(
      135deg,
      rgba(49, 11, 13, 0.075) 0%,
      rgba(180, 141, 75, 0.065) 100%
    );

  border-color: rgba(49, 11, 13, 0.28);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 10px 22px rgba(49, 11, 13, 0.11);
}

.l-soho-main--single .p-soho-single-nav__item--newer a:hover {
  transform: translateX(3px);
}

.l-soho-main--single .p-soho-single-nav__item--older a:hover {
  transform: translateX(-3px);
}

.l-soho-main--single .p-soho-single-nav__label {
  display: inline-flex;
  gap: 9px;
  align-items: center;

  font-size: 11px;
  line-height: 1.2;
  letter-spacing: 0.10em;

  color: var(--soho-red);
  opacity: 0.9;
}

.l-soho-main--single .p-soho-single-nav__item--newer .p-soho-single-nav__label {
  justify-content: flex-end;
}

.l-soho-main--single .p-soho-single-nav__item--older .p-soho-single-nav__label {
  justify-content: flex-start;
}

.l-soho-main--single .p-soho-single-nav__mark {
  display: inline-block;

  width: 0;
  height: 0;

  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;

  opacity: 1;
  filter: drop-shadow(0 1px 1px rgba(49, 11, 13, 0.26));

  transition:
    opacity 0.25s ease,
    transform 0.25s ease;
}

.l-soho-main--single .p-soho-single-nav__item--newer .p-soho-single-nav__mark {
  border-left: 9px solid #7a4a22;
}

.l-soho-main--single .p-soho-single-nav__item--older .p-soho-single-nav__mark {
  border-right: 9px solid #7a4a22;
}

.l-soho-main--single .p-soho-single-nav__title {
  display: block;
  overflow: hidden;

  max-width: 100%;

  font-size: 13px;
  line-height: 1.55;
  letter-spacing: 0.012em;

  color: rgba(27, 26, 23, 0.74);
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* =========================================================
   Responsive
========================================================= */

@media screen and (max-width: 960px) {
  body.single,
  .l-soho-main--single {
    --soho-single-sidebar-width: 0px;
  }

  .l-soho-main--single .l-soho-main-layout--sidebar-right {
    display: block;
  }

  .l-soho-main--single .l-soho-sidebar--fixed.l-soho-sidebar--right {
    position: relative;
    top: auto;
    right: auto;
    bottom: auto;

    width: 100%;
    min-width: 0;
    height: auto;
  }

  .l-soho-main--single .p-soho-single-article {
    width: min(100% - 36px, 720px);
    padding: 44px 0 68px;
  }

  .l-soho-main--single .p-soho-single-article::before,
  .l-soho-main--single .p-soho-single-article::after {
    inset: 22px -14px 34px;
  }

  .l-soho-main--single .p-soho-single-header {
    margin-bottom: 28px;
    padding: 0 20px 20px;
  }

  .l-soho-main--single .p-soho-single-title {
    font-size: clamp(20px, 5.4vw, 28px);
    line-height: 1.55;
  }

  .l-soho-main--single .p-soho-single-body {
    padding: 0 20px;
    font-size: 15px;
    line-height: 1.9;
  }

  .l-soho-main--single .p-soho-single-thumbnail--inline {
    float: none;

    width: 100%;
    max-width: 400px;
    margin: 0 auto 28px;
  }

  .l-soho-main--single .p-soho-single-nav {
    grid-template-columns: 1fr;
    gap: 14px;

    margin: 46px 12px 0;
    padding-top: 24px;
  }

  .l-soho-main--single .p-soho-single-nav__item--newer,
  .l-soho-main--single .p-soho-single-nav__item--older {
    text-align: left;
  }

  .l-soho-main--single .p-soho-single-nav__item--newer .p-soho-single-nav__label {
    justify-content: flex-start;
  }

  .l-soho-main--single .p-soho-single-nav__title {
    font-size: 13px;
    line-height: 1.55;
  }
}
