/* status.css: the styles of screens/status.js. OWNER: the status builder.
   The rules of ortuzar.css hold here too, and a unit test reads this file for them: the five colours (as the
   variables --paper, --ink, --grey, --rule, --red; write no colour value here), the five type sizes (14, 17, 20, 27,
   30; reading and typed text 16), the weights 300, 400 and 500, the spacing scale (--s1 to --s8), no shadow, no
   rounded corner, no motion. The shared pieces of a form (the label above, the ruled line, the row of words, the
   black bar, the list under a name field) are in ortuzar.css: use them, do not restyle them here.
   Begin every selector with the screen's own name, so that nothing here can change another screen. */

/* ---- the head of the form: the work's caption line, as the mockup draws it (reserve.html) ---- */
.status-screen .head{padding-bottom:0}
.status-screen .head h1{font-weight:300}
/* "AO 4602  $150,000  now Available". The last part may be a whole sentence ("now Reserved for ... on behalf of ...
   until ..."), so unlike the line under a show's name it is allowed to wrap. */
.status-screen .status-now{margin-top:var(--s1);display:flex;flex-wrap:wrap;gap:0 var(--s3)}
/* the grey words opposite "Cancel" give way on a narrow screen, where the two do not fit on one line */
.status-screen .crumb>span{display:block;flex:0 1 auto;text-align:right}
.status-screen .crumb>a{flex:0 0 auto;white-space:nowrap}

/* ---- before the fields: the row is being asked for, or could not be ---- */
.status-screen .status-wait{padding-top:var(--s5)}
.status-screen .status-wait p+p{margin-top:var(--s3)}
/* "Updated from the server": said once, above the fields it changed */
.status-screen .status-stale{padding-top:var(--s5)}

/* ---- "On behalf of": a name here is linked to a client's record or kept as text; no contact is ever made from it.
   So the name field's own line ("New contact: ...") and its offer of a new contact are left out here, and the
   form says in their place what will happen (the current app's words). ---- */
.status-screen .status-obo .hint{display:none}
.status-screen .status-obo .sugg li:has(> button.pick.grey){display:none}
.status-screen .status-obo-say{padding-top:var(--s1)}

/* ---- a date: the browser's own small calendar picture is not drawn (words, not icons); a tap anywhere on the
   line opens the browser's calendar ---- */
.status-screen input[type=date]{position:relative}
.status-screen input[type=date]::-webkit-calendar-picker-indicator{position:absolute;left:0;top:0;width:100%;height:100%;margin:0;padding:0;opacity:0;cursor:pointer}
.status-screen input[type=date]::-webkit-date-and-time-value{text-align:left}
/* the date stands at the left edge of its line, as typed text does (the browser's own date field sets it in a little) */
.status-screen input[type=date]::-webkit-datetime-edit,.status-screen input[type=date]::-webkit-datetime-edit-fields-wrapper{padding:0}

/* ---- under the fields: what else a press does, and the way back to the documents' status ---- */
.status-screen .status-info{padding-top:var(--s5)}
.status-screen .status-docs{padding-top:var(--s5)}
.status-screen .status-docs p+p{padding-top:var(--s4)}
/* while a save is being checked or finished the fields stay where they are but cannot be changed: they go grey */
.status-screen .status-frozen,.status-screen .status-frozen input{color:var(--grey)}

/* ---- above the black bar: what the bar is about when it is not the fields (a revert being asked about, a save
   being checked or finished), then the one red sentence, a colleague's change with its two choices, or what went
   wrong. On the phone it stands on the bar at the foot of the screen, so that it is read before the bar is pressed
   and nothing in the form moves when it comes. ---- */
.status-screen .status-say{background:var(--paper);border-top:1px solid var(--rule);padding:var(--s3) var(--gutter) var(--s4);max-height:40vh;overflow-y:auto}
.status-screen .status-sum:not([hidden]) + .status-say{border-top:0;padding-top:0}
.status-screen .status-say p+p,.status-screen .status-say div+p,.status-screen .status-say p+div,.status-screen .status-say div+div{margin-top:var(--s2)}
.status-screen .status-say .warn{padding-top:0}
.status-screen .status-say .status-choices{display:flex;gap:var(--s6);padding-top:var(--s3)}
/* a long sentence on the bar wraps; it is kept clear of the edges of the screen */
.status-screen .savebar .primary{padding-left:var(--gutter);padding-right:var(--gutter)}
@media(min-width:900px){
  .status-screen .status-say{border-top:0;padding:0 0 var(--s4);max-height:none;overflow:visible}
  .status-screen .savebar .primary{padding-left:var(--s4);padding-right:var(--s4)}
}

/* ---- on a work's page: the history of its status, ruled like a list ---- */
.status-history .status-log{border-top:1px solid var(--rule)}
.status-history .status-log li{padding:var(--s3) 0;border-bottom:1px solid var(--rule)}
.status-history .status-log li p+p{margin-top:2px}
/* the one line above the works that says a status was saved as Discreet went on (shown once; see screens/status.js cutNotice) */
.status-cut{padding-bottom:var(--s3)}
