/* =========================================================
   about.css — About page: central photo + scattered trait cards
   ========================================================= */

/* ---------------------------------------------------------
   Section — full-height positioning container
   Cards are absolutely placed within this.
   --------------------------------------------------------- */
.about {
  position: relative;
  /* Desktop: exactly fills the viewport between nav and footer */
  height: calc(100vh - var(--nav-height) - var(--footer-height));
  width: 100%;
  overflow: hidden;
}

/* ---------------------------------------------------------
   SVG connecting lines (injected by JS)
   Sits inside .about so it scrolls with the section.
   --------------------------------------------------------- */
#about-lines-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* ---------------------------------------------------------
   Central photo — sits below cards (z-index: 1 < wraps: 3)
   --------------------------------------------------------- */
.about__photo-wrap {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
}

.about__photo {
  display: block;
  width: auto;
  height: 65vh;
  max-height: 840px;
  object-fit: cover;
  border: 1px solid rgba(0, 229, 255, 0.35);
  background-color: #1a1a24; /* placeholder colour if image fails */
}

/* ---------------------------------------------------------
   Parallax wrappers — hold cards at absolute positions.
   JS drives their transform for the cursor parallax effect.
   --------------------------------------------------------- */
.about__parallax-wrap {
  position: absolute;
  width: 540px;
  will-change: transform;
  z-index: 3;
}

/*
   Desktop (>1200px) — cards sit fully within the viewport.
   Top two cards in the upper half; bottom two in the lower half.
   Positions are % of .about height (= 100vh - nav - footer).

   01 Passionate      — upper-left
   02 Organized       — upper-right
   03 Supportive      — lower-left
   04 Detail-Oriented — lower-right
*/
.about__parallax-wrap--1 { top:    4%;  left:  1%; }
.about__parallax-wrap--2 { top:    8%;  right: 1%; }
.about__parallax-wrap--3 { bottom: 4%;  left:  1%; }
.about__parallax-wrap--4 { bottom: 8%;  right: 1%; }

/* ---------------------------------------------------------
   Trait card
   --------------------------------------------------------- */
.about__card {
  position: relative;
  padding: 1.02rem 1.2rem;
  background-color: var(--color-surface);
  border: 1px solid rgba(0, 229, 255, 0.25);

  /* Entrance — JS adds .is-visible */
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity   600ms ease,
    transform 600ms cubic-bezier(0.22, 1, 0.36, 1);
}

.about__card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------------------------------------------------------
   ASCII corner decorations — all cyan
   --------------------------------------------------------- */
.about__corner {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1;
  color: var(--color-cyan);
  opacity: 0.6;
  pointer-events: none;
  user-select: none;
}

.about__corner--tl { top: -1px;    left:  -1px; }
.about__corner--tr { top: -1px;    right: -1px; }
.about__corner--bl { bottom: -1px; left:  -1px; }
.about__corner--br { bottom: -1px; right: -1px; }

/* ---------------------------------------------------------
   Card inner content.
   JS applies a separate (smaller) transform here for the
   text parallax effect — content shifts at ~half card speed.
   --------------------------------------------------------- */
.about__card-inner {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  will-change: transform;
}

/* ---------------------------------------------------------
   Index label (01 /, 02 /, …)
   --------------------------------------------------------- */
.about__index {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  color: var(--color-text-dim);
}

/* ---------------------------------------------------------
   Trait title — typed in by JS.
   2× the previous size (was var(--text-xl) = 2rem → 4rem).
   Allow natural wrapping within the card width.
   --------------------------------------------------------- */
.about__trait-title {
  font-family: var(--font-mono);
  font-size: 3.2rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-cyan);
  margin: 0;
  line-height: 1.1;
  min-height: 3.6rem; /* reserve space before typing */
  word-break: break-word;
  overflow-wrap: break-word;
}

/* ---------------------------------------------------------
   Blinking terminal cursor
   --------------------------------------------------------- */
.about__cursor {
  font-family: var(--font-mono);
  animation: about-blink 1s step-end infinite;
}

@keyframes about-blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

.about__cursor--done {
  animation: none;
  opacity: 0;
}

/* ---------------------------------------------------------
   Description — fades in after typing completes
   --------------------------------------------------------- */
.about__trait-desc {
  font-family: var(--font-mono);
  font-size: var(--text-body);
  line-height: 1.8;
  color: #c8c8b0;
  margin: 0;
  padding-left: 0.6rem;
  border-left: 2px solid var(--color-cyan);

  opacity: 0;
  transform: translateY(4px);
  transition:
    opacity   450ms ease,
    transform 450ms ease;
}

.about__trait-desc.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------------------------------------------------------
   Responsive.

   ≤1200px  Parallax layout replaced by single-column stack:
            photo at top, cards centered below in a column.
            Parallax disabled.
   ≤600px   Tighter gutters; smaller photo max-width.
   ≤400px   Extra-small screen adjustments.
   --------------------------------------------------------- */

/* ── ≤1200px: single-column stacked layout ── */
@media (max-width: 1200px) {
  .about {
    height: auto;
    overflow: visible;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-6);
    padding: var(--space-12) var(--space-8) var(--space-16);
  }

  .about__photo-wrap {
    position: static;
    transform: none;
    order: -1; /* photo at the top */
  }

  .about__photo {
    width: 100%;
    max-width: 400px;
    height: auto;
    aspect-ratio: 5 / 7; /* matches original 200×280 ratio */
  }

  /* Cards become static flex children, centered in the column */
  .about__parallax-wrap {
    position: static;
    width: 100%;
    max-width: 675px;
    transform: none !important; /* disable parallax */
  }

  .about__card-inner {
    transform: none !important;
  }

  #about-lines-svg {
    display: none;
  }

  .about__trait-title {
    font-size: 2.5rem;
    min-height: 2.8rem;
  }
}

/* ── ≤600px: tighter gutters and smaller photo ── */
@media (max-width: 600px) {
  .about {
    padding-inline: var(--space-4);
  }

  .about__photo {
    max-width: 320px;
  }

  .about__trait-title {
    font-size: 2rem;
    min-height: 2.2rem;
  }
}

@media (max-width: 400px) {
  .about__trait-title {
    font-size: 1.75rem;
  }
}

/* ── Desktop scroll gate — JS adds/removes scroll-locked on body ── */
@media (min-width: 1201px) {
  body.scroll-locked {
    overflow: hidden;
  }
}

/* ---------------------------------------------------------
   AT A GLANCE label
   --------------------------------------------------------- */
.about__glance-label {
  position: absolute;
  top: var(--space-6);
  left: 50%;
  transform: translateX(-50%);
  z-index: 4;
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  color: var(--color-cyan);
  white-space: nowrap;
  letter-spacing: 0.12em;
  pointer-events: none;
  user-select: none;
}

/* ---------------------------------------------------------
   Scroll for More button
   --------------------------------------------------------- */
.about__scroll-btn {
  position: absolute;
  bottom: var(--space-4);
  left: 50%;
  transform: translateX(-50%);
  z-index: 4;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 1.5rem;
  letter-spacing: 0.15em;
  color: #00e5ff;
  white-space: nowrap;
  animation: about-scroll-blink 1s steps(1) infinite;
}

@keyframes about-scroll-blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

/* ---------------------------------------------------------
   Detail section — 2×2 grid container
   --------------------------------------------------------- */
.about-detail {
  position: relative;
  z-index: 10;
  min-height: calc(100vh - var(--nav-height) - var(--footer-height));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-8);
}

.about-detail__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-8) var(--space-12);
  max-width: 960px;
  width: 100%;
}

/* Full-width cells that span both columns (rows 1 and 3) */
.about-detail__full {
  grid-column: 1 / -1;
}

.about-detail__heading {
  font-family: var(--font-heading);
  font-size: var(--text-md);
  color: var(--color-cyan);
  letter-spacing: 0.12em;
  margin: 0 0 var(--space-6);
}

.about-detail__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.about-detail__list li {
  font-family: var(--font-mono);
  font-size: var(--text-body);
  color: #c8c8b0;
  letter-spacing: 0.04em;
  padding-left: var(--space-3);
  border-left: 2px solid rgba(0, 229, 255, 0.25);
}

/* Mobile overrides */
@media (max-width: 1200px) {
  .about__glance-label {
    position: static;
    transform: none;
    text-align: center;
    white-space: normal;
    order: -2;
  }

  .about__scroll-btn {
    position: static;
    transform: none;
    display: block;
    margin: var(--space-4) auto 0;
    order: 99;
  }
}

@media (max-width: 760px) {
  .about-detail__grid {
    grid-template-columns: 1fr;
    gap: var(--space-8);
  }
}

/* ---------------------------------------------------------
   Currently — grid cell (bottom-left)
   --------------------------------------------------------- */
.about-currently {
  position: relative;
  display: flex;
  align-items: stretch;
}

.about-currently__frame {
  position: relative;
  padding: var(--space-8) var(--space-8);
  border: 1px solid rgba(0, 229, 255, 0.25);
  width: 100%;
}

.about-currently__corner {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 1rem;
  line-height: 1;
  color: var(--color-cyan);
  opacity: 0.6;
  pointer-events: none;
  user-select: none;
}

.about-currently__corner--tl { top: -1px;    left:  -1px; }
.about-currently__corner--tr { top: -1px;    right: -1px; }
.about-currently__corner--bl { bottom: -1px; left:  -1px; }
.about-currently__corner--br { bottom: -1px; right: -1px; }

.about-currently__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-6);
  text-align: center;
}

.about-currently__heading {
  font-family: var(--font-heading);
  font-size: var(--text-md);
  color: var(--color-cyan);
  letter-spacing: 0.12em;
  margin: 0;
}

.about-currently__body {
  font-family: var(--font-mono);
  font-size: var(--text-body);
  line-height: 1.8;
  color: #c8c8b0;
  margin: 0;
}

/* ---------------------------------------------------------
   Get in Touch — grid cell (bottom-right)
   --------------------------------------------------------- */
.about-contact {
  position: relative;
  display: flex;
  align-items: flex-start;
}

.about-contact__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-6);
  width: 100%;
  text-align: center;
}

.about-contact__heading {
  font-family: var(--font-heading);
  font-size: var(--text-md);
  color: #00e5ff;
  letter-spacing: 0.12em;
  margin: 0;
}

.about-contact__body {
  font-family: var(--font-mono);
  font-size: var(--text-body);
  line-height: 1.8;
  color: #c8c8b0;
  margin: 0;
}

.about-contact__email {
  font-family: var(--font-mono);
  font-size: var(--text-body);
  color: #00e5ff;
  text-decoration: none;
  letter-spacing: 0.06em;
  transition: opacity var(--transition-fast);
}

.about-contact__email:hover,
.about-contact__email:focus-visible {
  opacity: 0.75;
}

.about-contact__links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: var(--space-6);
  justify-content: center;
}

/* Override footer__link purple with cyan inside the contact cell */
.about-contact__social-link {
  color: #00e5ff;
}

.about-contact__social-link:hover,
.about-contact__social-link:focus-visible {
  color: rgba(0, 229, 255, 0.7);
}
