/* =========================================================================
   css/request.css  —  the rental request page at /request
   -------------------------------------------------------------------------
   Everything here is scoped under #view-request or a .rq- prefix. The page
   reuses the site's own variables, so it inherits the type and colour
   without redefining any of it.

   The states the page can be in are driven by classes on #view-request:
     .is-returning   the email is on file
     .is-unverified  on file, but this device has not proved it yet
   Rules for those live at the bottom.
   ========================================================================= */
#view-request .rq-grid{display:grid;grid-template-columns:1.3fr 0.9fr;gap:44px;}
#view-request .rq-grid > *{min-width:0;}
  @media(max-width:900px){
#view-request .rq-grid{grid-template-columns:1fr;gap:26px;}
/* On a phone the quote leads: what you are asking for comes before
       what we are asking you. */
#view-request .rq-grid > div:last-child{order:-1;}
  }
#view-request h1.rq-h{font-family:var(--ts-display);font-size:32px;margin:0 0 6px;}
/* A sentence now, not a three-word tag, so it wraps on anything narrow.
   align-items:flex-start keeps the warning sign on the first line instead of
   floating to the middle of a three-line block, and the radius comes down
   from a pill's 999px - which gives a wrapped box big semicircular ends - to
   the same 10px the other notes on this page use. */
#view-request .notres{display:inline-flex;align-items:flex-start;gap:7px;
    margin:8px 0 22px;padding:8px 13px;border-radius:10px;max-width:60ch;
    background:#FDF6E3;border:1px solid #ECD9A8;color:#7A4E00;font-size:12.5px;
    line-height:1.5;}
#view-request .sec{background:var(--ts-card);border:1.5px solid var(--ts-line);border-radius:var(--ts-radius-card);
    padding:20px 22px;margin:0 0 14px;}
#view-request .sec-h{display:flex;align-items:baseline;gap:10px;margin:0 0 16px;}
#view-request .sec-n{font-family:var(--ts-mono);font-size:11px;color:var(--ts-mute);}
#view-request .sec-h h2{font-family:var(--ts-display);font-size:19px;margin:0;}
#view-request .grp{font-family:var(--ts-mono);font-size:10.5px;letter-spacing:.07em;text-transform:uppercase;
    color:var(--ts-red);font-weight:600;margin:26px 0 15px;}
/* A heading that opens a section already has the section head above it. */
#view-request .sec-h + .grp{margin-top:0;}
#view-request .grp.plain{color:var(--ts-mute);font-weight:400;}
#view-request label.fld{display:block;font-family:var(--ts-mono);font-size:10.5px;letter-spacing:.06em;
    text-transform:uppercase;color:var(--ts-mute);margin:0 0 5px;}
#view-request .fw{margin:0 0 14px;}
/* The row gap alone spaces the rows; without this the fields inside also
     carry their own bottom margin and the pairs sit 27px apart while a
     single field below them sits 14px apart. */
#view-request .r2{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin:0 0 14px;}
#view-request .r2 .fw{margin-bottom:0;}
  @media(max-width:560px){
#view-request .r2{grid-template-columns:1fr;}}
#view-request input[type=text], #view-request input[type=email], #view-request input[type=tel], #view-request input[type=number], #view-request textarea, #view-request input[type=file]{width:100%;
    border:1.5px solid var(--ts-line);border-radius:10px;padding:11px 13px;
    font-family:var(--ts-body);font-size:14px;background:var(--ts-card);outline:none;}
#view-request textarea{min-height:80px;resize:vertical;}
#view-request .note{font-size:12.5px;color:var(--ts-mute);margin-top:7px;}
/* What is still missing, said next to the field rather than only on the Send
   button. Same size and position as .note so a field that has both reads as
   one column of small print, and the same red as .drophint.bad so the file
   fields and the text fields speak with one voice. */
#view-request .fielderr{
  margin:7px 0 0;
  font-size:12.5px;
  font-weight:600;
  color:#8E1B16;
}
#view-request .fw .fielderr:last-child{ margin-bottom:0; }
/* Standing on its own above a block of options rather than under a field, it
   needs room on BOTH sides or it reads as a caption on the first option
   instead of a note about all of them. The heading above already supplies
   its own 16px, so only the underside is set here; .opt carries 9px, which
   on its own left the line all but touching "I have a policy". */
#view-request .sec > .fielderr{ margin:0 0 16px; }
#view-request .reveal > .fielderr{ margin:10px 0 2px; }
#view-request .chk + .fielderr{ margin:9px 0 0; }
#view-request input.bad, #view-request textarea.bad{
  border-color:var(--ts-red);
  background:#FFFBFB;
}
/* The mileage and the fee are the answer to the question the renter just
   asked, so they are set at reading size in full ink rather than in the muted
   12.5px the rest of the note uses. */
#view-request .feeline{display:block;font-size:15px;line-height:1.45;color:var(--ts-ink);}
#view-request .feeline .fee{color:var(--ts-red);}
#view-request .feesum{font-size:12.5px;color:var(--ts-mute);font-weight:400;}

#view-request .opt{display:flex;gap:11px;align-items:flex-start;border:1.5px solid var(--ts-line);
    border-radius:11px;padding:12px 14px;margin:0 0 9px;cursor:pointer;}
#view-request .opt.on{border-color:var(--ts-red);background:#FDF5F4;}
#view-request .opt.off{opacity:.5;cursor:not-allowed;background:var(--ts-cloud);}
#view-request .opt.off .d{color:#8E1B16;}
#view-request .opt .t{font-weight:600;font-size:14.5px;}
#view-request .opt .d{font-size:13px;color:var(--ts-mute);margin-top:2px;}
/* 12px, not the 2px it was: the drag highlight spreads 7px above the file
   field inside these blocks and had nowhere to go. */
#view-request .reveal{margin:12px 0 14px 28px;padding-left:14px;border-left:2px solid var(--ts-line);}
#view-request .reveal[hidden], #view-request .qline[hidden], #view-request .qrow[hidden], #view-request .sub[hidden]{display:none;}
#view-request .rq{font-size:13px;line-height:1.65;margin:0 0 10px;}
#view-request .rq b{color:var(--ts-ink);}
#view-request .rq ul{margin:5px 0 0;padding-left:18px;}
#view-request .warnbox{background:#FCEBEA;border:1px solid #F3C9C6;color:#8E1B16;border-radius:9px;
    padding:9px 12px;font-size:12.5px;margin:0 0 10px;}
#view-request .coibox{background:var(--ts-cloud);border-radius:9px;padding:11px 13px;font-size:13px;
    line-height:1.6;margin:0 0 4px;}
#view-request .coibox .lab{font-family:var(--ts-mono);font-size:9.5px;letter-spacing:.05em;
    text-transform:uppercase;color:var(--ts-mute);display:block;margin-bottom:4px;}
#view-request .chk{display:flex;gap:10px;align-items:flex-start;padding:8px 0;font-size:14px;}
#view-request .chk .d{font-size:12.5px;color:var(--ts-mute);display:block;}
#view-request .pill{display:inline-block;padding:1px 7px;border-radius:999px;font-family:var(--ts-mono);
    font-size:9px;letter-spacing:.04em;text-transform:uppercase;font-weight:600;border:1px solid;}
#view-request .pill.ok{background:#E7F4EC;border-color:#BFE0CB;color:#17603A;}
#view-request .pill.warn{background:#FDF6E3;border-color:#ECD9A8;color:#7A4E00;}
#view-request .feebox{background:#E7F4EC;border:1px solid #BFE0CB;border-radius:10px;padding:11px 13px;
    margin:10px 0 0;font-size:13.5px;}
#view-request .feebox .big{font-size:17px;font-weight:700;}
#view-request .verify{background:var(--ts-cloud);border-radius:10px;padding:13px 15px;}
#view-request .rq-retbar{background:var(--ts-cloud);border:1.5px solid var(--ts-line);
    border-radius:var(--ts-radius-card);padding:15px 18px;margin:0 0 14px;
    display:flex;justify-content:space-between;gap:16px;align-items:center;flex-wrap:wrap;}
#view-request .rq-retbar b{font-size:15px;}
#view-request .rq-retbar .d{display:block;font-size:13px;color:var(--ts-mute);margin-top:2px;}
#view-request .rq-retbar .row{display:flex;gap:9px;}
#view-request .rq-retbar input{max-width:210px;}
#view-request .codebox{background:#FDF6E3;border:1px solid #ECD9A8;border-radius:10px;padding:13px 15px;}
#view-request .codebox .row{display:flex;gap:9px;margin-top:10px;}
#view-request .codebox input{max-width:150px;letter-spacing:.18em;font-family:var(--ts-mono);}
#view-request .onfile{background:var(--ts-cloud);border-radius:10px;padding:13px 15px;font-size:14px;
    line-height:1.65;display:flex;justify-content:space-between;gap:14px;align-items:flex-start;}
#view-request .onfile a{color:var(--ts-red);font-size:12.5px;white-space:nowrap;}
#view-request .verify.done{background:#E7F4EC;border:1px solid #BFE0CB;}
#view-request .mini{font-family:var(--ts-mono);font-size:10.5px;color:var(--ts-mute);}
#view-request .addbtn{background:var(--ts-ink);color:#fff;border:0;border-radius:999px;padding:9px 18px;
    font-family:var(--ts-body);font-size:13.5px;font-weight:600;cursor:pointer;margin-top:8px;}
#view-request .addbtn.added{background:#17603A;}
#view-request .addbtn.added:hover{background:#8E1B16;}
/* With every item listed, #view-request a big order can out-grow the screen. Let the
     card itself scroll rather than hiding items behind a button. */
/* 68px is the height of the sticky site nav; the card has to clear it or
   its heading hides behind the bar as soon as the page scrolls. */
#view-request .rail{position:sticky;top:84px;max-height:calc(100vh - 104px);overflow:auto;}
  @media(max-width:900px){
#view-request .rail{position:static;max-height:none;overflow:visible;}}
#view-request .quote{background:var(--ts-card);border:1.5px solid var(--ts-line);
    border-radius:var(--ts-radius-card);overflow:hidden;}
#view-request .quote-h{padding:15px 20px;border-bottom:1px solid var(--ts-line);
    display:flex;justify-content:space-between;align-items:baseline;}
#view-request .quote-h h3{font-family:var(--ts-display);font-size:19px;margin:0;}
#view-request .quote-h a{font-size:12px;color:var(--ts-red);}
#view-request .qdates{display:flex;gap:10px;padding:13px 20px;background:var(--ts-cloud);
    border-bottom:1px solid var(--ts-line);font-size:13px;}
#view-request .qdates .lab{font-family:var(--ts-mono);font-size:9.5px;letter-spacing:.05em;
    text-transform:uppercase;color:var(--ts-mute);display:block;}
#view-request .qdates .tsdp-wrap{display:block;margin-top:4px;}
/* The panel is a summary, not a form, so the trigger is sized down to sit in
   it - but it keeps its border, because the whole point of the change is that
   these dates no longer look like fixed text. */
#view-request .qdates .tsdp-trigger{padding:6px 9px;font-size:13px;gap:6px;border-radius:8px;}
#view-request .qtime{display:block;margin-top:4px;font-size:11px;color:var(--ts-mute);}
/* Gear that stopped being free when the dates moved. Sits under the item name
   on its own line so it cannot be mistaken for part of the title. */
#view-request .qavail{display:block;margin-top:3px;font-size:11.5px;font-weight:600;}
#view-request .qavail.out{color:#8E1B16;}
#view-request .qavail.low{color:#7A4E00;}
#view-request .qitems{padding:6px 20px;}
#view-request .qrow{display:flex;justify-content:space-between;gap:10px;padding:9px 0;font-size:13.5px;
    border-bottom:1px solid var(--ts-line);}
#view-request .qrow:last-child{border-bottom:0;}
/* Three columns now: the name takes the slack, the money and the remove
   button each take only what they need. min-width:0 lets a long gear name
   wrap instead of forcing the row wider than the card. */
#view-request .qrow > span:first-child{flex:1 1 auto;min-width:0;}
#view-request .qamt{flex:0 0 auto;white-space:nowrap;}
/* Quiet until it is wanted: this sits beside every line of a quote the
   renter is happy with, so it should not read as a warning. */
#view-request .qdel{flex:0 0 auto;align-self:flex-start;margin:-3px -6px 0 0;
    width:26px;height:26px;padding:0;background:none;border:0;border-radius:7px;
    font:inherit;font-size:18px;line-height:1;color:var(--ts-mute);cursor:pointer;
    transition:color .12s,background .12s;}
#view-request .qdel:hover,#view-request .qdel:focus-visible{color:var(--ts-red);
    background:var(--ts-cloud);}
/* The count, under the line it belongs to. display:flex (not inline-flex)
   with a fit-content width puts it on its own row inside a span that is
   otherwise running text, without wrapping it in another element. */
#view-request .qqty{display:flex;width:-moz-fit-content;width:fit-content;
    align-items:center;margin-top:7px;padding:1px;background:var(--ts-white);
    border:1px solid var(--ts-line);border-radius:999px;
    /* Tapping + twice quickly otherwise selects the number between them. */
    user-select:none;-webkit-user-select:none;}
#view-request .qstep{width:25px;height:25px;padding:0;margin:0;background:none;
    border:0;border-radius:999px;font:inherit;font-size:15px;line-height:1;
    color:var(--ts-ink);cursor:pointer;transition:background .12s;}
#view-request .qstep:hover:not([disabled]),
#view-request .qstep:focus-visible{background:var(--ts-cloud);}
/* Greyed rather than hidden: the range is easier to understand when both
   ends stay where they were. */
#view-request .qstep[disabled]{color:var(--ts-line);cursor:default;}
/* Tabular figures so 1 and 2 do not shuffle the buttons sideways. */
#view-request .qn{min-width:19px;text-align:center;font-size:13px;font-weight:700;
    font-variant-numeric:tabular-nums;}
#view-request .qsum{padding:13px 20px;border-top:1px solid var(--ts-line);font-size:13.5px;}
#view-request .qline{display:flex;justify-content:space-between;padding:3px 0;}
#view-request .qline.big{font-size:17px;font-weight:700;padding-top:9px;margin-top:6px;
    border-top:1px solid var(--ts-line);}
#view-request .qline .mut{color:var(--ts-mute);}
#view-request .qline.disc span:last-child{color:#17603A;}
#view-request .qcov{margin:11px 20px;padding:9px 12px;border-radius:9px;font-size:12.5px;border:1px solid;}
#view-request .qcov.ok{background:#E7F4EC;border-color:#BFE0CB;color:#17603A;}
#view-request .qcov.todo{background:#FDF6E3;border-color:#ECD9A8;color:#7A4E00;}
#view-request .qcov.none{background:#FCEBEA;border-color:#F3C9C6;color:#8E1B16;}
#view-request .qsend{padding:0 20px 18px;}
#view-request .btn[disabled]{background:var(--ts-line);color:var(--ts-mute);cursor:not-allowed;}
/* Everything still missing, listed. It wears the same skin as .qcov.none
   because it is the same kind of thing said in the same column - one panel
   of "not ready yet" rather than two competing reds. */
#view-request .qtodo{margin:11px 20px;padding:10px 12px;border-radius:9px;font-size:12.5px;
    border:1px solid #F3C9C6;background:#FCEBEA;color:#8E1B16;}
#view-request .qtodo[hidden]{display:none;}
#view-request .qtodo-h{margin:0 0 7px;font-weight:700;}
#view-request .qtodo ul{margin:0;padding-left:17px;}
#view-request .qtodo li{margin:0 0 5px;}
#view-request .qtodo li:last-child{margin-bottom:0;}
/* Each line goes to its field. Reading that something is missing and then
   having to hunt for it on a form this tall is most of the work. */
#view-request .qtodo button{background:none;border:0;padding:0;margin:0;font:inherit;
    color:inherit;text-align:left;cursor:pointer;
    text-decoration:underline;text-decoration-color:rgba(142,27,22,.38);
    text-underline-offset:2px;}
#view-request .qtodo button:hover{text-decoration-color:currentColor;}
/* The phone's Send is its own section with its own padding, so the card's
   side margins would double up here. */
#view-request .sendsec .qtodo{margin:12px 0 0;}
#view-request .btn{width:100%;background:var(--ts-red);color:#fff;border:0;border-radius:999px;padding:14px;
    font-family:var(--ts-body);font-size:15px;font-weight:600;cursor:pointer;}
/* The ShareGrid link wears the Send button's skin - it stands in the same
   place and is the same decision - but it is an <a>, so it needs the parts a
   <button> gets for free. [hidden] is spelled out because display:block beats
   the browser's own hidden rule, and a second visible button is the exact
   thing this was meant to stop. */
#view-request .btn.golink{display:block;box-sizing:border-box;text-align:center;
    text-decoration:none;}
#view-request .btn.golink[hidden]{display:none;}
#view-request .bar{display:none;position:fixed;left:0;right:0;bottom:0;z-index:20;background:var(--ts-card);
    border-top:1.5px solid var(--ts-line);padding:11px 16px;
    box-shadow:0 -6px 22px rgba(17,17,17,.1);align-items:center;gap:12px;}
#view-request .bar .tot{flex:1;font-size:13px;}
#view-request .bar .tot b{font-size:17px;display:block;}
#view-request .sendsec{display:none;}
  @media(max-width:900px){
#view-request .sendsec{display:block;}
/* the card's own Send, #view-request which is now above the questions */
#view-request .qsend{display:none;}
/* ...and its copy of the list, for the same reason: the card sits above the
   questions here, so this one would be read before the renter has had a
   chance to fill anything in. The copy under the phone's own Send stands. */
#view-request #rqTodo{display:none;}
  }
#view-request .bar button{background:var(--ts-red);color:#fff;border:0;border-radius:999px;padding:12px 22px;
    font-family:var(--ts-body);font-size:14.5px;font-weight:600;}
  @media(max-width:900px){
#view-request .bar{display:flex;}}
/* ---- who is filling it in ---------------------------------------------- */
#view-request .new-only, #view-request .ret-only, #view-request .verify-only, #view-request .verified-only{display:block;}
#view-request.is-returning .new-only{display:none;}
#view-request:not(.is-returning) .ret-only{display:none;}
/* An unrecognised device has proved nothing yet, so it is shown nothing. */
#view-request:not(.is-unverified) .verify-only{display:none;}
#view-request.is-unverified .verified-only{display:none;}
#view-request.is-returning:not(.is-unverified) .rq-retbar{display:none;}

/* ---- the page head -----------------------------------------------------
   The heading sits inside the left column rather than in a .ts-page-head
   above the grid, so the quote card lines up with the title instead of
   starting a heading and a pill lower down. That means this section owns
   the space under the nav. */
#view-request .ts-section.tight{padding-top:40px;}
#view-request .ts-eyebrow{margin-bottom:10px;}

/* The Places suggestion box is a web component with its own input inside a
   shadow root, so it cannot inherit our input styling the normal way. These
   are the parts Google exposes for theming; the rest is its own. Sized to
   match .fw input so the field does not jump when suggestions switch on. */
/* color-scheme:light is doing real work. The rest of the site ignores the
   visitor's dark-mode setting, but Google's widget honours it, so on a
   machine set to dark the address box rendered black inside a cream form. */
#view-request gmp-place-autocomplete{display:block;width:100%;margin-bottom:0;
    color-scheme:light;
    --gmp-mat-color-surface:#fff;
    --gmp-mat-color-on-surface:var(--ts-ink);
    --gmp-mat-color-outline:var(--ts-line);
    --gmp-mat-color-primary:var(--ts-red);
    --gmp-mat-font-family:var(--ts-body);}

/* ---- drag and drop onto the file fields ---------------------------------
   The .dropzone class is added by request.js, never written into the HTML,
   so these styles only ever apply where the handlers actually attached. */
/* Getting the highlight to sit OFF the content took four goes, so the whole
   reasoning is here.

   An inset box-shadow (first attempt) painted the line on the element's own
   edge, which is exactly where the label above and the hint below begin, so
   the red ran straight through both.

   An outline fixed the line - it is painted outside the box and takes no part
   in layout - but the background was still the element's own, so the tint
   went right up against the label and the Choose File control with nothing
   between them (second attempt).

   Painting the tint with a pseudo-element stretched past the box (third
   attempt) put real space between the red and the field, but it spends that
   space on whatever sits ABOVE: the file field under "Upload a student ID."
   had only 10px of room there, so a 10px spread landed flush on that line.
   A highlight that costs no layout has to be given room that already exists.

   So: the spread is 7px, and the gap above each file field was widened to
   make room for it - .reveal below, and the inline margin on the COI field's
   .fw in request.html. The spread and the outline offset are the same figure,
   which puts the red line exactly on the tint's edge: one panel, with the
   content sitting 7px in from it and clear air outside that. */
#view-request .dropzone{
  position:relative;
  border-radius:9px;
}
/* Above the tint, which is painted behind at z-index 0. */
#view-request .dropzone > *{ position:relative; z-index:1; }
#view-request .dropzone.over::before{
  content:'';
  position:absolute;
  top:-7px; right:-7px; bottom:-7px; left:-7px;
  background:#FDF0EF;
  border-radius:11px;
  z-index:0;
}
#view-request .dropzone.over{
  outline:2px solid var(--ts-red);
  outline-offset:7px;
  border-radius:3px;
}
/* A revealed block carries its grey rule as a border-left, and that caused
   two separate faults once the block became a dropzone.

   Pulling the tint in to left:0 to avoid covering the rule left a 7px sliver
   of white between the tint and the red line - the panel looked unfinished
   down one side only. The tint is symmetric again; the rule simply sits
   inside the panel, as the field and the hint do.

   The rule itself was being bent: border-radius on the zone rounds the ends
   of a border-left, so this one block had a curved line where every other
   block on the form has a straight one. A border cannot be rounded on some
   corners and not others, and the radius has to stay - the outline follows
   it. So the rule is drawn as a pseudo-element instead, which no radius can
   touch, and the real border is kept for its width alone. left:-2px is the
   border's own track: an absolutely positioned child is placed against the
   padding box, and the 2px border sits just outside it. */
#view-request .reveal.dropzone{ border-left-color:transparent; }
#view-request .reveal.dropzone::after{
  content:'';
  position:absolute;
  left:-2px; top:0; bottom:0;
  width:2px;
  background:var(--ts-line);
  z-index:1;
}
#view-request .drophint{
  margin:7px 0 0;
  font-size:12.5px;
  color:#6B6B6B;
}
#view-request .drophint.bad{ color:#8E1B16; font-weight:600; }
#view-request .drophint[hidden]{ display:none; }

/* The clear control. The filename is drawn by the native control's shadow
   DOM, so nothing can be appended beside it - the x is laid over the field's
   right-hand end instead, which is where the eye leaves the name anyway. */
#view-request .filewrap{ position:relative; display:block; }
/* Room for the x, so a long filename runs under it instead of through it. */
#view-request .filewrap input[type=file]{ padding-right:38px; }
#view-request .filex{
  position:absolute;
  right:9px;
  top:50%;
  transform:translateY(-50%);
  width:22px;
  height:22px;
  display:flex;
  align-items:center;
  justify-content:center;
  border:0;
  border-radius:50%;
  background:none;
  padding:0;
  font-family:var(--ts-body);
  font-size:19px;
  line-height:1;
  color:var(--ts-mute);
  cursor:pointer;
  transition:background .12s ease, color .12s ease;
}
#view-request .filex:hover{ background:#FDF0EF; color:var(--ts-red); }
#view-request .filex[hidden]{ display:none; }
