/* Tera3dKonfigurator Styles */
* {
    box-sizing: border-box;
}

#tp3d-app-container {
    font-family: 'Roboto', sans-serif;
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 25px;
    margin: 30px 0;
    min-height: 600px;
}

@media (max-width: 768px) {
    #tp3d-app-container {
        grid-template-columns: 1fr;
    }
}

/* Sidebar */
#tp3d-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.tp3d-step {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.tp3d-step h3 {
    color: #337ab7;
    border-bottom: 2px solid #337ab7;
    font-size: 14px;
    font-weight: 700;
    padding-bottom: 8px;
    margin: 0 0 15px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Upload */
.upload-zone {
    text-align: center;
}

.upload-button {
    background: #337ab7;
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 700;
    font-size: 14px;
    transition: background 0.3s;
    width: 100%;
}

.upload-button:hover {
    background: #2868a0;
}

.file-info {
    margin-top: 10px;
    font-size: 12px;
    color: #666;
    word-break: break-all;
}

/* Dimensionen */
.dimension-group {
    margin-bottom: 15px;
}

.dimension-group label {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #333;
    margin-bottom: 6px;
}

.dimension-group input[type="number"] {
    width: 100%;
    padding: 10px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    font-family: 'Roboto', sans-serif;
}

.dimension-group input[type="number"]:focus {
    outline: none;
    border-color: #337ab7;
}

.dimension-group input[type="range"] {
    width: 100%;
    margin-top: 5px;
}

#d-val {
    font-weight: 700;
    color: #337ab7;
}

/* Material & Farbe */
.material-group,
.color-group {
    margin-bottom: 15px;
}

.material-group label,
.color-group label {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #333;
    margin-bottom: 6px;
}

.material-group select {
    width: 100%;
    padding: 10px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    font-family: 'Roboto', sans-serif;
    background: #fff;
}

.color-group input[type="color"] {
    width: 100%;
    height: 45px;
    border: 2px solid #ddd;
    border-radius: 5px;
    cursor: pointer;
}

/* Summary */
#tp3d-summary {
    background: linear-gradient(135deg, #f9f9f9 0%, #fff 100%);
    padding: 20px;
    border-radius: 8px;
    border-left: 5px solid #f36f21;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.info-bar {
    font-size: 14px;
    color: #666;
    margin-bottom: 12px;
    text-align: center;
}

#print-details {
    background: #fff;
    padding: 12px;
    border-radius: 5px;
    margin-bottom: 15px;
    font-size: 12px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    color: #333;
}

.detail-row:last-child {
    margin-bottom: 0;
}

.detail-row span:first-child {
    font-weight: 400;
}

.detail-row span:last-child {
    font-weight: 700;
    color: #337ab7;
}

#price-tag {
    font-size: 32px;
    font-weight: 700;
    color: #f36f21;
    text-align: center;
    margin: 15px 0;
    text-shadow: 0 2px 4px rgba(243,111,33,0.2);
}

#tp3d-calc-btn,
#tp3d-cart-btn {
    background: #f36f21;
    color: #fff;
    border: none;
    padding: 14px 24px;
    width: 100%;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s;
    box-shadow: 0 4px 8px rgba(243,111,33,0.3);
}

#tp3d-calc-btn:hover:not(:disabled),
#tp3d-cart-btn:hover {
    background: #d85f1a;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(243,111,33,0.4);
}

#tp3d-calc-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    box-shadow: none;
}

#tp3d-cart-btn {
    margin-top: 10px;
    background: #337ab7;
    box-shadow: 0 4px 8px rgba(51,122,183,0.3);
}

#tp3d-cart-btn:hover {
    background: #2868a0;
}

/* Viewport */
#tp3d-viewport-wrapper {
    position: relative;
    background: #f5f5f5;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}

#tp3d-viewport {
    width: 100%;
    aspect-ratio: 1100 / 750;
    background: linear-gradient(135deg, #e8e8e8 0%, #f5f5f5 100%);
    position: relative;
}

#tp3d-loading {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.95);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #337ab7;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

#tp3d-loading p {
    margin-top: 15px;
    color: #337ab7;
    font-weight: 700;
    font-size: 14px;
}
