/* ==========================================================================
   Projects hub + Linkface project page: isolated add-on.
   Existing styles.css is untouched. Loaded only on /projects and /linkface.
   ========================================================================== */

/* ---------- Shared page intro ---------- */
.projects-page .page-intro,
.linkface-page .page-intro {
  padding: calc(var(--header-h) + 64px) 0 40px;
  background: var(--cream);
  border-bottom: 1px solid var(--hair);
}
.page-intro h1 {
  max-width: 900px;
  margin: 0 0 18px;
  font-family: var(--serif);
  font-size: clamp(2.4rem, 5vw, 4.4rem);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.03em;
}
.page-intro h1 em { color: var(--brass-ink); font-style: italic; }
.page-intro .lede { max-width: 720px; font-size: 1.05rem; line-height: 1.7; color: var(--muted); }

/* The site body is dark-themed (cream text). On these light sections force ink
   so headings and outline buttons stay readable. */
.projects-page .page-intro h1,
.linkface-page .project-hero h1 { color: var(--ink); }
.projects-page .page-intro h1 em,
.linkface-page .project-hero h1 em { color: var(--brass-ink); }
.projects-page .btn:not(.btn--solid),
.linkface-page .btn:not(.btn--solid) { color: var(--ink); border-color: var(--hair-strong); }

/* Keep labels and headings on the same left edge (styles.css centres .trusted-label). */
.projects-page .page-intro .trusted-label,
.linkface-page .project-hero .trusted-label { text-align: left; margin-top: 0; }

/* styles.css gives .features-head a 62ch grid + browser default h2 margins;
   reset both so section headings line up with the grid below. */
.projects-page .features-head,
.linkface-page .features-head {
  display: block;
  max-width: none;
  margin: 0 0 24px;
}
.projects-page .features-head h2,
.linkface-page .features-head h2 { margin: 0; }

/* Tighten the empty space between the intro and the project cards. */
.projects-page .section--projects { padding-top: 52px; }
.projects-page .project-grid { padding: 28px 0 64px; }

/* ---------- Two featured plates on the home page ---------- */
.projects-on-home {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-top: 8px;
}
/* Both featured plates share one top edge; icons line up with their text. */
.projects-on-home .project-plate { display: flex; }
.projects-on-home .project-plate-inner {
  flex: 1;
  align-items: start;
}

/* ---------- Projects hub grid ---------- */
.project-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  padding: 56px 0 72px;
}
.project-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 30px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-md);
  background: var(--ivory);
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s var(--ease-out-soft), border-color 0.25s var(--ease-out-soft);
}
.project-card:hover { transform: translateY(-4px); border-color: var(--brass); }
.project-card__top { display: flex; align-items: center; gap: 16px; }
.project-card__icon {
  width: 72px;
  height: 72px;
  object-fit: contain;
  border-radius: 16px;
  background: var(--cream);
  border: 1px solid var(--hair);
  padding: 8px;
  flex: 0 0 auto;
}
.project-card h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.65rem;
  font-weight: 500;
  letter-spacing: -0.02em;
}
.project-card__kind {
  margin: 4px 0 0;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass-ink);
}
/* Real product screenshot used as a card preview, not just a logo. */
.project-card__preview {
  position: relative;
  display: block;
  overflow: hidden;
  border: 1px solid var(--hair);
  border-radius: 10px;
  background: var(--cream);
}
.project-card__preview img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.4s var(--ease-out-soft);
}
.project-card__preview:hover img { transform: scale(1.04); }
.project-card__preview span {
  position: absolute;
  left: 0;
  bottom: 0;
  padding: 6px 12px;
  background: rgba(38, 6, 11, 0.88);
  color: var(--cream);
  font-size: 0.72rem;
  letter-spacing: 0.05em;
}
.project-card p { margin: 0; line-height: 1.7; color: var(--muted); }
.project-card__tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; }
.project-card__tags span {
  padding: 6px 11px;
  border: 1px solid var(--hair);
  border-radius: 999px;
  font-size: 0.75rem;
  color: var(--ink);
  background: var(--cream);
}
.project-card .btn { align-self: flex-start; }

/* ---------- Linkface project hero ---------- */
.linkface-page .project-hero {
  padding: calc(var(--header-h) + 56px) 0 56px;
  background: var(--cream);
  border-bottom: 1px solid var(--hair);
}
.linkface-hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: start;
}
.linkface-hero-grid h1 {
  margin: 0 0 20px;
  font-family: var(--serif);
  font-size: clamp(2.2rem, 4.4vw, 3.7rem);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.03em;
}
.linkface-hero-grid h1 em { color: var(--brass-ink); font-style: italic; }
.linkface-hero-grid .lede { font-size: 1.05rem; line-height: 1.75; color: var(--muted); margin-bottom: 24px; }
.hero-tags { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 26px; padding: 0; list-style: none; }
.hero-tags li {
  padding: 7px 13px;
  border: 1px solid var(--hair-strong);
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.linkface-visual {
  display: grid;
  place-items: center;
  padding: 32px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-frame);
  background: #fff;
  box-shadow: var(--shadow-soft);
}
.linkface-visual img { width: min(260px, 80%); height: auto; object-fit: contain; }
.linkface-visual p { margin: 18px 0 0; text-align: center; font-size: 0.8rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--brass-ink); }

/* ---------- Feature blocks ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.feature-tile {
  padding: 26px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-md);
  background: var(--ivory);
}
.feature-tile .num {
  font-family: var(--serif);
  font-size: 2.2rem;
  color: var(--brass-ink);
  line-height: 1;
}
.feature-tile h3 { margin: 14px 0 10px; font-family: var(--serif); font-size: 1.25rem; font-weight: 500; }
.feature-tile p { margin: 0; line-height: 1.7; color: var(--muted); font-size: 0.94rem; }

/* ---------- App chips ---------- */
.app-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.app-chips span {
  padding: 9px 14px;
  border: 1px solid var(--hair);
  border-radius: 4px;
  background: var(--cream);
  font-size: 0.85rem;
}

/* ---------- Focused product screenshots ---------- */
.showcase-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; align-items: stretch; }
.device-shot {
  display: flex;
  flex-direction: column;
  margin: 0;
  border: 1px solid var(--hair);
  border-radius: var(--radius-md);
  background: #fff;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.device-shot__bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--hair);
  background: var(--cream);
}
.device-shot__bar span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--hair-strong);
}
.device-shot__bar span:first-child { background: var(--brass); }
.device-shot__bar small {
  margin-left: 8px;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.device-shot__screen {
  display: grid;
  place-items: center;
  flex: 1 1 auto;
  min-height: 470px;
  padding: 18px;
  background: linear-gradient(160deg, var(--ivory), var(--cream));
}
.device-shot__screen a { display: block; transition: transform 0.3s var(--ease-out-soft); }
.device-shot__screen a:hover { transform: translateY(-3px); }
.device-shot__screen img {
  display: block;
  width: auto;
  border-radius: 10px;
  box-shadow: 0 18px 36px -18px rgba(38, 6, 11, 0.55);
}
.device-shot__screen--phone img { max-height: 400px; }
.device-shot__screen--profile img { max-height: 520px; }
.device-shot figcaption {
  padding: 14px 16px;
  border-top: 1px solid var(--hair);
  font-size: 0.84rem;
  line-height: 1.5;
  color: var(--muted);
}

/* ---------- Pricing ---------- */
.price-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.price-card {
  padding: 30px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-md);
  background: var(--ivory);
}
.price-card.is-pro { background: var(--oxblood-deep); color: var(--cream); border-color: var(--oxblood); }
.price-card h3 { margin: 0 0 8px; font-family: var(--serif); font-size: 1.4rem; font-weight: 500; }
.price-card .price { font-family: var(--serif); font-size: 2.6rem; line-height: 1.1; margin: 12px 0 4px; }
.price-card .price small { font-size: 0.9rem; font-family: var(--sans); opacity: 0.75; }
.price-card ul { margin: 18px 0 24px; padding: 0; list-style: none; }
.price-card li { padding: 7px 0 7px 22px; position: relative; line-height: 1.5; font-size: 0.92rem; }
.price-card li::before { content: ''; position: absolute; left: 0; width: 7px; height: 7px; border: 2px solid var(--brass); transform: rotate(45deg); }
.price-card.is-pro li { color: var(--cream); }
.price-card.is-pro .btn--solid { background: var(--cream); color: var(--oxblood-deep); }

/* ---------- FAQ ---------- */
.faq-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.faq-item { padding: 24px; border: 1px solid var(--hair); border-radius: var(--radius-md); background: var(--ivory); }
.faq-item h3 { margin: 0 0 10px; font-family: var(--serif); font-size: 1.1rem; font-weight: 500; }
.faq-item p { margin: 0; font-size: 0.92rem; line-height: 1.7; color: var(--muted); }

/* ---------- External link note ---------- */
.source-note {
  margin-top: 28px;
  font-size: 0.85rem;
  color: var(--muted);
}
.source-note a { color: var(--brass-ink); text-decoration: underline; }

@media (max-width: 860px) {
  .projects-on-home,
  .project-grid,
  .linkface-hero-grid,
  .showcase-grid,
  .price-grid { grid-template-columns: 1fr; }
  .feature-grid,
  .faq-grid { grid-template-columns: 1fr; }
  .linkface-visual { padding: 20px; }
}
