/* VerticalStackTemplate - SPACING CONTRACT: Controls gaps between organisms */
.vertical-stack-layout {
  display: flex;
  flex-direction: column;
  margin: 0;
  flex: 1;
  min-height: 0;
}

/* Whether a panel FILLS the tab is not this file's business -- it is the one-panel
   rule in styles/organisms/Panel/Panel.css. This template owns the gap between
   panels and nothing else. (It used to promote :last-child, which silently made a
   tab ending in a panel scroll differently from one ending in a hidden modal.) */

/* Gap variants */
.vertical-stack-layout.gap-sm {
  gap: var(--space-2);  /* 8px */
}

.vertical-stack-layout.gap-md {
  gap: var(--space-3);  /* 12px - Standard */
}

.vertical-stack-layout.gap-lg {
  gap: var(--space-5);  /* 20px */
}

/* Responsive: Tighter gaps on mobile */
@media (max-width: 640px) {
  .vertical-stack-layout.gap-md {
    gap: var(--space-3);  /* 12px on mobile */
  }
  
  .vertical-stack-layout.gap-lg {
    gap: var(--space-4);  /* 16px on mobile */
  }
}
