/* Employer company-profile editor */
.cp-page { max-width: 1180px; margin: 0 auto; }
.cp-head { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: stretch; margin-bottom: 24px; }
.cp-head-text { background: var(--brand-navy); color: #fff; border-radius: 18px; padding: 30px 32px; }
.cp-head-text h1 { margin: 0 0 10px; font-size: 1.6rem; color: #fff; }
.cp-head-text p { margin: 0; color: rgba(255,255,255,.82); font-size: .93rem; line-height: 1.7; }
.cp-progress-card { background: #fff; border: 1px solid var(--border, #e3e8ef); border-radius: 18px; padding: 24px; box-shadow: var(--ds-shadow-card); display: flex; flex-direction: column; gap: 10px; }
.cp-progress-top { display: flex; justify-content: space-between; align-items: baseline; font-size: .85rem; font-weight: 700; color: var(--text-light); }
.cp-progress-top strong { font-size: 2rem; color: var(--brand-navy); line-height: 1; }
.cp-bar { height: 10px; border-radius: 99px; background: #e6eaf0; overflow: hidden; }
.cp-bar span { display: block; height: 100%; background: var(--brand-gold); border-radius: 99px; transition: width .6s var(--ds-ease); }
.cp-progress-note { margin: 0; font-size: .8rem; color: var(--text-light); line-height: 1.55; }
.cp-preview { align-self: flex-start; margin-top: auto; }

.cp-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; align-items: start; }
.cp-tabs { position: sticky; top: 84px; display: flex; flex-direction: column; gap: 4px; background: #fff; border: 1px solid var(--border, #e3e8ef); border-radius: 16px; padding: 10px; }
.cp-tab { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 10px; font-weight: 700; font-size: .9rem; color: var(--text); text-decoration: none; transition: background .25s, color .25s; }
.cp-tab > i:first-child { width: 18px; text-align: center; color: var(--text-light); }
.cp-tab span { flex: 1; }
.cp-tab:hover { background: var(--ds-tint-dark); }
.cp-tab.is-active { background: var(--brand-navy); color: #fff; }
.cp-tab.is-active > i:first-child { color: var(--brand-gold); }
.cp-tab-done { color: #1e8e4e; font-size: .85rem; }
.cp-tab.is-active .cp-tab-done { color: var(--brand-gold); }

.cp-todo { position: relative; z-index: 1; background: var(--ds-tint-action); border-radius: 14px; padding: 14px 18px; margin-bottom: 18px; font-size: .88rem; }
.cp-todo-list a, .cp-preview-list a { pointer-events: auto; cursor: pointer; }
.cp-todo-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.cp-todo-list a { background: #fff; border: 1px solid rgba(44,62,80,.15); padding: 5px 12px; border-radius: 99px; font-size: .78rem; font-weight: 700; color: var(--brand-navy); text-decoration: none; }
.cp-todo-list a:hover { background: var(--brand-navy); color: #fff; }

.cp-card { background: #fff; border: 1px solid var(--border, #e3e8ef); border-radius: 18px; padding: 28px 30px; margin-bottom: 20px; box-shadow: var(--ds-shadow-card); display: block; }
.cp-card-head { margin-bottom: 22px; padding-bottom: 18px; border-bottom: 2px solid var(--bg, #f4f6fa); }
.cp-card-head h2 { margin: 4px 0 6px; font-size: 1.25rem; color: var(--brand-navy); }
.cp-card-head p { margin: 0; font-size: .88rem; color: var(--text-light); line-height: 1.65; }
.cp-step { display: inline-block; font-size: .7rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; background: var(--brand-gold); color: var(--brand-navy); padding: 3px 10px; border-radius: 99px; }
.cp-sub { margin: 26px 0 12px; font-size: .95rem; color: var(--brand-navy); }
.cp-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 22px; }

.cp-field { margin-bottom: 20px; }
.cp-field label { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: .9rem; color: var(--brand-navy); margin-bottom: 4px; }
.cp-req { color: #c0392b; }
.cp-opt { font-size: .66rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--text-light); background: var(--bg, #f4f6fa); padding: 2px 8px; border-radius: 99px; }
.cp-help { margin: 0 0 8px; font-size: .8rem; color: var(--text-light); line-height: 1.55; font-weight: 500; }
.cp-example { margin: 0 0 8px; font-size: .78rem; color: var(--text-light); background: var(--bg, #f4f6fa); border-left: 3px solid var(--brand-gold); padding: 6px 10px; border-radius: 0 8px 8px 0; line-height: 1.5; }
.cp-error { margin: 6px 0 0; font-size: .8rem; color: #c0392b; font-weight: 600; }
.cp-field.has-error .form-control { border-color: #c0392b; }
.cp-page .form-control, .cp-page select, .cp-page input[type=text], .cp-page input[type=email], .cp-page input[type=url], .cp-page input[type=number], .cp-page textarea {
  width: 100%; padding: 11px 14px; border: 1.5px solid #d5dbe3; border-radius: 10px; background: #fff; color: var(--text); font: inherit; font-size: .92rem; box-sizing: border-box; transition: border-color .25s, box-shadow .25s; }
.cp-page .form-control:focus, .cp-page select:focus, .cp-page textarea:focus, .cp-page input:focus { outline: none; border-color: var(--brand-navy); box-shadow: 0 0 0 3px rgba(44,62,80,.12); }
.cp-page input[type=file] { width: 100%; padding: 10px; border: 1.5px dashed #b8c2d0; border-radius: 10px; background: var(--bg, #f4f6fa); font: inherit; font-size: .85rem; box-sizing: border-box; }
.cp-page input[type=checkbox], .cp-page input[type=radio] { width: auto; }

.cp-media { display: flex; gap: 20px; align-items: flex-start; margin-bottom: 8px; }
.cp-media-field { flex: 1; min-width: 0; }
.cp-media-logo { width: 96px; height: 96px; border-radius: 50%; overflow: hidden; flex-shrink: 0; background: var(--brand-navy); color: var(--brand-gold); display: flex; align-items: center; justify-content: center; font-size: 1.8rem; font-weight: 700; border: 3px solid var(--brand-gold); }
.cp-media-logo img { width: 100%; height: 100%; object-fit: cover; }
.cp-media-cover-preview { width: 200px; height: 96px; border-radius: 12px; overflow: hidden; flex-shrink: 0; background: var(--ds-tint-dark); display: flex; align-items: center; justify-content: center; text-align: center; font-size: .78rem; color: var(--text-light); }
.cp-media-cover-preview img { width: 100%; height: 100%; object-fit: cover; }
.cp-check { display: inline-flex !important; align-items: center; gap: 8px; font-size: .82rem !important; font-weight: 600 !important; color: var(--text-light) !important; margin-top: 4px; cursor: pointer; }

.cp-visibility { margin-top: 10px; padding: 18px 20px; border-radius: 14px; background: var(--ds-tint-dark); }
.cp-visibility h3 { margin: 0 0 12px; font-size: .95rem; color: var(--brand-navy); }
.cp-switch { display: flex; gap: 14px; align-items: flex-start; cursor: pointer; }
.cp-switch input { position: absolute; opacity: 0; pointer-events: none; }
.cp-switch-ui { flex-shrink: 0; width: 46px; height: 26px; border-radius: 99px; background: #b8c2d0; position: relative; transition: background .25s; margin-top: 2px; }
.cp-switch-ui::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .25s; }
.cp-switch input:checked + .cp-switch-ui { background: var(--brand-navy); }
.cp-switch input:checked + .cp-switch-ui::after { transform: translateX(20px); background: var(--brand-gold); }
.cp-switch input:focus-visible + .cp-switch-ui { box-shadow: 0 0 0 3px rgba(44,62,80,.25); }
.cp-switch-text { font-size: .82rem; color: var(--text-light); line-height: 1.6; }
.cp-switch-text strong { display: block; font-size: .92rem; color: var(--brand-navy); margin-bottom: 4px; }

.cp-yesno { margin-bottom: 24px; border: 1px solid var(--border, #e3e8ef); border-radius: 14px; overflow: hidden; }
.cp-yesno-row { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 12px 16px; font-weight: 700; font-size: .88rem; color: var(--brand-navy); }
.cp-yesno-row + .cp-yesno-row { border-top: 1px solid var(--border, #e3e8ef); }
.cp-seg { display: inline-flex; border: 1.5px solid var(--brand-navy); border-radius: 10px; overflow: hidden; flex-shrink: 0; }
.cp-seg label { margin: 0; cursor: pointer; }
.cp-seg input { position: absolute; opacity: 0; pointer-events: none; }
.cp-seg span { display: block; padding: 6px 18px; font-size: .82rem; font-weight: 700; color: var(--brand-navy); transition: background .2s, color .2s; }
.cp-seg input:checked + span { background: var(--brand-navy); color: var(--brand-gold); }
.cp-seg input:focus-visible + span { outline: 2px solid var(--brand-gold); outline-offset: -2px; }

.cp-checks { display: flex; flex-wrap: wrap; gap: 10px; }
.cp-check-pill { display: inline-flex !important; margin: 0 !important; cursor: pointer; }
.cp-check-pill input { position: absolute; opacity: 0; pointer-events: none; }
.cp-check-pill span { padding: 8px 16px; border-radius: 99px; border: 1.5px solid #d5dbe3; font-size: .84rem; font-weight: 700; color: var(--text); transition: all .2s; }
.cp-check-pill input:checked + span { background: var(--brand-navy); border-color: var(--brand-navy); color: #fff; }
.cp-check-pill input:focus-visible + span { outline: 2px solid var(--brand-gold); outline-offset: 2px; }

/* tag input */
.cp-tagbox { display: flex; flex-wrap: wrap; gap: 8px; padding: 8px 10px; border: 1.5px solid #d5dbe3; border-radius: 10px; background: #fff; cursor: text; transition: border-color .25s, box-shadow .25s; }
.cp-tagbox:focus-within { border-color: var(--brand-navy); box-shadow: 0 0 0 3px rgba(44,62,80,.12); }
.cp-tagbox input { flex: 1; min-width: 160px; border: 0 !important; box-shadow: none !important; padding: 6px 4px !important; background: transparent !important; }
.cp-chip { display: inline-flex; align-items: center; gap: 8px; background: var(--brand-navy); color: #fff; padding: 5px 6px 5px 12px; border-radius: 99px; font-size: .82rem; font-weight: 700; }
.cp-chip button { width: 20px; height: 20px; border: 0; border-radius: 50%; background: rgba(255,255,255,.2); color: #fff; cursor: pointer; line-height: 1; font-size: .9rem; padding: 0; }
.cp-chip button:hover { background: var(--brand-gold); color: var(--brand-navy); }
.cp-suggest { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; align-items: center; font-size: .76rem; color: var(--text-light); }
.cp-suggest button { border: 1px dashed #b8c2d0; background: transparent; border-radius: 99px; padding: 3px 11px; font: inherit; font-size: .76rem; font-weight: 700; color: var(--text); cursor: pointer; }
.cp-suggest button:hover { border-color: var(--brand-navy); background: var(--ds-tint-dark); }

.cp-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; padding-top: 20px; border-top: 2px solid var(--bg, #f4f6fa); }

.cp-product { display: flex; gap: 18px; padding: 18px; border: 1px solid var(--border, #e3e8ef); border-radius: 14px; margin-bottom: 14px; }
.cp-product-new { background: var(--ds-tint-action); border-style: dashed; }
.cp-product-new h3 { margin: 0 0 10px; font-size: 1rem; color: var(--brand-navy); }
.cp-product-img { width: 96px; height: 96px; border-radius: 12px; overflow: hidden; flex-shrink: 0; background: var(--ds-tint-dark); display: flex; align-items: center; justify-content: center; color: var(--brand-navy); font-size: 1.5rem; }
.cp-product-img img { width: 100%; height: 100%; object-fit: cover; }
.cp-product-fields { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.cp-product-fields label { display: flex; flex-direction: column; gap: 5px; font-size: .84rem; font-weight: 700; color: var(--brand-navy); }
.cp-lbl { display: flex; align-items: center; gap: 8px; }
.cp-product-fields .cp-help { margin: 0; }
.cp-product-actions { display: flex; gap: 10px; }

.cp-upload { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 20px; }
.cp-upload input[type=file] { flex: 1; min-width: 220px; }
.cp-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.cp-gallery figure { position: relative; margin: 0; aspect-ratio: 4/3; border-radius: 12px; overflow: hidden; background: var(--ds-tint-dark); }
.cp-gallery img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cp-photo-remove { position: absolute; top: 8px; right: 8px; width: 34px; height: 34px; border: 0; border-radius: 50%; background: rgba(26,37,47,.85); color: #fff; cursor: pointer; transition: background .2s; }
.cp-photo-remove:hover { background: #c0392b; }
.cp-empty { padding: 30px; text-align: center; color: var(--text-light); background: var(--bg, #f4f6fa); border-radius: 12px; font-size: .9rem; margin: 0; }

@media (max-width: 1000px) {
  .cp-head { grid-template-columns: 1fr; }
  .cp-layout { grid-template-columns: 1fr; }
  .cp-tabs { position: static; flex-direction: row; overflow-x: auto; padding: 8px; gap: 6px; -webkit-overflow-scrolling: touch; }
  .cp-tab { flex-shrink: 0; white-space: nowrap; padding: 9px 14px; }
  .cp-tab span { flex: none; }
}
@media (max-width: 640px) {
  .cp-card { padding: 20px 16px; }
  .cp-grid { grid-template-columns: 1fr; }
  .cp-media { flex-direction: column; }
  .cp-media-cover-preview { width: 100%; }
  .cp-product { flex-direction: column; }
  .cp-yesno-row { flex-direction: column; align-items: flex-start; }
  .cp-actions .btn { flex: 1 1 100%; text-align: center; }
  .cp-head-text { padding: 22px 20px; }
}

[data-theme="dark"] .cp-card, [data-theme="dark"] .cp-progress-card, [data-theme="dark"] .cp-tabs, [data-theme="dark"] .cp-tagbox { background: #1a2030; border-color: rgba(255,255,255,.12); }
[data-theme="dark"] .cp-card-head h2, [data-theme="dark"] .cp-sub, [data-theme="dark"] .cp-field label, [data-theme="dark"] .cp-progress-top strong,
[data-theme="dark"] .cp-switch-text strong, [data-theme="dark"] .cp-visibility h3, [data-theme="dark"] .cp-yesno-row, [data-theme="dark"] .cp-product-new h3,
[data-theme="dark"] .cp-product-fields label { color: #e2e8f0; }
[data-theme="dark"] .cp-page .form-control, [data-theme="dark"] .cp-page select, [data-theme="dark"] .cp-page input[type=text], [data-theme="dark"] .cp-page input[type=email],
[data-theme="dark"] .cp-page input[type=url], [data-theme="dark"] .cp-page input[type=number], [data-theme="dark"] .cp-page textarea { background: #11161f; border-color: rgba(255,255,255,.18); color: #e2e8f0; }
[data-theme="dark"] .cp-page input[type=file], [data-theme="dark"] .cp-example, [data-theme="dark"] .cp-opt, [data-theme="dark"] .cp-empty { background: rgba(255,255,255,.06); color: #cbd5e1; }
[data-theme="dark"] .cp-tab { color: #e2e8f0; }
[data-theme="dark"] .cp-tab:hover { background: rgba(255,255,255,.08); }
[data-theme="dark"] .cp-tab.is-active, [data-theme="dark"] .cp-head-text { background: #24344a; }
[data-theme="dark"] .cp-todo-list a { background: #11161f; color: #e2e8f0; }
[data-theme="dark"] .cp-check-pill span, [data-theme="dark"] .cp-seg span { color: #e2e8f0; }
[data-theme="dark"] .cp-seg { border-color: rgba(255,255,255,.35); }
[data-theme="dark"] .cp-check-pill input:checked + span, [data-theme="dark"] .cp-seg input:checked + span { background: var(--brand-gold); color: var(--brand-navy); border-color: var(--brand-gold); }
[data-theme="dark"] .cp-chip { background: #2f4560; }
[data-theme="dark"] .cp-product, [data-theme="dark"] .cp-yesno { border-color: rgba(255,255,255,.14); }
[data-theme="dark"] .cp-product-new, [data-theme="dark"] .cp-visibility, [data-theme="dark"] .cp-todo { background: rgba(255,255,255,.06); }

.cp-steps { list-style: none; margin: 0 0 24px; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; counter-reset: none; }
.cp-steps li { min-width: 0; }
.cp-steps a { display: flex; flex-direction: column; gap: 8px; height: 100%; padding: 12px; border-radius: 14px; background: #fff; border: 1px solid var(--border, #e3e8ef); text-decoration: none; color: var(--text-light); font-size: .74rem; font-weight: 700; line-height: 1.35; transition: transform .25s, border-color .25s; }
.cp-steps a:hover { transform: translateY(-2px); border-color: var(--brand-navy); }
.cp-steps b { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--bg, #f4f6fa); color: var(--brand-navy); font-size: .78rem; }
.cp-steps .is-active a { background: var(--brand-navy); color: #fff; border-color: var(--brand-navy); }
.cp-steps .is-active b { background: var(--brand-gold); color: var(--brand-navy); }
.cp-steps .is-done b { background: #1e8e4e; color: #fff; }
.cp-preview-list { list-style: none; margin: 0 0 8px; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 22px; }
.cp-preview-list li a { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 10px; background: var(--bg, #f4f6fa); text-decoration: none; color: var(--text); font-weight: 700; font-size: .88rem; }
.cp-preview-list li.is-done a > i { color: #1e8e4e; }
.cp-preview-list li:not(.is-done) a > i { color: #b8c2d0; }
.cp-preview-list em { margin-left: auto; font-style: normal; font-size: .72rem; color: var(--text-light); }
@media (max-width: 1000px) { .cp-steps { grid-template-columns: repeat(7, 150px); overflow-x: auto; padding-bottom: 6px; } }
@media (max-width: 640px) { .cp-preview-list { grid-template-columns: 1fr; } }
[data-theme="dark"] .cp-steps a { background: #1a2030; border-color: rgba(255,255,255,.12); color: #cbd5e1; }
[data-theme="dark"] .cp-steps .is-active a { background: #24344a; }
[data-theme="dark"] .cp-preview-list li a { background: rgba(255,255,255,.06); color: #e2e8f0; }

.cp-counter { margin-top: 6px; font-size: .78rem; font-weight: 700; color: var(--text-light); }
.cp-counter.is-good { color: #1e8e4e; }
.cp-counter.is-short { color: #b26a00; }
.cp-counter.is-long { color: #c0392b; }
.cp-toolbar { display: flex; gap: 8px; margin-bottom: 8px; }
.cp-toolbar button { border: 1.5px solid var(--brand-navy); background: #fff; color: var(--brand-navy); border-radius: 8px; padding: 5px 12px; font: inherit; font-size: .78rem; font-weight: 700; cursor: pointer; }
.cp-toolbar button:hover { background: var(--brand-navy); color: #fff; }
.cp-format-tip code { background: var(--bg, #f4f6fa); padding: 1px 6px; border-radius: 5px; }
[data-theme="dark"] .cp-toolbar button { background: transparent; color: #e2e8f0; border-color: rgba(255,255,255,.35); }
