@import url("https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700&family=DM+Sans:wght@300;400;500;600;700&display=swap");

:root {
  --font-display: "Playfair Display", Georgia, serif;
  --font-body: "DM Sans", "Segoe UI", sans-serif;
  --background: #f3f3f3;
  --foreground: #1f1f1f;
  --card: #ffffff;
  --muted: #666666;
  --primary-overlay: rgba(20, 20, 20, 0.56);
  --accent: #c4902f;
  --accent-foreground: #111111;
  --border: rgba(0, 0, 0, 0.1);
  --radius-sm: 4px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--foreground);
  background: var(--background);
  line-height: 1.55;
}

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

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

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0;
  height: 3px;
  z-index: 90;
  background: var(--accent);
}

/* Layout utilities used in index.html */
.min-h-screen { min-height: 100vh; }
.h-screen { height: 100vh; }
.h-full { height: 100%; }
.w-full { width: 100%; }
.w-16 { width: 4rem; }
.h-16 { height: 4rem; }
.w-28 { width: 7rem; }
.h-28 { height: 7rem; }
.h-80 { height: 20rem; }
.max-h-screen { max-height: 100vh; }
.max-w-2xl { max-width: 42rem; }
.max-w-xl { max-width: 36rem; }
.max-w-7xl { max-width: 80rem; }
.mx-auto { margin-left: auto; margin-right: auto; }

.fixed { position: fixed; }
.relative { position: relative; }
.absolute { position: absolute; }
.inset-0 { inset: 0; }
.top-0 { top: 0; }
.bottom-0 { bottom: 0; }
.left-0 { left: 0; }
.right-0 { right: 0; }
.z-10 { z-index: 10; }
.z-50 { z-index: 50; }
.z-\[100\] { z-index: 100; }

.flex { display: flex; }
.inline-block { display: inline-block; }
.block { display: block; }
.hidden { display: none; }
.grid { display: grid; }
.flex-col { flex-direction: column; }
.flex-col-reverse { flex-direction: column-reverse; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.text-center { text-align: center; }

.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }
.gap-12 { gap: 3rem; }

.p-1 { padding: 0.25rem; }
.p-4 { padding: 1rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.px-8 { padding-left: 2rem; padding-right: 2rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-5 { padding-top: 1.25rem; padding-bottom: 1.25rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-24 { padding-top: 6rem; padding-bottom: 6rem; }
.pt-16 { padding-top: 4rem; }

.mb-1 { margin-bottom: 0.25rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-16 { margin-bottom: 4rem; }
.mb-24 { margin-bottom: 6rem; }
.mt-16 { margin-top: 4rem; }
.mt-24 { margin-top: 6rem; }

.order-1 { order: 1; }
.order-2 { order: 2; }

.border { border: 1px solid var(--border); }
.border-b { border-bottom: 1px solid var(--border); }
.border-t { border-top: 1px solid var(--border); }
.border-border { border-color: var(--border); }
.border-background\/10 { border-color: rgba(255, 255, 255, 0.1); }

.rounded-sm { border-radius: var(--radius-sm); }
.rounded-full { border-radius: 9999px; }
.overflow-hidden { overflow: hidden; }
.object-cover { object-fit: cover; }
.aspect-\[4\/5\] { aspect-ratio: 4 / 5; }
.grayscale { filter: grayscale(100%); }

.bg-background { background: var(--background); }
.bg-background\/80 { background: rgba(243, 243, 243, 0.8); }
.bg-card { background: var(--card); }
.bg-foreground { background: #181818; }
.bg-primary\/60 { background: var(--primary-overlay); }
.bg-accent { background: var(--accent); }
.bg-accent\/20 { background: rgba(196, 144, 47, 0.2); }
.bg-gradient-to-t {
  background-image: linear-gradient(to top, var(--tw-from), var(--tw-via), var(--tw-to));
}
.from-primary\/80 { --tw-from: rgba(20, 20, 20, 0.8); }
.via-primary\/20 { --tw-via: rgba(20, 20, 20, 0.2); }
.to-transparent { --tw-to: transparent; }

.text-foreground { color: var(--foreground); }
.text-muted-foreground { color: var(--muted); }
.text-accent { color: var(--accent); }
.text-accent-foreground { color: var(--accent-foreground); }
.text-primary-foreground { color: #ffffff; }
.text-primary-foreground\/80 { color: rgba(255, 255, 255, 0.8); }
.text-primary-foreground\/70 { color: rgba(255, 255, 255, 0.72); }
.text-background { color: #f4f4f4; }
.text-background\/40 { color: rgba(244, 244, 244, 0.4); }
.text-background\/50 { color: rgba(244, 244, 244, 0.5); }
.text-background\/60 { color: rgba(244, 244, 244, 0.6); }
.text-background\/70 { color: rgba(244, 244, 244, 0.7); }

.text-xs { font-size: 0.75rem; }
.text-sm { font-size: 0.875rem; }
.text-lg { font-size: 1.125rem; }
.text-xl { font-size: 1.25rem; }
.text-2xl { font-size: 1.5rem; }
.text-3xl { font-size: 1.875rem; }
.text-4xl { font-size: 2.25rem; }

.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.font-display { font-family: var(--font-display); }
.uppercase { text-transform: uppercase; }
.tracking-tight { letter-spacing: -0.02em; }
.tracking-wide { letter-spacing: 0.04em; }
.tracking-widest { letter-spacing: 0.12em; }
.leading-relaxed { line-height: 1.75; }

/* Interactions */
.transition-colors { transition: color 0.25s ease, border-color 0.25s ease; }
.transition-opacity { transition: opacity 0.25s ease; }
.transition-transform { transition: transform 0.4s ease; }
.transition-all { transition: all 0.4s ease; }
.duration-500 { transition-duration: 0.5s; }
.cursor-pointer { cursor: pointer; }
.group:hover .group-hover\:scale-105 { transform: scale(1.05); }
.hover\:opacity-90:hover { opacity: 0.9; }
.hover\:text-foreground:hover { color: #111; }
.hover\:text-accent:hover { color: var(--accent); }
.hover\:border-accent:hover { border-color: var(--accent); }
.hover\:grayscale-0:hover { filter: grayscale(0%); }

/* Navbar */
nav.fixed {
  backdrop-filter: blur(8px);
}

/* Lead widget */
.lead-widget {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 120;
  display: flex;
  flex-direction: column-reverse;
  align-items: flex-end;
}

.lead-widget-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border: 0;
  border-radius: 999px;
  padding: 0.85rem 1.15rem;
  background: var(--accent);
  color: var(--accent-foreground);
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.2);
  animation: assistant-enter 0.9s cubic-bezier(0.2, 0.9, 0.2, 1) 0.35s both,
             assistant-pulse 1.6s ease-in-out 1.5s 3;
}

.lead-widget-icon {
  flex: 0 0 auto;
}

.lead-widget-toggle::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 999px;
  border: 2px solid rgba(196, 144, 47, 0.45);
  opacity: 0;
  animation: assistant-ring 1.6s ease-out 1.5s 3;
  pointer-events: none;
}

.lead-widget-panel {
  width: min(92vw, 370px);
  max-height: min(76vh, 640px);
  margin-bottom: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.22);
  overflow: auto;
  padding: 0.95rem;
}

.lead-widget-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.8rem;
  margin-bottom: 0.9rem;
}

.lead-widget-kicker {
  margin: 0;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.lead-widget-head h3 {
  margin: 0.3rem 0;
  font-size: 1.15rem;
  font-family: var(--font-display);
}

.lead-widget-copy {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}

.lead-widget-close {
  border: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  background: #ececec;
  color: #333;
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}

@keyframes assistant-enter {
  0% {
    transform: translateY(18px) scale(0.92);
    opacity: 0;
  }
  65% {
    transform: translateY(-4px) scale(1.03);
    opacity: 1;
  }
  100% {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

@keyframes assistant-pulse {
  0%, 100% {
    transform: translateY(0) scale(1);
    box-shadow: 0 14px 28px rgba(0, 0, 0, 0.2);
  }
  50% {
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 18px 34px rgba(196, 144, 47, 0.3);
  }
}

@keyframes assistant-ring {
  0% {
    opacity: 0;
    transform: scale(0.9);
  }
  20% {
    opacity: 0.5;
  }
  100% {
    opacity: 0;
    transform: scale(1.28);
  }
}

.lead-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.lead-form.hidden {
  display: none;
}

.lead-step-meta {
  margin-bottom: 0.1rem;
}

.lead-step-label {
  margin: 0 0 0.4rem;
  font-size: 0.75rem;
  color: var(--muted);
}

.lead-step-progress {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: #ececec;
  overflow: hidden;
}

.lead-step-progress span {
  display: block;
  width: 33.333%;
  height: 100%;
  border-radius: 999px;
  background: var(--accent);
  transition: width 0.28s ease;
}

.lead-step {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.lead-step.hidden {
  display: none;
}

.lead-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-size: 0.86rem;
  color: var(--foreground);
}

.lead-field span {
  font-weight: 500;
}

.lead-field input,
.lead-field select,
.lead-field textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--foreground);
  padding: 0.7rem 0.8rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.lead-field textarea {
  resize: vertical;
  min-height: 90px;
}

.lead-field input:focus,
.lead-field select:focus,
.lead-field textarea:focus {
  border-color: rgba(196, 144, 47, 0.7);
  box-shadow: 0 0 0 3px rgba(196, 144, 47, 0.13);
}

.lead-submit {
  border: 0;
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  background: var(--accent);
  color: var(--accent-foreground);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.lead-nav {
  display: flex;
  justify-content: space-between;
  gap: 0.65rem;
  margin-top: 0.15rem;
}

.lead-back,
.lead-next {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.72rem 0.9rem;
  background: #f7f7f7;
  color: var(--foreground);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
  flex: 1;
}

.lead-next {
  border-color: rgba(196, 144, 47, 0.28);
  background: rgba(196, 144, 47, 0.2);
}

.lead-nav .lead-submit {
  flex: 1;
}

.lead-submit:hover {
  opacity: 0.9;
}

.lead-submit:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.lead-status {
  margin: 0;
  min-height: 1.4rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.lead-status.is-success {
  color: #176a1b;
}

.lead-status.is-error {
  color: #9e2727;
}

.lead-success-view {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 220px;
  text-align: center;
}

.lead-success-view.hidden {
  display: none;
}

.lead-success-text {
  margin: 0;
  font-size: 1rem;
  line-height: 1.5;
  color: #176a1b;
  font-weight: 600;
}

/* Reveal support for script.js */
.js-reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.js-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive prefixes */
@media (min-width: 640px) {
  .sm\:bottom-0 { bottom: 0; }
  .sm\:right-0 { right: 0; }
  .sm\:top-auto { top: auto; }
  .sm\:flex-col { flex-direction: column; }
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 768px) {
  .md\:hidden { display: none; }
  .md\:flex { display: flex; }
  .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .md\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .md\:order-1 { order: 1; }
  .md\:order-2 { order: 2; }
  .md\:px-12 { padding-left: 3rem; padding-right: 3rem; }
  .md\:text-4xl { font-size: 2.25rem; }
  .md\:text-6xl { font-size: 3.75rem; }
  .md\:text-xl { font-size: 1.25rem; }
  .md\:max-w-\[420px\] { max-width: 420px; }
}

@media (min-width: 1024px) {
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lg\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .lg\:px-20 { padding-left: 5rem; padding-right: 5rem; }
  .lg\:text-7xl { font-size: 4.5rem; }
}

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

  .js-reveal {
    opacity: 1;
    transform: none;
  }
}
