/* ============================================
   The 24/7 Buyer — style.css
   Dark navy + gold accent theme
   ============================================ */

:root {
  --bg: #0a0e1a;
  --bg-light: #111628;
  --bg-card: #161b2e;
  --gold: #d4a853;
  --gold-dim: #b8923e;
  --gold-glow: rgba(212, 168, 83, 0.15);
  --white: #ffffff;
  --gray: #a0a4b8;
  --gray-light: #c8cad6;
  --red: #e74c4c;
  --green: #3ecf8e;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --radius: 8px;
  --radius-lg: 12px;
  --transition: 0.2s ease;
}

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---- Nav ---- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(10, 14, 26, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(212, 168, 83, 0.1);
}

.nav-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--white);
  font-weight: 700;
  font-size: 1.1rem;
}

.nav-cta {
  padding: 8px 20px;
  background: var(--gold);
  color: var(--bg);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.875rem;
  border-radius: var(--radius);
  transition: background var(--transition);
}

.nav-cta:hover {
  background: var(--gold-dim);
}

/* ---- Hero ---- */
.hero {
  padding: 160px 0 100px;
  text-align: center;
  background: radial-gradient(ellipse at 50% 0%, rgba(212, 168, 83, 0.08) 0%, transparent 60%);
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.hero-sub {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--gray-light);
  max-width: 560px;
  margin: 0 auto 36px;
}

/* ---- Buttons ---- */
.btn {
  display: inline-block;
  cursor: pointer;
  border: none;
  font-family: var(--font);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius);
  transition: all var(--transition);
}

.btn-primary {
  padding: 14px 36px;
  font-size: 1.05rem;
  background: var(--gold);
  color: var(--bg);
}

.btn-primary:hover {
  background: var(--gold-dim);
  transform: translateY(-1px);
}

/* ---- How It Works ---- */
.how-it-works {
  padding: 80px 0;
  background: var(--bg-light);
}

.how-it-works h2,
.form-section h2,
.faq h2 {
  text-align: center;
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 700;
  margin-bottom: 48px;
}

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

.step {
  background: var(--bg-card);
  border: 1px solid rgba(212, 168, 83, 0.1);
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  text-align: center;
  transition: border-color var(--transition);
}

.step:hover {
  border-color: rgba(212, 168, 83, 0.3);
}

.step-icon {
  margin-bottom: 20px;
}

.step-number {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--gold);
  margin-bottom: 8px;
}

.step h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.step p {
  font-size: 0.9rem;
  color: var(--gray);
  line-height: 1.6;
}

/* ---- Form Section ---- */
.form-section {
  padding: 80px 0;
}

.form-intro {
  text-align: center;
  color: var(--gray-light);
  margin-top: -32px;
  margin-bottom: 40px;
  font-size: 1.05rem;
}

.deal-form {
  max-width: 680px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid rgba(212, 168, 83, 0.1);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--gray-light);
}

.req {
  color: var(--gold);
}

.optional {
  color: var(--gray);
  font-weight: 400;
}

.form-group input,
.form-group select,
.form-group textarea {
  background: var(--bg);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  padding: 12px 14px;
  font-size: 0.95rem;
  font-family: var(--font);
  color: var(--white);
  transition: border-color var(--transition);
  outline: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-glow);
}

.form-group select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23a0a4b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

.form-group select option {
  background: var(--bg-card);
  color: var(--white);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.form-group input.error,
.form-group select.error {
  border-color: var(--red);
}

.btn-submit {
  width: 100%;
  margin-top: 24px;
  padding: 16px;
  font-size: 1.1rem;
}

.btn-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.form-status {
  text-align: center;
  margin-top: 16px;
  font-size: 0.9rem;
  min-height: 24px;
}

.form-status.success {
  color: var(--green);
}

.form-status.error {
  color: var(--red);
}

/* ---- Trust ---- */
.trust {
  padding: 60px 0;
  background: var(--bg-light);
}

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

.trust-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
}

.trust-item strong {
  font-size: 0.95rem;
  font-weight: 700;
}

.trust-item span {
  font-size: 0.8rem;
  color: var(--gray);
}

/* ---- FAQ ---- */
.faq {
  padding: 80px 0;
}

.faq-list {
  max-width: 680px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
  background: none;
  border: none;
  color: var(--white);
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}

.faq-chevron {
  flex-shrink: 0;
  transition: transform 0.25s ease;
  color: var(--gold);
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.open .faq-answer {
  max-height: 300px;
  padding-bottom: 20px;
}

.faq-answer p {
  color: var(--gray);
  font-size: 0.9rem;
  line-height: 1.7;
}

/* ---- Footer ---- */
.footer {
  padding: 48px 0 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.footer-inner {
  text-align: center;
}

.footer-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 16px;
}

.footer-info {
  margin-bottom: 20px;
}

.footer-info p {
  font-size: 0.85rem;
  color: var(--gray);
  margin-bottom: 4px;
}

.footer-info a {
  color: var(--gold);
  text-decoration: none;
}

.footer-info a:hover {
  text-decoration: underline;
}

.footer-copy {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.3);
}

/* ---- Chatbot Widget ---- */
.chat-widget {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 200;
}

.chat-toggle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gold);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(212, 168, 83, 0.3);
  transition: transform var(--transition), box-shadow var(--transition);
}

.chat-toggle:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 28px rgba(212, 168, 83, 0.4);
}

.chat-panel {
  position: absolute;
  bottom: 70px;
  right: 0;
  width: 340px;
  max-height: 440px;
  background: var(--bg-card);
  border: 1px solid rgba(212, 168, 83, 0.2);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5);
}

.chat-header {
  padding: 14px 18px;
  background: var(--bg-light);
  border-bottom: 1px solid rgba(212, 168, 83, 0.15);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--gold);
}

.chat-messages {
  flex: 1;
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 240px;
  max-height: 300px;
}

.chat-message {
  padding: 10px 14px;
  border-radius: var(--radius);
  font-size: 0.85rem;
  line-height: 1.5;
  max-width: 85%;
}

.bot-message {
  background: rgba(212, 168, 83, 0.1);
  color: var(--gray-light);
  align-self: flex-start;
  border: 1px solid rgba(212, 168, 83, 0.1);
}

.user-message {
  background: var(--gold);
  color: var(--bg);
  align-self: flex-end;
  font-weight: 500;
}

.chat-input-area {
  display: flex;
  padding: 12px;
  gap: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.chat-input {
  flex: 1;
  background: var(--bg);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  padding: 10px 12px;
  font-size: 0.85rem;
  font-family: var(--font);
  color: var(--white);
  outline: none;
}

.chat-input::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

.chat-input:focus {
  border-color: var(--gold);
}

.chat-send {
  width: 40px;
  height: 40px;
  border-radius: var(--radius);
  background: var(--bg);
  border: 1px solid rgba(212, 168, 83, 0.2);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition);
}

.chat-send:hover {
  background: rgba(212, 168, 83, 0.1);
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
  .steps-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .trust-grid {
    grid-template-columns: 1fr 1fr;
    gap: 28px;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .deal-form {
    padding: 28px 20px;
  }

  .hero {
    padding: 130px 0 70px;
  }

  .chat-panel {
    width: calc(100vw - 48px);
    right: -12px;
  }
}

@media (max-width: 480px) {
  .trust-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .nav-inner {
    height: 56px;
  }

  .hero {
    padding: 110px 0 60px;
  }

  .how-it-works,
  .form-section,
  .faq {
    padding: 60px 0;
  }
}
