/* Volnyn Freelancer home — marketplace landing
   Display: Syne (expressive geometric). UI: Manrope (clean readable). */
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Syne:wght@500;600;700;800&display=swap');

.fv-home {
  --fv-green: #1dbf73;
  --fv-green-dark: #19a463;
  --fv-forest: #0a2e1c;
  --fv-carbon: #1a1c1e;
  --fv-slate: #3d3f43;
  --fv-graphite: #5c5e66;
  --fv-smoke: #757881;
  --fv-fog: #c5c6c9;
  --fv-mist: #dadbdd;
  --fv-cloud: #e8e9eb;
  --fv-bg: #fafafa;
  --fv-font: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --fv-font-display: "Syne", "Manrope", sans-serif;
  font-family: var(--fv-font);
  color: var(--fv-carbon);
  background: var(--fv-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.fv-home * { box-sizing: border-box; }

.fv-home__wrap {
  width: min(1160px, calc(100% - 48px));
  margin-inline: auto;
}

/* ── Hero ─────────────────────────────────────────── */
.fv-hero {
  position: relative;
  min-height: min(62vh, 480px);
  display: flex;
  align-items: center;
  overflow: hidden;
  background:
    linear-gradient(115deg, rgba(6, 28, 18, 0.88) 0%, rgba(10, 46, 28, 0.62) 48%, rgba(8, 40, 24, 0.40) 100%),
    url('https://images.unsplash.com/photo-1522071820081-009f0129c71c?auto=format&fit=crop&w=1800&q=80') center/cover no-repeat;
  color: #fff;
}

.fv-hero__inner {
  position: relative;
  z-index: 1;
  width: min(640px, 100%);
  padding: 68px 0 56px;
}

.fv-hero__title {
  margin: 0 0 26px;
  font-family: var(--fv-font-display);
  font-weight: 700;
  font-size: clamp(2.15rem, 4.6vw, 3.35rem);
  line-height: 1.08;
  letter-spacing: -0.04em;
  color: #fff;
  max-width: 14ch;
}

.fv-hero__search {
  display: flex;
  align-items: stretch;
  width: 100%;
  max-width: 560px;
  background: #fff;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
}

.fv-hero__search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 15px 18px;
  font-family: var(--fv-font);
  font-weight: 500;
  font-size: 15px;
  line-height: 1.3;
  color: var(--fv-carbon);
  background: #fff;
}

.fv-hero__search input::placeholder { color: var(--fv-smoke); font-weight: 400; }

.fv-hero__search button {
  flex: 0 0 52px;
  border: 0;
  background: var(--fv-green);
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background .15s ease;
}

.fv-hero__search button:hover { background: var(--fv-green-dark); }
.fv-hero__search button svg { width: 18px; height: 18px; }

.fv-hero__popular {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  font-family: var(--fv-font);
  font-weight: 500;
  font-size: 13px;
  line-height: 1.3;
  color: rgba(255, 255, 255, 0.9);
}

.fv-hero__popular span {
  opacity: .75;
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.fv-hero__popular a {
  display: inline-flex;
  align-items: center;
  padding: 5px 11px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 12.5px;
  transition: background .15s ease, border-color .15s ease;
}

.fv-hero__popular a:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: #fff;
  color: #fff;
  text-decoration: none;
}

/* ── Category strip ───────────────────────────────── */
.fv-cats {
  border-bottom: 1px solid var(--fv-cloud);
  background: #fff;
  padding: 22px 0 4px;
}

.fv-cats__row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 6px 10px;
  padding-bottom: 16px;
}

.fv-cats__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 8px 4px 12px;
  text-decoration: none;
  color: var(--fv-carbon);
  border-bottom: 2px solid transparent;
  transition: color .15s ease, border-color .15s ease;
  text-align: center;
}

.fv-cats__item:hover {
  color: var(--fv-green-dark);
  border-bottom-color: var(--fv-green);
  text-decoration: none;
}

.fv-cats__icon {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--fv-carbon);
}

.fv-cats__icon svg { width: 36px; height: 36px; stroke-width: 1.5; }
.fv-cats__item:hover .fv-cats__icon { color: var(--fv-green); }

.fv-cats__label {
  font-family: var(--fv-font);
  font-weight: 650;
  font-size: 12.5px;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

/* ── Category mega-menu ───────────────────────────────
   A category with grouped subcategories (Category::menuColumns()) opens a
   multi-column panel on hover, Fiverr-style — a named heading per group,
   its subcategories listed underneath. Pure CSS :hover/:focus-within, no
   JS: .fv-mega sits flush against its column (no gap) so the pointer never
   leaves the hoverable box while moving from the icon down into the panel;
   the small visual gap lives on .fv-mega__inner's margin instead. */
.fv-cats__col { position: relative; }
.fv-cats__col.has-menu > .fv-cats__item { cursor: pointer; }
.fv-mega {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 40;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .14s ease, visibility .14s ease;
}
.fv-cats__col.has-menu:hover .fv-mega,
.fv-cats__col.has-menu:focus-within .fv-mega {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
/* Right-anchor the last few columns' menus so they don't run off the
   viewport edge — a fixed-count nth-last-of-type is a simpler, sturdier
   fix here than JS viewport clamping for a strip this narrow. */
.fv-cats__col.has-menu:nth-last-of-type(-n+3) .fv-mega {
  left: auto;
  right: 0;
  transform: none;
}
.fv-mega__inner {
  display: grid;
  grid-auto-flow: column;
  margin-top: 8px;
  background: #fff;
  border: 1px solid var(--fv-cloud);
  border-radius: 10px;
  box-shadow: 0 20px 44px rgba(10, 20, 15, 0.16);
  padding: 22px 6px;
}
.fv-mega__inner--cols-1 { grid-template-columns: minmax(200px, 1fr); }
.fv-mega__inner--cols-2 { grid-template-columns: repeat(2, minmax(200px, 1fr)); }
.fv-mega__inner--cols-3 { grid-template-columns: repeat(3, minmax(200px, 1fr)); }
.fv-mega__inner--cols-4 { grid-template-columns: repeat(4, minmax(200px, 1fr)); }
.fv-mega__col { padding: 0 22px; border-left: 1px solid var(--fv-cloud); }
.fv-mega__col:first-child { border-left: 0; }
.fv-mega__heading {
  margin: 0 0 14px;
  font-family: var(--fv-font);
  font-weight: 700;
  font-size: 13px;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--fv-carbon);
  white-space: nowrap;
}
.fv-mega__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.fv-mega__list a {
  display: block;
  font-family: var(--fv-font);
  font-size: 13.5px;
  line-height: 1.3;
  color: var(--fv-graphite);
  text-decoration: none;
  white-space: nowrap;
  transition: color .12s ease;
}
.fv-mega__list a:hover { color: var(--fv-green-dark); text-decoration: underline; }

/* ── Sections ─────────────────────────────────────── */
.fv-section {
  padding: 48px 0;
  background: #fff;
}

.fv-section + .fv-section { padding-top: 8px; }

.fv-section__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.fv-section__title {
  margin: 0;
  font-family: var(--fv-font-display);
  font-weight: 700;
  font-size: clamp(1.35rem, 2.4vw, 1.85rem);
  line-height: 1.2;
  letter-spacing: -0.03em;
  color: var(--fv-carbon);
  max-width: 28ch;
}

.fv-section__link {
  font-family: var(--fv-font);
  font-weight: 700;
  font-size: 13.5px;
  line-height: 1;
  color: var(--fv-carbon);
  text-decoration: underline;
  text-underline-offset: 3px;
  flex-shrink: 0;
}

.fv-section__link:hover { color: var(--fv-green-dark); }

/* Popular services — forest stage + photo */
.fv-pop {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(188px, 1fr);
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.fv-pop::-webkit-scrollbar { height: 5px; }
.fv-pop::-webkit-scrollbar-thumb { background: var(--fv-fog); border-radius: 99px; }

.fv-pop__card {
  scroll-snap-align: start;
  position: relative;
  display: block;
  min-height: 250px;
  height: 250px;
  padding: 20px 18px 0;
  border-radius: 14px;
  background: var(--fv-forest);
  color: #fff;
  text-decoration: none;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: transform .18s ease, box-shadow .18s ease;
}

.fv-pop__card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.14);
  color: #fff;
  text-decoration: none;
}

.fv-pop__card h3 {
  margin: 0;
  font-family: var(--fv-font-display);
  font-weight: 700;
  font-size: 15.5px;
  line-height: 1.25;
  letter-spacing: -0.02em;
  position: relative;
  z-index: 2;
  max-width: 92%;
}

.fv-pop__media {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 62%;
  z-index: 1;
  pointer-events: none;
}

.fv-pop__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 28%, #000 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 28%, #000 100%);
}

.fv-pop__card .fv-pop__glyph { display: none; }

/* Gig cards */
.fv-gigs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px 16px;
}

.fv-gig {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  border-radius: 10px;
  overflow: hidden;
  transition: transform .15s ease;
}

.fv-gig:hover {
  transform: translateY(-2px);
  text-decoration: none;
  color: inherit;
}

.fv-gig__media {
  position: relative;
  aspect-ratio: 16 / 10;
  border-radius: 10px;
  overflow: hidden;
  background: #eef0f2;
  border: 1px solid var(--fv-cloud);
}

.fv-gig__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.fv-gig__body { padding: 10px 2px 0; }

.fv-gig__seller {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  font-family: var(--fv-font);
  font-weight: 700;
  font-size: 12px;
  line-height: 1.2;
  color: var(--fv-carbon);
}

.fv-gig__av {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #c5c9d0;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--fv-font-display);
  font-weight: 700;
  font-size: 10px;
  line-height: 1;
  overflow: hidden;
  flex-shrink: 0;
}

.fv-gig__av img { width: 100%; height: 100%; object-fit: cover; }

.fv-gig__title {
  margin: 0 0 8px;
  font-family: var(--fv-font);
  font-weight: 550;
  font-size: 13.5px;
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--fv-carbon);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.8em;
}

.fv-gig:hover .fv-gig__title { color: var(--fv-green-dark); }

.fv-gig__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-family: var(--fv-font);
  font-weight: 700;
  font-size: 13px;
  line-height: 1;
  color: var(--fv-carbon);
}

.fv-gig__price { letter-spacing: -0.015em; }
.fv-gig__price em {
  font-style: normal;
  font-weight: 500;
  color: var(--fv-smoke);
  font-size: 11.5px;
  margin-right: 4px;
}

/* Benefits */
.fv-benefits {
  background: #f3f4f5;
  border-radius: 0;
}

.fv-benefits .fv-home__wrap { padding-block: 52px; }

.fv-benefits__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.fv-benefits__item h3 {
  margin: 0 0 7px;
  font-family: var(--fv-font-display);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.fv-benefits__item p {
  margin: 0;
  font-family: var(--fv-font);
  font-weight: 450;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--fv-smoke);
}

.fv-benefits__item .ic {
  display: inline-flex;
  width: 26px;
  height: 26px;
  margin-bottom: 12px;
  color: var(--fv-green);
}

.fv-benefits__item .ic svg { width: 26px; height: 26px; }

/* Dark CTA */
.fv-cta {
  background: var(--fv-forest);
  color: #fff;
  padding: 56px 0;
}

.fv-cta__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
}

.fv-cta__inner h2 {
  margin: 0 0 8px;
  font-family: var(--fv-font-display);
  font-weight: 700;
  font-size: clamp(1.45rem, 2.8vw, 1.95rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: #fff;
}

.fv-cta__inner p {
  margin: 0;
  font-family: var(--fv-font);
  font-weight: 450;
  font-size: 14.5px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.75);
  max-width: 40ch;
}

.fv-cta__btn {
  display: inline-flex;
  align-items: center;
  padding: 13px 22px;
  border-radius: 8px;
  background: #fff;
  color: var(--fv-carbon);
  font-family: var(--fv-font);
  font-weight: 800;
  font-size: 14px;
  line-height: 1;
  letter-spacing: -0.01em;
  text-decoration: none;
  transition: background .15s ease, transform .12s ease;
}

.fv-cta__btn:hover {
  background: #f0f0f0;
  color: var(--fv-carbon);
  text-decoration: none;
  transform: translateY(-1px);
}

/* Empty state */
.fv-empty {
  padding: 32px;
  text-align: center;
  color: var(--fv-smoke);
  font-family: var(--fv-font);
  font-weight: 500;
  font-size: 14px;
  line-height: 1.4;
  border: 1px dashed var(--fv-cloud);
  border-radius: 12px;
  background: #fff;
}

@media (max-width: 1100px) {
  .fv-gigs { grid-template-columns: repeat(3, 1fr); }
  .fv-benefits__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .fv-home__wrap { width: min(100% - 32px, 1400px); }
  .fv-hero { min-height: 400px; }
  .fv-hero__inner { padding: 52px 0 44px; }
  .fv-hero__title { max-width: none; }
  .fv-gigs { grid-template-columns: repeat(2, 1fr); gap: 14px 12px; }
  .fv-section { padding: 36px 0; }
  .fv-pop__card { min-height: 230px; height: 230px; }
  .fv-section__title { max-width: none; }
}

@media (max-width: 520px) {
  .fv-gigs { grid-template-columns: 1fr 1fr; }
  .fv-benefits__grid { grid-template-columns: 1fr; gap: 18px; }
  .fv-hero__popular { display: none; }
  .fv-cats__row { grid-template-columns: repeat(3, 1fr); }
  .fv-hero__search { border-radius: 8px; }
}

@media (max-width: 768px) {
  /* No hover on touch — the mega-menu can't open anyway, and it would
     overflow a narrow screen; the label itself still links to the category. */
  .fv-mega { display: none; }
}
