/* All Projects database page — Apple style */

.db-header { margin: 40px 0 24px; }
.db-header h1 { display: flex; align-items: center; gap: 12px; }
.db-header p { color: var(--ink-soft); margin-top: 8px; }

/* Toolbar */
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 12px; }
.toolbar input[type="search"] {
  flex: 1 1 240px;
  height: 40px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-pill);
  font-size: 0.95rem;
  font-family: var(--font);
  background: var(--bg-soft);
  color: var(--ink);
  transition: box-shadow 0.2s, background 0.2s;
}
.toolbar input[type="search"]:focus {
  outline: none;
  background: var(--bg);
  box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.15);
  border-color: var(--accent);
}
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  cursor: pointer;
  border: 1px solid var(--line-strong);
  background: var(--bg);
  border-radius: var(--radius-pill);
  padding: 6px 14px;
  font-size: 0.82rem;
  color: var(--ink-soft);
  transition: all 0.18s ease;
}
.chip:hover { background: var(--hover); }
.chip.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.count { color: var(--ink-faint); font-size: 0.85rem; }

/* Table inside a soft rounded card */
.db-card {
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.db-table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
.db-table thead th {
  text-align: left;
  font-weight: 500;
  color: var(--ink-soft);
  padding: 13px 16px;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.db-table tbody td { padding: 14px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.db-table tbody tr:last-child td { border-bottom: none; }
.db-table tbody tr { transition: background 0.15s; }
.db-table tbody tr:hover { background: var(--hover); }
.db-table .c-name { font-weight: 600; min-width: 210px; }
.row-link { color: var(--ink); }
.row-link:hover { color: var(--accent-ink); }
.db-table .c-summary { color: var(--ink-soft); max-width: 320px; }
.db-table .c-skills { min-width: 170px; }
.empty { padding: 48px; text-align: center; color: var(--ink-faint); }

@media (max-width: 720px) {
  .db-table .c-summary, .db-table .c-client, .hide-sm { display: none; }
}

/* 뷰 전환 탭 */
.view-tabs { display:flex; gap:4px; margin:14px 0 4px; border-bottom:1px solid var(--line); }
.view-tab { padding:6px 12px; font-size:0.88rem; color:var(--ink-soft); text-decoration:none;
  border-bottom:2px solid transparent; }
.view-tab.on { color:var(--ink); border-bottom-color:var(--ink); font-weight:600; }
.view-tab:hover { background:var(--hover); border-radius:6px 6px 0 0; }

/* 갤러리 뷰 */
.gallery-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(230px, 1fr));
  gap:16px; margin-top:14px; }
.gallery-card { border:1px solid var(--line); border-radius:var(--radius); overflow:hidden;
  text-decoration:none; color:inherit; background:var(--card);
  transition:box-shadow .15s ease, transform .15s ease; }
.gallery-card:hover { box-shadow:var(--shadow-lg); transform:translateY(-2px); }
.gallery-card__cover { height:140px; background:var(--bg-soft); display:grid; place-items:center; }
.gallery-card__cover img { width:100%; height:100%; object-fit:cover; }
.gallery-card__ph { font-size:2rem; opacity:.5; }
.gallery-card__body { padding:12px 14px; }
.gallery-card__body h4 { margin:0 0 8px; font-size:0.95rem; }
.gallery-card__meta { margin-bottom:8px; }

/* 인라인 편집 셀 */
.db-table--edit .ec { cursor:text; outline:none; min-width:80px; }
.db-table--edit .ec:focus { background:var(--bg-soft); box-shadow:inset 0 0 0 2px var(--t-blue); border-radius:4px; }
.db-table--edit .ec:empty::before { content:attr(data-ph); color:var(--ink-faint); }
.db-table--edit .ec-x { width:28px; }
.db-table--edit tr:hover .ne-xbtn { opacity:1; }
