/* Projects pages: the list (/projects/) and each project story (/projects/<name>).
   Loaded after style.css, which holds the design tokens, nav, buttons and footer.
   List from Mockups/freelance/projects/projects-v1.html (A Grid); case study styles are in case-study.css. */

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
h1, h2, h3 { text-wrap: balance; }
.arr--back { rotate: 180deg; }
.js .fade { opacity: 0; translate: 0 24px; transition: opacity .9s, translate 1s var(--ease); }
.js .fade.in { opacity: 1; translate: 0 0; }

/* Screenshot frame: a flat Mac-style window like the service drawings
   (named .frame because style.css already uses .win for those drawings) */
.shot { margin: 0; }
.frame { border: 1px solid color-mix(in srgb, var(--ink) 22%, transparent); border-radius: 12px; overflow: hidden; background: #fff; }
.frame-bar { position: relative; display: flex; align-items: center; justify-content: center; height: 34px; background: color-mix(in srgb, var(--ink) 5%, var(--paper)); border-bottom: 1px solid color-mix(in srgb, var(--ink) 12%, transparent); font-size: 12px; font-weight: 600; color: var(--body); white-space: nowrap; }
.frame-bar .lights { left: 13px; gap: 7px; }
.frame-bar .lights i { width: 11px; height: 11px; }
.shot-img { display: block; width: 100%; height: auto; }
.shot figcaption { margin-top: 12px; font-size: 14px; line-height: 1.5; color: var(--muted); max-width: 60ch; }

/* ===== List page ===== */
.p-head { padding: clamp(48px, 7vw, 104px) 0 clamp(32px, 4vw, 56px); }
.p-head h1 { margin: 0; font-size: clamp(44px, 7vw, 104px); font-weight: 600; letter-spacing: -0.035em; line-height: .95; }
.p-head p { margin: 24px 0 0; max-width: 46ch; font-size: clamp(18px, 1.5vw, 21px); line-height: 1.55; color: var(--body); }
section.p-list { padding: 0 0 clamp(64px, 8vw, 120px); }
.p-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(20px, 2.4vw, 32px); }
.p-card { display: flex; flex-direction: column; gap: 18px; padding: clamp(16px, 1.6vw, 20px); border: 1px solid var(--line); border-radius: 16px; background: #fff; transition: border-color .3s, translate .35s var(--ease); }
.p-card .frame { background: var(--paper); }
.p-card .shot-img { aspect-ratio: 16 / 10; object-fit: cover; object-position: top center; }
.p-card-text { display: grid; gap: 8px; justify-items: start; padding: 0 4px 4px; }
.p-card h2 { margin: 0; font-size: clamp(22px, 2vw, 28px); font-weight: 700; letter-spacing: -0.025em; line-height: 1.1; }
.p-card p { margin: 0; font-size: 16px; line-height: 1.55; color: var(--body); }
.tag { display: inline-flex; padding: 5px 12px; border-radius: 999px; background: color-mix(in srgb, var(--ink) 6%, var(--paper)); font-size: 13px; font-weight: 600; color: var(--body); }
.go { display: inline-flex; align-items: center; gap: 8px; margin-top: 4px; font-size: 14px; font-weight: 700; color: var(--accent); }
@media (hover: hover) {
  .p-card:hover { border-color: color-mix(in srgb, var(--ink) 32%, transparent); translate: 0 -4px; }
  .p-card:hover .go .arr { translate: 3px 0; }
}
/* The last tile is always "Your business next?" so the grid never looks half empty */
.p-card--next { justify-content: center; align-items: flex-start; gap: 16px; padding: clamp(28px, 3vw, 44px); background: var(--accent); border-color: var(--accent); color: #fff; }
.p-card--next h2 { font-size: clamp(28px, 3vw, 40px); }
.p-card--next p { color: #fff; max-width: 34ch; }
.p-card--next .go { color: var(--accent-light); }
@media (hover: hover) { .p-card--next:hover { border-color: var(--accent); } }

/* Client quotes */
section.refs { padding: clamp(72px, 9vw, 130px) 0; border-top: 1px solid var(--line); }
.refs h2 { margin: 0; font-size: clamp(32px, 4vw, 56px); font-weight: 600; letter-spacing: -0.03em; line-height: 1; }
.quotes { display: grid; grid-template-columns: minmax(0, 760px); gap: clamp(16px, 2vw, 24px); margin-top: clamp(32px, 4vw, 56px); }
.q { margin: 0; display: flex; flex-direction: column; gap: 28px; padding: clamp(24px, 2.6vw, 36px); border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.q p { margin: 0; font-family: var(--serif); font-size: clamp(24px, 2.6vw, 34px); line-height: 1.3; }
.q a { color: var(--accent); font-weight: 600; }

/* Shared quote footer (list + project page) */
.who { display: flex; align-items: center; gap: 14px; }
.who .face { width: 48px; height: 48px; border-radius: 50%; flex: none; font-size: 9px; }
.who b { display: block; font-size: 15px; }
.who small { display: block; font-size: 14px; color: var(--muted); }

/* ===== Project page ===== */
.back { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 14px; font-weight: 600; color: var(--muted); }
@media (hover: hover) { .back:hover { color: var(--ink); } .back:hover .arr { translate: -3px 0; } }
.p-title { margin: 12px 0 0; font-size: clamp(44px, 7vw, 104px); font-weight: 600; letter-spacing: -0.035em; line-height: .95; }
.p-sum { margin: 24px 0 0; max-width: 40ch; font-size: clamp(19px, 1.7vw, 24px); line-height: 1.45; color: var(--body); }
/* The rest of the case study page is in case-study.css */

/* Big client quote */
.quote { max-width: 900px; margin: 0 auto; }
.quote p { margin: 0; font-family: var(--serif); font-size: clamp(26px, 3vw, 40px); line-height: 1.25; letter-spacing: -0.01em; }
.quote .who { margin-top: 24px; }

/* ===== End band (both pages): link + call to action, like the homepage contact ===== */
section.end { background: var(--ink); color: #fff; padding: clamp(72px, 9vw, 130px) 0 32px; }
.next { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 24px; padding: clamp(20px, 3vw, 32px); border: 1px solid color-mix(in srgb, #fff 16%, transparent); border-radius: 16px; transition: border-color .3s, background .3s; }
@media (hover: hover) { .next:hover { border-color: var(--accent-light); background: color-mix(in srgb, #fff 4%, transparent); } .next:hover .arr { translate: 3px 0; } }
.next small { display: block; font-size: 14px; color: var(--on-dark); }
.next strong { display: block; margin-top: 4px; font-size: clamp(22px, 2.4vw, 32px); font-weight: 600; letter-spacing: -0.02em; }
.next .arr { width: 24px; height: 24px; color: var(--accent-light); }
.cta { text-align: center; }
.next + .cta { margin-top: clamp(64px, 8vw, 112px); }
.cta h2 { margin: 0 auto; max-width: 16ch; font-size: clamp(36px, 5vw, 72px); font-weight: 600; letter-spacing: -0.035em; line-height: .98; }
.cta p { margin: 20px auto 0; max-width: 46ch; color: var(--on-dark); font-size: 17px; line-height: 1.6; }
.cta-btns { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 32px; }
.end .btn { border-color: color-mix(in srgb, #fff 40%, transparent); }
.end .btn--solid { border-color: var(--accent); }
@media (hover: hover) { .end .btn:hover { background: #fff; border-color: #fff; color: var(--ink); } }
.end .btn:focus-visible, .end a:focus-visible { outline-color: var(--accent-light); }

/* Phones and tablets */
@media (max-width: 899px) {
  .p-grid { grid-template-columns: 1fr; }
  .frame-bar { height: 28px; font-size: 11px; }
  .frame-bar .lights i { width: 9px; height: 9px; }
  .cta-btns .btn { width: 100%; justify-content: center; }
}

/* ----- Book a call page (/book): Google's booking calendar in a flat white card ----- */
.book { padding-bottom: clamp(64px, 8vw, 112px); }
.book .p-head { padding-bottom: clamp(24px, 3vw, 40px); }
.book-frame { border: 1px solid var(--line); border-radius: 16px; background: #fff; overflow: hidden; }
.book-frame iframe { display: block; width: 100%; height: 1050px; border: 0; }
@media (max-width: 899px) { .book-frame iframe { height: 1800px; } } /* phones: calendar, then a full day of times, with no scroll box inside the page */
.book-alt { display: flex; flex-wrap: wrap; gap: 4px 28px; margin: 16px 0 0; font-size: 15px; }
.book-alt a { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-weight: 600; color: var(--accent); }
section.end.end--foot { padding-top: 0; }
.end--foot .foot { margin-top: 0; border-top: 0; padding-top: 32px; }
