.cta-container {
  width: 100%;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: start;
}

/* Left Side Content */
.cta-left {
  width: 100%;
  padding: 60px 40px;
  /* position: relative; */
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.cta-title {
  font-size: 48px;
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 24px;
  text-transform: uppercase;
  color: var(--black);
}

.cta-description {
  font-size: 16px;
  color: var(--light-black);
  max-width: 400px;
  margin-bottom: 40px;
}

.cta-image-wrapper {
  /* position: relative; */
  margin-top: 40px;
  max-width: 400px;
}

.cta-image {
  position: absolute;
  bottom: 0;
  width: 458px;
  display: block;
  z-index: 555;
}

/* Decorative Lines SVG */
.decorative-lines {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
}

.decorative-lines path {
  fill: none;
  stroke: var(--orange-accent);
  stroke-width: 2;
  stroke-dasharray: 6 4;
}

.dot {
  position: absolute;
  width: 8px;
  height: 8px;
  background-color: var(--orange-accent);
  border-radius: 50%;
}

/* Right Side Form */
.cta-right {
  width: 100%;
  height: 629px;
  background-color: var(--white);
  padding: 60px 40px;
  display: grid;
  grid-template-columns: 1fr;
  /* grid-template-rows: repeat(6, 120px); */
  position: relative;
}

.form-group {
  /* margin-bottom: 24px; */
  /* position: relative; */
}

.form-label {
  display: block;
  font-size: 14px;
  margin-bottom: 8px;
  color: var(--black);
  font-weight: 500;
}

.form-input,
.form-textarea {
  width: 100%;
  padding: 12px 0;
  border: none;
  border-bottom: 1px solid var(--grid-gray);
  font-size: 16px;
  color: var(--light-black);
  background: transparent;
  transition: border-color 0.3s;
  font-family: inherit;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-bottom-color: var(--orange-accent);
}

.form-textarea {
  resize: none;
  min-height: 60px;
}

#contactForm .checkbox-group  {
  display: flex;
  align-items: flex-start;
  /* margin-bottom: 32px; */
  gap: 12px;
}

.custom-checkbox {
  width: 24px;
  height: 24px;
  border: 1px solid var(--grid-black);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 2px;
}

.custom-checkbox input {
  display: none;
}

.custom-checkbox.checked {
  background-color: var(--white);
}

.custom-checkbox.checked::after {
  content: '✓';
  color: var(--orange-accent);
  font-size: 16px;
  font-weight: bold;
}

.checkbox-label {
  font-size: 14px;
  color: var(--black);
  line-height: 1.4;
  cursor: pointer;
}

.checkbox-label a {

  text-decoration: none;
}

.submit-btn {
  background-color: var(--orange-accent);
  color: var(--white);
  border: none;
  padding: 20px 32px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  transition: opacity 0.3s;
}

.submit-btn:hover {
  opacity: 0.9;
}

.submit-btn svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

/* Error Styles */
.error-message {
  color: var(--orange-accent);
  font-size: 12px;
  margin-top: 4px;
  display: none;
}

.form-input.error,
.form-textarea.error {
  border-bottom-color: var(--orange-accent);
}

.error-message.visible {
  display: block;
}

.form-wrapper {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: repeat(5, 120px);
}

.cta-form-name {
  display: flex;
  flex-direction: column;
  justify-content: end;
  padding-top: 40px;
  grid-row: 1/2;
}

.form-label {
  align-self: start;
}

.cta-form-phone {
  display: flex;
  flex-direction: column;
  justify-content: end;
  grid-row: 2/3;
}

.cta-form-comment {
  display: flex;
  flex-direction: column;
  justify-content: end;
  grid-row: 3/4;
}

#contactForm .checkbox-group {
  display: flex;
  align-items: center;
  grid-row: 4/5;
}

.submit-btn {
  grid-row: 5/6;
}

/* Success State */
.success-wrapper {
  display: none;
  flex-direction: column;
  justify-content: center;
  height: 100%;
  animation: fadeIn 0.5s ease;
}

.success-wrapper.active {
  display: flex;
}

.success-icon {
  width: 40px;
  height: 40px;
  border: 2px solid var(--orange-accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  color: var(--orange-accent);
}

.success-title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--black);
}

.success-text {
  font-size: 16px;
  color: var(--light-black);
  max-width: 400px;
  margin-bottom: 40px;
}

.success-graphic {
  width: 100%;
  height: 200px;
  position: relative;
}

.success-graphic svg {
  width: 100%;
  height: 100%;
}

.success-graphic path {
  fill: none;
  stroke: var(--grid-gray);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.success-graphic .graph-line {
  stroke: var(--grid-black);
  stroke-width: 3;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Form Wrapper for toggling */
.form-wrapper {
  transition: opacity 0.3s;
}

.form-wrapper.hidden {
  display: none;
}

.cta-right {
  padding: 0px;
  height: 600px;
}

.form-group {
  /* padding-top: 40px; */
  padding-left: 40px;
  padding-right: 40px;
}

#contactForm .checkbox-group {
  padding-left: 40px;
  padding-right: 40px;
}

.submit-btn {
  height: 120px;
}

.cta-left {
  padding: 40px;
  padding-top: 0px;
}

/* MEDIA QUERIES */

/* Desktop: 1080px - 1440px */
@media (min-width: 1080px) and (max-width: 1439.98px) {
  .cta-title {
    font-size: 40px;
  }

}

/* Tablet Landscape / Small Desktop: 768px - 1080px */
@media (min-width: 768px) and (max-width: 1079.98px) {
  .cta-container {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
  }

  .cta-left {
    padding: 40px;
    flex-direction: row;
    align-items: flex-start;
    gap: 40px;
  }

  .cta-text-block {
    flex: 1;
  }

  .cta-image-wrapper {
    margin-top: 0;
    flex: 1;
    max-width: none;

  }

  .cta-image {
    max-height: 300px;
    object-fit: cover;

  }

  .cta-right {
    padding: 40px;
  }

  .decorative-lines {
    display: none;
    /* Simplify for tablet */
  }
}

/* Mobile: 360px - 768px */
@media (min-width: 360px) and (max-width: 767.98px) {
  .cta-container {
    grid-template-columns: 1fr;
  }

  .cta-left {
    padding: 30px 20px;
    text-align: center;
  }

  .cta-title {
    font-size: 28px;
  }

  .cta-description {
    margin: 0 auto 30px auto;
  }

  .cta-image-wrapper {
    margin: 0 auto;
    max-width: 250px;
  }

  .cta-right {
    padding: 30px 20px;
  }

  .decorative-lines {
    display: none;
  }
}