/* ═══════════════════════════════════════
   ABOUT — Kairdu v3
   ═══════════════════════════════════════ */

/* --- Navbar always dark on about page --- */
body:has(.about-header) .navbar {
  background: rgba(21, 31, 32, 0.95);
  backdrop-filter: blur(12px);
  padding: 12px 0;
  border-bottom: 1px solid var(--divider);
}

/* --- About header (parchment) --- */
.about-header {
  padding: 120px 0 64px;
  background: var(--light-bg);
  text-align: center;
  position: relative;
}

.about-header .kicker {
  position: relative; z-index: 1;
  color: var(--burnt-orange);
}

.about-header h1 {
  font-family: var(--font-headline);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--deep-petrol);
  position: relative; z-index: 1;
  margin: 0;
}

/* --- About sections --- */
.about-section {
  padding: 80px 0;
}

/* --- Row container (perspective for polaroid depth) --- */
.about-row {
  max-width: 800px;
  perspective: 600px;
  transform-style: preserve-3d;
}

.about-row--reverse {
  max-width: 800px;
}

/* --- About text (replaces about-content for row layouts) --- */
.about-text h2 {
  margin-bottom: 28px;
}

.about-text p,
.about-row > p {
  margin-bottom: 1.4em;
  line-height: 1.8;
  position: relative;
  z-index: 1;
}

.section-light .about-text p {
  color: var(--light-body);
}

.section-dark .about-text p {
  color: var(--text-secondary);
}

/* --- Full-width content (no polaroid) --- */
.about-content {
  max-width: 720px;
}

.about-content h2 {
  margin-bottom: 28px;
}

.about-content p {
  margin-bottom: 1.4em;
  line-height: 1.8;
}

.section-light .about-content p {
  color: var(--light-body);
}

.section-dark .about-content p {
  color: var(--text-secondary);
}

/* --- Polaroid photos (scattered on desk, real frame overlays) --- */
.polaroid {
  position: relative;
  width: 320px;
  background: transparent !important;
  padding: 0 !important;
  overflow: hidden;
  transition: transform 0.5s ease, filter 0.5s ease;
  transform-style: preserve-3d;
  filter: drop-shadow(4px 8px 16px rgba(0, 0, 0, 0.25));
}

.polaroid:hover {
  /* no box-shadow — frame PNG provides the visual edge */
}

/* Frame image sits on top */
.polaroid .polaroid-frame {
  position: relative;
  width: 100%;
  display: block;
  z-index: 2;
  pointer-events: none;
}

/* Photo sits behind the frame, inside the opening — per-frame positioning */
.polaroid .polaroid-photo {
  position: absolute;
  object-fit: cover;
  z-index: 1;
}

/* Frame 1: 428x500, opening at x:35 y:37 w:355 h:394 */
.polaroid.frame-1 .polaroid-photo {
  top: 7.4%;
  left: 8.2%;
  width: 82.9%;
  height: 78.8%;
}

/* Frame 3: 527x600, opening at x:46 y:47 w:430 h:470 */
.polaroid.frame-3 .polaroid-photo {
  top: 7.8%;
  left: 8.7%;
  width: 81.6%;
  height: 78.3%;
}

/* Frame 1: caption position */
.polaroid.frame-1 .polaroid-caption {
  top: 86.4%;
  transform: translateY(-50%);
}

/* Frame 3: caption position */
.polaroid.frame-3 .polaroid-caption {
  top: 88%;
  transform: translateY(-50%);
}

/* Frame 4: caption position */
.polaroid.frame-4 .polaroid-caption {
  top: 83.4%;
  transform: translateY(-50%);
}

/* Handwriting fonts — each polaroid gets a different one via .hw-* class */
.polaroid.hw-1 .polaroid-caption {
  font-family: 'Nothing You Could Do', cursive;
  font-size: 0.95rem;
}
.polaroid.hw-2 .polaroid-caption {
  font-family: 'Rock Salt', cursive;
  font-size: 0.7rem;
}
.polaroid.hw-3 .polaroid-caption {
  font-family: 'Homemade Apple', cursive;
  font-size: 0.85rem;
}
.polaroid.hw-4 .polaroid-caption {
  font-family: 'Reenie Beanie', cursive;
  font-size: 1.15rem;
}
.polaroid.hw-5 .polaroid-caption {
  font-family: 'Waiting for the Sunrise', cursive;
  font-size: 0.95rem;
}

/* Frame 4: 736x866, opening at x:84 y:94 w:570 h:627 */
.polaroid.frame-4 .polaroid-photo {
  top: 10.9%;
  left: 11.4%;
  width: 77.4%;
  height: 72.4%;
}

.polaroid-caption {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 3;
  display: block;
  text-align: center;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.78rem;
  font-weight: 500;
  color: #888;
  margin: 0;
  letter-spacing: 0.02em;
}

/* --- Polaroid stacks (scattered pile effect) --- */
.polaroid-stack {
  position: relative;
  width: 420px;
  height: 400px;
  transform-style: preserve-3d;
  overflow: visible;
  z-index: 10;
}

/* Polygons computed from actual photo visual envelopes after 3D rotation.
   Text hugs the silhouette tightly for the protrude effect. */
.polaroid-stack.stack-right {
  float: right;
  margin: 0 -40px 24px 20px;
  transform: rotateX(40deg) rotateY(-12deg) rotate(30deg);
  shape-outside: polygon(
    13% 19%,
    100% 19%,
    100% 100%,
    18% 99%,
    13% 71%,
    -2% 68%,
    -2% 25%
  );
  shape-margin: 6px;
}

.polaroid-stack.stack-left {
  float: left;
  margin: 0 20px 24px -40px;
  transform: rotateX(40deg) rotateY(12deg) rotate(-30deg);
  shape-outside: polygon(
    0% 25%,
    79% 25%,
    92% 33%,
    92% 74%,
    30% 74%,
    4% 70%
  );
  shape-margin: 6px;
}

.polaroid-stack.stack-right-steep {
  float: right;
  margin: 0 -40px 24px 20px;
  transform: rotateX(45deg) rotateY(-15deg) rotate(35deg);
  shape-outside: polygon(
    1% 23%,
    100% 23%,
    100% 86%,
    25% 86%,
    -9% 84%,
    -9% 41%,
    1% 26%
  );
  shape-margin: 6px;
}

.polaroid-stack.stack-left-steep {
  float: left;
  margin: 0 20px 24px -40px;
  transform: rotateX(45deg) rotateY(15deg) rotate(-35deg);
  shape-outside: polygon(
    0% 24%,
    76% 24%,
    92% 31%,
    92% 75%,
    31% 75%,
    -5% 75%
  );
  shape-margin: 6px;
}

/* Individual polaroids within a stack — scattered on the plane */
.polaroid-stack .polaroid {
  position: absolute;
  width: 220px;
  transform-style: preserve-3d;
  /* x/y position and local rotation set via inline style */
}

/* Thickness spacing between stacked photos */
.polaroid-stack .polaroid:nth-child(1) { z-index: 5; }
.polaroid-stack .polaroid:nth-child(2) { z-index: 4; }
.polaroid-stack .polaroid:nth-child(3) { z-index: 3; }
.polaroid-stack .polaroid:nth-child(4) { z-index: 2; }
.polaroid-stack .polaroid:nth-child(5) { z-index: 1; }

/* Float right into text — tossed on table, heavy lean like template */
.polaroid-right {
  float: right;
  margin: 0 -40px 24px 32px;
  transform: rotateX(40deg) rotateY(-12deg) rotate(30deg);
}
.polaroid-right:hover {
  transform: rotateX(15deg) rotateY(-4deg) rotate(8deg) scale(1.04);
}

/* Float left into text */
.polaroid-left {
  float: left;
  margin: 0 32px 24px -40px;
  transform: rotateX(40deg) rotateY(12deg) rotate(-30deg);
}
.polaroid-left:hover {
  transform: rotateX(15deg) rotateY(4deg) rotate(-8deg) scale(1.04);
}

/* Steeper tilt variants */
.polaroid-right-steep {
  float: right;
  margin: 0 -40px 24px 32px;
  transform: rotateX(45deg) rotateY(-15deg) rotate(35deg);
}
.polaroid-right-steep:hover {
  transform: rotateX(15deg) rotateY(-4deg) rotate(8deg) scale(1.04);
}

.polaroid-left-steep {
  float: left;
  margin: 0 32px 24px -40px;
  transform: rotateX(45deg) rotateY(15deg) rotate(-35deg);
}
.polaroid-left-steep:hover {
  transform: rotateX(15deg) rotateY(4deg) rotate(-8deg) scale(1.04);
}

/* Clearfix for floated polaroids */
.about-row::after {
  content: "";
  display: table;
  clear: both;
}

@media (max-width: 768px) {
  .polaroid {
    width: 240px;
  }
  .polaroid-right,
  .polaroid-right-steep {
    float: none;
    margin: 0 auto 28px;
    transform: rotate(2deg);
  }
  .polaroid-left,
  .polaroid-left-steep {
    float: none;
    margin: 0 auto 28px;
    transform: rotate(-2deg);
  }
}

/* --- Anchor lines (emphasized statements) --- */
.about-anchor {
  font-family: var(--font-headline);
  font-weight: 600;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  margin-top: 1.6em;
}

.section-dark .about-anchor {
  color: var(--warm-parchment);
}

.section-light .about-anchor {
  color: var(--deep-petrol);
}

/* --- Quote block --- */
.about-quote {
  font-family: var(--font-headline);
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--amber);
  text-align: center;
  padding: 32px 0;
  margin: 24px 0;
  border-top: 1px solid var(--divider);
  border-bottom: 1px solid var(--divider);
  line-height: 1.4;
}

/* --- Blog link --- */
.about-blog-link {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--deep-petrol);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.section-dark .about-blog-link {
  color: var(--light-petrol);
}

.about-blog-link:hover {
  color: var(--amber);
}

/* --- Blockquote --- */
.about-blockquote {
  border-left: 3px solid var(--burnt-orange);
  padding: 20px 28px;
  margin: 32px 0;
  background: rgba(0, 0, 0, 0.03);
  border-radius: 0 8px 8px 0;
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-style: italic;
  color: var(--deep-forest);
  line-height: 1.7;
}

/* --- Three words grid --- */
.about-intro {
  margin-bottom: 32px;
}

.word-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 40px;
}

@media (max-width: 768px) {
  .word-grid { grid-template-columns: 1fr; }
}

.word-card {
  background: var(--warm-parchment);
  border: 1px solid #dddad2;
  border-top: 3px solid var(--forest-green);
  border-radius: 10px;
  padding: 28px 24px;
}

.word-card h3 {
  font-family: var(--font-headline);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--deep-forest);
  margin-bottom: 4px;
}

.kanji {
  font-weight: 400;
  font-size: 0.9rem;
  color: var(--light-muted);
  margin-left: 8px;
}

.word-meaning {
  font-family: var(--font-headline);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--burnt-orange);
  margin-bottom: 12px;
}

.word-card p:last-child {
  font-size: 0.92rem;
  color: var(--light-muted);
  line-height: 1.6;
  margin-bottom: 0;
}

/* --- Logo float (no polaroid frame) --- */
.logo-float {
  float: left;
  margin: 0 40px 24px -20px;
  width: 280px;
  filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.12));
  transform: none;
  transition: transform 0.4s ease;
}

.logo-float:hover {
  transform: scale(1.06);
}

.logo-float img {
  width: 100%;
  height: auto;
}

/* --- CTA section --- */
.about-cta {
  padding: 80px 0;
}

.about-cta h2 {
  margin-bottom: 24px;
}
.section-light.about-cta h2 { color: var(--deep-petrol); }
.section-dark.about-cta h2 { color: var(--parchment); }

/* --- About footer --- */
.about-footer {
  background: var(--deep-forest);
  border-top: 1px solid var(--divider);
  padding: 40px 0;
  text-align: center;
}

/* --- Amber kicker (for Mission/Vision) --- */
.amber-kicker {
  color: var(--amber) !important;
  letter-spacing: 0.2em;
  font-weight: 500;
  margin-bottom: 16px;
}

/* --- Mission/Vision statements --- */
.about-statement {
  font-size: 1.15rem;
  line-height: 1.7;
  margin-bottom: 1.2em;
}

.section-dark .about-statement { color: var(--text-secondary); }
.section-light .about-statement { color: var(--light-body); }

/* --- Back link on founder-story header --- */
.about-back-link {
  margin-top: 24px;
  font-size: 0.95rem;
}
.about-back-link a {
  color: var(--burnt-orange);
  text-decoration: none;
  border-bottom: 1px solid rgba(206, 118, 53, 0.3);
  padding-bottom: 2px;
  transition: border-color 0.2s;
}
.about-back-link a:hover { border-bottom-color: var(--burnt-orange); }

.about-back-link-large {
  font-family: var(--font-headline);
  font-size: 1.2rem;
  margin: 0;
}
.about-back-link-large a {
  color: var(--deep-petrol);
  text-decoration: none;
  border-bottom: 2px solid rgba(47, 94, 107, 0.3);
  padding-bottom: 4px;
  transition: border-color 0.2s;
}
.about-back-link-large a:hover { border-bottom-color: var(--deep-petrol); }

/* --- Team section --- */
.team-heading {
  text-align: center;
  margin-bottom: 12px;
}
.team-intro {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 56px;
  line-height: 1.7;
}
.section-dark .team-intro { color: var(--text-secondary); }
.section-light .team-intro { color: var(--light-body); }
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 48px;
  max-width: 720px;
  margin: 0 auto;
}
.team-card {
  display: block;
  text-align: center;
  text-decoration: none;
  color: inherit;
  padding: 24px 16px;
  transition: transform 0.3s ease;
}
.team-card:hover {
  transform: translateY(-4px);
}
.team-card--static {
  cursor: default;
}
.team-card--static:hover {
  transform: none;
}
.team-avatar {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  overflow: hidden;
  margin: 0 auto 20px;
  border: 3px solid var(--amber);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}
.team-avatar--chris { background: var(--deep-petrol); }
.team-avatar--poppy { background: var(--burnt-orange); }
.team-avatar--poppy img { object-position: center top; }
.team-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.1);
  transform-origin: center;
}
.team-name {
  font-family: var(--font-headline);
  font-size: 1.35rem;
  font-weight: 600;
  margin: 0 0 4px;
}
.section-dark .team-name { color: var(--parchment); }
.section-light .team-name { color: var(--deep-petrol); }

.team-role {
  font-size: 0.95rem;
  color: var(--burnt-orange);
  font-style: italic;
  margin: 0 0 16px;
  letter-spacing: 0.02em;
}
.section-dark .team-role { color: var(--amber); }

.team-meta {
  list-style: none;
  padding: 0;
  margin: 0;
}
.team-meta li {
  font-size: 0.9rem;
  line-height: 1.8;
}
.section-dark .team-meta li { color: var(--text-secondary); }
.section-light .team-meta li { color: var(--light-body); }

.team-card:hover .team-meta li:last-child {
  color: var(--burnt-orange);
}
