.layer-actions { flex-wrap:wrap; }
.layer-actions .table-button {
  padding:5px 8px; font-size:11px; border:0; border-radius:5px;
  background:var(--paper); color:var(--ink); white-space:nowrap;
}
.layer-actions .table-button:hover { background:var(--accent-soft); color:var(--accent); }
#attribute-table-modal { width:min(1240px,calc(100% - 32px)); }
#attribute-table-modal .dialog-description { margin-bottom:16px; }
.attribute-readonly { display:inline-block; margin-left:8px; vertical-align:middle; color:var(--accent); background:var(--accent-soft); border-radius:20px; padding:3px 9px; font-size:10px; font-weight:600; }
.attribute-tools { display:flex; gap:12px; align-items:flex-end; flex-wrap:wrap; }
.attribute-tools label { flex:1; min-width:140px; }
.attribute-tools .attribute-search-field { flex:1.5; }
.attribute-tools select,.attribute-tools input { margin-bottom:0; }
.attribute-tools button { margin-bottom:1px; }
#attribute-count { margin:12px 0; }
.attribute-content { display:grid; grid-template-columns:minmax(0,1fr) 290px; border:1px solid var(--line); border-radius:10px; overflow:hidden; }
.attribute-grid-area { min-width:0; display:flex; flex-direction:column; }
.attribute-scroll { overflow:auto; height:clamp(250px,49dvh,560px); background:var(--surface); }
.attribute-grid { border-collapse:separate; border-spacing:0; width:100%; text-align:left; font-size:12px; }
.attribute-grid th { position:sticky; top:0; z-index:2; background:var(--paper); border-bottom:1px solid var(--line); }
.attribute-grid td { padding:8px 12px; border-bottom:1px solid var(--line); border-right:1px solid var(--line); vertical-align:top; }
.attribute-grid th:first-child { left:0; z-index:3; }
.attribute-grid td:first-child { position:sticky; left:0; z-index:1; background:var(--surface); padding:4px 8px; }
.attribute-grid tbody tr { cursor:pointer; }
.attribute-grid tbody tr:nth-child(even) { background:#fcfaf9; }
.attribute-grid tbody tr:hover,.attribute-grid tbody tr:hover td:first-child { background:var(--paper); }
.attribute-grid tbody tr.is-selected,.attribute-grid tbody tr.is-selected td:first-child { background:var(--accent-soft); }
.attribute-sort { display:flex; gap:10px; align-items:center; justify-content:space-between; width:100%; padding:10px 12px; background:transparent; border:0; text-align:left; white-space:nowrap; font-weight:650; font-size:12px; }
.attribute-sort i { color:var(--muted); font-size:11px; }
.attribute-grid th[aria-sort="ascending"] .attribute-sort,.attribute-grid th[aria-sort="descending"] .attribute-sort { color:var(--accent); }
.attribute-row-button { min-width:32px; padding:4px 5px; border:0; background:transparent; color:var(--accent); border-radius:4px; font-size:12px; font-weight:600; }
.attribute-cell { display:block; max-width:260px; min-width:70px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.attribute-cell.is-empty { color:var(--muted); font-style:italic; }
.attribute-empty { padding:35px 20px; text-align:center; color:var(--muted); }
.attribute-pagination { display:flex; flex-wrap:wrap; align-items:center; gap:10px; padding:10px 12px; border-top:1px solid var(--line); margin-top:auto; }
.attribute-pagination label { display:flex; align-items:center; gap:6px; font-size:10px; }
.attribute-pagination select { width:70px; padding:5px; margin:0; }
.attribute-pagination .helper { margin:0; font-size:11px; }
.attribute-page-buttons { display:flex; gap:4px; margin-left:auto; }
.attribute-page-buttons .icon-button { width:27px; height:27px; }
.attribute-inspector { border-left:1px solid var(--line); padding:16px; max-height:calc(clamp(250px,49dvh,560px) + 76px); overflow:auto; background:var(--paper); min-width:0; }
.attribute-inspector h3 { font-size:14px; }
.attribute-inspector .helper { margin:8px 0 12px; }
.attribute-detail-empty { font-size:12px; color:var(--muted); line-height:1.7; margin-top:20px; }
.attribute-detail-field { padding:12px 0; border-bottom:1px solid var(--line); }
.attribute-detail-field dt { font-size:11px; font-weight:650; overflow-wrap:anywhere; }
.attribute-detail-field dd { margin:6px 0 0; font-size:12px; white-space:pre-wrap; overflow-wrap:anywhere; }
.attribute-value-type { display:inline-block; margin-left:8px; color:var(--muted); font-size:9px; font-weight:400; }
.attribute-edit-actions { display:flex; flex-wrap:wrap; align-items:center; gap:8px; margin:12px 0; }
.attribute-edit-actions .helper { flex:1; min-width:220px; margin:0; }
.attribute-cell-button { display:block; width:100%; background:transparent; border:0; padding:0; text-align:left; font:inherit; color:inherit; cursor:text; }
.attribute-grid td.is-edited { background:var(--accent-soft); box-shadow:inset 0 -2px 0 var(--accent); }
.attribute-cell-editor { margin-top:15px; padding:12px; border:1px solid var(--accent); background:var(--surface); border-radius:8px; }
.attribute-cell-editor h4 { margin:0 0 12px; font-size:12px; overflow-wrap:anywhere; }
.attribute-cell-editor textarea { display:block; width:100%; margin:6px 0 12px; padding:9px; border:1px solid var(--line); border-radius:6px; background:var(--surface); color:var(--ink); font:inherit; resize:vertical; min-height:80px; }
.attribute-cell-editor textarea:focus-visible { outline:3px solid #e06878; outline-offset:2px; }
.attribute-discard-panel { padding:12px; margin:12px 0; background:var(--accent-soft); border:1px solid var(--accent); border-radius:8px; }
.attribute-discard-panel p { margin-bottom:10px; font-size:12px; }
@media (max-width:850px) {
  .attribute-content { grid-template-columns:minmax(0,1fr); }
  .attribute-scroll { height:35dvh; min-height:210px; }
  .attribute-inspector { border-left:0; border-top:1px solid var(--line); max-height:250px; }
}
