/*
 * Withdrawal form layout – label | input | description columns.
 * Uses centralized .form-control, .form-control-sm from application.css.
 * Scoped to .withdrawal-form-layout to avoid affecting other forms.
 */

.withdrawal-form-layout {
  width: 100%;
  max-width: none;
}

/* Number fields: compact width (centralized form-control still applies) */
.withdrawal-form-layout input[type="number"].form-control {
  max-width: 100px;
  width: auto;
  min-width: 4em;
  box-sizing: content-box;
}

/* Top row: main form (left) + state block (right) */
.withdrawal-form-layout .withdrawal-top-row {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}

.withdrawal-form-layout .withdrawal-main {
  flex: 1 1 0;
  min-width: 320px;
}

.withdrawal-form-layout .withdrawal-state-block {
  flex: 0 0 600px;
  min-width: 380px;
}

/* Shared states partial sets inline width: 50%; expand to full column without editing the partial */
.withdrawal-form-layout .withdrawal-state-block .state-dual-selector {
  margin-bottom: 0;
  width: 100% !important;
  max-width: 100%;
  box-sizing: border-box;
}

.withdrawal-form-layout .withdrawal-state-block h6 {
  font-size: 0.95rem;
  font-weight: 600;
  color: #495057;
  margin-bottom: 0.75rem;
  border-bottom: 1px solid #dee2e6;
  padding-bottom: 0.35rem;
}

/* Form row: label | input | description (aligned columns) */
.withdrawal-form-layout .form-row-labeled {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 0.6rem;
  min-height: 2.25rem;
}

.withdrawal-form-layout .form-row-labeled .field-label {
  flex: 0 0 200px;
  width: 200px;
  padding-top: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #495057;
  line-height: 1.5;
}

.withdrawal-form-layout .form-row-labeled .field-input {
  flex: 0 0 120px;
  width: 120px;
  min-width: 120px;
  display: flex;
  align-items: center;
}

.withdrawal-form-layout .form-row-labeled .field-input.wide {
  flex: 0 0 200px;
  width: 200px;
  min-width: 200px;
}

.withdrawal-form-layout .form-row-labeled .field-input .form-control {
  width: 100%;
  max-width: 100%;
}

.withdrawal-form-layout .form-row-labeled .field-input input[type="number"] {
  width: 100%;
  max-width: 100px;
}

/* Description column: fills remaining space (covers white space) */
.withdrawal-form-layout .form-row-labeled .field-desc {
  flex: 1 1 0;
  min-width: 0;
}

.withdrawal-form-layout .form-row-labeled .field-desc textarea {
  width: 80%;
  min-height: 2rem;
  resize: vertical;
  box-sizing: border-box;
}

/* Section description block (bottom of form) */
.withdrawal-form-layout .section-description-block {
  margin-top: 0.5rem;
  padding-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.withdrawal-form-layout .section-description-block .form-row-labeled .field-label {
  flex: 0 0 200px;
  width: 200px;
}

.withdrawal-form-layout .section-description-block .form-row-labeled .field-desc {
  flex: 1 1 0;
  min-width: 0;
}

.withdrawal-form-layout .section-description-block textarea {
  min-height: 80px;
  width: 100%;
  box-sizing: border-box;
}

/* Form actions (Save / Cancel) – uses centralized .btn */
.withdrawal-form-layout .form-actions {
  margin-top: 0.5rem;
  padding-top: 1rem;
  display: flex;
  gap: 0.75rem;
} 
