@import '../shared/form-engine.css';

body {
  max-width: 1600px;
}

/* Left Form Column */
.form-column {
  flex: 1 1 45%;
  max-width: 900px;
}

/* Right Sticky Preview Column */
.preview-column {
  flex: 1 1 50%;
}

/* Premium Responsive Responsibilities Table for Mobile Comfort */
@media (max-width: 768px) {
  fieldset table {
    border: none;
  }

  fieldset table thead {
    display: none; /* Hide header on mobile since we layout cards */
  }

  fieldset table,
  fieldset table tbody,
  fieldset table tr,
  fieldset table td {
    display: block;
    width: 100%;
    box-sizing: border-box;
  }

  fieldset table tr {
    border: 1px solid var(--card-border);
    margin-bottom: 1.25rem;
    padding: 0.75rem 1rem;
    border-radius: 4px;
    background-color: var(--card-bg);
  }

  fieldset table td {
    border: none;
    padding: 0.5rem 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }

  fieldset table td label {
    font-weight: 600;
    margin-bottom: 0.25rem;
  }

  /* Add friendly responsive labels before the date inputs */
  fieldset table td:nth-child(2)::before {
    content: "देखि (BS) :";
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--label-color);
    margin-bottom: 0.2rem;
  }

  fieldset table td:nth-child(3)::before {
    content: "सम्म (BS) :";
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--label-color);
    margin-bottom: 0.2rem;
  }

  fieldset table td input[type="text"] {
    width: 100%;
    margin-top: 0;
    height: 36px;
  }

  /* Unified look for dynamic other row buttons on mobile */
  #addOtherRow td {
    display: block;
    padding: 0.5rem 0;
  }

  #addOtherRow td button {
    width: 100% !important;
    height: 36px !important;
  }
}