/** 
 * Card container styles
 * Contains top and bottom card halves
 * Vertically and horizontally centered in the viewport
 */
.card {
  position: absolute;
  top: 50%;
  left: 50%;
  display: flex;
  flex-direction: column;
  text-align: center;
  border: 3px double var(--color-border-line);
  transform: translate(-50%, -50%);
}

 @media (min-width: 532px) {
  .card {
    max-height: 80vh;
    max-width: 500px;
    min-width: 500px;
    transform: translate(-50%, -50%);
  }
}

@media (max-width: 532px) {
  .container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    justify-content: center;
    align-items: center;
  }

  .card {
    position: relative;
    display: flex;
    flex: 0 1 auto;
    top: 0;
    left: 0;
    width: auto;
    height: auto;
    margin: var(--double-space);
    transform: none;
  }
}

/** 
 * Top card half styles
 * Contains headline and save the date info
 */ 
.card-top-half {
  flex: auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: var(--double-space);
  background-color: var(--color-background-primary);  
}

/** 
 * Bottom card half styles
 * Contains contact form
 */ 
.card-bottom-half {
  padding: var(--double-space);
  padding-top: var(--single-space);
  background-color: #FFF3F1;
  border-top: 3px double var(--color-border-line);
}

/**
 * Button styles
 */
button {
  display: inline-block;
  width: 100%;
  padding-top: calc(var(--half-space) + 2.5px); 
  padding-bottom: calc(var(--half-space) + 2.5px);
  padding-left: var(--half-space);
  padding-right: var(--half-space);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.2px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-on-color);
  background-color: #223214;
  cursor: pointer;
}

button:hover {
  background-color: var(--color-button-primary-hover);
}

button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/**
 * Form styles
 * Starting with .form-row, which applies flex and spacing to the input fields within the row
 */
.form-row {
  display: flex;
  gap: var(--half-space);
  margin-bottom: var(--half-space);
}

.form {
  margin-top: var(--single-space);
}

input,
select {
  width: 100%;
  padding: var(--half-space);
  color: var(--color-body-text);
  border: 1px solid #223214;
  background-color: var(--color-background-primary);
  transition: border-color 0.2s ease;
}

input::placeholder {
  color: #87927D;
}

input:focus,
select:focus {
  outline: none;
}

/** 
 * Status message styles
 */
.status-message {
  border-radius: 0px;
  padding: var(--half-space);
  margin-top: var(--half-space);
  margin-bottom: var(--single-space);
  text-align: center;
}

.status-message-success {
  background-color: #d4edda;
  color: var(--color-dark-green);
  border: 1px solid var(--color-dark-green);
}

.status-message-error {
  background-color: #F5CAC3;
  color: #450920;
  border: 1px solid #450920;
}
