/* ============================================================
   PAGE-SPECIFIC LAYOUT — homepage sections, services, case studies
   ============================================================ */

/* ── HOME: HERO ── */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  padding: 56px 0 64px;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -10%; right: -10%;
  width: 60%; height: 60%;
  background: radial-gradient(circle, rgba(var(--accent-rgb), 0.05) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  align-items: center;
  width: 100%;
}
@media (min-width: 1024px) {
  .hero-grid { grid-template-columns: 3fr 2fr; gap: 64px; }
}
@media (max-width: 1023px) {
  .hero-visual { order: -1; }
}
/* Grid items default to min-width:auto, which lets a large unbreakable
   heading word (e.g. a surname at --text-display size) force the column —
   and the whole page — wider than the viewport. Let them shrink instead. */
.hero-grid > * { min-width: 0; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(59, 122, 87, 0.1);
  border: 1px solid rgba(59, 122, 87, 0.3);
  border-radius: var(--radius-full);
  color: var(--success);
  font-size: var(--text-caption);
  font-weight: 500;
  margin-bottom: 24px;
}

.hero-heading { margin-bottom: 20px; overflow-wrap: break-word; }
.hero-heading .hero-name-last { display: inline-block; padding-left: 0.9em; }

.hero-subheading {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-subtle);
}

.hero-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.hero-lead { max-width: 520px; margin-bottom: 32px; }

.about-paragraph {
  max-width: 640px;
  color: var(--text-secondary);
  font-size: var(--text-lead);
  line-height: 1.75;
  margin: 40px 0;
  padding: 28px 32px;
  border: 1px dashed var(--border-subtle);
  border-radius: var(--radius-md);
}

.now-list { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.now-list li { color: var(--text-secondary); font-size: 0.95rem; }
.now-list li span { color: var(--text-primary); font-weight: 600; }

.margin-note {
  font-family: var(--font-hand);
  color: var(--accent);
  font-size: 1.15rem;
  margin-top: 10px;
  transform: rotate(-1deg);
}

.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }

.hero-meta { color: var(--text-muted); }

.hero-visual {
  align-self: start;
}
.hero-image-wrap {
  position: relative;
  max-width: 92px;
  margin: 0 auto;
}
@media (min-width: 560px) {
  .hero-image-wrap { max-width: 140px; }
}
@media (min-width: 1024px) {
  .hero-image-wrap { max-width: 150px; }
}
.hero-image-frame {
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-strong);
  background: linear-gradient(160deg, var(--accent-glow), transparent 60%), var(--bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-image-frame img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: 0.6; }
.hero-image-frame .initial { font-size: 4rem; font-weight: 700; color: var(--accent); }

/* Sits below the photo, in normal flow — used to overlap the bottom-right
   corner of the image (position:absolute), which cropped the face on
   narrow/tall photos and overlapped the name heading beneath it on mobile. */
.hero-floating-card {
  width: fit-content;
  max-width: 100%;
  margin: 16px auto 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  box-shadow: var(--shadow-glow);
  display: flex;
  align-items: center;
  gap: 12px;
}
.hero-floating-card .icon-wrap {
  width: 36px; height: 36px; flex-shrink: 0;
  border-radius: var(--radius-sm);
  background: var(--accent-glow);
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
}
.hero-floating-card .years { font-weight: 700; color: var(--text-primary); font-size: 0.95rem; }
.hero-floating-card .employer { color: var(--text-muted); font-size: var(--text-caption); }

/* ── HOME: TRUST BAR ── */
.trust-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 64px;
}
.trust-label {
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: var(--text-caption);
  color: var(--text-muted);
  flex-shrink: 0;
}
.trust-items { display: flex; flex-wrap: wrap; gap: 10px; }
.trust-pill {
  padding: 6px 16px; border-radius: var(--radius-full);
  background: var(--bg-elevated); border: 1px solid var(--border-subtle);
  font-size: var(--text-small); color: var(--text-secondary);
  white-space: nowrap;
}
.trust-pill strong { color: var(--text-primary); font-weight: 600; }

/* ── SECTION SCAFFOLDING ── */
.section-block { margin: 96px 0; }
.section-intro { color: var(--text-secondary); max-width: 620px; margin-bottom: 32px; }
.section-cta-row { margin-top: 32px; text-align: center; }

/* ── SERVICES PREVIEW ── */
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.service-card { display: flex; flex-direction: column; height: 100%; }
.service-card .icon-wrap {
  width: 44px; height: 44px; border-radius: var(--radius-sm);
  background: var(--accent-glow); color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
}
.service-card .card-title { font-size: var(--text-h3); }
.service-card .card-desc { flex: 1; margin: 8px 0 16px; }

/* ── FEATURED CASE STUDIES ── */
.case-study-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  padding: 24px;
  margin-bottom: 20px;
}
@media (min-width: 768px) {
  .case-study-row { grid-template-columns: 0.9fr 1.1fr; align-items: center; }
  .case-study-row:nth-child(even) .case-study-image { order: 2; }
}
.case-study-image {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-overlay);
  border: 1px solid var(--border-subtle);
}
.case-study-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.case-study-meta { font-family: 'JetBrains Mono', monospace; font-size: 0.72rem; color: var(--accent); margin-bottom: 8px; }
.case-study-result {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: var(--text-small);
}
.case-study-result strong { color: var(--accent); }

/* ── TESTIMONIALS ── */
.testimonial-card { display: flex; flex-direction: column; gap: 14px; }
.testimonial-quote-icon { color: var(--accent); opacity: 0.3; }
.testimonial-message { color: var(--text-secondary); font-size: var(--text-lead); line-height: 1.6; }
.testimonial-footer { display: flex; align-items: center; gap: 14px; padding-top: 14px; border-top: 1px solid var(--border-subtle); }
.testimonial-avatar {
  width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
}
.testimonial-avatar-fallback {
  width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0;
  background: var(--accent-glow); color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700;
}
.testimonial-name { font-weight: 600; color: var(--text-primary); font-size: 0.9rem; }
.testimonial-role { color: var(--text-muted); font-size: var(--text-caption); }

/* ── SKILLS CATEGORY CARDS ── */
.skills-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
@media (min-width: 640px) {
  .skill-category-featured { grid-column: span 2; padding: 32px; }
}
.skill-category-card .icon-wrap {
  width: 40px; height: 40px; border-radius: var(--radius-sm);
  background: var(--accent-glow); color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 14px;
}
.skill-category-list { color: var(--text-secondary); font-size: var(--text-small); line-height: 1.7; margin-top: 8px; }

/* ── BLOG PREVIEW CARDS ── */
.blog-preview-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.blog-preview-card { display: flex; flex-direction: column; height: 100%; }
.blog-preview-meta { display: flex; gap: 12px; align-items: center; margin-top: auto; padding-top: 12px; color: var(--text-muted); font-size: var(--text-caption); }

/* ── FINAL CTA ── */
.final-cta {
  background: var(--bg-elevated);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  text-align: center;
  padding: 96px 24px;
  margin: 96px 0 0;
}
.final-cta h2 { margin-bottom: 16px; }
.final-cta p { max-width: 520px; margin: 0 auto 32px; }
.final-cta .hero-actions { justify-content: center; }

/* ── SERVICES PAGE ── */
.pkg-card { display: flex; flex-direction: column; height: 100%; }
.pkg-name { font-family: 'JetBrains Mono', monospace; font-size: 0.72rem; color: var(--accent); margin-bottom: 8px; letter-spacing: 0.05em; }
.pkg-price { margin-top: auto; padding-top: 16px; border-top: 1px solid var(--border-subtle); }
.pkg-price .amount { font-weight: 700; color: var(--text-primary); font-size: 1rem; }
.pkg-price .timeline { font-size: 0.78rem; color: var(--text-muted); margin-top: 4px; }
.ideal-for { font-size: 0.82rem; color: var(--text-muted); margin: 12px 0; }
.step-num {
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  background: var(--accent-glow); border: 1px solid rgba(var(--accent-rgb),0.35);
  color: var(--accent); display: flex; align-items: center; justify-content: center;
  font-family: 'JetBrains Mono', monospace; font-weight: 700; font-size: 0.85rem;
}
.cta-card {
  text-align: center;
  padding: 48px 24px;
  margin-top: 24px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
}
.cta-card p.card-title { font-size: 1.2rem; margin-bottom: 18px; }

/* ── CASE STUDIES PAGE ── */
.cs-label { font-family: 'JetBrains Mono', monospace; font-size: 0.72rem; color: var(--accent); margin-bottom: 6px; }
.cs-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px,1fr)); gap: 20px; margin-bottom: 18px; }
.cs-columns ul { padding-left: 18px; color: var(--text-secondary); font-size: 0.88rem; line-height: 1.7; }

/* ── CONTACT PAGE ── */
.contact-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 32px; align-items: start; }
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-side-links { display: flex; flex-direction: column; gap: 14px; font-size: 0.9rem; }
.contact-side-links a { display: flex; align-items: center; gap: 10px; color: var(--accent); text-decoration: none; }
.contact-meta { font-size: 0.85rem; color: var(--text-muted); line-height: 1.9; }
.contact-meta strong { color: var(--text-primary); }
