/*
JobMee! final quick-fix stylesheet
Place at: JobMee/static/final_quick_fixes.css
Load after styles.css and profile_layout_fix.css.
*/

/* ---------- Guided Job Finder: refinement + fresh batches ---------- */
.finder-feedback,
.finder-refine-bar label {
  display: grid;
  gap: 9px;
  margin-top: 20px;
  color: var(--app-text);
}

.finder-feedback > span,
.finder-refine-bar label > span {
  font: 700 12px/1.3 var(--font-display);
}

.finder-feedback > span small {
  color: var(--app-muted);
  font-weight: 500;
  margin-left: 5px;
}

.finder-feedback textarea,
.finder-refine-bar textarea {
  width: 100%;
  min-height: 104px;
  resize: vertical;
  border: 1px solid var(--app-line);
  border-radius: 15px;
  background: var(--field);
  color: var(--app-text);
  padding: 14px 15px;
  line-height: 1.55;
  outline: none;
}

.finder-feedback textarea:focus,
.finder-refine-bar textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(214, 255, 63, .14);
}

.finder-feedback > small {
  color: var(--app-muted);
  line-height: 1.45;
}

.finder-refine-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: end;
  margin: 22px 0 6px;
  padding: 18px;
  border: 1px solid var(--app-line);
  border-radius: 18px;
  background: var(--app-panel-2);
}

.finder-refine-bar label {
  margin: 0;
}

.finder-refine-bar > div {
  display: flex;
  align-items: end;
  padding-bottom: 1px;
}

.finder-refine-bar .ghost-button {
  white-space: nowrap;
}

/* ---------- Writing sample ---------- */
.writing-sample-card {
  grid-column: 1 / -1;
  min-width: 0;
}

.writing-sample-card .panel-head p {
  max-width: 900px;
  color: var(--app-muted);
  line-height: 1.6;
}

.writing-sample-drop {
  margin-top: 20px;
  min-height: 190px;
  border: 1px dashed color-mix(in srgb, var(--app-text) 24%, transparent);
  border-radius: 22px;
  background:
    radial-gradient(circle at 12% 10%, rgba(214,255,63,.12), transparent 34%),
    var(--app-panel-2);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 8px;
  text-align: center;
  padding: 28px;
  cursor: pointer;
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}

.writing-sample-drop:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
}

.writing-sample-drop input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.writing-sample-drop strong {
  font: 750 18px/1.3 var(--font-display);
  color: var(--app-text);
}

.writing-sample-drop small {
  color: var(--app-muted);
}

.writing-sample-preview {
  margin-top: 16px;
  border: 1px solid var(--app-line);
  border-radius: 17px;
  overflow: hidden;
  background: var(--app-panel-2);
}

.writing-sample-preview summary {
  padding: 15px 17px;
  cursor: pointer;
  font-weight: 700;
  color: var(--app-text);
}

.writing-sample-preview textarea {
  display: block;
  width: 100%;
  min-height: 270px;
  border: 0;
  border-top: 1px solid var(--app-line);
  padding: 18px;
  resize: vertical;
  outline: none;
  background: var(--field);
  color: var(--app-text);
  line-height: 1.65;
}

/* ---------- Application Studio contrast ---------- */
html[data-theme="light"] .editable-document {
  background: #ffffff !important;
  color: #111111 !important;
  border: 1px solid rgba(0,0,0,.12);
}

html[data-theme="light"] .editable-document input,
html[data-theme="light"] .editable-document textarea,
html[data-theme="light"] .cover-editor,
html[data-theme="light"] .application-answer-editor {
  background: #ffffff !important;
  color: #111111 !important;
  caret-color: #111111;
  border-color: rgba(0,0,0,.18) !important;
}

html[data-theme="light"] .editable-document input::placeholder,
html[data-theme="light"] .editable-document textarea::placeholder,
html[data-theme="light"] .cover-editor::placeholder,
html[data-theme="light"] .application-answer-editor::placeholder {
  color: #777777 !important;
}

html[data-theme="light"] .editable-document h4 {
  border-color: rgba(0,0,0,.34);
  color: #111111;
}

html[data-theme="dark"] .editable-document {
  background: #090909 !important;
  color: #f5f5f1 !important;
  border: 1px solid rgba(255,255,255,.14);
}

html[data-theme="dark"] .editable-document input,
html[data-theme="dark"] .editable-document textarea,
html[data-theme="dark"] .cover-editor,
html[data-theme="dark"] .application-answer-editor {
  background: #101010 !important;
  color: #f5f5f1 !important;
  caret-color: #d6ff3f;
  border-color: rgba(255,255,255,.18) !important;
}

html[data-theme="dark"] .editable-document h4 {
  border-color: rgba(255,255,255,.32);
  color: #f5f5f1;
}

/* Keep the job selector useful without letting its filter dominate the page. */
.studio-jobs .mini-search {
  flex: 0 0 auto !important;
  width: 100%;
  min-height: 44px;
  max-height: 48px;
  margin: 15px 0 12px;
  padding: 0 12px;
}

.studio-jobs .mini-search input {
  height: 42px;
  min-height: 42px !important;
  padding: 0 !important;
  line-height: 42px;
}

.studio-job-list {
  min-height: 0;
}

/* ---------- InterviewMee focused full-width practice ---------- */
.interview-layout.session-active {
  grid-template-columns: minmax(0, 1fr) !important;
}

.interview-layout.session-active .interview-jobs {
  display: none !important;
}

.interview-layout.session-active .interview-stage {
  width: 100%;
  min-width: 0;
}

.interview-layout.session-active .hirevue-stage {
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, .85fr);
}

.interview-layout.session-active .hirevue-screen {
  min-height: 520px;
}

.answer-timer {
  display: none !important;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .finder-refine-bar {
    grid-template-columns: 1fr;
  }

  .finder-refine-bar > div,
  .finder-refine-bar .ghost-button {
    width: 100%;
  }

  .interview-layout.session-active .hirevue-stage {
    grid-template-columns: 1fr;
  }

  .writing-sample-drop {
    min-height: 160px;
    padding: 22px 16px;
  }
}


/* =========================================================
   Guided Finder compact results + stable selection controls
   ========================================================= */
.finder-step.active {
  animation: none !important;
}

.finder-quick-picks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
  min-height: 34px;
}

.finder-quick-picks > span {
  width: 100%;
  color: var(--app-muted);
  font: 700 10px/1.3 var(--font-display);
  letter-spacing: 1px;
  text-transform: uppercase;
}

.finder-quick-picks button,
.priority-choice-grid button,
.source-choices button {
  border: 1px solid var(--app-line);
  background: var(--app-panel-2);
  color: var(--app-text);
  border-radius: 999px;
  min-height: 40px;
  padding: 8px 14px;
  font-weight: 700;
  line-height: 1.2;
  transition: border-color .14s ease, background-color .14s ease, color .14s ease;
  transform: none !important;
  box-shadow: none;
  -webkit-tap-highlight-color: transparent;
}

.finder-quick-picks button:hover,
.finder-quick-picks button.selected,
.priority-choice-grid button:hover,
.priority-choice-grid button.selected,
.source-choices button:hover,
.source-choices button.selected {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 13%, var(--app-panel-2));
  color: var(--app-text);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.priority-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.priority-choice-grid button {
  min-height: 54px;
  border-radius: 14px;
  text-align: left;
}

.source-choices {
  align-items: center;
}

.source-choices > button {
  padding: 9px 12px;
  min-height: 38px;
}

.source-choices > small {
  width: 100%;
  color: var(--app-muted);
  line-height: 1.5;
  margin-top: 4px;
}

.finder-results {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  align-items: stretch;
}

.finder-result {
  min-height: 390px;
  overflow: hidden;
}

.finder-result-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-top: 14px;
}

.finder-result-heading > div {
  min-width: 0;
}

.finder-result-heading h3 {
  margin: 0 0 5px;
}

.finder-result-heading small {
  flex: none;
  color: var(--app-muted);
  font-size: 10px;
}

.finder-result-description {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  overflow: hidden;
  min-height: 74px;
  margin-bottom: 12px;
}

.finder-fit-note {
  display: grid;
  gap: 5px;
  border-top: 1px solid var(--app-line);
  padding-top: 12px;
  color: var(--app-muted);
  font-size: 12px;
  line-height: 1.5;
}

.finder-fit-note b {
  color: var(--app-text);
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.status-chip.verified {
  background: color-mix(in srgb, var(--accent) 17%, var(--app-panel));
  border-color: color-mix(in srgb, var(--accent) 55%, var(--app-line));
  color: var(--app-text);
}

/* =========================================================
   Bring-in-a-job description layout
   ========================================================= */
.import-modal {
  width: min(920px, calc(100vw - 32px));
  max-height: min(900px, calc(100dvh - 32px));
}

.import-form {
  min-width: 0;
}

.indeed-import-help {
  margin-top: 14px;
  padding: 16px 18px;
  border: 1px solid #e4b44f;
  border-radius: 16px;
  background: color-mix(in srgb, #f4c760 13%, var(--app-panel));
  color: var(--app-text);
}

.indeed-import-help strong,
.indeed-import-help p {
  display: block;
  margin: 0;
}

.indeed-import-help p {
  margin-top: 6px;
  color: var(--app-muted);
  line-height: 1.55;
}

.description-import-card {
  display: grid;
  gap: 16px;
  border: 1px solid var(--app-line);
  border-radius: 22px;
  background: var(--app-panel-2);
  padding: clamp(18px, 3vw, 28px);
  text-align: left;
}

.description-import-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
}

.description-import-head h3 {
  margin: 7px 0 6px;
  font: 800 clamp(23px, 4vw, 34px)/1.1 var(--font-display);
  color: var(--app-text);
}

.description-import-head p {
  margin: 0;
  color: var(--app-muted);
  line-height: 1.5;
}

.description-import-label {
  display: grid !important;
  gap: 10px !important;
  width: 100%;
  min-width: 0;
}

.description-import-label > span {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--app-text);
  font: 750 13px/1.3 var(--font-display);
}

.description-import-label > span small {
  color: var(--app-muted);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.description-import-label textarea {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: clamp(320px, 48vh, 520px);
  padding: 20px;
  border: 1px solid var(--app-line) !important;
  border-radius: 18px !important;
  background: var(--field) !important;
  color: var(--app-text) !important;
  line-height: 1.65;
  resize: vertical;
  text-align: left;
  white-space: pre-wrap;
}

.description-import-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  color: var(--app-muted);
  font-size: 11px;
  line-height: 1.45;
}

#descriptionCharacterCount {
  flex: none;
  color: #b36d14;
}

#descriptionCharacterCount[data-ready="true"] {
  color: color-mix(in srgb, var(--accent) 70%, var(--app-text));
}

.description-import-tips {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.description-import-tips span {
  border: 1px solid var(--app-line);
  border-radius: 12px;
  padding: 10px 12px;
  color: var(--app-muted);
  background: var(--app-panel);
  font-size: 11px;
}

.description-import-fields {
  margin-top: 2px;
}

@media (max-width: 720px) {
  .priority-choice-grid,
  .description-import-tips {
    grid-template-columns: 1fr;
  }

  .finder-result {
    min-height: 0;
  }

  .finder-result-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .description-import-card {
    padding: 17px;
    border-radius: 18px;
  }

  .description-import-label textarea {
    min-height: 360px;
    padding: 16px;
  }

  .description-import-meta,
  .description-import-head {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* =========================================================
   Application Studio focus mode
   ========================================================= */
.studio-layout.job-active {
  grid-template-columns: minmax(0, 1fr) !important;
}

.studio-layout.job-active > .studio-jobs {
  display: none !important;
}

.studio-layout.job-active > .studio-output {
  width: 100%;
  max-width: none;
}

.studio-selection-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 22px;
  padding: 14px 16px;
  border: 1px solid var(--app-line);
  border-radius: 16px;
  background: var(--app-panel-2);
}

.studio-selection-bar > div {
  min-width: 0;
  text-align: right;
}

.studio-selection-bar strong,
.studio-selection-bar small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.studio-selection-bar strong {
  color: var(--app-text);
  font: 750 15px/1.3 var(--font-display);
  margin-top: 3px;
}

.studio-selection-bar small {
  color: var(--app-muted);
  margin-top: 2px;
}

.studio-change-job svg {
  transform: rotate(180deg);
}

/* =========================================================
   Multi-location guided finder
   ========================================================= */
.finder-location-composer {
  display: grid;
  gap: 8px;
  margin-top: 18px;
}

.finder-location-composer > label,
.finder-sponsorship-filter {
  color: var(--app-text);
  font: 700 12px/1.3 var(--font-display);
}

.finder-location-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 9px;
}

.finder-location-input-row input,
.finder-sponsorship-filter select {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  border: 1px solid var(--app-line);
  border-radius: 14px;
  background: var(--field);
  color: var(--app-text);
  padding: 0 14px;
  outline: none;
}

.finder-location-input-row input:focus,
.finder-sponsorship-filter select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 15%, transparent);
}

.finder-location-autocomplete,
.finder-quick-picks.horizontal {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: thin;
  padding: 2px 0 8px;
}

.finder-location-autocomplete button,
.finder-quick-picks.horizontal button {
  flex: 0 0 auto;
  border: 1px solid var(--app-line);
  border-radius: 999px;
  background: var(--app-panel-2);
  color: var(--app-text);
  padding: 8px 12px;
  white-space: nowrap;
}

.finder-location-autocomplete button:hover,
.finder-location-autocomplete button:focus,
.finder-quick-picks.horizontal button.selected {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 12%, var(--app-panel-2));
}

.finder-selected-locations {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 34px;
  margin: 12px 0;
}

.finder-selected-locations > span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 8px 9px 8px 12px;
  font-size: 11px;
  font-weight: 800;
}

.finder-selected-locations button {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent-ink) 12%, transparent);
  color: inherit;
  line-height: 1;
}

.finder-selected-locations small {
  color: var(--app-muted);
}

.finder-sponsorship-filter {
  display: grid;
  gap: 8px;
  margin-top: 20px;
}

.finder-sponsorship-filter small {
  color: var(--app-muted);
  font-weight: 500;
  line-height: 1.45;
}

/* =========================================================
   Sponsorship profile controls
   ========================================================= */
.sponsorship-profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--app-line);
}

.sponsorship-profile-grid label {
  display: grid;
  gap: 8px;
  color: var(--app-text);
  font-size: 11px;
  font-weight: 700;
}

.sponsorship-profile-grid .wide {
  grid-column: 1 / -1;
}

.sponsorship-profile-grid select,
.sponsorship-profile-grid textarea {
  width: 100%;
  border: 1px solid var(--app-line);
  border-radius: 14px;
  background: var(--field);
  color: var(--app-text);
  padding: 12px 14px;
  outline: none;
}

.sponsorship-profile-grid select:focus,
.sponsorship-profile-grid textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 15%, transparent);
}

/* =========================================================
   Word-like master résumé editor
   ========================================================= */
.resume-document-shell {
  overflow: hidden;
  margin-top: 20px;
  border: 1px solid var(--app-line);
  border-radius: 22px;
  background: var(--app-panel-2);
  box-shadow: 0 20px 60px rgba(0, 0, 0, .08);
}

.resume-document-toolbar {
  position: sticky;
  top: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  padding: 10px 12px;
  border-bottom: 1px solid var(--app-line);
  background: color-mix(in srgb, var(--app-panel) 94%, transparent);
  backdrop-filter: blur(12px);
}

.resume-document-toolbar > span {
  width: 1px;
  height: 26px;
  flex: 0 0 1px;
  background: var(--app-line);
}

.resume-document-toolbar button {
  min-width: 36px;
  min-height: 36px;
  flex: 0 0 auto;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--app-text);
  padding: 0 10px;
  font-size: 12px;
  font-weight: 750;
}

.resume-document-toolbar button:hover,
.resume-document-toolbar button:focus {
  border-color: var(--app-line);
  background: var(--app-soft);
}

.resume-document-status {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  padding: 10px 16px;
  border-bottom: 1px solid var(--app-line);
  color: var(--app-muted);
  font-size: 10px;
}

.resume-document-status > span {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}

.resume-document-status svg {
  color: var(--accent);
}

.resume-document-status > div {
  display: flex;
  gap: 13px;
}

.resume-rich-editor {
  width: min(850px, calc(100% - 32px));
  min-height: 720px;
  margin: 28px auto;
  padding: clamp(38px, 6vw, 72px);
  border: 1px solid rgba(0, 0, 0, .12);
  border-radius: 4px;
  background: #fff;
  color: #111;
  box-shadow: 0 16px 45px rgba(0, 0, 0, .14);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 11.5pt;
  line-height: 1.55;
  outline: none;
  caret-color: #111;
}

.resume-rich-editor:empty::before {
  content: attr(data-placeholder);
  color: #888;
  pointer-events: none;
}

.resume-rich-editor:focus {
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 25%, transparent), 0 18px 50px rgba(0, 0, 0, .16);
}

.resume-rich-editor h1,
.resume-rich-editor h2,
.resume-rich-editor h3 {
  color: #111 !important;
  font-family: Arial, Helvetica, sans-serif;
}

.resume-rich-editor h2 {
  margin: 24px 0 8px;
  padding-bottom: 5px;
  border-bottom: 1px solid #222;
  font-size: 12pt;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.resume-rich-editor p {
  margin: 0 0 10px;
}

.resume-rich-editor ul,
.resume-rich-editor ol {
  margin: 5px 0 12px;
  padding-left: 24px;
}

/* =========================================================
   Assessment modal: keep controls inside the container
   ========================================================= */
.test-modal {
  overflow: hidden !important;
  padding: 0 !important;
}

#testModalContent {
  display: flex;
  flex-direction: column;
  max-height: min(90vh, 900px);
  min-height: 0;
}

.test-modal-head {
  flex: 0 0 auto;
  padding: 25px 27px 18px;
  border-bottom: 1px solid var(--app-line);
}

.test-form-shell {
  display: flex;
  flex: 1 1 auto;
  min-height: 0;
  flex-direction: column;
}

.test-question-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 14px 27px 8px;
}

.test-modal-actions {
  flex: 0 0 auto;
  margin: 0 !important;
  padding: 15px 27px calc(15px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--app-line);
  background: var(--app-panel);
  box-shadow: 0 -12px 28px rgba(0, 0, 0, .08);
}

@media (max-width: 720px) {
  .studio-selection-bar {
    align-items: stretch;
    flex-direction: column;
  }

  .studio-selection-bar > div {
    text-align: left;
  }

  .studio-change-job {
    width: 100%;
  }

  .finder-location-input-row {
    grid-template-columns: 1fr;
  }

  .finder-location-input-row .ghost-button {
    width: 100%;
  }

  .sponsorship-profile-grid {
    grid-template-columns: 1fr;
  }

  .sponsorship-profile-grid .wide {
    grid-column: auto;
  }

  .resume-document-status {
    align-items: flex-start;
    flex-direction: column;
  }

  .resume-rich-editor {
    width: calc(100% - 16px);
    min-height: 560px;
    margin: 8px auto;
    padding: 28px 22px;
    border-radius: 2px;
  }

  .test-modal-head,
  .test-question-scroll,
  .test-modal-actions {
    padding-left: 18px;
    padding-right: 18px;
  }

  .test-modal-actions {
    display: grid !important;
    grid-template-columns: 1fr;
  }
}


/* =========================================================
   NON-BLOCKING MULTI-OPERATION PROGRESS TRAY
   ========================================================= */
.operation-loader {
  position: fixed !important;
  inset: auto 18px 18px auto !important;
  z-index: 1450 !important;
  width: min(430px, calc(100vw - 28px)) !important;
  max-height: min(72vh, 620px) !important;
  display: block !important;
  padding: 0 !important;
  background: transparent !important;
  backdrop-filter: none !important;
  pointer-events: none !important;
}
.operation-loader.hidden { display: none !important; }
.operation-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: inherit;
  overflow-y: auto;
  padding: 4px;
}
.operation-card {
  pointer-events: auto;
  border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--app-line));
  border-radius: 19px;
  padding: 15px 16px 14px;
  color: var(--app-text);
  background: color-mix(in srgb, var(--app-panel) 94%, transparent);
  box-shadow: 0 22px 60px rgba(0,0,0,.24);
  backdrop-filter: blur(18px);
  animation: operationCardIn .32s var(--ease);
}
.operation-card.complete { border-color: color-mix(in srgb, var(--accent) 65%, var(--app-line)); }
.operation-card.failed { border-color: #d65c50; }
.operation-card-head {
  display: grid;
  grid-template-columns: 18px minmax(0,1fr) 28px;
  gap: 10px;
  align-items: center;
}
.operation-card-head small,
.operation-card-head strong { display: block; }
.operation-card-head small {
  color: var(--accent);
  font: 800 9px/1.2 var(--font-display);
  letter-spacing: 1.35px;
}
.operation-card-head strong {
  margin-top: 3px;
  font: 750 14px/1.3 var(--font-display);
}
.operation-pulse {
  width: 14px;
  height: 14px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  display: grid;
  place-items: center;
}
.operation-pulse i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: operationPulse 1.1s ease-in-out infinite;
}
.operation-minimize {
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 50%;
  background: var(--app-panel-2);
  color: var(--app-muted);
  font-size: 19px;
}
.operation-card > p {
  margin: 12px 0 9px;
  color: var(--app-muted);
  font-size: 12px;
  line-height: 1.45;
}
.operation-progress {
  height: 5px;
  overflow: hidden;
  border-radius: 99px;
  background: var(--app-soft);
}
.operation-progress i {
  display: block;
  width: 4%;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--app-text));
  transition: width .45s linear;
}
.operation-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
  color: var(--app-muted);
  font-size: 10px;
}
.operation-footnote {
  display: block;
  margin-top: 8px;
  color: var(--app-muted);
  font-size: 9px;
  line-height: 1.35;
}
@keyframes operationCardIn {
  from { opacity: 0; transform: translateY(14px) scale(.98); }
}
@keyframes operationPulse {
  50% { transform: scale(.55); opacity: .5; }
}

/* =========================================================
   APPLICATION STUDIO DOCUMENT EDITORS
   ========================================================= */
.studio-word-editor {
  display: grid;
  gap: 0;
  width: 100%;
  min-width: 0;
}
.studio-editor-toolbar {
  position: sticky;
  top: 0;
  z-index: 6;
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
  padding: 10px;
  border: 1px solid var(--app-line);
  border-bottom: 0;
  border-radius: 17px 17px 0 0;
  background: var(--app-panel);
  box-shadow: 0 8px 20px rgba(0,0,0,.06);
}
.studio-editor-toolbar button {
  min-height: 34px;
  padding: 0 11px;
  border: 1px solid var(--app-line);
  border-radius: 9px;
  background: var(--app-panel-2);
  color: var(--app-text);
  font-weight: 700;
  font-size: 11px;
}
.studio-editor-toolbar button:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}
.studio-document-page {
  width: min(100%, 900px);
  min-height: 760px;
  margin: 0 auto;
  padding: clamp(34px, 6vw, 74px);
  border: 1px solid var(--app-line);
  border-radius: 0 0 17px 17px;
  outline: none;
  background: #fff;
  color: #151515;
  box-shadow: 0 24px 55px rgba(0,0,0,.12);
  font: 400 15px/1.65 "DM Sans", system-ui, sans-serif;
  caret-color: #111;
}
.studio-document-page:focus {
  border-color: color-mix(in srgb, var(--accent) 70%, #111);
  box-shadow: 0 0 0 4px rgba(214,255,63,.13), 0 24px 55px rgba(0,0,0,.12);
}
.studio-document-page h2 {
  margin: 25px 0 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid #cfcfcf;
  color: #111;
  font: 800 13px/1.3 var(--font-display);
  letter-spacing: 1.2px;
}
.studio-document-page h2:first-child { margin-top: 0; }
.studio-document-page h3 {
  margin: 18px 0 2px;
  color: #111;
  font: 750 16px/1.35 var(--font-display);
}
.studio-document-page p { color: #222; }
.studio-document-page ul,
.studio-document-page ol { padding-left: 24px; }
.studio-document-page li { margin: 6px 0; }
.studio-document-page .resume-context {
  margin: 2px 0 7px;
  color: #656565;
  font-size: 12px;
}
.cover-document { white-space: normal; }
.editor-status-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 4px 0;
  color: var(--app-muted);
  font-size: 10px;
}

@media (max-width: 720px) {
  .operation-loader {
    left: 10px !important;
    right: 10px !important;
    bottom: calc(10px + env(safe-area-inset-bottom)) !important;
    width: auto !important;
    max-height: 54vh !important;
  }
  .operation-card { padding: 13px; border-radius: 16px; }
  .operation-footnote { display: none; }
  .studio-editor-toolbar {
    overflow-x: auto;
    flex-wrap: nowrap;
    border-radius: 14px 14px 0 0;
  }
  .studio-editor-toolbar button { flex: 0 0 auto; }
  .studio-document-page {
    min-height: 620px;
    padding: 26px 20px 58px;
    border-radius: 0 0 14px 14px;
    font-size: 14px;
  }
  .editor-status-line { flex-direction: column; gap: 3px; }
}
