/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #0e0e10;
  --surface:   #18181c;
  --surface2:  #222228;
  --border:    #2e2e38;
  --accent:    #7c6ef7;
  --accent2:   #a78bfa;
  --text:      #f0f0f4;
  --muted:     #8888a0;
  --success:   #4ade80;
  --radius:    14px;
  --radius-sm: 8px;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

/* ── Header ── */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 40px;
  background: rgba(14,14,16,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--text);
}
.logo span { color: var(--accent); }

.btn-post {
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 10px 22px;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}
.btn-post:hover { background: var(--accent2); transform: translateY(-1px); }

.btn-ghost {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--border);
  padding: 10px 18px;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.btn-ghost:hover { color: var(--text); border-color: var(--muted); }

.header-right { display: flex; align-items: center; gap: 10px; }

.user-menu { display: flex; align-items: center; gap: 10px; }

/* ── User Dropdown ── */
.user-dropdown-wrap {
  position: relative;
}
.user-email {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 50px;
  transition: color 0.2s, background 0.2s;
  display: block;
  white-space: nowrap;
}
.user-dropdown-wrap:hover .user-email {
  color: var(--accent2);
  background: rgba(124,110,247,0.1);
}
.user-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 6px;
  min-width: 180px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.4);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
  transition: opacity 0.15s, transform 0.15s;
  z-index: 150;
}
.user-dropdown-wrap:hover .user-dropdown {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}
.dropdown-item {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  background: none;
  border: none;
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 500;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  text-align: left;
  transition: background 0.15s;
}
.dropdown-item:hover { background: var(--surface2); }
.dropdown-item--muted { color: var(--muted); cursor: default; }
.dropdown-item--muted:hover { background: none; }
.dropdown-item--danger { color: #f87171; }
.dropdown-item--danger:hover { background: rgba(248,113,113,0.08); }
.dropdown-divider {
  height: 1px;
  background: var(--border);
  margin: 4px 6px;
}
.coming-soon {
  font-size: 0.65rem;
  font-weight: 700;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 1px 7px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-left: auto;
}

/* ── Slide Panel (My Posts) ── */
.bid-backdrop {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(0,0,0,0.6);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}
.bid-backdrop.active { opacity: 1; pointer-events: all; }

.bid-panel {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: 100%;
  max-width: 480px;
  z-index: 400;
  background: var(--surface);
  border-left: 1px solid var(--border);
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow-y: auto;
}
.bid-panel.active { transform: translateX(0); }

.bid-panel-inner {
  padding: 36px 32px 60px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* ── My Posts Panel ── */
.my-post-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.my-post-info { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.my-post-title { font-size: 0.95rem; font-weight: 700; }
.my-post-meta { display: flex; gap: 6px; flex-wrap: wrap; font-size: 0.75rem; }
.my-post-actions { display: flex; gap: 8px; align-items: center; flex-shrink: 0; }

/* ── Auth Modal ── */
.auth-tabs {
  display: flex;
  gap: 4px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 4px;
  margin-bottom: 32px;
  width: fit-content;
}
.auth-tab {
  background: transparent;
  border: none;
  color: var(--muted);
  padding: 8px 22px;
  border-radius: 50px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.auth-tab.active { background: var(--accent); color: #fff; }

/* Phone input */
.phone-input-wrap {
  display: flex;
  align-items: center;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.phone-input-wrap:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(124,110,247,0.15);
}
.dial-select {
  width: auto;
  border: none;
  border-right: 1px solid var(--border);
  border-radius: 0;
  background: var(--surface2);
  color: var(--text);
  padding: 11px 10px;
  font-size: 0.88rem;
  cursor: pointer;
  box-shadow: none;
  background-image: none;
}
.dial-select:focus { box-shadow: none; border-color: transparent; }
.phone-input-wrap input {
  border: none;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
  flex: 1;
}
.phone-input-wrap input:focus { box-shadow: none; }

.password-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.password-wrap input { padding-right: 64px; }
.btn-show-pass {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 6px;
  transition: color 0.15s;
}
.btn-show-pass:hover { color: var(--text); }

.recovery-user-info {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 24px;
}
.recovery-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.recovery-name { font-size: 0.95rem; font-weight: 700; }
.recovery-email { font-size: 0.8rem; color: var(--muted); margin-top: 2px; }

.input-readonly {
  opacity: 0.6;
  cursor: not-allowed;
  border-style: dashed !important;
}
.input-readonly:focus {
  border-color: var(--border) !important;
  box-shadow: none !important;
}

.forgot-wrap {
  display: flex;
  justify-content: flex-end;
  margin-top: -12px;
  margin-bottom: 4px;
}
.btn-forgot {
  background: none;
  border: none;
  color: var(--accent2);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  transition: color 0.15s;
}
.btn-forgot:hover { color: #fff; }

.btn-back {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  margin-bottom: 24px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.15s;
}
.btn-back:hover { color: var(--text); }

.auth-success {
  color: var(--success);
  font-size: 0.82rem;
  margin-top: 10px;
  min-height: 18px;
}

.auth-error {
  color: #f87171;
  font-size: 0.82rem;
  margin-top: 10px;
  min-height: 18px;
}

/* ── Hero ── */
.hero {
  text-align: center;
  padding: 72px 20px 48px;
}
.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -1px;
  background: linear-gradient(135deg, #fff 30%, var(--accent2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p { margin-top: 16px; color: var(--muted); font-size: 1.1rem; }

/* ── Listings Grid ── */
.listings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
  max-width: 1200px;
  margin: 0 auto 80px;
  padding: 0 32px;
}

/* ── Empty State ── */
.empty-state {
  text-align: center;
  padding: 60px 20px 120px;
  color: var(--muted);
  display: none;
}
.empty-state.visible { display: block; }
.empty-icon { font-size: 3rem; margin-bottom: 14px; opacity: 0.3; }

/* ── Listing Card ── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
  animation: cardIn 0.35s ease both;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.4);
  border-color: rgba(124,110,247,0.35);
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}
.card-title { font-size: 1.05rem; font-weight: 700; line-height: 1.3; color: var(--text); }
.card-pay {
  white-space: nowrap;
  font-size: 1rem;
  font-weight: 700;
  color: var(--success);
  background: rgba(74,222,128,0.1);
  border-radius: 50px;
  padding: 4px 12px;
}
.card-meta { display: flex; flex-wrap: wrap; gap: 8px; font-size: 0.78rem; color: var(--muted); }
.meta-pill {
  display: flex;
  align-items: center;
  gap: 4px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 3px 10px;
}
.card-desc {
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.card-skills { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.skill-tag {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent2);
  background: rgba(124,110,247,0.12);
  border: 1px solid rgba(124,110,247,0.25);
  border-radius: 50px;
  padding: 3px 10px;
}

/* ── Card Bid Row ── */
.card-bid-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
  flex-wrap: wrap;
}
.card-bid-label { color: var(--muted); }
.card-bid-amount { font-weight: 700; color: var(--success); }
.card-bid-cta { margin-left: auto; color: var(--accent2); font-weight: 600; transition: color 0.15s; }
.card:hover .card-bid-cta { color: #fff; }

/* ── Shared Overlay Base ── */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(8,8,10,0.97);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
  overflow-y: auto;
  padding: 40px 20px;
}
.overlay.active { opacity: 1; pointer-events: all; }

/* ── Post Listing Form Container ── */
.form-container {
  position: relative;
  width: 100%;
  max-width: 620px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 48px 44px;
  transform: translateY(24px);
  transition: transform 0.3s;
}
.overlay.active .form-container { transform: translateY(0); }

/* ── Task Detail Overlay ── */
.detail-overlay { z-index: 300; align-items: flex-start; padding: 0; }

.detail-container {
  position: relative;
  width: 100%;
  min-height: 100%;
  background: var(--bg);
  transform: translateY(20px);
  transition: transform 0.3s;
  display: flex;
  flex-direction: column;
}
.detail-overlay.active .detail-container { transform: translateY(0); }

.detail-close {
  position: fixed;
  top: 20px;
  right: 24px;
  z-index: 10;
}

.detail-body {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 0;
  min-height: 100vh;
}

/* Left: Task info */
.detail-left {
  padding: 60px 56px 80px;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.detail-sector-badge {
  display: inline-flex;
  align-self: flex-start;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--accent2);
  background: rgba(124,110,247,0.12);
  border: 1px solid rgba(124,110,247,0.25);
  border-radius: 50px;
  padding: 4px 14px;
}

.detail-title {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.5px;
}

.detail-meta { display: flex; flex-wrap: wrap; gap: 10px; }

.detail-skills { display: flex; flex-wrap: wrap; gap: 8px; }

.detail-desc {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.75;
  max-width: 620px;
}

.detail-budget {
  margin-top: auto;
  padding-top: 28px;
  border-top: 1px solid var(--border);
}
.detail-budget-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}
.detail-budget-amount {
  font-size: 2.4rem;
  font-weight: 800;
  color: var(--success);
  line-height: 1;
}
.detail-budget-sub { font-size: 0.82rem; color: var(--muted); margin-top: 4px; }

/* Right: Bidding */
.detail-right {
  padding: 60px 36px 80px;
  display: flex;
  flex-direction: column;
  gap: 28px;
  background: var(--surface);
  overflow-y: auto;
  max-height: 100vh;
  position: sticky;
  top: 0;
}

/* Current bid block */
.bid-current-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
}
.bid-current-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}
.bid-current-amount { font-size: 2rem; font-weight: 800; color: var(--success); line-height: 1; }
.bid-current-leader { font-size: 0.8rem; color: var(--muted); margin-top: 4px; }
.bid-count {
  font-size: 0.82rem;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 4px 12px;
  white-space: nowrap;
}

/* Bid history */
.bid-history-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.btn-show-all {
  background: none;
  border: none;
  color: var(--accent2);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  transition: color 0.15s;
}
.btn-show-all:hover { color: #fff; }

.bid-history-title {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.bid-list { display: flex; flex-direction: column; gap: 8px; }
.bid-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
}
.bid-item--leading {
  border-color: rgba(74,222,128,0.3);
  background: rgba(74,222,128,0.05);
}
.bid-item-left { display: flex; align-items: center; gap: 8px; }
.bid-badge {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--success);
  background: rgba(74,222,128,0.12);
  border: 1px solid rgba(74,222,128,0.3);
  border-radius: 50px;
  padding: 2px 8px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}
.bid-item-name { font-size: 0.88rem; font-weight: 600; }
.bid-item-amount { font-size: 0.95rem; font-weight: 700; }

/* Bid form */
.bid-form-wrap h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 6px; }
.bid-form-hint { font-size: 0.82rem; color: var(--muted); margin-bottom: 18px; }
.bid-error { color: #f87171; font-size: 0.82rem; margin-top: 10px; min-height: 18px; }

/* ── Shared Close Button ── */
.btn-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--muted);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
}
.btn-close:hover { background: var(--border); color: var(--text); }

.form-header { margin-bottom: 32px; }
.form-header h2 { font-size: 1.7rem; font-weight: 800; letter-spacing: -0.5px; }
.form-header p { color: var(--muted); margin-top: 6px; font-size: 0.95rem; }

/* ── Form Elements ── */
.form-group { display: flex; flex-direction: column; gap: 8px; margin-bottom: 22px; }

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 22px;
}

label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

input[type="text"],
input[type="number"],
input[type="date"],
input[type="email"],
input[type="password"],
input[type="tel"],
select,
textarea {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.95rem;
  padding: 11px 14px;
  width: 100%;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  font-family: inherit;
}
input::placeholder, textarea::placeholder { color: #555565; }
input:focus, select:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(124,110,247,0.15);
}

select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238888a0' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}
select option { background: var(--surface2); }
textarea { resize: vertical; min-height: 90px; }

/* Skills input */
.skills-input-wrap {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.skills-input-wrap:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(124,110,247,0.15);
}
.skills-input-wrap input { background: transparent; border: none; padding: 0; box-shadow: none; }
.skills-input-wrap input:focus { box-shadow: none; border: none; }

.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent2);
  background: rgba(124,110,247,0.12);
  border: 1px solid rgba(124,110,247,0.25);
  border-radius: 50px;
  padding: 3px 10px;
}
.tag-remove {
  background: none;
  border: none;
  color: var(--accent2);
  cursor: pointer;
  font-size: 0.85rem;
  line-height: 1;
  padding: 0 2px;
  opacity: 0.6;
  transition: opacity 0.15s;
}
.tag-remove:hover { opacity: 1; }
.hint { font-size: 0.76rem; color: #555565; }

/* Pay input */
.pay-input-wrap {
  display: flex;
  align-items: center;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.pay-input-wrap:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(124,110,247,0.15);
}
.currency {
  padding: 11px 14px;
  font-size: 1rem;
  font-weight: 700;
  color: var(--success);
  border-right: 1px solid var(--border);
  background: rgba(74,222,128,0.05);
  user-select: none;
}
.pay-input-wrap input { border: none; border-radius: 0; box-shadow: none; background: transparent; flex: 1; }
.pay-input-wrap input:focus { box-shadow: none; }

/* Submit button */
.btn-submit {
  width: 100%;
  padding: 14px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 8px;
  transition: background 0.2s, transform 0.15s;
}
.btn-submit:hover { background: var(--accent2); transform: translateY(-1px); }
.btn-submit:active { transform: translateY(0); }

/* ── Edit Mode ── */
.btn-edit-listing {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--muted);
  border-radius: 50px;
  padding: 3px 12px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.btn-edit-listing:hover { border-color: var(--accent); color: var(--accent2); }

.edit-mode-header { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.edit-mode-badge {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--accent2);
  background: rgba(124,110,247,0.12);
  border: 1px solid rgba(124,110,247,0.25);
  border-radius: 50px;
  padding: 3px 12px;
}

.edit-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: flex-end;
  margin-top: 8px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

/* ── Edit Warning Dialog ── */
.dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 600;
  background: rgba(0,0,0,0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  padding: 20px;
}
.dialog-backdrop.active { opacity: 1; pointer-events: all; }

.dialog {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 32px;
  max-width: 420px;
  width: 100%;
  text-align: center;
  transform: translateY(12px);
  transition: transform 0.2s;
}
.dialog-backdrop.active .dialog { transform: translateY(0); }

.dialog-icon { font-size: 2.2rem; margin-bottom: 14px; }
.dialog h3 { font-size: 1.2rem; font-weight: 800; margin-bottom: 10px; }
.dialog p { font-size: 0.88rem; color: var(--muted); line-height: 1.6; margin-bottom: 28px; }

.dialog-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

.btn-danger {
  background: #ef4444;
  color: #fff;
  border: none;
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-danger:hover { background: #dc2626; }

/* ── Responsive ── */
@media (max-width: 860px) {
  .detail-body { grid-template-columns: 1fr; }
  .detail-right { position: static; max-height: none; border-top: 1px solid var(--border); }
  .detail-left { padding: 48px 28px 40px; border-right: none; }
  .detail-right { padding: 36px 28px 80px; }
}
@media (max-width: 520px) {
  .form-row { grid-template-columns: 1fr; }
  .form-container { padding: 36px 24px; }
  header { padding: 16px 20px; }
  .listings-grid { padding: 0 16px; }
}
