/* CWA homepage, design preview. tasteskill v2 direction "one-motif", seed 166040107.
   The motif: mitred lock gates closing into a V, from the Waltham Abbey office's lock-keeper's cottage
   and the two Vs of the CWA W. It is the hero shape, the picture masks, the buttons and the date tags. */
@font-face { font-family: "Schibsted Grotesk"; src: url("fonts/schibsted-grotesk-latin-wght-normal.woff2") format("woff2"); font-weight: 400 900; font-display: swap; }

:root {
  --bg: #ffffff;
  --surface: #f0f1f1;
  --ink: #0e1e29;
  --muted: #4a5660;
  --accent: #a1ffcb;
  --accent-ink: #0e1e29;
  --field-2: #0e1e29;
  --field-2-ink: #ffffff;
  --pale: #dfe7ec;

  --step-small: 0.875rem;
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.375rem, 1.05rem + 1.15vw, 2.25rem);
  --step-head: clamp(2rem, 1.25rem + 3vw, 3.75rem);
  --step-display: clamp(3.25rem, 1.2rem + 6.4vw, 6.25rem);

  --m: clamp(16px, 2.6vw, 32px);
  --gap: clamp(96px, 12vw, 200px);
  --tip: 0.62em;
  --ease: cubic-bezier(.2, .7, .2, 1);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 var(--step-body)/1.5 "Schibsted Grotesk", system-ui, sans-serif; letter-spacing: -0.01em; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--accent); }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
h1, h2, h3 { font-weight: 800; letter-spacing: -0.04em; line-height: 0.95; margin: 0; text-wrap: balance; }
p { margin: 0; }
.vh { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: var(--m); top: -60px; background: var(--ink); color: #fff; padding: 10px 14px; z-index: 10; }
.skip:focus { top: 8px; }

/* concept notice and bar */
.concept { background: var(--surface); padding: 10px var(--m); font-size: var(--step-small); }
.concept p { max-width: 72ch; }
.bar { display: flex; align-items: center; justify-content: space-between; padding: 18px var(--m); }
.mark img { height: 32px; width: auto; }
.bar nav { display: flex; gap: clamp(16px, 2.4vw, 36px); font-weight: 600; font-size: var(--step-body); }
.bar nav a { text-decoration: none; }
.bar nav a:hover { text-decoration: underline; }

/* buttons: cut to the gate's point */
.btn { display: inline-block; background: var(--ink); color: #fff; font-weight: 600; text-decoration: none; padding: 16px calc(28px + var(--tip)) 16px 26px; clip-path: polygon(0 0, calc(100% - var(--tip)) 0, 100% 50%, calc(100% - var(--tip)) 100%, 0 100%); transition: transform .25s var(--ease), background-color .25s var(--ease); }
.btn:hover { transform: translateX(4px); background: #1d3445; text-decoration: none; }
.btn:active { transform: translateX(1px) scale(.98); }
.btn-accent { background: var(--accent); color: var(--accent-ink); }
.btn-accent:hover { background: #c3ffdf; }
.btn-small { padding: 10px calc(18px + var(--tip)) 10px 16px; font-size: var(--step-small); }

/* hero */
.hero { position: relative; min-height: min(86svh, 900px); display: grid; grid-template-columns: repeat(12, 1fr); align-items: center; padding: 0 var(--m); overflow: hidden; }
.hero-shape { position: absolute; top: -12svh; right: -6vw; width: 58vw; height: 124svh; background: var(--accent); clip-path: polygon(34% 0, 100% 0, 100% 100%, 34% 100%, 0 50%); }
.hero-copy { position: relative; grid-column: 1 / 7; padding: 64px 0; }
.hero h1 { font-size: var(--step-display); line-height: 0.9; letter-spacing: -0.05em; max-width: 9.5em; }
.hero-line { margin-top: 36px; line-height: 1.45; max-width: 30em; }
.hero-copy .btn { margin-top: 36px; }
.hero-shape img { width: 100%; height: 100%; object-fit: cover; object-position: 62% 55%; }
.hero-next { position: relative; grid-column: 9 / 13; align-self: end; margin-right: calc(-1 * var(--m)); background: var(--accent); color: var(--accent-ink); padding: 32px var(--m) 36px calc(var(--m) + 2.2rem); clip-path: polygon(2.2rem 0, 100% 0, 100% 100%, 2.2rem 100%, 0 50%); }
.next-date { font-size: var(--step-head); font-weight: 800; letter-spacing: -0.04em; line-height: 1; }
.next-what { margin-top: 14px; max-width: 22em; }
.next-days { margin-top: 14px; font-weight: 600; }

/* intro statement */
.intro { padding: var(--gap) var(--m); display: flex; justify-content: center; }
.statement { font-size: var(--step-lead); font-weight: 600; line-height: 1.22; letter-spacing: -0.025em; max-width: 30em; text-align: center; }
.statement.left { text-align: left; }

/* dated list */
.dates { padding: 0 var(--m) var(--gap); }
.dates-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 48px; gap: 24px; }
.dates h2, .answers h2 { font-size: var(--step-head); }
.count { font-weight: 600; }
.date-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 40px 64px; }
.date-list li { display: grid; grid-template-columns: 96px 1fr; gap: 20px; align-items: start; }
.date-list li.past { display: none; }
.tag { display: grid; place-items: center start; height: 44px; padding-left: 12px; background: var(--surface); font-weight: 700; font-size: var(--step-small); clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 50%, calc(100% - 14px) 100%, 0 100%); }
.date-list li.next .tag { background: var(--accent); }
.date-row { display: flex; justify-content: space-between; gap: 16px; font-weight: 700; }
.date-row a { text-decoration: none; }
.date-row a:hover { text-decoration: underline; }
.days { font-weight: 600; white-space: nowrap; }
.date-note { margin-top: 4px; color: var(--muted); max-width: 40ch; }
.source { margin-top: 48px; color: var(--muted); font-size: var(--step-small); }

/* Making Tax Digital chooser */
.mtd { position: relative; min-height: 88svh; display: grid; grid-template-columns: repeat(12, 1fr); align-items: center; padding: 72px var(--m); background: var(--surface); overflow: hidden; }
.mtd-stage { position: absolute; inset: 0; pointer-events: none; }
.mtd-shape { position: absolute; left: 39%; top: 14svh; width: min(60svh, 34vw); height: min(60svh, 34vw); background: var(--accent); clip-path: polygon(30% 0, 100% 0, 100% 100%, 30% 100%, 0 50%); display: grid; place-items: center; transition: background-color .3s var(--ease); }
.mtd-shape.s-50 { background: var(--ink); }
.mtd-shape.s-50 .mtd-big { color: #fff; }
.mtd-shape.s-20 { background: var(--pale); }
.mtd-shape.s-0 { background: #ffffff; }
.mtd-big { font-size: var(--step-head); font-weight: 800; letter-spacing: -0.04em; line-height: 0.95; text-align: center; padding-left: 22%; max-width: 6.5em; transition: opacity .3s var(--ease); }
.mtd-list { position: relative; grid-column: 1 / 6; }
.mtd h2 { font-size: var(--step-head); max-width: 8em; }
.mtd-help { margin-top: 20px; max-width: 26em; }
.choices { margin-top: 28px; display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.choice { font: inherit; font-size: var(--step-lead); font-weight: 700; letter-spacing: -0.03em; color: var(--muted); background: none; border: 0; padding: 4px 0; cursor: pointer; text-align: left; transition: color .2s var(--ease), transform .2s var(--ease); }
.choice:hover { color: var(--ink); transform: translateX(6px); }
.choice[aria-pressed="true"] { color: var(--ink); }
.choice[aria-pressed="true"]::before { content: ""; display: inline-block; width: .5em; height: .7em; margin-right: .3em; background: var(--ink); clip-path: polygon(0 0, 100% 50%, 0 100%); vertical-align: 0.02em; }
.mtd-fact { position: relative; grid-column: 10 / 13; max-width: 26em; }
.mtd-fact p + p { margin-top: 16px; font-weight: 600; }
.mtd-plain { position: relative; grid-column: 1 / 13; margin-top: 24px; }

/* services paragraph */
.work { padding: var(--gap) var(--m); display: grid; grid-template-columns: repeat(12, 1fr); }
.work .statement { grid-column: 1 / 12; max-width: 34em; min-width: 0; }
.work-more { grid-column: 1 / 13; margin-top: 72px; display: grid; grid-template-columns: repeat(12, 1fr); gap: 0 24px; }
.work-more > p { grid-column: 1 / 6; font-size: var(--step-lead); font-weight: 600; letter-spacing: -0.025em; line-height: 1.22; max-width: 14em; }
.work-more .services { grid-column: 7 / 13; margin: 0; }
.work-more > .ip { grid-column: 1 / -1; }
.services { list-style: none; padding: 0; margin: 20px 0 0; columns: 2; column-gap: 32px; }
.services li { break-inside: avoid; margin-bottom: 8px; font-weight: 600; }
.services a { text-decoration: none; }
.services a:hover { text-decoration: underline; }

/* the two places, at full width */
.places { padding: 0 var(--m) var(--gap); display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; align-items: start; }
.places h2 { grid-column: 1 / 13; font-size: var(--step-head); margin-bottom: 24px; }
.places figure { margin: 0; min-width: 0; }
.places img { width: 100%; height: auto; }
.places figcaption { margin-top: 12px; font-size: var(--step-small); color: var(--muted); max-width: 48ch; }
.place-map { grid-column: 1 / 8; grid-row: 2 / 4; }
.place-map img { aspect-ratio: 16 / 10; object-fit: cover; clip-path: polygon(0 0, 88% 0, 100% 50%, 88% 100%, 0 100%); }
.place-angel { grid-column: 8 / 13; grid-row: 2; }
.place-angel img { aspect-ratio: 4 / 3; object-fit: cover; }
.place-abbey { grid-column: 8 / 13; grid-row: 3; }
.place-abbey img { aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 30%; }

/* offices panel */
.offices { padding: 0 20px; }
.panel { background: var(--field-2); color: var(--field-2-ink); display: grid; grid-template-columns: 58% 42%; overflow: hidden; }
.panel-left { padding: 56px 0 0; display: flex; flex-direction: column; gap: 48px; }
.panel-left h2 { padding-left: 56px; }
.panel h2 { font-size: var(--step-head); color: var(--pale); }
.panel-pic { width: 100%; aspect-ratio: 4 / 3; margin-top: auto; clip-path: polygon(0 0, 78% 0, 100% 50%, 78% 100%, 0 100%); overflow: hidden; }
.panel-pic img { width: 100%; height: 100%; object-fit: cover; }
.panel-right { padding: 56px 56px 56px 0; display: flex; flex-direction: column; justify-content: center; gap: 64px; }
.office { max-width: 22em; }
.office h3 { font-size: var(--step-lead); letter-spacing: -0.03em; }
.office p { margin-top: 12px; }
.panel .btn, .panel .ip { align-self: flex-start; }

/* answers */
.answers { padding: var(--gap) var(--m); display: grid; grid-template-columns: repeat(12, 1fr); gap: 0 32px; }
.answers > div:first-child { grid-column: 1 / 5; align-self: start; position: sticky; top: 96px; }
.answers h2 { max-width: 5em; }
.tiles { grid-column: 5 / 13; display: grid; gap: 8px; }
.answers details { background: var(--surface); transition: background-color .25s var(--ease); }
.answers details[open] { background: var(--accent); }
.answers summary { list-style: none; cursor: pointer; min-height: 72px; padding: 22px 64px 22px 24px; position: relative; font-weight: 600; font-size: var(--step-body); }
.answers summary::-webkit-details-marker { display: none; }
.answers summary::before, .answers summary::after { content: ""; position: absolute; right: 24px; top: 50%; width: 16px; height: 3px; background: var(--ink); transition: transform .25s var(--ease); }
.answers summary::after { transform: rotate(90deg); }
.answers details[open] summary::after { transform: rotate(0deg); }
.answers summary:hover { transform: translateX(2px); }
.ans { padding: 0 24px 24px; max-width: 52ch; }
.ans p + p { margin-top: 12px; font-weight: 600; }

/* coupon */
.contact { padding: 0 var(--m) var(--gap); }
.coupon { position: relative; margin: 0 auto; max-width: 1180px; background: var(--accent); display: grid; grid-template-columns: 46% 24px 1fr; min-height: 420px; }
.coupon::before, .coupon::after { content: ""; position: absolute; left: calc(46% + 12px); width: 28px; height: 28px; margin-left: -14px; border-radius: 50%; background: var(--bg); }
.coupon::before { top: -14px; }
.coupon::after { bottom: -14px; }
.coupon-left { padding: 48px; display: flex; flex-direction: column; justify-content: space-between; gap: 32px; }
.coupon h2 { font-size: var(--step-head); }
.perf { display: flex; flex-direction: column; justify-content: space-evenly; align-items: center; padding: 28px 0; }
.perf span { width: 6px; height: 6px; border-radius: 50%; background: var(--bg); }
.coupon-form { padding: 48px; display: grid; gap: 10px; align-content: center; }
.coupon-form input, .coupon-form select { font: inherit; height: 52px; padding: 0 16px; border: 0; background: #d4ffe7; color: var(--ink); }
.coupon-form input::placeholder { color: #3d4b55; }
.submit { font: inherit; font-weight: 700; height: 56px; border: 0; background: var(--ink); color: #fff; cursor: pointer; transition: background-color .2s var(--ease), transform .2s var(--ease); }
.submit:hover { background: #1d3445; }
.submit:active { transform: scale(.99); }
.sent { font-weight: 600; }

/* footer */
.foot { background: var(--field-2); color: var(--field-2-ink); padding: 72px var(--m) 32px; }
.foot-mark img { width: 100%; height: auto; max-height: 34svh; object-fit: contain; object-position: left; }
.foot-cols { margin-top: 56px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.foot-cols ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.foot-cols a { text-decoration: none; }
.foot-cols a:hover { text-decoration: underline; }
.credits { margin-top: 48px; font-size: var(--step-small); color: var(--pale); max-width: 72ch; }
.foot-last { margin-top: 32px; display: flex; justify-content: space-between; align-items: center; gap: 24px; font-size: var(--step-small); }
.foot .btn-small { background: var(--accent); color: var(--ink); }

/* motion */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }
.js .shutter { clip-path: polygon(0 0, 0 0, 0 50%, 0 100%, 0 100%); transition: clip-path 1.1s var(--ease); }
.js .shutter img { transform: scale(1.12); transition: transform 1.4s var(--ease); }
.js .shutter.in { clip-path: polygon(0 0, 78% 0, 100% 50%, 78% 100%, 0 100%); }
.js .shutter.in img { transform: scale(1); }
.hero-shape { animation: gate 1.2s var(--ease) both; }
@keyframes gate { from { transform: translateX(18vw); } to { transform: none; } }
.hero-copy > * { animation: rise .8s var(--ease) both; }
.hero-copy > :nth-child(2) { animation-delay: .08s; }
.hero-copy > :nth-child(3) { animation-delay: .16s; }
.hero-next > * { animation: rise .8s var(--ease) both; animation-delay: .3s; }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
.date-list li { transition: opacity .6s var(--ease), transform .6s var(--ease); }
.date-list.wait li { opacity: 0; transform: translateY(20px); }
.mtd-shape.swap .mtd-big { opacity: 0; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal, .date-list.wait li { opacity: 1; transform: none; }
  .js .shutter, .js .shutter.in { clip-path: polygon(0 0, 78% 0, 100% 50%, 78% 100%, 0 100%); }
  .js .shutter img { transform: none; }
  html { scroll-behavior: auto; }
}

/* tablet */
@media (max-width: 1024px) {
  .hero-copy { grid-column: 1 / 9; }
  .hero-next { grid-column: 7 / 13; }
  .mtd-list { grid-column: 1 / 8; }
  .mtd-fact { grid-column: 10 / 13; }
  .coupon h2 { font-size: var(--step-lead); }

  .panel-left { padding: 40px 0 0; }
  .panel-left h2 { padding-left: 40px; }
  .panel-right { padding: 40px 40px 40px 0; }
}

/* phone: its own composition */
@media (max-width: 720px) {
  .bar nav { gap: 14px; font-size: 1rem; }
  .bar nav a:not(.bar-call) { display: none; }
  .hero { display: block; min-height: 0; padding-bottom: 0; }
  .hero-shape { top: auto; bottom: -22vw; right: auto; left: -10vw; width: 130vw; height: 70vw; clip-path: polygon(0 34%, 50% 0, 100% 34%, 100% 100%, 0 100%); }
  .hero-copy { padding: 40px 0 0; }
  .hero h1 { font-size: 13vw; }
  .hero-line { font-size: 1.0625rem; margin-top: 24px; }
  .hero-copy .btn { margin-top: 24px; }
  .hero-next { margin: 40px calc(-1 * var(--m)) calc(48vw + 8px); padding: 24px var(--m); clip-path: none; }
  .hero-next .next-date { font-size: var(--step-body); letter-spacing: -0.01em; }
  .intro { padding: 96px var(--m); }
  .statement { text-align: left; font-size: 1.375rem; }
  .date-list { grid-template-columns: 1fr; gap: 28px; }
  .date-list li { grid-template-columns: 76px 1fr; gap: 14px; }
  .dates-head { margin-bottom: 32px; }
  .mtd { display: block; min-height: 0; padding: 64px var(--m); }
  .mtd-stage { position: relative; inset: auto; }
  .mtd-shape { position: relative; left: auto; top: auto; width: 86vw; height: 62vw; margin: 0 auto 32px; }
  .mtd-big { font-size: 2rem; }
  .choice { font-size: 1.375rem; }
  .mtd-fact { margin-top: 28px; }
  .work { display: block; padding: 96px var(--m); }
  .places { display: block; padding-bottom: 96px; }
  .places figure + figure { margin-top: 28px; }
  .work-more { margin-top: 48px; display: block; }
  .work-more .services { margin-top: 20px; }
  .services { columns: 1; }
  .offices { padding: 0 10px; }
  .panel { display: block; min-height: 0; }
  .panel-left { padding: 32px 0 0; }
  .panel-left h2 { padding-left: 24px; }
  .panel-right { padding: 32px 24px 48px; gap: 36px; }
  .panel-pic { width: 100%; margin: 8px 0 0; }
  .panel { display: flex; flex-direction: column; }
  .panel-left { order: 1; }
  .panel-right { order: 2; }
  .answers { display: block; padding: 96px var(--m); }
  .answers > div:first-child { position: static; }
  .answers h2 { margin-bottom: 28px; max-width: none; }
  .answers summary { min-height: 64px; padding: 20px 56px 20px 20px; font-size: 1.0625rem; }
  .coupon { grid-template-columns: 1fr; }
  .coupon::before, .coupon::after { display: none; }
  .coupon-left { padding: 32px 24px 8px; }
  .perf { flex-direction: row; padding: 12px 24px; }
  .coupon-form { padding: 16px 24px 32px; }
  .foot-cols { grid-template-columns: 1fr 1fr; }
  .foot-last { flex-wrap: wrap; }
}
