.ai3d-main {
    flex: 1;
    min-width: 0;
}

.ai3d-preview-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.ai3d-preview-wrap {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 130px);
    height: 100%;
    padding: 24px;
    border-radius: 22px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: linear-gradient(180deg, rgba(10, 14, 22, 0.82), rgba(7, 10, 16, 0.95));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 26px 60px rgba(0, 0, 0, 0.28);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
}

.ai3d-preview-wrap[data-stage-state="loading"] .ai3d-preview-stage {
    border-color: rgba(114, 171, 255, 0.34);
    box-shadow: 0 0 0 1px rgba(114, 171, 255, 0.06), 0 28px 55px rgba(29, 72, 168, 0.18);
}

.ai3d-preview-wrap[data-stage-state="success"] .ai3d-preview-stage {
    border-color: rgba(96, 212, 170, 0.32);
    box-shadow: 0 0 0 1px rgba(96, 212, 170, 0.06), 0 28px 58px rgba(17, 78, 56, 0.18);
}

.ai3d-preview-wrap[data-stage-state="error"] .ai3d-preview-stage {
    border-color: rgba(255, 154, 120, 0.28);
    box-shadow: 0 0 0 1px rgba(255, 154, 120, 0.05), 0 28px 58px rgba(104, 39, 15, 0.18);
}

.ai3d-preview-copy {
    max-width: 680px;
}

.ai3d-preview-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(68, 111, 255, 0.12);
    border: 1px solid rgba(104, 151, 255, 0.24);
    color: #a9cfff;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.ai3d-preview-title {
    margin: 12px 0 10px;
    color: #fff;
    font-size: clamp(24px, 2.2vw, 34px);
    line-height: 1.18;
    font-weight: 600;
}

.ai3d-preview-subtitle {
    margin: 0;
    color: #97a4bf;
    font-size: 14px;
    line-height: 1.75;
}

.ai3d-preview-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.ai3d-preview-control,
.ai3d-preview-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 16px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(18, 24, 35, 0.88);
    color: #dce7fb;
    font-size: 13px;
    text-decoration: none;
    transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.ai3d-preview-control {
    cursor: pointer;
}

.ai3d-preview-control:hover,
.ai3d-preview-link:hover {
    border-color: rgba(114, 178, 255, 0.4);
    background: rgba(34, 48, 74, 0.92);
    transform: translateY(-1px);
}

.ai3d-preview-control[disabled] {
    opacity: 0.45;
    cursor: not-allowed;
    transform: none;
}

.ai3d-preview-stage {
    position: relative;
    flex: 1;
    min-height: 520px;
    margin-top: 20px;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background:
        radial-gradient(circle at 50% 18%, rgba(91, 134, 255, 0.22), transparent 34%),
        linear-gradient(180deg, rgba(12, 18, 28, 0.98), rgba(4, 7, 12, 0.98));
}

.ai3d-preview-stage::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 44px 44px;
    opacity: 0.26;
    pointer-events: none;
}

.ai3d-preview-stage::after {
    content: "";
    position: absolute;
    inset: 24px;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    pointer-events: none;
}

.ai3d-preview-mount {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    min-height: 520px;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
}

.ai3d-preview-canvas-frame {
    position: relative;
    width: 100%;
    min-height: 520px;
}

.ai3d-preview-format-badge {
    position: absolute;
    top: 18px;
    left: 18px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 62px;
    height: 30px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(8, 12, 20, 0.74);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #dce7fb;
    font-size: 12px;
    letter-spacing: 0.08em;
    pointer-events: none;
}

.ai3d-preview-hud {
    position: absolute;
    left: 18px;
    bottom: 18px;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    max-width: calc(100% - 36px);
    pointer-events: none;
}

.ai3d-preview-hud-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(7, 12, 20, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #dce7fb;
    font-size: 12px;
}

.ai3d-preview-stage-panel {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 34px;
}

.ai3d-preview-stage-card {
    width: min(560px, 100%);
    padding: 34px 30px;
    border-radius: 22px;
    background: rgba(10, 14, 22, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.26);
    text-align: center;
}

.ai3d-preview-stage-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 18px;
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(54, 105, 255, 0.26), rgba(90, 206, 255, 0.2));
    border: 1px solid rgba(110, 166, 255, 0.24);
    color: #dce7fb;
    font-size: 28px;
}

.ai3d-preview-stage-title {
    margin: 0;
    color: #fff;
    font-size: 24px;
    line-height: 1.3;
}

.ai3d-preview-stage-desc {
    margin: 12px 0 0;
    color: #a8b5cd;
    font-size: 14px;
    line-height: 1.8;
}

.ai3d-preview-stage-meta {
    margin-top: 18px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #dce7fb;
    font-size: 12px;
}

