/* CSS Clip-path Maker Styles */

.clippath-preview-container {
    min-height: 350px;
    background: repeating-conic-gradient(#e2e8f0 0% 25%, transparent 0% 50%) 50% / 20px 20px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

[data-bs-theme="dark"] .clippath-preview-container {
    background: repeating-conic-gradient(#374151 0% 25%, transparent 0% 50%) 50% / 20px 20px;
}

.clippath-preview-wrapper {
    position: relative;
    width: 300px;
    height: 300px;
}

.clippath-preview-box {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transition: clip-path 0.15s ease;
}

.clippath-points-svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: visible;
}

.clippath-points-svg .draggable-point {
    pointer-events: all;
    transition: fill 0.2s ease;
}

.clippath-points-svg .draggable-point:hover {
    fill: #4f46e5;
    transform-origin: center;
}

/* Point control rows */
.point-control-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px;
    background: var(--bs-secondary-bg);
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-wrap: wrap;
    gap: 10px;
}

.point-control-row:hover {
    background: var(--bs-tertiary-bg);
}

.point-control-row.selected {
    border-left: 3px solid #6366f1;
    padding-left: 7px;
}

.point-label {
    font-weight: 500;
    min-width: 70px;
}

.point-inputs {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.point-inputs .input-group {
    width: auto;
}

.point-inputs input[type="number"] {
    width: 60px;
}

/* CSS Output */
.css-output {
    background: var(--bs-secondary-bg);
    padding: 15px;
    border-radius: 8px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.85rem;
    white-space: pre-wrap;
    word-break: break-all;
    color: var(--bs-body-color);
    overflow-x: auto;
}

/* Shape buttons */
.shape-btn.active {
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
    color: #fff;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .clippath-preview-container {
        min-height: 280px;
        padding: 15px;
    }

    .clippath-preview-wrapper {
        width: 250px;
        height: 250px;
    }

    .point-control-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .point-inputs {
        width: 100%;
    }

    .point-inputs .input-group {
        flex: 1;
    }
}

@media (max-width: 480px) {
    .clippath-preview-wrapper {
        width: 200px;
        height: 200px;
    }
}
