/* Preview layer: the "marked-up" site. Loads after styles.css. */

/* Pen and highlighter motion */
.draw .ring path { stroke-dasharray: var(--len, 4000px); stroke-dashoffset: var(--len, 4000px); transition: stroke-dashoffset 1.1s cubic-bezier(.6,.1,.3,1); }
.draw.in .ring path { stroke-dashoffset: 0; }
.nav .wordmark.draw .ring path { transition-delay: .25s; }
.marked.sweep { background-repeat: no-repeat; background-size: 0% 100%; transition: background-size 1.1s cubic-bezier(.6,.1,.3,1) .5s; }
.marked.sweep.in { background-size: 100% 100%; }
.wiggle { cursor: default; }
.wiggle:hover .ring { animation: wiggle .55s ease-in-out; transform-origin: 50% 50%; }
@keyframes wiggle { 20% { transform: rotate(-3deg) scale(1.03); } 50% { transform: rotate(2.5deg); } 80% { transform: rotate(-1deg); } }
@media (prefers-reduced-motion: reduce) {
  .draw .ring path, .marked.sweep { transition: none; }
  .wiggle:hover .ring { animation: none; }
}

/* The receipts: a magazine spread, not a grid */
.spread {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: clamp(16px, 2.5vw, 32px); row-gap: clamp(28px, 4vw, 56px);
  border-top: 1.5px solid var(--ink); padding-top: clamp(28px, 4vw, 48px);
}
.r p { margin: 10px 0 0; font-size: 15px; line-height: 1.45; color: var(--graphite); max-width: 26ch; }
.r p b { color: var(--ink); font-weight: 600; }
.rn { font-weight: 800; letter-spacing: -0.045em; line-height: 0.9; font-variant-numeric: lining-nums; color: var(--ink); }
.rn .circled { padding: 0.12em 0.3em 0.14em; margin: -0.12em -0.3em -0.14em; }
.rn .circled .ring path { stroke-width: 3px; }
.r-hero { grid-column: 1 / 8; grid-row: 1 / 3; }
.r-hero .rn { font-size: clamp(100px, 14.5vw, 200px); }
.r-hero p { font-size: 18px; max-width: 30ch; color: var(--ink); }
.r-a { grid-column: 9 / 13; grid-row: 1; align-self: end; }
.r-a .rn { font-size: clamp(52px, 6vw, 80px); }
.r-b { grid-column: 9 / 12; grid-row: 2; align-self: start; padding-top: 22px; border-top: 1px solid var(--rule); }
.r-b .rn { font-size: clamp(60px, 7vw, 96px); font-family: var(--serif); font-style: italic; font-weight: 500; letter-spacing: -0.02em; }
.r-c { grid-column: 2 / 7; grid-row: 3; }
.r-c .rn { font-size: clamp(80px, 10vw, 140px); }
.r-d { grid-column: 8 / 13; grid-row: 3; align-self: center; }
.r-d .rn { font-size: clamp(52px, 6.4vw, 88px); }
.r-e { grid-column: 4 / 10; grid-row: 4; display: flex; align-items: baseline; gap: 20px; padding-top: 22px; border-top: 1px solid var(--rule); }
.r-e .rn { font-size: clamp(48px, 5.4vw, 72px); font-family: var(--serif); font-style: italic; font-weight: 500; letter-spacing: -0.02em; }
.r-e p { margin: 0; }

/* Margin notes, in her voice */
.note {
  display: inline-flex; align-items: flex-start; gap: 6px;
  margin: -6px 0 18px; padding-left: 4px;
  font-family: var(--serif); font-style: italic; font-size: 19px; line-height: 1.3; color: var(--rose);
  transform: rotate(-1.6deg); transform-origin: left center; max-width: 32ch;
}
.note-arrow { flex: none; width: 34px; height: 24px; margin-top: 2px; transform: scaleY(-1) rotate(8deg); }
.note-arrow path { fill: none; stroke: var(--rose); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* Copy-email button */
button.btn { font-family: var(--text); cursor: pointer; }

@media (max-width: 860px) {
  .spread { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .r-hero { grid-column: 1 / -1; grid-row: auto; }
  .r-a { grid-column: 1 / 4; grid-row: auto; align-self: start; }
  .r-b { grid-column: 4 / 7; grid-row: auto; padding-top: 0; border-top: 0; }
  .r-c { grid-column: 1 / -1; grid-row: auto; }
  .r-d { grid-column: 1 / 4; grid-row: auto; }
  .r-e { grid-column: 4 / 7; grid-row: auto; display: block; padding-top: 0; border-top: 0; }
  .r-e p { margin-top: 10px; }
}
@media (max-width: 560px) {
  .r-a, .r-b, .r-d, .r-e { grid-column: 1 / -1; }
  .note { font-size: 17px; }
}

/* ---------- Round 2: one palette, roomier circles, collapsibles, more motion ---------- */

/* One family: rose, blush, charcoal, paper. The highlighter goes pink. */
.pv { --marker: #f7cfdb; }

/* Circles never clip at the screen edge */
.pv .wordmark { margin-left: -0.35em; }
.pv .rn .circled { margin-left: 0; margin-right: 0; }
.pv .spread { padding-left: 6px; }
.pv main, .pv footer { overflow-x: clip; }

/* FPSA panels in the portfolio's colors (FPSA's own logos and swatches stay as content) */
/* FPSA section uses FPSA's own colors: navy, sea blue, teal, green. No pink. */
#work-fpsa { --rose: #0097ae; --blush: #d6eef2; --marker: #d6eef2; }
#work-fpsa .work-group-title { border-bottom-color: #003d69; }
#work-fpsa .work-group-title h3 { color: #003d69; }
#work-fpsa .case h4 { color: #003d69; }
#work-fpsa .case-meta strong { color: #007198; }
#work-fpsa .figures { border-top-color: #003d69; }
#work-fpsa .figures dt { color: #003d69; }
#work-fpsa .points li::before { background: #66bd57; }
#work-fpsa .note { color: #007198; }
#work-fpsa .note-arrow path { stroke: #007198; }
#work-fpsa .more summary { border-color: #003d69; color: #003d69; }
#work-fpsa .more summary::before { color: #0097ae; }
#work-fpsa .more summary:hover { background: #003d69; color: #fff; }
#work-fpsa .more summary:hover::before { color: #66bd57; }
.pv .fpsa-master { background: linear-gradient(135deg, #003d69 0%, #007198 55%, #0097ae 100%); }
.pv .fpsa-master::after { background: linear-gradient(90deg, #0097ae, #66bd57); }
.pv .fpsa-panel, .pv .cultivate-panel { border-color: #c9dbe5; }
.pv .fpsa-swatches > p, .pv .fpsa-programs > p { color: #003d69; }
.pv .cultivate-panel > p { color: #1b3c49; }
.pv .fpsa-bars { background: linear-gradient(160deg, #003d69 0%, #00557f 100%); }
.pv .fpsa-bars::after { background: linear-gradient(90deg, #0097ae, #66bd57); }
.pv .fpsa-bars .bar { background: rgba(255,255,255,.14); }
.pv .fpsa-bars .bar i { background: linear-gradient(90deg, #0097ae, #66bd57); }
.pv .cultivate-pieces li { background: #e6f3f5; color: #1b3c49; }

/* Collapsible "How I did it" */
.more { margin-top: 6px; }
.more summary {
  list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 15px; padding: 8px 16px 8px 14px; border: 1.5px solid var(--ink); border-radius: 999px;
}
.more summary::-webkit-details-marker { display: none; }
.more summary::before { content: "+"; font-size: 18px; line-height: 1; color: var(--rose); transition: transform .3s ease; }
.more[open] summary::before { transform: rotate(45deg); }
.more summary:hover { background: var(--ink); color: var(--paper); }
.more[open] > :not(summary) { animation: unfold .45s cubic-bezier(.2,.7,.2,1); }
.more .points { margin-top: 18px; }
@keyframes unfold { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.more-series summary { margin-bottom: 8px; }
.more-series[open] .series { margin-top: 18px; }

/* Margin notes write themselves in */
.note { clip-path: inset(0 100% 0 0); transition: clip-path 1.2s cubic-bezier(.6,.1,.3,1) .2s; }
.note.in { clip-path: inset(0 0 0 0); }

/* Photos sit like pinned prints and straighten on hover */
.pv .case-media > img, .pv .case-media.landscape > img { transform: rotate(-1.2deg); box-shadow: 0 1px 0 var(--rule); transition: transform .5s cubic-bezier(.2,.7,.2,1); }
.pv .case:nth-of-type(even) .case-media > img { transform: rotate(1.1deg); }
.pv .case .case-media > img:hover { transform: rotate(0) scale(1.01); }

@media (prefers-reduced-motion: reduce) {
  .note { clip-path: none; transition: none; }
  .more[open] > :not(summary) { animation: none; }
  .pv .case-media > img { transition: none; }
}

/* Brand pills are links */
.pv .brands li { padding: 0; border: 0; background: none; }
.pv .brands a { display: inline-block; font-size: 14px; padding: 7px 15px; border: 1px solid var(--rule); border-radius: 999px; background: #fff; text-decoration: none; transition: border-color .2s, background .2s, transform .2s; }
.pv .brands a:hover, .pv .brands a:focus-visible { border-color: var(--rose); background: #fdf0f4; transform: rotate(-2deg); }
html { scroll-padding-top: 90px; }
