/**
 * About Page Component CSS
 * Shared styles for About page and Project detail subpage
 *
 * Design Guidelines Compliance:
 * ✅ CSS token hierarchy (uses about-tokens.css via AboutLayout)
 * ✅ BEM naming convention
 * ✅ No border boxing
 * ✅ Responsive design
 *
 * Dependencies:
 * - /assets/css/tokens/about-tokens.css (imported via AboutLayout)
 *
 * BEM Structure:
 * - .hero (hero section base)
 * - .section (content sections)
 * - .media-placeholder (image placeholders)
 * - .nav-button (navigation buttons)
 * - .cta-button (call-to-action)
 * - .notice (important notice section - about.astro only)
 * - .tech-stack (tech stack list - project.astro only)
 */

/* ==========================================================================
   HERO SECTION (Shared Base)
   ========================================================================== */
.hero {
  text-align: center;
  background: linear-gradient(135deg,
    rgba(42, 42, 62, 0.4) 0%,
    rgba(30, 30, 46, 0.6) 100%);
}

.hero__container {
  max-width: 800px;
  margin: 0 auto;
}

.hero__title {
  font-family: var(--font-family-system);
  font-size: 3rem;
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-text-header);
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.hero__perex {
  font-family: var(--font-family-about);
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--color-text-meta);
  max-width: 600px;
  margin: 0 auto;
}

.hero__nav {
  display: flex;
  justify-content: center;
  gap: 2rem;
}

.hero__link {
  font-family: var(--font-family-system);
  font-size: 1rem;
  color: var(--color-ui-primary);
  text-decoration: none;
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--color-ui-primary);
  border-radius: 4px;
  transition: all 0.3s ease;
}

.hero__link:hover {
  color: var(--color-text-header);
  border-color: var(--color-text-header);
}

/* ==========================================================================
   MAIN CONTENT SECTIONS (Shared Layout)
   ========================================================================== */
.about-content {
  padding: 0 var(--margin-horizontal);        /* 3rem (48px) */
}

.section {
  padding: 6rem 0 0 0;
  scroll-margin-top: 2rem;
}

.section__container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 4rem;
  align-items: start;
}

/* Image Right Layout (default) */
.section--image-right .section__container {
  grid-template-columns: 1.5fr 1fr;
}

/* Image Left Layout */
.section--image-left .section__container {
  grid-template-columns: 1fr 1.5fr;
}

.section--image-left .section__media {
  order: -1;
}

.section__content {
  padding: 2rem 0;
}

.section__heading {
  font-family: var(--font-family-system);
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--color-text-header);
  margin-bottom: 2rem;
  letter-spacing: -0.01em;
}

.section__text {
  font-family: var(--font-family-about);
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--color-text-primary);
  text-align: justify;
}

.section__text p {
  margin-bottom: 1.5rem;
}

.section__text p:last-child {
  margin-bottom: 0;
}

.section__media {
  position: relative;
  padding-top: 9.75rem;
}

/* ==========================================================================
   MEDIA PLACEHOLDERS (Shared)
   ========================================================================== */
.media-placeholder {
  width: 100%;
  aspect-ratio: 4 / 5;
  background: linear-gradient(135deg,
    rgba(204, 204, 255, 0.08) 0%,
    rgba(166, 166, 166, 0.08) 100%);
  border: 1px solid var(--color-panel-border);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.3),
    0 2px 4px rgba(0, 0, 0, 0.2);
}

.media-placeholder:hover {
  border-color: rgba(204, 204, 255, 0.4);
  background: linear-gradient(135deg,
    rgba(204, 204, 255, 0.12) 0%,
    rgba(166, 166, 166, 0.12) 100%);
}

.media-placeholder::after {
  content: attr(data-label);
  font-family: var(--font-family-system);
  font-size: 1.25rem;
  letter-spacing: 0.3em;
  color: rgba(166, 166, 166, 0.3);
  font-weight: 700;
}

/* Real image - inherits panel look from placeholder */
.media-image {
  width: 100%;
  display: block;
  border-radius: 8px;
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.3),
    0 2px 4px rgba(0, 0, 0, 0.2);
}

.media-placeholder--wide {
  aspect-ratio: 16 / 10;
}

.media-caption {
  font-family: var(--font-family-system);
  font-size: 0.9rem;
  color: var(--color-text-meta);
  font-style: italic;
  text-align: center;
}

/* ==========================================================================
   CTA BUTTON (Shared)
   ========================================================================== */
.cta-button {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 2rem;
  padding: 0.75rem 1.5rem;
  font-family: var(--font-family-system);
  font-size: 1rem;
  color: var(--color-ui-primary);
  background: transparent;
  border: 1px solid var(--color-ui-primary);
  border-radius: 4px;
  text-decoration: none;
  transition: all 0.3s ease;
}

.cta-button:hover {
  color: var(--color-text-header);
  border-color: var(--color-text-header);
}

.cta-button__arrow {
  font-size: 1.25rem;
  transition: transform 0.3s ease;
}

.cta-button:hover .cta-button__arrow {
  transform: translateX(4px);
}

/* ==========================================================================
   NAVIGATION BUTTONS (Shared Base + Variants)
   ========================================================================== */
.about-navigation {
  display: flex;
  justify-content: center;
  margin-top: 4rem;
  padding-bottom: 3rem;
}

.page-navigation {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  margin-top: 7rem;
  padding-bottom: 4rem;
}

.nav-button {
  font-family: var(--font-family-system);
  font-size: 1rem;
  letter-spacing: 0.02em;
  color: var(--color-ui-primary);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  padding: 0.75em 1.5em;
  border: 1px solid var(--color-ui-primary);
  border-radius: 4px;
  transition: all 0.3s ease;
}

.nav-button:hover {
  color: var(--color-text-header);
  border-color: var(--color-text-header);
}

.nav-button--previous::before {
  content: "←";
}

.nav-button__icon {
  font-size: 1.25rem;
  transition: transform 0.3s ease;
}

.nav-button--back:hover .nav-button__icon {
  transform: translateX(-4px);
}

.nav-button--home:hover .nav-button__icon {
  transform: translateY(-4px);
}

.nav-button__text {
  font-weight: 500;
}

/* ==========================================================================
   COPYRIGHT SECTION (about.astro specific)
   ========================================================================== */
.copyright {
  margin-top: 8rem;
  padding: 3rem 2rem;
  border-top: 1px solid rgba(166, 166, 166, 0.15);
  text-align: center;
}

.copyright__container {
  max-width: 800px;
  margin: 0 auto;
}

.copyright__text {
  font-family: var(--font-family-about);
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--color-text-meta);
  margin-bottom: 0.75rem;
}

.copyright__text:last-child {
  margin-bottom: 0;
}

.copyright__link {
  color: var(--color-ui-primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.copyright__link:hover {
  color: var(--color-text-header);
  text-decoration: underline;
}

/* ==========================================================================
   TECH STACK LIST (project.astro specific)
   ========================================================================== */
.tech-stack {
  margin: 2rem 0;
  padding: 2rem;
  background: rgba(42, 42, 62, 0.3);
  border-left: 3px solid var(--color-ui-primary);
  border-radius: 4px;
}

.tech-stack__item {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1rem;
  align-items: baseline;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(166, 166, 166, 0.1);
}

.tech-stack__item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.tech-stack__item:first-child {
  padding-top: 0;
}

.tech-stack__label {
  font-family: var(--font-family-system);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--color-ui-primary);
  letter-spacing: 0.05em;
}

.tech-stack__value {
  font-family: var(--font-family-about);
  font-size: 1rem;
  color: var(--color-text-primary);
}

/* ==========================================================================
   MARKDOWN CONTENT STYLES
   ========================================================================== */

/* Links in markdown content */
.section__text a {
  color: var(--color-ui-primary);
  text-decoration: none;
  transition: color 0.2s ease;
  padding-bottom: 0.3em;
  background-image: var(--underline-02-img);
  background-size: 100% var(--underline-02-height);
  background-position: bottom center;
  background-repeat: no-repeat;
}

.section__text a:hover {
  color: var(--color-text-header);
  background-image: var(--underline-01-img);
  background-size: 100% var(--underline-01-height);
}

/* H2 subsections (in Project Vision) */
.section__text h2 {
  font-family: var(--font-family-system);
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--color-text-header);
  margin-top: 2.5rem;
  margin-bottom: 1.25rem;
  line-height: 1.3;
}

.section__text h2:first-child {
  margin-top: 0;
}

/* Bullet lists */
.section__text ul {
  margin: 1.5rem 0;
  padding-left: 1.5rem;
  list-style-type: disc;
  color: var(--color-text-primary);
}

.section__text ul li {
  margin-bottom: 0.75rem;
  line-height: 1.8;
}

.section__text ul li:last-child {
  margin-bottom: 0;
}

/* Strong emphasis */
.section__text strong {
  font-weight: 600;
  color: var(--color-text-header);
}

/* Code inline */
.section__text code {
  font-family: var(--font-family-system);
  font-size: 0.95em;
  background: rgba(42, 42, 62, 0.5);
  padding: 0.2em 0.4em;
  border-radius: 3px;
  color: var(--color-ui-primary);
}

/* ==========================================================================
   RESPONSIVE DESIGN
   ========================================================================== */
@media (max-width: 968px) {
  .hero__title {
    font-size: 2.25rem;
  }

  .hero__perex {
    font-size: 1rem;
  }

  .hero__nav {
    flex-wrap: wrap;
    gap: 1rem;
  }

  .section {
    padding: 4rem 0 0 0;
  }

  .section__container {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .section--image-right .section__container,
  .section--image-left .section__container {
    grid-template-columns: 1fr;
  }

  .section--image-left .section__media {
    order: 0;
  }

  .section__media {
    padding-top: 0;
  }

  .section__heading {
    font-size: 2rem;
  }

  .section__text {
    font-size: 1.0625rem;
  }

  .section__text h2 {
    font-size: 1.5rem;
    margin-top: 2rem;
  }

  .tech-stack__item {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .page-navigation {
    flex-direction: column;
    gap: 1rem;
    margin-top: 5rem;
  }

  .nav-button {
    width: 100%;
    justify-content: center;
  }

  .copyright {
    margin-top: 5rem;
  }
}

@media (max-width: 640px) {
  .hero__title {
    font-size: 1.875rem;
  }

  .hero__perex {
    font-size: 1rem;
  }

  .hero__nav {
    flex-direction: column;
  }

  .hero__link {
    width: 100%;
    text-align: center;
  }

  .about-content {
    padding: 0 var(--margin-horizontal-mobile); /* 1.5rem (24px) */
  }

  .section {
    padding: 3rem 0 0 0;
  }

  .section__heading {
    font-size: 1.75rem;
  }

  .section__text h2 {
    font-size: 1.375rem;
  }

  .media-placeholder::after {
    font-size: 1rem;
    letter-spacing: 0.2em;
  }

  .cta-button {
    width: 100%;
    justify-content: center;
  }

  .tech-stack {
    padding: 1.5rem;
  }

  .tech-stack__label {
    font-size: 0.875rem;
  }

  .tech-stack__value {
    font-size: 0.9375rem;
  }
}

/* ==========================================================================
   APPRECIATION SECTION (about.astro specific)
   ========================================================================== */
.appreciation {
  margin-top: 6rem;
  padding: 4rem 0;
  text-align: center;
  border-top: 1px solid rgba(166, 166, 166, 0.15);
}

.appreciation__container {
  max-width: 800px;
  margin: 0 auto;
}

.appreciation__container p:first-of-type {
  font-family: var(--font-family-handwritten);
  font-size: 2rem;
  line-height: 1.6;
  color: var(--color-light-orange);
  margin-bottom: 2rem;
}

.appreciation__container p:not(:first-of-type) {
  font-family: var(--font-family-about);
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--color-text-primary);
  margin-bottom: 0;
}

.appreciation__container a {
  color: var(--color-ui-primary);
  text-decoration: none;
  transition: color 0.2s ease;
  padding-bottom: 0.3em;
  background-image: var(--underline-02-img);
  background-size: 100% var(--underline-02-height);
  background-position: bottom center;
  background-repeat: no-repeat;
}

.appreciation__container a:hover {
  color: var(--color-text-header);
  background-image: var(--underline-01-img);
  background-size: 100% var(--underline-01-height);
}

/* Responsive - Appreciation Section */
@media (max-width: 968px) {
  .appreciation {
    margin-top: 4rem;
    padding: 3rem 0;
  }

  .appreciation__container p:first-of-type {
    font-size: 1.25rem;
  }
}

@media (max-width: 640px) {
  .appreciation {
    margin-top: 3rem;
    padding: 2rem var(--margin-horizontal-mobile);
  }

}

/* ==========================================================================
   IMPORTANT NOTICE SECTION (about.astro specific)
   ========================================================================== */
.notice {
  margin-top: 6rem;
  padding: 3rem 0;
  border-top: 1px solid rgba(166, 166, 166, 0.15);
}

.notice__container {
  padding: 0 100px;
}

.notice__title {
  font-family: var(--font-family-system);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--color-text-meta);
  margin-bottom: 1.5rem;
  text-transform: uppercase;
}

.notice__content {
  font-family: var(--font-family-system);
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--color-text-meta);
}

.notice__content ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.notice__content li {
  margin-bottom: 1rem;
  padding-left: 1.25rem;
  position: relative;
}

.notice__content li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--color-text-meta);
}

.notice__content li:last-child {
  margin-bottom: 0;
}

.notice__content strong {
  font-weight: 600;
}

.notice__content em {
  font-style: italic;
}

.notice__content a {
  color: var(--color-text-meta);
  text-decoration: none;
  border-bottom: 1px solid rgba(166, 166, 166, 0.3);
  transition: all 0.2s ease;
}

.notice__content a:hover {
  color: var(--color-text-header);
  border-bottom-color: var(--color-text-header);
}

.notice__content > p:last-child {
  margin-top: 1.5rem;
}

/* Responsive - Notice Section */
@media (max-width: 968px) {
  .notice {
    margin-top: 4rem;
  }

  .notice__container {
    padding: 0 50px;
  }
}

@media (max-width: 640px) {
  .notice {
    margin-top: 3rem;
    padding: 2rem 0;
  }

  .notice__container {
    padding: 0 var(--margin-horizontal-mobile);
  }

  .notice__title {
    font-size: 0.875rem;
  }

  .notice__content {
    font-size: 0.8125rem;
  }
}

/* ==========================================================================
   NOTES
   ========================================================================== */

/**
 * This CSS file contains SHARED styles used by both About pages.
 * Page-specific styles remain in the .astro file's <style> blocks:
 *
 * about.astro:
 * - .hero (full padding: 8rem horizontal 6rem)
 * - .hero__perex (larger font: 1.25rem, margin-bottom: 3rem)
 *
 * project.astro:
 * - .hero--compact (compact padding: 6rem horizontal 4rem)
 * - .hero__perex (standard size, no extra margin)
 *
 * This separation allows:
 * 1. Zero duplication (DRY principle)
 * 2. Easier maintenance of shared patterns
 * 3. Page-specific customization when needed
 */
