/* ed_ink.css — EDITOR_INK: the desktop editor as one frame (see static/ed_ink.js).
   A slim bar (who and what: the name, its design, saved; Share, Download, more), the résumé straight under it on a
   grey table, and a white panel beside it for the score and the AI. White paper, black print, one blue ink: the same
   split as the design page (the page on the table, the choosing beside it).
   LOAD ORDER: this file is linked in the body, after head2.js (templates/index.html). head2.js injects its own <style>
   into the head at start, and many rules here replace head2's at equal weight: linked from the head, they lose.
   Everything is under body.edk, which the script sets only while the frame is on. The first block is the opposite:
   it makes the two wrappers disappear when the frame is off, so EDITOR_HEAD2's own layout is untouched. */

/* ---------- frame off: the wrappers are not there ---------- */
body:not(.edk) .edk-bar, body:not(.edk) .edk-panel{ display:contents }
body:not(.edk) .edk-logo, body:not(.edk) .edk-kick, body:not(.edk) .edk-films{ display:none }
body:not(.edk).hd2 .edk-bar > .edk-id{ grid-area:id; min-width:0 }

/* ---------- frame on ---------- */
body.edk{
  --e-ink:#0A0A0C; --e-table:#F2F3F6; --e-blue:#1233D6; --e-hl:#FFE45C; --e-hair:rgba(10,10,12,.12); --e-mute:rgba(10,10,12,.64);
  --e-bar:56px; --e-panel:348px; --e-out:cubic-bezier(.16,1,.3,1);
  --e-sans:"Inter",system-ui,-apple-system,"Segoe UI",sans-serif; --e-mono:"IBM Plex Mono",ui-monospace,Menlo,monospace;
  /* EDITOR_HEAD2's own palette, re-inked: its rules follow */
  --h2-ink:#0A0A0C; --h2-mut:rgba(10,10,12,.66); --h2-faint:rgba(10,10,12,.5); --h2-rule:rgba(10,10,12,.14);
  --h2-rule2:rgba(10,10,12,.08); --h2-soft:#F2F3F6; --h2-gold:#FFE45C;
  background:#fff;
}
body.edk.hd2 div.wrap{ max-width:none !important; width:auto; margin:0; padding:0 }   /* style.css caps the editor at 1240px with a :has() rule */
body.edk.hd2.hd2-editor .hero{ display:none !important }      /* the logo is in the bar; the films are in the panel */

body.edk #result.result{ display:grid; grid-template-columns:minmax(0,1fr) var(--e-panel); grid-template-rows:auto auto 1fr;
  grid-template-areas:"bar bar" "note panel" "work panel";
  margin:0; padding:0; border:0; border-radius:0; box-shadow:none; background:var(--e-table); min-height:100vh; }
body.edk #result.result[hidden]{ display:none }
body.edk #result.result > *{ min-width:0 }
body.edk #result.result > :not(.workbench):not(#sample-banner):not(.result-head){ grid-column:1 / -1 }   /* anything else the app adds: a full row of its own */
body.edk .result-head{ display:contents }

/* ---------- the bar ---------- */
body.edk.hd2 .result-head > .edk-bar{ grid-area:bar; position:sticky; top:0; z-index:70; height:var(--e-bar);
  display:flex; align-items:center; gap:14px; padding:0 calc(var(--edk-acct, 0px) + 30px) 0 16px;
  background:rgba(255,255,255,.95); -webkit-backdrop-filter:saturate(1.4) blur(10px); backdrop-filter:saturate(1.4) blur(10px);
  border-bottom:1px solid var(--e-hair); }
body.edk .edk-logo{ flex:none; display:flex; align-items:center; gap:8px; text-decoration:none; color:var(--e-ink);
  font:600 22px/1 "Cormorant Garamond",Georgia,serif; letter-spacing:-.01em; }
body.edk .edk-logo b{ font-weight:600; color:#8B7355 }
body.edk .edk-id{ flex:1 1 auto; min-width:0; overflow:hidden; display:flex; align-items:center; gap:10px; height:26px; padding-left:14px;
  border-left:1px solid var(--e-hair); }
body.edk .edk-id #result-name{ order:1; flex:0 1 auto; min-width:48px; max-width:28ch; margin:0; padding:0;
  font:600 15px/1.25 var(--e-sans); letter-spacing:0; color:var(--e-ink); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
body.edk .edk-id .hd2-meta{ order:2; flex:0 1 auto; flex-wrap:nowrap; min-width:0; overflow:hidden }
body.edk .edk-id .hd2-chip{ height:26px; padding:0 10px; font-size:12px; flex:none }
body.edk .edk-id button.hd2-chip:hover{ border-color:var(--e-ink) }
body.edk .edk-id .result-kicker{ order:3; flex:none; margin:0; font-size:0; letter-spacing:0; gap:7px }
body.edk .edk-id .result-kicker #save-status{ font-size:12px; white-space:nowrap }
body.edk .edk-id .result-kicker #save-status::before{ content:none }
body.edk .edk-id #result-meta, body.edk .edk-id #back-to-designs{ display:none }

body.edk .edk-bar .result-actions{ flex:none; width:auto; position:relative; flex-direction:row; align-items:center; gap:8px; margin:0 }
body.edk .edk-bar .ra-primary{ gap:8px; width:auto; flex-wrap:nowrap }
body.edk .edk-bar .ra-primary > .btn, body.edk .edk-bar .hd2-share > .btn, body.edk .edk-bar .hd2-more{ height:36px; border-radius:9px; font-size:13.5px }
body.edk .edk-bar .hd2-share{ height:36px; border-radius:9px }
body.edk .edk-bar .hd2-share #share-open{ height:34px; padding:0 10px 0 13px }
body.edk .edk-bar .hd2-share:hover, body.edk .edk-bar .hd2-more:hover, body.edk .edk-bar .hd2-more[aria-expanded=true]{ border-color:var(--e-ink); background:#fff }
body.edk .edk-bar #download{ padding:0 16px; background:var(--e-ink); border-color:var(--e-ink); transition:background .25s }
body.edk .edk-bar #download:hover{ background:var(--e-blue); border-color:var(--e-blue) }
body.edk .edk-bar .hd2-more{ width:36px }
body.edk .hd2-menu .hd2-ic{ color:var(--e-ink) }
/* "Have a coupon?" hangs under the bar's right end; its row opens as a small card there */
body.edk .edk-bar #coupon-toggle{ position:absolute; top:calc(100% + 10px); right:0; left:auto; width:max-content; margin:0; padding:5px 10px; border-radius:0 0 8px 8px;
  background:#fff; border:1px solid var(--e-hair); border-top:0; font:500 11.5px/1 var(--e-sans); color:var(--e-mute); white-space:nowrap }
body.edk .edk-bar #coupon-toggle:hover{ color:var(--e-ink) }
body.edk .edk-bar #coupon-row{ position:absolute; top:calc(100% + 40px); right:0; z-index:5; width:300px; padding:12px; border-radius:12px;
  background:#fff; box-shadow:0 0 0 1px var(--e-hair), 0 22px 40px -18px rgba(10,10,12,.45); justify-content:flex-start; flex-wrap:wrap; gap:8px }
body.edk .edk-bar #coupon-row[hidden], body.edk .edk-bar #coupon-toggle[hidden]{ display:none }

/* the account: floats over the bar's right end; one chip, which opens into a small card */
body.edk #account-area{ position:fixed; top:10px; right:14px; z-index:90 }
body.edk .acct-signin{ height:36px; padding:0 14px; border-radius:9px; border-color:var(--h2-rule); font:600 13px/1 var(--e-sans) }
body.edk .acct-signin:hover{ background:#fff; border-color:var(--e-ink) }
body.edk #acct-chip{ position:relative; flex-wrap:wrap; justify-content:flex-start; gap:0 8px; width:max-content; min-height:36px; padding:0 12px; cursor:pointer;
  border:1px solid var(--h2-rule); border-radius:9px; background:#fff; font:500 13px/1 var(--e-sans); color:var(--e-ink) }
body.edk #acct-chip:hover, body.edk #acct-chip.edk-open{ border-color:var(--e-ink) }
body.edk #acct-chip::after{ content:""; order:2; align-self:center; width:6px; height:6px; margin:-3px 1px 0 2px; border-right:1.5px solid currentColor; border-bottom:1.5px solid currentColor;
  transform:rotate(45deg); transition:transform .25s }
body.edk #acct-chip.edk-open::after{ transform:rotate(225deg); margin-top:3px }
body.edk #acct-chip .acct-dot{ order:0; align-self:center }
body.edk #acct-chip #acct-phone{ order:1; line-height:34px }
body.edk #acct-chip > button, body.edk #acct-chip > a{ display:none }
body.edk #acct-chip.edk-open{ position:absolute; right:0; top:0; max-width:230px; padding:0 6px 6px 12px; border-radius:12px;
  box-shadow:0 22px 40px -18px rgba(10,10,12,.45) }
body.edk #acct-chip.edk-open > button, body.edk #acct-chip.edk-open > a{ order:3; display:block; flex:0 0 calc(100% + 6px); margin:0 0 0 -6px; padding:10px 10px;
  border:0; border-radius:8px; background:none; text-align:left; text-decoration:none; font:500 13.5px/1 var(--e-sans); color:var(--e-ink) }
body.edk #acct-chip.edk-open > [hidden]{ display:none }
body.edk #acct-chip.edk-open > button:hover, body.edk #acct-chip.edk-open > a:hover{ background:var(--e-table); color:var(--e-ink) }
body.edk #acct-chip.edk-open > #logout-btn{ color:#A1261C }

/* ---------- the résumé, on the table ---------- */
body.edk #sample-banner{ grid-area:note; margin:14px auto 0; width:calc(100% - 48px); max-width:880px; background:#fff; border-color:var(--e-hair) }
body.edk .workbench{ grid-area:work; display:block; min-width:0; padding:0 24px 72px }
body.edk .editor-col{ min-width:0 }
body.edk .inline-doc{ max-width:880px; margin:0 auto }
body.edk .ied2-info{ margin:10px 2px 0; min-height:26px; font-size:12.5px }
body.edk .ied-sticky{ top:var(--e-bar); z-index:6; padding:10px 0 10px; background:transparent; box-shadow:none }
body.edk .ied2-tools{ background:#fff; border:1px solid var(--e-hair); border-radius:12px; padding:5px 6px;
  box-shadow:0 10px 24px -18px rgba(10,10,12,.5) }
body.edk .ied2-tools .ied-tool:hover:not(:disabled){ background:var(--e-table) }
body.edk .ied2-tools .ied-tool[aria-expanded="true"]{ background:#e6e8ee }
body.edk .ied2-sep{ background:var(--e-hair) }
body.edk .ied-note:empty{ display:none }
body.edk .ied-stage{ background:#fff; border:0; border-radius:3px;
  box-shadow:0 0 0 1px rgba(10,10,12,.07), 0 2px 4px rgba(10,10,12,.05), 0 30px 60px -28px rgba(10,10,12,.32) }
body.edk .site-foot{ margin:0; padding:22px 24px 28px; background:#fff; border-top:1px solid var(--e-hair) }

/* ---------- the panel: the score and the AI, beside the résumé ---------- */
body.edk.hd2 .result-head > .edk-panel{ grid-area:panel; align-self:start; position:sticky; top:var(--e-bar); z-index:8; min-width:0;
  height:calc(100vh - var(--e-bar)); height:calc(100dvh - var(--e-bar)); display:flex; flex-direction:column; gap:12px; padding:18px 18px 14px;
  background:#fff; border-left:1px solid var(--e-hair); }
body.edk .edk-kick{ margin:0 0 2px; font:500 10.5px/1 var(--e-mono); letter-spacing:.18em; text-transform:uppercase; color:var(--e-mute) }
body.edk .edk-panel .hd2-strip{ display:flex; flex-direction:column; align-items:stretch; gap:12px; min-width:0 }
body.edk .edk-panel .hd2-strip > *{ flex:none }
/* the ATS card */
body.edk .edk-panel #sc-host-doc{ width:100%; border-radius:12px; background:#fff; padding:11px 12px; gap:11px; flex-wrap:nowrap }
body.edk .edk-panel #sc-host-doc:hover{ border-color:var(--e-ink) }
body.edk .edk-panel #sc-host-doc .sc-deep{ flex:1 1 auto; flex-wrap:wrap; gap:8px; min-width:0 }
body.edk .edk-panel .hd2-strip #sc-host-doc:has(.sc-deep-cta) .sc-deep{ flex-wrap:nowrap }
body.edk .edk-panel .hd2-strip #sc-host-doc:has(.sc-deep-cta) .sc-deep::before{ content:none }   /* the button says it */
/* with a score: the number and its grade, what changed since, then the two things to do */
body.edk .edk-panel #sc-host-doc:not(:has(.sc-deep-cta)){ flex-direction:column; align-items:stretch; gap:10px }
body.edk .edk-panel .hd2-strip .sc-deep-stale{ flex:1 1 55%; max-width:none; margin:0 }
body.edk .edk-panel .hd2-strip .sc-deep-btn:not(.sc-deep-cta){ margin-left:auto }
body.edk .edk-panel .hd2-strip .sc-breakdown{ width:100%; justify-content:center; height:36px }
body.edk .edk-panel .sc-deep-ring{ background:radial-gradient(closest-side,#fff 79%,transparent 80% 100%),conic-gradient(var(--h2-ring,var(--h2-green)) calc(var(--p)*1%),#e6e8ee 0) }
body.edk .edk-panel .sc-deep-btn:hover, body.edk .edk-panel .sc-breakdown:hover{ border-color:var(--e-ink) }
body.edk .edk-panel #sc-host-doc:has(.sc-deep-cta)::before{ border-color:#e6e8ee }
body.edk .edk-panel .hd2-strip .sc-deep-cta{ flex:1 1 auto; height:38px; padding:0 12px; white-space:nowrap; background:var(--e-ink); border-color:var(--e-ink); transition:background .25s }
body.edk .edk-panel .hd2-strip .sc-deep-cta:hover{ background:var(--e-blue); border-color:var(--e-blue) }
/* Ask AI: a box you would type in */
body.edk .edk-panel #ai-ask-open{ flex-wrap:wrap; align-items:flex-start; gap:8px 9px; min-height:92px; padding:13px 10px 10px 13px; border-radius:12px;
  color:rgba(10,10,12,.5); font-size:14px; line-height:1.4 }
body.edk .edk-panel #ai-ask-open:hover, body.edk .edk-panel #ai-ask-open:focus-visible{ border-color:var(--e-blue); box-shadow:0 0 0 3px rgba(18,51,214,.1) }
body.edk .edk-panel #ai-ask-open .hd2-spark{ color:var(--e-blue); margin-top:1px }
body.edk .edk-panel #ai-ask-open .hd2-ph{ flex:1 1 calc(100% - 30px); white-space:normal; overflow:visible }
body.edk .edk-panel #ai-ask-open .ai-pro-chip{ margin-left:auto; align-self:center }
body.edk .edk-panel #ai-ask-open .hd2-go{ width:32px; height:32px; border-radius:8px; background:var(--e-ink); transition:background .25s }
body.edk .edk-panel #ai-ask-open:hover .hd2-go{ background:var(--e-blue) }
body.edk .edk-panel #ai-ask-open .hd2-go:first-of-type{ margin-left:auto }
body.edk .edk-panel #ai-ask-open .ai-pro-chip + .hd2-go{ margin-left:0 }
/* AI tools: the same menu, opening beside the panel (over the table), never under the fold */
body.edk .edk-panel .ai-menu-wrap{ margin:0; width:100% }
body.edk .edk-panel #ai-tools-open{ width:100%; min-height:46px; justify-content:flex-start; border-radius:12px; padding:0 14px }
body.edk .edk-panel #ai-tools-open:hover, body.edk .edk-panel #ai-tools-open[aria-expanded=true]{ border-color:var(--e-ink) }
body.edk .edk-panel #ai-tools-open > svg:last-child{ margin-left:auto; transform:rotate(90deg) }
body.edk .edk-panel .hd2-strip .ai-menu{ right:calc(100% + 26px); left:auto; top:-120px; border-radius:12px;
  box-shadow:0 0 0 1px var(--e-hair), 0 26px 50px -20px rgba(10,10,12,.5) }
body.edk .edk-panel #ats-open, body.edk .edk-panel #ai-review-open, body.edk .edk-panel #ai-extras-open{ min-height:44px; border-radius:12px }
/* let HR find you */
body.edk .edk-panel .hd2-find{ flex-wrap:wrap; gap:10px 12px; padding:13px; border-radius:12px; background:var(--e-table); border-color:transparent }
body.edk .edk-panel .hd2-find:hover{ border-color:var(--e-ink); box-shadow:none }
body.edk .edk-panel .hd2-find-ic{ width:34px; height:34px; border-radius:9px; background:var(--e-blue) }
body.edk .edk-panel .hd2-find-ic svg{ width:18px; height:18px }
body.edk .edk-panel .hd2-find-t{ flex:1 1 calc(100% - 50px) }
body.edk .edk-panel .hd2-find-t b{ font-size:14px; line-height:1.3 }
body.edk .edk-panel .hd2-find-t > span{ font-size:12.5px; line-height:1.4 }
body.edk .edk-panel .hd2-find-go{ flex:1 1 100%; justify-content:center; height:38px; border-radius:9px; font-size:13.5px; background:var(--e-ink); transition:background .25s }
body.edk .edk-panel .hd2-find:hover .hd2-find-go{ background:var(--e-blue) }
/* the films */
body.edk .edk-films{ margin-top:auto; display:flex; flex-direction:column; gap:2px; padding-top:10px; border-top:1px solid var(--e-hair) }
body.edk .edk-films:empty{ display:none }
body.edk .edk-film{ display:flex; align-items:center; gap:10px; width:100%; padding:8px 6px; border:0; border-radius:9px; background:none; cursor:pointer; text-align:left;
  font:500 13px/1.3 var(--e-sans); color:var(--e-ink) }
body.edk .edk-film:hover{ background:var(--e-table) }
body.edk .edk-play{ flex:none; width:24px; height:24px; border-radius:50%; background:var(--e-ink); color:#fff; display:grid; place-items:center; transition:background .25s }
body.edk .edk-play svg{ width:14px; height:14px }
body.edk .edk-film:hover .edk-play{ background:var(--e-blue) }
body.edk .edk-film-t{ flex:1 1 auto; min-width:0 }
body.edk .edk-films{ padding-right:44px }   /* the guide stands in this corner */
body.edk .edk-film-n{ flex:none; font:500 10.5px/1 var(--e-mono); letter-spacing:.08em; text-transform:uppercase; color:var(--e-mute) }

/* "Ask ResumeInk" docks on the right (the page makes 420px of room for it): it takes the panel's place */
@media (min-width:1100px){
  body.edk.askp-open #result.result{ grid-template-columns:minmax(0,1fr); grid-template-areas:"bar" "note" "work" }
  body.edk.askp-open.hd2 .result-head > .edk-panel{ display:none }
}

body.edk :focus-visible{ outline:2px solid var(--e-blue); outline-offset:2px }

/* a narrower desktop: the panel slims, the name gives way first */
@media (max-width:1280px){
  body.edk{ --e-panel:312px }
  body.edk .edk-logo span{ display:none }
  body.edk .edk-id #result-name{ max-width:18ch }
}
@media (prefers-reduced-motion:reduce){
  body.edk #download, body.edk .hd2-go, body.edk .edk-play, body.edk .sc-deep-cta, body.edk .hd2-find-go, body.edk #acct-chip::after{ transition:none }
}
