/* Yardjobsja — Responsive Marketplace Styles */

:root {
  --g: #167447;
  --g-dark: #105735;
  --g-light: #e7f5ec;
  --ink: #183126;
  --muted: #65756b;
  --line: #dce7df;
  --surface: #f5f8f5;
  --white: #ffffff;
  --gold: #f2b544;
  --danger: #b42318;
  --shadow: 0 12px 35px rgba(24, 49, 38, 0.08);
  --radius: 18px;
  --content-width: 1160px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--surface);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

[hidden] {
  display: none !important;
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

a {
  color: var(--g);
  text-decoration: none;
}

a:hover {
  color: var(--g-dark);
}

h1,
h2,
h3,
h4 {
  margin-top: 0;
  line-height: 1.2;
  letter-spacing: -0.025em;
}

h1 {
  font-size: clamp(2.25rem, 5vw, 4rem);
}

h2 {
  font-size: clamp(1.65rem, 3vw, 2.45rem);
}

h3 {
  font-size: 1.2rem;
}

p {
  color: var(--muted);
}

main {
  overflow: clip;
}

section {
  scroll-margin-top: 88px;
}

/* HEADER */

.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  min-height: 74px;
  padding: 12px max(24px, calc((100% - var(--content-width)) / 2));
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 3px 15px rgba(24, 49, 38, 0.035);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  color: var(--ink);
  font-size: 1.22rem;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.brand:hover {
  color: var(--g);
}

.mark {
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border-radius: 13px;
  color: var(--white);
  background: var(--g);
  font-size: 1.35rem;
  font-weight: 800;
  box-shadow: 0 5px 12px rgba(22, 116, 71, 0.2);
}

.topbar nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 20px;
}

.topbar nav a {
  color: #43564a;
  font-size: 0.92rem;
  font-weight: 650;
}

.topbar nav a:hover {
  color: var(--g);
}

.topbar nav button,
#open-login {
  min-height: 42px;
  padding: 9px 16px;
  color: var(--white);
  background: var(--g);
  border: 1px solid var(--g);
  border-radius: 10px;
  font-weight: 750;
}

.topbar nav button:hover,
#open-login:hover {
  color: white;
  background: var(--g-dark);
}

/* BUTTONS */

button,
.btn {
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    color 0.18s ease,
    transform 0.18s ease;
}

.btn,
button[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 12px 19px;
  color: var(--white);
  background: var(--g);
  border: 1px solid var(--g);
  border-radius: 11px;
  font-weight: 750;
  line-height: 1.3;
  text-align: center;
}

.btn:hover,
button[type="submit"]:hover {
  color: white;
  background: var(--g-dark);
  border-color: var(--g-dark);
}

.btn:active,
button[type="submit"]:active {
  transform: scale(0.98);
}

.btn-light {
  color: var(--g);
  background: white;
  border-color: var(--line);
}

.btn-light:hover {
  color: var(--g-dark);
  background: var(--g-light);
  border-color: #b6d9c3;
}

.btn-small {
  min-height: 36px;
  padding: 8px 12px;
  border-radius: 9px;
  font-size: 0.88rem;
}

.actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 25px;
}

.actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* HERO SECTION */

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(290px, 0.85fr);
  align-items: center;
  gap: clamp(28px, 5vw, 66px);
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 70px 24px 76px;
}

.hero::before {
  position: absolute;
  top: 22px;
  left: -110px;
  z-index: -1;
  width: 290px;
  height: 290px;
  border-radius: 50%;
  background: #e6f4e9;
  content: "";
  filter: blur(2px);
}

.hero > div:first-child {
  min-width: 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 15px;
  color: var(--g);
  font-size: 0.77rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 700px;
  margin-bottom: 20px;
  color: var(--ink);
  font-weight: 850;
}

.hero h1 strong,
.hero h1 span {
  color: var(--g);
}

.hero .lead {
  max-width: 570px;
  margin-bottom: 0;
  font-size: clamp(1rem, 1.7vw, 1.18rem);
  line-height: 1.8;
}

.note {
  margin-top: 17px;
  font-size: 0.88rem;
}

.hero-card {
  position: relative;
  padding: clamp(22px, 3vw, 34px);
  background: white;
  border: 1px solid var(--line);
  border-radius: 23px;
  box-shadow: var(--shadow);
}

.hero-card::before {
  position: absolute;
  top: -11px;
  right: 24px;
  z-index: -1;
  width: 62px;
  height: 62px;
  border-radius: 18px;
  background: var(--g-light);
  content: "";
  transform: rotate(12deg);
}

.hero-card h2,
.hero-card h3 {
  margin-bottom: 12px;
}

.hero-card p {
  font-size: 0.95rem;
}

.hero-card ul {
  margin: 18px 0 0;
  padding-left: 21px;
}

.hero-card li {
  margin: 9px 0;
  color: #43564a;
}

.service-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 26px;
}

.service-row span {
  display: inline-flex;
  align-items: center;
  padding: 7px 11px;
  color: #365344;
  background: white;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 650;
}

/* GENERAL SECTIONS */

.section {
  padding: 72px 24px;
}

.section:nth-of-type(even) {
  background: white;
}

.section > * {
  max-width: var(--content-width);
  margin-right: auto;
  margin-left: auto;
}

.section-heading {
  max-width: 760px;
  margin-bottom: 30px;
}

.section-heading .eyebrow {
  margin-bottom: 11px;
}

.section-heading h2 {
  margin-bottom: 12px;
  color: var(--ink);
}

.section-heading > p:not(.eyebrow) {
  margin-top: 12px;
  color: var(--muted);
}

/* ACCOUNT FORMS */

.account-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 23px;
  align-items: start;
}

.account-grid form,
.account-grid > div,
.account-grid > article {
  min-width: 0;
  padding: 27px;
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 5px 22px rgba(24, 49, 38, 0.04);
}

.account-grid form h2,
.account-grid form h3 {
  margin-bottom: 17px;
}

form,
label {
  min-width: 0;
}

form h2,
form h3 {
  color: var(--ink);
}

label {
  display: block;
  margin: 4px 0 7px;
  color: #354b3e;
  font-size: 0.91rem;
  font-weight: 700;
}

input,
select,
textarea {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 46px;
  margin-bottom: 16px;
  padding: 11px 13px;
  color: var(--ink);
  background: white;
  border: 1px solid #ccd9cf;
  border-radius: 10px;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

input::placeholder,
textarea::placeholder {
  color: #8a978e;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--g);
  box-shadow: 0 0 0 3px rgba(22, 116, 71, 0.12);
}

textarea {
  min-height: 120px;
  resize: vertical;
}

input[type="checkbox"],
input[type="radio"] {
  display: inline-block;
  width: auto;
  min-height: auto;
  margin-right: 8px;
  accent-color: var(--g);
}

input[type="file"] {
  padding: 10px;
  background: var(--surface);
}

form button[type="submit"] {
  width: 100%;
  margin-top: 4px;
}

form button:not([type="submit"]) {
  min-height: 40px;
  padding: 9px 13px;
  color: var(--g);
  background: white;
  border: 1px solid var(--line);
  border-radius: 9px;
  font-weight: 700;
}

form button:not([type="submit"]):hover {
  background: var(--g-light);
}

form small,
.help-text {
  color: var(--muted);
  font-size: 0.84rem;
}

form p {
  font-size: 0.93rem;
}

#signed-in,
.signed-in {
  padding: 25px;
  background: var(--g-light);
  border: 1px solid #c9e5d1;
  border-radius: var(--radius);
}

#signed-in h2,
#signed-in h3,
.signed-in h2,
.signed-in h3 {
  color: var(--g-dark);
}

#signed-in button,
.signed-in button {
  margin: 5px 6px 5px 0;
}

/* POST A TASK */

.tasks {
  padding: 72px 24px;
  background: #f0f6f1;
}

.tasks > * {
  max-width: var(--content-width);
  margin-right: auto;
  margin-left: auto;
}

.wide-form {
  padding: clamp(21px, 4vw, 35px);
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.wide-form h2,
.wide-form h3 {
  margin-bottom: 10px;
}

.wide-form button[type="submit"] {
  width: auto;
  min-width: 180px;
}

.wide-form .form-row,
.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.form-row > * {
  min-width: 0;
}

/* FIND JOBS */

#jobs {
  padding: 72px 24px;
  background: white;
}

#jobs > * {
  max-width: var(--content-width);
  margin-right: auto;
  margin-left: auto;
}

.job-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 13px;
  margin-bottom: 23px;
}

.job-toolbar input,
.job-toolbar select {
  flex: 1 1 170px;
  width: auto;
  margin-bottom: 0;
}

.view-switch {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 5px;
  padding: 5px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.view-button {
  min-height: 39px;
  padding: 8px 13px;
  color: var(--muted);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 700;
}

.view-button:hover,
.view-button.active,
.view-button[aria-pressed="true"] {
  color: var(--g-dark);
  background: white;
  border-color: var(--line);
  box-shadow: 0 2px 6px rgba(24, 49, 38, 0.06);
}

.map-placeholder {
  display: grid;
  min-height: 250px;
  place-items: center;
  padding: 28px;
  color: var(--muted);
  background:
    linear-gradient(30deg, transparent 48%, #dce9de 49%, #dce9de 51%, transparent 52%),
    linear-gradient(120deg, transparent 48%, #dce9de 49%, #dce9de 51%, transparent 52%),
    #edf4ee;
  background-size: 75px 75px, 95px 95px, auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-align: center;
}

.map-placeholder > * {
  max-width: 520px;
}

.job-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 19px;
  margin-top: 22px;
}

.job-grid > *,
#hybrid-jobs > *,
#list-jobs > * {
  min-width: 0;
}

.job-card,
.job-item,
.task-card {
  min-width: 0;
  padding: 21px;
  overflow-wrap: anywhere;
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 5px 18px rgba(24, 49, 38, 0.045);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.job-card:hover,
.job-item:hover,
.task-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.job-card h2,
.job-card h3,
.job-item h2,
.job-item h3,
.task-card h2,
.task-card h3 {
  margin-bottom: 10px;
  color: var(--ink);
}

.job-card p,
.job-item p,
.task-card p {
  margin-bottom: 10px;
}

.job-card button,
.job-item button,
.task-card button {
  margin: 6px 6px 0 0;
}

#jobs-message {
  margin: 20px 0;
  padding: 15px 17px;
  background: var(--surface);
  border-radius: 10px;
}

#list-jobs {
  display: grid;
  gap: 14px;
}

#list-jobs > * {
  width: 100%;
}

#refresh-jobs {
  margin: 12px 0 20px;
}

/* INFORMATION CARDS */

.info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 19px;
}

.info-grid > * {
  min-width: 0;
  padding: 24px;
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.info-grid h3 {
  margin-bottom: 10px;
  color: var(--ink);
}

.info-grid p {
  margin-bottom: 0;
}

/* DASHBOARD AND STATUS ELEMENTS */

.account-grid form a {
  font-weight: 700;
}

.account-grid form .error,
.error,
.form-error {
  color: var(--danger);
}

.success,
.form-success {
  color: var(--g-dark);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--ink);
  background: var(--surface);
  font-size: 0.9rem;
}

td {
  color: #43564a;
}

.status,
.badge,
.tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  color: var(--g-dark);
  background: var(--g-light);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
}

hr {
  height: 1px;
  margin: 24px 0;
  background: var(--line);
  border: 0;
}

/* FOOTER */

footer {
  padding: 34px 24px;
  color: #dce9df;
  background: #142d21;
  text-align: center;
}

footer p {
  margin: 0;
  color: #dce9df;
  font-size: 0.9rem;
}

footer a {
  color: white;
}

footer a:hover {
  color: #a8e0b8;
}

:focus-visible {
  outline: 3px solid #7cc99a;
  outline-offset: 3px;
}

/* ACCESSIBILITY */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* TABLETS */

@media (max-width: 900px) {
  .topbar {
    gap: 14px;
    padding-right: 20px;
    padding-left: 20px;
  }

  .topbar nav {
    gap: 12px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(250px, 0.85fr);
    gap: 25px;
    padding-top: 56px;
    padding-bottom: 60px;
  }

  .job-grid,
  .info-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .section,
  .tasks,
  #jobs {
    padding-top: 56px;
    padding-bottom: 56px;
  }
}

/* MOBILE */

@media (max-width: 640px) {
  html {
    scroll-padding-top: 12px;
  }

  .topbar {
    position: relative;
    align-items: flex-start;
    flex-direction: column;
    gap: 11px;
    min-height: 0;
    padding: 12px 17px;
  }

  .brand {
    font-size: 1.1rem;
  }

  .mark {
    width: 37px;
    height: 37px;
    border-radius: 11px;
  }

  .topbar nav {
    justify-content: flex-start;
    width: 100%;
    gap: 8px 13px;
  }

  .topbar nav a {
    font-size: 0.84rem;
  }

  .topbar nav button,
  #open-login {
    min-height: 37px;
    padding: 7px 11px;
    font-size: 0.84rem;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 27px;
    padding: 40px 18px 44px;
  }

  .hero h1 {
    max-width: 100%;
    margin-bottom: 16px;
    font-size: clamp(2.05rem, 9.5vw, 3rem);
    line-height: 1.08;
    letter-spacing: -0.04em;
  }

  .hero .lead {
    font-size: 1rem;
    line-height: 1.7;
  }

  .hero-card {
    padding: 21px;
    border-radius: 18px;
  }

  .actions {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
    margin-top: 21px;
  }

  .actions .btn,
  .actions a {
    width: 100%;
  }

  .service-row {
    gap: 7px;
    margin-top: 19px;
  }

  .service-row span {
    font-size: 0.77rem;
  }

  .section,
  .tasks,
  #jobs {
    padding: 43px 17px;
  }

  .section-heading {
    margin-bottom: 22px;
  }

  .account-grid,
  .job-grid,
  .info-grid,
  .wide-form .form-row,
  .form-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .account-grid {
    gap: 16px;
  }

  .account-grid form,
  .account-grid > div,
  .account-grid > article {
    padding: 20px;
  }

  .wide-form {
    padding: 19px;
  }

  .wide-form button[type="submit"] {
    width: 100%;
  }

  .job-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .job-toolbar input,
  .job-toolbar select {
    flex: auto;
    width: 100%;
  }

  .view-switch {
    display: flex;
    width: 100%;
  }

  .view-button {
    flex: 1;
    padding: 8px 6px;
    font-size: 0.8rem;
  }

  .map-placeholder {
    min-height: 185px;
    padding: 19px;
  }

  .job-card,
  .job-item,
  .task-card,
  .info-grid > * {
    padding: 19px;
  }

  #signed-in,
  .signed-in {
    padding: 19px;
  }

  footer {
    padding: 27px 17px;
  }

  table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}

/* SMALL PHONES */

@media (max-width: 380px) {
  .topbar nav {
    gap: 8px 10px;
  }

  .hero {
    padding-right: 15px;
    padding-left: 15px;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .section,
  .tasks,
  #jobs {
    padding-right: 14px;
    padding-left: 14px;
  }

  .account-grid form,
  .account-grid > div,
  .account-grid > article {
    padding: 16px;
  }

  .btn {
    padding: 11px 14px;
  }
}
/* Fix the individual service cards in the hero section */

.hero-card {
  padding: 28px;
}

.hero-card .service-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 10px 0;
  padding: 13px 15px;
  color: var(--ink);
  background: #f5f8f5;
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 0.94rem;
  font-weight: 600;
}

.hero-card .service-row:hover {
  background: #e7f5ec;
  border-color: #b6d9c3;
}

.actions .btn {
  text-decoration: none;
}

.actions .btn-light {
  color: var(--g);
  background: white;
  border: 1px solid var(--line);
}

.form-message {
  margin-top: 12px;
  font-size: 0.9rem;
}

.full-width {
  width: 100%;
}

.map-placeholder .map-symbol {
  font-size: 2rem;
}

.info-grid > article > span {
  display: inline-flex;
  margin-bottom: 14px;
  color: var(--g);
  font-size: 1.1rem;
  font-weight: 800;
}

@media (max-width: 640px) {
  .hero-card {
    padding: 20px;
  }

  .hero-card .service-row {
    padding: 12px;
    font-size: 0.9rem;
  }
}
/* Yardjobsja role dashboards */

[hidden] {
  display: none !important;
}

.role-dashboard {
  min-height: 65vh;
}

.dashboard-card,
.dashboard-notice {
  background: #ffffff;
  border: 1px solid #dce7df;
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 20px;
  overflow-wrap: anywhere;
}

.dashboard-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

.dashboard-workspace {
  margin-top: 28px;
}

.dashboard-notice {
  background: #f5f8f5;
}

.dashboard-ticket-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.payment-ticket label {
  display: block;
  margin-top: 16px;
}

.payment-ticket select,
.payment-ticket textarea {
  display: block;
  width: 100%;
  margin-top: 8px;
}

.dashboard-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid #dce7df;
}

@media (max-width: 700px) {
  .dashboard-ticket-list {
    grid-template-columns: 1fr;
  }

  .dashboard-card,
  .dashboard-notice {
    padding: 18px;
  }

  .dashboard-actions .btn,
  .dashboard-footer .btn {
    width: 100%;
  }
}
