/* ============================================
   Painting Gallery – Dark Unified Style (Final Desktop Fix)
   ============================================ */

.pg-root {
  font-family: Arial, Helvetica, sans-serif;
  background: #111;
  color: #e8e8e8;
  padding: 20px 0;
}

.pg-topbar { 
  margin-bottom: 14px; 
}

/* === Artist Tags === */
.pg-artist-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-left: 20px; /* ← добавлен такой же отступ, как у поиска */
}

.pg-tag {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  color: #ddd;
  text-decoration: none;
  font-size: 13px;
  transition: all 0.25s ease;
}
.pg-tag:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
}
.pg-tag-active {
  background: rgba(188, 164, 111, 0.9);
  border-color: rgba(188, 164, 111, 0.9);
  color: #fff;
}

/* === Search Form === */
.pg-search-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 18px;
  margin-left: 20px; /* ← отступ слева */
}
.pg-search-row input {
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 14px;
  box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
  transition: all 0.25s ease;
}
.pg-search-row input::placeholder {
  color: rgba(255, 255, 255, 0.45);
}
.pg-search-row input:focus {
  border-color: rgba(188, 164, 111, 0.8);
  box-shadow: 0 0 0 3px rgba(188, 164, 111, 0.25);
  outline: none;
}
.pg-search-row button {
  padding: 10px 16px;
  border: none;
  border-radius: 8px;
  background: rgba(188, 164, 111, 0.9);
  color: #fff;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.2s ease;
}
.pg-search-row button:hover {
  background: rgba(188, 164, 111, 1);
  transform: translateY(-1px);
}
.pg-clear {
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
  font-size: 13px;
  transition: color 0.25s ease;
}
.pg-clear:hover { color: #fff; }

/* === Table Dark === */
.pg-table {
  width: 100%;
  border-collapse: collapse;
  background: #161616;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
}
.pg-table th, .pg-table td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  text-align: left;
  color: #ddd;
  vertical-align: middle;
}
.pg-table th {
  background: #1f1f1f;
  font-weight: 600;
  color: #aaa;
  text-transform: uppercase;
  font-size: 12px;
}
.pg-table td[data-label="Title"],
.pg-table td[data-label="Year"],
.pg-table td[data-label="Size"],
.pg-table td[data-label="Styles"],
.pg-table td[data-label="Mediums"] {
  font-size: 13px;
}

.pg-table td[data-label="Styles"] {
  font-style: italic;
  white-space: normal;
  word-break: normal;
  overflow-wrap: break-word;
}

/* === Inventory Links === */
.pg-artist-link,
.pg-table td[data-label="Inventory"] a {
  color: #c8b47a;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}
.pg-artist-link:hover,
.pg-table td[data-label="Inventory"] a:hover {
  color: #e6d398;
  text-shadow: none !important;
}

.pg-artist-strong {
  font-weight: 700;
  color: #e5e5e5;
  text-decoration: none;
}
.pg-artist-strong:hover { color: #c8b47a; text-decoration: underline; }

/* === Profile Icon === */
.pg-profile-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  width: 42px;
  height: 42px;
  color: #d8c27a;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 50%;
  text-decoration: none;
  transition: all 0.25s ease;
  box-shadow: none;
}
.pg-profile-icon:hover {
  color: #fff;
  background: rgba(216, 194, 122, 0.2);
  transform: scale(1.05);
}
.pg-table td[data-label="Profile"]::before {
  content: "" !important;
  display: none !important;
}

/* === Thumbnails === */
.pg-thumb-wrap {
  position: relative;
  display: inline-block;
  overflow: hidden;
  border-radius: 6px;
  width: 100%;
  aspect-ratio: 1 / 1;
  display: block;
  vertical-align: middle;
}
.pg-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 6px;
  transition: transform 0.18s ease;
  display: block;
  cursor: pointer;
}
.pg-thumb:hover { transform: scale(1.05); }

@media (min-width: 801px) {
  .pg-thumb-wrap {
    width: 180px;
    display: inline-block;
    vertical-align: middle;
  }
}

/* === Buttons & Status === */
.pg-request,
.pg-sold {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  text-align: center;
  color: #fff !important;
  text-shadow: none !important;
  white-space: nowrap;
}
.pg-sold {
  background: #a03a3a;
  transition: background 0.25s ease, transform 0.2s ease;
}
.pg-sold:hover { background: #b44a4a; transform: translateY(-1px); }

.pg-request.pg-normal {
  background: #3e6faf;
  transition: background 0.25s ease, transform 0.2s ease;
}
.pg-request.pg-normal:hover { background: #5a8fe0; transform: translateY(-1px); }

.pg-request.pg-reserved {
  background: #c1a13b;
  color: #000 !important;
  transition: background 0.25s ease, transform 0.2s ease;
}
.pg-request.pg-reserved:hover {
  background: #e0c25e;
  color: #000 !important;
  transform: translateY(-1px);
}

.pg-request.pg-auction {
  background: #6f42c1;
  transition: background 0.25s ease, transform 0.2s ease;
}
.pg-request.pg-auction:hover {
  background: #875adf;
  transform: translateY(-1px);
}

/* === Row background === */
.pg-row-sold { background: rgba(181, 66, 66, 0.08); }
.pg-row-reserved { background: rgba(193, 161, 59, 0.08); }
.pg-row-auction { background: rgba(111, 66, 193, 0.08); }

/* === Lightbox === */
.pg-lightbox {
  position: fixed;
  left: 0; top: 0; right: 0; bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
}
.pg-lightbox.pg-visible { opacity: 1; pointer-events: auto; }
.pg-lightbox-backdrop {
  position: absolute;
  left: 0; top: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.85);
}
.pg-lightbox-content {
  position: relative;
  width: 90%;
  max-width: 900px;
  max-height: 80vh;
  background: #1c1c1c;
  border-radius: 8px;
  padding: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  z-index: 10000;
  overflow: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.pg-lightbox-close {
  position: absolute;
  right: 8px;
  top: 6px;
  background: transparent;
  border: 0;
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
  color: #ccc;
}
.pg-lightbox-img {
  width: 100%;
  height: auto;
  max-width: 720px;
  max-height: 60vh;
  object-fit: contain;
  border-radius: 6px;
  display: block;
  margin: 0 auto;
}
.pg-lightbox-desc {
  font-size: 14px;
  color: #bbb;
  text-align: center;
  margin-top: 8px;
}

/* === Mobile fix === */
@media (max-width:800px){
  .pg-thumb:hover { transform: none !important; }
  .pg-table, .pg-table thead, .pg-table tbody, .pg-table th, .pg-table td, .pg-table tr {
    display:block; width:100%;
  }
  .pg-table thead { display:none; }
  .pg-table tr {
    margin-bottom:12px;
    border:1px solid rgba(255,255,255,0.1);
    padding:10px;
    border-radius:6px;
    background:#161616;
    box-shadow:0 6px 14px rgba(0,0,0,0.2);
  }
  .pg-table td {
    display:block;
    padding:6px 0;
    width:100%;
    color:#ddd;
    position: relative;
    word-break: normal;
    white-space: normal;
    overflow-wrap: break-word;
  }
  .pg-table td[data-label]:before {
    content: attr(data-label) ": ";
    font-weight: 700;
    color: #aaa;
    margin-right: 6px;
  }
  .pg-table td[data-label="Photo"]::before,
  .pg-table td[data-label="Price"]::before,
  .pg-table td[data-label="Profile"]::before {
    content: "" !important;
    display: none !important;
  }
  .pg-table td[data-label="Size"],
  .pg-table td[data-label="Styles"],
  .pg-table td[data-label="Mediums"],
  .pg-table td[data-label="Title"] {
    display: block;
    width: 100%;
    text-align: left;
  }
  .pg-table td[data-label="Photo"] .pg-thumb-wrap {
    width:100%;
    aspect-ratio:1/1;
    overflow:hidden;
    border-radius:6px;
  }
}

@media (max-width:800px){
  .pg-table tr.pg-row-sold { background: rgba(181, 66, 66, 0.12) !important; }
  .pg-table tr.pg-row-reserved { background: rgba(193, 161, 59, 0.12) !important; }
  .pg-table tr.pg-row-auction { background: rgba(111, 66, 193, 0.12) !important; }
}

@media (min-width: 801px) {
  .pg-table th.pg-size-col,
  .pg-table td[data-label="Size"] { width: 160px; max-width: 200px; }
  .pg-table th.pg-styles-col,
  .pg-table td[data-label="Styles"] { width: 220px; max-width: 260px; }
}

/* ============================================
   Breadcrumbs + Header Final (Catalogue with Gold Divider)
   ============================================ */

.pg-breadcrumbs-inline {
  text-align: left;
  margin: 90px auto 20px;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.8);
  font-family: 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
}

.pg-breadcrumbs-inline a {
  color: #fff;
  text-decoration: none;
  transition: color 0.25s ease;
}

.pg-breadcrumbs-inline a:hover {
  color: rgba(188, 164, 111, 0.95);
}

.pg-breadcrumb-sep {
  color: rgba(188, 164, 111, 0.9);
  margin: 0 6px;
  font-weight: 600;
}

.pg-catalogue-header {
  text-align: center;
  margin: 0 auto 35px;
  padding: 0 18px;
}

.pg-catalogue-title {
  font-size: 38px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 10px;
  letter-spacing: 0.4px;
  position: relative;
}

.pg-catalogue-title::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background: rgba(188, 164, 111, 0.9);
  margin: 12px auto 0;
  border-radius: 3px;
}

.pg-catalogue-intro {
  color: rgba(255, 255, 255, 0.85);
  font-size: 16px;
  letter-spacing: 0.2px;
  margin-top: 8px;
}

@media (max-width: 700px) {
  .pg-breadcrumbs-inline { 
    margin-top: 70px;
    font-size: 14px;
  }
  .pg-catalogue-title {
    font-size: 28px;
  }
  .pg-catalogue-intro {
    font-size: 14px;
  }
}

.pg-pagination ul {
  list-style: none !important;
  margin: 0;
  padding: 0;
}

.pg-pagination li {
  display: inline-block;
  margin: 0 6px;
}

.pg-pagination a, .pg-pagination span {
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 4px;
  background: #f5f5f5;
  color: #222;
}

.pg-pagination a:hover {
  background: #2b6cb0;
  color: #fff;
}
