/* frame.css: the Jobgraph frame around the two views.
   The views are the show; the frame is a bar, and under the stage the readout of a deck's time in each
   firm with the one caption. Colours and type are Jobgraph's own (the landing-page preview's on-dark
   values); nothing is loaded from another origin.
   Type: one size (13px) and one weight (400) for everything the frame says, heavier only on the switch,
   the one action and the readout's two figures (the bar's weight, half as large again), and the large
   opening line. */

@font-face{font-family:Inter;font-weight:100 900;font-display:block;src:url(fonts/InterVariable.woff2) format("woff2")}

:root{
  --ink:#211c19; --raised:#2f2824; --line:#4a403a; --muted:#b6ada6; --white:#fff;
  --orange:#b9512e; --orange-deep:#8f3d23;
  --hot:#ff8a57;   /* the page's live orange, globe.css's --hot */
  --bar:60px;
  --out:cubic-bezier(.2,.8,.2,1);
}
*{box-sizing:border-box}
html,body{height:100%;margin:0;overflow:hidden}
body{background:var(--ink);color:var(--white);font:400 13px/1.35 Inter,sans-serif;-webkit-font-smoothing:antialiased;font-variant-numeric:tabular-nums}
h1,p{margin:0}
button{font:inherit;color:inherit}
svg{fill:none;stroke:currentColor;stroke-width:1.4;stroke-linecap:round;stroke-linejoin:round}
:focus-visible{outline:3px solid var(--orange);outline-offset:2px}
.vh{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
[hidden]{display:none !important}

/* ---------- the bar ---------- */
.bar{position:fixed;inset:0 0 auto 0;height:var(--bar);z-index:30;display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);align-items:center;gap:20px;padding:0 18px 0 24px;background:var(--ink)}
.bar-left{display:flex;align-items:center;gap:20px;min-width:0}
.logo{flex:none;display:block;border-radius:4px}
.logo img{display:block;width:130px;height:auto;filter:invert(1)}
.back{position:relative;flex:none;display:inline-flex;align-items:center;gap:6px;height:34px;padding:0 14px 0 10px;border-radius:999px;border:1px solid var(--line);background:var(--raised);color:var(--white);white-space:nowrap;cursor:pointer}
.back:hover{border-color:var(--muted)}
/* after a while on one desk the way back draws the eye once: one soft pulse, never a loop */
.back.cue{animation:nudge 1.8s cubic-bezier(.2,.6,.3,1) 1}
@keyframes nudge{0%{box-shadow:0 0 0 0 rgba(255,255,255,.55);border-color:var(--white)}60%{border-color:var(--white)}100%{box-shadow:0 0 0 16px rgba(255,255,255,0)}}
.back svg{width:12px;height:12px}

/* the switch: the one unmissable control */
.flip{position:relative;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);height:46px;padding:4px;border-radius:999px;border:1px solid var(--line);background:var(--raised);font-weight:700;font-size:15px;letter-spacing:-.015em;color:var(--muted);cursor:pointer}
.flip .thumb{position:absolute;top:4px;bottom:4px;left:4px;width:calc(50% - 4px);border-radius:999px;background:var(--white);transition:transform .5s cubic-bezier(.5,0,.15,1)}
.flip[aria-checked="true"] .thumb{transform:translateX(100%)}
.flip .opt{position:relative;display:flex;align-items:center;justify-content:center;gap:9px;padding:0 24px;white-space:nowrap;border-radius:999px;transition:color .3s}
.flip .opt i{width:8px;height:8px;border-radius:50%;background:var(--orange)}
.flip .opt:hover{color:var(--white)}
.flip[aria-checked="false"] .today,.flip[aria-checked="true"] .rebuilt{color:var(--ink)}
.flip::after{content:"";position:absolute;inset:-1px;border-radius:999px;pointer-events:none}
.flip.cue::after{animation:cue 1.7s cubic-bezier(.2,.6,.3,1) 1}
.flip.cue .rebuilt{animation:cue-word 1.7s 1}
@keyframes cue{0%{box-shadow:0 0 0 0 rgba(185,81,46,.95)}100%{box-shadow:0 0 0 22px rgba(185,81,46,0)}}
@keyframes cue-word{0%,70%{color:var(--white)}}

.bar-right{display:flex;align-items:center;justify-content:flex-end;gap:8px;min-width:0}
.pause{display:inline-flex;align-items:center;gap:9px;height:40px;padding:0 14px;border-radius:999px;border:1px solid var(--line);background:none;white-space:nowrap;cursor:pointer}
.pause:hover{border-color:var(--muted)}
.pause svg{width:11px;height:11px;fill:currentColor;stroke:none}
.pause .ic-play{display:none}
.pause[aria-pressed="true"] .ic-play{display:inline}
.pause[aria-pressed="true"] .ic-pause{display:none}
.pause[aria-pressed="true"] .clock{color:var(--muted)}
.clock{min-width:4.9em;text-align:left}
.call{display:inline-flex;align-items:center;height:40px;padding:0 19px;border-radius:999px;background:var(--orange);color:var(--white);font-weight:700;font-size:15px;letter-spacing:-.01em;text-decoration:none;white-space:nowrap}
.call:hover{background:var(--orange-deep)}
.call:focus-visible,.flip:focus-visible{outline-color:var(--white)}

/* ---------- the stage, and the one line under it ---------- */
.main{position:fixed;top:var(--bar);left:0;right:0;bottom:0;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr) auto;container:main / inline-size}
.stage{grid-row:1;position:relative;overflow:hidden;background:var(--ink)}
.layer{position:absolute;inset:0;overflow:hidden;background:var(--ink);transform-origin:50% 50%;z-index:1}
.layer.off{opacity:0;pointer-events:none}
body.is-boot .layer.office{opacity:0;pointer-events:none}
.stage.flipping .layer{pointer-events:none;will-change:transform}
iframe{position:absolute;inset:0;width:100%;height:100%;border:0;display:block;background:var(--ink)}
iframe.desk{opacity:0;pointer-events:none;visibility:hidden}
iframe.desk.on{opacity:1;pointer-events:auto;visibility:visible}
.seed{position:absolute;left:50%;top:50%;width:10px;height:10px;border-radius:50%;background:var(--orange);opacity:0;transform:translate(-50%,-50%);z-index:4;pointer-events:none}

/* the opening line: large on an empty stage for a few seconds; the office swells up as it leaves */
.opening{position:absolute;inset:0;z-index:5;container-type:inline-size;display:flex;flex-direction:column;justify-content:center;align-items:flex-start;padding:0 24px 7vh;pointer-events:none}
.opening h1{font-weight:800;font-size:min(7.2cqw,104px);letter-spacing:-.04em;line-height:1.05;white-space:nowrap;animation:rise .7s var(--out) both}
.opening p{margin-top:.9em;font-size:clamp(17px,1.7cqw,22px);line-height:1.42;color:var(--muted);max-width:29em;animation:rise .7s .14s var(--out) both}
@keyframes rise{from{opacity:0;transform:translateY(22px)}}

/* the foot: the readout, and directly under it the one caption, so the figures never show without it.
   The readout is one row: the deck's name, then each firm's label, figure and a few words, every one of
   them an item of the one row (a side is display:contents), so only the name and the words can give
   way, cut short; a label and a figure never are. The line keeps its height
   whatever it says, so the stage does not move when the call note or a hint takes its turn. */
.foot{grid-row:2;min-width:0;display:flex;flex-direction:column;align-items:stretch;padding:5px 24px 8px;color:var(--muted);line-height:1.3}
.say{--fig:20px;min-width:0;height:30px;line-height:30px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;opacity:0;transition:opacity .4s}
.say.on{opacity:1}
.say .deck,.say .note,.say .hint{display:none}
.say[data-kind="deck"] .deck{display:flex}
.say[data-kind="note"] .note{display:inline}
.say[data-kind="hint"] .hint{display:inline}
.say .deck{align-items:baseline;gap:0 8px;min-width:0}
.say .name{flex:0 1 auto;min-width:3em;margin-right:24px;color:var(--white);overflow:hidden;text-overflow:ellipsis}
.say .side{display:contents}
.say .jobgraph .k{margin-left:24px}
.say .k,.say .fig{flex:none}
.say .fig{font-weight:700;font-size:var(--fig);line-height:var(--fig);letter-spacing:-.015em;color:var(--white)}   /* a line no taller than the figure, so the row keeps the line's height */
.say .jobgraph .fig{color:var(--hot)}
.say .more{flex:0 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis}
.say .more:empty{display:none}
.cap{flex:none}

/* ---------- narrower windows ---------- */
@media (max-width:1240px){.clock{display:none}}
@media (max-width:1180px){.logo img{width:114px}.flip{font-size:14.5px}.flip .opt{padding:0 18px}}
@media (max-width:1060px){
  :root{--bar:108px}
  .bar{grid-template-columns:minmax(0,1fr) auto;grid-template-rows:54px 54px;gap:0 10px}
  .flip{grid-column:1 / -1;grid-row:2;justify-self:center;width:min(480px,100%);height:44px}
}
@media (max-width:760px){
  .bar{padding:0 12px}
  .flip .opt{padding:0 10px;white-space:normal;text-align:center;line-height:1.1;text-wrap:balance}
  .logo img{width:104px}
  .back span{display:none}
  .back{padding:0 9px}
  .bar-left{gap:10px}
  .call{padding:0 15px}
  .foot{padding-left:12px;padding-right:12px}
  /* the readout in three rows, the name over each firm's: the line is the three rows' height, 74px,
     whatever it says; the call note or a hint takes at most two of its 28px lines */
  .say{height:calc(18px + 2 * 28px);line-height:28px;white-space:normal}
  .say[data-kind="deck"] .deck{flex-direction:column;align-items:stretch}
  .say .name{margin-right:0;line-height:18px;white-space:nowrap}
  .say .side{display:flex;align-items:baseline;gap:0 8px;min-width:0;height:28px;white-space:nowrap}
  .say .jobgraph .k{margin-left:0}
  .opening{padding:0 14px 7vh}.opening h1{font-size:min(11.5cqw,64px);white-space:normal;text-wrap:balance}
}
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{transition-duration:.01ms !important;animation-duration:.01ms !important;animation-iteration-count:1 !important}
}
