/* VDM Galerías: all panel styles are scoped; does not modify body/page wrappers. */
.vdmg-wrap,.vdmg-wrap *,.vdmg-gallery,.vdmg-gallery * {box-sizing:border-box}
.vdmg-wrap {width:100%;max-width:1160px;margin:0 auto;color:#33291d;font-family:inherit;font-size:14px;line-height:1.5}
.vdmg-wrap a {text-decoration:none}
.vdmg-hero {display:flex;gap:22px;align-items:center;justify-content:space-between;border:1px solid #e8d8ae;border-radius:18px;background:linear-gradient(120deg,#fbf7eb 0%,#f0e7d0 100%);padding:24px 27px;margin:0 0 16px}
.vdmg-eyebrow {font-size:11px;letter-spacing:1.6px;font-weight:800;color:#8e6c20;margin-bottom:6px}
.vdmg-hero h2 {margin:0 0 7px!important;font-family:Georgia,'Times New Roman',serif;font-weight:600;font-size:clamp(26px,3vw,37px);line-height:1.16;color:#262014}
.vdmg-hero p {font-size:13px;margin:0;color:#77603e}
.vdmg-wrap .vdmg-btn {font-weight:700;font-size:13px;line-height:1.3;font-family:inherit;display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;gap:5px;padding:13px 17px;border-radius:10px;border:1px solid transparent;min-height:42px;cursor:pointer;text-decoration:none;transition:filter .15s,background .15s;box-shadow:none}
.vdmg-wrap .vdmg-btn:hover {filter:brightness(.97)}
.vdmg-wrap .vdmg-btn-gold {color:#fff!important;background:#987923;border-color:#987923;box-shadow:0 4px 10px rgba(91,69,18,.1)}
.vdmg-wrap .vdmg-btn-outline {background:#fff;color:#5b472e;border-color:#eadbc6}
.vdmg-wrap .vdmg-btn-soft {color:#9b731c;background:#fffaf0;border-color:#e9d9b9}
.vdmg-wrap .vdmg-btn-danger {color:#ae1f2d;background:#fff;border-color:#f3c8ca}
.vdmg-nav {display:flex;flex-wrap:wrap;gap:8px;padding:0 0 20px;margin-bottom:12px;border-bottom:1px solid #eae3d7}
.vdmg-wrap .vdmg-pill {display:inline-flex;align-items:center;justify-content:center;min-height:40px;border:1px solid #e9dbc9;color:#55442d;background:#fff;border-radius:30px;font-weight:700;font-size:12px;padding:10px 17px;text-decoration:none}
.vdmg-wrap .vdmg-pill-active {background:#937622;color:#fff;border-color:#937622}
.vdmg-message,.vdmg-empty,.vdmg-notice {border-radius:10px;padding:14px 16px;margin:14px 0 20px}
.vdmg-message,.vdmg-empty {background:#faf8f3;border:1px solid #e8dfd2}
.vdmg-notice-success {color:#18653a;background:#edf9f1;border:1px solid #b6e4c2}
.vdmg-notice-error {color:#8f2630;background:#fff2f2;border:1px solid #f2c1c5}
.vdmg-search {display:grid;grid-template-columns:minmax(140px,2fr) minmax(120px,1fr) minmax(135px,1fr) auto;align-items:end;gap:10px;border:1px solid #ebdfcc;border-radius:14px;padding:16px;margin-top:20px;background:#fff}
.vdmg-search label,.vdmg-fields label {font-size:12px;display:flex;flex-direction:column;gap:6px;font-weight:700;color:#4f3b25;min-width:0}
.vdmg-wrap input[type=search],.vdmg-wrap input[type=text],.vdmg-wrap input[type=number],.vdmg-wrap select {display:block;width:100%;max-width:none;min-height:44px;border-radius:9px;border:1px solid #e2d2bb;background:#fff;color:#473621;padding:10px 12px;margin:0;font-size:13px;line-height:1.3;box-shadow:none}
.vdmg-wrap input:focus,.vdmg-wrap select:focus {border-color:#9d7b26;outline:2px solid rgba(160,122,38,.16);outline-offset:0}
.vdmg-wrap input[type=checkbox],.vdmg-wrap input[type=radio] {accent-color:#957622}
.vdmg-results {font-size:12px;color:#766047;margin:15px 2px 10px}
.vdmg-item {display:flex;align-items:center;gap:18px;border:1px solid #e8dece;border-radius:15px;background:#fff;padding:13px;margin-bottom:12px;box-shadow:0 3px 10px rgba(36,26,10,.025)}
.vdmg-item-thumb {flex:0 0 134px;width:134px;height:120px;border-radius:12px;overflow:hidden;background:#f8f2e7;display:grid;place-items:center;color:#aa925b;font-size:30px}
.vdmg-item-thumb img {width:100%;height:100%;object-fit:cover;display:block}
.vdmg-item-info {flex:1;min-width:0}
.vdmg-status {display:inline-block;border-radius:30px;font-size:11px;padding:3px 9px;font-weight:700}
.vdmg-status-live {background:#eaf8ef;color:#227346;border:1px solid #cfe8d7}
.vdmg-status-draft {background:#fff6e3;color:#895b14;border:1px solid #eadab4}
.vdmg-item-info h3 {font-family:Georgia,'Times New Roman',serif;font-size:19px;font-weight:600;color:#30241a;margin:6px 0!important;line-height:1.25}
.vdmg-item-meta {font-size:12px;color:#946d25;margin-bottom:5px}
.vdmg-shortcode {display:flex;align-items:center;gap:10px;margin-top:7px;flex-wrap:wrap}
.vdmg-shortcode code,.vdmg-existing-shortcode code {background:#faf4e9;color:#735519;padding:5px 8px;border:1px solid #eee0cc;border-radius:6px;font-size:11px;overflow-wrap:anywhere}
.vdmg-wrap .vdmg-copy {border:0;background:transparent;padding:3px 0;font:700 12px inherit;color:#977420;cursor:pointer;text-decoration:underline}
.vdmg-item-actions {display:flex;align-items:center;justify-content:end;flex-wrap:wrap;gap:7px;margin-left:auto}
.vdmg-item-actions .vdmg-btn {min-height:38px;padding:9px 13px;font-size:12px}
.vdmg-delete-form {margin:0}
.vdmg-pagination {display:flex;justify-content:center;gap:7px;flex-wrap:wrap;margin:20px 0}
.vdmg-page {display:grid;place-items:center;min-width:35px;height:35px;border-radius:8px;border:1px solid #e3d8c6;color:#84631e;background:#fff}
.vdmg-page-active {background:#957622;color:#fff}
.vdmg-back {display:inline-block;color:#896923;font-weight:700;font-size:13px;margin-bottom:13px}
.vdmg-form-section {background:#fff;border:1px solid #e9dfce;border-radius:14px;padding:23px;margin:14px 0}
.vdmg-form-heading h3 {font-family:Georgia,'Times New Roman',serif;font-weight:600;color:#2f261b;margin:0 0 5px!important;font-size:23px}
.vdmg-form-heading p {font-size:13px;color:#7c684d;margin:0 0 19px}
.vdmg-fields {display:grid;grid-template-columns:1fr 1fr;gap:18px}
.vdmg-fields .vdmg-full {grid-column:1/-1}
.vdmg-fields label span {color:#b23836}
.vdmg-upload {display:flex;flex-direction:column;align-items:center;text-align:center;justify-content:center;gap:6px;border:2px dashed #d5c292;background:#fdfbf5;border-radius:13px;padding:25px 15px;cursor:pointer;position:relative;color:#715722}
.vdmg-upload:hover {background:#fbf6ea}
.vdmg-upload-icon {font-size:28px;font-weight:bold;color:#967524;line-height:1}
.vdmg-upload strong {font-size:15px}
.vdmg-upload small {font-size:12px;color:#7c725e}
.vdmg-upload input {position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}
.vdmg-new-preview {display:flex;flex-wrap:wrap;gap:10px;margin-top:12px}
.vdmg-new-preview:empty {display:none}
.vdmg-new-preview-item {width:95px;max-width:100%;position:relative}
.vdmg-new-preview-item img {width:95px;height:90px;display:block;object-fit:cover;border-radius:8px}
.vdmg-new-preview-item small {display:block;color:#786849;font-size:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.vdmg-new-preview-count {width:100%;font-size:12px;color:#796138}
.vdmg-existing-title {font-size:15px;margin:22px 0 3px;color:#392b1b}
.vdmg-existing-title span {color:#8b7147;font-weight:400}
.vdmg-field-help {font-size:12px;color:#827159;margin:0 0 12px}
.vdmg-image-order {display:grid;grid-template-columns:repeat(auto-fill,minmax(122px,1fr));gap:12px}
.vdmg-image-tile {border:1px solid #e8dcc6;border-radius:11px;padding:7px;background:#fdfaf6;min-width:0}
.vdmg-tile-image {height:108px;overflow:hidden;border-radius:6px;background:#eee7da}
.vdmg-tile-image img {width:100%;height:100%;object-fit:cover;display:block}
.vdmg-tile-tools {display:flex;gap:5px;justify-content:center;margin-top:7px}
.vdmg-tile-tools button {border:1px solid #d9c8a6;background:#fff;color:#72591f;width:31px;height:29px;border-radius:7px;cursor:pointer;font-size:17px;padding:0}
.vdmg-tile-tools .vdmg-remove {color:#bc3030;border-color:#f3cbcb}
.vdmg-layout-choices {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:22px}
.vdmg-layout-choice {position:relative;cursor:pointer;min-width:0}
.vdmg-layout-choice input {position:absolute;opacity:0;top:15px;right:15px;z-index:1}
.vdmg-layout-choice-inner {display:flex;flex-direction:column;gap:7px;height:100%;border:1px solid #e6d9c1;border-radius:11px;padding:15px 13px;background:#fff;min-height:135px}
.vdmg-layout-choice-inner .vdmg-layout-icon {font-size:32px;line-height:1;color:#a0812c}
.vdmg-layout-choice-inner strong {font-size:13px;color:#3d3020}
.vdmg-layout-choice-inner small {font-size:11px;color:#887258;line-height:1.4}
.vdmg-layout-choice input:checked + .vdmg-layout-choice-inner {border:2px solid #9f7c25;background:#fbf6e9;padding:14px 12px}
.vdmg-layout-choice input:focus-visible + .vdmg-layout-choice-inner {outline:3px solid #b19d66;outline-offset:2px}
.vdmg-design-fields {margin-top:12px}
.vdmg-checkbox {display:flex!important;flex-direction:row!important;align-items:center;gap:9px!important;justify-content:start;align-self:end;min-height:44px;font-size:13px!important}
.vdmg-checkbox input {height:18px;width:18px}
.vdmg-editor-footer {display:flex;justify-content:flex-end;gap:10px;margin:20px 0}
.vdmg-existing-shortcode {font-size:12px;color:#715a36;margin-bottom:20px}
/* Public galleries are independent of the administration panel */
.vdmg-gallery {width:100%;max-width:100%;min-width:0;position:relative;margin:10px 0 20px}
.vdmg-gallery button {appearance:none;-webkit-appearance:none;font:inherit;box-shadow:none}
.vdmg-photo-grid {display:grid;grid-template-columns:repeat(var(--vdmg-cols,3),minmax(0,1fr));gap:12px}
.vdmg-photo {border:0;padding:0;margin:0;cursor:zoom-in;width:100%;overflow:hidden;border-radius:11px;display:block;background:#f5f1e9;min-width:0;position:relative}
.vdmg-photo img {display:block;width:100%;height:100%;object-fit:cover;transition:transform .2s ease}
.vdmg-photo:hover img {transform:scale(1.025)}
.vdmg-ratio-wide .vdmg-photo {aspect-ratio:16/9}
.vdmg-ratio-square .vdmg-photo {aspect-ratio:1/1}
.vdmg-ratio-portrait .vdmg-photo {aspect-ratio:3/4}
.vdmg-ratio-natural .vdmg-photo {height:auto}
.vdmg-ratio-natural .vdmg-photo img {height:auto;object-fit:contain}
.vdmg-layout-collage .vdmg-photo-grid {grid-template-columns:repeat(3,minmax(0,1fr));grid-auto-flow:row dense}
.vdmg-layout-collage .vdmg-photo:first-child:not(:only-child) {grid-column:span 2;grid-row:span 2;height:100%;aspect-ratio:auto}
.vdmg-layout-collage .vdmg-photo:first-child:not(:only-child) img {width:100%;height:100%;object-fit:cover}
.vdmg-layout-masonry .vdmg-photo-grid {display:block;columns:var(--vdmg-cols,3);column-gap:12px}
.vdmg-layout-masonry .vdmg-photo {display:inline-block;vertical-align:top;break-inside:avoid;margin:0 0 12px;aspect-ratio:auto;height:auto}
.vdmg-layout-masonry .vdmg-photo img {width:100%;height:auto;object-fit:contain}
.vdmg-carousel-frame {position:relative}
.vdmg-carousel-viewport {display:flex;overflow-x:auto;scroll-snap-type:x mandatory;scroll-behavior:smooth;scrollbar-width:none;gap:0;border-radius:13px;overscroll-behavior-x:contain}
.vdmg-carousel-viewport::-webkit-scrollbar {display:none}
.vdmg-layout-carousel .vdmg-slide {flex:0 0 100%;scroll-snap-align:start;scroll-snap-stop:always;border-radius:0}
.vdmg-carousel-arrow {position:absolute;top:50%;transform:translateY(-50%);z-index:2;width:40px;height:45px;padding:0;border-radius:10px;background:rgba(255,255,255,.9);color:#6d501d;border:1px solid rgba(184,159,102,.4);font-size:29px;line-height:1;cursor:pointer;display:grid;place-items:center}
.vdmg-carousel-arrow:hover {background:white}
.vdmg-arrow-prev {left:12px}.vdmg-arrow-next {right:12px}
.vdmg-carousel-dots {display:flex;justify-content:center;gap:7px;flex-wrap:wrap;margin-top:12px}
.vdmg-carousel-dot {width:9px;height:9px;border-radius:50%;background:#d9ccb2;border:0;cursor:pointer;padding:0}
.vdmg-carousel-dot.is-active {background:#927123;transform:scale(1.2)}
.vdmg-lightbox {position:fixed;inset:0;z-index:2147483000;background:rgba(0,0,0,.91);display:flex;align-items:center;justify-content:center;padding:45px 20px 25px}
.vdmg-lightbox img {max-width:100%;max-height:100%;object-fit:contain;display:block}
.vdmg-lightbox-close {position:absolute;top:12px;right:14px;border:1px solid rgba(255,255,255,.55);border-radius:40px;width:38px;height:38px;background:rgba(0,0,0,.25);color:white;font-size:28px;cursor:pointer;line-height:1}
.vdmg-lightbox-caption {position:absolute;bottom:6px;color:#f2f2f2;font-size:12px;text-align:center;padding:4px 20px;max-width:90%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
@media(max-width:850px) {
 .vdmg-item {align-items:flex-start;flex-wrap:wrap}
 .vdmg-item-actions {width:100%;margin-left:0;justify-content:flex-end}
 .vdmg-layout-choices {grid-template-columns:repeat(2,minmax(0,1fr))}
 .vdmg-search {grid-template-columns:1fr 1fr}
 .vdmg-search-main {grid-column:1/-1}
 .vdmg-search>.vdmg-btn {align-self:end}
}
@media(max-width:570px) {
 .vdmg-hero {padding:18px;align-items:stretch;flex-direction:column;gap:13px}
 .vdmg-hero .vdmg-btn {align-self:flex-start}
 .vdmg-nav {gap:7px;padding-bottom:15px}
 .vdmg-wrap .vdmg-pill {font-size:11px;padding:9px 13px}
 .vdmg-search {grid-template-columns:1fr;padding:12px}
 .vdmg-search-main {grid-column:auto}
 .vdmg-search>.vdmg-btn {width:100%}
 .vdmg-item {gap:12px;padding:12px}
 .vdmg-item-thumb {flex:0 0 95px;width:95px;height:95px}
 .vdmg-item-info h3 {font-size:16px}
 .vdmg-item-actions {justify-content:flex-start}
 .vdmg-item-actions .vdmg-btn {padding:9px 11px}
 .vdmg-form-section {padding:15px}
 .vdmg-fields {grid-template-columns:1fr;gap:12px}
 .vdmg-layout-choices {gap:8px}
 .vdmg-layout-choice-inner {min-height:136px;padding:10px}
 .vdmg-layout-choice input:checked + .vdmg-layout-choice-inner {padding:9px}
 .vdmg-photo-grid {grid-template-columns:repeat(2,minmax(0,1fr))}
 .vdmg-layout-collage .vdmg-photo-grid {grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}
 .vdmg-layout-collage .vdmg-photo:first-child:not(:only-child) {grid-column:span 2;grid-row:span 1;aspect-ratio:16/9}
 .vdmg-layout-masonry .vdmg-photo-grid {columns:2;column-gap:7px}
 .vdmg-layout-masonry .vdmg-photo {margin-bottom:7px}
 .vdmg-layout-carousel:not(.vdmg-ratio-natural) .vdmg-slide {aspect-ratio:4/3}
 .vdmg-carousel-arrow {height:36px;width:32px;font-size:23px}
 .vdmg-arrow-prev {left:6px}.vdmg-arrow-next {right:6px}
}
@media(prefers-reduced-motion:reduce) {
 .vdmg-gallery * {scroll-behavior:auto!important;transition:none!important}
}

/* VDM Galerías v1.1: mixed-media gallery improvements */
.vdmg-gallery {isolation:isolate}
.vdmg-gallery .vdmg-photo {box-shadow:0 7px 22px rgba(39,32,20,.07);outline-offset:3px;transition:box-shadow .2s ease,transform .2s ease}
.vdmg-gallery .vdmg-photo:focus-visible {outline:3px solid #a08239}
.vdmg-gallery .vdmg-photo:hover {box-shadow:0 10px 28px rgba(39,32,20,.14)}
.vdmg-photo .vdmg-play-icon {position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);height:66px;width:66px;display:grid;place-items:center;padding-left:4px;color:#fff;background:rgba(17,17,17,.7);border:2px solid rgba(255,255,255,.92);border-radius:50%;font-size:23px;z-index:2;box-shadow:0 4px 22px rgba(0,0,0,.2);pointer-events:none;transition:transform .2s ease,background .2s ease}
.vdmg-photo.vdmg-is-video:hover .vdmg-play-icon {background:rgba(152,121,35,.98);transform:translate(-50%,-50%) scale(1.08)}
.vdmg-gallery .vdmg-media-label {position:absolute;right:12px;top:12px;border-radius:7px;font-size:11px;font-weight:700;background:rgba(16,16,16,.76);color:#fff;padding:5px 9px;z-index:2;pointer-events:none}
.vdmg-video-placeholder {display:grid;place-items:center;width:100%;height:100%;min-height:100px;background:linear-gradient(125deg,#373027,#181818);color:#d7c9ac;font-size:26px;position:relative}
.vdmg-gallery .vdmg-photo>.vdmg-video-placeholder {height:100%}
.vdmg-layout-masonry .vdmg-photo>.vdmg-video-placeholder,.vdmg-ratio-natural .vdmg-photo>.vdmg-video-placeholder {aspect-ratio:16/9}
.vdmg-layout-masonry .vdmg-photo.vdmg-is-video,.vdmg-ratio-natural .vdmg-photo.vdmg-is-video {aspect-ratio:16/9}
.vdmg-layout-masonry .vdmg-photo.vdmg-is-video img,.vdmg-ratio-natural .vdmg-photo.vdmg-is-video img {height:100%;object-fit:cover}
.vdmg-gallery .vdmg-carousel-frame {overflow:hidden;border-radius:14px;background:#1e1a16}
.vdmg-layout-carousel .vdmg-slide,.vdmg-layout-filmstrip .vdmg-slide {flex:0 0 100%;scroll-snap-align:start;scroll-snap-stop:always;border-radius:0}
.vdmg-layout-carousel .vdmg-slide img,.vdmg-layout-filmstrip .vdmg-slide img {object-fit:contain;background:#211d19}
.vdmg-layout-carousel .vdmg-slide,.vdmg-layout-filmstrip .vdmg-slide {box-shadow:none}
.vdmg-layout-carousel .vdmg-slide.vdmg-is-video img,.vdmg-layout-filmstrip .vdmg-slide.vdmg-is-video img {object-fit:contain}
.vdmg-carousel-counter {position:absolute;right:13px;bottom:13px;border-radius:50px;padding:6px 11px;color:white;background:rgba(15,15,15,.68);font-size:12px;font-weight:700;pointer-events:none;z-index:1;line-height:1.2}
.vdmg-filmstrip-thumbs {display:flex;gap:9px;padding:12px 2px 5px;overflow-x:auto;scrollbar-width:thin;overscroll-behavior-x:contain}
.vdmg-gallery .vdmg-filmstrip-thumb {flex:0 0 94px;width:94px;height:70px;padding:0;border:2px solid transparent;border-radius:9px;background:#eee7df;position:relative;overflow:hidden;cursor:pointer;opacity:.65;transition:opacity .2s, border-color .2s}
.vdmg-gallery .vdmg-filmstrip-thumb.is-active {opacity:1;border-color:#9f7c25}
.vdmg-gallery .vdmg-filmstrip-thumb img {width:100%;height:100%;object-fit:cover;display:block}
.vdmg-gallery .vdmg-filmstrip-thumb .vdmg-video-placeholder {min-height:0;font-size:22px}
.vdmg-gallery .vdmg-filmstrip-thumb>span:not(.vdmg-video-placeholder) {position:absolute;inset:0;display:grid;place-items:center;color:#fff;text-shadow:0 2px 8px #000;font-size:22px;pointer-events:none}
.vdmg-gallery .vdmg-filmstrip-thumb:focus-visible {outline:3px solid #9f7c25}
.vdmg-layout-filmstrip .vdmg-carousel-viewport {border-radius:0}
.vdmg-image-tile .vdmg-tile-image,.vdmg-new-preview-item {position:relative}
.vdmg-image-tile .vdmg-video-placeholder {min-height:0}
.vdmg-new-preview-item>.vdmg-video-placeholder {width:95px;height:90px;border-radius:8px;min-height:0}
.vdmg-video-tag {position:absolute;bottom:5px;left:5px;background:rgba(16,16,16,.83);color:#fff;font-size:10px;font-weight:700;padding:4px 6px;border-radius:5px;line-height:1.2}
.vdmg-new-preview-item img {max-width:100%}
.vdmg-layout-choices {grid-template-columns:repeat(auto-fit,minmax(148px,1fr))}
.vdmg-photo-grid {gap:11px}
.vdmg-layout-collage .vdmg-photo-grid {gap:11px}
/* Lightbox is appended to body, not constrained by the theme or page layout. */
body.vdmg-lightbox-open {overflow:hidden!important}
.vdmg-lightbox {z-index:2147483000;padding:58px 65px 55px;box-sizing:border-box;touch-action:pan-y;background:rgba(12,12,12,.96)}
.vdmg-lightbox-stage {display:flex;align-items:center;justify-content:center;width:100%;height:100%;min-width:0;min-height:0;pointer-events:none}
.vdmg-lightbox-stage img,.vdmg-lightbox-stage video {width:auto;height:auto;max-width:100%;max-height:100%;object-fit:contain;pointer-events:auto;border:0;box-shadow:none;background:#080808}
.vdmg-lightbox-stage video {width:100%;max-width:min(1100px,100%);max-height:100%;aspect-ratio:auto}
.vdmg-lightbox button {font-family:inherit;cursor:pointer;z-index:2}
.vdmg-lightbox .vdmg-lightbox-close {top:12px;right:20px;width:42px;height:42px;color:#fff;background:rgba(20,20,20,.6);font-size:28px;display:grid;place-items:center;padding:0}
.vdmg-lightbox-prev,.vdmg-lightbox-next {position:absolute;top:50%;transform:translateY(-50%);width:45px;height:50px;border:1px solid rgba(255,255,255,.34);border-radius:10px;color:white;background:rgba(18,18,18,.72);font-size:34px;display:grid;place-items:center;padding:0}
.vdmg-lightbox-prev {left:12px}.vdmg-lightbox-next {right:12px}
.vdmg-lightbox .vdmg-lightbox-count {position:absolute;left:20px;top:21px;color:#fff;font-size:12px;background:rgba(40,40,40,.74);padding:6px 12px;border-radius:25px}
.vdmg-lightbox .vdmg-lightbox-caption {bottom:13px;max-width:80%;white-space:normal;line-height:1.4;font-size:12px}
.vdmg-lightbox button:focus-visible {outline:3px solid #c7a04a;outline-offset:2px}
.vdmg-lightbox button[hidden],.vdmg-gallery button[hidden] {display:none!important}
@media(max-width:570px) {
 .vdmg-layout-filmstrip .vdmg-slide {aspect-ratio:4/3}
 .vdmg-photo .vdmg-play-icon {width:50px;height:50px;font-size:19px}
 .vdmg-photo-grid,.vdmg-layout-collage .vdmg-photo-grid {gap:7px}
 .vdmg-gallery .vdmg-filmstrip-thumb {flex-basis:74px;width:74px;height:56px}
 .vdmg-lightbox {padding:62px 10px 72px}
 .vdmg-lightbox-prev,.vdmg-lightbox-next {top:auto;bottom:14px;transform:none;width:42px;height:42px}
 .vdmg-lightbox-prev {left:15px}.vdmg-lightbox-next {right:15px}
 .vdmg-lightbox .vdmg-lightbox-caption {bottom:21px;max-width:58%;font-size:11px}
 .vdmg-lightbox-stage video {max-height:80vh}
}

/* Business-wide accent color set in VDM Galerías > Configuración. */
.vdmg-wrap .vdmg-btn-gold,.vdmg-wrap .vdmg-pill-active,.vdmg-wrap .vdmg-page-active {background:var(--vdmg-accent,#987923);border-color:var(--vdmg-accent,#987923);color:#fff}
.vdmg-wrap .vdmg-eyebrow,.vdmg-wrap .vdmg-back,.vdmg-wrap .vdmg-copy,.vdmg-wrap .vdmg-upload-icon {color:var(--vdmg-accent,#987923)}
.vdmg-wrap .vdmg-layout-choice input:checked + .vdmg-layout-choice-inner {border-color:var(--vdmg-accent,#987923)}

/* v1.3.0 — five genuinely different public layouts.
   Strongly scoped rules prevent themes and builders from flattening the gallery. */
.vdmg-gallery.vdmg-layout-grid > .vdmg-photo-grid {
 display:grid!important;grid-template-columns:repeat(var(--vdmg-cols,3),minmax(0,1fr))!important;
 grid-auto-flow:row;align-items:stretch;gap:12px
}
.vdmg-gallery.vdmg-layout-grid > .vdmg-photo-grid > .vdmg-photo {
 grid-area:auto;display:block;min-height:0
}
.vdmg-gallery.vdmg-layout-collage > .vdmg-photo-grid {
 display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;
 grid-auto-flow:row dense;align-items:stretch;gap:12px
}
.vdmg-gallery.vdmg-layout-collage > .vdmg-photo-grid > .vdmg-photo {
 display:block;aspect-ratio:1/1;height:auto;grid-area:auto;min-height:0
}
.vdmg-gallery.vdmg-layout-collage > .vdmg-photo-grid > .vdmg-photo:first-child:not(:only-child) {
 grid-column:span 2;grid-row:span 2;aspect-ratio:auto;height:100%
}
.vdmg-gallery.vdmg-layout-collage > .vdmg-photo-grid > .vdmg-photo img {object-fit:cover;width:100%;height:100%}
.vdmg-gallery.vdmg-layout-masonry > .vdmg-photo-grid {
 display:grid!important;grid-template-columns:repeat(var(--vdmg-cols,3),minmax(0,1fr))!important;
 grid-auto-rows:65px;grid-auto-flow:row dense;align-items:stretch;gap:11px;
 column-count:auto!important;columns:auto!important
}
.vdmg-gallery.vdmg-layout-masonry > .vdmg-photo-grid > .vdmg-photo {
 display:block;grid-row:span 2;grid-column:auto;aspect-ratio:auto!important;
 height:100%!important;width:100%;margin:0;break-inside:auto;min-height:0
}
.vdmg-gallery.vdmg-layout-masonry > .vdmg-photo-grid > .vdmg-photo:nth-child(6n+1),
.vdmg-gallery.vdmg-layout-masonry > .vdmg-photo-grid > .vdmg-photo:nth-child(6n+4) {grid-row:span 3}
.vdmg-gallery.vdmg-layout-masonry > .vdmg-photo-grid > .vdmg-photo:nth-child(9n+7) {grid-row:span 4}
.vdmg-gallery.vdmg-layout-masonry > .vdmg-photo-grid > .vdmg-photo img {
 display:block;width:100%;height:100%!important;object-fit:cover!important
}
.vdmg-gallery.vdmg-layout-masonry > .vdmg-photo-grid > .vdmg-photo > .vdmg-video-placeholder {height:100%;aspect-ratio:auto;min-height:0}
.vdmg-gallery.vdmg-layout-carousel .vdmg-carousel-viewport,
.vdmg-gallery.vdmg-layout-filmstrip .vdmg-carousel-viewport {display:flex!important;width:100%;max-width:100%;scroll-snap-type:x mandatory;overflow-x:auto}
.vdmg-gallery.vdmg-layout-carousel .vdmg-carousel-viewport > .vdmg-slide,
.vdmg-gallery.vdmg-layout-filmstrip .vdmg-carousel-viewport > .vdmg-slide {
 display:block;flex:0 0 100%!important;min-width:100%;width:100%;scroll-snap-align:start
}
.vdmg-gallery.vdmg-layout-filmstrip .vdmg-filmstrip-thumbs {display:flex;gap:9px;margin-top:4px}
@media(max-width:570px) {
 .vdmg-gallery.vdmg-layout-grid > .vdmg-photo-grid,
 .vdmg-gallery.vdmg-layout-masonry > .vdmg-photo-grid {grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:7px}
 .vdmg-gallery.vdmg-layout-collage > .vdmg-photo-grid {grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:7px}
 .vdmg-gallery.vdmg-layout-collage > .vdmg-photo-grid > .vdmg-photo:first-child:not(:only-child) {grid-column:span 2;grid-row:span 1;aspect-ratio:16/9}
 .vdmg-gallery.vdmg-layout-masonry > .vdmg-photo-grid {grid-auto-rows:44px}
}

/* Each editor card illustrates the real geometry, instead of repeating an icon. */
.vdmg-layout-visual {display:grid;grid-template-columns:repeat(3,1fr);grid-template-rows:repeat(3,10px);gap:3px;width:86px;height:35px;position:relative;margin-bottom:2px}
.vdmg-layout-visual i {display:block;border-radius:2px;background:#c4a667;opacity:.95;min-width:0;min-height:0}
.vdmg-choice-carousel .vdmg-layout-visual i:first-child,
.vdmg-choice-filmstrip .vdmg-layout-visual i:first-child {grid-column:1/-1;grid-row:1/-1}
.vdmg-choice-carousel .vdmg-layout-visual i:not(:first-child),
.vdmg-choice-filmstrip .vdmg-layout-visual i:not(:first-child) {display:none}
.vdmg-choice-carousel .vdmg-layout-visual:before,
.vdmg-choice-carousel .vdmg-layout-visual:after {position:absolute;top:8px;font-size:17px;color:#fff;line-height:1}
.vdmg-choice-carousel .vdmg-layout-visual:before {content:'‹';left:5px}
.vdmg-choice-carousel .vdmg-layout-visual:after {content:'›';right:5px}
.vdmg-choice-filmstrip .vdmg-layout-visual {grid-template-rows:22px 9px;grid-template-columns:repeat(3,1fr)}
.vdmg-choice-filmstrip .vdmg-layout-visual i:first-child {grid-row:1;grid-column:1/-1}
.vdmg-choice-filmstrip .vdmg-layout-visual i:nth-child(2),
.vdmg-choice-filmstrip .vdmg-layout-visual i:nth-child(3),
.vdmg-choice-filmstrip .vdmg-layout-visual i:nth-child(4) {display:block;grid-row:2}
.vdmg-choice-filmstrip .vdmg-layout-visual i:nth-child(2) {grid-column:1}
.vdmg-choice-filmstrip .vdmg-layout-visual i:nth-child(3) {grid-column:2}
.vdmg-choice-filmstrip .vdmg-layout-visual i:nth-child(4) {grid-column:3}
.vdmg-choice-collage .vdmg-layout-visual i:first-child {grid-area:1/1/3/3;background:#a88536}
.vdmg-choice-collage .vdmg-layout-visual i:nth-child(2) {grid-area:1/3/2/4}
.vdmg-choice-collage .vdmg-layout-visual i:nth-child(3) {grid-area:2/3/3/4}
.vdmg-choice-collage .vdmg-layout-visual i:nth-child(4) {grid-area:3/1/4/2}
.vdmg-choice-collage .vdmg-layout-visual i:nth-child(5) {grid-area:3/2/4/3}
.vdmg-choice-collage .vdmg-layout-visual i:nth-child(6) {grid-area:3/3/4/4}
.vdmg-choice-grid .vdmg-layout-visual {grid-template-rows:repeat(2,1fr);height:35px}
.vdmg-choice-masonry .vdmg-layout-visual {grid-template-rows:repeat(4,1fr);height:35px}
.vdmg-choice-masonry .vdmg-layout-visual i:first-child {grid-row:span 3}
.vdmg-choice-masonry .vdmg-layout-visual i:nth-child(2) {grid-row:span 2}
.vdmg-choice-masonry .vdmg-layout-visual i:nth-child(3) {grid-row:span 4}
.vdmg-choice-masonry .vdmg-layout-visual i:nth-child(n+4) {grid-row:span 1}

/* Instant, unsaved editor preview made from this gallery's selected files. */
.vdmg-preview-wrap {margin-top:26px;border-top:1px solid #eadfce;padding-top:22px}
.vdmg-preview-heading {display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.vdmg-preview-heading h4 {font-family:Georgia,'Times New Roman',serif;font-size:19px;line-height:1.3;margin:0 0 3px;color:#30261a}
.vdmg-preview-heading p {margin:0;font-size:12px;color:#7c684d}
.vdmg-preview-layout-name {flex:none;background:#f5eee1;color:#84661f;font-size:11px;padding:6px 9px;border-radius:20px;font-weight:700}
.vdmg-live-preview {width:100%;max-width:650px;margin:0 auto}
.vdmg-demo {position:relative;min-height:175px;overflow:hidden;isolation:isolate}
.vdmg-demo-tile {position:relative;overflow:hidden;background:#ddc49f;min-width:0;min-height:0;border-radius:8px}
.vdmg-demo-tile:nth-child(6n+2) {background:#aaa68b}
.vdmg-demo-tile:nth-child(6n+3) {background:#bf9977}
.vdmg-demo-tile:nth-child(6n+4) {background:#b59c8b}
.vdmg-demo-tile:nth-child(6n+5) {background:#b4baa3}
.vdmg-demo-tile:nth-child(6n+6) {background:#c7b18f}
.vdmg-demo-tile img {display:block;width:100%;height:100%;object-fit:cover}
.vdmg-demo-play {display:grid;place-items:center;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:40px;height:40px;border-radius:50%;background:#171717af;color:#fff;padding-left:2px}
.vdmg-demo-featured {width:100%;height:235px;display:block;background:#c5b196}
.vdmg-demo-carousel .vdmg-demo-featured,.vdmg-demo-filmstrip .vdmg-demo-featured {border-radius:10px}
.vdmg-demo-ratio-square .vdmg-demo-featured {height:300px}
.vdmg-demo-ratio-portrait .vdmg-demo-featured {height:345px}
.vdmg-demo-arrow {position:absolute;top:98px;width:29px;height:33px;border-radius:7px;background:#ffffffdd;color:#715726;display:grid;place-items:center;font-size:25px;line-height:1}
.vdmg-demo-arrow-left {left:10px}.vdmg-demo-arrow-right {right:10px}
.vdmg-demo-dots {text-align:center;color:#947629;letter-spacing:5px;font-size:13px;margin:2px 0}
.vdmg-demo-thumbnails {display:flex;gap:8px;margin-top:10px;overflow:hidden}
.vdmg-demo-thumbnails .vdmg-demo-tile {width:70px;flex:0 0 70px;height:54px;border:2px solid transparent}
.vdmg-demo-thumbnails .vdmg-demo-tile:first-child {border-color:var(--vdmg-accent,#987923)}
.vdmg-demo-thumbnails .vdmg-demo-play {width:25px;height:25px;font-size:11px}
.vdmg-demo-grid {display:grid;gap:9px}
.vdmg-demo-grid .vdmg-demo-tile {aspect-ratio:16/9}
.vdmg-demo-ratio-square .vdmg-demo-grid .vdmg-demo-tile {aspect-ratio:1}
.vdmg-demo-ratio-portrait .vdmg-demo-grid .vdmg-demo-tile {aspect-ratio:3/4}
.vdmg-demo-ratio-natural .vdmg-demo-grid .vdmg-demo-tile {aspect-ratio:4/3}
.vdmg-demo-grid .vdmg-demo-tile img {height:100%}
.vdmg-demo-grid .vdmg-demo-tile:only-child {min-height:160px}
.vdmg-demo-grid .vdmg-demo-tile {width:100%}
.vdmg-demo-grid .vdmg-demo-play {width:29px;height:29px;font-size:12px}
.vdmg-demo-grid,.vdmg-demo-collage .vdmg-demo-grid {grid-template-columns:repeat(var(--vdmg-demo-cols,3),minmax(0,1fr))}
.vdmg-demo-collage .vdmg-demo-grid {grid-template-columns:repeat(3,minmax(0,1fr));grid-auto-flow:row dense}
.vdmg-demo-collage .vdmg-demo-grid .vdmg-demo-tile {aspect-ratio:1}
.vdmg-demo-collage .vdmg-demo-grid .vdmg-demo-tile:first-child {grid-column:span 2;grid-row:span 2;aspect-ratio:auto;height:100%}
.vdmg-demo-masonry .vdmg-demo-grid {grid-auto-rows:52px;grid-auto-flow:row dense}
.vdmg-demo-masonry .vdmg-demo-grid .vdmg-demo-tile {aspect-ratio:auto;height:100%;grid-row:span 2}
.vdmg-demo-masonry .vdmg-demo-grid .vdmg-demo-tile:nth-child(6n+1),
.vdmg-demo-masonry .vdmg-demo-grid .vdmg-demo-tile:nth-child(6n+4) {grid-row:span 3}
.vdmg-demo-masonry .vdmg-demo-grid .vdmg-demo-tile:nth-child(9n+7) {grid-row:span 4}
.vdmg-preview-help {font-size:12px!important;color:#7b6649;margin:14px 0 0!important;text-align:center}
@media(max-width:570px) {
 .vdmg-preview-heading {align-items:flex-start}
 .vdmg-preview-layout-name {margin-top:1px}
 .vdmg-demo-grid,.vdmg-demo-collage .vdmg-demo-grid,.vdmg-demo-masonry .vdmg-demo-grid {grid-template-columns:repeat(2,minmax(0,1fr))}
 .vdmg-demo-collage .vdmg-demo-grid .vdmg-demo-tile:first-child {grid-column:span 2;grid-row:span 1;aspect-ratio:16/9}
 .vdmg-demo-masonry .vdmg-demo-grid {grid-auto-rows:39px}
 .vdmg-demo-featured {height:195px}
 .vdmg-demo-arrow {top:75px}
}

/* 1.3.1: a small confirmation of the actually saved gallery layout. */
.vdmg-wrap .vdmg-layout-confirmation {background:#f8f3e8;border:1px solid #e5d2ad;border-radius:10px;padding:12px 15px;margin:15px 0;color:#563f18;font-size:13px;line-height:1.5}


/* VDM Galerías 1.4 — título público y escaparate de mosaico desplazable.
   Mantener reglas estrictamente limitadas al widget para no interferir con GenerateBlocks. */
.vdmg-gallery > .vdmg-gallery-title {
  font-family:inherit; font-size:clamp(21px,2.9vw,30px); font-weight:700;
  color:inherit; line-height:1.23; margin:0 0 16px!important; padding:0;
  overflow-wrap:anywhere;
}
.vdmg-gallery.vdmg-layout-masonry > .vdmg-mosaic-shell {
  position:relative; width:100%; min-width:0;
}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-viewport {
  display:block!important; max-width:100%; width:100%; overflow-x:auto!important; overflow-y:hidden!important;
  touch-action:pan-x pan-y; -webkit-overflow-scrolling:touch;
  overscroll-behavior-x:contain; scroll-snap-type:x proximity;
  scroll-padding-inline:2px; scrollbar-width:thin;
  scrollbar-color:#b6a581 transparent;
  cursor:grab; user-select:none; -webkit-user-select:none;
}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-viewport.is-dragging {cursor:grabbing;scroll-snap-type:none}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-track {
  display:flex!important; flex-wrap:nowrap!important; align-items:stretch; gap:10px;
  width:100%; min-width:100%; padding:0 0 5px;
  height:clamp(300px,40vw,460px);
}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col {
  display:flex!important; flex-direction:column; flex:0 0 42%;
  min-width:0; width:42%; max-width:42%; height:100%; gap:9px;
  scroll-snap-align:start;
}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col:only-child {flex-basis:100%;width:100%;max-width:100%}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col > .vdmg-photo {
  position:relative; display:block!important; flex:1 1 0!important;
  min-height:0!important; height:0!important; width:100%!important;
  aspect-ratio:auto!important; border-radius:5px;
  margin:0!important; overflow:hidden!important; touch-action:pan-x pan-y;
}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col > .vdmg-photo img,
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col > .vdmg-photo > .vdmg-video-placeholder {
  display:block; width:100%!important; height:100%!important; object-fit:cover!important;
  aspect-ratio:auto!important; pointer-events:none;
}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col:nth-child(3n+1) > .vdmg-photo:first-child {flex-grow:1.35!important}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col:nth-child(3n+2) > .vdmg-photo:first-child {flex-grow:1.8!important}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col:nth-child(3n+3) > .vdmg-photo:first-child {flex-grow:.72!important}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col.vdmg-mosaic-single > .vdmg-photo:first-child {flex-grow:1!important}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-nav {
  position:absolute; top:50%; transform:translateY(-50%); z-index:3;
  display:grid;place-items:center;width:38px;height:44px;padding:0;
  background:#fff; color:#30291e; border:1px solid #e7d7b6;
  border-radius:50px; font-size:27px; line-height:1; cursor:pointer;
  box-shadow:0 3px 14px #0003;
}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-nav:hover {background:#f6eddf}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-nav:focus-visible {outline:3px solid #9a7929;outline-offset:3px}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-prev {left:8px}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-next {right:8px}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-nav:disabled {opacity:.35;cursor:default}
.vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-nav[hidden] {display:none!important}
.vdmg-gallery .vdmg-mosaic-hint {font-size:12px; color:#7d6a50; margin:5px 2px 0!important;text-align:right}
.vdmg-gallery .vdmg-mosaic-hint[hidden] {display:none!important}
@media(max-width:700px){
  .vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-track {height:clamp(300px,75vw,420px);gap:7px}
  .vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col {flex-basis:64%;width:64%;max-width:64%;gap:7px}
  .vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-col:only-child {flex-basis:100%;width:100%;max-width:100%}
  .vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-nav {width:30px;height:35px;font-size:23px}
  .vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-prev {left:4px}
  .vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-next {right:4px}
}
@media(prefers-reduced-motion:reduce) {
  .vdmg-gallery.vdmg-layout-masonry .vdmg-mosaic-viewport {scroll-behavior:auto!important}
}
/* Editor: preview con el mismo sentido horizontal que el mosaico público. */
.vdmg-demo-masonry {overflow:hidden}
.vdmg-demo-masonry .vdmg-demo-mosaic-viewport {overflow-x:auto;scroll-snap-type:x proximity;max-width:100%;width:100%;-webkit-overflow-scrolling:touch}
.vdmg-demo-masonry .vdmg-demo-mosaic-track {display:flex;gap:8px;width:max-content;min-width:100%;height:290px;padding-bottom:6px}
.vdmg-demo-masonry .vdmg-demo-mosaic-col {display:flex;flex-direction:column;gap:7px;width:200px;flex:0 0 200px;height:100%;scroll-snap-align:start}
.vdmg-demo-masonry .vdmg-demo-mosaic-col .vdmg-demo-tile {height:0;flex:1 1 0;aspect-ratio:auto!important;width:100%}
.vdmg-demo-masonry .vdmg-demo-mosaic-col:nth-child(3n+1) .vdmg-demo-tile:first-child {flex-grow:1.35}
.vdmg-demo-masonry .vdmg-demo-mosaic-col:nth-child(3n+3) .vdmg-demo-tile:first-child {flex-grow:.72}
.vdmg-demo-masonry .vdmg-demo-mosaic-col.vdmg-demo-mosaic-single .vdmg-demo-tile {flex-grow:1}
@media(max-width:570px){.vdmg-demo-masonry .vdmg-demo-mosaic-col{width:64vw;max-width:240px;flex-basis:min(64vw,240px)}.vdmg-demo-masonry .vdmg-demo-mosaic-track{height:255px}}
