/* ==========================================================================
   About page
   Builds on styles.css (tokens, nav, background, tags, footer).
   Layout follows a photo stack → story → timeline → credentials shelf → toolkit flow.
     mobile  < 720px   timeline stacks (date over thumbnail + copy)
     tablet  720–1079  date | rail | thumbnail | copy
     desktop ≥ 1080    wider measure, stickers beside the story
   ========================================================================== */

.about {
  /* Text colours match the case studies (case-study.css): one slate ink for headings + body,
     the badge grey for small uppercase labels */
  --ab-ink: #475569;          /* = --cs-ink */
  --ab-ink-strong: #475569;   /* headings, titles and bold lead-ins use the same ink, as in the case studies */
  --ab-muted: rgba(15, 23, 42, 0.7); /* = --cs-muted (badges) */
  --ab-accent: #006ebd;
  --ab-rule: rgba(19, 58, 94, 0.14);
  --ab-warm: #e7b791;
  --font-title: "Crimson Pro", Georgia, "Times New Roman", serif; /* all About page titles, as in the case studies */
}

.ab {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--ab-ink);
}

/* ---------- Photo stack ---------- */
.ab-hero {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  padding: 24px 20px 32px;
}
/* Three overlapping photos, no frames: the portrait sits straight in front,
   the other two fan out behind it. Every photo is the same 4:5 size
   (--ph wide). The box is as wide as one photo; the side photos overhang it. */
.ab-photos {
  --ph: min(230px, 58vw);    /* photo width (old portrait size: 230 phone / 260 tablet / 280 desktop) */
  --spread: 44%;             /* how far the side photos slide out; on phones their outer edges may bleed off-screen (the page clips them) so faces stay visible */
  position: relative;
  width: var(--ph);
  aspect-ratio: 4 / 5;
  margin-block: 8px 20px; /* room for the tilted corners */
}
.ab-photos__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 14px;
  box-shadow: 0 22px 44px -20px rgba(19, 58, 94, 0.45), 0 2px 8px rgba(15, 23, 42, 0.08);
  transition: rotate 0.5s var(--ease), translate 0.5s var(--ease);
}
.ab-photos__img--left  { translate: calc(var(--spread) * -1) 4%; rotate: -8deg; }
.ab-photos__img--right { translate: var(--spread) 4%; rotate: 8deg; }
.ab-photos__img--main  { z-index: 1; }
@media (hover: hover) {
  /* Hover: the side photos fan out a little farther apart */
  .ab-photos:hover .ab-photos__img--left  { translate: calc(var(--spread) * -1.32) 2%; rotate: -11deg; }
  .ab-photos:hover .ab-photos__img--right { translate: calc(var(--spread) * 1.32) 2%; rotate: 11deg; }
}


/* ---------- Sections + headings ---------- */
.ab-section {
  width: 100%;
  max-width: 880px;
  display: flex;
  flex-direction: column;
  gap: 32px;
  padding: 48px 20px;
  scroll-margin-top: 16px;
}
.ab-section--last { padding-bottom: 88px; }

.ab-heading {
  color: var(--ab-ink-strong);
  font-family: var(--font-title);
  font-weight: 500;
  font-size: 40px;
  line-height: 1.1;
  letter-spacing: -1px;
  text-align: center;
}
.ab-heading__accent { color: var(--ab-accent); font-style: italic; }

/* ---------- How I got here ---------- */
.ab-story__body {
  width: 100%;
  max-width: 600px;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.ab-story__row { position: relative; }
.ab-story p {
  font-size: 16px;
  line-height: 1.6;
  text-wrap: pretty;
}
.ab-story strong { color: var(--ab-ink-strong); font-weight: 600; }

/* Tilted name stickers beside each paragraph (desktop only) */
.ab-sticker {
  display: none;
  position: absolute;
  top: 4px;
  padding: 10px 14px;
  border: 1px solid #fff;
  border-radius: 12px;
  background: var(--tag-bg);
  box-shadow: 0 10px 24px -12px rgba(19, 58, 94, 0.4);
  color: var(--tag-ink);
  font-family: var(--font-eyebrow);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.5px;
  white-space: nowrap;
}
.ab-sticker--left  { right: calc(100% + 40px); rotate: -6deg; }
.ab-sticker--right { left: calc(100% + 40px); rotate: 5deg; }
/* A logo instead of a text pill: just the wordmark, same spot and tilt */
.ab-sticker--logo {
  width: 92px;
  height: auto;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  top: 8px;
  filter: drop-shadow(0 8px 12px rgba(19, 58, 94, 0.3)); /* follows each logo's outline, same blue-grey as the cards */
}
.ab-sticker--ucf { width: 72px; top: -4px; } /* taller mark than the wordmarks, so a little narrower */
/* Thin black wordmarks (Travel + Leisure, To & Fro) sit on the lightest part of the page:
   a tight contact shadow plus a deeper, softer one so they lift as much as the UCF mark */
.ab-sticker--logo:not(.ab-sticker--ucf) {
  filter: drop-shadow(0 2px 2px rgba(19, 58, 94, 0.35)) drop-shadow(0 8px 14px rgba(19, 58, 94, 0.5));
} /* taller mark than the wordmarks, so a little narrower */

/* ---------- Where I've been (timeline) ---------- */
.ab-timeline {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
}
.ab-item {
  position: relative;
  display: grid;
  grid-template-columns: 88px 1fr;
  grid-template-areas:
    "date date"
    "thumb body";
  column-gap: 16px;
  row-gap: 10px;
  padding: 24px 0;
  border-top: 1px solid var(--ab-rule);
}
.ab-item:last-child { border-bottom: 1px solid var(--ab-rule); }

.ab-item__date {
  grid-area: date;
  color: var(--ab-muted); /* small uppercase label, like the case-study badges */
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.91px;
  text-transform: uppercase;
  white-space: nowrap;
}
.ab-item__thumb {
  grid-area: thumb;
  align-self: start;
  width: 88px;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 14px;
  background: rgba(0, 115, 185, 0.14);
  box-shadow: 0 10px 24px -14px rgba(19, 58, 94, 0.45);
}
.ab-item__thumb picture { display: contents; }
.ab-item__thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease); }
.ab-item__thumb--tofro { background: var(--ab-warm); }
.ab-item__thumb--tl { background: #111; } /* matches the logo's backdrop while it loads */
.ab-item__thumb--budget { background: #e8f7ff; } /* matches the logo's backdrop while it loads */
.ab-item__thumb--desiheart { background: #2879b4; } /* matches the logo's blue backdrop while it loads */
@media (hover: hover) {
  .ab-item:hover .ab-item__thumb img { transform: scale(1.05); }
}

.ab-item__body { grid-area: body; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.ab-item__title {
  color: var(--ab-ink-strong);
  font-family: var(--font-title);
  font-weight: 600; /* Crimson Pro SemiBold, 18px at every size */
  font-size: 18px;
  line-height: 1.25;
}
.ab-item__sep { margin-inline: 2px; } /* title, company and dot all share the title's #0F172A */
.ab-item__summary { color: var(--ab-ink-strong); font-weight: 300; font-size: 15px; line-height: 1.5; text-wrap: pretty; } /* DM Sans Light, 15px at every size */



/* ---------- Credentials shelf ---------- */
.ab-shelf {
  position: relative;
  margin-top: 48px; /* same breathing room as a new section */
  padding: 0 8px;
}
/* "My Education": same style as the section headings, with the section gap beneath it */
.ab-shelf__title { margin-bottom: 32px; }
.ab-shelf__items {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 16px;
}
.ab-cred {
  width: min(190px, 44vw);
  aspect-ratio: 3 / 3.6;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border-radius: 6px 10px 10px 6px;
  box-shadow: inset 6px 0 0 rgba(255, 255, 255, 0.35), 0 14px 28px -14px rgba(19, 58, 94, 0.45);
  transition: translate 0.35s var(--ease);
}
.ab-cred--cert   { background: linear-gradient(160deg, #ffffff 0%, #e8f0fe 100%); rotate: -2deg; }
.ab-cred--degree { background: linear-gradient(160deg, #f6e4d6 0%, var(--ab-warm) 100%); rotate: 1.5deg; }
@media (hover: hover) {
  .ab-cred:hover { translate: 0 -8px; }
}
.ab-cred__kind {
  color: var(--ab-muted); /* badge grey, as in the case studies */
  font-family: var(--font-eyebrow);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}
.ab-cred__name {
  color: var(--ab-ink-strong);
  font-family: var(--font-title);
  font-weight: 600;
  font-size: 21px;
  line-height: 1.15;
  text-wrap: balance;
}
.ab-cred__meta { margin-top: auto; color: var(--ab-ink); font-size: 12px; line-height: 1.4; }

.ab-shelf__board {
  display: block;
  height: 14px;
  margin-top: -4px;
  border: 1px solid #fff;
  border-radius: 4px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(237, 245, 252, 0.8));
  box-shadow: 0 16px 30px -12px rgba(19, 58, 94, 0.35);
}


/* ==========================================================================
   Tablet
   ========================================================================== */
@media (min-width: 720px) {
  .ab-hero { padding: 32px 48px 40px; gap: 32px; }
  .ab-photos { --ph: 260px; --spread: 44%; }

  .ab-section { padding: 64px 48px; gap: 44px; }
  .ab-heading { font-size: 54px; }
  .ab-story p { font-size: 17px; }
  /* Labels beside the story from tablet up: narrow the text so each label has ~120px of room on its side */
  .ab-story__body { max-width: min(600px, calc(100% - 240px)); }
  .ab-sticker { display: block; }
  .ab-sticker--left  { right: calc(100% + 24px); }
  .ab-sticker--right { left: calc(100% + 24px); }

  /* date | rail | thumbnail | copy */
  .ab-item {
    grid-template-columns: 128px 140px 1fr;
    grid-template-areas: "date thumb body";
    column-gap: 28px;
    padding: 32px 0;
    border: 0;
  }
  .ab-item:last-child { border: 0; }
  /* Vertical rail just right of the dates */
  .ab-item::before {
    content: "";
    position: absolute;
    left: 142px;
    top: 0;
    bottom: 0;
    width: 1px;
    background: var(--ab-rule);
  }
  .ab-item::after {
    content: "";
    position: absolute;
    left: 138px;
    top: 40px;
    width: 9px;
    height: 9px;
    border: 2px solid #fff;
    border-radius: 50%;
    background: var(--ab-accent);
    box-shadow: 0 0 0 3px rgba(0, 110, 189, 0.15);
  }
  .ab-item__date { padding-top: 6px; text-align: right; white-space: normal; }
  .ab-item__thumb { width: 140px; margin-left: 14px; border-radius: 16px; }
  .ab-shelf { margin-top: 64px; padding: 0 40px; }
  .ab-shelf__title { margin-bottom: 44px; }
  .ab-shelf__items { gap: 28px; }
  .ab-cred { width: 200px; padding: 20px; }
  .ab-cred__name { font-size: 23px; }
}

/* ==========================================================================
   Desktop
   ========================================================================== */
@media (min-width: 1080px) {
  .page:has(.ab) .navbar { padding: 16px 48px; }
  .ab-hero { padding: 24px 48px 48px; }
  .ab-photos { --ph: 280px; --spread: 48%; } /* same size as the old framed portrait (280 × 350) */

  .ab-section { padding: 88px 48px; gap: 56px; }
  .ab-section--last { padding-bottom: 160px; }
  .ab-heading { font-size: 66px; letter-spacing: -2px; }

  .ab-story__body { gap: 32px; }
  .ab-story p { font-size: 18px; }
  .ab-sticker--left  { right: calc(100% + 40px); }
  .ab-sticker--right { left: calc(100% + 40px); }

  .ab-item { grid-template-columns: 140px 160px 1fr; column-gap: 32px; padding: 36px 0; }
  .ab-item::before { left: 156px; }
  .ab-item::after { left: 152px; top: 44px; }
  .ab-item__thumb { width: 160px; margin-left: 16px; }
  .ab-shelf { margin-top: 88px; }
  .ab-shelf__title { margin-bottom: 56px; }
  .ab-cred { width: 220px; }
  .ab-cred__name { font-size: 25px; }
}

@media (prefers-reduced-motion: reduce) {
  .ab-photos__img, .ab-item__thumb img, .ab-cred { transition: none; }
}
