.container.full-width {
    max-width: 100%;
    padding: 20px;
    height: 100vh;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

.tool-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.tool-header h1 {
    font-size: 1.5rem;
    margin: 0;
}

.editor-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    flex: 1;
    min-height: 0;
    /* Important for nested scrolling */
}

.panel {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.panel-header {
    padding: 15px;
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 0, 0, 0.2);
}

.panel-header h3 {
    margin: 0;
    font-size: 1rem;
    color: var(--text-color);
}

.badge {
    font-size: 0.75rem;
    background: var(--primary-color);
    color: white;
    padding: 2px 8px;
    border-radius: 10px;
}

/* Code Editor */
.code-editor-wrapper {
    flex: 1;
    position: relative;
}

#svg-code {
    width: 100%;
    height: 100%;
    background: #1e1e1e;
    color: #d4d4d4;
    border: none;
    padding: 15px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    line-height: 1.5;
    resize: none;
    outline: none;
    box-sizing: border-box;
}

.drop-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(59, 130, 246, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s;
}

.code-editor-wrapper.drag-over .drop-overlay {
    opacity: 1;
}

.drop-message {
    text-align: center;
    color: white;
}

.drop-message svg {
    margin-bottom: 10px;
}

.drop-message p {
    font-size: 1.2rem;
    font-weight: 600;
}

.hidden {
    display: none;
}

/* Preview */
.preview-canvas-wrapper {
    flex: 1;
    background: repeating-conic-gradient(#222 0% 25%, #333 0% 50%) 50% / 20px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: auto;
    padding: 20px;
    position: relative;
}

#preview-container {
    max-width: 100%;
    max-height: 100%;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
}

#preview-container svg {
    display: block;
    max-width: 100%;
    max-height: 100%;
    height: auto;
}

.empty-state {
    color: var(--text-muted);
    text-align: center;
}

.download-actions {
    padding: 15px;
    border-top: 1px solid var(--glass-border);
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: flex-end;
    gap: 15px;
    align-items: center;
}

.action-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.action-group label {
    font-size: 0.9rem;
    color: var(--text-muted);
}

select {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--glass-border);
    color: white;
    padding: 8px;
    border-radius: 6px;
    outline: none;
}

select option {
    background: #222;
}

@media (max-width: 768px) {
    .editor-layout {
        grid-template-columns: 1fr;
        grid-template-rows: 1fr 1fr;
    }

    .container.full-width {
        height: auto;
        min-height: 100vh;
    }

    .code-editor-wrapper,
    .preview-canvas-wrapper {
        min-height: 300px;
    }
}