/* ==========================================================================
   Page: Single Posts (Refactored & Consolidated)
   ========================================================================== */

/* --- Base Layout for Single Pages --- */
.p-single {
  margin: 40px auto;
  padding: 40px 20px 60px;
  max-width: 1200px;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.p-single__content {
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  padding: 30px;
}

/* --- Common Elements --- */
.p-single__title {
  text-align: center;
  font-size: var(--font-2xl);
  font-weight: bold;
  margin: 0 0 20px 0;
  line-height: 1.4;
  color: var(--primary-text-color);
}

.p-single__thumbnail {
  margin: 30px auto;
  width: 100%;
  max-width: 780px;
  position: relative;
  text-align: center;
}

.p-single__thumbnail img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 4px;
  object-fit: cover;
  aspect-ratio: 16 / 9;
}

.p-single__body {
  display: flex;
  flex-direction: column;
  line-height: 1.8;
  color: var(--third-text-color);
  gap: 2rem;
}

.p-single__content--column .p-single__body h2 {
  font-weight: bold;
  /* color: var(--primary-color); */
  text-align: left;
  padding-bottom: 1rem;
  position: relative;
}

.p-single__content--column .p-single__body h2::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background-color: var(--primary-color);
  border-radius: 2px;
}

.p-single__content--column .p-single__body h3 {
  font-weight: bold;
  padding: 0.4rem 0.8rem;
  border-left: 3px solid var(--primary-color);
  color: var(--primary-text-color);
}

.p-single__body h2 {
  font-size: var(--font-2xl);
  font-weight: bold;
  padding-bottom: 10px;
}

.p-single__body h3 {
  font-size: var(--font-xl);
  font-weight: bold;
  padding-bottom: 8px;
}

.p-case-single__meta {
  margin-bottom: 25px;
  padding-bottom: 15px;
  border-bottom: 1px solid #eee;
}

.p-case-single__meta-label {
  font-weight: bold;
  color: #555;
  margin-right: 5px;
}

.p-case-single__meta-value {
  color: #333;
}

.p-single--seminar {
  max-width: 1000px;
}

.p-single__title--seminar {
  color: var(--primary-color);
  position: relative;
  margin-bottom: 60px;
}

.p-single__title--seminar:after {
  content: "";
  position: absolute;
  bottom: -30px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background-color: var(--primary-color);
  border-radius: 10px;
}

.p-single__thumbnail--expired img {
  filter: brightness(0.8);
}

.p-single__thumbnail-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(37, 32, 32, 0.8);
  z-index: 1;
  display: none;
}

.p-single__thumbnail--expired .p-single__thumbnail-overlay {
  display: block;
}

.p-single__expired-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-weight: bold;
  font-size: clamp(var(--font-4xl), 5vw, var(--font-6xl));
  letter-spacing: var(--default-letter-spacing);
  z-index: 2;
  margin: 0;
  display: none;
  text-align: center;
  white-space: nowrap;
}

.p-single__thumbnail--expired .p-single__expired-text {
  display: block;
}

.p-seminar-single__summary {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.p-single__body h2 {
  position: relative;
  border-bottom: none;
  padding-bottom: 0;
}

.p-single__body h2.border:after {
  content: "";
  position: absolute;
  bottom: -1rem;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background-color: var(--primary-color);
  border-radius: 10px;
}

.seminar-table table {
  width: 100%;
}

.seminar-table td {
  padding: 15px 0;
  border-top: none;
  border-left: none;
  border-right: none;
  border-bottom: 1px solid #ddd;
}

.seminar-table td:first-child {
  width: 20%;
  font-weight: 600;
  padding-right: 10px;
  vertical-align: top;
}

.p-single__column-cta {
  margin-top: 60px;
  padding-top: 50px;
  border-top: 1px solid #eee;
  color: #333;
}

.p-single__column-cta h2 {
  margin: 40px 0 30px;
  text-align: center;
}

.p-single__column-cta h3 {
  margin: 30px 0 15px;
  padding: 0 0 10px;
  border-left: 0;
  border-bottom: 2px solid #f99f9c;
  color: #333;
}

.p-single__column-cta h4 {
  margin: 30px 0 15px;
  padding: 10px;
  font-size: 18px;
  background: #f7f7f7;
  border-left: 5px solid #f99f9c;
}

.p-single__column-cta p {
  margin-bottom: 20px;
  font-size: 16px;
}

.p-single__column-cta strong {
  background: linear-gradient(transparent 70%, #ffdfdf 70%);
}

.p-single__column-cta-image {
  margin: 20px auto;
}

.p-single__column-cta-image img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.p-single__column-cta-phone {
  font-size: 20px;
  font-weight: 700;
  text-align: center;
}

.p-single__column-cta-phone span {
  display: inline-block;
  margin-left: 8px;
  font-size: 14px;
  font-weight: 400;
}

.p-single__cta-note,
.p-single__cta-check,
.p-single__cta-submit {
  text-align: center;
}

.p-single__cta-check .c-contact-form__checkbox {
  display: inline-flex;
}

@media screen and (max-width: 768px) {
  .p-single__title {
    font-size: var(--font-xl);
  }

  .p-single__content--column .p-single__body h1 {
    font-size: var(--font-2xl);
  }

  .p-single__content--column .p-single__body h2 {
    font-size: var(--font-xl);
    padding: 0.6rem 0.8rem;
  }

  .p-single__content--column .p-single__body h3 {
    font-size: var(--font-lg);
  }

  .p-single__column-cta {
    padding: 20px 15px 0;
  }

  .p-single__column-cta h2 {
    font-size: 20px;
  }

  .p-single__column-cta h3 {
    font-size: 18px;
  }

  .p-single__column-cta-phone {
    font-size: 18px;
  }

  .p-single__column-cta-phone span {
    display: block;
    margin: 8px 0 0;
  }
}

@media (max-width: 864px) {
  .seminar-table table,
  .seminar-table tbody,
  .seminar-table tr,
  .seminar-table td {
    display: block;
    width: 100%;
    text-align: left;
  }

  .seminar-table td {
    border-bottom: none;
    padding: 5px 0;
  }

  .seminar-table td:first-child {
    width: 100%;
    padding: 15px 0 5px 0;
    font-weight: 600;
  }

  .seminar-table td:last-child {
    width: 100%;
    padding: 5px 0 15px 0;
    border-bottom: 1px solid #ddd;
  }

  .seminar-table tr:last-child td:last-child {
    border-bottom: none;
  }
}
