*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  font-family: 'Poppins', sans-serif;
  color: #1a3d1a;
  overflow-x: hidden;
}

body.modal-open {
  overflow: hidden;
}

.page {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: url('background-img.webp') center center / cover no-repeat fixed;
}

/* Hero */
.hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1.5rem 4rem;
  position: relative;
  z-index: 2;
}

.brand-logo {
  width: min(620px, 72vw);
  height: auto;
  display: block;
  margin-bottom: 1.75rem;
  mix-blend-mode: lighten;
}

.headline {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  color: #1b4d1b;
  line-height: 1.2;
  margin-bottom: 0.75rem;
}

.subtext {
  font-size: clamp(1rem, 2.2vw, 1.2rem);
  font-weight: 500;
  color: #2a3d2a;
  margin-bottom: 2rem;
  line-height: 1.5;
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 2.25rem;
  background: #2e9b3a;
  color: #ffffff;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s ease, transform 0.2s ease;
}

.cta:hover {
  background: #248a2f;
  transform: translateY(-1px);
}

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: rgba(0, 20, 0, 0.55);
  backdrop-filter: blur(4px);
}

.modal-overlay[hidden] {
  display: none;
}

.modal {
  position: relative;
  width: 100%;
  max-width: 440px;
  background: #ffffff;
  border-radius: 16px;
  padding: 2rem 1.75rem 1.75rem;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
  text-align: left;
  animation: modalIn 0.25s ease;
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-close {
  position: absolute;
  top: 0.75rem;
  right: 0.9rem;
  border: none;
  background: transparent;
  font-size: 1.75rem;
  line-height: 1;
  color: #666;
  cursor: pointer;
  padding: 0.25rem;
}

.modal-close:hover {
  color: #1a3d1a;
}

.modal-title {
  font-size: 1.4rem;
  font-weight: 700;
  color: #1b4d1b;
  margin-bottom: 0.35rem;
}

.modal-subtitle {
  font-size: 0.95rem;
  color: #555;
  margin-bottom: 1.35rem;
  line-height: 1.5;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.field span {
  font-size: 0.85rem;
  font-weight: 600;
  color: #2a3d2a;
}

.field input,
.field textarea {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid #cdd9cd;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.95rem;
  color: #1a3d1a;
  background: #f8fbf8;
  resize: vertical;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field input:focus,
.field textarea:focus {
  border-color: #2e9b3a;
  box-shadow: 0 0 0 3px rgba(46, 155, 58, 0.15);
}

.honeypot {
  display: none !important;
  position: absolute;
  left: -9999px;
}

.form-error {
  color: #c62828;
  font-size: 0.875rem;
  margin-bottom: 0.75rem;
}

.submit-btn {
  width: 100%;
  margin-top: 0.25rem;
  padding: 0.85rem 1.25rem;
  background: #2e9b3a;
  color: #fff;
  border: none;
  border-radius: 999px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease;
}

.submit-btn:hover:not(:disabled) {
  background: #248a2f;
}

.submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* Success state */
.modal-success-view {
  text-align: center;
  padding: 1rem 0 0.5rem;
}

.success-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1rem;
  border-radius: 50%;
  background: #e8f5e9;
  color: #2e9b3a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  font-weight: 700;
}

/* Responsive */
@media (max-width: 768px) {
  .hero {
    padding: 2.5rem 1.25rem 3rem;
  }

  .brand-logo {
    width: min(300px, 80vw);
    margin-bottom: 1.25rem;
  }
}

@media (max-width: 480px) {
  .cta {
    padding: 0.75rem 1.75rem;
  }

  .modal {
    padding: 1.75rem 1.25rem 1.5rem;
  }
}
