/* Buyer profile — mockup 1:1 */

.pf-page {
  --pf-radius: 14px;
  --pf-radius-sm: 10px;
  --pf-border: #e8e9ee;
  --pf-soft: #f3f4f8;
  --pf-max: var(--site-max, 1240px);
  background: var(--background, #f8f8fa);
  width: 100%;
  max-width: var(--pf-max);
  margin: 0 auto;
  padding: 0 var(--site-gutter, 1.5rem) 2.5rem;
  box-sizing: border-box;
}

.pf-mode {
  display: inline-flex;
  gap: 0.25rem;
  padding: 0.25rem;
  margin: 1rem 0 0.35rem;
  border-radius: 12px;
  background: #eceef3;
  border: 1px solid var(--pf-border);
}

.pf-mode-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 7.5rem;
  padding: 0.5rem 0.95rem;
  border-radius: 9px;
  color: var(--text-secondary);
  font-weight: 750;
  font-size: 0.88rem;
  text-decoration: none;
}

.pf-mode-btn:hover {
  color: var(--text-primary);
}

.pf-mode-btn.on {
  background: #fff;
  color: var(--primary);
  box-shadow: 0 1px 4px rgba(23, 24, 39, 0.08);
}

.pf-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  flex-wrap: wrap;
  padding: 1.35rem 0 0.35rem;
}

.pf-hero-main {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  min-width: 0;
}

.pf-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  background: var(--primary);
  color: #fff;
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  overflow: hidden;
}

.pf-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pf-avatar.lg {
  width: 88px;
  height: 88px;
  font-size: 1.6rem;
}

.pf-hero-text {
  min-width: 0;
}

.pf-hero-name-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.55rem 0.7rem;
}

.pf-hero-text h1 {
  margin: 0;
  font-size: 1.55rem;
  letter-spacing: -0.03em;
  font-weight: 800;
  color: var(--text-primary);
}

.pf-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 0.72rem;
  font-weight: 750;
}

.pf-hero-meta {
  margin-top: 0.35rem;
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

.pf-hero-meta span + span::before {
  content: " · ";
  opacity: 0.55;
}

.pf-btn-edit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.55rem 0.95rem;
  border-radius: 10px;
  border: 1px solid var(--pf-border);
  background: #fff;
  color: var(--text-primary);
  font-weight: 650;
  font-size: 0.9rem;
  text-decoration: none;
  cursor: pointer;
}

.pf-btn-edit:hover {
  border-color: rgba(var(--primary-rgb), 0.35);
  color: var(--primary);
}

.pf-tabs {
  display: flex;
  gap: 0.15rem 1.35rem;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--pf-border);
  margin: 0.85rem 0 1.25rem;
}

.pf-tab {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.75rem 0.1rem 0.85rem;
  border: 0;
  background: none;
  color: var(--text-muted);
  font-weight: 650;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
}

.pf-tab:hover {
  color: var(--text-primary);
}

.pf-tab.on {
  color: var(--primary);
  font-weight: 750;
}

.pf-tab.on::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--primary);
}

.pf-tab-count {
  display: inline-grid;
  place-items: center;
  min-width: 1.35rem;
  height: 1.35rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 0.72rem;
  font-weight: 800;
}

.pf-tab.on .pf-tab-count {
  background: var(--primary);
  color: #fff;
}

.pf-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 1.15rem;
  align-items: start;
}

@media (max-width: 980px) {
  .pf-layout {
    grid-template-columns: 1fr;
  }

  .pf-side {
    order: -1;
  }
}

.pf-main {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 0;
}

.pf-side {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.pf-card {
  background: #fff;
  border: 1px solid var(--pf-border);
  border-radius: var(--pf-radius);
  box-shadow: 0 4px 14px rgba(23, 24, 39, 0.04);
  padding: 1.15rem 1.2rem;
}

.pf-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.95rem;
}

.pf-card-head h2 {
  margin: 0;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.pf-count {
  display: inline-grid;
  place-items: center;
  min-width: 1.45rem;
  height: 1.45rem;
  padding: 0 0.4rem;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 800;
}

.pf-count.muted {
  background: #eceef3;
  color: var(--text-muted);
}

.pf-link {
  color: var(--primary);
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
}

.pf-link:hover {
  text-decoration: underline;
}

.pf-link.muted {
  color: var(--text-muted);
  font-weight: 650;
}

.pf-side-label {
  margin: 0 0 0.85rem;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.pf-side-profile {
  text-align: center;
}

.pf-side-avatar {
  width: 88px;
  height: 88px;
  margin: 0 auto 0.75rem;
  border-radius: 50%;
  background: var(--pf-soft);
  color: var(--text-muted);
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px dashed #d5d7e0;
  cursor: pointer;
  position: relative;
}

.pf-side-avatar.has-img {
  border-style: solid;
  border-color: var(--pf-border);
}

.pf-side-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pf-side-avatar .plus {
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1;
}

.pf-side-avatar .hint {
  font-size: 0.72rem;
  font-weight: 650;
  margin-top: 0.15rem;
}

.pf-side-name {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.pf-side-role {
  margin: 0.2rem 0 0.95rem;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.pf-kv {
  display: grid;
  gap: 0.55rem;
  text-align: left;
  margin: 0 0 0.95rem;
}

.pf-kv-row {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.88rem;
}

.pf-kv-row span {
  color: var(--text-muted);
}

.pf-kv-row strong {
  font-weight: 700;
  color: var(--text-primary);
  text-align: right;
}

.pf-activity-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.35rem;
  text-align: center;
  margin-bottom: 0.85rem;
}

.pf-activity-stats .n {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-primary);
}

.pf-activity-stats .l {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 650;
}

.pf-activity-line {
  height: 2px;
  background: linear-gradient(90deg, var(--primary), #cfc7ea 55%, #e5e7ef);
  border-radius: 999px;
  position: relative;
  margin: 0.35rem 0.4rem 0.75rem;
}

.pf-activity-line::before,
.pf-activity-line::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
  transform: translateY(-50%);
}

.pf-activity-line::before {
  left: 0;
}

.pf-activity-line::after {
  right: 0;
  background: #cfc7ea;
}

.pf-activity-empty {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.86rem;
  margin: 0;
}

.pf-reco-list {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.pf-reco {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 0.65rem;
  align-items: center;
  text-decoration: none;
  color: inherit;
}

.pf-reco img,
.pf-reco .ph {
  width: 52px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
  background: var(--pf-soft);
  display: grid;
  place-items: center;
  color: var(--text-muted);
  font-size: 0.7rem;
  font-weight: 700;
}

.pf-reco strong {
  display: block;
  font-size: 0.86rem;
  letter-spacing: -0.01em;
}

.pf-reco .price {
  color: var(--primary);
  font-weight: 800;
  font-size: 0.86rem;
}

.pf-reco .meta {
  color: var(--text-muted);
  font-size: 0.75rem;
}

.pf-complete {
  position: relative;
  border-color: rgba(var(--primary-rgb), 0.22);
  background: linear-gradient(160deg, #fff, var(--primary-soft));
}

.pf-complete h2 {
  margin: 0 0 0.25rem;
  font-size: 1.05rem;
}

.pf-complete p {
  margin: 0 0 0.85rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.pf-complete-close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1.2rem;
  line-height: 1;
}

.pf-progress-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.45rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary);
}

.pf-progress {
  height: 8px;
  border-radius: 999px;
  background: rgba(var(--primary-rgb), 0.12);
  overflow: hidden;
  margin-bottom: 0.95rem;
}

.pf-progress > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--primary);
}

.pf-checklist {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.pf-check {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.92rem;
}

.pf-check-left {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}

.pf-check-ico {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid #d5d7e0;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  font-size: 0.7rem;
  color: transparent;
}

.pf-check.done .pf-check-ico {
  border-color: #22c55e;
  background: #22c55e;
  color: #fff;
}

.pf-empty {
  text-align: center;
  padding: 2rem 1rem 1.6rem;
}

.pf-empty-ico {
  width: 72px;
  height: 72px;
  margin: 0 auto 1rem;
  border-radius: 50%;
  background: var(--pf-soft);
  color: #b0b4c0;
  display: grid;
  place-items: center;
}

.pf-empty-ico svg {
  width: 32px;
  height: 32px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pf-empty h3 {
  margin: 0 0 0.4rem;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
}

.pf-empty p {
  margin: 0 auto 1.15rem;
  max-width: 28rem;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.pf-empty-actions {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.pf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.65rem 1.05rem;
  border-radius: 10px;
  border: 0;
  background: var(--primary);
  color: #fff;
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  cursor: pointer;
}

.pf-btn:hover {
  background: var(--primary-hover);
}

.pf-btn.ghost {
  background: #fff;
  color: var(--primary);
  border: 1px solid rgba(var(--primary-rgb), 0.28);
}

.pf-tips {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}

.pf-tips.x2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 720px) {
  .pf-tips,
  .pf-tips.x2 {
    grid-template-columns: 1fr;
  }
}

.pf-tip {
  background: #fff;
  border: 1px solid var(--pf-border);
  border-radius: var(--pf-radius);
  padding: 1rem;
}

.pf-tip-ico {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--primary-soft);
  color: var(--primary);
  display: grid;
  place-items: center;
  margin-bottom: 0.65rem;
}

.pf-tip-ico svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pf-tip strong {
  display: block;
  margin-bottom: 0.25rem;
  font-size: 0.92rem;
}

.pf-tip p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.84rem;
  line-height: 1.4;
}

.pf-saved-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

@media (max-width: 720px) {
  .pf-saved-grid {
    grid-template-columns: 1fr;
  }
}

.pf-saved-item {
  display: grid;
  grid-template-columns: 108px 1fr;
  gap: 0.75rem;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}

.pf-saved-item img,
.pf-saved-item .ph {
  width: 108px;
  height: 78px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--pf-soft);
}

.pf-saved-item strong {
  display: block;
  font-size: 0.92rem;
  letter-spacing: -0.01em;
  margin-bottom: 0.15rem;
}

.pf-saved-item .price {
  color: var(--primary);
  font-weight: 800;
  font-size: 0.95rem;
  margin-bottom: 0.2rem;
}

.pf-saved-item .specs {
  color: var(--text-muted);
  font-size: 0.78rem;
  line-height: 1.35;
}

.pf-search-list,
.pf-activity-list,
.pf-row-list {
  display: flex;
  flex-direction: column;
}

.pf-search-row,
.pf-activity-row,
.pf-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid #eef0f4;
}

.pf-search-row:last-child,
.pf-activity-row:last-child,
.pf-row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.pf-search-row:first-child,
.pf-activity-row:first-child,
.pf-row:first-child {
  padding-top: 0;
}

.pf-search-title {
  font-weight: 750;
  font-size: 0.95rem;
  margin-bottom: 0.3rem;
}

.pf-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.pf-tag {
  display: inline-flex;
  padding: 0.14rem 0.45rem;
  border-radius: 6px;
  background: #f1f2f6;
  color: var(--text-secondary);
  font-size: 0.72rem;
  font-weight: 650;
}

.pf-search-actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex: 0 0 auto;
}

.pf-pill {
  display: inline-flex;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 0.72rem;
  font-weight: 750;
}

.pf-pill.flat {
  background: transparent;
  color: var(--text-muted);
}

.pf-foot-note {
  margin: 0.85rem 0 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.8rem;
}

.pf-activity-row {
  justify-content: flex-start;
}

.pf-act-ico {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--primary-soft);
  color: var(--primary);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.pf-act-ico svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
}

.pf-act-body strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 650;
}

.pf-act-body span {
  color: var(--text-muted);
  font-size: 0.78rem;
}

.pf-vehicle-list {
  display: flex;
  flex-direction: column;
}

.pf-vehicle {
  display: grid;
  grid-template-columns: 120px 1fr auto;
  gap: 0.9rem;
  align-items: center;
  padding: 0.85rem 0;
  border-bottom: 1px solid #eef0f4;
  text-decoration: none;
  color: inherit;
}

.pf-vehicle:last-child {
  border-bottom: 0;
}

.pf-vehicle img,
.pf-vehicle .ph {
  width: 120px;
  height: 84px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--pf-soft);
}

.pf-vehicle strong {
  display: block;
  font-size: 1rem;
  margin-bottom: 0.15rem;
}

.pf-vehicle .price {
  color: var(--primary);
  font-weight: 800;
  margin-bottom: 0.25rem;
}

.pf-vehicle .specs {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.pf-vehicle-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.65rem;
}

.pf-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.85rem;
}

.pf-chip {
  border: 0;
  border-radius: 999px;
  padding: 0.4rem 0.75rem;
  background: #eef0f4;
  color: var(--text-secondary);
  font-weight: 650;
  font-size: 0.82rem;
  cursor: pointer;
}

.pf-chip.on {
  background: var(--primary);
  color: #fff;
}

.pf-settings-stack {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.pf-row-label {
  min-width: 0;
}

.pf-row-label strong {
  display: block;
  font-size: 0.92rem;
}

.pf-row-label span,
.pf-row-value {
  color: var(--text-muted);
  font-size: 0.88rem;
}

.pf-row-value {
  font-weight: 650;
  color: var(--text-primary);
  margin-right: 0.75rem;
}

.pf-row-right {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex: 0 0 auto;
}

.pf-toggle {
  width: 44px;
  height: 26px;
  border-radius: 999px;
  border: 0;
  background: #d7dae3;
  position: relative;
  cursor: pointer;
  flex: 0 0 auto;
  transition: background 0.15s ease;
}

.pf-toggle::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
  transition: transform 0.15s ease;
}

.pf-toggle.on {
  background: var(--primary);
}

.pf-toggle.on::after {
  transform: translateX(18px);
}

.pf-danger {
  border-color: #fecaca;
  background: #fff7f7;
}

.pf-danger .pf-card-head h2,
.pf-danger .pf-row-label strong {
  color: #b91c1c;
}

.pf-btn-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 0.9rem;
  border-radius: 10px;
  border: 1px solid #f87171;
  background: #fff;
  color: #b91c1c;
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
}

.pf-btn-danger:hover {
  background: #fef2f2;
}

.pf-secure {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
}

.pf-secure-ico {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--primary-soft);
  color: var(--primary);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.pf-secure h3 {
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
}

.pf-secure p,
.pf-secure li {
  color: var(--text-muted);
  font-size: 0.84rem;
  line-height: 1.4;
}

.pf-secure ul {
  margin: 0.55rem 0 0;
  padding-left: 1.1rem;
}

.pf-new-list .pf-vehicle {
  grid-template-columns: 92px 1fr auto;
}

.pf-new-list .pf-vehicle img,
.pf-new-list .pf-vehicle .ph {
  width: 92px;
  height: 68px;
}

.pf-hidden-file {
  display: none;
}

@media (max-width: 640px) {
  .pf-page {
    padding-bottom: 5.5rem;
  }

  .pf-hero {
    align-items: flex-start;
  }

  .pf-avatar,
  .pf-avatar.lg {
    width: 64px;
    height: 64px;
    font-size: 1.15rem;
  }

  .pf-hero-text h1 {
    font-size: 1.25rem;
  }

  .pf-tabs {
    gap: 0.1rem 0.95rem;
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .pf-tabs::-webkit-scrollbar {
    display: none;
  }

  .pf-tab {
    white-space: nowrap;
    font-size: 0.88rem;
  }

  .pf-vehicle {
    grid-template-columns: 88px 1fr;
  }

  .pf-vehicle-actions {
    grid-column: 2;
    flex-direction: row;
    justify-content: space-between;
    width: 100%;
  }

  .pf-vehicle img,
  .pf-vehicle .ph {
    width: 88px;
    height: 66px;
  }
}
