/* ==========================================================================
   Coebly /operators/ : "Work Ticket" look (Stage 2) + self-hosted type (Stage 3)
   Loaded by operators/index.html only, after ../style.css. Overrides only;
   the shared stylesheet and the homepage are untouched. No JavaScript.
   Replaces video-v2.css (its two rules are carried below).
   ========================================================================== */

/* ---- Stage 3: one font file, served from this site. SIL Open Font License. */
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url("archivo-latin.woff2") format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---- palette: ticket stock, ballpoint ink, canary and pink copies ---------- */
:root {
  --paper: #F5F0E3;          /* ticket stock */
  --white: #FFFDF7;
  --text-dark: #1C1F2A;      /* ballpoint ink */
  --muted-dark: #3E4350;     /* 9.3:1 on ticket stock */
  --hairline: #1C1F2A;
  --canary: #F2C94C;         /* ink on canary 10.4:1 */
  --canary-deep: #E9BC2F;
  --pink: #EFB8B0;
  --stock-dark: #EDE6D3;
  --carbon: #2E4A86;         /* 7.0:1 on ticket stock */
  --sky-dark: var(--carbon);
  --focus: var(--carbon);
  --accent-gradient: var(--canary);
  --radius: 6px;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --font: "Archivo", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
}

body {
  font-size: 1.0625rem;
  line-height: 1.6;
}

h1, h2, h3 {
  font-stretch: 112%;
  font-weight: 750;
  letter-spacing: -0.01em;
}

/* ---- header: cab navy stays; the demo link becomes a 44px canary button --- */
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 1rem;
  background: var(--canary);
  color: var(--text-dark);
  font-weight: 700;
  border: 2px solid var(--canary);
  border-radius: var(--radius);
}

.site-nav a:hover {
  background: var(--canary-deep);
  border-color: var(--canary-deep);
}

/* ---- hero ----------------------------------------------------------------- */
.hero-paper {
  background: var(--paper);
  padding: 2.5rem 0 3.5rem;
}

.hero h1 {
  font-size: clamp(2.75rem, 9vw, 5rem);
  font-stretch: 118%;
  font-weight: 800;
  line-height: 1.02;
}

.hero-paper .hero-sub {
  font-size: clamp(1.125rem, 2.4vw, 1.25rem);
  color: var(--text-dark);
}

.hero-actions {
  gap: 0.75rem;
}

/* every call to action is a bordered button, 54px tall, thumb-sized */
.btn,
.hero-actions .link-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 0 1.5rem;
  border: 2px solid var(--text-dark);
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 1.0625rem;
  line-height: 1.2;
  text-decoration: none;
  color: var(--text-dark);
}

.btn-primary {
  background: var(--canary);
}

.btn-primary:hover {
  filter: none;
  background: var(--canary-deep);
}

.hero-actions .link-secondary {
  background: var(--white);
}

.hero-actions .link-secondary:hover {
  background: var(--stock-dark);
}

/* ---- sections: double rule between them, two paper tones alternate -------- */
.section {
  border-top: 3px double var(--text-dark);
}

.section-white {
  background: var(--paper);
}

.section-paper {
  background: var(--stock-dark);
}

.section h2 {
  font-size: clamp(1.8125rem, 4.2vw, 2.875rem);
  line-height: 1.1;
}

.section-lead,
.video-caption,
.faq details p,
.steps li,
.labor-math-note,
.callout-sub {
  color: var(--muted-dark);
}

/* ---- video ---------------------------------------------------------------- */
.video-frame.video-frame-wide {
  max-width: 56rem;
  aspect-ratio: 16 / 9;
  border: 2px solid var(--text-dark);
  border-radius: 8px;
}

.video-frame video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
  background: var(--ink);
}

.video-caption {
  font-size: 1rem;
}

/* ---- three habits: three ticket stubs ------------------------------------- */
.steps {
  gap: 1.125rem;
}

.steps li {
  background: var(--white);
  border: 1.5px solid var(--text-dark);
  border-top: 3px dashed var(--text-dark);
  border-radius: 4px;
  padding: 1.25rem 1.25rem 1.25rem 4.25rem;
}

.steps li::before {
  left: 1.25rem;
  top: 1.25rem;
  width: 2.25rem;
  height: 2.25rem;
  font-family: var(--mono);
  background: var(--text-dark);
  color: var(--paper);
}

.steps h3 {
  font-size: 1.25rem;
}

/* the review promise: a navy band, the one line he came to read */
.callout {
  background: var(--ink);
  color: var(--text-light);
  border: 2px solid var(--text-dark);
  border-left-width: 2px;
  border-radius: var(--radius);
  padding: 1.75rem 1.5rem;
  max-width: none;
}

.callout-lead {
  font-stretch: 112%;
  font-weight: 800;
  font-size: clamp(1.5rem, 3.6vw, 2.375rem);
  line-height: 1.15;
  color: var(--text-light);
}

.callout-sub {
  color: #D9D5EE;
}

/* ---- second job: the math card on ruled ticket paper ---------------------- */
.labor-math {
  background-color: var(--white);
  background-image: repeating-linear-gradient(to bottom, transparent 0, transparent 27px,
    #C3CFDD 27px, #C3CFDD 28px);
  border: 1.5px solid var(--text-dark);
  border-left-width: 1.5px;
  border-radius: 4px;
  padding: 1.25rem;
}

.labor-math-lead {
  font-weight: 700;
  font-size: 1.1875rem;
  line-height: 1.4;
  background: var(--white);
}

.labor-math-note {
  font-family: var(--mono);
  font-size: 0.875rem;
  background: var(--white);
}

/* ---- faq: 64px rows, a plus that turns into a minus ----------------------- */
.faq {
  border-top: 2px solid var(--text-dark);
}

.faq details {
  border-bottom: 2px solid var(--text-dark);
}

.faq summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 64px;
  padding: 0.75rem 0;
  font-size: 1.125rem;
  font-weight: 700;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  flex: none;
  font-family: var(--mono);
  font-size: 1.5rem;
  line-height: 1;
}

.faq details[open] summary::after {
  content: "\2013";
}

.faq summary:hover {
  color: var(--carbon);
}

/* ---- contact form: a ticket with a canary header -------------------------- */
.form {
  background: var(--white);
  border: 1.5px solid var(--text-dark);
  border-radius: 4px;
  overflow: hidden;
  padding: 0 1.125rem 1.375rem;
}

.form-label {
  margin: 0 -1.125rem 1.25rem;
  padding: 0.875rem 1.125rem;
  background: #F7E08F;
  border-bottom: 2px solid var(--text-dark);
  font-size: 1.0625rem;
}

.field label {
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.field input,
.field textarea {
  min-height: 54px;
  font-size: 1.0625rem;
  border: 2px solid var(--text-dark);
  border-radius: 4px;
  padding: 0.75rem 0.875rem;
}

.form .btn {
  width: 100%;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

/* ---- footer: 44px link rows ------------------------------------------------ */
.footer-note {
  border-bottom-color: #3A3762;
}

.footer-meta a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--canary);
}

.footer-meta a:hover {
  color: #FFFFFF;
}

/* ---- ≥ 48em ---------------------------------------------------------------- */
@media (min-width: 48em) {
  .hero-paper {
    padding: 4rem 0 5rem;
  }

  .steps {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.125rem;
  }

  .steps li {
    max-width: none;
  }

  .callout {
    padding: 2.5rem 2.25rem;
  }

  .form .btn {
    width: auto;
  }
}

/* ---- Stage 2b: the hero drawing and three icons. No images, no script. ---- */
.btn-ic {
  width: 1.125rem;
  height: 1.125rem;
  margin-right: 0.6rem;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linejoin: round;
}

.btn-primary .btn-ic path:only-child {
  fill: currentColor;
  stroke: none;
}

.callout {
  display: flex;
  gap: 1.125rem;
  align-items: flex-start;
}

.callout-mark {
  flex: none;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: var(--canary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.callout-mark svg {
  width: 1.5rem;
  height: 1.5rem;
  fill: none;
  stroke: var(--text-dark);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.callout-body {
  min-width: 0;
}

.ticket-stack {
  position: relative;
  width: 100%;
  max-width: 24rem;
  height: 20.5rem;
  margin: 2.25rem auto 0;
}

.pile {
  position: absolute;
  inset: 0;
}

.snap0,
.spacer {
  display: none;
}

.sheet {
  position: absolute;
  width: 62%;
  height: 16.5rem;
  border: 1.5px solid var(--text-dark);
  border-radius: 3px;
  padding: 0.875rem 1rem;
  display: flex;
  flex-direction: column;
  background-image: repeating-linear-gradient(to bottom, transparent 0, transparent 25px,
    #C3CFDD 25px, #C3CFDD 26px);
  cursor: pointer;
  transition: left 0.3s ease, top 0.3s ease, transform 0.3s ease;
}

/* The papers flip on tap: three radios decide which one is in front.
   Slots: front (left 0), middle (left 11%), back (left 22%). */
.sheet-pick {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  opacity: 0;
}

#sheet-record:checked ~ .sheet-white,
#sheet-customer:checked ~ .sheet-canary,
#sheet-state:checked ~ .sheet-pink,
#sheet-ledger:checked ~ .sheet-ledger {
  left: 2%;
  top: 0.5rem;
  z-index: 4;
  transform: rotate(-2deg);
}

#sheet-record:checked ~ .sheet-canary,
#sheet-customer:checked ~ .sheet-pink,
#sheet-state:checked ~ .sheet-ledger,
#sheet-ledger:checked ~ .sheet-white {
  left: 12%;
  top: 1rem;
  z-index: 3;
  transform: rotate(2deg);
}

#sheet-record:checked ~ .sheet-pink,
#sheet-customer:checked ~ .sheet-ledger,
#sheet-state:checked ~ .sheet-white,
#sheet-ledger:checked ~ .sheet-canary {
  left: 22%;
  top: 1.5rem;
  z-index: 2;
  transform: rotate(5deg);
}

#sheet-record:checked ~ .sheet-ledger,
#sheet-customer:checked ~ .sheet-white,
#sheet-state:checked ~ .sheet-canary,
#sheet-ledger:checked ~ .sheet-pink {
  left: 32%;
  top: 2rem;
  z-index: 1;
  transform: rotate(8deg);
}

#sheet-record:focus-visible ~ .sheet-white,
#sheet-ledger:focus-visible ~ .sheet-ledger,
#sheet-customer:focus-visible ~ .sheet-canary,
#sheet-state:focus-visible ~ .sheet-pink {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.sheet-pink {
  background-color: #F4C9C2;
}

.sheet-canary {
  background-color: #F7E08F;
}

.sheet-white {
  background-color: #FFFFFF;
}

/* the ledger: green grid paper, no figures */
.sheet-ledger {
  background-color: #E6EFDF;
  /* a blank ledger: four column rules, item rows, a double rule over the
     totals line. Drawn only; no headings, no figures. */
  background-image:
    linear-gradient(to right,
      transparent calc(24% - 0.75px), #6F8F66 calc(24% - 0.75px), #6F8F66 calc(24% + 0.75px),
      transparent calc(24% + 0.75px), transparent calc(56% - 0.75px), #6F8F66 calc(56% - 0.75px),
      #6F8F66 calc(56% + 0.75px), transparent calc(56% + 0.75px), transparent calc(76% - 0.75px),
      #6F8F66 calc(76% - 0.75px), #6F8F66 calc(76% + 0.75px), transparent calc(76% + 0.75px)),
    linear-gradient(to bottom,
      transparent 70%, #3E5A37 70%, #3E5A37 calc(70% + 1.5px), transparent calc(70% + 1.5px),
      transparent calc(70% + 4px), #3E5A37 calc(70% + 4px), #3E5A37 calc(70% + 5.5px),
      transparent calc(70% + 5.5px)),
    repeating-linear-gradient(to bottom, transparent 0, transparent 21px,
      #A9BFA0 21px, #A9BFA0 22px);
  background-size: 100% calc(70% - 0.875rem), 100% 100%, 100% 100%;
  background-position: 0 0.875rem, 0 0, 0 0;
  background-repeat: no-repeat, no-repeat, repeat;
}

.sheet-ledger .sheet-head {
  border-bottom-width: 2.5px;
}

.sheet-ledger .sheet-lines {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  background-color: inherit;
}

.sheet-head,
.sheet-lines,
.sheet-lines span,
.sheet-stamp {
  display: block;
}

.sheet-tag {
  display: block;
  font-family: var(--mono);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: right;
  color: var(--text-dark);
}

.sheet-tag span {
  white-space: nowrap;
}

.sheet-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--text-dark);
  background-color: inherit;
}

.sheet-brand {
  font-stretch: 118%;
  font-weight: 800;
  font-size: 1.0625rem;
  color: var(--text-dark);
}

.sheet-lines {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
  padding-top: 1.125rem;
}

.sheet-lines span {
  display: block;
  font-family: var(--mono);
  font-size: 0.6rem;
  line-height: 1.5;
  letter-spacing: 0;
  color: var(--text-dark);
  white-space: normal;
  padding-bottom: 0.1rem;
  border-bottom: 1.5px solid var(--text-dark);
}

.sheet-stamp {
  margin-top: auto;
  align-self: flex-end;
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--carbon);
  border: 2.5px solid var(--carbon);
  border-radius: 4px;
  padding: 0.25rem 0.625rem;
  background-color: inherit;
  transform: rotate(-6deg);
}

@media (min-width: 48em) {
  .hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 24rem;
    gap: 3rem;
    align-items: center;
  }

  .hero-copy {
    min-width: 0;
  }

  .hero-grid .ticket-stack {
    margin: 0;
  }
}

/* Swipe shuffles the pile on touch screens. An invisible sideways snap track
   drives the papers between slots: one swipe, the front paper goes to the
   back and the rest move up one. Mouse and trackpad devices, and browsers
   without scroll-driven animation, keep the click version above. No script. */
@supports (animation-timeline: scroll()) {
  .ticket-stack:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: 3px;
  }

  @media (pointer: coarse) {
    .ticket-stack {
      display: flex;
      overflow-x: auto;
      overflow-y: hidden;
      scroll-snap-type: x mandatory;
      overscroll-behavior-x: contain;
      -webkit-overflow-scrolling: touch;
      scrollbar-width: none;
    }

    .ticket-stack::-webkit-scrollbar {
      display: none;
    }

    .snap0,
    .spacer {
      display: block;
      flex: 0 0 100%;
      height: 100%;
      scroll-snap-align: start;
      scroll-snap-stop: always;
    }

    .snap0 {
      flex-basis: 1px;
    }

    .pile {
      display: block;
      flex: 0 0 100%;
      height: 100%;
      position: sticky;
      inset: auto;
      left: 0;
    }

    .sheet-pick {
      display: none;
    }

    .sheet {
      cursor: grab;
      transition: none;
      animation-timing-function: linear;
      animation-fill-mode: both;
      animation-timeline: scroll(nearest inline);
    }

    .sheet-white  { animation-name: shuffle-0; }
    .sheet-canary { animation-name: shuffle-1; }
    .sheet-pink   { animation-name: shuffle-2; }
    .sheet-ledger { animation-name: shuffle-3; }

    @keyframes shuffle-0 {
      0% { left: 2%; top: 0.5rem; transform: rotate(-2deg); z-index: 4; }
      33.333% { left: 32%; top: 2rem; transform: rotate(8deg); z-index: 1; }
      66.667% { left: 22%; top: 1.5rem; transform: rotate(5deg); z-index: 2; }
      100% { left: 12%; top: 1rem; transform: rotate(2deg); z-index: 3; }
    }

    @keyframes shuffle-1 {
      0% { left: 12%; top: 1rem; transform: rotate(2deg); z-index: 3; }
      33.333% { left: 2%; top: 0.5rem; transform: rotate(-2deg); z-index: 4; }
      66.667% { left: 32%; top: 2rem; transform: rotate(8deg); z-index: 1; }
      100% { left: 22%; top: 1.5rem; transform: rotate(5deg); z-index: 2; }
    }

    @keyframes shuffle-2 {
      0% { left: 22%; top: 1.5rem; transform: rotate(5deg); z-index: 2; }
      33.333% { left: 12%; top: 1rem; transform: rotate(2deg); z-index: 3; }
      66.667% { left: 2%; top: 0.5rem; transform: rotate(-2deg); z-index: 4; }
      100% { left: 32%; top: 2rem; transform: rotate(8deg); z-index: 1; }
    }

    @keyframes shuffle-3 {
      0% { left: 32%; top: 2rem; transform: rotate(8deg); z-index: 1; }
      33.333% { left: 22%; top: 1.5rem; transform: rotate(5deg); z-index: 2; }
      66.667% { left: 12%; top: 1rem; transform: rotate(2deg); z-index: 3; }
      100% { left: 2%; top: 0.5rem; transform: rotate(-2deg); z-index: 4; }
    }
  }

}

.flip,
.flip-cue {
  display: none;
}

/* Mouse and trackpad: a click flips the pile. Clicking the front paper sends
   it to the back, in the same order as a swipe; clicking a paper behind
   brings it forward. A cue under the pile says so. Touch screens see none of
   this. No script. */
@media (hover: hover) and (pointer: fine) {
  .pile {
    -webkit-user-select: none;
    user-select: none;
  }

  #sheet-record:checked ~ .flip-to-customer,
  #sheet-customer:checked ~ .flip-to-state,
  #sheet-state:checked ~ .flip-to-ledger,
  #sheet-ledger:checked ~ .flip-to-record {
    display: block;
    position: absolute;
    left: 2%;
    top: 0.5rem;
    z-index: 5;
    width: 62%;
    height: 16.5rem;
    transform: rotate(-2deg);
    cursor: pointer;
  }

  .flip-cue {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 0.25rem;
    font-family: var(--mono);
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-align: center;
    color: var(--muted-dark);
  }
}

/* The narrowest phones (under 360px): wrapped lines need room above the
   stamp, so line spacing tightens and line type steps down slightly. */
@media (max-width: 22.4375rem) {
  .sheet-lines {
    gap: 0.5rem;
    padding-top: 0.75rem;
  }

  .sheet-lines span {
    font-size: 0.5625rem;
  }

  .sheet-tag {
    font-size: 0.5625rem;
    letter-spacing: 0.04em;
  }

  .sheet-stamp {
    font-size: 0.625rem;
    letter-spacing: 0.06em;
  }
}
