/* ==========================================================================
   Slabfinder — Concrete Company Directory
   Design language: literal neumorphism. The palette IS raw poured concrete —
   panels are either "poured up" (raised, soft dual shadow) or "cut into"
   (pressed, inset shadow) the same slab. Nothing here is a color the
   material itself couldn't be, aside from the safety-orange rebar accent.
   ========================================================================== */

:root {
  /* --- palette: 5 named values, all derived from concrete + rebar --- */
  --concrete:      #e4e3e0;   /* base slab / page background            */
  --slab:          #e7e6e3;   /* raised element surface (barely lighter) */
  --shadow-dark:   #b8b6b1;   /* cast shadow (the "low" side of light)   */
  --shadow-light:  #ffffff;   /* highlight (the "high" side of light)    */
  --charcoal:      #2e2c29;   /* ink / primary text                      */
  --charcoal-soft: #6b6862;   /* secondary text                          */
  --rebar:         #d65a2e;   /* safety-orange accent                    */
  --rebar-dark:    #b7481f;
  --rebar-tint:    #f0c9b8;

  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --radius-pill: 999px;

  --shadow-raised-sm: 5px 5px 10px var(--shadow-dark), -5px -5px 10px var(--shadow-light);
  --shadow-raised-lg: 9px 9px 18px var(--shadow-dark), -9px -9px 18px var(--shadow-light);
  --shadow-pressed:   inset 4px 4px 8px var(--shadow-dark), inset -4px -4px 8px var(--shadow-light);
  --shadow-pressed-sm: inset 3px 3px 6px var(--shadow-dark), inset -3px -3px 6px var(--shadow-light);

  --font-display: "Archivo Black", "Archivo", sans-serif;
  --font-heading: "Archivo", sans-serif;
  --font-body: "Inter", sans-serif;
  --font-mono: "IBM Plex Mono", monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--concrete);
  color: var(--charcoal);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

/* subtle aggregate texture across the whole page — flecks in the concrete */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
  background-image:
    radial-gradient(circle at 12% 22%, rgba(46,44,41,0.05) 0 1.4px, transparent 1.6px),
    radial-gradient(circle at 78% 8%,  rgba(46,44,41,0.04) 0 1.1px, transparent 1.3px),
    radial-gradient(circle at 45% 60%, rgba(46,44,41,0.05) 0 1.6px, transparent 1.8px),
    radial-gradient(circle at 88% 75%, rgba(46,44,41,0.04) 0 1.2px, transparent 1.4px),
    radial-gradient(circle at 25% 85%, rgba(46,44,41,0.05) 0 1.3px, transparent 1.5px),
    radial-gradient(circle at 60% 35%, rgba(46,44,41,0.04) 0 1.1px, transparent 1.3px);
  background-size: 340px 340px;
}

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 28px;
  position: relative;
  z-index: 1;
}

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 { font-family: var(--font-heading); font-weight: 800; margin: 0; letter-spacing: -0.01em; }

::selection { background: var(--rebar-tint); color: var(--charcoal); }

/* focus visibility — kept even though the theme is soft */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2.5px solid var(--rebar);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* ---------------------------------- header ---------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--concrete);
  border-bottom: 1px solid rgba(46,44,41,0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  padding-top: 18px;
  padding-bottom: 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
}

.brand-mark { display: grid; place-items: center; }

.brand-text {
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: -0.01em;
}

.header-nav { display: flex; gap: 26px; font-weight: 600; font-size: 0.95rem; }
.header-nav a { color: var(--charcoal-soft); transition: color 0.15s ease; }
.header-nav a:hover { color: var(--charcoal); }

/* ---------------------------------- buttons ----------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 14px 26px;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
  background: var(--slab);
  color: var(--charcoal);
  box-shadow: var(--shadow-raised-sm);
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { box-shadow: var(--shadow-pressed-sm); transform: translateY(0); }

.btn-accent {
  background: var(--rebar);
  color: #fff9f5;
  box-shadow: 5px 5px 10px var(--shadow-dark), -5px -5px 10px var(--shadow-light), inset 0 0 0 1px rgba(255,255,255,0.06);
}
.btn-accent:active { box-shadow: inset 3px 3px 7px var(--rebar-dark), inset -2px -2px 5px rgba(255,255,255,0.15); }

.btn-small { padding: 10px 20px; font-size: 0.85rem; }

.btn-ghost {
  background: transparent;
  box-shadow: none;
  color: var(--charcoal-soft);
}
.btn-ghost:hover { color: var(--charcoal); box-shadow: none; }
.btn-ghost:active { box-shadow: none; }

/* ---------------------------------- hero -------------------------------- */

.hero { padding: 64px 0 40px; }

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--rebar-dark);
  background: var(--slab);
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-pressed-sm);
  margin-bottom: 22px;
}
.hero-eyebrow .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--rebar); }

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  line-height: 1.05;
  max-width: 15ch;
}
.hero h1 .accent { color: var(--rebar); }

.hero-sub {
  margin-top: 18px;
  max-width: 46ch;
  font-size: 1.1rem;
  color: var(--charcoal-soft);
}

.hero-stats {
  display: flex;
  gap: 14px;
  margin-top: 34px;
  flex-wrap: wrap;
}

.stat-chip {
  background: var(--slab);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-raised-sm);
  padding: 14px 20px;
  min-width: 128px;
}
.stat-chip .num {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--charcoal);
  display: block;
}
.stat-chip .label {
  font-size: 0.78rem;
  color: var(--charcoal-soft);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ---------------------------------- search / filter panel ---------------- */

.finder-panel {
  background: var(--slab);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-raised-lg);
  padding: 26px 28px;
  margin: 8px 0 44px;
}

.search-row {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.field-group { flex: 1 1 220px; }
.field-group.grow { flex: 2 1 320px; }

.field-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--charcoal-soft);
  margin-bottom: 8px;
}

.pressed-input {
  width: 100%;
  border: none;
  background: var(--concrete);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-pressed);
  padding: 14px 18px;
  font-family: var(--font-body);
  font-size: 0.98rem;
  color: var(--charcoal);
}
.pressed-input::placeholder { color: #98958f; }

select.pressed-input { appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%236b6862'%3E%3Cpath d='M5.5 7.5l4.5 5 4.5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

.search-actions { display: flex; align-items: flex-end; }

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.chip {
  font-family: var(--font-heading);
  font-size: 0.86rem;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  background: var(--concrete);
  box-shadow: var(--shadow-raised-sm);
  cursor: pointer;
  border: none;
  color: var(--charcoal-soft);
  transition: box-shadow 0.12s ease, color 0.12s ease;
}
.chip:hover { color: var(--charcoal); }
.chip.active {
  color: var(--rebar-dark);
  box-shadow: var(--shadow-pressed-sm);
}

/* ---------------------------------- results meta -------------------------- */

.results-bar {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 10px;
}
.results-count { color: var(--charcoal-soft); font-size: 0.95rem; }
.results-count strong { color: var(--charcoal); }

/* ---------------------------------- company grid -------------------------- */

.company-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
  margin-bottom: 60px;
}

.company-card {
  background: var(--slab);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-raised-lg);
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.company-card:hover {
  transform: translateY(-3px);
}

.card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }

.card-initial {
  width: 46px; height: 46px;
  border-radius: var(--radius-sm);
  background: var(--concrete);
  box-shadow: var(--shadow-pressed-sm);
  display: grid; place-items: center;
  font-family: var(--font-display);
  color: var(--rebar-dark);
  font-size: 1.1rem;
  flex-shrink: 0;
}

.featured-tag {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--rebar-dark);
  background: var(--concrete);
  box-shadow: var(--shadow-pressed-sm);
  padding: 5px 10px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

.company-card h3 { font-size: 1.2rem; line-height: 1.25; }
.company-card .tagline { color: var(--charcoal-soft); font-size: 0.92rem; margin: 0; }

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--charcoal-soft);
}
.card-meta span { display: inline-flex; align-items: center; gap: 6px; }

.rating-row { display: flex; align-items: center; gap: 8px; font-size: 0.88rem; }
.rating-row .stars { color: var(--rebar); letter-spacing: 1px; font-size: 0.9rem; }
.rating-row .rating-num { font-family: var(--font-mono); font-weight: 500; }
.rating-row .rating-count { color: var(--charcoal-soft); }

.service-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.service-tag {
  font-size: 0.74rem;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: var(--radius-pill);
  background: var(--concrete);
  box-shadow: var(--shadow-pressed-sm);
  color: var(--charcoal-soft);
}

.card-footer { margin-top: auto; display: flex; gap: 10px; }
.card-footer .btn { flex: 1; }

.empty-state {
  text-align: center;
  padding: 70px 20px;
  background: var(--slab);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-pressed);
  color: var(--charcoal-soft);
}
.empty-state h3 { color: var(--charcoal); margin-bottom: 10px; }

/* ---------------------------------- how it works -------------------------- */

.how-section { padding: 20px 0 60px; }
.section-head { max-width: 60ch; margin-bottom: 36px; }
.section-head h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
.section-head p { color: var(--charcoal-soft); margin-top: 10px; }

.steps-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.step-card {
  background: var(--slab);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-raised-sm);
  padding: 28px;
}
.step-card .step-num {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--rebar-dark);
  background: var(--concrete);
  box-shadow: var(--shadow-pressed-sm);
  width: 34px; height: 34px;
  border-radius: 50%;
  display: grid; place-items: center;
  margin-bottom: 16px;
}
.step-card h4 { font-size: 1.05rem; margin-bottom: 8px; }
.step-card p { color: var(--charcoal-soft); font-size: 0.92rem; margin: 0; }

/* ---------------------------------- list-your-company CTA ------------------ */

.cta-band {
  background: var(--slab);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-raised-lg);
  padding: 44px;
  margin-bottom: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  flex-wrap: wrap;
}
.cta-band h2 { font-size: 1.7rem; max-width: 20ch; }
.cta-band p { color: var(--charcoal-soft); margin-top: 8px; max-width: 42ch; }

/* ---------------------------------- footer -------------------------------- */

.site-footer { border-top: 1px solid rgba(46,44,41,0.08); padding: 34px 0; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px; }
.footer-brand p { margin: 4px 0 0; color: var(--charcoal-soft); font-size: 0.88rem; }
.footer-meta { font-family: var(--font-mono); font-size: 0.8rem; color: var(--charcoal-soft); display: flex; align-items: center; gap: 10px; }

/* ---------------------------------- company detail page -------------------- */

.detail-header { padding: 44px 0 20px; }
.breadcrumb { font-size: 0.85rem; color: var(--charcoal-soft); margin-bottom: 22px; }
.breadcrumb a:hover { color: var(--rebar-dark); }

.detail-hero {
  background: var(--slab);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-raised-lg);
  padding: 36px;
  display: flex;
  gap: 24px;
  align-items: flex-start;
  flex-wrap: wrap;
}

.detail-initial {
  width: 74px; height: 74px;
  border-radius: var(--radius-md);
  background: var(--concrete);
  box-shadow: var(--shadow-pressed);
  display: grid; place-items: center;
  font-family: var(--font-display);
  font-size: 1.8rem;
  color: var(--rebar-dark);
  flex-shrink: 0;
}

.detail-title-block { flex: 1; min-width: 240px; }
.detail-title-block h1 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); }
.detail-title-block .tagline { color: var(--charcoal-soft); margin-top: 8px; font-size: 1.02rem; }

.detail-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 26px;
  padding: 34px 0 70px;
  align-items: start;
}

.panel {
  background: var(--slab);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-raised-sm);
  padding: 30px;
  margin-bottom: 24px;
}
.panel h3 { font-size: 1.1rem; margin-bottom: 14px; }
.panel p { color: var(--charcoal-soft); }

.contact-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.contact-list li { display: flex; flex-direction: column; gap: 3px; }
.contact-list .label { font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase; color: var(--charcoal-soft); letter-spacing: 0.05em; }
.contact-list .value { font-family: var(--font-mono); font-size: 0.95rem; }
.contact-list a.value:hover { color: var(--rebar-dark); }

.stat-line { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid rgba(46,44,41,0.08); font-size: 0.92rem; }
.stat-line:last-child { border-bottom: none; }
.stat-line .k { color: var(--charcoal-soft); }
.stat-line .v { font-family: var(--font-mono); font-weight: 500; }

/* ---------------------------------- responsive ---------------------------- */

@media (max-width: 860px) {
  .steps-row { grid-template-columns: 1fr; }
  .detail-grid { grid-template-columns: 1fr; }
  .header-nav { display: none; }
}

@media (max-width: 560px) {
  .wrap { padding: 0 18px; }
  .hero { padding: 44px 0 30px; }
  .finder-panel { padding: 20px; }
  .cta-band { padding: 30px; }
  .card-footer { flex-direction: column; }
}
