:root {
  --accent: #0867f2;
  --accent-dark: #0754c9;
  --accent-soft: #eaf2ff;
  --ink: #09152e;
  --muted: #63708a;
  --line: #dfe5ee;
  --surface: #fff;
  --canvas: #f8fafc;
  --success: #079447;
  --warm: #ff7919;
  --shadow: 0 10px 30px rgba(22, 36, 62, .06);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--canvas); font-family: Inter, system-ui, sans-serif; font-size: 14px; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
a { color: inherit; text-decoration: none; }
.shell { width: min(1390px, calc(100% - 48px)); margin-inline: auto; }

.topbar { height: 66px; display: flex; align-items: center; gap: 34px; padding: 0 max(28px, calc((100vw - 1390px)/2)); border-bottom: 1px solid var(--line); background: rgba(255,255,255,.96); position: sticky; top: 0; z-index: 20; backdrop-filter: blur(12px); }
.brand { display: flex; align-items: center; gap: 10px; min-width: max-content; font-size: 24px; font-weight: 800; letter-spacing: -.8px; }
.brand-mark { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 9px; background: var(--accent-soft); color: var(--accent); font-size: 22px; }
.brand em { color: var(--accent); font-style: normal; }
nav { display: flex; align-self: stretch; gap: 38px; margin-left: auto; }
nav a { display: grid; place-items: center; position: relative; font-weight: 600; }
nav a.active { color: var(--accent); }
nav a.active::after { content: ""; height: 2px; border-radius: 2px; background: var(--accent); position: absolute; inset: auto 0 0; }
.header-actions { display: flex; align-items: center; gap: 14px; }
.login-button, .icon-button { height: 40px; padding: 0 20px; border: 1px solid var(--line); background: white; border-radius: 8px; font-weight: 600; color: var(--ink); }
.icon-button { width: 40px; padding: 0; font-size: 20px; border: 0; background: transparent; }
.menu-button { display: none; margin-left: auto; border: 0; background: none; font-size: 25px; }

main { padding: 22px 0 10px; }
.hero { display: grid; grid-template-columns: minmax(0, 1fr) 365px; gap: 24px; }
.hero-main, .steps, .market { border: 1px solid var(--line); background: var(--surface); border-radius: 12px; box-shadow: var(--shadow); }
.hero-main { padding: 25px 26px 21px; }
.hero-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; margin-bottom: 19px; }
h1 { margin: 0; font-size: clamp(24px, 2.2vw, 31px); line-height: 1.15; letter-spacing: -.9px; }
h1 em { font-style: normal; }
.hero-heading p { color: var(--muted); margin: 8px 0 0; font-size: 15px; }
.benefit-row { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.benefit { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; color: #45516a; font-size: 12px; }
.benefit i { font-style: normal; color: var(--accent); font-size: 17px; }
.publish-form { display: grid; grid-template-columns: 1.65fr 1fr 1fr; gap: 15px 18px; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field label { font-weight: 700; font-size: 12px; }
.required { color: #ed2f3b; }
.field input, .field select, .field textarea { width: 100%; border: 1px solid #cfd7e4; border-radius: 7px; color: var(--ink); background: #fff; outline: 0; padding: 0 13px; transition: .18s; }
.field input, .field select { height: 43px; }
.field textarea { min-height: 138px; resize: vertical; padding-top: 12px; line-height: 1.5; }
.field-hint { color: var(--muted); font-size: 11px; line-height: 1.4; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.field-large { grid-row: span 2; }
.publish-error { margin-top: 10px; font-weight: 600; }
.form-footer { display: flex; align-items: center; gap: 30px; margin-top: 18px; }
.primary-button { height: 46px; padding: 0 24px; border: 0; border-radius: 7px; color: #fff; background: var(--accent); box-shadow: 0 6px 16px color-mix(in srgb, var(--accent) 25%, transparent); display: inline-flex; align-items: center; gap: 10px; }
.primary-button:hover { background: var(--accent-dark); transform: translateY(-1px); }

.steps { padding: 27px 22px; display: flex; flex-direction: column; justify-content: center; }
.step { display: grid; grid-template-columns: 34px 44px 1fr; gap: 12px; align-items: start; position: relative; padding: 11px 0; }
.step:not(:last-child)::after { content: ""; position: absolute; left: 16px; top: 47px; width: 1px; height: 36px; background: var(--line); }
.step-number { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: var(--accent); background: var(--accent-soft); font-weight: 800; }
.step-icon { width: 42px; height: 42px; border-radius: 9px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-size: 21px; }
.step h3 { font-size: 13px; margin: 2px 0 7px; }
.step p { color: var(--muted); font-size: 12px; line-height: 1.65; margin: 0; }

.market { margin-top: 16px; overflow: hidden; }
.filters { display: grid; grid-template-columns: repeat(3, minmax(140px, 1fr)) 1.25fr; gap: 18px; padding: 13px 20px; border-bottom: 1px solid var(--line); }
.filter label { display: block; font-size: 10px; font-weight: 700; margin-bottom: 6px; }
.filter select, .search-wrap input { height: 39px; width: 100%; border: 1px solid #d4dce8; border-radius: 7px; padding: 0 12px; background: white; color: #253047; outline: 0; }
.search-wrap { align-self: end; position: relative; }
.search-wrap input { padding-right: 40px; }
.search-wrap span { position: absolute; right: 13px; top: 10px; font-size: 18px; }
.market-title { display: none; padding: 14px 18px; align-items: center; gap: 9px; }
.market-title h2 { font-size: 16px; margin: 0 10px 0 0; }
.market-title span:last-child { color: var(--muted); font-size: 11px; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #12ad54; }
.table-head, .listing-row { display: grid; align-items: center; grid-template-columns: 1.15fr 3.6fr .9fr .9fr .8fr 1fr 1fr; }
.table-head { min-height: 39px; padding: 0 19px; border-bottom: 1px solid var(--line); font-size: 10px; font-weight: 700; }
.listing-row { min-height: 62px; padding: 8px 19px; border-bottom: 1px solid #e7ebf1; font-size: 11px; transition: background .15s; }
.listing-row[data-details-id] { cursor: pointer; }
.listing-row:hover, .listing-row:focus-visible { background: #fbfcff; outline: none; }
.cell { min-width: 0; padding-right: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.category { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.category-icon { width: 22px; font-size: 18px; text-align: center; }
.job { font-weight: 700; }
.description, .place, .time, .contact { color: #4e5b73; }
.listing-row .description { white-space: normal; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.budget { color: var(--success); font-weight: 700; }
.budget.pending { color: var(--accent); }
.action-button { min-height: 32px; border: 1px solid var(--accent); border-radius: 6px; color: var(--accent); background: white; font-size: 10px; font-weight: 600; padding: 5px 10px; }
.action-button.reserve { border-color: var(--warm); color: var(--warm); }
.more-button { width: 100%; height: 43px; color: var(--accent); border: 0; background: #fff; font-weight: 600; }
.empty-state { padding: 42px 20px; text-align: center; color: var(--muted); border-bottom: 1px solid var(--line); }
.mobile-cards { display: none; }

.footer { width: min(1390px, calc(100% - 48px)); margin: 7px auto 0; min-height: 58px; display: flex; align-items: center; justify-content: space-between; color: #59657b; font-size: 11px; }
.footer div { display: flex; gap: 34px; }
.toast { position: fixed; right: 24px; bottom: 24px; background: #101a2e; color: white; border-radius: 9px; padding: 14px 18px; box-shadow: 0 14px 45px rgba(0,0,0,.2); transform: translateY(90px); opacity: 0; transition: .25s; z-index: 50; }
.toast.show { transform: translateY(0); opacity: 1; }
.primary-button:disabled { cursor: wait; opacity: .7; transform: none; }
.modal-overlay { position: fixed; inset: 0; z-index: 100; background: rgba(8,18,38,.55); display: grid; place-items: center; padding: 20px; backdrop-filter: blur(4px); }
.modal-overlay[hidden] { display: none; }
.modal { width: min(620px, 100%); max-height: min(780px, calc(100vh - 40px)); overflow: auto; position: relative; border-radius: 14px; background: white; box-shadow: 0 24px 80px rgba(0,0,0,.25); padding: 30px; }
.modal.wide { width: min(880px, 100%); }
.modal-close { position: absolute; right: 15px; top: 12px; width: 36px; height: 36px; border: 0; background: #f1f4f8; border-radius: 50%; font-size: 24px; color: var(--muted); }
.modal h2 { font-size: 24px; margin: 0 38px 8px 0; }
.modal-lead { color: var(--muted); margin: 0 0 22px; line-height: 1.6; }
.auth-tabs { display: flex; padding: 4px; background: #f0f3f8; border-radius: 9px; margin-bottom: 20px; }
.auth-tabs button { flex: 1; height: 38px; border: 0; border-radius: 7px; background: transparent; font-weight: 700; color: var(--muted); }
.auth-tabs button.active { color: var(--accent); background: white; box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.social-auth { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.social-auth-button { height: 46px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); font-weight: 700; display: flex; align-items: center; justify-content: center; gap: 10px; }
.social-auth-button:hover { border-color: #aeb9ca; background: #f8fafc; }
.social-auth-button span { width: 23px; height: 23px; border-radius: 50%; display: grid; place-items: center; font-size: 17px; font-weight: 800; }
.social-auth-button.google span { color: #4285f4; font-family: Arial, sans-serif; }
.social-auth-button.facebook { color: #1877f2; }
.social-auth-button.facebook span { color: #fff; background: #1877f2; font-family: Arial, sans-serif; }
.auth-divider { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 12px; }
.auth-divider::before, .auth-divider::after { content: ""; height: 1px; background: var(--line); flex: 1; }
.modal-form { display: grid; gap: 14px; }
.modal-form .field textarea { min-height: 95px; }
.role-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.role-card { border: 1px solid var(--line); border-radius: 9px; padding: 13px; cursor: pointer; }
.role-card:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.role-card input { margin-right: 6px; }
.form-error { min-height: 18px; color: #c52c38; font-size: 12px; }
.security-notice { margin-bottom: 14px; padding: 12px 14px; border: 1px solid #f1cf58; border-radius: 9px; background: #fff9df; color: #6e5700; }
.reservation-summary { display: flex; flex-direction: column; gap: 6px; margin: 0 0 16px; padding: 14px; border: 1px solid var(--line); border-radius: 9px; }
.reservation-summary span { color: var(--muted); font-size: 12px; }
.confirm-check { display: flex; align-items: flex-start; gap: 9px; margin: 0 0 16px; line-height: 1.5; cursor: pointer; }
.confirm-check input { margin-top: 3px; }
.details-category, .card-category { display: inline-block; color: var(--accent); background: var(--accent-soft); border-radius: 99px; padding: 5px 9px; font-size: 11px; font-weight: 700; margin-bottom: 10px; }
.details-description { white-space: pre-wrap; color: #39455d; line-height: 1.75; font-size: 14px; margin: 20px 0; }
.details-meta { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 0 0 22px; }
.details-meta span { padding: 12px; border: 1px solid var(--line); border-radius: 9px; color: var(--muted); font-size: 12px; }
.details-meta b { display: block; color: var(--ink); margin-bottom: 5px; }
.dashboard-head { display: flex; justify-content: space-between; align-items: start; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.dashboard-head p { color: var(--muted); margin: 5px 0 0; }
.dashboard-tabs { display: flex; gap: 6px; overflow-x: auto; margin: 18px 0; }
.dashboard-tabs button { border: 1px solid var(--line); background: white; border-radius: 7px; padding: 9px 13px; white-space: nowrap; }
.dashboard-tabs button.active { color: white; border-color: var(--accent); background: var(--accent); }
.dashboard-list { display: grid; gap: 10px; }
.dashboard-item { padding: 14px; border: 1px solid var(--line); border-radius: 9px; display: flex; justify-content: space-between; gap: 14px; align-items: center; }
.dashboard-item h4 { margin: 0 0 5px; }
.dashboard-item p { margin: 0; color: var(--muted); font-size: 12px; }
.status-pill { display: inline-block; padding: 4px 8px; border-radius: 99px; color: var(--accent); background: var(--accent-soft); font-size: 10px; font-weight: 700; }
.text-button { border: 0; background: none; color: var(--accent); padding: 5px; }
.legal-copy { color: #39455d; line-height: 1.75; }
.legal-copy h3 { color: var(--ink); margin-top: 22px; }

body.transport { --accent: #159c45; --accent-dark: #0d8136; --accent-soft: #e9f8ee; --canvas: #fafcfb; }
body.transport h1 em { color: var(--accent); }
body.transport .hero { grid-template-columns: 1fr; }
body.transport .steps { display: none; }
body.transport .hero-main { padding: 20px 22px; }
body.transport .publish-form { grid-template-columns: 1.5fr 1.15fr 1.15fr 1.05fr .72fr .72fr .62fr; align-items: end; }
body.transport .field-large { grid-row: auto; }
body.transport .field textarea { min-height: 43px; height: 43px; resize: none; padding-top: 12px; }
body.transport .form-submit { height: 43px; padding: 0 12px; justify-content: center; }
body.transport .form-footer { display: none; }
body.transport .hero-heading { margin-bottom: 17px; }
body.transport .market-title { display: flex; }
body.transport .table-head, body.transport .listing-row { grid-template-columns: 3.1fr 2.3fr .85fr .8fr 1fr 1fr; }
body.transport .thumb { width: 70px; height: 40px; border-radius: 6px; display: grid; place-items: center; flex: 0 0 auto; font-size: 27px; background: linear-gradient(135deg, var(--accent-soft), #f3efe5); }
body.transport .job-cell { display: flex; align-items: center; gap: 11px; }
body.transport .job-stack { min-width: 0; }
body.transport .job-stack small { display: block; color: var(--muted); margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

body.yellow { --accent: #f6b900; --accent-dark: #dfa800; --accent-soft: #fff7db; --ink: #11182a; }
body.yellow .primary-button { color: #171200; }
body.yellow .budget.pending, body.yellow nav a.active { color: #126af3; }
body.yellow .action-button { border-color: #126af3; color: #126af3; }

@media (max-width: 1050px) {
  .hero { grid-template-columns: 1fr; }
  .steps { display: grid; grid-template-columns: repeat(3, 1fr); padding: 14px 20px; }
  .step:not(:last-child)::after { display: none; }
  .step { grid-template-columns: 30px 38px 1fr; }
  .step-icon { width: 36px; height: 36px; }
  .table-head, .listing-row { grid-template-columns: 1.15fr 3fr .9fr .85fr 1fr; }
  .table-head > :nth-child(5), .listing-row > :nth-child(5), .table-head > :nth-child(6), .listing-row > :nth-child(6) { display: none; }
  body.transport .table-head, body.transport .listing-row { grid-template-columns: 2.7fr 2fr .8fr .8fr 1fr; }
  body.transport .table-head > :nth-child(5), body.transport .listing-row > :nth-child(5) { display: block; }
  body.transport .table-head > :nth-child(6), body.transport .listing-row > :nth-child(6) { display: block; }
}

@media (max-width: 760px) {
  .shell, .footer { width: min(100% - 24px, 600px); }
  .topbar { height: 60px; padding: 0 16px; }
  .brand { font-size: 21px; }
  nav, .header-actions { display: none; }
  nav.open { display: flex; position: absolute; top: 60px; left: 0; right: 0; padding: 14px 18px; background: white; flex-direction: column; gap: 4px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
  nav.open a { min-height: 42px; justify-content: start; }
  nav.open a.active::after { display: none; }
  .menu-button { display: block; }
  main { padding-top: 12px; }
  .hero-main { padding: 19px 16px; }
  .hero-heading { display: block; }
  .hero-heading .benefit-row { margin-top: 13px; }
  .publish-form, body.transport .publish-form { grid-template-columns: 1fr; gap: 13px; }
  .field-large { grid-row: auto; }
  .field textarea { min-height: 95px; }
  body.transport .field textarea { height: 74px; }
  .form-footer { display: block; }
  .primary-button { width: 100%; justify-content: center; }
  .form-footer .benefit-row { justify-content: center; margin-top: 16px; }
  .steps { display: block; }
  body.transport .steps { display: none; }
  .filters { grid-template-columns: 1fr 1fr; gap: 12px; padding: 14px; }
  .search-wrap { grid-column: span 2; }
  .desktop-table { display: none; }
  .mobile-cards { display: block; }
  .listing-card { padding: 15px; border-bottom: 1px solid var(--line); }
  .card-top { display: flex; justify-content: space-between; gap: 12px; align-items: start; }
  .listing-card h3 { font-size: 14px; margin: 0 0 5px; }
  .listing-card p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
  .card-meta { display: flex; gap: 10px; flex-wrap: wrap; margin: 12px 0; font-size: 11px; color: #4e5b73; }
  .card-bottom { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
  .card-bottom .action-button { min-width: 115px; }
  .footer { flex-direction: column; align-items: flex-start; gap: 12px; padding: 20px 0; }
  .footer div { gap: 18px; flex-wrap: wrap; }
  .modal { padding: 24px 18px; }
  .details-meta { grid-template-columns: 1fr 1fr; }
  .role-cards { grid-template-columns: 1fr; }
  .dashboard-item { align-items: flex-start; flex-direction: column; }
}
