.dp360-viewer {
position: relative;
width: 100%;
max-width: 640px;
aspect-ratio: 1 / 1;
margin: 0 auto 24px;
background: #f5f5f5;
border: 1px solid #e5e5e5;
border-radius: 8px;
overflow: hidden;
user-select: none;
-webkit-user-select: none;
-ms-user-select: none;
cursor: grab;
touch-action: pan-y;
box-sizing: border-box;
contain: layout paint;
}
.dp360-viewer.dp360-dragging {
cursor: grabbing;
}
.dp360-viewer * {
box-sizing: border-box;
}
.dp360-canvas {
position: absolute;
inset: 0;
display: block;
width: 100%;
height: 100%;
pointer-events: none;
image-rendering: auto;
will-change: contents;
} .dp360-spinner {
position: absolute;
inset: 0;
display: flex;
align-items: center;
justify-content: center;
flex-direction: column;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
font-size: 14px;
font-weight: 500;
color: #666;
background: rgba(245, 245, 245, 0.9);
backdrop-filter: blur(2px);
-webkit-backdrop-filter: blur(2px);
transition: opacity 0.4s ease;
pointer-events: none;
}
.dp360-spinner::before {
content: "";
display: block;
width: 34px;
height: 34px;
margin-bottom: 12px;
border: 3px solid #ddd;
border-top-color: #666;
border-radius: 50%;
animation: dp360-spin 0.9s linear infinite;
}
@keyframes dp360-spin {
to { transform: rotate(360deg); }
}
.dp360-viewer.dp360-ready .dp360-spinner {
opacity: 0;
} .dp360-hint {
position: absolute;
bottom: 59px;
left: 50%;
transform: translateX(-50%);
display: flex;
align-items: center;
gap: 5px;
background: rgba(0, 0, 0, 0.7);
color: #fff;
padding: 4px 10px;
border-radius: 20px;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
font-size: 10px;
font-weight: 500;
opacity: 0;
pointer-events: none;
transition: opacity 0.35s ease, transform 0.35s ease;
white-space: nowrap;
z-index: 3;
}
.dp360-hint svg {
width: 12px;
height: 12px;
flex-shrink: 0;
} .dp360-viewer.dp360-ready .dp360-hint {
opacity: 1;
}
.dp360-viewer.dp360-moving .dp360-hint {
opacity: 0;
transform: translateX(-50%) translateY(6px);
} .dp360-controls {
position: absolute;
bottom: 14px;
left: 50%;
transform: translateX(-50%);
display: flex;
align-items: center;
gap: 4px;
padding: 3px 5px;
background: rgba(255, 255, 255, 0.92);
border: 1px solid rgba(0, 0, 0, 0.08);
border-radius: 999px;
box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
opacity: 0;
transition: opacity 0.4s ease;
pointer-events: none;
z-index: 4;
backdrop-filter: blur(6px);
-webkit-backdrop-filter: blur(6px);
}
.dp360-viewer.dp360-ready .dp360-controls {
opacity: 1;
pointer-events: auto;
}
.dp360-btn {
appearance: none;
-webkit-appearance: none;
background: transparent;
border: 0;
color: #222;
width: 26px;
height: 26px;
min-width: 26px;
min-height: 26px;
flex: 0 0 26px;
aspect-ratio: 1 / 1;
box-sizing: border-box;
padding: 0;
margin: 0;
display: flex;
align-items: center;
justify-content: center;
border-radius: 50%;
cursor: pointer;
transition: background-color 0.15s ease, color 0.15s ease, transform 0.1s ease;
font: inherit;
line-height: 1;
}
.dp360-btn svg {
width: 14px;
height: 14px;
display: block;
pointer-events: none;
}
.dp360-btn:hover {
background: rgba(0, 0, 0, 0.07);
}
.dp360-btn:active {
transform: scale(0.94);
background: rgba(0, 0, 0, 0.12);
}
.dp360-btn:focus {
outline: none;
}
.dp360-btn:focus-visible {
outline: 2px solid #2b90d9;
outline-offset: 2px;
}
.dp360-btn-play {
background: #222;
color: #fff;
}
.dp360-btn-play:hover {
background: #000;
}
.dp360-btn-play:active {
background: #000;
}
.dp360-viewer.dp360-autoplay .dp360-btn-play {
background: #2b90d9;
}
.dp360-viewer.dp360-autoplay .dp360-btn-play:hover {
background: #1e7fc0;
} .dp360-error {
padding: 20px;
text-align: center;
color: #a00;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
font-size: 14px;
} .dp360-gallery {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
gap: 24px;
max-width: 1400px;
margin: 0 auto;
padding: 20px;
}
.dp360-gallery .dp360-viewer {
max-width: 100%;
}
@media (max-width: 640px) {
.dp360-viewer {
margin: 0 auto 30px;
}
.dp360-gallery {
gap: 16px;
padding: 12px;
}
.dp360-hint {
bottom: 49px;
font-size: 10px;
padding: 4px 8px;
}
.dp360-controls {
bottom: 10px;
gap: 3px;
padding: 2px 4px;
}
.dp360-btn {
width: 24px;
height: 24px;
min-width: 24px;
min-height: 24px;
flex: 0 0 24px;
}
.dp360-btn svg {
width: 12px;
height: 12px;
}
}