/* ERP2.0 Connect public landing page (landing page plan).
   SACC teal and charcoal on warm paper, a serif for reading and a system sans for labels; no web fonts and nothing from
   elsewhere. The layouts change from section to section on purpose, and only three things move: the sample invoice
   printing itself, the getting-started timeline, and the tier slider. All motion stops when the visitor's system asks
   for reduced motion. */

:root {
    --teal: #256b68;
    --teal-deep: #1b4f4d;
    --teal-bright: #2f8a86;
    --teal-tint: #e7f0ef;
    --amber: #f2a33a;
    --charcoal: #221e1f;
    --ink: #2e2c2c;
    --grey: #5d6565;
    --rule: #d6dfdd;
    --paper: #fffefb;
    --band: #f4f6f3;
    --serif: Cambria, Georgia, "Times New Roman", serif;
    --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --mono: ui-monospace, "Cascadia Mono", Consolas, "Courier New", monospace;
    --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 5rem; -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    color: var(--ink);
    background: var(--paper);
    font-family: var(--serif);
    font-size: 1.0625rem;
    line-height: 1.62;
    font-variant-numeric: lining-nums proportional-nums;
    text-rendering: optimizeLegibility;
    hanging-punctuation: first last;
}

img { max-width: 100%; height: auto; }

a { color: var(--teal); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--teal-deep); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }

.skip { position: absolute; left: -999px; top: 0; }
.skip:focus { left: 1rem; z-index: 10; padding: .5rem 1rem; background: var(--paper); }

.wrap { width: min(68rem, 100% - 2.5rem); margin-inline: auto; }

h1, h2, h3 { color: var(--charcoal); font-family: var(--serif); font-variant-numeric: lining-nums; text-wrap: balance; }
h1 { margin: 0 0 1.25rem; font-size: clamp(2.2rem, 4.6vw, 3.4rem); line-height: 1.08; letter-spacing: -.02em; }
h2 { margin: 0 0 1rem; font-size: clamp(1.6rem, 2.6vw, 2.05rem); line-height: 1.15; letter-spacing: -.012em; }
h3 { margin: 0 0 .35rem; font-size: 1.12rem; line-height: 1.3; }
p { text-wrap: pretty; }
/* Old-style figures sit with the serif in running text; labels, prices and the invoice keep lining figures. */
.lead, .section-lead, .note, .split-side p, .margin-list p, .prose-columns p, .faq details p, .contact-text p, .answer p, .founder-note p, .since { font-variant-numeric: oldstyle-nums proportional-nums; }

section { padding-block: 4.5rem; }
.band { background: var(--band); border-block: 1px solid #ebeee9; }
.section-lead { max-width: 42rem; margin: 0 0 2rem; color: var(--grey); font-size: 1.1rem; }
.note { max-width: 46rem; color: var(--grey); font-size: .98rem; }
.source { color: var(--grey); font-size: .9rem; }

/* ------------------------------------------------------------------ top bar */
.topbar {
    position: sticky;
    top: 0;
    z-index: 5;
    background: rgba(255, 254, 251, .94);
    border-bottom: 1px solid transparent;
    backdrop-filter: saturate(1.2) blur(6px);
    transition: border-color .3s, box-shadow .3s;
}
.topbar.is-scrolled { border-color: var(--rule); box-shadow: 0 4px 18px rgba(34, 30, 31, .05); }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .6rem; }
.brand { display: inline-flex; align-items: center; gap: .5rem; color: var(--charcoal); font-weight: 700; font-size: 1.25rem; text-decoration: none; }
.brand img { width: 96px; }
.topbar nav { display: flex; align-items: center; gap: 1.5rem; font-family: var(--sans); font-size: .93rem; }
.topbar nav a[data-nav], .topbar nav a.nav-page { position: relative; padding-block: .25rem; color: var(--ink); text-decoration: none; }
.topbar nav a[data-nav]::after, .topbar nav a.nav-page::after {
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;
    height: 2px;
    background: var(--teal);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .3s var(--ease);
    content: "";
}
.topbar nav a[data-nav]:hover, .topbar nav a[data-nav].is-current, .topbar nav a.nav-page:hover { color: var(--teal); }
.topbar nav a[data-nav]:hover::after, .topbar nav a[data-nav].is-current::after, .topbar nav a.nav-page:hover::after { transform: scaleX(1); }
/* The tour is a page of its own, not a section: it stays in the bar at phone width, where the section links go. */

/* ------------------------------------------------------------------ buttons and links */
.button {
    display: inline-block;
    padding: .78rem 1.45rem;
    border: 1px solid var(--teal);
    border-radius: .4rem;
    color: #fff;
    background: var(--teal);
    font-family: var(--sans);
    font-size: .98rem;
    font-weight: 600;
    text-decoration: none;
    transition: background .2s, border-color .2s, box-shadow .2s;
}
.button:hover { color: #fff; background: var(--teal-deep); border-color: var(--teal-deep); box-shadow: 0 6px 16px rgba(37, 107, 104, .22); }
.button-quiet { color: var(--teal); background: transparent; }
.button-quiet:hover { color: var(--teal-deep); background: var(--teal-tint); box-shadow: none; }
.button-small { padding: .45rem 1rem; font-size: .9rem; }
.text-link { font-family: var(--sans); font-weight: 600; text-decoration: none; }
.text-link span { display: inline-block; transition: transform .2s var(--ease); }
.text-link:hover span { transform: translateX(3px); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1.25rem; margin: 2rem 0 0; }

/* ------------------------------------------------------------------ hero */
.hero {
    position: relative;
    overflow: hidden;
    padding-block: 5rem 5.5rem;
    background: linear-gradient(175deg, #f1f6f4 0%, var(--paper) 72%);
    border-bottom: 1px solid #ebeee9;
}
.hero-grid { position: relative; display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: 3.5rem; align-items: center; }
.lead { max-width: 36rem; margin: 0; font-size: 1.18rem; color: var(--ink); }
.since { margin: 2.25rem 0 0; padding-top: 1rem; border-top: 1px solid var(--rule); max-width: 38rem; color: var(--grey); font-family: var(--sans); font-size: .9rem; }

/* The SACC sunburst, from the logo: very faint, very slow. */
.sunburst { position: absolute; right: -5rem; top: 1rem; width: 30rem; height: 30rem; opacity: .06; pointer-events: none; }
.sunburst-rays { stroke: var(--teal); stroke-width: 7; stroke-linecap: square; transform-origin: center; animation: sacc-turn 140s linear infinite; }
@keyframes sacc-turn { to { transform: rotate(360deg); } }

/* ------------------------------------------------------------------ the sample e-invoice */
.invoice { position: relative; margin: 0; justify-self: center; width: min(100%, 25rem); }
.invoice-paper {
    position: relative;
    padding: 1.5rem 1.5rem 1.25rem;
    border: 1px solid #e3e1da;
    background: #fff;
    font-family: var(--sans);
    font-size: .8rem;
    font-variant-numeric: lining-nums tabular-nums;
    color: var(--ink);
    box-shadow: 0 1px 0 #ece9e1, 0 24px 60px rgba(34, 30, 31, .12);
    transform: rotate(1.2deg);
    /* A torn-off bottom edge, as a printed slip has. */
    -webkit-mask: linear-gradient(#000 0 0) top / 100% calc(100% - 10px) no-repeat, conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 14px 10px repeat-x;
    mask: linear-gradient(#000 0 0) top / 100% calc(100% - 10px) no-repeat, conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 14px 10px repeat-x;
    padding-bottom: 1.85rem;
}
.inv-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: .9rem; padding-bottom: .6rem; border-bottom: 2px solid var(--charcoal); }
.inv-kind { margin: 0; color: var(--charcoal); font-weight: 700; font-size: .82rem; letter-spacing: .06em; text-transform: uppercase; }
.inv-sample { margin: 0; padding: .05rem .5rem; border: 1px solid var(--grey); border-radius: .2rem; color: var(--grey); font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; }
.inv-parties { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: .9rem; line-height: 1.45; }
.inv-label { display: block; margin: 0 0 .15rem; color: var(--grey); font-size: .64rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.inv-mono { font-family: var(--mono); font-size: .76rem; }
.inv-lines { width: 100%; border-collapse: collapse; }
.inv-lines th { padding: .3rem 0; border-bottom: 1px solid var(--rule); color: var(--grey); font-size: .66rem; font-weight: 700; letter-spacing: .08em; text-align: left; text-transform: uppercase; }
.inv-lines td { padding: .35rem 0; border-bottom: 1px dotted var(--rule); }
.inv-lines th:nth-child(2), .inv-lines td:nth-child(2) { width: 2.5rem; text-align: center; }
.inv-lines th:last-child, .inv-lines td:last-child { text-align: right; }
.inv-totals { margin: .6rem 0 0; }
.inv-totals div { display: flex; justify-content: space-between; padding: .12rem 0; }
.inv-totals dt { color: var(--grey); }
.inv-totals dd { margin: 0; }
.inv-gross { margin-top: .2rem; padding-top: .35rem !important; border-top: 2px solid var(--charcoal); font-weight: 700; color: var(--charcoal); }
.inv-gross dt { color: var(--charcoal) !important; }
.inv-ura { display: grid; grid-template-columns: 1fr auto; gap: 1rem; align-items: center; margin-top: 1rem; padding: .85rem; border: 1px dashed var(--teal); border-radius: .35rem; background: #f7fbfa; }
.inv-ura p { display: grid; margin: 0 0 .35rem; }
.inv-ura p:last-child { margin-bottom: 0; }
.inv-ura .inv-label { color: var(--teal); }
.inv-key { color: var(--grey); font-size: .68rem; }
.inv-qr { width: 4.4rem; height: 4.4rem; padding: .25rem; background: #fff; }
.inv-qr-code { display: block; width: 100%; height: 100%; fill: var(--charcoal); }
.inv-stamp {
    position: absolute;
    right: 6.5rem;
    top: 17.4rem;
    margin: 0;
    padding: .35rem .8rem;
    border: 3px double var(--teal);
    border-radius: .3rem;
    color: var(--teal);
    background: rgba(255, 255, 255, .7);
    font-family: var(--sans);
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .14em;
    text-transform: uppercase;
    transform: rotate(-9deg);
}

/* The printing: the slip slides up, the lines print one by one, URA's part arrives, then the stamp lands. */
.js .invoice .invoice-paper { opacity: 0; transform: translateY(26px) rotate(1.2deg); transition: opacity .6s var(--ease), transform .8s var(--ease); }
.js .invoice .inv-lines tbody tr { opacity: 0; transition: opacity .35s ease; transition-delay: calc(.7s + var(--i) * .28s); }
.js .invoice .inv-totals { opacity: 0; transition: opacity .4s ease 1.65s; }
.js .invoice .inv-ura { opacity: 0; transform: translateY(6px); transition: opacity .45s ease 2.05s, transform .45s var(--ease) 2.05s; }
.js .invoice .inv-type { display: inline-block; overflow: hidden; white-space: nowrap; width: 0; vertical-align: bottom; transition: width .9s steps(17, end) 2.35s; }
.js .invoice .inv-qr { opacity: 0; transition: opacity .4s ease 3.1s; }
.js .invoice .inv-stamp { opacity: 0; transform: rotate(-9deg) scale(1.6); transition: opacity .2s ease 3.5s, transform .35s cubic-bezier(.3, 1.5, .5, 1) 3.5s; }
.js .invoice.is-visible .invoice-paper { opacity: 1; transform: rotate(1.2deg); }
.js .invoice.is-visible .inv-lines tbody tr,
.js .invoice.is-visible .inv-totals,
.js .invoice.is-visible .inv-qr { opacity: 1; }
.js .invoice.is-visible .inv-ura { opacity: 1; transform: none; }
.js .invoice.is-visible .inv-type { width: 17ch; }
.js .invoice.is-visible .inv-stamp { opacity: 1; transform: rotate(-9deg) scale(1); }

/* ------------------------------------------------------------------ split sections (text one side, the tool the other) */
.split { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 3.5rem; align-items: start; }
.split-side p { max-width: 30rem; }

.chooser { padding: 1.75rem; border: 1px solid var(--rule); border-radius: .6rem; background: #fff; }
.chooser-question { margin: 0 0 1rem; color: var(--charcoal); font-weight: 700; font-size: 1.15rem; }
.choices { display: grid; gap: .55rem; }
.choice {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: .85rem 1rem;
    border: 1px solid var(--rule);
    border-radius: .4rem;
    color: var(--charcoal);
    background: var(--paper);
    font-family: var(--sans);
    font-size: .98rem;
    text-align: left;
    cursor: pointer;
    transition: border-color .2s, background .2s;
}
.choice::after { color: var(--grey); content: "→"; transition: transform .2s var(--ease); }
.choice:hover { border-color: var(--teal); }
.choice:hover::after { transform: translateX(3px); }
.choice[aria-pressed="true"] { color: var(--teal-deep); background: var(--teal-tint); border-color: var(--teal); }
.choice[aria-pressed="true"]::after { color: var(--teal); content: "✓"; }
.answer { margin-top: 1.25rem; padding: 1rem 1.2rem; border-left: 3px solid var(--teal); background: var(--teal-tint); }
.answer p { margin: .3rem 0; }
.answer-mode { color: var(--teal-deep); font-weight: 700; font-size: 1.08rem; }
.modes-fold { margin-top: 1.25rem; }
.modes-fold summary { color: var(--teal); font-family: var(--sans); font-size: .93rem; font-weight: 600; cursor: pointer; }
.modes { width: 100%; margin-top: .9rem; border-collapse: collapse; font-family: var(--sans); font-size: .9rem; }
.modes th { padding: .5rem .6rem; border-bottom: 2px solid var(--charcoal); color: var(--charcoal); text-align: left; }
.modes td { padding: .5rem .6rem; border-bottom: 1px solid var(--rule); vertical-align: top; }
.modes .ours td { color: var(--teal-deep); font-weight: 700; }

/* ------------------------------------------------------------------ what happens to an invoice: a numbered margin */
.margin-list { margin: 2rem 0 0; padding: 0; list-style: none; }
.margin-list li { display: grid; grid-template-columns: 6rem minmax(0, 40rem); gap: 1.5rem; padding: 1.6rem 0; border-top: 1px solid var(--rule); }
.margin-list li:last-child { border-bottom: 1px solid var(--rule); }
.margin-num { color: var(--teal); font-family: var(--serif); font-size: 2.6rem; font-weight: 700; line-height: 1; font-variant-numeric: lining-nums; letter-spacing: -.03em; }
.margin-list h3 { font-size: 1.2rem; }
.margin-list p { margin: .3rem 0 0; color: var(--grey); }

/* ------------------------------------------------------------------ what you can rely on: plain prose in two columns */
.prose-columns { columns: 2 22rem; column-gap: 3.5rem; margin-top: 1.5rem; }
.prose-columns p { margin: 0 0 1.25rem; break-inside: avoid; }
.prose-columns strong { color: var(--charcoal); }

/* ------------------------------------------------------------------ a note from the director */
.note-band { padding-block: 4rem; }
.note-wrap { display: flex; justify-content: center; }
.founder-note { position: relative; max-width: 44rem; margin: 0; padding-left: 2.25rem; border-left: 3px solid var(--amber); }
.founder-note p { margin: 0 0 1rem; color: var(--charcoal); font-size: clamp(1.2rem, 2vw, 1.45rem); font-style: italic; line-height: 1.5; }
.founder-note footer { color: var(--charcoal); font-family: var(--sans); font-size: .95rem; font-weight: 700; }
.founder-note footer span { color: var(--grey); font-weight: 400; }

/* ------------------------------------------------------------------ pricing */
.estimator { margin-bottom: 1.75rem; padding: 1.5rem 1.75rem; border: 1px solid var(--rule); border-radius: .6rem; background: #fff; }
.estimator label { display: block; color: var(--charcoal); font-weight: 700; font-size: 1.08rem; }
.estimator-row { display: flex; align-items: center; gap: 1.25rem; margin: 1rem 0 .6rem; }
.estimator input[type="range"] { flex: 1; height: 1.5rem; accent-color: var(--teal); cursor: pointer; }
.estimator output { min-width: 4.75rem; padding: .3rem .7rem; border-radius: .35rem; color: var(--teal-deep); background: var(--teal-tint); font-family: var(--sans); font-size: 1.3rem; font-weight: 700; font-variant-numeric: tabular-nums; text-align: center; }
.estimate { margin: 0; color: var(--ink); }
.estimate strong { color: var(--teal-deep); }

.tiers { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); gap: 0; margin: 0 0 1.5rem; border: 1px solid var(--rule); border-radius: .6rem; background: #fff; overflow: hidden; }
.tier { position: relative; padding: 1.6rem 1.5rem; border-right: 1px solid var(--rule); transition: background .3s; }
.tier:last-child { border-right: 0; }
.tiers-status { grid-column: 1 / -1; margin: 0; padding: 1.6rem 1.5rem; color: var(--grey); }
.tier p { margin: .25rem 0; }
.tier.is-fit { background: var(--teal-tint); }
.tier.is-fit::before { position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--teal); content: ""; }
.tier.is-fit h3::after { margin-left: .5rem; padding: .1rem .5rem; border-radius: 1rem; color: #fff; background: var(--teal); font-family: var(--sans); font-size: .7rem; font-weight: 700; vertical-align: middle; content: "Fits you"; }
.price { color: var(--charcoal); font-size: 1.55rem; font-weight: 700; font-variant-numeric: lining-nums tabular-nums; white-space: nowrap; }
.price span { color: var(--grey); font-size: 1rem; font-weight: 400; }
.yearly { color: var(--grey); font-family: var(--sans); font-size: .88rem; font-variant-numeric: tabular-nums; }

/* ------------------------------------------------------------------ getting started: the events timeline */
.events {
    --step: .45s;
    --line-top: 3.6rem;
    position: relative;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
    margin: 2rem 0 1.5rem;
    padding: 0;
    list-style: none;
}
.events::before, .events::after { position: absolute; left: 10%; right: 10%; top: var(--line-top); height: 4px; border-radius: 2px; content: ""; }
.events::before { background: var(--rule); }
.events::after { right: auto; width: 0; background: linear-gradient(90deg, var(--teal) 0%, var(--teal-bright) 100%); transition: width calc(var(--step) * 4) linear .15s; }
.events.is-visible::after { width: 80%; }
.event { position: relative; display: grid; grid-template-rows: auto auto 1fr; justify-items: center; text-align: center; }
.event-when { padding: .2rem .65rem; border-radius: 1rem; color: var(--teal-deep); background: var(--teal-tint); font-family: var(--sans); font-size: .78rem; font-weight: 700; white-space: nowrap; }
.event-node {
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 2.6rem;
    height: 2.6rem;
    margin: .55rem 0 1rem;
    border: 3px solid var(--rule);
    border-radius: 50%;
    color: var(--grey);
    background: #fff;
    font-family: var(--sans);
    font-weight: 700;
    transform: scale(.75);
    transition: transform .35s var(--ease), background .35s, border-color .35s, color .35s, box-shadow .35s;
    transition-delay: calc(var(--i) * var(--step) + .15s);
}
.events.is-visible .event-node { border-color: var(--teal); color: #fff; background: var(--teal); transform: scale(1); box-shadow: 0 0 0 6px rgba(37, 107, 104, .12); }
.event-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    padding: 1rem;
    border: 1px solid var(--rule);
    border-radius: .6rem;
    background: #fff;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity .5s var(--ease), transform .5s var(--ease), border-color .25s;
    transition-delay: calc(var(--i) * var(--step) + .3s), calc(var(--i) * var(--step) + .3s), 0s;
}
.events.is-visible .event-card { opacity: 1; transform: none; }
.event:hover .event-card { border-color: var(--teal); }
.event-card h3 { margin-bottom: .3rem; }
.event-card p { margin: 0 0 .6rem; color: var(--grey); font-size: .95rem; line-height: 1.5; }
.event-who { margin-top: auto; color: var(--teal); font-family: var(--sans); font-size: .8rem; font-weight: 600; }
.event-live .event-node svg { width: 1.5rem; height: 1.5rem; stroke: var(--grey); stroke-width: 2.2; stroke-linecap: round; }
.events.is-visible .event-live .event-node { border-color: var(--amber); background: var(--amber); }
.events.is-visible .event-live .event-node svg { stroke: var(--charcoal); animation: sacc-turn 12s linear infinite; animation-delay: calc(4 * var(--step) + .5s); }
.events.is-visible .event-live .event-node::after {
    position: absolute;
    inset: -3px;
    border: 3px solid var(--amber);
    border-radius: 50%;
    opacity: 0;
    animation: sacc-ping 2.4s var(--ease) infinite;
    animation-delay: calc(4 * var(--step) + .5s);
    content: "";
}
@keyframes sacc-ping { 0% { opacity: .8; transform: scale(1); } 100% { opacity: 0; transform: scale(1.9); } }
.event-live .event-card { border-color: var(--amber); background: #fffaf0; }

/* ------------------------------------------------------------------ questions */
.faq { border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary { position: relative; padding: 1.05rem 2.25rem 1.05rem 0; color: var(--charcoal); font-weight: 700; list-style: none; cursor: pointer; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { position: absolute; right: .25rem; top: .95rem; color: var(--teal); font-family: var(--sans); font-size: 1.35rem; line-height: 1; transition: transform .25s var(--ease); content: "+"; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 1.1rem; max-width: 40rem; color: var(--grey); }

/* ------------------------------------------------------------------ contact and footer */
.contact { position: relative; overflow: hidden; background: linear-gradient(170deg, var(--teal-tint) 0%, #f6f9f7 65%, var(--paper) 100%); border-top: 1px solid var(--rule); }
.contact-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 3rem; align-items: center; }
.contact-text p { max-width: 32rem; }
.contact-card { padding: 1.75rem; border: 1px solid var(--rule); border-radius: .6rem; background: #fff; font-style: normal; box-shadow: 0 14px 36px rgba(34, 30, 31, .06); }
.contact-name { margin: 0 0 1rem; color: var(--charcoal); font-weight: 700; font-size: 1.12rem; }
.contact-lines { display: grid; gap: .85rem; margin: 0; padding: 0; list-style: none; font-family: var(--sans); font-size: .96rem; }
.contact-lines li { display: grid; grid-template-columns: 2.25rem 1fr; align-items: center; gap: .75rem; }
.contact-lines a { color: var(--ink); text-decoration: none; }
.contact-lines a:hover { color: var(--teal); text-decoration: underline; }
.contact-icon { display: grid; place-items: center; width: 2.25rem; height: 2.25rem; border-radius: 50%; background: var(--teal-tint); }
.contact-icon svg { width: 1.1rem; height: 1.1rem; fill: none; stroke: var(--teal); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.footer { padding-block: 1.25rem; border-top: 1px solid var(--rule); background: var(--paper); font-family: var(--sans); font-size: .9rem; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.footer img { width: 110px; }
.footer-link { color: var(--teal); font-weight: 600; text-decoration: none; margin-left: auto; }
.footer-link:hover { text-decoration: underline; }
.copyright { margin: 0; color: var(--grey); }

/* ------------------------------------------------------------------ narrow screens */
/* ---------------------------------------------------------------- after a sign-out */
.signed-out {
    margin: 0;
    padding: .7rem 1.25rem;
    border-bottom: 1px solid var(--rule);
    background: var(--teal-tint);
    color: var(--teal-deep);
    font-family: var(--sans);
    font-size: .93rem;
    text-align: center;
}
.signed-out a { margin-left: .4rem; font-weight: 600; }

/* ---------------------------------------------------------------- screens: real ones, in a plain window frame */
.screens { margin-top: .5rem; }
.screen-tabs { display: flex; flex-wrap: wrap; gap: .25rem; margin-bottom: 1rem; font-family: var(--sans); font-size: .93rem; }
.screen-tabs button {
    padding: .45rem .9rem;
    border: 1px solid transparent;
    border-radius: 2rem;
    background: none;
    color: var(--grey);
    font: inherit;
    cursor: pointer;
    transition: color .2s, background-color .2s, border-color .2s;
}
.screen-tabs button:hover { color: var(--teal); }
.screen-tabs button[aria-selected="true"] { border-color: var(--teal); background: var(--teal-tint); color: var(--teal-deep); font-weight: 600; }
.screen-tabs button:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }
.screen { margin: 0 0 2rem; }
.screen img {
    display: block;
    width: 100%;
    height: auto;
    border: 1px solid var(--rule);
    border-top: 1.4rem solid #e9eeec;   /* the window's title bar, without pretending to be a particular browser */
    border-radius: .5rem;
    box-shadow: 0 18px 40px -22px rgba(34, 30, 31, .35);
    background: #fff;
}
.screen-frame { border-radius: .5rem; }
.screen-frame:focus-visible { outline: 2px solid var(--teal); outline-offset: 3px; }
.screen-hint { display: none; margin: -1rem 0 1.25rem; color: var(--grey); font-family: var(--sans); font-size: .85rem; }
.screen figcaption { margin-top: .8rem; color: var(--grey); font-size: .95rem; }
/* Scripts on: one screen at a time, the chosen one easing in. Off: every screen, one under another, and no tabs. */
.screen-tabs { display: none; }
.js .screen-tabs { display: flex; }
.js .screen[hidden] { display: none; }
.js .screen.is-shown { animation: screen-in .45s var(--ease) both; }
@keyframes screen-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

@media (max-width: 900px) {
    .hero-grid, .split, .contact-grid { grid-template-columns: 1fr; gap: 2.5rem; }
    .invoice { margin-top: .5rem; }
    .inv-stamp { right: .5rem; }
    .margin-list li { grid-template-columns: 3.5rem 1fr; gap: 1rem; }
    .margin-num { font-size: 1.9rem; }
    .tier { border-right: 0; border-bottom: 1px solid var(--rule); }
    .tier:last-child { border-bottom: 0; }
    .events { grid-template-columns: 1fr; gap: 0; padding-left: 3.75rem; }
    .events::before, .events::after { left: 1.25rem; right: auto; top: 1.5rem; bottom: 1.5rem; width: 4px; height: auto; }
    .events::after { bottom: auto; height: 0; transition: height calc(var(--step) * 4) linear .15s; }
    .events.is-visible::after { width: 4px; height: calc(100% - 3rem); }
    .event { justify-items: start; text-align: left; padding-bottom: 1.25rem; }
    .event-node { position: absolute; left: -3.75rem; top: 1.65rem; margin: 0; }
    .event-when { margin-bottom: .5rem; }
}
@media (max-width: 640px) {
    /* A whole app screen at phone width is too small to read: show it at a readable size and let it scroll sideways,
       and keep the tabs on one swipeable row instead of wrapping. */
    .js .screen-tabs { flex-wrap: nowrap; overflow-x: auto; margin-inline: -1.25rem; padding-inline: 1.25rem; scrollbar-width: none; }
    .screen-tabs::-webkit-scrollbar { display: none; }
    .screen-tabs button { flex: 0 0 auto; }
    .screen-frame { overflow-x: auto; -webkit-overflow-scrolling: touch; box-shadow: 0 18px 40px -22px rgba(34, 30, 31, .35); }
    .screen-frame img { width: 760px; max-width: none; box-shadow: none; }
    .screen-hint { display: block; }
    .topbar nav a[data-nav] { display: none; }
    section { padding-block: 3rem; }
    .hero { padding-block: 3rem 3.5rem; }
    .estimator-row { flex-direction: column; align-items: stretch; }
    .inv-parties { grid-template-columns: 1fr; gap: .5rem; }
    .footer-inner { flex-wrap: wrap; }
}

/* ------------------------------------------------------------------ reduced motion: everything shown, nothing moving */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .js .invoice .invoice-paper, .js .invoice .inv-lines tbody tr, .js .invoice .inv-totals, .js .invoice .inv-ura,
    .js .invoice .inv-qr, .js .invoice .inv-stamp { opacity: 1; }
    .js .invoice .invoice-paper { transform: rotate(1.2deg); }
    .js .invoice .inv-ura { transform: none; }
    .js .invoice .inv-stamp { transform: rotate(-9deg); }
    .js .invoice .inv-type { width: auto; }
    .events::after { width: 80%; }
    .event-node, .event-card { opacity: 1; transform: none; }
}

/* ------------------------------------------------------------------ print: everything shown, nothing moving */
@media print {
    .screen-tabs { display: none !important; }
    .screen[hidden] { display: block !important; }
    .topbar, .sunburst, .estimator, .chooser .choices { display: none; }
    .js .invoice * { opacity: 1 !important; transform: none !important; width: auto !important; }
    .answer[hidden] { display: block; }
    .event-card { opacity: 1; transform: none; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* The 2-minute demo, in the browser's own player (demo-video.js). */
.demo { margin: 2rem 0 0; }
.demo-video { position: relative; overflow: hidden; border-radius: 12px; background: var(--charcoal, #221e1f); box-shadow: 0 18px 40px rgba(34, 30, 31, .16); aspect-ratio: 16 / 9; }
.demo-video video { display: block; width: 100%; height: 100%; object-fit: contain; background: #000; }
.demo-video-play { position: absolute; inset: 0; margin: auto; width: 5rem; height: 5rem; border: 0; border-radius: 50%; cursor: pointer; background: rgba(255, 255, 255, .94); box-shadow: 0 10px 30px rgba(0, 0, 0, .3); transition: transform .2s var(--ease, ease), background .2s; }
.demo-video-play::before { content: ""; position: absolute; left: 54%; top: 50%; transform: translate(-50%, -50%); border-style: solid; border-width: .85rem 0 .85rem 1.35rem; border-color: transparent transparent transparent var(--teal, #256b68); }
.demo-video-play::after { content: ""; position: absolute; inset: -9px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .8); animation: demo-ring 2.2s ease-out infinite; }
.demo-video-play:hover, .demo-video-play:focus-visible { transform: scale(1.08); background: #fff; outline: none; }
.demo-video.is-playing .demo-video-play { display: none; }
@keyframes demo-ring { from { transform: scale(.9); opacity: .9; } to { transform: scale(1.35); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .demo-video-play::after { animation: none; } }
.demo figcaption { margin-top: .6rem; color: var(--grey, #5d6565); font-size: .92rem; }
.demo-video-fallback { display: flex; align-items: center; justify-content: center; height: 100%; color: #fff; font-weight: 600; }
.demo-dialog { width: min(64rem, calc(100vw - 2rem)); padding: 0; border: 0; border-radius: 14px; background: #000; overflow: visible; }
.demo-dialog::backdrop { background: rgba(20, 18, 18, .82); }
.demo-dialog .demo-video { border-radius: 14px; box-shadow: none; }
.demo-dialog-close { position: absolute; top: -2.6rem; right: 0; width: 2.2rem; height: 2.2rem; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .92); color: #221e1f; font-size: 1.4rem; line-height: 1; cursor: pointer; }
.demo-dialog-note { position: absolute; bottom: -2rem; left: 0; margin: 0; color: #e8eceb; font-size: .85rem; }
.demo-dialog-note a { color: #fff; }

/* Hero: two buttons (book, watch), the text links on their own line below. */
.button-play { display: inline-flex; align-items: center; gap: .6rem; color: var(--teal); background: #fff; }
.button-play:hover { color: var(--teal-deep); background: var(--teal-tint); border-color: var(--teal-deep); }
.play-dot { position: relative; width: 1.35rem; height: 1.35rem; border-radius: 50%; background: var(--teal); transition: background .2s; }
.play-dot::before { content: ""; position: absolute; left: 55%; top: 50%; transform: translate(-50%, -50%); border-style: solid; border-width: .3rem 0 .3rem .48rem; border-color: transparent transparent transparent #fff; }
.button-play:hover .play-dot { background: var(--teal-deep); }
.actions-more { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; margin: 1rem 0 0; }
@media (max-width: 560px) { .actions .button { flex: 1 1 100%; text-align: center; justify-content: center; } }

