/* DDS Projects – public pages. Colors inherit from your theme where possible. */
.dds-portfolio { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 24px; margin: 1.5em 0; }
.dds-pcard { display: block; text-decoration: none !important; color: inherit; }
.dds-pcard-img { display: block; aspect-ratio: 4/3; overflow: hidden; border-radius: 6px; background: #eee; }
.dds-pcard-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s ease; }
.dds-pcard:hover .dds-pcard-img img { transform: scale(1.04); }
.dds-pcard-title { display: block; font-weight: 600; font-size: 1.1em; margin-top: .6em; }
.dds-pcard-meta { display: block; opacity: .7; font-size: .9em; }

.dds-back a { text-decoration: none; }
.dds-project-head h2 { margin-bottom: .2em; }
.dds-meta { opacity: .7; margin-top: 0; }

.dds-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 1.2em 0 .6em; border-bottom: 1px solid rgba(0,0,0,.12); }
.dds-tabs button { background: none; border: 0; border-bottom: 3px solid transparent; padding: .6em 1em; cursor: pointer; font: inherit; color: inherit; opacity: .7; }
.dds-tabs button.is-active { border-bottom-color: currentColor; opacity: 1; font-weight: 600; }
.dds-tabs em { font-style: normal; font-size: .75em; background: rgba(0,0,0,.08); padding: 2px 6px; border-radius: 8px; margin-left: 4px; }

.dds-revpanel { display: none; }
.dds-revpanel.is-active { display: block; }
.dds-revinfo { opacity: .75; font-size: .95em; }

.dds-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; margin: 1em 0 2em; }
.dds-item { position: relative; display: block; aspect-ratio: 4/3; overflow: hidden; border-radius: 6px; background: #eee; text-decoration: none !important; color: inherit; }
.dds-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s ease; }
.dds-item:hover img { transform: scale(1.04); }
.dds-item .dds-cap { position: absolute; left: 0; right: 0; bottom: 0; padding: .5em .7em; background: linear-gradient(transparent, rgba(0,0,0,.7)); color: #fff; font-size: .85em; }
.dds-item-pdf { display: flex; flex-direction: column; }
.dds-item-pdf .dds-pdf { flex: 1; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1.6em; color: #b32d2e; background: #fbeaea; }
.dds-item-pdf .dds-cap { position: static; background: #f5f5f5; color: #333; }

.dds-lock { max-width: 420px; margin: 2em auto; padding: 2em; border: 1px solid rgba(0,0,0,.12); border-radius: 8px; text-align: center; }
.dds-lock form { display: flex; gap: 8px; margin-top: 1em; }
.dds-lock input { flex: 1; padding: .6em .8em; }
.dds-lock button { padding: .6em 1.2em; cursor: pointer; }
.dds-err { color: #b32d2e; }
.dds-missing { opacity: .75; }

/* Lightbox */
.dds-lb { position: fixed; inset: 0; z-index: 99999; background: rgba(10,10,12,.94); display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity .2s; }
.dds-lb.is-open { opacity: 1; }
.dds-lb figure { margin: 0; max-width: 92vw; max-height: 88vh; display: flex; flex-direction: column; align-items: center; }
.dds-lb img { max-width: 92vw; max-height: 82vh; object-fit: contain; box-shadow: 0 10px 40px rgba(0,0,0,.5); background: #fff; }
.dds-lb figcaption { color: #eee; margin-top: .8em; text-align: center; font-size: .95em; }
.dds-lb button { position: absolute; background: rgba(255,255,255,.12); color: #fff; border: 0; cursor: pointer; width: 48px; height: 48px; border-radius: 50%; font-size: 26px; line-height: 48px; padding: 0; }
.dds-lb button:hover { background: rgba(255,255,255,.25); }
.dds-lb .dds-lb-close { top: 16px; right: 16px; }
.dds-lb .dds-lb-prev { left: 16px; top: 50%; transform: translateY(-50%); }
.dds-lb .dds-lb-next { right: 16px; top: 50%; transform: translateY(-50%); }
.dds-lb .dds-lb-count { position: absolute; top: 24px; left: 24px; color: #bbb; font-size: .9em; }
@media (max-width: 600px) { .dds-lb .dds-lb-prev, .dds-lb .dds-lb-next { top: auto; bottom: 16px; transform: none; } }
