.profile-page { background: var(--paper); }
.profile-masthead {
  align-items: center;
  background: var(--paper);
  border-bottom: 3px solid var(--ink);
  display: flex;
  justify-content: space-between;
  padding: 16px 24px;
}
.profile-brand { font-family: "DM Serif Display", serif; font-size: 26px; }
.profile-brand span:first-child { color: var(--red); }
.profile-brand span:last-child { color: var(--gold); }
.breadcrumb { color: var(--grey); font-family: "Inconsolata", monospace; font-size: 11px; }
.breadcrumb a { color: var(--red); }
.profile-container { margin: 0 auto; max-width: 1180px; padding: 0 24px 60px; }
.cover-banner {
  background: radial-gradient(ellipse 500px 300px at 15% 0%, rgba(201,154,46,0.16), transparent 65%), radial-gradient(ellipse 400px 260px at 90% 100%, rgba(185,28,28,0.08), transparent 60%), linear-gradient(160deg, #e8e2d0, #d9d1b8);
  height: 150px;
}
.cover-inner { height: 100%; margin: 0 auto; max-width: 1180px; }
.profile-hero {
  align-items: end;
  display: grid;
  gap: 28px;
  grid-template-columns: 180px 1fr auto;
  margin-top: -64px;
  padding-bottom: 28px;
  position: relative;
}
.profile-photo {
  align-items: center;
  background: linear-gradient(135deg, #dfd9ca, #b8b096);
  border: 4px solid var(--paper);
  border-radius: 10px;
  box-shadow: 0 10px 28px rgba(13,15,12,0.1), 0 2px 6px rgba(13,15,12,0.06);
  color: var(--grey);
  display: flex;
  font-family: "DM Serif Display", serif;
  font-size: 48px;
  height: 164px;
  justify-content: center;
  width: 164px;
}
.profile-main { padding-bottom: 6px; }
.name-row { align-items: center; display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 6px; }
.name-row h1 { font-family: "DM Serif Display", serif; font-size: 36px; font-weight: 400; }
.verify-badge-lg {
  background: rgba(37,99,235,0.1);
  border: 1px solid rgba(37,99,235,0.25);
  border-radius: 20px;
  color: #2563eb;
  font-family: "Inconsolata", monospace;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
}
.profile-role { color: var(--grey); font-size: 15px; margin-bottom: 12px; }
.profile-meta-row { color: var(--grey); display: flex; flex-wrap: wrap; font-family: "Inconsolata", monospace; font-size: 12px; gap: 14px; margin-bottom: 14px; }
.rating-row { align-items: center; color: var(--grey); display: flex; flex-wrap: wrap; font-family: "Inconsolata", monospace; font-size: 12px; gap: 8px; }
.stars { color: var(--gold-bright); font-size: 15px; letter-spacing: 1px; }
.trust-score { background: var(--paper-dim); border: 1px solid var(--line-strong); border-radius: 20px; color: var(--ink); font-weight: 700; padding: 3px 9px; }
.profile-actions { display: flex; flex-direction: column; gap: 10px; min-width: 150px; padding-bottom: 6px; }
.profile-actions a, .availability-badge {
  border-radius: 4px;
  font-size: 13.5px;
  font-weight: 700;
  padding: 10px 18px;
  text-align: center;
}
.btn-follow { background: var(--red); box-shadow: 0 4px 12px rgba(185,28,28,0.25); color: #fff; }
.btn-contact, .btn-share-profile { background: #fff; border: 1px solid var(--line-strong); }
.btn-share-profile { color: var(--grey); font-size: 12px; }
.availability-badge { align-items: center; background: rgba(21,128,61,0.1); color: #15803d; display: inline-flex; font-family: "Inconsolata", monospace; font-size: 11.5px; gap: 6px; justify-content: center; }
.availability-badge span { background: #15803d; border-radius: 50%; height: 7px; width: 7px; }
.stats-bar {
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  box-shadow: 0 4px 18px rgba(13,15,12,0.06), 0 1px 3px rgba(13,15,12,0.05);
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  margin-bottom: 20px;
  overflow: hidden;
}
.stats-bar div { border-right: 1px solid var(--line); padding: 18px 10px; text-align: center; }
.stats-bar div:last-child { border-right: 0; }
.stats-bar strong { display: block; font-family: "DM Serif Display", serif; font-size: 23px; font-weight: 400; }
.stats-bar span { color: var(--grey); display: block; font-family: "Inconsolata", monospace; font-size: 9.5px; letter-spacing: 0.04em; margin-top: 4px; text-transform: uppercase; }
.engagement-card, .info-card, .web-mentions-card {
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  box-shadow: 0 4px 18px rgba(13,15,12,0.06), 0 1px 3px rgba(13,15,12,0.05);
}
.engagement-card { margin-bottom: 36px; padding: 22px; }
.engagement-head { align-items: baseline; display: flex; justify-content: space-between; margin-bottom: 18px; }
.engagement-head h2, .wm-head h2 { font-family: "DM Serif Display", serif; font-size: 18px; font-weight: 400; }
.engagement-head span, .wm-head span { color: var(--grey); font-family: "Inconsolata", monospace; font-size: 10.5px; }
.engagement-grid { display: grid; gap: 18px; grid-template-columns: repeat(4, 1fr); }
.engagement-grid article { background: var(--paper-dim); border-radius: 5px; padding: 14px; }
.engagement-grid strong { display: block; font-family: "DM Serif Display", serif; font-size: 20px; font-weight: 400; }
.engagement-grid b { color: #15803d; display: block; font-family: "Inconsolata", monospace; font-size: 10.5px; margin-top: 2px; }
.engagement-grid b.down { color: var(--red); }
.engagement-grid span { color: var(--grey); display: block; font-family: "Inconsolata", monospace; font-size: 9.5px; letter-spacing: 0.03em; margin-top: 6px; text-transform: uppercase; }
.profile-grid { display: grid; gap: 36px; grid-template-columns: 2fr 1fr; }
.bio-block { margin-bottom: 36px; }
.profile-section-title {
  border-bottom: 2px solid var(--ink);
  font-family: "Inconsolata", monospace;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  margin-bottom: 16px;
  padding-bottom: 9px;
  text-transform: uppercase;
}
.bio-text { color: #2b2b26; font-size: 14.5px; line-height: 1.7; }
.tag-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.tag-row span { background: var(--paper-dim); border: 1px solid var(--line-strong); border-radius: 20px; font-family: "Inconsolata", monospace; font-size: 11.5px; padding: 5px 12px; }
.tag-row .primary { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.portfolio-item { border-bottom: 1px solid var(--line); padding: 18px 0; }
.portfolio-item:first-of-type { padding-top: 0; }
.portfolio-top { display: grid; gap: 14px; grid-template-columns: 88px 1fr; }
.portfolio-thumb { background: linear-gradient(135deg, #e2ded2, #cac3ae); border: 1px solid var(--line); border-radius: 4px; height: 64px; width: 88px; }
.portfolio-item h3 { font-family: "DM Serif Display", serif; font-size: 16px; font-weight: 400; line-height: 1.3; margin-bottom: 6px; }
.portfolio-item p { color: var(--grey); font-family: "Inconsolata", monospace; font-size: 10.5px; }
.share-row { align-items: center; display: flex; flex-wrap: wrap; gap: 8px; margin-left: 102px; margin-top: 12px; }
.share-row span { border: 1px solid var(--line-strong); border-radius: 20px; color: var(--grey); font-family: "Inconsolata", monospace; font-size: 10.5px; font-weight: 700; padding: 5px 10px; }
.share-row b { color: var(--grey); font-family: "Inconsolata", monospace; font-size: 10px; margin-left: auto; }
.comment-item { border-bottom: 1px solid var(--line); display: flex; gap: 11px; padding: 14px 0; }
.comment-item > div { align-items: center; background: var(--paper-dim); border: 1px solid var(--line-strong); border-radius: 50%; color: var(--grey); display: flex; flex-shrink: 0; font-family: "DM Serif Display", serif; height: 32px; justify-content: center; width: 32px; }
.comment-item h3 { font-size: 12.5px; margin-bottom: 4px; }
.comment-item h3 span { color: var(--gold); font-family: "Inconsolata", monospace; font-size: 10px; }
.comment-item p { color: #2b2b26; font-size: 13px; line-height: 1.5; }
.comment-item small { color: var(--grey); display: block; font-family: "Inconsolata", monospace; font-size: 10px; margin-top: 5px; }
.web-mentions-card { margin-bottom: 36px; padding: 22px; }
.wm-head { align-items: flex-start; display: flex; gap: 12px; justify-content: space-between; margin-bottom: 6px; }
.wm-head span { border: 1px solid var(--line-strong); border-radius: 20px; color: var(--gold); font-weight: 700; padding: 3px 9px; white-space: nowrap; }
.web-mentions-card > p { color: var(--grey); font-size: 12px; line-height: 1.5; margin-bottom: 18px; }
.wm-item { align-items: flex-start; border-bottom: 1px solid var(--line); display: flex; gap: 12px; padding: 14px 0; }
.wm-item:last-child { border-bottom: 0; }
.wm-item > div { align-items: center; background: var(--paper-dim); border: 1px solid var(--line-strong); border-radius: 5px; display: flex; flex-shrink: 0; font-family: "Inconsolata", monospace; height: 32px; justify-content: center; width: 32px; }
.wm-item section { flex: 1; }
.wm-item h3 { font-size: 12.5px; }
.wm-item p { color: var(--grey); font-size: 12.5px; line-height: 1.4; margin-top: 2px; }
.wm-item small { background: rgba(146,102,10,0.12); border-radius: 2px; color: var(--gold); display: inline-block; font-family: "Inconsolata", monospace; font-size: 10px; font-weight: 700; margin-top: 6px; padding: 2px 7px; }
.wm-item small.high { background: rgba(21,128,61,0.1); color: #15803d; }
.wm-item aside { display: flex; flex-shrink: 0; gap: 6px; }
.wm-item aside span { border: 1px solid var(--line-strong); border-radius: 4px; font-family: "Inconsolata", monospace; font-size: 10px; font-weight: 700; padding: 5px 10px; }
.info-card { margin-bottom: 24px; padding: 18px; }
.info-card p { border-bottom: 1px dashed var(--line); display: flex; font-size: 12.5px; justify-content: space-between; padding: 8px 0; }
.info-card p:last-child { border-bottom: 0; }
.info-card p span { color: var(--grey); font-family: "Inconsolata", monospace; font-size: 10.5px; letter-spacing: 0.03em; text-transform: uppercase; }
.info-card p b { font-weight: 700; text-align: right; }
.card-header-row { align-items: baseline; display: flex; justify-content: space-between; margin-bottom: 12px; }
.card-header-row .profile-section-title { border: 0; margin: 0; padding: 0; }
.card-header-row label { color: var(--red); cursor: pointer; font-family: "Inconsolata", monospace; font-size: 10.5px; font-weight: 700; }
.website-list { margin-top: 10px; }
.website-list a { border-bottom: 1px dashed var(--line); color: var(--red); display: block; font-size: 12.5px; font-weight: 700; overflow: hidden; padding: 8px 0; text-overflow: ellipsis; white-space: nowrap; }
.website-list span { color: var(--grey); float: right; font-family: "Inconsolata", monospace; font-size: 9.5px; font-weight: 400; margin-left: 10px; }
.social-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.social-row span { border: 1px solid var(--line-strong); border-radius: 20px; font-family: "Inconsolata", monospace; font-size: 11px; font-weight: 700; padding: 6px 12px; }
.award-item { border-bottom: 1px solid var(--line); display: flex; gap: 10px; padding: 10px 0; }
.award-item > span { align-items: center; background: var(--gold-bright); border-radius: 50%; color: #fff; display: flex; flex-shrink: 0; font-family: "Inconsolata", monospace; font-size: 12px; height: 26px; justify-content: center; width: 26px; }
.award-item p { border: 0; display: block; line-height: 1.4; padding: 0; }
.award-item b { color: var(--grey); display: block; font-family: "Inconsolata", monospace; font-size: 10px; margin-top: 2px; text-align: left; }
.edit-toggle-input { display: none; }
.edit-modal-overlay { align-items: center; background: rgba(13,15,12,0.6); display: none; inset: 0; justify-content: center; padding: 20px; position: fixed; z-index: 50; }
#edit-links-toggle:checked ~ .edit-modal-overlay { display: flex; }
.edit-modal { background: var(--paper); border-radius: 6px; box-shadow: 0 30px 60px rgba(0,0,0,0.4); max-height: 90vh; max-width: 460px; overflow-y: auto; padding: 28px; position: relative; width: 100%; }
.edit-modal-close { align-items: center; border: 1px solid var(--line); border-radius: 50%; color: var(--grey); cursor: pointer; display: flex; height: 28px; justify-content: center; position: absolute; right: 16px; top: 16px; width: 28px; }
.edit-modal h2 { font-family: "DM Serif Display", serif; font-size: 20px; font-weight: 400; margin-bottom: 6px; padding-right: 20px; }
.edit-modal p, .edit-modal small { color: var(--grey); display: block; font-size: 12px; margin-bottom: 18px; }
.link-input-row { align-items: center; display: flex; gap: 8px; margin-bottom: 10px; }
.link-input-row select { flex-shrink: 0; width: 108px; }
.link-input-row input { flex: 1; min-width: 0; }
.link-input-row select, .link-input-row input, .link-input-row button {
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  color: var(--grey);
  font: inherit;
  padding: 10px 12px;
}
.link-input-row button { cursor: pointer; flex-shrink: 0; padding: 10px 12px; }
.modal-save-btn { background: var(--red); border-radius: 4px; color: #fff; cursor: pointer; display: block; font-weight: 700; padding: 13px; text-align: center; }

@media (max-width: 860px) {
  .profile-hero { grid-template-columns: 1fr; margin-top: -40px; }
  .cover-banner { height: 110px; }
  .profile-photo { font-size: 36px; height: 120px; width: 120px; }
  .profile-actions { flex-direction: row; flex-wrap: wrap; }
  .stats-bar { grid-template-columns: repeat(4, 1fr); }
  .engagement-grid { grid-template-columns: repeat(2, 1fr); }
  .profile-grid { grid-template-columns: 1fr; }
  .share-row { margin-left: 0; }
}

@media (max-width: 560px) {
  .profile-masthead { align-items: flex-start; flex-direction: column; gap: 6px; padding: 14px 16px; }
  .profile-container { padding: 0 16px 40px; }
  .name-row h1 { font-size: 30px; }
  .stats-bar, .engagement-grid { grid-template-columns: repeat(2, 1fr); }
  .wm-item { flex-wrap: wrap; }
  .wm-item aside { width: 100%; }
  .link-input-row { align-items: stretch; flex-direction: column; }
  .link-input-row select { width: 100%; }
}
