/* context-grid.css - Styling for Context Grid */

.context-grid {
  display: flex;
  flex-direction: column; /* stack “grid rows” vertically */
  border: 1px solid var(--background3); /* Soft border */
  border-radius: 10px;
  overflow: hidden;
  font-family: Arial, sans-serif;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08); /* Softer shadow */
}

/* Each "row" is a grid that has X columns: 1 for item + #context columns */
.grid-row {
  display: grid;
  grid-template-columns: 300px repeat(auto-fit, minmax(150px, 1fr));
  border-bottom: 1px solid var(--background3);
}

/* The last row might not need a border if you want to avoid a bottom border */
.grid-row:last-child {
  border-bottom: none;
}

.grid-cell {
  border-right: 1px solid var(--background3);
  padding: 15px;
  text-align: center;
  color: var(--text1); /* Ensuring consistency in text color */
}

/* The last column in a row might not need a border */
.grid-row > .grid-cell:last-child {
  border-right: none;
}

.selected-cell {
  border: 1px solid black;
}

/* Highlight edited cells with a light yellow background */
.edited-cell {
  background-color: #fff9c4; /* Light yellow */
}

/* Header row style */
.header-row {
  background: var(--background2); /* Soft light grey */
  border-bottom: 2px solid var(--primary1); /* Emphasize separation from data rows */
}

.header-cell {
  font-weight: bold;
  font-size: 18px;
  color: var(--text1);
}

.header-title {
  display: flex;
  justify-content: space-between; 
  align-items: center;
  padding: 10px 15px;
}

.action-buttons {
  display: flex;
  gap: 10px;
}

/* Parent summary styling */
.parent-summary {
  display: inline-block;
  background: var(--accent1); /* Muted cyan for a technical look */
  color: white; /* Ensuring contrast */
  font-size: 12px;
  padding-top: 2px; 
  padding-bottom: 1px;
  padding-left: 4px;
  padding-right: 4px;
  border-radius: 5px;
  margin-bottom: 5px;
  border: 1px solid var(--accent2); /* Defines the element */
}
